/* ===================================================
   Naba Cookie Consent Bar
   =================================================== */

.naba-cookie-bar {
    position: fixed;
    bottom: 0;
    right: 0;
    left: 0;
    z-index: 99999;
    background: #0b2733;
    color: #fff;
    padding: 14px 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
    font-size: 14px;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, .15);
}

.naba-cookie-text a {
    color: #7fd1ff;
    text-decoration: underline;
    margin-right: 4px;
}

.naba-cookie-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.naba-cookie-btn {
    border-radius: 50px;
    padding: 8px 20px;
    font-weight: 700;
    cursor: pointer;
    border: 1px solid #fff;
}

.naba-cookie-btn-solid {
    background: var(--naba-primary-color, #0b3d51);
    color: #fff;
}

.naba-cookie-btn-ghost {
    background: transparent;
    color: #fff;
}

@media (max-width: 600px) {
    .naba-cookie-bar {
        flex-direction: column;
        text-align: center;
    }
}

/* ===================================================
   نافذة تخصيص تفضيلات الكوكيز (مودال) — تظهر من أي صفحة
   بعد الضغط على زرار "تخصيص" في الشريط، أو زرار "إدارة
   الموافقة" في صفحة سياسة الكوكيز نفسها
   =================================================== */
.naba-cookie-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 100000;
    background: rgba(15, 23, 42, .55);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}
.naba-cookie-modal {
    background: #fff;
    color: #1a1a1a;
    border-radius: 16px;
    width: 100%;
    max-width: 520px;
    max-height: 88vh;
    overflow-y: auto;
    direction: rtl;
    text-align: right;
    box-shadow: 0 10px 40px rgba(0,0,0,.25);
}
.naba-cookie-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 22px;
    border-bottom: 1px solid #eee;
}
.naba-cookie-modal-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 800;
    color: var(--naba-primary-color, #0b3d51);
}
.naba-cookie-modal-close {
    background: none;
    border: none;
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
    color: #64748B;
}
.naba-cookie-modal .cookies-panel { margin: 14px 18px; }
.naba-cookie-modal-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    padding: 14px 22px 20px;
    border-top: 1px solid #eee;
}
.naba-cookie-modal-link {
    font-size: 13px;
    color: var(--naba-primary-color, #0b3d51);
    text-decoration: underline;
}

/* ===================================================
   عناصر لوحة الفئات والسلايدرز — مشتركة بين نافذة التخصيص
   وصفحة "سياسة الكوكيز" نفسها، عشان تشتغل بنفس الشكل والسلوك
   في المكانين من غير تكرار كود
   =================================================== */
.cookies-panel {
    background: var(--naba-content-bg, #eaedf0);
    border-radius: 12px;
    padding: 8px 20px;
}
.cookie-row {
    padding: 14px 4px;
    border-bottom: 1px solid rgba(0,0,0,0.08);
}
.cookie-row:last-child { border-bottom: none; }
.cookie-row-text { flex: 1; }
.cookie-row-text h4 {
    margin: 0;
    font-size: 15.5px;
    font-weight: 700;
    color: var(--naba-primary-color, #0b3d51);
    display: flex;
    align-items: center;
    flex-wrap: wrap;
}
.cookie-row-badge {
    font-size: 11px;
    font-weight: 700;
    color: #059669;
    background: #d1fae5;
    padding: 2px 8px;
    border-radius: 20px;
    margin-inline-start: 8px;
}
.cookie-row-badge.is-upcoming {
    color: #92400e;
    background: #fde68a;
}

/* ---- Accordion ---- */
.cookie-row-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    cursor: pointer;
    user-select: none;
}
.cookie-row-chevron {
    display: inline-block;
    margin-inline-start: 6px;
    font-size: 12px;
    color: #94a3b8;
    transition: transform .2s;
}
.cookie-row.is-open .cookie-row-chevron { transform: rotate(180deg); }
.cookie-row-details {
    max-height: 0;
    overflow: hidden;
    transition: max-height .25s ease;
}
.cookie-row.is-open .cookie-row-details { max-height: 240px; }
.cookie-row-details p {
    margin: 10px 0 4px;
    font-size: 13px;
    color: #475569;
    line-height: 1.8;
}
.cookie-row input:disabled ~ .cookie-row-details,
.naba-toggle input:disabled {
    cursor: not-allowed;
}

/* مفتاح التبديل (Toggle Slider) */
.naba-toggle {
    position: relative;
    display: inline-block;
    width: 46px;
    height: 26px;
    flex-shrink: 0;
}
.naba-toggle input { opacity: 0; width: 0; height: 0; }
.naba-toggle .slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background-color: #cbd5e1;
    border-radius: 30px;
    transition: .25s;
}
.naba-toggle .slider::before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    right: 3px;
    bottom: 3px;
    background-color: #fff;
    border-radius: 50%;
    transition: .25s;
    box-shadow: 0 1px 3px rgba(0,0,0,.3);
}
.naba-toggle input:checked + .slider { background-color: var(--naba-secondary-color, #2A8FAF); }
.naba-toggle input:checked + .slider::before { transform: translateX(-20px); }
.naba-toggle input:disabled + .slider { cursor: not-allowed; opacity: .75; }
.naba-toggle input:disabled + .slider::before { background: #f1f5f9; }

.cookies-panel-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    padding: 16px 4px 12px;
}

/* ===================================================
   Placeholder لأي Embed (يوتيوب/فيسبوك/تويتر...) قبل الموافقة
   =================================================== */

.naba-embed-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 40px 20px;
    background: #f1f5f9;
    border-radius: 12px;
    text-align: center;
    min-height: 200px;
}

.naba-embed-placeholder button {
    background: var(--naba-primary-color, #0b3d51);
    color: #fff;
    border: none;
    padding: 8px 20px;
    border-radius: 50px;
    font-weight: 700;
    cursor: pointer;
}
