/* =============================================
   CRYPGUARD GENESIS - LIVE DEMO / TEST SUITE
   Hidden page for security testing scenarios
   ============================================= */

/* === BACKGROUND EFFECTS === */
.demo-bg-grid {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
    background:
        radial-gradient(ellipse at 20% 50%, rgba(0, 217, 255, 0.04) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 20%, rgba(188, 19, 254, 0.03) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 80%, rgba(0, 255, 170, 0.02) 0%, transparent 50%);
}

.demo-bg-grid::before,
.demo-bg-grid::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.demo-bg-grid::before {
    background:
        radial-gradient(ellipse at 70% 30%, rgba(0, 255, 170, 0.04) 0%, transparent 50%),
        radial-gradient(ellipse at 30% 80%, rgba(0, 217, 255, 0.03) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 70%, rgba(188, 19, 254, 0.02) 0%, transparent 50%);
    opacity: 1;
}

.demo-bg-grid::after {
    background:
        radial-gradient(ellipse at 50% 20%, rgba(188, 19, 254, 0.03) 0%, transparent 50%),
        radial-gradient(ellipse at 10% 60%, rgba(0, 255, 170, 0.03) 0%, transparent 50%),
        radial-gradient(ellipse at 90% 50%, rgba(0, 217, 255, 0.04) 0%, transparent 50%);
    opacity: 1;
}

/* Scanline removed — was distracting while reading */
.demo-bg-scanline { display: none; }

/* === PAGE HEADER === */
.demo-header {
    text-align: center;
    padding: 8rem 1.5rem 2.5rem;
    position: relative;
    z-index: 1;
    overflow: hidden;
}

.demo-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 10%;
    right: 10%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(0, 217, 255, 0.3), transparent);
}

.demo-header-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-family: 'Orbitron', sans-serif;
    font-size: var(--fs-xs);
    letter-spacing: 3px;
    color: var(--accent-purple);
    background: rgba(188, 19, 254, 0.08);
    border: 1px solid rgba(188, 19, 254, 0.35);
    border-radius: var(--radius-full);
    padding: 0.5rem 1.5rem;
    margin-bottom: 1.5rem;
    animation: badgePulse 3s ease-in-out infinite;
    will-change: box-shadow;
    transform: translateZ(0);
}

.badge-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent-purple);
    animation: dotBlink 1.5s ease-in-out infinite;
    will-change: opacity;
    transform: translateZ(0);
}

@keyframes dotBlink {
    0%, 100% { opacity: 1; box-shadow: 0 0 6px var(--accent-purple); }
    50% { opacity: 0.3; box-shadow: none; }
}

@keyframes badgePulse {
    0%, 100% { box-shadow: 0 0 10px rgba(188, 19, 254, 0.15); }
    50% { box-shadow: 0 0 30px rgba(188, 19, 254, 0.35); }
}

.demo-header h1 {
    font-family: 'Orbitron', sans-serif;
    font-size: var(--fs-3xl);
    color: var(--text-primary);
    margin-bottom: 1rem;
    letter-spacing: 4px;
    line-height: 1.15;
    background: linear-gradient(135deg, #fff 0%, var(--accent-cyan) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.demo-tagline {
    font-size: var(--fs-lg);
    color: var(--accent-cyan);
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.demo-subtitle {
    font-size: var(--fs-base);
    color: var(--text-secondary);
    max-width: 620px;
    margin: 0 auto 1.5rem;
    line-height: 1.7;
}

.demo-desktop-tag {
    display: inline-block;
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-full);
    padding: 0.35rem 1.25rem;
    margin-bottom: 2.5rem;
}

/* === TERMINAL WIDGET === */
.terminal-widget {
    max-width: 520px;
    margin: 0 auto;
    border-radius: var(--radius-sm);
    overflow: hidden;
    border: 1px solid rgba(0, 217, 255, 0.2);
    box-shadow:
        0 0 30px rgba(0, 217, 255, 0.08),
        0 20px 60px rgba(0, 0, 0, 0.4);
    text-align: left;
}

.terminal-bar {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.6rem 1rem;
    background: rgba(0, 0, 0, 0.6);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.terminal-dots { display: flex; gap: 6px; }

.tdot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.tdot-r { background: #ff5f57; }
.tdot-y { background: #febc2e; }
.tdot-g { background: #28c840; }

.terminal-title {
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 0.75rem;
    color: var(--text-secondary);
    letter-spacing: 0.5px;
}

.terminal-body {
    background: rgba(5, 8, 18, 0.95);
    padding: 1rem 1.25rem;
    height: 220px;
    overflow: hidden;
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 0.82rem;
    line-height: 1.75;
}

/* Terminal line classes */
.tl { animation: lineIn 0.2s ease-out; }

@keyframes lineIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.tl-sys { color: #8899aa; }
.tl-scan { color: #55ccee; }
.tl-threat { color: #ff4477; font-weight: 600; }
.tl-ok { color: #33eebb; }
.tl-clean { color: #66bb99; }
.tl-gap { height: 4px; }

/* === BRIEFING PANEL === */
.demo-briefing {
    max-width: 1000px;
    margin: 2.5rem auto 2rem;
    padding: 2rem 2rem 1.75rem;
    background: rgba(20, 28, 45, 0.85);
    border: 1px solid rgba(0, 217, 255, 0.2);
    border-radius: var(--radius-md);
    position: relative;
    z-index: 1;
}

.briefing-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.briefing-diamond {
    color: var(--accent-cyan);
    font-size: 0.7rem;
    animation: diamondPulse 2s ease-in-out infinite;
    will-change: opacity;
    transform: translateZ(0);
}

@keyframes diamondPulse {
    0%, 100% { opacity: 1; text-shadow: 0 0 8px rgba(0, 217, 255, 0.6); }
    50% { opacity: 0.5; text-shadow: none; }
}

.briefing-header h3 {
    font-family: 'Orbitron', sans-serif;
    font-size: var(--fs-xl);
    color: var(--accent-cyan);
    letter-spacing: 3px;
    flex-shrink: 0;
    text-shadow: 0 0 12px rgba(0, 217, 255, 0.3);
}

.briefing-line {
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, rgba(0, 217, 255, 0.3), transparent);
}

.briefing-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.briefing-item {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    padding: 1rem 1.15rem;
    background: rgba(0, 217, 255, 0.05);
    border: 1px solid rgba(0, 217, 255, 0.12);
    border-radius: var(--radius-sm);
    transition: border-color 0.3s;
}

.briefing-item:hover {
    border-color: rgba(0, 217, 255, 0.3);
}

/* Per-item color tinting */
.briefing-item:nth-child(1) {
    background: rgba(0, 217, 255, 0.06);
    border-color: rgba(0, 217, 255, 0.18);
}
.briefing-item:nth-child(1) .briefing-num { color: #00d9ff; }

.briefing-item:nth-child(2) {
    background: rgba(0, 255, 170, 0.05);
    border-color: rgba(0, 255, 170, 0.15);
}
.briefing-item:nth-child(2) .briefing-num { color: #00ffaa; text-shadow: 0 0 10px rgba(0, 255, 170, 0.3); }

.briefing-item:nth-child(3) {
    background: rgba(255, 170, 51, 0.05);
    border-color: rgba(255, 170, 51, 0.15);
}
.briefing-item:nth-child(3) .briefing-num { color: #ffaa33; text-shadow: 0 0 10px rgba(255, 170, 51, 0.3); }

.briefing-item:nth-child(4) {
    background: rgba(188, 19, 254, 0.05);
    border-color: rgba(188, 19, 254, 0.15);
}
.briefing-item:nth-child(4) .briefing-num { color: #bc13fe; text-shadow: 0 0 10px rgba(188, 19, 254, 0.3); }

.briefing-num {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.35rem;
    font-weight: 900;
    color: var(--accent-cyan);
    min-width: 36px;
    text-shadow: 0 0 12px rgba(0, 217, 255, 0.3);
}

.briefing-text strong {
    display: block;
    color: #fff;
    font-size: var(--fs-base);
    margin-bottom: 0.3rem;
}

.briefing-text p {
    color: #a8b4c4;
    font-size: var(--fs-sm);
    line-height: 1.6;
    margin: 0;
}

.briefing-text code {
    background: rgba(0, 217, 255, 0.12);
    color: var(--accent-cyan);
    padding: 0.1rem 0.45rem;
    border-radius: 3px;
    font-size: 0.82em;
}

/* === IMPERSONATION TEST BOX === */
.demo-impersonation {
    max-width: 1000px;
    margin: 0 auto 2.5rem;
    padding: 2rem 2rem 1.75rem;
    background: rgba(255, 153, 51, 0.04);
    border: 1px solid rgba(255, 153, 51, 0.2);
    border-left: 4px solid #ff9933;
    border-radius: var(--radius-md);
    position: relative;
    z-index: 1;
}

.impersonation-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.impersonation-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.impersonation-header h3 {
    font-family: 'Orbitron', sans-serif;
    font-size: var(--fs-base);
    color: #ff9933;
    letter-spacing: 1.5px;
}

.impersonation-intro {
    color: var(--text-secondary);
    font-size: var(--fs-sm);
    line-height: 1.7;
    margin-bottom: 1.25rem;
}

.impersonation-intro strong {
    color: var(--text-primary);
}

.impersonation-steps {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.imp-step {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
    padding: 0.6rem 0;
}

.imp-step-num {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    min-width: 30px;
    border-radius: 50%;
    background: rgba(255, 153, 51, 0.12);
    border: 1px solid rgba(255, 153, 51, 0.3);
    color: #ff9933;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.75rem;
    font-weight: 700;
    flex-shrink: 0;
}

/* Each step circle gets its own color */
.imp-step:nth-child(1) .imp-step-num {
    background: rgba(0, 217, 255, 0.12);
    border-color: rgba(0, 217, 255, 0.35);
    color: #00d9ff;
}
.imp-step:nth-child(2) .imp-step-num {
    background: rgba(0, 255, 170, 0.12);
    border-color: rgba(0, 255, 170, 0.35);
    color: #00ffaa;
}
.imp-step:nth-child(3) .imp-step-num {
    background: rgba(255, 153, 51, 0.12);
    border-color: rgba(255, 153, 51, 0.35);
    color: #ff9933;
}
.imp-step:nth-child(4) .imp-step-num {
    background: rgba(255, 102, 170, 0.12);
    border-color: rgba(255, 102, 170, 0.35);
    color: #ff66aa;
}
.imp-step:nth-child(5) .imp-step-num {
    background: rgba(255, 215, 0, 0.12);
    border-color: rgba(255, 215, 0, 0.35);
    color: #ffd700;
}

.imp-step div {
    color: var(--text-secondary);
    font-size: var(--fs-sm);
    line-height: 1.6;
}

.imp-step strong {
    color: var(--text-primary);
}

.impersonation-note {
    padding: 0.75rem 1rem;
    background: rgba(0, 255, 170, 0.06);
    border: 1px solid rgba(0, 255, 170, 0.2);
    border-radius: 6px;
    color: var(--accent-green);
    font-size: 0.85rem;
    font-weight: 600;
}

/* === SECTION LAYOUT + ACCORDION === */
.demo-section {
    max-width: 1400px;
    margin: 0 auto 0.75rem;
    padding: 0 1.5rem;
    position: relative;
    z-index: 1;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: 1.25rem 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: var(--radius-sm);
    background: rgba(26, 31, 46, 0.5);
    cursor: pointer;
    user-select: none;
    transition: all 0.3s ease;
    flex-wrap: wrap;
}

.section-header:hover {
    background: rgba(26, 31, 46, 0.7);
}

/* Color-coded section headers by threat level */
.demo-section[data-theme="red"] .section-header {
    border-color: rgba(255, 51, 102, 0.15);
    border-left: 3px solid rgba(255, 51, 102, 0.5);
}
.demo-section[data-theme="red"] .section-header:hover {
    border-color: rgba(255, 51, 102, 0.3);
    box-shadow: 0 0 20px rgba(255, 51, 102, 0.06);
}
.demo-section[data-theme="red"] .section-number {
    color: rgba(255, 51, 102, 0.25);
}

.demo-section[data-theme="orange"] .section-header {
    border-color: rgba(255, 153, 51, 0.15);
    border-left: 3px solid rgba(255, 153, 51, 0.5);
}
.demo-section[data-theme="orange"] .section-header:hover {
    border-color: rgba(255, 153, 51, 0.3);
    box-shadow: 0 0 20px rgba(255, 153, 51, 0.06);
}
.demo-section[data-theme="orange"] .section-number {
    color: rgba(255, 153, 51, 0.25);
}

.demo-section[data-theme="green"] .section-header {
    border-color: rgba(0, 255, 170, 0.15);
    border-left: 3px solid rgba(0, 255, 170, 0.5);
}
.demo-section[data-theme="green"] .section-header:hover {
    border-color: rgba(0, 255, 170, 0.3);
    box-shadow: 0 0 20px rgba(0, 255, 170, 0.06);
}
.demo-section[data-theme="green"] .section-number {
    color: rgba(0, 255, 170, 0.25);
}

.demo-section[data-theme="purple"] .section-header {
    border-color: rgba(188, 19, 254, 0.15);
    border-left: 3px solid rgba(188, 19, 254, 0.5);
}
.demo-section[data-theme="purple"] .section-header:hover {
    border-color: rgba(188, 19, 254, 0.3);
    box-shadow: 0 0 20px rgba(188, 19, 254, 0.06);
}
.demo-section[data-theme="purple"] .section-number {
    color: rgba(188, 19, 254, 0.25);
}

.section-number {
    font-family: 'Orbitron', sans-serif;
    font-size: var(--fs-xl);
    font-weight: 900;
    color: rgba(0, 217, 255, 0.15);
    line-height: 1;
    flex-shrink: 0;
}

.section-info {
    flex: 1;
    min-width: 180px;
}

.section-info h2 {
    font-family: 'Orbitron', sans-serif;
    font-size: var(--fs-lg);
    color: var(--text-primary);
    margin-bottom: 0.25rem;
    letter-spacing: 1px;
}

.section-info p {
    color: var(--text-secondary);
    font-size: var(--fs-sm);
    line-height: 1.5;
}

.section-badge {
    font-family: 'Orbitron', sans-serif;
    font-size: var(--fs-xs);
    letter-spacing: 1px;
    padding: 0.4rem 1rem;
    border-radius: var(--radius-full);
    flex-shrink: 0;
    white-space: nowrap;
}

.badge-red {
    color: var(--danger);
    background: rgba(255, 51, 102, 0.1);
    border: 1px solid rgba(255, 51, 102, 0.3);
}
.badge-orange {
    color: #ff9933;
    background: rgba(255, 153, 51, 0.1);
    border: 1px solid rgba(255, 153, 51, 0.3);
}
.badge-green {
    color: var(--accent-green);
    background: rgba(0, 255, 170, 0.1);
    border: 1px solid rgba(0, 255, 170, 0.3);
}
.badge-purple {
    color: var(--accent-purple);
    background: rgba(188, 19, 254, 0.1);
    border: 1px solid rgba(188, 19, 254, 0.3);
}

/* Accordion chevron — large and obvious */
.section-chevron {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: var(--text-secondary);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.03);
    transition: all 0.35s ease;
    flex-shrink: 0;
    margin-left: auto;
}

.section-header:hover .section-chevron {
    border-color: rgba(0, 217, 255, 0.3);
    color: var(--accent-cyan);
    background: rgba(0, 217, 255, 0.06);
}

.demo-section.section-open .section-chevron {
    transform: rotate(180deg);
    background: rgba(0, 217, 255, 0.08);
    border-color: rgba(0, 217, 255, 0.25);
    color: var(--accent-cyan);
}

/* Accordion body - smooth open/close via max-height transition */
.scenarios-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
    padding-top: 0;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.45s ease, opacity 0.3s ease, padding-top 0.35s ease;
}

.demo-section.section-open .scenarios-grid {
    max-height: 10000px;
    opacity: 1;
    padding-top: 1.25rem;
}

/* === SCENARIO CARD === */
.scenario-card {
    background: rgba(26, 31, 46, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: all 0.3s ease;
}

.scenario-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
}

/* Threat-level left border accents */
.threat-simple { border-left: 3px solid var(--danger); }
.threat-advanced { border-left: 3px solid #ff9933; }
.threat-sophisticated { border-left: 3px solid var(--danger); }
.threat-safe { border-left: 3px solid var(--accent-green); }
.threat-ultra { border-left: 3px solid var(--accent-purple); }

/* Card header */
.card-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem 1.25rem;
    background: rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.card-number {
    font-family: 'Orbitron', sans-serif;
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    flex-shrink: 0;
}

.card-title {
    font-family: 'Inter', sans-serif;
    font-size: var(--fs-sm);
    font-weight: 600;
    color: var(--text-primary);
    flex: 1;
}

.threat-tag {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.6rem;
    letter-spacing: 1px;
    padding: 0.2rem 0.65rem;
    border-radius: var(--radius-full);
    flex-shrink: 0;
    white-space: nowrap;
}

.tag-red {
    color: var(--danger);
    background: rgba(255, 51, 102, 0.15);
    border: 1px solid rgba(255, 51, 102, 0.3);
}
.tag-orange {
    color: #ff9933;
    background: rgba(255, 153, 51, 0.15);
    border: 1px solid rgba(255, 153, 51, 0.3);
}
.tag-green {
    color: var(--accent-green);
    background: rgba(0, 255, 170, 0.15);
    border: 1px solid rgba(0, 255, 170, 0.3);
}
.tag-purple {
    color: var(--accent-purple);
    background: rgba(188, 19, 254, 0.15);
    border: 1px solid rgba(188, 19, 254, 0.3);
}

/* Card body */
.card-body { padding: 1rem 1.25rem; }

.scenario-text {
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 0.8rem;
    color: #c8d0dc;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: var(--radius-sm);
    padding: 1rem;
    white-space: pre-wrap;
    word-wrap: break-word;
    line-height: 1.6;
    max-height: 300px;
    overflow-y: auto;
}

.scenario-text::-webkit-scrollbar { width: 5px; }
.scenario-text::-webkit-scrollbar-track { background: rgba(0, 0, 0, 0.2); border-radius: 3px; }
.scenario-text::-webkit-scrollbar-thumb { background: rgba(0, 217, 255, 0.3); border-radius: 3px; }

.card-note {
    margin-top: 0.6rem;
    padding: 0.65rem 0.95rem;
    background: rgba(0, 217, 255, 0.06);
    border: 1px solid rgba(0, 217, 255, 0.18);
    border-left: 3px solid rgba(0, 217, 255, 0.35);
    border-radius: 4px 6px 6px 4px;
    font-size: 0.78rem;
    color: rgba(224, 230, 237, 0.75);
    line-height: 1.6;
    font-style: italic;
}

/* Card footer */
.card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.7rem 1.25rem;
    background: rgba(0, 0, 0, 0.15);
    border-top: 1px solid rgba(255, 255, 255, 0.04);
    gap: 0.75rem;
    flex-wrap: wrap;
}

.expected-result {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.result-label {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.6rem;
    color: var(--text-secondary);
    letter-spacing: 1px;
    text-transform: uppercase;
}

.result-value { font-size: 0.85rem; font-weight: 600; }
.result-danger { color: var(--danger); }
.result-safe { color: var(--accent-green); }

/* Copy button */
.btn-copy {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.45rem 1rem;
    background: rgba(0, 217, 255, 0.08);
    border: 1px solid rgba(0, 217, 255, 0.25);
    border-radius: 6px;
    color: var(--accent-cyan);
    font-family: 'Inter', sans-serif;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    flex-shrink: 0;
    min-height: 36px;
}

.btn-copy:hover {
    background: rgba(0, 217, 255, 0.2);
    border-color: var(--accent-cyan);
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(0, 217, 255, 0.2);
}

.btn-copy.copied {
    background: rgba(0, 255, 170, 0.15);
    border-color: var(--accent-green);
    color: var(--accent-green);
}

.copy-icon { font-size: 0.95rem; }

/* === SUMMARY SECTION === */
.demo-summary {
    max-width: 900px;
    margin: 2rem auto 4rem;
    padding: 2.5rem 2rem;
    text-align: center;
    background: rgba(26, 31, 46, 0.4);
    border: 1px solid rgba(0, 217, 255, 0.15);
    border-radius: var(--radius-md);
    position: relative;
    z-index: 1;
}

.demo-summary h2 {
    font-family: 'Orbitron', sans-serif;
    font-size: var(--fs-lg);
    color: var(--text-primary);
    letter-spacing: 2px;
    margin-bottom: 2rem;
}

.summary-grid {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.summary-stat { text-align: center; }

.stat-number {
    font-family: 'Orbitron', sans-serif;
    font-size: var(--fs-2xl);
    font-weight: 900;
    line-height: 1;
    margin-bottom: 0.35rem;
}

.stat-total { color: var(--accent-cyan); }
.stat-threats { color: var(--danger); }
.stat-safe { color: var(--accent-green); }

.stat-label {
    font-size: var(--fs-sm);
    color: var(--text-secondary);
    letter-spacing: 0.5px;
}

.summary-note {
    color: var(--text-secondary);
    font-size: var(--fs-sm);
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto;
}

.summary-note strong { color: var(--text-primary); }

.summary-note code {
    background: rgba(0, 217, 255, 0.1);
    color: var(--accent-cyan);
    padding: 0.15rem 0.5rem;
    border-radius: 4px;
    font-size: 0.85em;
}

/* === SCROLL ANIMATIONS === */
.fade-in {
    opacity: 0;
    transition: opacity 0.5s ease-out;
}

.fade-in.visible {
    opacity: 1;
}

.scenarios-grid .scenario-card.fade-in:nth-child(2) { transition-delay: 0.08s; }
.scenarios-grid .scenario-card.fade-in:nth-child(3) { transition-delay: 0.16s; }
.scenarios-grid .scenario-card.fade-in:nth-child(4) { transition-delay: 0.24s; }
.scenarios-grid .scenario-card.fade-in:nth-child(5) { transition-delay: 0.32s; }
.scenarios-grid .scenario-card.fade-in:nth-child(6) { transition-delay: 0.40s; }
.scenarios-grid .scenario-card.fade-in:nth-child(7) { transition-delay: 0.48s; }
.scenarios-grid .scenario-card.fade-in:nth-child(8) { transition-delay: 0.56s; }

/* === HOVER GLOW PER THREAT LEVEL === */
.threat-simple:hover {
    border-color: rgba(255, 51, 102, 0.3);
    box-shadow: 0 8px 30px rgba(255, 51, 102, 0.1);
}
.threat-advanced:hover {
    border-color: rgba(255, 153, 51, 0.3);
    box-shadow: 0 8px 30px rgba(255, 153, 51, 0.1);
}
.threat-sophisticated:hover {
    border-color: rgba(255, 51, 102, 0.3);
    box-shadow: 0 8px 30px rgba(255, 51, 102, 0.1);
}
.threat-safe:hover {
    border-color: rgba(0, 255, 170, 0.3);
    box-shadow: 0 8px 30px rgba(0, 255, 170, 0.1);
}
.threat-ultra:hover {
    border-color: rgba(188, 19, 254, 0.3);
    box-shadow: 0 8px 30px rgba(188, 19, 254, 0.1);
}

/* === RESPONSIVE: TABLET (768px+) === */
@media (min-width: 768px) {
    .demo-header {
        padding: 9rem 2rem 3rem;
    }

    .demo-section {
        padding: 0 2rem;
    }

    .briefing-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .scenarios-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* === RESPONSIVE: DESKTOP (1100px+) === */
@media (min-width: 1100px) {
    .demo-section.section-open .scenarios-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .briefing-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .demo-briefing,
    .demo-impersonation {
        max-width: 1400px;
    }

    .terminal-widget {
        max-width: 560px;
    }

    .demo-after-testing {
        max-width: 1400px;
    }

    .after-steps {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* === AFTER TESTING SECTION === */
.demo-after-testing {
    max-width: 1000px;
    margin: 3rem auto 2rem;
    padding: 2.5rem 2rem;
    background: rgba(26, 31, 46, 0.5);
    border: 1px solid rgba(0, 217, 255, 0.15);
    border-top: 3px solid var(--accent-cyan);
    border-radius: var(--radius-md);
    position: relative;
    z-index: 1;
}

.after-header {
    text-align: center;
    margin-bottom: 2rem;
}

.after-icon {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
}

.after-header h2 {
    font-family: 'Orbitron', sans-serif;
    font-size: var(--fs-xl);
    color: var(--text-primary);
    letter-spacing: 3px;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, #fff 0%, var(--accent-cyan) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.after-header p {
    color: var(--text-secondary);
    font-size: var(--fs-base);
    line-height: 1.6;
}

.after-steps {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

.after-step {
    display: flex;
    gap: 1.25rem;
    align-items: flex-start;
    padding: 1.5rem;
    border-radius: var(--radius-sm);
    transition: border-color 0.3s, box-shadow 0.3s;
}

.after-step--report {
    background: rgba(0, 217, 255, 0.04);
    border: 1px solid rgba(0, 217, 255, 0.15);
}

.after-step--report:hover {
    border-color: rgba(0, 217, 255, 0.3);
    box-shadow: 0 0 20px rgba(0, 217, 255, 0.06);
}

.after-step--cleanup {
    background: rgba(0, 255, 170, 0.04);
    border: 1px solid rgba(0, 255, 170, 0.15);
}

.after-step--cleanup:hover {
    border-color: rgba(0, 255, 170, 0.3);
    box-shadow: 0 0 20px rgba(0, 255, 170, 0.06);
}

.after-step-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    min-width: 44px;
    border-radius: 50%;
    font-family: 'Orbitron', sans-serif;
    font-size: 1.2rem;
    font-weight: 900;
    flex-shrink: 0;
}

.after-step--report .after-step-number {
    background: rgba(0, 217, 255, 0.1);
    border: 2px solid rgba(0, 217, 255, 0.3);
    color: #00d9ff;
    text-shadow: 0 0 10px rgba(0, 217, 255, 0.3);
}

.after-step--cleanup .after-step-number {
    background: rgba(0, 255, 170, 0.1);
    border: 2px solid rgba(0, 255, 170, 0.3);
    color: #00ffaa;
    text-shadow: 0 0 10px rgba(0, 255, 170, 0.3);
}

.after-step-content h3 {
    font-family: 'Orbitron', sans-serif;
    font-size: var(--fs-base);
    color: var(--text-primary);
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}

.after-step-content p {
    color: var(--text-secondary);
    font-size: var(--fs-sm);
    line-height: 1.6;
    margin: 0 0 0.75rem;
}

.after-command {
    display: inline-block;
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 1rem;
    font-weight: 700;
    padding: 0.6rem 1.25rem;
    border-radius: 6px;
    margin: 0.5rem 0;
    letter-spacing: 0.5px;
}

.after-step--report .after-command {
    background: rgba(0, 217, 255, 0.08);
    border: 1px solid rgba(0, 217, 255, 0.25);
    color: #00d9ff;
}

.after-step--cleanup .after-command {
    background: rgba(0, 255, 170, 0.08);
    border: 1px solid rgba(0, 255, 170, 0.25);
    color: #00ffaa;
}

.after-detail {
    font-size: 0.85rem !important;
    color: #8b92a0 !important;
    line-height: 1.55 !important;
}

.after-detail code {
    background: rgba(0, 217, 255, 0.1);
    color: var(--accent-cyan);
    padding: 0.1rem 0.4rem;
    border-radius: 3px;
    font-size: 0.85em;
}

/* =============================================
   SESSION 159 ADDITIONS
   ============================================= */

/* === COLLAPSIBLE ADMIN ALERTS SECTION === */
.demo-alerts-collapsible {
    max-width: 1000px;
    margin: 2.5rem auto 2rem;
    background: rgba(20, 28, 45, 0.85);
    border: 1px solid rgba(0, 217, 255, 0.2);
    border-radius: var(--radius-md);
    position: relative;
    z-index: 1;
    overflow: hidden;
}

.alerts-toggle-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1.25rem 2rem;
    cursor: pointer;
    user-select: none;
    transition: background 0.3s;
}

.alerts-toggle-header:hover {
    background: rgba(0, 217, 255, 0.04);
}

.alerts-toggle-diamond {
    color: var(--accent-cyan);
    font-size: 0.7rem;
    animation: diamondPulse 2s ease-in-out infinite;
    flex-shrink: 0;
    will-change: opacity;
    transform: translateZ(0);
}

.alerts-toggle-header h3 {
    font-family: 'Orbitron', sans-serif;
    font-size: var(--fs-xl);
    color: var(--accent-cyan);
    letter-spacing: 3px;
    text-shadow: 0 0 12px rgba(0, 217, 255, 0.3);
    flex: 1;
}

.alerts-toggle-hint {
    font-size: 0.72rem;
    color: rgba(0, 217, 255, 0.45);
    letter-spacing: 1px;
    margin-right: 0.5rem;
    flex-shrink: 0;
}

.alerts-chevron {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: var(--accent-cyan);
    border: 1px solid rgba(0, 217, 255, 0.3);
    border-radius: 50%;
    background: rgba(0, 217, 255, 0.06);
    transition: all 0.35s ease;
    flex-shrink: 0;
}

.demo-alerts-collapsible.alerts-open .alerts-chevron {
    transform: rotate(180deg);
    background: rgba(0, 217, 255, 0.12);
}

.alerts-toggle-header:hover .alerts-chevron {
    border-color: var(--accent-cyan);
    box-shadow: 0 0 12px rgba(0, 217, 255, 0.2);
}

.alerts-body {
    display: none;
    padding: 0 2rem 1.75rem;
}

.demo-alerts-collapsible.alerts-open .alerts-body {
    display: block;
}

.alerts-divider {
    height: 1px;
    background: linear-gradient(90deg, rgba(0, 217, 255, 0.3), transparent);
    margin-bottom: 1.5rem;
}

/* === SECTION HEADER BACKGROUND TINTS (distinct per theme) === */
.demo-section[data-theme="red"] .section-header {
    background: rgba(255, 51, 102, 0.05);
}
.demo-section[data-theme="orange"] .section-header {
    background: rgba(255, 153, 51, 0.05);
}
.demo-section[data-theme="green"] .section-header {
    background: rgba(0, 255, 170, 0.04);
}
.demo-section[data-theme="purple"] .section-header {
    background: rgba(188, 19, 254, 0.05);
}

/* === CYAN THEME (Section 03 — Sophisticated Attacks) === */
.demo-section[data-theme="cyan"] .section-header {
    border-color: rgba(0, 217, 255, 0.18);
    border-left: 3px solid rgba(0, 217, 255, 0.55);
    background: rgba(0, 217, 255, 0.05);
}
.demo-section[data-theme="cyan"] .section-header:hover {
    border-color: rgba(0, 217, 255, 0.35);
    box-shadow: 0 0 20px rgba(0, 217, 255, 0.07);
}
.demo-section[data-theme="cyan"] .section-number {
    color: rgba(0, 217, 255, 0.25);
}
.badge-cyan {
    color: var(--accent-cyan);
    background: rgba(0, 217, 255, 0.1);
    border: 1px solid rgba(0, 217, 255, 0.3);
}

/* === SCENARIO CARD BACKGROUND TINTS (subtle, per threat type) === */
.threat-simple {
    background: rgba(255, 51, 102, 0.04);
}
.threat-advanced {
    background: rgba(255, 153, 51, 0.04);
}
.threat-sophisticated {
    background: rgba(0, 217, 255, 0.025);
}
.threat-safe {
    background: rgba(0, 255, 170, 0.03);
}
.threat-ultra {
    background: rgba(188, 19, 254, 0.05);
}

/* Expected result color varies per card type (no HTML changes needed) */
.threat-advanced .result-danger { color: #ff9933; }
.threat-sophisticated .result-danger { color: #22aadd; }
.threat-ultra .result-value { color: var(--accent-purple); }

/* === BONUS TEST — ENHANCED GLOW AT END === */
.demo-bonus-test {
    max-width: 1000px;
    margin: 2.5rem auto 3rem;
    padding: 0;
    border-radius: var(--radius-md);
    position: relative;
    z-index: 1;
    animation: bonusGlow 3s ease-in-out infinite;
    overflow: hidden;
}

@keyframes bonusGlow {
    0%, 100% {
        box-shadow:
            0 0 20px rgba(255, 153, 51, 0.15),
            0 0 40px rgba(255, 153, 51, 0.07),
            inset 0 0 20px rgba(255, 153, 51, 0.03);
    }
    50% {
        box-shadow:
            0 0 40px rgba(255, 153, 51, 0.32),
            0 0 80px rgba(255, 153, 51, 0.14),
            inset 0 0 30px rgba(255, 153, 51, 0.06);
    }
}

.bonus-test-inner {
    padding: 2rem 2rem 1.75rem;
    background: rgba(255, 153, 51, 0.04);
    border: 1px solid rgba(255, 153, 51, 0.3);
    border-left: 4px solid #ff9933;
    border-radius: var(--radius-md);
}

.bonus-top-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.65rem;
    letter-spacing: 3px;
    color: #ff9933;
    background: rgba(255, 153, 51, 0.1);
    border: 1px solid rgba(255, 153, 51, 0.35);
    border-radius: var(--radius-full);
    padding: 0.35rem 1.1rem;
    margin-bottom: 1rem;
}

.bonus-badge-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #ff9933;
    animation: dotBlink 1.5s ease-in-out infinite;
}

/* Mini avatar comparison widget */
.bonus-avatar-widget {
    display: flex;
    gap: 1rem;
    align-items: stretch;
    margin: 1.5rem 0 1.25rem;
    flex-wrap: wrap;
}

.bonus-avatar-card {
    flex: 1;
    min-width: 180px;
    padding: 1rem;
    border-radius: var(--radius-sm);
    text-align: center;
    position: relative;
}

.bonus-avatar-card--trusted {
    background: rgba(0, 255, 170, 0.05);
    border: 1px solid rgba(0, 255, 170, 0.25);
}

.bonus-avatar-card--clone {
    background: rgba(255, 51, 102, 0.06);
    border: 1px solid rgba(255, 51, 102, 0.3);
    animation: clonePulse 2.5s ease-in-out infinite;
}

@keyframes clonePulse {
    0%, 100% { border-color: rgba(255, 51, 102, 0.3); }
    50% { border-color: rgba(255, 51, 102, 0.7); box-shadow: 0 0 15px rgba(255, 51, 102, 0.15); }
}

.bonus-avatar-pic {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    margin: 0 auto 0.6rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    position: relative;
}

.bonus-avatar-pic--trusted {
    background: rgba(0, 255, 170, 0.12);
    border: 2px solid rgba(0, 255, 170, 0.4);
}

.bonus-avatar-pic--clone {
    background: rgba(255, 51, 102, 0.1);
    border: 2px solid rgba(255, 51, 102, 0.4);
}

.bonus-identical-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.5rem;
    letter-spacing: 1px;
    color: #fff;
    background: #ff3366;
    border-radius: 4px;
    padding: 0.15rem 0.35rem;
    animation: identicalFlash 1.8s ease-in-out infinite;
}

@keyframes identicalFlash {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.bonus-avatar-name {
    font-weight: 700;
    color: var(--text-primary);
    font-size: 0.82rem;
    margin-bottom: 0.2rem;
}

.bonus-avatar-sub {
    font-size: 0.71rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.bonus-status-badge {
    display: inline-block;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.55rem;
    letter-spacing: 1px;
    padding: 0.2rem 0.55rem;
    border-radius: 4px;
}

.bonus-status-badge--verified {
    color: #00ffaa;
    background: rgba(0, 255, 170, 0.12);
    border: 1px solid rgba(0, 255, 170, 0.35);
}

.bonus-status-badge--impersonator {
    color: #ff3366;
    background: rgba(255, 51, 102, 0.12);
    border: 1px solid rgba(255, 51, 102, 0.4);
}

.bonus-vs-divider {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 0 0.5rem;
    color: rgba(255, 255, 255, 0.2);
    font-family: 'Orbitron', sans-serif;
    font-size: 0.65rem;
    letter-spacing: 2px;
    flex-shrink: 0;
}

.bonus-vs-line {
    width: 1px;
    height: 30px;
    background: linear-gradient(to bottom, transparent, rgba(255,255,255,0.15), transparent);
}

/* Verdict row */
.bonus-verdict-row {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 0.75rem;
}

.bonus-verdict-item {
    flex: 1;
    min-width: 100px;
    padding: 0.6rem 0.75rem;
    border-radius: 6px;
    text-align: center;
}

.bonus-verdict-item--match {
    background: rgba(0, 255, 170, 0.06);
    border: 1px solid rgba(0, 255, 170, 0.2);
}
.bonus-verdict-item--timing {
    background: rgba(255, 204, 0, 0.06);
    border: 1px solid rgba(255, 204, 0, 0.2);
}
.bonus-verdict-item--verdict {
    background: rgba(255, 51, 102, 0.07);
    border: 1px solid rgba(255, 51, 102, 0.25);
}

.bonus-verdict-label {
    font-size: 0.68rem;
    color: rgba(255,255,255,0.45);
    letter-spacing: 1px;
    margin-bottom: 0.3rem;
    font-family: 'Orbitron', sans-serif;
}

.bonus-verdict-val {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 1px;
}

.bonus-verdict-val--yes { color: #00ffaa; }
.bonus-verdict-val--suspicious { color: #ffcc00; }
.bonus-verdict-val--clone { color: #ff3366; animation: identicalFlash 1.5s ease-in-out infinite; }

.bonus-caught-bar {
    margin-top: 1rem;
    padding: 0.75rem 1rem;
    background: rgba(255, 51, 102, 0.08);
    border: 1px solid rgba(255, 51, 102, 0.3);
    border-radius: 6px;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.72rem;
    letter-spacing: 1.5px;
    color: #ff5577;
    text-align: center;
    animation: bonusGlow 2s ease-in-out infinite;
}

@media (min-width: 1100px) {
    .demo-bonus-test {
        max-width: 1400px;
    }
    .bonus-avatar-widget {
        flex-wrap: nowrap;
    }
}

/* =============================================
   SESSION 159 POLISH FIXES
   ============================================= */

/* Width fix — outer container matches .demo-section */
.demo-alerts-outer {
    max-width: 1400px;
    margin: 2.5rem auto 2rem;
    padding: 0 1.5rem;
    position: relative;
    z-index: 1;
}
.demo-alerts-collapsible {
    max-width: none;
    margin: 0;
}

/* Alerts headline — amber/gold, distinct from TEST PROTOCOL cyan */
.alerts-toggle-header h3 {
    color: #ffaa33;
    text-shadow: 0 0 14px rgba(255, 170, 51, 0.55), 0 0 28px rgba(255, 170, 51, 0.2);
}

/* TEST PROTOCOL headline — cyan glow on letters */
.briefing-header h3 {
    text-shadow: 0 0 14px rgba(0, 217, 255, 0.55), 0 0 28px rgba(0, 217, 255, 0.2);
}

/* Section 03 Sophisticated Attacks — tags use cyan to match section badge */
.threat-sophisticated .threat-tag {
    color: var(--accent-cyan) !important;
    background: rgba(0, 217, 255, 0.12) !important;
    border-color: rgba(0, 217, 255, 0.35) !important;
}

/* Purple section badge — lighter, readable */
.badge-purple {
    color: #cc55ff;
    background: rgba(188, 19, 254, 0.1);
    border: 1px solid rgba(188, 19, 254, 0.3);
}
.demo-section[data-theme="purple"] .section-header {
    border-left-color: rgba(204, 85, 255, 0.55);
    border-color: rgba(204, 85, 255, 0.18);
}
.demo-section[data-theme="purple"] .section-number {
    color: rgba(204, 85, 255, 0.3);
}

/* After Testing — cyan glow border (matches bonus test energy) */
.demo-after-testing {
    animation: afterGlow 3.5s ease-in-out infinite;
    will-change: box-shadow;
    transform: translateZ(0);
}
@keyframes afterGlow {
    0%, 100% {
        box-shadow: 0 0 15px rgba(0, 217, 255, 0.1), 0 0 30px rgba(0, 217, 255, 0.04);
    }
    50% {
        box-shadow: 0 0 35px rgba(0, 217, 255, 0.28), 0 0 65px rgba(0, 217, 255, 0.1);
    }
}

/* STOP FLICKERING — GPU promote + remove inset from bonusGlow */
.demo-bonus-test {
    transform: translateZ(0);
    will-change: box-shadow;
}
.bonus-avatar-card--clone {
    transform: translateZ(0);
    will-change: border-color, box-shadow;
}

/* Override bonusGlow — remove inset (inset repaints content, causes flicker) */
@keyframes bonusGlow {
    0%, 100% {
        box-shadow:
            0 0 20px rgba(255, 153, 51, 0.15),
            0 0 40px rgba(255, 153, 51, 0.07);
    }
    50% {
        box-shadow:
            0 0 40px rgba(255, 153, 51, 0.30),
            0 0 80px rgba(255, 153, 51, 0.12);
    }
}

/* Bonus caught bar — own simple pulse, not the heavy bonusGlow */
.bonus-caught-bar {
    animation: caughtBarPulse 2.5s ease-in-out infinite;
    will-change: border-color;
}
@keyframes caughtBarPulse {
    0%, 100% { border-color: rgba(255, 51, 102, 0.3); }
    50% { border-color: rgba(255, 51, 102, 0.7); text-shadow: 0 0 10px rgba(255, 85, 119, 0.35); }
}
