/* ============================================================
   Art of Living — Gurudev's Knowledge Platform
   Generous, spacious design with AOL brand colors
   ============================================================ */

/* ── Reset ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
    font-family: 'Open Sans', sans-serif;
    font-weight: 400;
    background: #F5F1FA;
    color: #2D1B4E;
    line-height: 1.65;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

a { color: #5F259F; text-decoration: none; transition: color 0.2s; }
a:hover { color: #7677F4; }
img { max-width: 100%; display: block; }

/* ── Variables ─────────────────────────────────────────────── */
:root {
    --purple:       #5F259F;
    --purple-light: #7677F4;
    --purple-dark:  #4A1D7A;
    --purple-faint: #F0EBF9;
    --white:        #FFFFFF;
    --off-white:    #F5F1FA;
    --surface:      #FFFFFF;
    --border:       #E4DAF0;
    --border-light: #EDE6F5;
    --text:         #2D1B4E;
    --text-sec:     #5A4E72;
    --text-muted:   #9187A8;
    --success:      #27AE60;
    --danger:       #E74C3C;
    --warning:      #F39C12;
    --radius:       16px;
    --radius-sm:    10px;
    --radius-xs:    6px;
    --shadow:       0 6px 32px rgba(95, 37, 159, 0.10);
    --shadow-hover: 0 12px 48px rgba(95, 37, 159, 0.18);
    --shadow-sm:    0 2px 12px rgba(95, 37, 159, 0.07);
}

/* ── Layout ────────────────────────────────────────────────── */
.container {
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 32px;
}

.container-narrow {
    max-width: 480px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 80px);
}

/* ── Navigation ────────────────────────────────────────────── */
.nav {
    background: var(--white);
    border-bottom: 1px solid var(--border-light);
    box-shadow: 0 1px 12px rgba(95, 37, 159, 0.05);
    position: sticky;
    top: 0;
    z-index: 100;
    padding: 0 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 80px;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 14px;
    text-decoration: none;
    color: var(--purple);
    font-weight: 700;
    font-size: 1.15rem;
    letter-spacing: -0.02em;
    cursor: pointer;
}

.nav-brand:hover { text-decoration: none; color: var(--purple); }

.nav-logo {
    height: 44px;
    width: auto;
    flex-shrink: 0;
}

.nav-divider {
    width: 1.5px;
    height: 32px;
    background: var(--border);
    flex-shrink: 0;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-link {
    display: inline-flex;
    align-items: center;
    padding: 10px 18px;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-sec);
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}

.nav-link:hover {
    background: var(--purple-faint);
    color: var(--purple);
    text-decoration: none;
}

.nav-user {
    color: var(--text);
    font-weight: 600;
}

.nav-logout {
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* ── Page Header (gradient banner) ─────────────────────────── */
.page-header {
    background: linear-gradient(135deg, var(--purple-dark) 0%, var(--purple) 50%, var(--purple-light) 100%);
    color: var(--white);
    padding: 72px 32px 64px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 70% 20%, rgba(255,255,255,0.08) 0%, transparent 60%);
    pointer-events: none;
}

.page-header h1 {
    font-size: 2.6rem;
    font-weight: 700;
    margin-bottom: 14px;
    letter-spacing: -0.03em;
    position: relative;
    line-height: 1.2;
}

.page-header p {
    font-size: 1.15rem;
    font-weight: 300;
    opacity: 0.85;
    max-width: 520px;
    margin: 0 auto;
    position: relative;
    line-height: 1.6;
}

/* ── Back Link ─────────────────────────────────────────────── */
.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--text-sec);
    font-size: 0.9rem;
    font-weight: 500;
    padding: 16px 0;
    margin-bottom: 4px;
    cursor: pointer;
    transition: color 0.2s;
}

.back-link:hover { color: var(--purple); text-decoration: none; }

/* ── Buttons ───────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: var(--radius);
    font-family: 'Open Sans', sans-serif;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.25s ease;
    text-decoration: none;
    white-space: nowrap;
    background: var(--white);
    color: var(--text-sec);
    border-color: var(--border);
}

.btn:hover {
    background: var(--purple-faint);
    color: var(--purple);
    border-color: var(--purple-light);
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
}

.btn.active {
    background: var(--purple);
    color: var(--white);
    border-color: var(--purple);
    box-shadow: 0 4px 18px rgba(95, 37, 159, 0.3);
}

.btn.active:hover {
    background: var(--purple-dark);
    border-color: var(--purple-dark);
}

.btn-primary {
    background: var(--purple);
    color: var(--white);
    border-color: var(--purple);
    box-shadow: 0 4px 18px rgba(95, 37, 159, 0.25);
    padding: 14px 28px;
    font-size: 0.95rem;
}

.btn-primary:hover {
    background: var(--purple-dark);
    border-color: var(--purple-dark);
    color: var(--white);
    box-shadow: 0 6px 24px rgba(95, 37, 159, 0.35);
    transform: translateY(-2px);
}

.btn-danger {
    background: #FEF2F2;
    color: var(--danger);
    border-color: #FECACA;
}

.btn-danger:hover {
    background: var(--danger);
    color: var(--white);
    border-color: var(--danger);
}

.btn-success {
    background: #F0FDF4;
    color: var(--success);
    border-color: #BBF7D0;
}

.btn-success:hover {
    background: var(--success);
    color: var(--white);
    border-color: var(--success);
}

.btn-small {
    padding: 8px 16px;
    font-size: 0.82rem;
    border-radius: var(--radius-sm);
}

/* ── Alerts ────────────────────────────────────────────────── */
.alert {
    padding: 16px 20px;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 20px;
    border: 1px solid transparent;
}

.alert-error {
    background: #FEF2F2;
    color: #B91C1C;
    border-color: #FECACA;
}

.alert-success {
    background: #F0FDF4;
    color: #166534;
    border-color: #BBF7D0;
}

.alert-info {
    background: #EFF6FF;
    color: #1E40AF;
    border-color: #BFDBFE;
}

/* ── Loading Spinner ───────────────────────────────────────── */
.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 120px 24px;
    color: var(--text-muted);
    font-size: 1rem;
    gap: 20px;
}

.loading::before {
    content: '';
    width: 44px;
    height: 44px;
    border: 3px solid var(--border);
    border-top-color: var(--purple);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ── Form Card (Login/Register) ────────────────────────────── */
.form-card {
    width: 100%;
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 52px 44px;
    border: 1px solid var(--border-light);
}

.form-logo {
    text-align: center;
    margin-bottom: 32px;
}

.form-logo img {
    height: 52px;
    width: auto;
    margin: 0 auto;
}

.form-card h2 {
    font-size: 1.65rem;
    font-weight: 700;
    color: var(--text);
    text-align: center;
    margin-bottom: 6px;
    letter-spacing: -0.02em;
}

.form-subtitle {
    text-align: center;
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-bottom: 36px;
}

.form-group {
    margin-bottom: 22px;
}

.form-group label {
    display: block;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-sec);
    margin-bottom: 8px;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: 'Open Sans', sans-serif;
    font-size: 1rem;
    color: var(--text);
    background: var(--white);
    transition: border-color 0.2s, box-shadow 0.2s;
    outline: none;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--purple);
    box-shadow: 0 0 0 4px rgba(95, 37, 159, 0.08);
}

.form-footer {
    margin-top: 24px;
    text-align: center;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.form-footer a { color: var(--purple); font-weight: 600; }
.form-footer a:hover { text-decoration: underline; }

/* ── Series Grid (Library) ─────────────────────────────────── */
.series-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 32px;
    padding: 56px 0 72px;
}

.series-card {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-light);
    padding: 40px 36px 36px;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
}

.series-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, var(--purple) 0%, var(--purple-light) 100%);
    opacity: 0;
    transition: opacity 0.3s;
}

.series-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-hover);
}

.series-card:hover::before {
    opacity: 1;
}

.series-card h2 {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 14px;
    letter-spacing: -0.02em;
    line-height: 1.35;
}

.series-card p {
    font-size: 0.95rem;
    color: var(--text-sec);
    line-height: 1.7;
    margin-bottom: 24px;
}

.episode-count {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--purple);
    background: var(--purple-faint);
    padding: 8px 18px;
    border-radius: 24px;
    border: 1px solid var(--border-light);
}

.episode-count::before {
    content: '\25B6';
    font-size: 0.65rem;
}

/* ── Episode List ──────────────────────────────────────────── */
.episode-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 40px 0 60px;
}

.episode-item {
    display: flex;
    align-items: center;
    gap: 20px;
    background: var(--white);
    border: 1.5px solid var(--border-light);
    border-radius: var(--radius);
    padding: 22px 28px;
    cursor: pointer;
    transition: all 0.25s ease;
}

.episode-item:hover {
    background: var(--purple-faint);
    border-color: var(--purple-light);
    box-shadow: var(--shadow-sm);
    transform: translateX(4px);
}

.episode-num {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    background: var(--purple-faint);
    color: var(--purple);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 700;
    border: 2px solid var(--border);
    transition: all 0.25s;
}

.episode-item:hover .episode-num {
    background: var(--purple);
    color: var(--white);
    border-color: var(--purple);
}

.episode-title {
    flex: 1;
    font-size: 1.05rem;
    font-weight: 500;
    color: var(--text);
    line-height: 1.45;
}

.episode-badges {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.badge {
    display: inline-flex;
    align-items: center;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    background: var(--purple-faint);
    color: var(--text-muted);
    border: 1px solid var(--border);
}

.badge.active {
    background: var(--purple);
    color: var(--white);
    border-color: var(--purple);
}

/* ── Player Page ───────────────────────────────────────────── */
.player-container {
    max-width: 1060px;
    margin: 0 auto;
    padding: 32px 32px 72px;
}

.player-title {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 28px;
    letter-spacing: -0.02em;
    line-height: 1.35;
}

.player-wrapper {
    position: relative;
    background: #0A0012;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: 0 16px 64px rgba(95, 37, 159, 0.22);
    margin-bottom: 8px;
}

/* ── Subtitle Overlay ──────────────────────────────────────── */
#sub-overlay {
    position: absolute;
    bottom: 60px;
    left: 5%;
    right: 5%;
    text-align: center;
    color: #fff;
    font-family: 'Open Sans', sans-serif;
    font-size: 1.3em;
    line-height: 1.45;
    text-shadow: 1px 1px 4px rgba(0,0,0,0.9), -1px -1px 4px rgba(0,0,0,0.9);
    background: rgba(0,0,0,0.65);
    padding: 8px 18px;
    border-radius: 6px;
    pointer-events: none;
    z-index: 10;
    max-width: 88%;
    margin: 0 auto;
    backdrop-filter: blur(2px);
}

#sub-overlay:empty { display: none; }

/* Mobile: smaller font, push subtitles all the way to the bottom edge
   so they don't sit over Gurudev. */
@media (max-width: 768px) {
    #sub-overlay {
        font-size: 0.95rem;
        line-height: 1.3;
        bottom: 4px;
        left: 3%;
        right: 3%;
        max-width: 94%;
        padding: 3px 10px;
        border-radius: 4px;
        background: rgba(0,0,0,0.55);
    }
}

@media (max-width: 480px) {
    #sub-overlay {
        font-size: 0.85rem;
        line-height: 1.25;
        bottom: 2px;
        padding: 2px 8px;
    }
}

/* Tap-to-seek visual feedback (left/right edge tap → ±15s) */
#seek-flash {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.65);
    color: #fff;
    padding: 14px 22px;
    border-radius: 50px;
    font-family: 'Open Sans', sans-serif;
    font-size: 1.1rem;
    font-weight: 600;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.35s ease;
    z-index: 11;
    white-space: nowrap;
}
#seek-flash.show { opacity: 1; }
#seek-flash.left  { left: 12%; right: auto; }
#seek-flash.right { right: 12%; left: auto; }
@media (max-width: 480px) {
    #seek-flash {
        padding: 10px 16px;
        font-size: 0.95rem;
    }
}

/* Native ::cue fallback (in case the custom overlay is bypassed and
   the browser falls back to native track rendering) */
video::cue {
    font-size: 1.1em;
    background: rgba(0,0,0,0.6);
    line-height: 1.3;
}
@media (max-width: 768px) {
    video::cue { font-size: 0.85em; }
}

/* ── Controls Bar ──────────────────────────────────────────── */
.controls-bar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
    padding: 18px 24px;
    background: var(--white);
    border-radius: var(--radius);
    border: 1.5px solid var(--border-light);
    box-shadow: var(--shadow-sm);
}

/* ── Crossfader ────────────────────────────────────────────── */
.crossfader {
    margin-top: 20px;
    padding: 22px 28px;
    background: var(--white);
    border-radius: var(--radius);
    border: 1.5px solid var(--border-light);
    box-shadow: var(--shadow-sm);
}

.crossfader-label {
    display: flex;
    justify-content: space-between;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 12px;
}

.crossfader input[type="range"] {
    width: 100%;
    -webkit-appearance: none;
    appearance: none;
    height: 6px;
    border-radius: 6px;
    background: var(--border);
    outline: none;
    cursor: pointer;
}

.crossfader input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--purple);
    border: 3px solid var(--white);
    box-shadow: 0 0 0 2px var(--purple), 0 2px 10px rgba(95, 37, 159, 0.35);
    cursor: pointer;
    transition: transform 0.15s;
}

.crossfader input[type="range"]::-webkit-slider-thumb:hover {
    transform: scale(1.15);
}

.crossfader input[type="range"]::-moz-range-thumb {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--purple);
    border: 3px solid var(--white);
    box-shadow: 0 0 0 2px var(--purple), 0 2px 10px rgba(95, 37, 159, 0.35);
    cursor: pointer;
}

/* ── Download Bar ──────────────────────────────────────────── */
.download-bar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
    padding: 16px 24px;
    background: var(--off-white);
    border-radius: var(--radius);
    border: 1.5px solid var(--border-light);
}

/* ── Tabs ──────────────────────────────────────────────────── */
.tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 24px;
}

.tab {
    padding: 10px 22px;
    border-radius: var(--radius-sm) var(--radius-sm) 0 0;
    cursor: pointer;
    background: var(--off-white);
    color: var(--text-sec);
    border: 1px solid var(--border-light);
    border-bottom: none;
    font-size: 0.9rem;
    font-weight: 500;
    font-family: inherit;
}

.tab.active {
    background: var(--white);
    color: var(--purple);
    font-weight: 600;
    border-color: var(--purple-light);
}

/* ── Admin Table ───────────────────────────────────────────── */
.admin-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-light);
    overflow: hidden;
    margin-top: 24px;
    margin-bottom: 48px;
}

.admin-table thead {
    background: linear-gradient(135deg, var(--purple-dark), var(--purple));
    color: var(--white);
}

.admin-table th {
    padding: 16px 22px;
    text-align: left;
    font-weight: 600;
    font-size: 0.78rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.admin-table td {
    padding: 16px 22px;
    border-bottom: 1px solid var(--border-light);
    color: var(--text-sec);
}

.admin-table tbody tr:last-child td { border-bottom: none; }
.admin-table tbody tr:hover td { background: var(--purple-faint); }

.status-pending {
    display: inline-flex;
    padding: 5px 14px;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 600;
    background: #FFFBEB;
    color: #92400E;
    border: 1px solid #FDE68A;
}

.status-approved {
    display: inline-flex;
    padding: 5px 14px;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 600;
    background: #F0FDF4;
    color: #166534;
    border: 1px solid #BBF7D0;
}

.status-rejected {
    display: inline-flex;
    padding: 5px 14px;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 600;
    background: #FEF2F2;
    color: #991B1B;
    border: 1px solid #FECACA;
}

/* ── Subtitle Editor ───────────────────────────────────────── */
.subtitle-editor textarea {
    width: 100%;
    min-height: 450px;
    padding: 20px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: 'Fira Mono', 'Courier New', monospace;
    font-size: 0.9rem;
    color: var(--text);
    background: #FAFAFA;
    line-height: 1.7;
    resize: vertical;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.subtitle-editor textarea:focus {
    border-color: var(--purple);
    box-shadow: 0 0 0 4px rgba(95, 37, 159, 0.08);
}

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 768px) {
    .nav {
        height: 68px;
        padding: 0 20px;
    }

    .nav-logo { height: 36px; }
    .nav-divider { display: none; }

    .page-header {
        padding: 48px 20px 40px;
    }

    .page-header h1 { font-size: 1.8rem; }
    .page-header p { font-size: 1rem; }

    .series-grid {
        grid-template-columns: 1fr;
        gap: 20px;
        padding: 32px 0 48px;
    }

    .series-card { padding: 32px 28px 28px; }

    .form-card { padding: 36px 28px; }

    .player-container { padding: 20px 16px 48px; }
    .player-title { font-size: 1.3rem; }

    .episode-item {
        padding: 18px 20px;
        gap: 14px;
    }

    .episode-list { gap: 10px; padding: 28px 0 40px; }

    .controls-bar { padding: 14px 18px; }
    .crossfader { padding: 18px 20px; }

    .admin-table th, .admin-table td { padding: 12px 14px; }
}

@media (max-width: 480px) {
    .container { padding: 0 16px; }
    .episode-badges { display: none; }
    .episode-num { width: 38px; height: 38px; font-size: 0.82rem; }
    .episode-title { font-size: 0.95rem; }
    .nav-brand { font-size: 1rem; gap: 10px; }
}

/* --- Strategy page --- */
.strategy-intro {
    background: #f5efff;
    border-left: 4px solid #5F259F;
    padding: 16px 20px;
    border-radius: 8px;
    margin-bottom: 32px;
    color: #333;
}
.strategy-intro strong { color: #5F259F; }

.strategy-steps {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 40px;
}
.strategy-step {
    display: flex;
    background: #fff;
    border: 1px solid #e8e3f0;
    border-radius: 12px;
    padding: 20px 22px;
    box-shadow: 0 1px 3px rgba(95, 37, 159, 0.06);
    transition: box-shadow 0.2s, transform 0.2s;
}
.strategy-step:hover {
    box-shadow: 0 4px 12px rgba(95, 37, 159, 0.12);
    transform: translateY(-1px);
}
.strategy-step-num {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, #5F259F, #8B4FBF);
    color: #fff;
    font-size: 1.4rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 20px;
}
.strategy-step-body { flex: 1; }
.strategy-step-body h3 {
    margin: 0 0 8px 0;
    color: #5F259F;
    font-size: 1.2rem;
}
.strategy-step-body p {
    margin: 0 0 12px 0;
    color: #444;
    line-height: 1.55;
}
.strategy-gate {
    display: inline-block;
    padding: 4px 12px;
    background: #e8f5e9;
    color: #2e7d32;
    font-size: 0.85rem;
    font-weight: 600;
    border-radius: 12px;
    border: 1px solid #c8e6c9;
}
.strategy-gate-none {
    background: #f5f5f5;
    color: #757575;
    border-color: #e0e0e0;
}

.strategy-rollback, .strategy-scope {
    background: #fafafa;
    border: 1px solid #eee;
    border-radius: 12px;
    padding: 20px 24px;
    margin-bottom: 24px;
}
.strategy-rollback h3, .strategy-scope h3 {
    color: #5F259F;
    margin: 0 0 12px 0;
    font-size: 1.1rem;
}
.strategy-rollback pre {
    background: #2d1b47;
    color: #f5efff;
    padding: 14px 18px;
    border-radius: 8px;
    font-size: 0.9rem;
    overflow-x: auto;
    margin: 0;
}
.strategy-scope ul {
    margin: 0;
    padding-left: 20px;
    line-height: 1.9;
    color: #444;
}

@media (max-width: 600px) {
    .strategy-step { flex-direction: column; }
    .strategy-step-num { margin: 0 0 12px 0; }
}

/* --- Suggestion box (viewer side) --- */
.suggestion-box {
    margin-top: 36px;
    padding: 24px;
    background: #fff;
    border: 1px solid #e8e3f0;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(95, 37, 159, 0.06);
}
.suggestion-box h3 {
    margin: 0 0 8px 0;
    color: #5F259F;
    font-size: 1.2rem;
}
.suggestion-hint {
    color: #666;
    font-size: 0.9rem;
    margin: 0 0 16px 0;
}
.suggestion-tabs {
    display: flex;
    gap: 4px;
    border-bottom: 1px solid #e8e3f0;
    margin-bottom: 16px;
}
.suggestion-tab {
    background: transparent;
    border: none;
    padding: 10px 16px;
    cursor: pointer;
    color: #666;
    font-size: 0.95rem;
    font-weight: 500;
    border-bottom: 2px solid transparent;
    font-family: inherit;
}
.suggestion-tab.active {
    color: #5F259F;
    border-bottom-color: #5F259F;
}
.suggestion-panel { display: none; }
.suggestion-panel.active { display: block; }
.suggestion-panel textarea,
.suggestion-panel input[type="text"] {
    width: 100%;
    padding: 12px;
    border: 1px solid #e0d8ec;
    border-radius: 8px;
    font-family: inherit;
    font-size: 0.95rem;
    margin-bottom: 12px;
    box-sizing: border-box;
}
.suggestion-panel textarea:focus,
.suggestion-panel input:focus {
    outline: none;
    border-color: #5F259F;
}
.suggestion-cue-capture {
    padding: 14px 16px;
    background: #f5efff;
    border: 1px dashed #c9b3e8;
    border-radius: 8px;
    margin-bottom: 12px;
    font-size: 0.9rem;
}
.suggestion-cue-capture.suggestion-cue-empty {
    color: #999;
    font-style: italic;
    text-align: center;
}
.sug-cue-meta {
    font-size: 0.8rem;
    color: #5F259F;
    margin-bottom: 4px;
    font-weight: 600;
}
.sug-cue-text { color: #333; }
.suggestion-result {
    margin-top: 12px;
    padding: 10px 14px;
    border-radius: 6px;
    font-size: 0.9rem;
    min-height: 1px;
}
.suggestion-result.success {
    background: #e8f5e9;
    color: #2e7d32;
    border: 1px solid #c8e6c9;
}
.suggestion-result.error {
    background: #ffebee;
    color: #c62828;
    border: 1px solid #ffcdd2;
}

/* --- Nav badge --- */
.nav-badge {
    display: inline-block;
    background: #c62828;
    color: #fff;
    border-radius: 10px;
    min-width: 18px;
    padding: 0 6px;
    font-size: 0.72rem;
    font-weight: 700;
    margin-left: 6px;
    line-height: 18px;
    text-align: center;
    vertical-align: middle;
}

/* --- Admin: suggestions list --- */
.sug-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.sug-row {
    background: #fff;
    border: 1px solid #e8e3f0;
    border-left: 4px solid #ffa726;
    border-radius: 10px;
    padding: 16px 20px;
}
.sug-row-approved { border-left-color: #4caf50; opacity: 0.7; }
.sug-row-rejected { border-left-color: #bdbdbd; opacity: 0.6; }
.sug-row-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}
.sug-status {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 10px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}
.sug-status-pending { background: #fff3e0; color: #e65100; }
.sug-status-approved { background: #e8f5e9; color: #2e7d32; }
.sug-status-rejected { background: #f5f5f5; color: #757575; }
.sug-meta { flex: 1; font-size: 0.9rem; color: #444; }
.sug-date { color: #999; font-size: 0.82rem; }
.sug-row-body { margin-bottom: 12px; color: #333; line-height: 1.55; }
.sug-cue-old {
    background: #fafafa;
    padding: 10px 14px;
    border-radius: 6px;
    border-left: 3px solid #bdbdbd;
    margin-bottom: 6px;
    font-size: 0.9rem;
}
.sug-cue-new {
    background: #e8f5e9;
    padding: 10px 14px;
    border-radius: 6px;
    border-left: 3px solid #4caf50;
    color: #1b5e20;
    font-weight: 500;
}
.sug-general { white-space: pre-wrap; }
.sug-row-actions { display: flex; gap: 8px; }
.sug-reviewed { color: #999; font-size: 0.85rem; font-style: italic; }
.sug-filter-tabs { display: flex; gap: 4px; margin: 16px 0 20px; border-bottom: 1px solid #e0e0e0; }
.sug-filter-tab {
    background: transparent; border: 0; border-bottom: 2px solid transparent;
    padding: 10px 16px; cursor: pointer; font-size: 0.95rem; color: #666;
    font-family: inherit; display: inline-flex; align-items: center; gap: 6px;
}
.sug-filter-tab:hover { color: #5F259F; }
.sug-filter-tab.active { color: #5F259F; border-bottom-color: #5F259F; font-weight: 600; }
.sug-filter-count {
    background: #eee; color: #555; border-radius: 10px; padding: 1px 8px;
    font-size: 0.8rem; min-width: 20px; text-align: center;
}
.sug-filter-tab.active .sug-filter-count { background: #5F259F; color: #fff; }
.sug-empty { padding: 40px; text-align: center; color: #999; font-style: italic; }
.sug-review-note { margin-top: 8px; padding: 8px 10px; background: #fff8e1; border-left: 3px solid #ffb300; font-size: 0.88rem; color: #6d4c00; }
