/* ============================================================================
   HOME PAGE — /
   V2 Redesign: Hero → Stack → Core Story → VelvetCMS Story → Fleet Story → CTA
   ============================================================================ */


/* ════════════════════════════════════════════════════════════════════════════
   SECTION 1 — HERO
   ════════════════════════════════════════════════════════════════════════════ */

.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    padding-top: 80px;
}
.hero .container {
    display: flex;
    flex-direction: column;
    align-items: center;
}
.hero__headline {
    font-size: 56px;
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.03em;
    max-width: 720px;
}
.hero__sub {
    color: var(--text-secondary);
    font-size: 18px;
    line-height: 1.7;
    max-width: 600px;
    margin-top: var(--space-lg);
}
.hero__actions {
    display: flex;
    gap: var(--space-md);
    margin-top: var(--space-2xl);
    flex-wrap: wrap;
    justify-content: center;
}


/* ── Ambient Terminal ────────────────────────────────────────────────────── */

.hero-terminal {
    margin-top: var(--space-3xl);
    width: 100%;
    max-width: 680px;
}
.hero-terminal .terminal__body {
    min-height: 56px;
    display: flex;
    align-items: center;
}
.hero-terminal .terminal__body code {
    width: 100%;
    position: relative;
}
.hero-terminal .terminal-line {
    display: flex;
    justify-content: space-between;
    gap: var(--space-xl);
    opacity: 0;
    animation: terminalFadeIn 400ms ease-out forwards;
}
.hero-terminal .terminal-line.is-active {
    opacity: 1;
}
.hero-terminal .terminal-line .cmd {
    color: var(--text-primary);
    white-space: nowrap;
}
.hero-terminal .terminal-line .cmd .prompt {
    color: var(--accent);
    user-select: none;
}
.hero-terminal .terminal-line .comment {
    color: var(--text-muted);
    font-style: italic;
    white-space: nowrap;
}
@keyframes terminalFadeIn {
    from { opacity: 0; transform: translateY(4px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Terminal pause button */
.terminal__pause {
    padding: 4px 10px;
    font-size: 11px;
    font-family: var(--font-mono);
    color: var(--text-muted);
    background: transparent;
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: color var(--ease-fast), border-color var(--ease-fast);
}
.terminal__pause:hover {
    color: var(--text-secondary);
    border-color: var(--border-active);
}
.terminal__pause.is-paused {
    color: var(--amber);
    border-color: var(--amber);
}


/* ════════════════════════════════════════════════════════════════════════════
   SECTION 2 — INTERACTIVE STACK
   ════════════════════════════════════════════════════════════════════════════ */

.stack-section {
    position: relative;
}
.stack {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    max-width: 700px;
    margin-inline: auto;
}

/* Connector line between layers */
.stack__connector {
    width: 2px;
    height: 24px;
    position: relative;
    overflow: hidden;
}
.stack__connector::before {
    content: '';
    position: absolute;
    top: -24px; left: 0;
    width: 100%; height: calc(100% + 24px);
    background: repeating-linear-gradient(
        to bottom,
        var(--border-active) 0px,
        var(--border-active) 4px,
        transparent 4px,
        transparent 12px
    );
    animation: connectorFlow 2s linear infinite;
}
@keyframes connectorFlow {
    from { transform: translateY(-24px); }
    to   { transform: translateY(0); }
}
@keyframes connectorFlowSmall {
    from { transform: translateY(-18px); }
    to   { transform: translateY(0); }
}

/* Stack layer card */
.stack__layer {
    width: 100%;
    display: flex;
    align-items: center;
    gap: var(--space-md);
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: var(--space-lg) var(--space-xl);
    text-decoration: none;
    color: var(--text-primary);
    transition: border-color var(--ease-fast), transform var(--ease-fast), box-shadow var(--ease-fast);
    cursor: pointer;
    position: relative;
}
.stack__layer:hover {
    border-color: var(--border-active);
    transform: translateY(-2px);
    color: var(--text-primary);
}

.stack__icon {
    font-size: 24px;
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-elevated);
    border-radius: var(--radius-md);
}
.stack__body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.stack__name {
    font-size: 20px;
    font-weight: 600;
}
.stack__desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.4;
}

/* Product-specific hover glow */
.stack__layer[data-product="fleet"]:hover  { box-shadow: 0 0 32px rgba(45, 212, 191, 0.06); }
.stack__layer[data-product="velvet"]:hover { box-shadow: 0 0 32px rgba(139, 108, 199, 0.06); }
.stack__layer[data-product="core"]:hover   { box-shadow: 0 0 32px rgba(74, 158, 255, 0.06); }

/* Connector accent on hover (driven by JS) */
.stack__connector.accent-fleet::before  { background: repeating-linear-gradient(to bottom, var(--product-fleet) 0px, var(--product-fleet) 4px, transparent 4px, transparent 12px); }
.stack__connector.accent-velvet::before { background: repeating-linear-gradient(to bottom, var(--product-velvet) 0px, var(--product-velvet) 4px, transparent 4px, transparent 12px); }
.stack__connector.accent-core::before   { background: repeating-linear-gradient(to bottom, var(--product-core) 0px, var(--product-core) 4px, transparent 4px, transparent 12px); }

.stack__oneliner {
    text-align: center;
    color: var(--text-secondary);
    font-size: 16px;
    max-width: 640px;
    margin: var(--space-2xl) auto 0;
    line-height: 1.7;
}
.stack__oneliner a {
    font-weight: 600;
}
.stack__oneliner a[data-product="core"]   { color: var(--product-core); }
.stack__oneliner a[data-product="velvet"] { color: var(--product-velvet); }
.stack__oneliner a[data-product="fleet"]  { color: var(--product-fleet); }


/* ════════════════════════════════════════════════════════════════════════════
   STORIES — Core · VelvetCMS · Fleet
   The three product narratives, each with beats and a footer.
   ════════════════════════════════════════════════════════════════════════════ */


/* ── Story Section Container ─────────────────────────────────────────────── */

.story {
    padding-block: var(--space-5xl);
    position: relative;
}

/* Subtle product-tinted top border per story */
.story--core   { border-top: 1px solid rgba(74, 158, 255, 0.12); }
.story--velvet { border-top: 1px solid rgba(139, 108, 199, 0.12); }
.story--fleet  { border-top: 1px solid rgba(45, 212, 191, 0.12); }


/* ── Story Intro ─────────────────────────────────────────────────────────── */

.story__intro {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    margin-bottom: var(--space-3xl);
}

/* Horizontal accent line before the badge */
.story__intro-line {
    width: 48px;
    height: 2px;
    border-radius: 1px;
    flex-shrink: 0;
}
.story__intro-line[data-product="core"]   { background: var(--product-core); }
.story__intro-line[data-product="velvet"] { background: var(--product-velvet); }
.story__intro-line[data-product="fleet"]  { background: var(--product-fleet); }

.story__layer-label {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-muted);
}


/* ── Story Beats (the alternating text+visual sub-sections) ──────────────── */

.story__beat {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-3xl);
    align-items: start;
    margin-bottom: var(--space-4xl);
}

/* LEFT-dominant: text left, visual right (default for --left) */
.story__beat--left .story__text   { order: 1; }
.story__beat--left .story__visual { order: 2; }

/* RIGHT-dominant: visual left, text right */
.story__beat--right .story__visual { order: 1; }
.story__beat--right .story__text   { order: 2; }


/* ── Story Text ──────────────────────────────────────────────────────────── */

.story__text {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
    min-width: 0;
}

.story__heading {
    font-size: 36px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.story__subheading {
    font-size: 24px;
    font-weight: 600;
    line-height: 1.3;
    letter-spacing: -0.01em;
}

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

.story__bullets {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
    margin-top: var(--space-sm);
}
.story__bullets li {
    display: flex;
    align-items: flex-start;
    gap: var(--space-sm);
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.6;
}
.story__bullets li::before {
    content: '→';
    color: var(--accent);
    flex-shrink: 0;
    font-weight: 600;
}


/* ── Story Stats (big numbers row) ───────────────────────────────────────── */

.story__stats {
    display: flex;
    gap: var(--space-2xl);
    margin-top: var(--space-lg);
    padding-top: var(--space-lg);
    border-top: 1px solid var(--border-subtle);
}
.story__stat {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.story__stat-number {
    font-size: 36px;
    font-weight: 700;
    font-family: var(--font-mono);
    line-height: 1;
    color: var(--text-primary);
}
.story__stat-number[data-product="core"]   { color: var(--product-core); }
.story__stat-number[data-product="velvet"] { color: var(--product-velvet); }
.story__stat-number[data-product="fleet"]  { color: var(--product-fleet); }

.story__stat-unit {
    font-size: 20px;
    font-weight: 600;
}
.story__stat-label {
    font-size: 13px;
    color: var(--text-muted);
    letter-spacing: 0.02em;
}


/* ── Story Comparison (inline stat comparison) ───────────────────────────── */

.story__comparison {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
    padding: var(--space-md);
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    font-size: 14px;
    margin-top: var(--space-sm);
}
.story__comparison-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.story__comparison-label {
    color: var(--text-secondary);
    font-weight: 500;
}
.story__comparison-value {
    font-family: var(--font-mono);
    font-weight: 600;
    color: var(--text-primary);
}
.story__comparison-value--accent {
    color: var(--accent) !important;
}
.story__comparison-value--accent[data-product="core"] {
    color: var(--product-core) !important;
}


/* ── Story Visual ────────────────────────────────────────────────────────── */

.story__visual {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
}


/* ── Story Footer (meta + CTA link) ──────────────────────────────────────── */

.story__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-xl);
    padding-top: var(--space-xl);
    border-top: 1px solid var(--border-subtle);
    margin-top: var(--space-lg);
}

.story__meta {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    flex-wrap: wrap;
}
.story__meta-item {
    font-size: 13px;
    color: var(--text-muted);
}
.story__meta-divider {
    color: var(--border-active);
    font-size: 13px;
}

.story__cta {
    display: inline-flex;
    align-items: center;
    gap: var(--space-sm);
    font-size: 15px;
    font-weight: 600;
    white-space: nowrap;
    transition: gap var(--ease-fast);
}
.story__cta:hover {
    gap: var(--space-md);
}
.story__cta[data-product="core"]   { color: var(--product-core); }
.story__cta[data-product="velvet"] { color: var(--product-velvet); }
.story__cta[data-product="fleet"]  { color: var(--product-fleet); }

.story__cta-arrow {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    transition: transform var(--ease-fast);
}
.story__cta:hover .story__cta-arrow {
    transform: translateX(4px);
}


/* ════════════════════════════════════════════════════════════════════════════
   STORY — CORE  (specific styles)
   ════════════════════════════════════════════════════════════════════════════ */

/* Terminal with title label (used in the routing example) */
.terminal__title {
    font-size: 12px;
    color: var(--text-muted);
    font-family: var(--font-mono);
}


/* ════════════════════════════════════════════════════════════════════════════
   STORY — VELVETCMS (specific styles)
   ════════════════════════════════════════════════════════════════════════════ */

/* ── Large Services Diagram ──────────────────────────────────────────────── */

.services-diagram {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
    max-width: 100%;
    overflow: hidden;
}
.services-diagram--large {
    padding: var(--space-2xl);
}

.diagram-consumers {
    display: flex;
    justify-content: center;
    gap: var(--space-lg);
}
.diagram-consumer {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-xs);
    padding: var(--space-md) var(--space-lg);
    background: var(--bg-elevated);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    cursor: default;
    transition: border-color var(--ease-fast), box-shadow var(--ease-fast);
    text-align: center;
    min-width: 120px;
}
.diagram-consumer:hover {
    border-color: var(--accent);
    box-shadow: 0 0 20px var(--accent-glow);
}
.diagram-consumer .diagram-icon {
    font-size: 22px;
}
.diagram-consumer__name {
    font-weight: 700;
    font-size: 15px;
}
.diagram-consumer__use {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 400;
}

/* Flow lines between consumers and services */
.diagram-flow {
    display: flex;
    justify-content: center;
    gap: var(--space-3xl);
    padding: var(--space-sm) 0;
}
.diagram-flow__line {
    width: 2px;
    height: 32px;
    position: relative;
    overflow: hidden;
}
.diagram-flow__line::before {
    content: '';
    position: absolute;
    top: -9px; left: 0;
    width: 100%; height: calc(100% + 9px);
    background: repeating-linear-gradient(
        to bottom,
        var(--accent) 0px,
        var(--accent) 3px,
        transparent 3px,
        transparent 9px
    );
    animation: connectorFlowSmall 1.5s linear infinite;
}

/* Legacy arrow (kept for simple version) */
.diagram-arrow {
    display: flex;
    justify-content: center;
    color: var(--border-active);
    font-size: 20px;
    letter-spacing: 32px;
    user-select: none;
}

/* Services layer */
.diagram-services {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-sm);
    background: var(--bg-elevated);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: var(--space-lg);
}
.diagram-services__label {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: var(--space-xs);
}
.diagram-services__tags {
    display: flex;
    justify-content: center;
    gap: var(--space-sm);
    flex-wrap: wrap;
}
.diagram-service {
    padding: 5px 12px;
    background: var(--accent-soft);
    border: 1px solid rgba(139, 108, 199, 0.2);
    border-radius: var(--radius-pill);
    font-size: 12px;
    font-weight: 600;
    font-family: var(--font-mono);
    color: var(--accent-hover);
}


/* ── Consumer Inline Modes ───────────────────────────────────────────────── */

.story__inline-modes {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
    margin-top: var(--space-md);
    padding: var(--space-md);
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
}
.story__mode {
    display: flex;
    align-items: baseline;
    gap: var(--space-sm);
}
.story__mode-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
}
.story__mode-desc {
    font-size: 14px;
    color: var(--text-muted);
}


/* ── Submodule Grid (tag cloud for 19 submodules) ────────────────────────── */

.story__submodule-grid {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-xs);
    padding: var(--space-md);
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
}
.story__submodule {
    font-size: 12px;
    font-weight: 600;
    font-family: var(--font-mono);
    padding: 4px 12px;
    background: var(--accent-soft);
    border: 1px solid rgba(139, 108, 199, 0.15);
    border-radius: var(--radius-pill);
    color: var(--accent-hover);
    transition: background var(--ease-fast), border-color var(--ease-fast);
}
.story__submodule:hover {
    background: rgba(139, 108, 199, 0.2);
    border-color: rgba(139, 108, 199, 0.35);
}


/* ── Elevated Code Block variant ─────────────────────────────────────────── */

.code-block--elevated {
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.15);
}
.code-block--compact {
    border-radius: var(--radius-md);
}
.code-block--compact pre {
    padding: var(--space-sm) var(--space-md);
    font-size: 13px;
}


/* ── Workflow Diagram ────────────────────────────────────────────────────── */

.workflow-diagram {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    overflow-x: auto;
}

.workflow-states {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    justify-content: center;
    flex-wrap: nowrap;
}

.workflow-state {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    padding: var(--space-sm) var(--space-md);
    background: var(--bg-elevated);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    white-space: nowrap;
}
.workflow-state__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}
.workflow-state--draft .workflow-state__dot       { background: var(--text-muted); }
.workflow-state--review .workflow-state__dot      { background: var(--amber); }
.workflow-state--approved .workflow-state__dot    { background: var(--blue); }
.workflow-state--published .workflow-state__dot   { background: var(--green); }

.workflow-state__label {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
}

.workflow-arrow {
    display: flex;
    align-items: center;
    position: relative;
    padding: 0 var(--space-xs);
}
.workflow-arrow::before {
    content: '';
    width: 24px;
    height: 1px;
    background: var(--border-active);
}
.workflow-arrow::after {
    content: '';
    width: 0; height: 0;
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
    border-left: 6px solid var(--border-active);
}
.workflow-arrow__label {
    position: absolute;
    top: -16px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-muted);
    white-space: nowrap;
}

.workflow-reject {
    text-align: center;
    margin-top: var(--space-md);
}
.workflow-reject__label {
    font-size: 12px;
    color: var(--text-muted);
    font-style: italic;
}


/* ════════════════════════════════════════════════════════════════════════════
   STORY — FLEET (specific styles)
   ════════════════════════════════════════════════════════════════════════════ */

/* ── VelvetScore Visualization ───────────────────────────────────────────── */

.story__velvet-score {
    margin-top: var(--space-lg);
    padding: var(--space-lg);
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
}

.story__velvet-score-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: var(--space-md);
}
.story__velvet-score-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-secondary);
    letter-spacing: 0.02em;
    text-transform: uppercase;
}
.story__velvet-score-value {
    font-size: 32px;
    font-weight: 700;
    font-family: var(--font-mono);
    line-height: 1;
}
.story__velvet-score-value[data-product="fleet"] {
    color: var(--product-fleet);
}

/* Score bar segments */
.story__velvet-score-bar {
    display: flex;
    height: 10px;
    border-radius: 5px;
    overflow: hidden;
    gap: 2px;
    margin-bottom: var(--space-md);
}
.story__velvet-score-segment {
    flex: 1;
    position: relative;
    border-radius: 3px;
}
.story__velvet-score-segment[data-segment="basic"]    { background: rgba(90, 90, 112, 0.3); }
.story__velvet-score-segment[data-segment="standard"] { background: rgba(251, 191, 36, 0.25); }
.story__velvet-score-segment[data-segment="enhanced"] { background: rgba(96, 165, 250, 0.25); }
.story__velvet-score-segment[data-segment="premium"]  { background: rgba(45, 212, 191, 0.25); }

.story__velvet-score-segment--active {
    position: relative;
}
.story__velvet-score-segment--active::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 3px;
    background: var(--product-fleet);
    animation: scoreGlow 2s ease-in-out infinite alternate;
}
@keyframes scoreGlow {
    from { opacity: 0.5; }
    to   { opacity: 1; }
}

.story__velvet-score-segment-label {
    position: absolute;
    top: calc(100% + 6px);
    left: 50%;
    transform: translateX(-50%);
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-muted);
    white-space: nowrap;
}

/* Score weight breakdown */
.story__velvet-score-weights {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-sm);
    margin-top: var(--space-xl);
}
.story__velvet-score-weight {
    font-size: 12px;
    color: var(--text-muted);
    padding: 3px 10px;
    background: var(--bg-elevated);
    border-radius: var(--radius-pill);
}


/* ── Deployment Modes (Group vs Instance) ────────────────────────────────── */

.story__deploy-modes {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
    margin-top: var(--space-md);
}
.story__deploy-mode {
    display: flex;
    align-items: flex-start;
    gap: var(--space-md);
    padding: var(--space-md);
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    transition: border-color var(--ease-fast);
}
.story__deploy-mode:hover {
    border-color: var(--border-active);
}
.story__deploy-mode-icon {
    font-size: 20px;
    flex-shrink: 0;
    line-height: 1;
    margin-top: 2px;
}
.story__deploy-mode-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    display: block;
    margin-bottom: 2px;
}
.story__deploy-mode-desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
}


/* ── Fleet Architecture Diagram ──────────────────────────────────────────── */

.fleet-architecture {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    max-width: 100%;
    overflow: hidden;
}

.fleet-tier {
    width: 100%;
    text-align: center;
}

/* Control panel tier */
.fleet-tier--control {
    padding: var(--space-lg);
    background: var(--bg-elevated);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    margin-bottom: 0;
}
.fleet-tier__icon {
    font-size: 24px;
    display: block;
    margin-bottom: var(--space-xs);
}
.fleet-tier__name {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    display: block;
}
.fleet-tier__desc {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 2px;
    display: block;
}

/* Connector between architecture tiers */
.fleet-connector {
    width: 2px;
    height: 24px;
    position: relative;
    overflow: hidden;
}
.fleet-connector::before {
    content: '';
    position: absolute;
    top: -9px; left: 0;
    width: 100%; height: calc(100% + 9px);
    background: repeating-linear-gradient(
        to bottom,
        var(--product-fleet) 0px,
        var(--product-fleet) 3px,
        transparent 3px,
        transparent 9px
    );
    animation: connectorFlowSmall 1.5s linear infinite;
}

/* Agents tier */
.fleet-tier--agents {
    display: flex;
    gap: var(--space-md);
    justify-content: center;
}
.fleet-agent {
    flex: 1;
    max-width: 200px;
    padding: var(--space-md);
    background: var(--bg-elevated);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    transition: border-color var(--ease-fast), box-shadow var(--ease-fast);
}
.fleet-agent:hover {
    border-color: var(--product-fleet);
    box-shadow: 0 0 16px rgba(45, 212, 191, 0.06);
}
.fleet-agent__name {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-primary);
    display: block;
    margin-bottom: 2px;
}
.fleet-agent__sites {
    font-size: 12px;
    color: var(--text-muted);
}

/* Sites tier */
.fleet-tier--sites {
    padding: var(--space-md);
}
.fleet-tier__count {
    font-size: 14px;
    font-weight: 600;
    color: var(--product-fleet);
    font-family: var(--font-mono);
}


/* ── Feature Grid (Fleet features) ───────────────────────────────────────── */

.story__feature-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-sm);
    margin-top: var(--space-md);
}
.story__feature-item {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    padding: var(--space-sm) var(--space-md);
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    transition: border-color var(--ease-fast);
}
.story__feature-item:hover {
    border-color: var(--border-active);
}
.story__feature-icon {
    font-size: 16px;
    flex-shrink: 0;
}
.story__feature-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
}


/* ── Deploy Options (Fleet Cloud vs Self-Hosted) ─────────────────────────── */

.story__deploy-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-md);
}
.story__deploy-option {
    padding: var(--space-md);
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    text-align: center;
    transition: border-color var(--ease-fast);
}
.story__deploy-option:hover {
    border-color: var(--product-fleet);
}
.story__deploy-option-name {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-primary);
    display: block;
    margin-bottom: 2px;
}
.story__deploy-option-desc {
    font-size: 13px;
    color: var(--text-muted);
}


/* ════════════════════════════════════════════════════════════════════════════
   STORY BRIDGES (interstitial transitions between products)
   ════════════════════════════════════════════════════════════════════════════ */

.story-bridge {
    padding: var(--space-2xl) 0;
    text-align: center;
}
.story-bridge__text {
    font-size: 18px;
    color: var(--text-muted);
    font-style: italic;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-md);
}
.story-bridge__arrow {
    display: inline-flex;
    font-size: 24px;
    font-style: normal;
    color: var(--border-active);
    animation: bridgeBounce 2s ease-in-out infinite;
}
@keyframes bridgeBounce {
    0%, 100% { transform: translateY(0); }
    50%      { transform: translateY(6px); }
}


/* ════════════════════════════════════════════════════════════════════════════
   BENCHMARK BARS (shared, used in Core story)
   ════════════════════════════════════════════════════════════════════════════ */

.benchmark-bars {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}
.benchmark-bar {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.benchmark-bar__label {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-size: 14px;
}
.benchmark-bar__name {
    font-weight: 600;
    color: var(--text-primary);
}
.benchmark-bar__name[data-product="core"] {
    color: var(--product-core);
}
.benchmark-bar__value {
    font-family: var(--font-mono);
    font-size: 13px;
    color: var(--text-secondary);
}
.benchmark-bar__track {
    height: 8px;
    background: var(--bg-elevated);
    border-radius: 4px;
    overflow: hidden;
}
.benchmark-bar__fill {
    height: 100%;
    border-radius: 4px;
    width: 0%;
    transition: width 800ms ease-out;
}
.benchmark-bar__fill--accent {
    background: var(--product-core);
}
.benchmark-bar__fill--neutral {
    background: var(--border-active);
}
.benchmark-bars__note {
    font-size: 13px;
    font-style: italic;
    color: var(--text-muted);
    margin-top: var(--space-sm);
}


/* ════════════════════════════════════════════════════════════════════════════
   CODE COMPARISON (used in Core story)
   ════════════════════════════════════════════════════════════════════════════ */

.code-compare {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-md);
}
.code-compare__block {
    position: relative;
}
.code-compare__label {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: var(--space-sm);
}
.code-compare__block--accent .code-block {
    border-left: 2px solid var(--accent);
}


/* ════════════════════════════════════════════════════════════════════════════
   FINAL CTA
   ════════════════════════════════════════════════════════════════════════════ */

.final-cta {
    background: linear-gradient(180deg, var(--bg-deep) 0%, var(--bg-surface) 100%);
    text-align: center;
}
.final-cta__sub {
    color: var(--text-secondary);
    font-size: 16px;
    line-height: 1.7;
    max-width: 560px;
    margin: var(--space-md) auto 0;
}
.final-cta__actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-lg);
    margin-top: var(--space-2xl);
    flex-wrap: wrap;
}
.final-cta__actions .text-link {
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 15px;
}
.final-cta__actions .text-link:hover {
    color: var(--text-primary);
}
.final-cta__contact {
    color: var(--text-muted);
    font-size: 14px;
    margin-top: var(--space-xl);
}
.final-cta__contact a {
    color: var(--text-secondary);
}


/* ════════════════════════════════════════════════════════════════════════════
   TOKEN COLORS FOR TERMINAL OUTPUT (Fleet terminals)
   ════════════════════════════════════════════════════════════════════════════ */

.token-muted { color: var(--text-muted); }
.token-green { color: var(--green); }


/* ════════════════════════════════════════════════════════════════════════════
   RESPONSIVE — HOME
   ════════════════════════════════════════════════════════════════════════════ */

/* ── Tablet (≤ 1024px) ───────────────────────────────────────────────────── */
@media (max-width: 1024px) {

    /* Beats go single-column */
    .story__beat {
        grid-template-columns: 1fr;
        gap: var(--space-2xl);
    }

    /* Visual always comes after text in single column */
    .story__beat--left .story__visual,
    .story__beat--right .story__visual {
        order: 2;
    }
    .story__beat--left .story__text,
    .story__beat--right .story__text {
        order: 1;
    }

    /* Heading sizes */
    .story__heading {
        font-size: 30px;
    }
    .story__subheading {
        font-size: 20px;
    }

    /* Code compare stacks */
    .code-compare {
        grid-template-columns: 1fr;
    }

    /* Fleet agents stack vertically */
    .fleet-tier--agents {
        flex-direction: column;
        align-items: center;
    }
    .fleet-agent {
        max-width: 100%;
    }

    /* Footer wraps */
    .story__footer {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--space-md);
    }
}


/* ── Mobile (≤ 639px) ────────────────────────────────────────────────────── */
@media (max-width: 639px) {

    .hero {
        min-height: auto;
        padding-top: 120px;
        padding-bottom: var(--space-3xl);
    }
    .hero__headline {
        font-size: 34px;
    }
    .hero__sub {
        font-size: 16px;
    }
    .hero-terminal {
        max-width: 100%;
    }
    .hero-terminal .terminal-line {
        flex-direction: column;
        gap: 2px;
    }
    .hero-terminal .terminal-line .comment {
        padding-left: var(--space-md);
        font-size: 12px;
    }

    /* Stack layers stack more compactly */
    .stack__layer {
        gap: var(--space-sm);
    }

    /* Stats row wraps */
    .story__stats {
        flex-direction: column;
        gap: var(--space-lg);
    }
    .story__stat-number {
        font-size: 28px;
    }

    /* Feature grids go single column */
    .story__feature-grid {
        grid-template-columns: 1fr;
    }

    /* Deploy options stack */
    .story__deploy-options {
        grid-template-columns: 1fr;
    }

    /* Diagram consumers stack */
    .diagram-consumers {
        flex-direction: column;
        align-items: center;
    }
    .diagram-consumer {
        width: 100%;
        max-width: 200px;
        min-width: 0;
    }
    .diagram-flow {
        flex-direction: column;
        align-items: center;
        gap: var(--space-xs);
    }
    .diagram-flow__line {
        width: 32px;
        height: 2px;
    }
    .diagram-flow__line::before {
        background: repeating-linear-gradient(
            to right,
            var(--accent) 0px,
            var(--accent) 3px,
            transparent 3px,
            transparent 9px
        );
    }

    /* Services diagram smaller padding */
    .services-diagram--large {
        padding: var(--space-md);
    }
    .diagram-services__tags {
        gap: var(--space-xs);
    }
    .diagram-service {
        padding: 3px 8px;
        font-size: 11px;
    }

    /* Workflow diagram scrolls horizontally */
    .workflow-diagram {
        padding: var(--space-md);
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .workflow-states {
        justify-content: flex-start;
        min-width: max-content;
    }

    /* VelvetScore segments hide labels on mobile */
    .story__velvet-score-segment-label {
        font-size: 9px;
    }
    .story__velvet-score-weights {
        flex-direction: column;
    }
    .story__velvet-score {
        padding: var(--space-md);
    }

    /* Fleet architecture smaller */
    .fleet-architecture {
        padding: var(--space-md);
    }
    .fleet-tier--control {
        padding: var(--space-md);
    }
    .fleet-tier__desc {
        font-size: 12px;
    }
    .fleet-tier--agents {
        flex-direction: column;
        align-items: stretch;
    }
    .fleet-agent {
        max-width: 100%;
    }

    /* Inline modes */
    .story__mode {
        flex-direction: column;
        gap: 2px;
    }

    /* Deploy modes */
    .story__deploy-mode {
        flex-direction: column;
    }

    /* Terminal and code blocks constrained */
    .terminal,
    .code-block,
    .code-block--elevated,
    .code-block--compact {
        max-width: 100%;
    }
    .terminal__body,
    .code-block pre {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .terminal__body code,
    .code-block pre code {
        font-size: 12px;
    }

    /* Code compare blocks */
    .code-compare {
        gap: var(--space-sm);
    }

    /* Story bridge smaller */
    .story-bridge__text {
        font-size: 16px;
    }

    /* Final CTA stacks */
    .final-cta__actions {
        flex-direction: column;
        align-items: center;
    }

    /* Story footer on mobile */
    .story__meta {
        gap: var(--space-xs);
    }
    .story__meta-item {
        font-size: 12px;
    }
}
