/* ========================================
   Shroudbyte — Digital Ghost Theme
   Electric teal on rich black
   Clash Display + General Sans (Fontshare)
   ======================================== */

:root {
    --bg:          #06060a;
    --bg-surface:  #0c0d14;
    --bg-card:     #12131c;
    --bg-card-alt: #161822;
    --bg-hover:    #1c1e2c;
    --border:      rgba(255,255,255,0.06);
    --border-lit:  rgba(255,255,255,0.1);
    --teal:        #00e5c3;
    --teal-dim:    #00b89c;
    --teal-glow:   rgba(0,229,195,0.12);
    --teal-deep:   rgba(0,229,195,0.06);
    --purple:      #a78bfa;
    --purple-glow: rgba(167,139,250,0.12);
    --amber:       #f59e0b;
    --amber-glow:  rgba(245,158,11,0.12);
    --coral:       #ff6b6b;
    --coral-glow:  rgba(255,107,107,0.12);
    --rose:        #f472b6;
    --rose-glow:   rgba(244,114,182,0.12);
    --blue:        #60a5fa;
    --blue-glow:   rgba(96,165,250,0.12);
    --green:       #34d399;
    --green-glow:  rgba(52,211,153,0.12);
    --text:        #e8e8ef;
    --text-dim:    #8a8a9e;
    --text-faint:  #7b7b98;
    --display:     'Clash Display', system-ui, sans-serif;
    --body:        'General Sans', system-ui, sans-serif;
    --mono:        'JetBrains Mono', ui-monospace, monospace;
    --radius-sm:   8px;
    --radius:      14px;
    --radius-lg:   20px;
    --radius-xl:   28px;
}

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

html { scroll-behavior: smooth; scroll-padding-top: 80px; }

body {
    font-family: var(--body);
    background: var(--bg);
    color: var(--text);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

a { color: var(--teal); text-decoration: none; transition: color .2s; }
a:hover { color: #33f0d4; }

:focus-visible {
    outline: 2px solid var(--teal);
    outline-offset: 2px;
    border-radius: 4px;
}
a:focus:not(:focus-visible),
button:focus:not(:focus-visible) { outline: none; }

code {
    font-family: var(--mono);
    font-size: 0.82em;
    background: var(--bg-hover);
    padding: 0.15em 0.45em;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    color: var(--teal);
}

.container { max-width: 1200px; margin: 0 auto; padding: 0 28px; }

.skip-link {
    position: absolute;
    top: -100%;
    left: 16px;
    background: var(--teal);
    color: var(--bg);
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    z-index: 9999;
}
.skip-link:focus { top: 16px; }

.accent { color: var(--teal); }

/* ====== PARTICLE CANVAS ====== */
#particle-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    opacity: 0.6;
}

/* ====== NAV ====== */
.nav {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 1000;
    padding: 18px 0;
    transition: all .3s ease;
}
.nav.scrolled {
    background: rgba(6, 6, 10, 0.92);
    backdrop-filter: blur(24px) saturate(1.3);
    -webkit-backdrop-filter: blur(24px) saturate(1.3);
    border-bottom: 1px solid var(--border);
    padding: 12px 0;
}
.nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.nav-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: var(--display);
    font-weight: 600;
    font-size: 1.2rem;
    color: var(--text);
    letter-spacing: -0.02em;
}
.nav-logo:hover { color: var(--text); }
.logo-glyph {
    filter: drop-shadow(0 0 12px rgba(0,229,195,0.3));
    transition: filter .3s;
}
.nav-logo:hover .logo-glyph {
    filter: drop-shadow(0 0 20px rgba(0,229,195,0.5));
}
.nav-links {
    display: flex;
    align-items: center;
    gap: 36px;
}
.nav-links a {
    color: var(--text-dim);
    font-size: 0.88rem;
    font-weight: 500;
    transition: color .2s;
    position: relative;
}
.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0; right: 0;
    height: 2px;
    background: var(--teal);
    border-radius: 1px;
    transform: scaleX(0);
    transition: transform .2s;
}
.nav-links a:hover { color: var(--text); }
.nav-links a.active { color: var(--teal); }
.nav-links a.active::after,
.nav-links a:hover::after { transform: scaleX(1); }

.nav-github {
    display: inline-flex !important;
    align-items: center;
    gap: 6px;
    background: var(--bg-card);
    color: var(--text) !important;
    padding: 8px 18px;
    border-radius: 10px;
    border: 1px solid var(--border);
    font-size: 0.85rem !important;
    transition: all .2s;
}
.nav-github::after { display: none !important; }
.nav-github:hover {
    background: var(--bg-hover);
    border-color: var(--border-lit);
    transform: translateY(-1px);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}
.nav-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text);
    border-radius: 2px;
    transition: all .3s;
}
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nav-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(4px);
    z-index: 998;
}
.nav-overlay.open { display: block; }

/* ====== HERO ====== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 120px 28px 60px;
    overflow: hidden;
    z-index: 1;
}
.hero-bg {
    position: absolute;
    inset: 0;
    z-index: -1;
}
.hero-grid-pattern {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(0,229,195,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0,229,195,0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, black 20%, transparent 70%);
    -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, black 20%, transparent 70%);
}
.hero-radial {
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 50% 40% at 50% 30%, rgba(0,229,195,0.08) 0%, transparent 70%);
}
.hero-noise {
    position: absolute;
    inset: 0;
    opacity: 0.35;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
    background-repeat: repeat;
    background-size: 256px;
}

.hero-content {
    text-align: center;
    max-width: 780px;
    margin: 0 auto;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--teal-deep);
    border: 1px solid rgba(0,229,195,0.15);
    color: var(--teal);
    padding: 6px 18px;
    border-radius: 100px;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    margin-bottom: 36px;
    animation: fadeInUp 0.8s ease both;
}
.badge-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--teal);
    animation: pulse-dot 2s ease infinite;
}
@keyframes pulse-dot {
    0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(0,229,195,0.4); }
    50% { opacity: 0.7; box-shadow: 0 0 0 6px rgba(0,229,195,0); }
}

.hero-title {
    font-family: var(--display);
    font-size: clamp(2.8rem, 6.5vw, 5.2rem);
    font-weight: 600;
    line-height: 1.18;
    letter-spacing: -0.01em;
    margin-bottom: 28px;
}
.title-line {
    display: block;
    animation: fadeInUp 0.8s ease both;
}
.title-line-1 { animation-delay: 0.1s; color: var(--text-dim); }
.title-line-2 {
    animation-delay: 0.25s;
    background: linear-gradient(135deg, var(--teal), #33f0d4, var(--teal-dim));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.title-line-2 em {
    font-style: normal;
    -webkit-text-fill-color: var(--text);
}

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

.hero-sub {
    font-size: 1.12rem;
    color: var(--text-dim);
    line-height: 1.75;
    max-width: 600px;
    margin: 0 auto 40px;
    animation: fadeInUp 0.8s ease 0.5s both;
}

.hero-ctas {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
    animation: fadeInUp 0.8s ease 0.6s both;
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: var(--teal);
    color: var(--bg);
    padding: 14px 32px;
    border-radius: 12px;
    font-family: var(--body);
    font-weight: 600;
    font-size: 0.95rem;
    transition: all .25s;
    box-shadow: 0 0 0 0 rgba(0,229,195,0), 0 4px 20px rgba(0,229,195,0.2);
}
.btn-primary:hover {
    background: #33f0d4;
    color: var(--bg);
    transform: translateY(-2px);
    box-shadow: 0 0 30px rgba(0,229,195,0.25), 0 8px 30px rgba(0,229,195,0.3);
}

.btn-ghost {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    color: var(--text);
    padding: 14px 28px;
    border-radius: 12px;
    font-weight: 500;
    font-size: 0.95rem;
    border: 1px solid var(--border-lit);
    transition: all .25s;
}
.btn-ghost:hover {
    color: var(--text);
    border-color: var(--teal);
    background: var(--teal-deep);
    transform: translateY(-2px);
}

/* ====== HERO VIZ ====== */
.hero-viz {
    position: relative;
    width: 320px;
    height: 320px;
    margin: 60px auto 0;
    animation: fadeInUp 0.8s ease 0.7s both;
}
.viz-shield {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.shield-svg {
    width: 100px;
    height: 116px;
    filter: drop-shadow(0 0 30px rgba(0,229,195,0.2));
    animation: shield-breathe 3s ease-in-out infinite;
}
@keyframes shield-breathe {
    0%, 100% { filter: drop-shadow(0 0 20px rgba(0,229,195,0.2)); }
    50% { filter: drop-shadow(0 0 40px rgba(0,229,195,0.35)); }
}
.shield-counter {
    text-align: center;
    margin-top: -8px;
}
.counter-num {
    display: block;
    font-family: var(--display);
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--teal);
    line-height: 1;
}
.counter-label {
    font-size: 0.65rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.tracker-field {
    position: absolute;
    inset: 0;
    z-index: 1;
}

.tracker-blob {
    position: absolute;
    background: rgba(255,107,107,0.12);
    border: 1px solid rgba(255,107,107,0.25);
    color: var(--coral);
    font-family: var(--mono);
    font-size: 0.6rem;
    padding: 3px 8px;
    border-radius: 6px;
    white-space: nowrap;
    animation: tracker-in 1.2s ease forwards;
    pointer-events: none;
}
.tracker-blob.zapped {
    animation: tracker-zap 0.6s ease forwards;
}

@keyframes tracker-in {
    from { opacity: 0; scale: 0.5; }
    to { opacity: 1; scale: 1; translate: var(--tx) var(--ty); }
}
@keyframes tracker-zap {
    0% { opacity: 1; scale: 1; }
    30% { border-color: var(--teal); color: var(--teal); background: var(--teal-glow); scale: 1.2; }
    100% { opacity: 0; scale: 0; filter: blur(4px); }
}

/* ====== HERO STATS ====== */
.hero-stats {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    margin-top: 60px;
    flex-wrap: wrap;
    animation: fadeInUp 0.8s ease 0.8s both;
}
.stat-pill {
    text-align: center;
}
.stat-val {
    display: block;
    font-family: var(--display);
    font-size: 2rem;
    font-weight: 800;
    color: var(--text);
    line-height: 1.1;
}
.stat-lbl {
    font-size: 0.72rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-top: 4px;
    display: block;
}
.stat-divider {
    width: 1px;
    height: 36px;
    background: var(--border-lit);
}

/* ====== SECTIONS ====== */
.section {
    position: relative;
    padding: 120px 0;
    z-index: 1;
}
.section-alt {
    background: var(--bg-surface);
}
.section-alt::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border-lit), transparent);
}
.section-alt::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border-lit), transparent);
}

.section-head {
    text-align: center;
    margin-bottom: 72px;
}
.section-tag {
    display: inline-block;
    font-family: var(--mono);
    font-size: 0.72rem;
    font-weight: 500;
    color: var(--teal);
    text-transform: uppercase;
    letter-spacing: 0.12em;
    margin-bottom: 16px;
    background: var(--teal-deep);
    border: 1px solid rgba(0,229,195,0.12);
    padding: 4px 14px;
    border-radius: 6px;
}
.section-title {
    font-family: var(--display);
    font-size: clamp(2rem, 4vw, 3.2rem);
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: -0.005em;
    margin-bottom: 16px;
}
.section-sub {
    font-size: 1.05rem;
    color: var(--text-dim);
    max-width: 560px;
    margin: 0 auto;
    line-height: 1.7;
}

/* ====== BENTO GRID ====== */
.bento {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}
.bento-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 36px;
    transition: all .35s cubic-bezier(.23,1,.32,1);
    will-change: transform;
}
.bento-card:hover {
    border-color: var(--border-lit);
    box-shadow: 0 8px 40px rgba(0,0,0,0.3);
}
.bento-wide {
    grid-column: span 2;
}
.bento-card h3 {
    font-family: var(--display);
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 10px;
    letter-spacing: -0.01em;
}
.bento-card p {
    font-size: 0.9rem;
    color: var(--text-dim);
    line-height: 1.7;
}

.card-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}
.card-icon-teal  { background: var(--teal-glow); color: var(--teal); }
.card-icon-purple { background: var(--purple-glow); color: var(--purple); }
.card-icon-amber { background: var(--amber-glow); color: var(--amber); }
.card-icon-coral { background: var(--coral-glow); color: var(--coral); }
.card-icon-rose  { background: var(--rose-glow); color: var(--rose); }
.card-icon-blue  { background: var(--blue-glow); color: var(--blue); }
.card-icon-green { background: var(--green-glow); color: var(--green); }

.tracker-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 20px;
}
.tracker-tag {
    font-family: var(--mono);
    font-size: 0.7rem;
    background: var(--bg-hover);
    border: 1px solid var(--border);
    padding: 4px 12px;
    border-radius: 6px;
    color: var(--text-dim);
}
.tracker-tag em {
    font-style: normal;
    color: var(--coral);
    margin-left: 4px;
}
.tag-more {
    color: var(--teal) !important;
    border-color: rgba(0,229,195,0.15);
    background: var(--teal-deep);
}

/* Fingerprint demo */
.fp-demo {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-top: 20px;
}
.fp-item {
    background: var(--bg-hover);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.fp-label {
    font-size: 0.7rem;
    color: var(--text-faint);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.fp-status {
    font-family: var(--mono);
    font-size: 0.75rem;
    color: var(--teal);
}

/* ====== PRIVACY LAYERS ====== */
.layers {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
}
.layer {
    display: flex;
    gap: 32px;
    align-items: flex-start;
    padding: 36px 0;
    position: relative;
}
.layer + .layer {
    border-top: 1px solid var(--border);
}
.layer-number {
    font-family: var(--display);
    font-size: 2.4rem;
    font-weight: 800;
    color: var(--teal);
    opacity: 0.25;
    min-width: 56px;
    line-height: 1;
    padding-top: 4px;
}
.layer-body h3 {
    font-family: var(--display);
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 10px;
}
.layer-body p {
    font-size: 0.9rem;
    color: var(--text-dim);
    line-height: 1.75;
}
.layer-line { display: none; }

/* ====== FILTER GRID ====== */
.filter-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}
.filter-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
    transition: all .25s;
}
.filter-card:hover {
    border-color: var(--border-lit);
    transform: translateY(-2px);
}
.filter-status {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-bottom: 16px;
}
.filter-status.on {
    background: var(--teal);
    box-shadow: 0 0 10px rgba(0,229,195,0.4);
}
.filter-status.off {
    background: var(--text-faint);
}
.filter-card h4 {
    font-family: var(--display);
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 6px;
}
.filter-card p {
    font-size: 0.82rem;
    color: var(--text-dim);
}

/* ====== ARCHITECTURE MOSAIC ====== */
.arch-mosaic {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}
.arch-tile {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    transition: all .25s;
}
.arch-tile:hover {
    border-color: var(--border-lit);
    transform: translateY(-2px);
}
.arch-filename {
    font-family: var(--mono);
    font-size: 0.78rem;
    color: var(--teal);
    background: var(--teal-deep);
    display: inline-block;
    padding: 3px 10px;
    border-radius: 6px;
    margin-bottom: 12px;
    border: 1px solid rgba(0,229,195,0.1);
}
.arch-tile p {
    font-size: 0.82rem;
    color: var(--text-dim);
    line-height: 1.65;
}

.tech-ribbon {
    margin-top: 48px;
    text-align: center;
}
.tech-label {
    font-size: 0.78rem;
    color: var(--text-faint);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    display: block;
    margin-bottom: 12px;
}
.tech-pills {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}
.tech-pill {
    font-family: var(--mono);
    font-size: 0.75rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: 6px 16px;
    border-radius: 8px;
    color: var(--text-dim);
}

/* ====== KEYBOARD SHORTCUTS ====== */
.kb-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}
.kb-group {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
}
.kb-group h4 {
    font-family: var(--display);
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 16px;
    color: var(--teal);
}
.kb-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    font-size: 0.82rem;
    color: var(--text-dim);
}
.kb-row + .kb-row {
    border-top: 1px solid var(--border);
}
.kb-keys {
    display: flex;
    gap: 4px;
}
kbd {
    font-family: var(--mono);
    font-size: 0.68rem;
    background: var(--bg-hover);
    border: 1px solid var(--border-lit);
    border-bottom-width: 2px;
    padding: 3px 8px;
    border-radius: 5px;
    color: var(--text);
    line-height: 1;
}

/* ====== INSTALL TERMINAL ====== */
.terminal-window {
    max-width: 700px;
    margin: 0 auto;
    background: var(--bg-card);
    border: 1px solid var(--border-lit);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0,0,0,0.4);
}
.terminal-bar {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 14px 20px;
    background: var(--bg-card-alt);
    border-bottom: 1px solid var(--border);
}
.terminal-dots {
    display: flex;
    gap: 6px;
}
.terminal-dots span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}
.terminal-dots span:nth-child(1) { background: #ff5f57; }
.terminal-dots span:nth-child(2) { background: #febc2e; }
.terminal-dots span:nth-child(3) { background: #28c840; }
.terminal-title {
    font-family: var(--mono);
    font-size: 0.72rem;
    color: var(--text-faint);
}
.terminal-body {
    padding: 24px;
}
.terminal-line {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    position: relative;
}
.terminal-line + .terminal-line {
    border-top: 1px solid var(--border);
}
.term-prompt {
    font-family: var(--mono);
    color: var(--teal);
    font-weight: 600;
    font-size: 0.85rem;
}
.terminal-line code {
    background: none;
    border: none;
    padding: 0;
    color: var(--text);
    font-size: 0.82rem;
    flex: 1;
}
.terminal-output {
    padding: 10px 0;
    font-family: var(--mono);
    font-size: 0.82rem;
    color: var(--text-dim);
    border-top: 1px solid var(--border);
}
.term-success {
    color: var(--teal);
    margin-right: 6px;
}

.copy-btn {
    background: none;
    border: none;
    color: var(--text-faint);
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: all .2s;
    flex-shrink: 0;
}
.copy-btn:hover { color: var(--teal); }
.copy-btn.copied { color: var(--teal); }

.deps-row {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 36px;
    flex-wrap: wrap;
}
.dep-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 14px 24px;
    display: flex;
    align-items: center;
    gap: 12px;
}
.dep-name {
    font-family: var(--mono);
    font-size: 0.82rem;
    color: var(--text);
}
.dep-ver {
    font-size: 0.75rem;
    color: var(--teal);
}

.extras {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-top: 36px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}
.extra-block {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
}
.extra-block h4 {
    font-family: var(--display);
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 12px;
}
.extra-note {
    font-size: 0.8rem;
    color: var(--text-dim);
    margin-bottom: 12px;
}
.terminal-inline {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--bg-hover);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 10px 14px;
}
.terminal-inline code {
    background: none;
    border: none;
    padding: 0;
    font-size: 0.75rem;
    color: var(--text);
    flex: 1;
    word-break: break-all;
}

/* ====== FILE TREE ====== */
.file-tree-card {
    max-width: 600px;
    margin: 0 auto;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px;
}
.ft-line {
    font-family: var(--mono);
    font-size: 0.82rem;
    padding: 7px 0;
    padding-left: 24px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-dim);
}
.ft-line + .ft-line {
    border-top: 1px solid var(--border);
}
.ft-dir {
    padding-left: 0;
    color: var(--text);
    font-weight: 600;
}
.ft-icon {
    font-size: 0.9rem;
    width: 18px;
    text-align: center;
    flex-shrink: 0;
}
.ft-note {
    margin-left: auto;
    font-size: 0.7rem;
    color: var(--text-faint);
}
.ft-encrypted {
    color: var(--teal);
}

/* ====== FOOTER ====== */
.footer {
    border-top: 1px solid var(--border);
    padding: 48px 0 36px;
    position: relative;
    z-index: 1;
}
.footer-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 28px;
}
.footer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--display);
    font-weight: 600;
    font-size: 1.05rem;
    color: var(--text);
}
.footer-links {
    display: flex;
    gap: 24px;
}
.footer-links a {
    color: var(--text-dim);
    font-size: 0.85rem;
    transition: color .2s;
}
.footer-links a:hover { color: var(--text); }
.footer-bottom {
    border-top: 1px solid var(--border);
    padding-top: 20px;
}
.footer-bottom p {
    font-size: 0.82rem;
    color: var(--text-faint);
    text-align: center;
}

/* ====== SCROLL REVEAL ====== */
.reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ====== RESPONSIVE ====== */
@media (max-width: 1024px) {
    .bento { grid-template-columns: repeat(2, 1fr); }
    .bento-wide { grid-column: span 2; }
    .arch-mosaic { grid-template-columns: repeat(3, 1fr); }
    .kb-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: fixed;
        top: 0; right: 0;
        width: 280px;
        height: 100vh;
        background: var(--bg-surface);
        border-left: 1px solid var(--border);
        flex-direction: column;
        align-items: flex-start;
        padding: 80px 32px 32px;
        gap: 0;
        z-index: 999;
    }
    .nav-links.open { display: flex; }
    .nav-links a {
        width: 100%;
        padding: 14px 0;
        font-size: 1rem;
        border-bottom: 1px solid var(--border);
    }
    .nav-links a::after { display: none; }
    .nav-github { margin-top: 16px; }
    .nav-toggle { display: flex; }

    .hero { min-height: auto; padding: 140px 20px 60px; }
    .hero-title { font-size: 2.4rem; }
    .hero-viz { width: 260px; height: 260px; margin-top: 40px; }

    .section { padding: 80px 0; }
    .section-head { margin-bottom: 48px; }

    .bento { grid-template-columns: 1fr; }
    .bento-wide { grid-column: span 1; }
    .fp-demo { grid-template-columns: repeat(2, 1fr); }

    .filter-grid { grid-template-columns: repeat(2, 1fr); }
    .arch-mosaic { grid-template-columns: repeat(2, 1fr); }
    .kb-grid { grid-template-columns: 1fr; }

    .hero-stats { gap: 16px; }
    .stat-divider { display: none; }
    .stat-val { font-size: 1.5rem; }

    .extras { grid-template-columns: 1fr; }
    .deps-row { flex-direction: column; align-items: center; }

    .footer-top { flex-direction: column; gap: 16px; text-align: center; }
    .footer-links { gap: 16px; }
}

@media (max-width: 480px) {
    .hero-title { font-size: 2rem; }
    .hero-ctas { flex-direction: column; }
    .btn-primary, .btn-ghost { width: 100%; justify-content: center; }
    .filter-grid { grid-template-columns: 1fr; }
    .arch-mosaic { grid-template-columns: 1fr; }
    .fp-demo { grid-template-columns: 1fr; }
    .hero-stats { flex-direction: column; gap: 20px; }
}

/* ====== REDUCED MOTION ====== */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    .reveal { opacity: 1; transform: none; }
    #particle-canvas { display: none; }
}
