/* ==========================================================================
   STUDENT SUCCESS SYSTEM (SSS) — 3D MODERN LANDING PAGE STYLESHEET
   Brand: #0056D2 Blue | #28A745 Green | #FF9F1C Gold | #0D1B3E Navy
   Typography: Montserrat & Garamond | Empowering Education. Achieving Goals.
   ========================================================================== */

:root {
    --bg-base: #040816;
    --bg-surface: #0a1128;
    --bg-card: rgba(13, 23, 52, 0.62);
    --bg-card-hover: rgba(20, 36, 78, 0.75);
    --bg-card-solid: #0d1734;

    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;

    /* SSS Brand Colors */
    --sss-blue: #0056D2;
    --sss-blue-glow: rgba(0, 86, 210, 0.35);
    --sss-green: #28A745;
    --sss-green-glow: rgba(40, 167, 69, 0.35);
    --sss-gold: #FF9F1C;
    --sss-gold-glow: rgba(255, 159, 28, 0.35);
    --sss-navy: #0D1B3E;

    --cyan: #38bdf8;
    --cyan-glow: rgba(56, 189, 248, 0.28);
    --blue: #0056D2;
    --emerald: #28A745;
    --emerald-glow: rgba(40, 167, 69, 0.28);
    --amber: #FF9F1C;
    --amber-glow: rgba(255, 159, 28, 0.28);
    --purple: #6366F1;
    --purple-glow: rgba(99, 102, 241, 0.28);

    --border-glass: rgba(255, 255, 255, 0.08);
    --border-highlight: rgba(0, 86, 210, 0.38);

    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-xl: 28px;

    --font-main: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-heading: 'Montserrat', sans-serif;
    --font-serif: 'EB Garamond', Garamond, serif;

    --transition-fast: 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-smooth: 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
    scroll-behavior: smooth;
    color-scheme: dark;
}

body.landing-3d-page {
    background-color: var(--bg-base);
    color: var(--text-primary);
    font-family: var(--font-main);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color var(--transition-fast);
}

button {
    font-family: inherit;
    border: none;
    background: none;
    cursor: pointer;
}

.content-width {
    width: min(1280px, calc(100% - 48px));
    margin-inline: auto;
}

/* Ambient Background Glow */
.ambient-mesh {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.glow-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.45;
    mix-blend-mode: screen;
    animation: orbDrift 20s infinite alternate ease-in-out;
}

.orb-primary {
    top: -10%;
    left: 20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, #1d4ed8 0%, rgba(29, 78, 216, 0) 70%);
}

.orb-secondary {
    top: 40%;
    right: -10%;
    width: 700px;
    height: 700px;
    background: radial-gradient(circle, #0284c7 0%, rgba(2, 132, 199, 0) 70%);
    animation-delay: -7s;
}

.orb-amber {
    bottom: -15%;
    left: 10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, #7c3aed 0%, rgba(124, 58, 237, 0) 70%);
    animation-delay: -14s;
}

.noise-overlay {
    position: absolute;
    inset: 0;
    opacity: 0.025;
    background-image: radial-gradient(rgba(255,255,255,0.8) 1px, transparent 0);
    background-size: 24px 24px;
}

@keyframes orbDrift {
    0% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(60px, 40px) scale(1.12); }
    100% { transform: translate(-40px, 80px) scale(0.95); }
}

/* ==========================================================================
   HEADER & NAVIGATION
   ========================================================================== */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding: 16px 0;
    transition: background var(--transition-smooth), padding var(--transition-smooth), border-color var(--transition-smooth);
}

.site-header.scrolled {
    background: rgba(4, 8, 22, 0.82);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-glass);
    padding: 12px 0;
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand-link {
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand-icon-box {
    width: 42px;
    height: 42px;
    border-radius: var(--radius-sm);
    background: linear-gradient(135deg, rgba(56, 189, 248, 0.2), rgba(37, 99, 235, 0.3));
    border: 1px solid var(--border-highlight);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    box-shadow: 0 0 20px rgba(56, 189, 248, 0.2);
}

.brand-icon-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.fallback-icon {
    display: none;
    color: var(--cyan);
    font-size: 20px;
}

.brand-text {
    display: flex;
    flex-direction: column;
}

.brand-title {
    font-family: var(--font-heading);
    font-size: 19px;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: #fff;
    line-height: 1.2;
}

.brand-title b {
    color: var(--amber);
    background: linear-gradient(135deg, #38bdf8 0%, #28A745 50%, #FF9F1C 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.brand-subtitle {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--text-muted);
    font-weight: 600;
    line-height: 1.3;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 32px;
}

.nav-link {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    position: relative;
    padding: 6px 0;
}

.nav-link:hover, .nav-link.active {
    color: #fff;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--cyan);
    border-radius: 2px;
    transition: width var(--transition-fast);
}

.nav-link:hover::after, .nav-link.active::after {
    width: 100%;
}

.header-cta-group {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* Buttons */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    background: linear-gradient(135deg, #0056D2 0%, #003E9A 100%);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 4px 18px rgba(0, 86, 210, 0.38);
    border: 1px solid rgba(255, 255, 255, 0.15);
    transition: transform var(--transition-fast), box-shadow var(--transition-fast), background var(--transition-fast);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 26px rgba(0, 86, 210, 0.55);
    background: linear-gradient(135deg, #0b68ea 0%, #0056D2 100%);
    color: #fff;
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    color: var(--text-primary);
    font-size: 14px;
    font-weight: 600;
    backdrop-filter: blur(8px);
    transition: background var(--transition-fast), border-color var(--transition-fast), transform var(--transition-fast);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.btn-ghost {
    display: inline-flex;
    align-items: center;
    padding: 10px 16px;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 600;
    transition: color var(--transition-fast);
}

.btn-ghost:hover {
    color: #fff;
}

.btn-large {
    padding: 14px 28px;
    font-size: 15px;
    border-radius: var(--radius-md);
}

.play-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    font-size: 9px;
    color: var(--cyan);
}

.btn-arrow {
    transition: transform var(--transition-fast);
}

.btn-primary:hover .btn-arrow {
    transform: translateX(4px);
}

/* Mobile Toggle & Drawer */
.mobile-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 36px;
    height: 36px;
    padding: 4px;
    cursor: pointer;
}

.mobile-toggle .bar {
    width: 24px;
    height: 2px;
    background: #fff;
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.mobile-drawer {
    display: none;
    position: fixed;
    top: 72px;
    left: 16px;
    right: 16px;
    background: rgba(10, 17, 40, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
    flex-direction: column;
    gap: 20px;
    z-index: 99;
}

.mobile-drawer.open {
    display: flex;
}

.mobile-nav {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.mobile-link {
    font-size: 16px;
    font-weight: 500;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.mobile-auth {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.full-width {
    width: 100%;
}

/* ==========================================================================
   HERO 3D SECTION
   ========================================================================== */
.hero-3d-section {
    position: relative;
    min-height: 100vh;
    padding-top: 110px;
    padding-bottom: 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow: hidden;
    z-index: 1;
}

/* Three.js Canvas Container */
.canvas-3d-viewport {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: auto;
}

#hero-canvas3d {
    width: 100%;
    height: 100%;
    display: block;
    cursor: grab;
}

#hero-canvas3d:active {
    cursor: grabbing;
}

/* 3D HUD Controls on Top of Canvas */
.canvas-hud {
    position: absolute;
    inset: 0;
    pointer-events: none;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 110px 48px 48px;
    z-index: 2;
}

.hud-pill {
    align-self: flex-end;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(10, 17, 40, 0.65);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border-glass);
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
    color: var(--text-secondary);
    letter-spacing: 0.04em;
    pointer-events: auto;
}

.live-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--emerald);
    box-shadow: 0 0 10px var(--emerald);
    animation: blinkPulse 2s infinite;
}

@keyframes blinkPulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.4; transform: scale(0.85); }
}

.canvas-tools {
    align-self: flex-end;
    display: flex;
    gap: 8px;
    pointer-events: auto;
}

.tool-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: var(--radius-sm);
    background: rgba(10, 17, 40, 0.7);
    border: 1px solid var(--border-glass);
    color: var(--text-secondary);
    font-size: 11px;
    font-weight: 600;
    backdrop-filter: blur(10px);
    transition: all var(--transition-fast);
}

.tool-btn:hover {
    color: #fff;
    background: rgba(56, 189, 248, 0.15);
    border-color: var(--border-highlight);
    transform: translateY(-2px);
}

.tool-icon {
    font-size: 14px;
    color: var(--cyan);
}

/* Hero Content Grid (Text left, HUD cards right) */
.hero-content {
    position: relative;
    z-index: 3;
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    align-items: center;
    gap: 60px;
    pointer-events: none; /* Let canvas capture drag unless hovering buttons/cards */
}

.hero-text-col {
    pointer-events: auto;
}

.hero-hud-col {
    pointer-events: auto;
    display: flex;
    flex-direction: column;
    gap: 18px;
    perspective: 1000px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 6px 14px;
    background: rgba(56, 189, 248, 0.08);
    border: 1px solid rgba(56, 189, 248, 0.25);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    color: var(--cyan);
    margin-bottom: 24px;
}

.sparkle {
    font-size: 14px;
    color: var(--cyan);
}

.badge-tag {
    background: var(--blue);
    color: #fff;
    font-size: 9px;
    padding: 2px 7px;
    border-radius: 999px;
    font-weight: 700;
    letter-spacing: 0.05em;
}

.hero-title {
    font-family: var(--font-heading);
    font-size: clamp(34px, 6vw, 68px);
    font-weight: 700;
    line-height: 1.05;
    letter-spacing: -0.035em;
    margin-bottom: 24px;
    color: #fff;
}

.gradient-text {
    background: linear-gradient(135deg, #0056D2 0%, #28A745 50%, #FF9F1C 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

.hero-description {
    font-size: clamp(15px, 1.2vw, 18px);
    line-height: 1.7;
    color: var(--text-secondary);
    max-width: 580px;
    margin-bottom: 36px;
}

.hero-description b {
    color: #fff;
}

.hero-cta-row {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 48px;
}

/* Telemetry Bar */
.telemetry-bar {
    display: flex;
    align-items: center;
    gap: 28px;
    padding: 18px 24px;
    background: rgba(10, 17, 40, 0.55);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
    backdrop-filter: blur(12px);
    width: fit-content;
}

.telemetry-item {
    display: flex;
    flex-direction: column;
}

.tele-val {
    font-family: var(--font-heading);
    font-size: 22px;
    font-weight: 700;
    color: #fff;
    line-height: 1.2;
}

.tele-label {
    font-size: 11px;
    color: var(--text-muted);
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.telemetry-divider {
    width: 1px;
    height: 32px;
    background: var(--border-glass);
}

/* Floating 3D HUD Cards */
.floating-hud-card {
    position: relative;
    padding: 20px 24px;
    border-radius: var(--radius-md);
    background: rgba(13, 23, 52, 0.75);
    border: 1px solid var(--border-glass);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.45);
    transition: transform var(--transition-fast), border-color var(--transition-fast);
    overflow: hidden;
}

.floating-hud-card:hover {
    transform: translateY(-4px) scale(1.02);
    border-color: var(--border-highlight);
}

.card-tap {
    animation: floatAnim 6s ease-in-out infinite;
}

.card-behavior {
    animation: floatAnim 6s ease-in-out infinite 2s;
    margin-left: 30px;
}

.card-parent {
    animation: floatAnim 6s ease-in-out infinite 4s;
    margin-left: 10px;
}

@keyframes floatAnim {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

.card-glow {
    position: absolute;
    top: 0;
    right: 0;
    width: 120px;
    height: 120px;
    background: radial-gradient(circle, var(--cyan-glow) 0%, transparent 70%);
    pointer-events: none;
}

.card-glow.gold {
    background: radial-gradient(circle, var(--amber-glow) 0%, transparent 70%);
}

.card-glow.emerald {
    background: radial-gradient(circle, var(--emerald-glow) 0%, transparent 70%);
}

.hud-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.hud-icon {
    width: 34px;
    height: 34px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 700;
}

.nfc-icon {
    background: rgba(56, 189, 248, 0.15);
    color: var(--cyan);
    border: 1px solid rgba(56, 189, 248, 0.3);
}

.star-icon {
    background: rgba(251, 191, 36, 0.15);
    color: var(--amber);
    border: 1px solid rgba(251, 191, 36, 0.3);
}

.heart-icon {
    background: rgba(52, 211, 153, 0.15);
    color: var(--emerald);
    border: 1px solid rgba(52, 211, 153, 0.3);
}

.hud-header-text {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.hud-header-text small {
    font-size: 10px;
    color: var(--text-muted);
    font-weight: 700;
    letter-spacing: 0.1em;
}

.hud-header-text strong {
    font-size: 14px;
    color: #fff;
    font-weight: 600;
}

.status-chip {
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 700;
}

.status-chip.success {
    background: rgba(52, 211, 153, 0.15);
    color: var(--emerald);
    border: 1px solid rgba(52, 211, 153, 0.3);
}

.status-chip.online {
    background: rgba(56, 189, 248, 0.15);
    color: var(--cyan);
    border: 1px solid rgba(56, 189, 248, 0.3);
}

.points-badge {
    background: var(--amber);
    color: #000;
    font-size: 11px;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 999px;
}

.progress-track {
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 8px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--cyan), var(--emerald));
    border-radius: 4px;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: var(--text-muted);
}

.hud-snippet {
    font-size: 12px;
    color: var(--text-secondary);
    font-style: italic;
    margin-bottom: 10px;
}

.card-avatars {
    display: flex;
    align-items: center;
    gap: 8px;
}

.avatar-circle {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #0284c7;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.teacher-tag {
    font-size: 11px;
    color: var(--text-muted);
}

.message-preview {
    font-size: 12px;
    color: var(--text-secondary);
    background: rgba(0, 0, 0, 0.2);
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    border-left: 2px solid var(--emerald);
}

/* Scroll Prompt */
.scroll-prompt {
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: var(--text-muted);
    font-size: 11px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    z-index: 3;
    pointer-events: auto;
}

.mouse-icon {
    width: 20px;
    height: 32px;
    border: 2px solid var(--text-muted);
    border-radius: 12px;
    display: flex;
    justify-content: center;
    padding-top: 5px;
}

.mouse-icon .wheel {
    width: 3px;
    height: 6px;
    background: var(--cyan);
    border-radius: 2px;
    animation: wheelBob 1.8s infinite;
}

@keyframes wheelBob {
    0% { transform: translateY(0); opacity: 1; }
    80% { transform: translateY(10px); opacity: 0; }
    100% { transform: translateY(0); opacity: 0; }
}

/* ==========================================================================
   INTERACTIVE NFC HARDWARE SIMULATOR SECTION
   ========================================================================== */
.simulator-section {
    padding: 120px 0;
    position: relative;
    z-index: 2;
}

.section-badge-center {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--cyan);
    margin-bottom: 16px;
}

.section-title-center {
    font-family: var(--font-heading);
    font-size: clamp(32px, 4vw, 52px);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.03em;
    text-align: center;
    margin-bottom: 16px;
}

.section-subtitle-center {
    font-size: clamp(15px, 1.2vw, 17px);
    color: var(--text-secondary);
    text-align: center;
    max-width: 620px;
    margin: 0 auto 60px;
}

.glass-card {
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-xl);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5);
}

.simulator-container {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 40px;
    padding: 48px;
    position: relative;
    overflow: hidden;
}

.sim-left-panel {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
}

.panel-header-title h3 {
    font-family: var(--font-heading);
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 4px;
}

.panel-header-title p {
    font-size: 13px;
    color: var(--text-muted);
}

.sim-sound-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    color: var(--text-secondary);
    font-size: 12px;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.sim-sound-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.2);
}

.sim-sound-toggle.muted {
    opacity: 0.6;
    border-color: rgba(239, 68, 68, 0.3);
}

.id-token-selector {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.token-choice {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 14px 18px;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-glass);
    color: inherit;
    text-align: left;
    transition: all var(--transition-fast);
}

.token-choice:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.15);
}

.token-choice.active {
    background: rgba(56, 189, 248, 0.1);
    border-color: var(--cyan);
    box-shadow: 0 0 20px rgba(56, 189, 248, 0.18);
}

.token-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    color: #fff;
    flex-shrink: 0;
}

.token-info {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.token-info strong {
    font-size: 15px;
    color: #fff;
}

.token-info small {
    font-size: 12px;
    color: var(--text-muted);
}

.token-badge {
    font-size: 11px;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-secondary);
}

.token-choice.active .token-badge {
    background: var(--cyan);
    color: #000;
    font-weight: 700;
}

/* Checkpoint Location Selector */
.sim-checkpoint-box {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.checkpoint-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.checkpoint-options {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.checkpoint-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 10px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-glass);
    color: var(--text-secondary);
    font-size: 11px;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.checkpoint-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.checkpoint-btn.active {
    background: rgba(56, 189, 248, 0.12);
    border-color: var(--cyan);
    color: var(--cyan);
    font-weight: 600;
}

.cp-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: currentColor;
}

/* Big Tap Trigger Button & Sub Actions */
.sim-actions-grid {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 6px;
}

.btn-nfc-tap {
    position: relative;
    width: 100%;
    padding: 22px 20px;
    border-radius: var(--radius-lg);
    background: linear-gradient(135deg, #0284c7 0%, #1e40af 100%);
    border: 1px solid rgba(56, 189, 248, 0.4);
    box-shadow: 0 12px 35px rgba(2, 132, 199, 0.35);
    overflow: hidden;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
    cursor: pointer;
}

.btn-nfc-tap:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 45px rgba(2, 132, 199, 0.55);
}

.btn-nfc-tap:active {
    transform: translateY(1px);
}

.tap-inner {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    color: #fff;
}

.tap-icon {
    font-size: 28px;
    color: #fff;
    margin-bottom: 2px;
}

.tap-inner b {
    font-family: var(--font-heading);
    font-size: 15px;
    letter-spacing: 0.08em;
}

.tap-inner small {
    font-size: 11px;
    opacity: 0.8;
}

.nfc-waves {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.35) 0%, transparent 70%);
    opacity: 0;
    pointer-events: none;
    transform: scale(0.6);
    transition: transform 0.6s ease-out, opacity 0.6s ease-out;
}

.btn-nfc-tap.tapped .nfc-waves {
    opacity: 1;
    transform: scale(2.2);
}

.sim-sub-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.btn-sub-action {
    padding: 10px 14px;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-glass);
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-fast);
    text-align: center;
}

.btn-sub-action:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
}

/* Terminal Screen & Hardware Indicators */
.sim-right-panel {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.reader-hardware-leds {
    display: flex;
    align-items: center;
    gap: 6px;
}

.hw-led {
    font-family: monospace;
    font-size: 9px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: all 0.2s ease;
}

.hw-led.active.led-pwr {
    background: rgba(52, 211, 153, 0.2);
    color: var(--emerald);
    border-color: var(--emerald);
    box-shadow: 0 0 8px rgba(52, 211, 153, 0.4);
}

.hw-led.active.led-rf {
    background: rgba(56, 189, 248, 0.2);
    color: var(--cyan);
    border-color: var(--cyan);
    box-shadow: 0 0 8px rgba(56, 189, 248, 0.4);
}

.hw-led.active.led-act {
    background: rgba(251, 191, 36, 0.3);
    color: var(--amber);
    border-color: var(--amber);
    box-shadow: 0 0 10px rgba(251, 191, 36, 0.6);
}

/* Terminal Tabs */
.terminal-tab-bar {
    display: flex;
    align-items: center;
    gap: 6px;
    border-bottom: 1px solid var(--border-glass);
    padding-bottom: 8px;
}

.term-tab {
    padding: 5px 12px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    color: var(--text-muted);
    cursor: pointer;
    background: transparent;
    transition: all var(--transition-fast);
}

.term-tab:hover {
    color: var(--text-primary);
}

.term-tab.active {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    font-weight: 600;
}

.term-tab.clear-btn {
    margin-left: auto;
    font-size: 11px;
    opacity: 0.7;
}

.term-tab.clear-btn:hover {
    opacity: 1;
    color: #f87171;
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    font-weight: 600;
    color: var(--emerald);
}

.blink-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--emerald);
    box-shadow: 0 0 10px var(--emerald);
    animation: blinkPulse 1.5s infinite;
}

.blink-dot.warning {
    background: var(--amber);
    box-shadow: 0 0 12px var(--amber);
}

.blink-dot.error {
    background: #ef4444;
    box-shadow: 0 0 12px #ef4444;
}

.terminal-screen {
    background: #020612;
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
    padding: 18px;
    font-family: 'Consolas', 'Courier New', monospace;
    font-size: 12px;
    line-height: 1.8;
    height: 250px;
    overflow-y: auto;
    box-shadow: inset 0 4px 14px rgba(0, 0, 0, 0.7);
}

.terminal-json-view {
    background: #03081a;
}

.json-code {
    color: #38bdf8;
    font-family: 'Consolas', monospace;
    font-size: 11px;
    line-height: 1.6;
    margin: 0;
    white-space: pre-wrap;
}

.terminal-line {
    animation: fadeIn 0.3s ease;
    word-break: break-all;
}

.text-muted { color: #64748b; }
.text-info { color: #38bdf8; }
.text-success { color: #34d399; }
.text-warn { color: #fbbf24; }
.text-cyan { color: #38bdf8; }

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}

.sim-live-metrics {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.metric-box {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
    padding: 14px 16px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.metric-box small {
    font-size: 10px;
    color: var(--text-muted);
    letter-spacing: 0.1em;
    font-weight: 700;
}

.metric-box strong {
    font-family: var(--font-heading);
    font-size: 18px;
    color: #fff;
}

/* ==========================================================================
   BENTO GRID FEATURES SECTION
   ========================================================================== */
.features-section {
    padding: 120px 0;
    position: relative;
    z-index: 2;
}

.bento-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.bento-card {
    position: relative;
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-xl);
    padding: 38px 34px;
    backdrop-filter: blur(16px);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 380px;
    transition: transform var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.bento-card:hover {
    transform: translateY(-6px);
    border-color: var(--border-highlight);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
}

.bento-wide {
    grid-column: span 2;
}

.bento-glow {
    position: absolute;
    top: -50px;
    right: -50px;
    width: 220px;
    height: 220px;
    border-radius: 50%;
    pointer-events: none;
    filter: blur(50px);
    opacity: 0.25;
}

.bento-cyan .bento-glow { background: var(--cyan); }
.bento-emerald .bento-glow { background: var(--emerald); }
.bento-amber .bento-glow { background: var(--amber); }
.bento-purple .bento-glow { background: var(--purple); }
.bento-dark .bento-glow { background: #1e3a8a; }

.bento-tag {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.14em;
    color: var(--cyan);
    margin-bottom: 14px;
}

.bento-emerald .bento-tag { color: var(--emerald); }
.bento-amber .bento-tag { color: var(--amber); }
.bento-purple .bento-tag { color: var(--purple); }

.bento-content h3 {
    font-family: var(--font-heading);
    font-size: 24px;
    font-weight: 600;
    line-height: 1.25;
    margin-bottom: 14px;
    color: #fff;
}

.bento-content p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 18px;
}

.bento-features {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
    font-size: 13px;
    color: var(--text-muted);
}

/* Bento Visuals */
.bento-visual {
    position: relative;
    height: 140px;
    margin-top: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Visual NFC Rings */
.visual-nfc {
    height: 160px;
}

.rf-ring {
    position: absolute;
    border-radius: 50%;
    border: 1px solid rgba(56, 189, 248, 0.25);
    animation: ringPulse 4s infinite linear;
}

.ring-lg { width: 180px; height: 180px; }
.ring-md { width: 130px; height: 130px; animation-delay: -1.3s; }
.ring-sm { width: 80px; height: 80px; animation-delay: -2.6s; }

.rf-core {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 12px 18px;
    border-radius: var(--radius-sm);
    background: rgba(10, 17, 40, 0.85);
    border: 1px solid var(--border-highlight);
    box-shadow: 0 0 24px rgba(56, 189, 248, 0.3);
}

.rf-core span { font-size: 10px; color: var(--cyan); font-weight: 700; }
.rf-core b { font-size: 12px; color: #fff; font-family: monospace; }

@keyframes ringPulse {
    0% { transform: scale(0.85); opacity: 0.7; }
    50% { transform: scale(1.1); opacity: 0.2; }
    100% { transform: scale(0.85); opacity: 0.7; }
}

/* Merit Badge Visual */
.merit-badge-3d {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 18px 24px;
    border-radius: var(--radius-md);
    background: linear-gradient(135deg, rgba(52, 211, 153, 0.15), rgba(5, 150, 105, 0.25));
    border: 1px solid rgba(52, 211, 153, 0.35);
    box-shadow: 0 0 30px rgba(52, 211, 153, 0.2);
}

.badge-star { font-size: 28px; color: var(--emerald); }
.merit-badge-3d b { font-family: var(--font-heading); font-size: 26px; color: #fff; }
.merit-badge-3d small { font-size: 11px; color: var(--text-muted); }

/* Chat Bubbles Visual */
.chat-bubble-stack {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}

.bubble {
    padding: 10px 16px;
    border-radius: var(--radius-md);
    font-size: 12px;
    color: #fff;
    backdrop-filter: blur(8px);
}

.bubble-1 {
    background: rgba(251, 191, 36, 0.15);
    border: 1px solid rgba(251, 191, 36, 0.3);
    align-self: flex-start;
}

.bubble-2 {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--border-glass);
    align-self: flex-end;
}

/* Chart Bars Visual */
.bar-chart-mock {
    display: flex;
    align-items: flex-end;
    gap: 12px;
    height: 100px;
    width: 160px;
}

.bar-chart-mock span {
    flex: 1;
    background: linear-gradient(to top, #7c3aed, #c084fc);
    border-radius: 4px 4px 0 0;
    transition: height 0.5s ease;
}

/* Command Matrix Visual */
.matrix-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    width: 120px;
}

.matrix-cell {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
}

.matrix-cell.active {
    background: rgba(56, 189, 248, 0.25);
    border-color: var(--cyan);
    box-shadow: 0 0 12px rgba(56, 189, 248, 0.35);
}

.command-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 14px;
}

.pill {
    padding: 6px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    font-size: 12px;
    color: var(--text-secondary);
}

/* ==========================================================================
   ROLE-BASED ECOSYSTEM SECTION
   ========================================================================== */
.roles-section {
    padding: 120px 0;
    position: relative;
    z-index: 2;
}

.roles-tab-container {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.tab-nav {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.tab-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 22px;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-glass);
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 600;
    transition: all var(--transition-fast);
}

.tab-btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
}

.tab-btn.active {
    color: #fff;
    background: rgba(56, 189, 248, 0.12);
    border-color: var(--cyan);
    box-shadow: 0 0 20px rgba(56, 189, 248, 0.2);
}

.tab-icon {
    font-size: 18px;
}

.role-panel {
    display: none;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    animation: fadeIn 0.4s ease;
}

.role-panel.active {
    display: grid;
}

.role-info {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.role-badge {
    font-size: 12px;
    font-weight: 700;
    color: var(--cyan);
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.role-info h3 {
    font-family: var(--font-heading);
    font-size: clamp(28px, 3.5vw, 42px);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.025em;
    color: #fff;
}

.role-info p {
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.7;
}

.role-highlights {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin: 10px 0;
}

.highlight-item {
    display: flex;
    flex-direction: column;
    padding: 16px;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-glass);
}

.highlight-item strong {
    font-family: var(--font-heading);
    font-size: 22px;
    color: #fff;
}

.highlight-item span {
    font-size: 12px;
    color: var(--text-muted);
}

/* Mock Dashboard Cards */
.role-card-mock {
    padding: 32px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.mock-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    font-weight: 600;
    color: #fff;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--border-glass);
}

.badge-chip {
    padding: 3px 8px;
    border-radius: 999px;
    background: rgba(56, 189, 248, 0.15);
    color: var(--cyan);
    font-size: 10px;
    font-weight: 700;
}

.badge-chip.success {
    background: rgba(52, 211, 153, 0.15);
    color: var(--emerald);
}

.mock-stats-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.m-stat {
    display: flex;
    flex-direction: column;
}

.m-stat small {
    font-size: 11px;
    color: var(--text-muted);
}

.m-stat b {
    font-family: var(--font-heading);
    font-size: 20px;
    color: #fff;
}

.mock-graph {
    height: 8px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    overflow: hidden;
}

.graph-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--cyan), var(--emerald));
    border-radius: 8px;
}

.roster-list, .gateway-list, .notif-stream {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.roster-row, .gw-row, .stream-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.03);
    font-size: 13px;
}

.badge-green { color: var(--emerald); font-weight: 600; }
.badge-gold { color: var(--amber); font-weight: 600; }

/* ==========================================================================
   METRICS & IMPACT SECTION
   ========================================================================= */
.metrics-section {
    padding: 80px 0;
    position: relative;
    z-index: 2;
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.metric-card {
    padding: 32px 24px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: transform var(--transition-fast);
}

.metric-card:hover {
    transform: translateY(-4px);
}

.metric-icon {
    font-size: 32px;
    margin-bottom: 12px;
}

.metric-number {
    font-family: var(--font-heading);
    font-size: clamp(32px, 3.2vw, 44px);
    font-weight: 700;
    color: #fff;
    line-height: 1.1;
    margin-bottom: 8px;
}

.metric-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.metric-desc {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.6;
}

/* ==========================================================================
   FAQ SECTION
   ========================================================================== */
.faq-section {
    padding: 120px 0;
    position: relative;
    z-index: 2;
}

.faq-accordion {
    max-width: 820px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.faq-item {
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
    overflow: hidden;
    backdrop-filter: blur(14px);
    transition: border-color var(--transition-fast);
}

.faq-item[open] {
    border-color: var(--border-highlight);
}

.faq-question {
    padding: 22px 28px;
    font-size: 16px;
    font-weight: 600;
    color: #fff;
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    user-select: none;
}

.faq-question::-webkit-details-marker {
    display: none;
}

.faq-toggle-icon {
    font-size: 20px;
    color: var(--cyan);
    transition: transform 0.25s ease;
}

.faq-item[open] .faq-toggle-icon {
    transform: rotate(45deg);
}

.faq-answer {
    padding: 0 28px 24px;
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.75;
}

/* ==========================================================================
   FINAL CTA BANNER
   ========================================================================== */
.final-cta-section {
    padding: 80px 0 140px;
    position: relative;
    z-index: 2;
}

.cta-banner-card {
    position: relative;
    padding: 72px 64px;
    text-align: center;
    overflow: hidden;
    border: 1px solid var(--border-highlight);
}

.cta-glow-bg {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 50%, rgba(56, 189, 248, 0.2) 0%, rgba(37, 99, 235, 0.05) 60%, transparent 100%);
    pointer-events: none;
}

.cta-text {
    position: relative;
    z-index: 2;
    max-width: 680px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.cta-text h2 {
    font-family: var(--font-heading);
    font-size: clamp(34px, 4vw, 50px);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.03em;
    color: #fff;
}

.cta-text p {
    font-size: 16px;
    color: var(--text-secondary);
    line-height: 1.7;
}

.cta-btn-group {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 10px;
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.site-footer {
    position: relative;
    z-index: 2;
    padding-bottom: 48px;
    border-top: 1px solid var(--border-glass);
    padding-top: 60px;
}

.footer-top {
    display: grid;
    grid-template-columns: 1.4fr 2fr;
    gap: 60px;
    margin-bottom: 60px;
}

.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.footer-tagline {
    font-size: 13px;
    color: var(--text-muted);
    max-width: 340px;
    line-height: 1.7;
}

.system-status {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(52, 211, 153, 0.08);
    border: 1px solid rgba(52, 211, 153, 0.2);
    font-size: 11px;
    color: var(--emerald);
    font-weight: 600;
    width: fit-content;
}

.status-pulse {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--emerald);
    box-shadow: 0 0 8px var(--emerald);
    animation: blinkPulse 2s infinite;
}

.footer-links-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.footer-col {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-col h4 {
    font-family: var(--font-heading);
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    margin-bottom: 4px;
}

.footer-col a {
    font-size: 13px;
    color: var(--text-muted);
}

.footer-col a:hover {
    color: var(--cyan);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 32px;
    border-top: 1px solid rgba(255, 255, 255, 0.04);
    font-size: 12px;
    color: var(--text-muted);
    flex-wrap: wrap;
    gap: 16px;
}

.footer-bottom-links {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* ==========================================================================
   SCROLL REVEAL UTILITY
   ========================================================================== */
[data-reveal] {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: opacity, transform;
}

[data-reveal].is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ==========================================================================
   RESPONSIVE DESIGN BREAKPOINTS
   ========================================================================== */
@media (max-width: 1024px) {
    .hero-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .hero-hud-col {
        display: none; /* Hide floating HUD cards on tablet/mobile so 3D canvas and text shine */
    }

    .bento-container {
        grid-template-columns: 1fr;
    }

    .bento-wide {
        grid-column: span 1;
    }

    .simulator-container {
        grid-template-columns: 1fr;
    }

    .role-panel {
        grid-template-columns: 1fr;
    }

    .metrics-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-top {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 900px) {
    .footer-links-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 768px) {
    .content-width {
        width: calc(100% - 32px);
    }

    .desktop-nav, #navLoginBtn {
        display: none;
    }

    .mobile-toggle {
        display: flex;
    }

    .hero-3d-section {
        min-height: auto;
        padding-top: 100px;
        padding-bottom: 40px;
    }

    .hero-cta-row {
        flex-direction: column;
        align-items: stretch;
    }

    .hero-cta-row .btn-secondary {
        align-self: center;
    }

    .telemetry-bar {
        width: 100%;
        justify-content: space-around;
        padding: 14px;
        gap: 12px;
    }

    .canvas-hud {
        padding: 85px 20px 20px;
    }

    .hud-pill {
        max-width: 100%;
    }

    .hud-pill > span:last-child {
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .canvas-tools {
        display: none; /* Hide tool buttons on small mobile */
    }

    .simulator-container {
        padding: 20px 16px;
    }

    .checkpoint-options {
        grid-template-columns: 1fr;
    }

    .sim-sub-actions {
        grid-template-columns: 1fr;
    }

    .sim-live-metrics {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .cta-banner-card {
        padding: 40px 24px;
    }

    .cta-btn-group {
        flex-direction: column;
        width: 100%;
    }

    .metrics-grid {
        grid-template-columns: 1fr;
    }

    .footer-links-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
}

@media (max-width: 480px) {
    .telemetry-bar {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
        padding: 12px 10px;
    }

    .telemetry-divider {
        display: none;
    }

    .telemetry-item {
        min-width: 0;
        align-items: center;
        text-align: center;
    }

    .tele-val {
        font-size: 20px;
    }

    .tele-label {
        font-size: 10px;
        letter-spacing: 0.03em;
    }

    .tab-nav {
        gap: 8px;
    }

    .tab-btn {
        gap: 7px;
        padding: 8px 14px;
        font-size: 13px;
    }

    .faq-question {
        padding: 18px 20px;
    }

    .faq-answer {
        padding: 0 20px 20px;
    }
}

/* Reduced Motion Mode */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* ==========================================================================
   LANGUAGE SWITCHER BUTTON
   ========================================================================== */
.lang-switcher-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-fast);
    backdrop-filter: blur(10px);
}

.lang-switcher-btn:hover {
    background: rgba(56, 189, 248, 0.14);
    border-color: var(--border-highlight);
    color: var(--cyan);
    box-shadow: 0 0 16px rgba(56, 189, 248, 0.22);
}

.lang-switcher-btn .lang-flag {
    font-size: 16px;
    line-height: 1;
}

/* ==========================================================================
   ACTIVE SUBSCRIPTION PLANS (PRICING) SECTION
   ========================================================================== */
.pricing-section {
    padding: 100px 0;
    position: relative;
    z-index: 2;
}

.pricing-toggle-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin: 32px 0 52px;
}

.toggle-label {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    transition: color var(--transition-fast);
}

.toggle-label.active {
    color: #fff;
}

.pricing-switch {
    position: relative;
    width: 60px;
    height: 32px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--border-glass);
    border-radius: 999px;
    cursor: pointer;
    transition: background var(--transition-fast), border-color var(--transition-fast);
}

.pricing-switch.active {
    background: linear-gradient(135deg, #0284c7, #2563eb);
    border-color: var(--border-highlight);
}

.switch-handle {
    position: absolute;
    top: 4px;
    left: 4px;
    width: 22px;
    height: 22px;
    background: #fff;
    border-radius: 50%;
    transition: transform var(--transition-fast);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
}

.pricing-switch.active .switch-handle {
    transform: translateX(28px);
}

html[dir="rtl"] .pricing-switch.active .switch-handle {
    transform: translateX(-28px);
}

.discount-pill {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(52, 211, 153, 0.15);
    border: 1px solid rgba(52, 211, 153, 0.35);
    color: var(--emerald);
    font-size: 12px;
    font-weight: 700;
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
    align-items: stretch;
    margin-bottom: 40px;
}

.plan-card {
    position: relative;
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-xl);
    padding: 38px 30px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transition: transform var(--transition-smooth), border-color var(--transition-smooth), box-shadow var(--transition-smooth);
    overflow: hidden;
}

.plan-card:hover {
    transform: translateY(-8px);
    border-color: var(--border-highlight);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4), 0 0 30px var(--cyan-glow);
}

.plan-card.popular {
    background: linear-gradient(180deg, rgba(14, 34, 76, 0.88) 0%, rgba(8, 18, 44, 0.96) 100%);
    border: 1.5px solid var(--cyan);
    box-shadow: 0 12px 35px rgba(2, 132, 199, 0.25), 0 0 25px rgba(56, 189, 248, 0.2);
    transform: scale(1.03);
    z-index: 2;
}

.plan-card.popular:hover {
    transform: scale(1.03) translateY(-8px);
    box-shadow: 0 20px 50px rgba(2, 132, 199, 0.35), 0 0 35px rgba(56, 189, 248, 0.3);
}

.popular-ribbon {
    position: absolute;
    top: 18px;
    right: 20px;
    padding: 4px 12px;
    background: linear-gradient(135deg, #0284c7, #38bdf8);
    color: #040816;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    border-radius: 999px;
    box-shadow: 0 0 14px rgba(56, 189, 248, 0.5);
}

html[dir="rtl"] .popular-ribbon {
    right: auto;
    left: 20px;
}

.plan-header {
    margin-bottom: 24px;
}

.plan-title {
    font-family: var(--font-heading);
    font-size: 22px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 8px;
}

.plan-desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.5;
    min-height: 42px;
}

.plan-pricing-box {
    margin-bottom: 28px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border-glass);
}

.price-amount-row {
    display: flex;
    align-items: baseline;
    gap: 6px;
}

.price-currency {
    font-size: 24px;
    font-weight: 700;
    color: var(--cyan);
}

.price-val {
    font-family: var(--font-heading);
    font-size: 46px;
    font-weight: 800;
    color: #fff;
    letter-spacing: -0.03em;
    line-height: 1;
}

.price-period {
    font-size: 14px;
    color: var(--text-muted);
}

.price-billing-note {
    display: block;
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 6px;
}

.plan-features-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-bottom: 32px;
    flex-grow: 1;
}

.plan-features-list li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 14px;
    color: var(--text-primary);
    line-height: 1.4;
}

.feat-check {
    color: var(--cyan);
    font-size: 15px;
    line-height: 1.3;
    flex-shrink: 0;
}

.plan-cta-btn {
    width: 100%;
    padding: 13px 20px;
    text-align: center;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all var(--transition-fast);
}

.plan-cta-btn.popular-btn {
    background: linear-gradient(135deg, #0284c7 0%, #2563eb 100%);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 18px rgba(37, 99, 235, 0.4);
}

.plan-cta-btn.popular-btn:hover {
    box-shadow: 0 8px 25px rgba(37, 99, 235, 0.6);
    transform: translateY(-2px);
}

.plan-cta-btn.standard-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    color: #fff;
}

.plan-cta-btn.standard-btn:hover {
    background: rgba(56, 189, 248, 0.15);
    border-color: var(--border-highlight);
    color: var(--cyan);
    transform: translateY(-2px);
}

.enterprise-custom-card {
    background: linear-gradient(135deg, rgba(13, 23, 52, 0.8), rgba(20, 36, 78, 0.6));
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    padding: 28px 36px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 36px;
    backdrop-filter: blur(16px);
}

.enterprise-info h4 {
    font-size: 18px;
    color: #fff;
    margin-bottom: 4px;
    font-family: var(--font-heading);
}

.enterprise-info p {
    font-size: 14px;
    color: var(--text-secondary);
}

.pricing-guarantees {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-top: 24px;
}

.guarantee-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
}

.guarantee-icon {
    font-size: 24px;
    flex-shrink: 0;
}

.guarantee-text strong {
    display: block;
    font-size: 13px;
    color: #fff;
}

.guarantee-text span {
    font-size: 11px;
    color: var(--text-muted);
}

@media (max-width: 1024px) {
    .pricing-grid {
        grid-template-columns: 1fr;
        max-width: 560px;
        margin-left: auto;
        margin-right: auto;
    }
    .plan-card.popular {
        transform: none;
    }
    .plan-card.popular:hover {
        transform: translateY(-8px);
    }
    .pricing-guarantees {
        grid-template-columns: repeat(2, 1fr);
    }
    .enterprise-custom-card {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 640px) {
    .pricing-guarantees {
        grid-template-columns: 1fr;
    }
}

/* ==========================================================================
   RTL (ARABIC) LOCALIZATION STYLES
   ========================================================================== */
html[dir="rtl"] {
    direction: rtl;
    text-align: right;
}

html[dir="rtl"], html[dir="rtl"] body {
    font-family: 'Cairo', 'Plus Jakarta Sans', sans-serif;
}

html[dir="rtl"] h1, 
html[dir="rtl"] h2, 
html[dir="rtl"] h3, 
html[dir="rtl"] h4,
html[dir="rtl"] .brand-title,
html[dir="rtl"] .price-val {
    font-family: 'Cairo', 'Space Grotesk', sans-serif;
    letter-spacing: normal;
}

html[dir="rtl"] .btn-arrow {
    transform: scaleX(-1);
}

html[dir="rtl"] .hero-cta-row .btn-arrow {
    transform: scaleX(-1);
}

html[dir="rtl"] .telemetry-divider {
    transform: scaleX(-1);
}

html[dir="rtl"] .canvas-hud {
    direction: rtl;
}

html[dir="rtl"] .top-pill {
    left: auto;
    right: 24px;
}

html[dir="rtl"] .canvas-tools {
    right: auto;
    left: 24px;
}

html[dir="rtl"] .hud-card-header {
    text-align: right;
}

html[dir="rtl"] .bento-features li,
html[dir="rtl"] .plan-features-list li {
    text-align: right;
}

html[dir="rtl"] .roster-row,
html[dir="rtl"] .gw-row,
html[dir="rtl"] .mock-stats-row {
    direction: rtl;
}

html[dir="rtl"] .terminal-tab-bar {
    direction: rtl;
}

html[dir="rtl"] .terminal-screen:not(.terminal-json-view) {
    direction: rtl;
    text-align: right;
}

html[dir="rtl"] .terminal-json-view {
    direction: ltr;
    text-align: left;
}

html[dir="rtl"] .faq-question {
    text-align: right;
}

html[dir="rtl"] .faq-toggle-icon {
    margin-right: auto;
    margin-left: 0;
}

html[dir="rtl"] .footer-top {
    direction: rtl;
}

html[dir="rtl"] .footer-bottom {
    direction: rtl;
}

