/* ═══════════════════════════════════════════════════════════════
   DarkBrew — Website Stylesheet
   Theme: Deep dark + purple/green neon hacker aesthetic
   ═══════════════════════════════════════════════════════════════ */

/* ── Variables ──────────────────────────────────────────────── */
:root {
    /* Core palette — matched to dark beer mug logo */
    --bg-deepest:    #04030a;
    --bg-dark:       #0a0610;
    --bg-card:       #0e0b16;
    --bg-card-hover: #14101e;
    --bg-surface:    #1e1e2e;
    --bg-surface-2:  #1a1525;

    /* Accent colors */
    --purple:        #9b5de5;
    --purple-dim:    #7c3aed;
    --purple-glow:   rgba(124, 58, 237, 0.12);
    --purple-glow-strong: rgba(124, 58, 237, 0.25);
    --green:         #c4b5fd;
    --green-dim:     #a78bfa;
    --green-glow:    rgba(196, 181, 253, 0.10);
    --green-glow-strong: rgba(196, 181, 253, 0.20);
    --cyan:          #8b5cf6;
    --yellow:        #d4a855;
    --red:           #ef4444;

    /* Text */
    --text:          #d5d0e0;
    --text-dim:      #7a7590;
    --text-dimmer:   #4a4560;
    --text-bright:   #f0edf5;

    /* Terminal */
    --term-bg:       #0a0810;
    --term-border:   #1e1a2a;

    /* Spacing */
    --section-pad:   120px;
    --container:     1200px;

    /* Fonts */
    --font-sans:     'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-mono:     'JetBrains Mono', 'SF Mono', 'Fira Code', monospace;

    /* Misc */
    --radius:        12px;
    --radius-sm:     8px;
    --radius-xs:     6px;
    --transition:    0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    scroll-padding-top: 104px;
}

body {
    font-family: var(--font-sans);
    background: var(--bg-deepest);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
}

code {
    font-family: var(--font-mono);
}

/* ── Utility ────────────────────────────────────────────────── */
.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 24px;
}

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

.mono {
    font-family: var(--font-mono);
    color: var(--green);
    font-weight: 500;
}

/* ── NAV ────────────────────────────────────────────────────── */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 16px 0;
    transition: background var(--transition), padding var(--transition), box-shadow var(--transition);
    background: rgba(4, 3, 10, 0);
    backdrop-filter: blur(0) saturate(100%);
    -webkit-backdrop-filter: blur(0) saturate(100%);
    will-change: background, box-shadow;
}

.nav::after {
    content: '';
    position: absolute;
    left: max(24px, calc((100vw - var(--container)) / 2 + 24px));
    right: max(24px, calc((100vw - var(--container)) / 2 + 24px));
    bottom: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(124, 58, 237, 0.18) 18%, rgba(124, 58, 237, 0.18) 82%, transparent);
    opacity: 0;
    transform: scaleX(0.985);
    transform-origin: center;
    transition: opacity var(--transition), transform var(--transition);
    pointer-events: none;
}

.nav.scrolled {
    background: rgba(4, 3, 10, 0.9);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    box-shadow: 0 18px 48px -36px rgba(0, 0, 0, 0.9);
    padding: 10px 0;
}

.nav.scrolled::after {
    opacity: 1;
    transform: scaleX(1);
}

.nav-inner {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 40px;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--text-bright);
}

.nav-logo {
    width: 36px;
    height: 36px;
    border-radius: 8px;
}

.nav-name {
    letter-spacing: -0.02em;
}

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

.nav-links a {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-dim);
    transition: color 0.2s ease;
    position: relative;
}

.nav-links a:hover {
    color: var(--text-bright);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--purple);
    transition: width var(--transition);
}

.nav-links a:hover::after {
    width: 100%;
}

.nav-github {
    display: flex;
    align-items: center;
    color: var(--text-dim) !important;
    transition: color var(--transition) !important;
}

.nav-github:hover {
    color: var(--text-bright) !important;
}

.nav-github::after {
    display: none !important;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    width: 40px;
    height: 40px;
    justify-content: center;
    align-items: center;
}

.nav-toggle span {
    width: 22px;
    height: 2px;
    background: var(--text);
    transition: var(--transition);
    display: block;
    transform-origin: center;
}

/* X animation when open */
.nav-toggle.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.nav-toggle.active span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.nav-toggle.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* ── HERO ───────────────────────────────────────────────────── */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 120px 24px 80px;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.grid-lines {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(124, 58, 237, 0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(124, 58, 237, 0.025) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse 80% 60% at 50% 40%, black 30%, transparent 70%);
    -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 40%, black 30%, transparent 70%);
}

.glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.4;
    will-change: transform;
    contain: strict;
}

.glow-purple {
    width: 600px;
    height: 600px;
    background: var(--purple);
    top: -200px;
    left: 50%;
    transform: translateX(-70%);
    opacity: 0.12;
    animation: float-slow 8s ease-in-out infinite alternate;
}

.glow-green {
    width: 400px;
    height: 400px;
    background: var(--purple-dim);
    bottom: -100px;
    right: -100px;
    opacity: 0.08;
    animation: float-slow 10s ease-in-out infinite alternate-reverse;
}

@keyframes float-slow {
    from { transform: translate(0, 0); }
    to   { transform: translate(30px, -20px); }
}

.particles {
    position: absolute;
    inset: 0;
}

.particle {
    position: absolute;
    width: 2px;
    height: 2px;
    border-radius: 50%;
    opacity: 0;
    animation: particle-float linear infinite;
    will-change: transform, opacity;
    contain: strict;
}

@keyframes particle-float {
    0%   { opacity: 0; transform: translateY(0); }
    10%  { opacity: 0.6; }
    90%  { opacity: 0.6; }
    100% { opacity: 0; transform: translateY(-100vh); }
}

.hero-content {
    position: relative;
    text-align: center;
    max-width: 800px;
    width: min(800px, 100%);
    margin: 0 auto;
}

/* Logo + Title lockup */
.hero-lockup {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    padding: 6px 16px;
    background: var(--purple-glow);
    border: 1px solid rgba(124, 58, 237, 0.2);
    border-radius: 100px;
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--purple);
    margin-bottom: 24px;
    font-family: var(--font-mono);
    line-height: 1.5;
    max-width: min(100%, 460px);
    text-align: center;
    text-wrap: balance;
}

.badge-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 8px var(--green);
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50%      { opacity: 0.4; }
}

.hero-logo {
    width: 100px;
    height: auto;
    border-radius: 0;
    margin-bottom: 0;
    filter: drop-shadow(0 0 30px rgba(124, 58, 237, 0.25));
    animation: logo-glow 4s ease-in-out infinite alternate;
    object-fit: contain;
    flex-shrink: 0;
}

@keyframes logo-glow {
    from { filter: drop-shadow(0 0 20px rgba(124, 58, 237, 0.15)); }
    to   { filter: drop-shadow(0 0 40px rgba(124, 58, 237, 0.35)) drop-shadow(0 0 60px rgba(42, 32, 64, 0.3)); }
}

.hero h1 {
    font-size: clamp(4rem, 10vw, 7rem);
    font-weight: 900;
    letter-spacing: -0.03em;
    line-height: 1;
    margin-bottom: 0;
    text-wrap: balance;
}

.hero-dark {
    color: var(--text-bright);
}

.hero-brew {
    background: linear-gradient(135deg, var(--purple) 0%, var(--green) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-tagline {
    font-size: 1.4rem;
    font-weight: 500;
    color: var(--text-dim);
    margin-bottom: 12px;
    font-family: var(--font-mono);
    text-wrap: balance;
}

.hero-sub {
    font-size: 1.1rem;
    color: var(--text-dim);
    max-width: 550px;
    margin: 0 auto 40px;
    line-height: 1.7;
    text-wrap: pretty;
}

/* Terminal in hero */
.hero-terminal {
    width: min(100%, 600px);
    max-width: 600px;
    margin: 0 auto 40px;
    text-align: left;
    border-radius: var(--radius);
    border: 1px solid var(--term-border);
    overflow: hidden;
    background: var(--term-bg);
    box-shadow:
        0 0 0 1px rgba(124, 58, 237, 0.06),
        0 20px 60px -15px rgba(0, 0, 0, 0.7),
        0 0 30px rgba(124, 58, 237, 0.04);
}

.term-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid var(--term-border);
}

.term-dots {
    display: flex;
    gap: 6px;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.dot.red    { background: #ff5f56; }
.dot.yellow { background: #ffbd2e; }
.dot.green  { background: #27c93f; }

.term-title {
    font-size: 0.75rem;
    color: var(--text-dimmer);
    font-family: var(--font-mono);
}

.term-body {
    padding: 20px 20px 24px;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    line-height: 1.7;
    min-height: 124px;
}

.term-line {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: calc(1.7em * 2);
}

.term-prompt {
    color: var(--green);
    font-weight: 700;
}

.term-cmd {
    color: var(--text-bright);
}

.term-cursor {
    color: var(--green);
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50%      { opacity: 0; }
}

.term-output {
    margin-top: 8px;
    color: var(--text-dim);
    font-size: 0.85rem;
    min-height: 1.7em;
}

.term-output .t-green {
    color: var(--green);
}

/* Hero actions */
.hero-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-bottom: 48px;
    flex-wrap: wrap;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 28px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.95rem;
    transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition), color var(--transition), background var(--transition);
    cursor: pointer;
    border: none;
    will-change: transform;
    min-height: 52px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--purple-dim) 0%, #5b21b6 100%);
    color: #f0edf5;
    box-shadow: 0 0 20px rgba(124, 58, 237, 0.25);
}

.btn-primary:hover {
    box-shadow: 0 0 30px rgba(124, 58, 237, 0.45);
    transform: translateY(-2px);
}

.btn-ghost {
    background: transparent;
    color: var(--text);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-ghost:hover {
    border-color: var(--purple);
    color: var(--purple);
    background: var(--purple-glow);
}

/* Hero stats */
.hero-stats {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 32px;
    flex-wrap: wrap;
    max-width: 720px;
    margin: 0 auto;
}

.stat {
    min-width: 112px;
    text-align: center;
}

.stat-num {
    display: block;
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-bright);
    font-family: var(--font-mono);
    background: linear-gradient(135deg, var(--purple-dim), var(--green));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: 0.8rem;
    color: var(--text-dimmer);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 500;
}

.stat-sep {
    width: 1px;
    height: 40px;
    background: linear-gradient(to bottom, transparent, var(--text-dimmer), transparent);
}

/* ── SECTIONS ───────────────────────────────────────────────── */
.section {
    padding: var(--section-pad) 0;
    position: relative;
    scroll-margin-top: 96px;
}

.section-dark {
    background: var(--bg-dark);
}

.section-header {
    text-align: center;
    margin-bottom: 64px;
}

.section-tag {
    display: block;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--purple);
    margin-bottom: 16px;
    letter-spacing: 0.05em;
}

.section-header h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    color: var(--text-bright);
    line-height: 1.2;
    letter-spacing: -0.02em;
    margin-bottom: 16px;
    text-wrap: balance;
}

.section-sub {
    font-size: 1.1rem;
    color: var(--text-dim);
    max-width: 580px;
    margin: 0 auto;
}

/* ── FEATURES GRID ──────────────────────────────────────────── */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 20px;
}

.feature-card {
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: var(--radius);
    padding: 32px 28px;
    transition: transform var(--transition), background var(--transition), border-color var(--transition), box-shadow var(--transition);
    position: relative;
    overflow: hidden;
    will-change: transform;
    contain: content;
    display: flex;
    flex-direction: column;
    min-height: 100%;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    opacity: 0;
    transition: opacity var(--transition);
}

.feature-glow-purple::before {
    background: linear-gradient(90deg, transparent, var(--purple), transparent);
}

.feature-glow-green::before {
    background: linear-gradient(90deg, transparent, var(--green), transparent);
}

.feature-card:hover {
    background: var(--bg-card-hover);
    border-color: rgba(124, 58, 237, 0.15);
    transform: translateY(-4px);
    box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.6);
}

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

.feature-icon {
    font-size: 1.8rem;
    margin-bottom: 16px;
    color: var(--purple);
}

.feature-icon svg {
    stroke: var(--purple);
    opacity: 0.85;
    transition: opacity 0.2s ease;
}

.feature-card:hover .feature-icon svg {
    opacity: 1;
}

.feature-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text-bright);
    margin-bottom: 8px;
}

.feature-card p {
    font-size: 0.9rem;
    color: var(--text-dim);
    line-height: 1.6;
    margin-bottom: 16px;
}

.feature-card code {
    display: block;
    padding: 8px 14px;
    background: var(--term-bg);
    border: 1px solid var(--term-border);
    border-radius: var(--radius-xs);
    font-size: 0.8rem;
    color: var(--green);
    margin-top: auto;
}

/* ── INSTALL STEPS ──────────────────────────────────────────── */
.install-steps {
    max-width: 700px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.install-step {
    display: flex;
    gap: 24px;
    align-items: flex-start;
}

.step-num {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--purple-glow);
    border: 1px solid rgba(124, 58, 237, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: 1.2rem;
    color: var(--purple);
}

.step-content {
    flex: 1;
}

.step-content h3 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-bright);
    margin-bottom: 6px;
}

.step-content p {
    color: var(--text-dim);
    font-size: 0.95rem;
    margin-bottom: 16px;
}

/* Code blocks */
.code-block {
    border-radius: var(--radius);
    border: 1px solid var(--term-border);
    overflow: hidden;
    background: var(--term-bg);
}

.code-block-lg pre {
    font-size: 1.05rem;
}

.code-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid var(--term-border);
    font-size: 0.75rem;
    color: var(--text-dimmer);
    font-family: var(--font-mono);
}

.copy-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    background: none;
    border: none;
    color: var(--text-dimmer);
    cursor: pointer;
    padding: 4px;
    min-width: 36px;
    min-height: 36px;
    border-radius: 4px;
    transition: color 0.2s ease, background 0.2s ease;
}

.copy-btn:hover {
    color: var(--green);
    background: var(--purple-glow);
}

.copy-btn.copied {
    color: var(--green);
}

.code-block pre {
    padding: 16px 20px;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    line-height: 1.7;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: var(--bg-surface) transparent;
}

.code-block code {
    font-family: inherit;
}

.t-prompt  { color: var(--green); font-weight: 700; }
.t-comment { color: var(--text-dimmer); }
.t-green   { color: var(--green); }
.t-cyan    { color: var(--cyan); }
.t-yellow  { color: var(--yellow); }
.t-red     { color: var(--red); }
.t-dim     { color: var(--text-dimmer); }

/* ── TOOLS SHOWCASE ─────────────────────────────────────────── */
.tools-showcase {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 24px;
}

.tool-category {
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: var(--radius);
    padding: 24px;
    transition: border-color var(--transition);
    contain: content;
    display: flex;
    flex-direction: column;
    min-height: 100%;
}

.tool-category:hover {
    border-color: rgba(124, 58, 237, 0.15);
}

.cat-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
}

.cat-icon {
    font-size: 1.4rem;
    display: flex;
    align-items: center;
    color: var(--purple);
}

.cat-icon svg {
    stroke: var(--purple);
}

.cat-header h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-bright);
}

.tool-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pill {
    display: inline-block;
    padding: 4px 12px;
    background: var(--bg-surface);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 100px;
    font-family: var(--font-mono);
    font-size: 0.78rem;
    color: var(--text-dim);
    transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.pill:hover {
    border-color: var(--purple);
    color: var(--purple);
    background: var(--purple-glow);
}

/* ── COMMANDS GRID ──────────────────────────────────────────── */
.commands-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 24px;
}

.cmd-group {
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: var(--radius);
    padding: 28px;
    display: flex;
    flex-direction: column;
    min-height: 100%;
}

.cmd-group h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-bright);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.cmd-icon {
    stroke: var(--purple);
    flex-shrink: 0;
}

.cmd-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.cmd {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 12px;
    border-radius: var(--radius-xs);
    transition: background 0.2s ease;
}

.cmd:hover {
    background: rgba(124, 58, 237, 0.06);
}

.cmd code {
    font-size: 0.82rem;
    color: var(--green);
    white-space: nowrap;
}

.cmd span {
    font-size: 0.8rem;
    color: var(--text-dimmer);
    text-align: right;
}

/* ── WORKFLOW CARDS ─────────────────────────────────────────── */
.workflow-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(500px, 1fr));
    gap: 24px;
}

.workflow-card {
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: var(--radius);
    overflow: hidden;
    transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
    will-change: transform;
    contain: content;
    display: flex;
    flex-direction: column;
}

.workflow-card:hover {
    border-color: rgba(124, 58, 237, 0.15);
    transform: translateY(-2px);
    box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.6);
}

.wf-header {
    padding: 24px 28px;
    display: flex;
    align-items: center;
    gap: 16px;
    border-bottom: 1px solid var(--term-border);
}

.wf-icon {
    font-size: 2rem;
    display: flex;
    align-items: center;
    color: var(--purple);
}

.wf-icon svg {
    stroke: var(--purple);
}

.wf-header h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text-bright);
    margin-bottom: 4px;
}

.wf-tag {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--purple);
}

.wf-terminal {
    background: var(--term-bg);
    flex: 1;
}

.wf-terminal pre {
    padding: 20px 24px;
    font-family: var(--font-mono);
    font-size: 0.82rem;
    line-height: 1.7;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    color: var(--text-dim);
    min-height: 100%;
}

/* ── CTA ────────────────────────────────────────────────────── */
.section-cta {
    background: var(--bg-dark);
    position: relative;
    overflow: hidden;
}

.section-cta::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(124, 58, 237, 0.15) 0%, transparent 70%);
    pointer-events: none;
}

.cta-content {
    text-align: center;
    position: relative;
}

.cta-content h2 {
    font-size: clamp(2.2rem, 5vw, 3.5rem);
    font-weight: 900;
    color: var(--text-bright);
    line-height: 1.2;
    margin-bottom: 12px;
    text-wrap: balance;
}

.cta-content > p {
    font-size: 1.2rem;
    color: var(--text-dim);
    margin-bottom: 40px;
}

.cta-install {
    max-width: 560px;
    margin: 0 auto 32px;
}

.cta-links {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

/* ── FOOTER ─────────────────────────────────────────────────── */
.footer {
    padding: 40px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.04);
    background: var(--bg-deepest);
}

.footer-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--text-bright);
}

.footer-logo {
    width: 28px;
    height: 28px;
    border-radius: 6px;
}

.footer-ver {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    font-weight: 400;
    color: var(--text-dimmer);
}

.footer-links {
    display: flex;
    gap: 24px;
}

.footer-links a {
    font-size: 0.85rem;
    color: var(--text-dimmer);
    transition: color 0.2s ease;
}

.footer-links a:hover {
    color: var(--purple);
}

.footer-copy {
    font-size: 0.8rem;
    color: var(--text-dimmer);
}

/* ── RESPONSIVE ─────────────────────────────────────────────── */

/* Tablet */
@media (max-width: 1024px) {
    .features-grid,
    .tools-showcase,
    .commands-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    }

    .workflow-cards {
        grid-template-columns: 1fr;
    }
}

/* Mobile landscape / small tablet */
@media (max-width: 768px) {
    :root {
        --section-pad: 80px;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(4, 3, 10, 0.97);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        flex-direction: column;
        padding: 24px 20px;
        gap: 16px;
        border-bottom: 1px solid var(--term-border);
    }

    .nav::after {
        left: 24px;
        right: 24px;
    }

    .nav-links.open {
        display: flex;
    }

    .nav-links a {
        font-size: 1rem;
        padding: 8px 0;
    }

    .nav-links a::after {
        display: none;
    }

    .nav-toggle {
        display: flex;
    }

    .hero {
        padding: 100px 20px 60px;
        min-height: auto;
    }

    .hero-logo {
        width: 72px;
        height: auto;
    }

    .hero-lockup {
        gap: 14px;
    }

    .hero h1 {
        font-size: clamp(2.8rem, 10vw, 4rem);
    }

    .hero-badge {
        font-size: 0.7rem;
        padding: 5px 12px;
    }

    .hero-tagline {
        font-size: 1.15rem;
    }

    .hero-sub {
        font-size: 1rem;
    }

    .hero-sub br {
        display: none;
    }

    .hero-terminal {
        width: 100%;
        margin: 0 auto 32px;
    }

    .term-body {
        padding: 16px;
        font-size: 0.82rem;
        min-height: 104px;
    }

    .hero-stats {
        gap: 20px;
    }

    .stat {
        min-width: 96px;
    }

    .stat-sep {
        display: none;
    }

    .stat-num {
        font-size: 1.6rem;
    }

    .features-grid,
    .tools-showcase,
    .commands-grid {
        grid-template-columns: 1fr;
    }

    .feature-card {
        padding: 24px 20px;
    }

    .install-step {
        flex-direction: column;
        gap: 16px;
    }

    .cmd {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .cmd span {
        text-align: left;
    }

    .wf-terminal pre {
        font-size: 0.75rem;
        padding: 16px;
    }

    .code-block pre {
        font-size: 0.82rem;
        padding: 14px 16px;
    }

    .code-block-lg pre {
        font-size: 0.9rem;
    }

    .section-header h2 {
        font-size: clamp(1.6rem, 5vw, 2.2rem);
    }

    .section-sub {
        font-size: 1rem;
    }

    .cta-content h2 {
        font-size: clamp(1.8rem, 6vw, 2.8rem);
    }

    .cta-content > p {
        font-size: 1.05rem;
    }

    .footer-inner {
        gap: 12px;
    }

    .pill {
        padding: 6px 14px;
        font-size: 0.8rem;
    }
}

/* Mobile portrait */
@media (max-width: 480px) {
    :root {
        --section-pad: 60px;
    }

    .container {
        padding: 0 16px;
    }

    .nav::after {
        left: 16px;
        right: 16px;
    }

    .hero {
        padding: 90px 16px 48px;
    }

    .hero h1 {
        font-size: 2.6rem;
    }

    .hero-lockup {
        flex-direction: column;
        gap: 8px;
    }

    .hero-logo {
        width: 64px;
    }

    .hero-tagline {
        font-size: 1rem;
    }

    .hero-sub {
        font-size: 0.95rem;
    }

    .hero-badge {
        font-size: 0.65rem;
        padding: 4px 10px;
        gap: 6px;
    }

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

    .btn {
        width: 100%;
        justify-content: center;
        padding: 14px 20px;
    }

    .hero-stats {
        gap: 16px;
    }

    .stat {
        min-width: 70px;
    }

    .stat-num {
        font-size: 1.4rem;
    }

    .stat-label {
        font-size: 0.7rem;
    }

    .feature-card {
        padding: 20px 16px;
    }

    .feature-card code {
        font-size: 0.72rem;
    }

    .term-body {
        padding: 14px 12px;
        font-size: 0.78rem;
        min-height: 92px;
    }

    .wf-header {
        padding: 16px 18px;
    }

    .wf-terminal pre {
        font-size: 0.68rem;
        line-height: 1.6;
        padding: 14px 12px;
        -webkit-overflow-scrolling: touch;
    }

    .cmd-group {
        padding: 20px 18px;
    }

    .cmd code {
        font-size: 0.78rem;
    }

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

    .section-header {
        margin-bottom: 40px;
    }
}

/* ── Animations ─────────────────────────────────────────────── */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-deepest);
}

::-webkit-scrollbar-thumb {
    background: var(--bg-surface);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-dimmer);
}

/* Selection */
::selection {
    background: rgba(124, 58, 237, 0.3);
    color: var(--text-bright);
}

/* Focus styles for accessibility */
.btn:focus-visible,
.copy-btn:focus-visible,
.nav-toggle:focus-visible,
.pill:focus-visible {
    outline: 2px solid var(--purple);
    outline-offset: 2px;
}

.nav-links a:focus-visible {
    outline: 2px solid var(--purple);
    outline-offset: 4px;
}

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

    .fade-in {
        opacity: 1;
        transform: none;
    }

    .particle {
        display: none;
    }
}
