/* ═══════════════════════════════════════════════════════
   review-components.css
   Ekip Calismasi paneli + Bildirim widget + Davet modal
   docx-sidebar tasarim diline uyumlu
   ═══════════════════════════════════════════════════════ */

/* ── Bildirim Widget ─────────────────────────────────── */
.bildirim-item {
    padding: 12px 20px;
    border-bottom: 1px solid #f1f5f9;
    cursor: pointer;
    transition: background 0.15s;
}
.bildirim-item:hover { background: #f8fafc; }
.bildirim-item.bildirim-okunmadi { background: #eff6ff; }
.bildirim-item.bildirim-okunmadi:hover { background: #dbeafe; }
.bildirim-icerik { display: flex; flex-direction: column; gap: 2px; }
.bildirim-baslik { font-size: 13px; font-weight: 500; color: #1e293b; }
.bildirim-detay { font-size: 12px; color: #64748b; }
.bildirim-tarih { font-size: 11px; color: #94a3b8; margin-top: 2px; }
.bildirim-bos { padding: 48px 32px; text-align: center; font-size: 13px; color: #94a3b8; display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 200px; gap: 6px; }
.bildirim-item:last-child { border-bottom: none; }
.bildirim-footer {
    position: sticky; bottom: 0;
    padding: 10px 20px; border-top: 1px solid #f1f5f9;
    text-align: center; background: #fff;
    box-shadow: 0 -1px 4px rgba(0,0,0,0.04);
    z-index: 1;
}
.bildirim-tumunu-okundu-btn {
    font-size: 12px; color: #3b82f6; background: none; border: none;
    cursor: pointer; padding: 4px 8px;
}
.bildirim-tumunu-okundu-btn:hover { text-decoration: underline; }
.dark .bildirim-footer { background: #0f172a; box-shadow: 0 -1px 4px rgba(0,0,0,0.4); }

.dark .bildirim-item { border-color: #1e293b; }
.dark .bildirim-item:hover { background: #1e293b; }
.dark .bildirim-item.bildirim-okunmadi { background: #172554; }
.dark .bildirim-item.bildirim-okunmadi:hover { background: #1e3a5f; }
.dark .bildirim-baslik { color: #e2e8f0; }
.dark .bildirim-detay { color: #94a3b8; }
.dark .bildirim-tarih { color: #64748b; }
.dark .bildirim-footer { border-color: #1e293b; }

/* ── Ekip Paneli (docx-sidebar tarzi) ────────────────── */
.ekip-panel {
    width: 320px; border-left: 1px solid #e5e7eb;
    background: #fff; display: flex; flex-direction: column;
    overflow: hidden; flex-shrink: 0;
}
.ekip-panel-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 14px 16px; border-bottom: 1px solid #e5e7eb;
}
.ekip-panel-header h3 {
    font-size: 14px; font-weight: 700; margin: 0;
    display: flex; align-items: center; gap: 8px;
}
.ekip-panel-close {
    width: 28px; height: 28px; border: none; background: none;
    color: #6b7280; cursor: pointer; border-radius: 6px;
    display: flex; align-items: center; justify-content: center;
    transition: background 0.15s;
}
.ekip-panel-close:hover { background: #f3f4f6; color: #374151; }
.ekip-panel-body { flex: 1; overflow-y: auto; display: flex; flex-direction: column; }

.ekip-bos {
    display: flex; flex-direction: column; align-items: center;
    justify-content: center; padding: 32px 20px; text-align: center; flex: 1;
}
.ekip-baslat-btn {
    padding: 10px 20px; background: #6366f1; color: white;
    border: none; border-radius: 8px; font-size: 14px; font-weight: 500;
    cursor: pointer; transition: background 0.15s;
}
.ekip-baslat-btn:hover { background: #4f46e5; }
.ekip-baslat-btn:disabled { opacity: 0.6; cursor: not-allowed; }

.ekip-durum-bar {
    padding: 10px 16px; border-bottom: 1px solid #f3f4f6;
    display: flex; align-items: center;
}
.ekip-durum-badge {
    display: inline-flex; align-items: center; gap: 6px;
    font-size: 12px; font-weight: 600; color: #16a34a;
    background: #f0fdf4; padding: 4px 10px; border-radius: 12px;
}
.ekip-durum-dot {
    width: 6px; height: 6px; background: #22c55e; border-radius: 50%;
    animation: ekipDotPulse 2s infinite;
}
@keyframes ekipDotPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

/* Dark ekip paneli */
.dark .ekip-panel { background: #1e293b; border-color: #334155; }
.dark .ekip-panel-header { border-color: #334155; }
.dark .ekip-panel-header h3 { color: #f1f5f9; }
.dark .ekip-panel-close:hover { background: #334155; color: #e2e8f0; }
.dark .ekip-baslat-btn { background: #818cf8; }
.dark .ekip-baslat-btn:hover { background: #6366f1; }
.dark .ekip-durum-bar { border-color: #334155; }
.dark .ekip-durum-badge { background: #052e16; color: #4ade80; }

/* ── Katilimci Ozet Bar ──────────────────────────────── */
.rk-ozet {
    display: flex; align-items: center; justify-content: center; gap: 12px;
    padding: 10px 16px; border-bottom: 1px solid #f1f5f9;
}
.rk-ozet-item { display: flex; flex-direction: column; align-items: center; gap: 1px; }
.rk-ozet-sayi { font-size: 16px; font-weight: 700; color: #1e293b; }
.rk-ozet-etiket { font-size: 10px; font-weight: 500; color: #94a3b8; text-transform: uppercase; letter-spacing: 0.5px; }
.rk-ozet-ayrac { width: 1px; height: 28px; background: #e2e8f0; }

/* ── Katilimci Listesi ───────────────────────────────── */
.review-katilimci-listesi { display: flex; flex-direction: column; gap: 2px; padding: 6px 0; }
.review-katilimci-item {
    display: flex; align-items: center; gap: 10px;
    padding: 8px 16px; transition: background 0.15s;
    border-radius: 0;
}
.review-katilimci-item:hover { background: #f9fafb; }
.review-katilimci-item.rk-active { background: #eef2ff; box-shadow: inset 3px 0 0 #6366f1; }
.review-katilimci-item.rk-beklemede { opacity: 0.65; }

/* Avatar wrap — durum noktasi icin */
.rk-avatar-wrap { position: relative; flex-shrink: 0; }
.review-katilimci-avatar {
    width: 34px; height: 34px; border-radius: 50%;
    background: #6366f1; color: white; font-size: 12px; font-weight: 600;
    display: flex; align-items: center; justify-content: center;
}
.rk-durum-dot {
    position: absolute; bottom: -1px; right: -1px;
    width: 10px; height: 10px; border-radius: 50%;
    border: 2px solid white;
}
.rk-dot-aktif { background: #9ca3af; }
.rk-dot-online { background: #22c55e; box-shadow: 0 0 0 0 rgba(34,197,94,0.5); animation: rk-pulse 2s infinite; }
@keyframes rk-pulse { 0% { box-shadow: 0 0 0 0 rgba(34,197,94,0.5); } 70% { box-shadow: 0 0 0 4px rgba(34,197,94,0); } 100% { box-shadow: 0 0 0 0 rgba(34,197,94,0); } }
.rk-dot-beklemede { background: #f59e0b; }
.rk-dot-red { background: #ef4444; }

/* Bilgi */
.review-katilimci-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.rk-ad-satir { display: flex; align-items: center; gap: 6px; }
.review-katilimci-ad {
    font-size: 13px; font-weight: 600; color: #1e293b;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.rk-alt-satir { display: flex; align-items: center; gap: 6px; }
.rk-istatistik {
    display: inline-flex; align-items: center; gap: 3px;
    font-size: 11px; color: #64748b;
}
.rk-katki-yok { font-size: 11px; color: #cbd5e1; font-style: italic; }
.rk-durum-metin { font-size: 11px; font-weight: 500; }
.status-kabul { color: #16a34a; }
.status-beklemede { color: #ca8a04; }
.status-red { color: #dc2626; }

.review-rol-badge {
    font-size: 10px; font-weight: 600; padding: 1px 6px;
    border-radius: 10px; white-space: nowrap; flex-shrink: 0;
}
.rol-sahip { background: #fef3c7; color: #92400e; }
.rol-hakem { background: #dbeafe; color: #1e40af; }
.rol-editor { background: #d1fae5; color: #065f46; }
.rol-izleyici { background: #f1f5f9; color: #475569; }

.review-davet-btn {
    display: flex; align-items: center; gap: 6px; justify-content: center;
    width: calc(100% - 32px); margin: 8px 16px; padding: 8px;
    border: 2px dashed #cbd5e1; border-radius: 8px; background: none;
    color: #64748b; font-size: 13px; cursor: pointer; transition: all 0.15s;
}
.review-davet-btn:hover { border-color: #6366f1; color: #6366f1; }

/* Dark katilimci */
.dark .rk-ozet { border-color: #334155; }
.dark .rk-ozet-sayi { color: #f1f5f9; }
.dark .rk-ozet-ayrac { background: #334155; }
.dark .review-katilimci-item:hover { background: #334155; }
.dark .review-katilimci-item.rk-active { background: #312e81; box-shadow: inset 3px 0 0 #818cf8; }
.dark .review-katilimci-ad { color: #e2e8f0; }
.dark .rk-durum-dot { border-color: #1e293b; }
.dark .rk-istatistik { color: #94a3b8; }
.dark .rk-katki-yok { color: #475569; }
.dark .review-davet-btn { border-color: #334155; color: #94a3b8; }
.dark .review-davet-btn:hover { border-color: #818cf8; color: #818cf8; }

/* ── Context Menu ────────────────────────────────────── */
.review-ctx-btn {
    width: 28px; height: 28px; border: none; background: none;
    color: #94a3b8; cursor: pointer; border-radius: 6px;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0; transition: all 0.15s;
}
.review-ctx-btn:hover { background: #f1f5f9; color: #475569; }

.review-ctx-menu {
    position: fixed; z-index: 10000;
    background: white; border-radius: 10px; padding: 6px;
    min-width: 180px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.12), 0 0 0 1px rgba(0,0,0,0.04);
    animation: ctxFadeIn 0.12s ease;
}
@keyframes ctxFadeIn {
    from { opacity: 0; transform: translateY(-4px); }
    to { opacity: 1; transform: translateY(0); }
}
.review-ctx-label {
    font-size: 11px; font-weight: 600; color: #94a3b8;
    text-transform: uppercase; letter-spacing: 0.5px;
    padding: 6px 10px 4px;
}
.review-ctx-item {
    display: flex; align-items: center; gap: 8px;
    width: 100%; padding: 7px 10px; border: none; background: none;
    font-size: 13px; color: #374151; cursor: pointer;
    border-radius: 6px; transition: background 0.1s; text-align: left;
}
.review-ctx-item:hover { background: #f1f5f9; }
.review-ctx-active { color: #6366f1; font-weight: 500; }
.review-ctx-danger { color: #dc2626; }
.review-ctx-danger:hover { background: #fee2e2; }
.review-ctx-divider { height: 1px; background: #f1f5f9; margin: 4px 6px; }
.review-ctx-section { display: flex; flex-direction: column; }

/* Dark context menu */
.dark .review-ctx-btn:hover { background: #334155; color: #e2e8f0; }
.dark .review-ctx-menu { background: #1e293b; box-shadow: 0 4px 20px rgba(0,0,0,0.3), 0 0 0 1px rgba(255,255,255,0.06); }
.dark .review-ctx-label { color: #64748b; }
.dark .review-ctx-item { color: #e2e8f0; }
.dark .review-ctx-item:hover { background: #334155; }
.dark .review-ctx-divider { background: #334155; }
.dark .review-ctx-danger:hover { background: #450a0a; }

/* ── Davet Modal (site.css modal-overlay kullanir) ───── */
/* Davet modal artik site.css'deki .modal-overlay/.modal-container kullanir.
   Ek stiller asagida: */
.davet-rol-active { border: 2px solid #6366f1 !important; background: #eef2ff !important; }
.dark .davet-rol-active { background: #312e81 !important; }
.dark .davet-rol-btn { background: #0f172a !important; border-color: #334155 !important; color: #e2e8f0; }

/* ── Team Fullscreen ─────────────────────────────────── */
#teamView.team-fullscreen {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    z-index: 9999; background: #f9fafb;
    display: flex !important; flex-direction: column;
    padding: 0; margin: 0; overflow: hidden;
}
#teamView.team-fullscreen .docx-toolbar {
    border-radius: 0; border-left: none; border-right: none; border-top: none;
    flex-shrink: 0;
}
#teamView.team-fullscreen .docx-main {
    flex: 1; height: 100% !important; border-radius: 0; border: none;
}
body.team-fullscreen-active { overflow: hidden !important; }

.team-fs-enter { display: inline; }
.team-fs-exit { display: none; }
#teamView.team-fullscreen .team-fs-enter { display: none; }
#teamView.team-fullscreen .team-fs-exit { display: inline !important; }

.dark #teamView.team-fullscreen { background: #0f172a; }

/* ── Davet Sayfasi — yatay grid ────────────────────── */
.dv-grid {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 36px;
    align-items: start;
}
@media (max-width: 768px) {
    .dv-grid { grid-template-columns: 1fr; }
}

/* Sol: Bilgi */
.dv-info { display: flex; flex-direction: column; gap: 20px; justify-content: center; }
.dv-info-header { display: flex; align-items: center; gap: 16px; }
.dv-icon-box {
    width: 56px; height: 56px; flex-shrink: 0;
    background: var(--color-primary-100, #D5EECC);
    border-radius: 16px;
    display: flex; align-items: center; justify-content: center;
}
.dv-info-title { font-size: 19px; font-weight: 700; color: #1e293b; margin: 0 0 3px; }
.dv-info-desc { font-size: 15px; color: #64748b; line-height: 1.7; margin: 0; }

.dv-checklist { display: flex; flex-direction: column; gap: 10px; }
.dv-check-item {
    display: flex; align-items: center; gap: 10px;
    font-size: 14px; color: #334155;
}

.dv-notice {
    display: flex; align-items: flex-start; gap: 8px;
    padding: 10px 12px;
    background: #fffbeb; border: 1px solid #fde68a; border-radius: 10px;
    font-size: 13px; color: #92400e; line-height: 1.5;
}

/* Sag: Detay karti */
.dv-actions { display: flex; flex-direction: column; }
.dv-detail-card {
    background: var(--color-background-secondary, #f8fafc);
    border: 1px solid var(--border-light, #e2e8f0);
    border-radius: 14px;
    padding: 24px;
}
.dv-detail-title {
    display: flex; align-items: center; gap: 8px;
    font-size: 14px; font-weight: 700; color: #475569;
    letter-spacing: 0.03em;
    margin-bottom: 18px;
}
.dv-detail-row {
    display: flex; align-items: center; justify-content: space-between;
    padding: 10px 0;
}
.dv-detail-label {
    font-size: 14px; color: #94a3b8; font-weight: 500;
}
.dv-detail-value {
    font-size: 15px; font-weight: 600; color: #1e293b;
    max-width: 220px;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.dv-detail-value[title] { cursor: help; }
.dv-detail-divider {
    height: 1px; background: var(--border-light, #e2e8f0); margin: 2px 0;
}

.dv-btn-group {
    display: flex; gap: 8px; margin-top: 20px;
}
.dv-btn-group .btn {
    flex: 0 0 auto;
    font-size: 13px; padding: 8px 16px;
}

/* Status ikonlari */
.dv-status-icon {
    width: 56px; height: 56px; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    margin-bottom: 20px;
}
.dv-status-error { background: #fef2f2; }
.dv-status-success { background: #f0fdf4; }
.dv-status-warn { background: #fffbeb; }

/* Dark mode — davet sayfasi */
.dark .dv-info-title { color: #f1f5f9; }
.dark .dv-info-desc { color: #94a3b8; }
.dark .dv-check-item { color: #cbd5e1; }
.dark .dv-detail-card { background: var(--color-background-secondary, #1e293b); border-color: var(--border-light, #334155); }
.dark .dv-detail-label { color: #64748b; }
.dark .dv-detail-value { color: #f1f5f9; }
.dark .dv-detail-title { color: #94a3b8; }
.dark .dv-notice { background: #422006; border-color: #854d0e; color: #fbbf24; }

.dv-grid-center { align-items: center; }

/* ── Ödeme Sonuç Sayfası ────────────────────────────── */
.os-wrapper {
    display: flex; align-items: center; justify-content: center;
    padding: 40px 16px; min-height: calc(100vh - 80px);
}
.os-card { max-width: 960px; width: 100%; }
.os-card-body { padding: 36px 32px; }
.os-loading { text-align: center; padding: 40px 0; }
.os-loading-icon {
    background: #eef2ff; margin: 0 auto 20px;
}
.os-loading-title {
    font-size: 18px; font-weight: 700; color: #1e293b; margin: 0 0 8px;
}
.os-loading-desc {
    font-size: 14px; color: #64748b; line-height: 1.6; margin: 0;
}
.os-subtitle {
    font-size: 13px; color: #64748b; margin: 0;
}
.os-siparis-no {
    font-family: monospace; font-size: 13px;
}
.os-durum-badge {
    font-size: 13px; font-weight: 600; color: #16a34a;
    background: #f0fdf4; padding: 3px 10px; border-radius: 6px;
}
.os-tarih { font-size: 14px; }
.os-fail-icon-wrap {
    width: 64px; height: 64px; border-radius: 50%; background: #fef2f2;
    display: inline-flex; align-items: center; justify-content: center;
    margin: 0 auto 16px;
}
.os-fail-guide {
    font-size: 14px; color: #64748b; margin: 0 0 20px; line-height: 1.6;
}
.os-pending-spinner-wrap {
    text-align: center; padding: 20px 0;
}
.os-pending-spinner {
    width: 48px; height: 48px; border-radius: 50%; background: #fffbeb;
    display: inline-flex; align-items: center; justify-content: center;
    margin: 0 auto 12px;
}
.os-pending-wait {
    font-size: 14px; color: #64748b; margin: 0; line-height: 1.6;
}
.os-check-muted { color: #94a3b8; }
.os-center { text-align: center; }
.os-btn-center { justify-content: center; }
.os-btn-flex1 { flex: 1; }

/* Sonraki adımlar kutusu */
.os-next-steps {
    margin-top: 16px; background: #f0fdf4;
    border: 1px solid #bbf7d0; border-radius: 14px; padding: 20px 24px;
}
.os-next-header {
    display: flex; align-items: center; gap: 8px; margin-bottom: 14px;
}
.os-next-title {
    font-size: 14px; font-weight: 700; color: #15803d;
}
.os-next-list {
    display: flex; flex-direction: column; gap: 10px;
}
.os-next-item {
    display: flex; align-items: center; gap: 10px;
    padding: 10px 14px; background: white;
    border: 1px solid #e2e8f0; border-radius: 10px;
    text-decoration: none; transition: all 0.15s; color: inherit;
}
.os-next-item:hover {
    border-color: #22c55e;
    box-shadow: 0 2px 8px rgba(34,197,94,0.1);
}
.os-next-icon {
    width: 36px; height: 36px; border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.os-next-icon-upload { background: #f0fdf4; }
.os-next-icon-library { background: #eff6ff; }
.os-next-icon-credits { background: #fef3c7; }
.os-next-item-title {
    font-size: 13px; font-weight: 600; color: #1e293b;
}
.os-next-item-desc {
    font-size: 12px; color: #64748b;
}
.os-next-arrow {
    flex-shrink: 0; margin-left: auto;
}

/* Dark — odeme sonuc */
.dark .os-loading-title { color: #f1f5f9; }
.dark .os-loading-desc { color: #94a3b8; }
.dark .os-loading-icon { background: #1e1b4b; }
.dark .os-subtitle { color: #94a3b8; }
.dark .os-durum-badge { background: #052e16; color: #4ade80; }
.dark .os-fail-icon-wrap { background: #450a0a; }
.dark .os-fail-guide { color: #94a3b8; }
.dark .os-pending-spinner { background: #422006; }
.dark .os-pending-wait { color: #94a3b8; }
.dark .os-next-steps { background: #052e16; border-color: #14532d; }
.dark .os-next-title { color: #4ade80; }
.dark .os-next-item { background: #1e293b; border-color: #334155; }
.dark .os-next-item:hover { border-color: #22c55e; box-shadow: 0 2px 8px rgba(34,197,94,0.05); }
.dark .os-next-item-title { color: #f1f5f9; }
.dark .os-next-item-desc { color: #94a3b8; }

/* ── Responsive ──────────────────────────────────────── */
@media (max-width: 767px) {
    .review-modal-content { width: 95%; padding: 16px; }
    .review-katilimci-aksiyonlar { flex-direction: column; gap: 4px; }
    .review-cikar-btn, .review-rol-select { min-height: 44px; min-width: 44px; }
    .review-davet-btn { min-height: 44px; }

    .ekip-panel {
        width: 100%; border-left: none; border-top: 1px solid #e5e7eb;
        max-height: 300px;
    }

    #bildirimDropdown { width: calc(100vw - 20px); right: -60px; }
}
