/* Geri bildirim widget'ı — magaza/sepet/siparislerim/yasal/iletisim sayfalarında
   js/feedback-widget.js tarafından DOM'a enjekte edilir. Sayfalar farklı CSS setleri
   yüklediği için (.modal-overlay yalnız sepet.css/hesabim.css/admin.css'te var) burada
   hiçbir dış sınıfa güvenilmez; her şey kendi içinde tanımlıdır. */

.feedback-fab {
    position: fixed;
    /* Masaüstünde .scroll-top-btn bottom:30px/right:30px'te oturuyor; hemen üstüne hizalı. */
    bottom: 95px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 1px solid var(--border-medium, rgba(0, 0, 0, 0.12));
    background: var(--card-bg, #fff);
    color: var(--btn-primary-bg, #b87333);
    font-size: 21px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
    /* Alt navigasyon (1001) ve kategori çekmecesi (1030) üstünde; çerez bandı (9999) ve
       PWA giriş katmanı (12000) altında. */
    z-index: 1050;
    transition: transform 0.2s, box-shadow 0.2s;
}

/* Çerez bandı açıkken (z-index 9999) düğme zaten örtülü kalıyor; js tarafı bu sınıfla gizler. */
.feedback-fab.is-suppressed { display: none; }

.feedback-fab:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.24);
}

.feedback-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(4px);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
}

.feedback-overlay.is-open { display: flex; }

.feedback-card {
    background: var(--card-bg, #fff);
    color: var(--text-primary, #1c1917);
    width: 100%;
    max-width: 460px;
    max-height: 90vh;
    overflow-y: auto;
    border-radius: 16px;
    padding: 22px;
    box-sizing: border-box;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
    text-align: start;
}

.feedback-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 6px;
}

.feedback-card-header h2 {
    margin: 0;
    font-size: 20px;
    font-weight: 900;
    color: var(--text-primary, #1c1917);
}

.feedback-close {
    background: transparent;
    border: none;
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
    color: var(--text-tertiary, #78716c);
    padding: 0 4px;
}

.feedback-intro {
    margin: 0 0 18px 0;
    font-size: 13px;
    line-height: 1.5;
    color: var(--text-secondary, #57534e);
}

.feedback-field { margin-bottom: 14px; }

.feedback-field label {
    display: block;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    color: var(--text-secondary, #57534e);
    margin-bottom: 6px;
}

.feedback-field select,
.feedback-field input,
.feedback-field textarea {
    width: 100%;
    box-sizing: border-box;
    padding: 11px 12px;
    font-family: inherit;
    font-size: 14px;
    color: var(--text-primary, #1c1917);
    background: var(--bg-secondary, #fafaf9);
    border: 1px solid var(--border-medium, rgba(0, 0, 0, 0.15));
    border-radius: 9px;
}

.feedback-field textarea {
    min-height: 120px;
    resize: vertical;
    line-height: 1.5;
}

.feedback-field select:focus,
.feedback-field input:focus,
.feedback-field textarea:focus {
    outline: none;
    border-color: var(--btn-primary-bg, #b87333);
}

.feedback-counter {
    display: block;
    margin-top: 5px;
    font-size: 11px;
    color: var(--text-tertiary, #78716c);
    text-align: end;
}

.feedback-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 18px;
}

.feedback-actions button {
    padding: 11px 22px;
    font-family: inherit;
    font-size: 14px;
    font-weight: 700;
    border-radius: 9px;
    cursor: pointer;
    border: 1px solid transparent;
}

.feedback-actions button[disabled] { opacity: 0.6; cursor: default; }

.feedback-cancel-btn {
    background: transparent;
    border-color: var(--border-medium, rgba(0, 0, 0, 0.15));
    color: var(--text-secondary, #57534e);
}

.feedback-submit-btn {
    background: var(--btn-primary-bg, #b87333);
    color: #fff;
}

@media (max-width: 768px) {
    .feedback-fab {
        /* Mobilde alt bölge dolu: alt nav 65px, sepet/ürün detay barı bottom:65px,
           yukarı-çık butonu bottom:80px. 130px üstü serbest. */
        bottom: 150px;
        right: 14px;
        width: 44px;
        height: 44px;
        font-size: 19px;
    }

    .feedback-overlay { padding: 14px; align-items: flex-end; }

    .feedback-card {
        max-height: 85vh;
        padding: 18px;
        border-radius: 16px;
    }
}
