/* ==========================================================================
   AICAP Design System
   Futuristic / Isometric / Dark Theme
   ========================================================================== */

/* ---------- CSS Custom Properties ---------- */
:root {
    --bg-primary: #060a14;
    --bg-section: #0a0f1e;
    --bg-section-alt: #0d1326;
    --bg-card: #111a30;
    --bg-card-hover: #162040;

    --accent: #00e5ff;
    --accent-dim: rgba(0, 229, 255, 0.15);
    --accent-glow: rgba(0, 229, 255, 0.35);
    --accent-purple: #10b981;
    --accent-purple-dim: rgba(16, 185, 129, 0.15);
    --accent-purple-glow: rgba(16, 185, 129, 0.35);
    --accent-magenta: #34d399;
    --accent-magenta-dim: rgba(52, 211, 153, 0.15);

    --text-primary: #f0f4ff;
    --text-secondary: #94a3b8;
    --text-muted: #475569;

    --border: rgba(0, 229, 255, 0.12);
    --border-strong: rgba(0, 229, 255, 0.25);

    --font-display: 'Space Grotesk', system-ui, sans-serif;
    --font-mono: 'JetBrains Mono', ui-monospace, monospace;

    --radius: 8px;
    --radius-lg: 16px;

    --transition: 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}


/* ---------- Base ---------- */
*,
*::before,
*::after {
    box-sizing: border-box;
}

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

body {
    overflow-x: hidden;
}

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

::selection {
    background: var(--accent);
    color: var(--bg-primary);
}


/* ---------- Typography ---------- */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.text-accent { color: var(--accent) !important; }
.text-secondary-light { color: var(--text-secondary) !important; }


/* ---------- Navbar ---------- */
.navbar {
    padding: 1rem 0;
    background: rgba(6, 10, 20, 0.7);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid transparent;
    transition: var(--transition);
    z-index: 1050;
}

.navbar.scrolled {
    padding: 0.6rem 0;
    border-bottom-color: var(--border);
    background: rgba(6, 10, 20, 0.95);
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 700;
    font-size: 1.3rem;
    letter-spacing: 0.05em;
    text-decoration: none;
}

.brand-icon {
    color: var(--accent);
    font-size: 1.8rem;
    filter: drop-shadow(0 0 6px var(--accent-glow));
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.brand-icon-inner {
    position: absolute;
    font-size: 0.85rem;
}

.brand-text {
    color: var(--text-primary);
}

.nav-link {
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.03em;
    color: var(--text-secondary) !important;
    padding: 0.5rem 1rem !important;
    position: relative;
    transition: var(--transition);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 1rem;
    right: 1rem;
    height: 2px;
    background: var(--accent);
    transform: scaleX(0);
    transition: transform var(--transition);
}

.nav-link:hover,
.nav-link.active {
    color: var(--text-primary) !important;
}

.nav-link:hover::after,
.nav-link.active::after {
    transform: scaleX(1);
}

.navbar-toggler {
    border-color: var(--border) !important;
}


/* ==========================================================================
   ISOMETRIC GRID BACKGROUNDS
   ========================================================================== */

/* Diamond / isometric grid — used on hero and section backgrounds */
.hero-grid-bg {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(var(--border) 1px, transparent 1px),
        linear-gradient(90deg, var(--border) 1px, transparent 1px);
    background-size: 50px 50px;
    transform: perspective(600px) rotateX(60deg) scale(2.5);
    transform-origin: center top;
    mask-image: radial-gradient(ellipse 60% 80% at 50% 20%, black 10%, transparent 60%);
    -webkit-mask-image: radial-gradient(ellipse 60% 80% at 50% 20%, black 10%, transparent 60%);
    opacity: 0.6;
    animation: gridPulse 8s ease-in-out infinite;
}

/* Secondary iso-grid for inner sections */
.iso-grid-bg {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.iso-grid-bg::before {
    content: '';
    position: absolute;
    inset: -50%;
    background:
        linear-gradient(60deg, var(--border) 1px, transparent 1px),
        linear-gradient(-60deg, var(--border) 1px, transparent 1px);
    background-size: 80px 46px;
    opacity: 0.3;
}

@keyframes gridPulse {
    0%, 100% { opacity: 0.4; }
    50% { opacity: 0.7; }
}


/* ==========================================================================
   FLOATING ISOMETRIC SHAPES (reusable decorative elements)
   ========================================================================== */

.iso-shapes {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.iso-shape {
    position: absolute;
    border: 1.5px solid var(--accent-dim);
    animation: isoFloat 6s ease-in-out infinite;
}

/* Diamond (rotated square) */
.iso-shape--diamond {
    width: 40px;
    height: 40px;
    transform: rotate(45deg);
}

/* Hexagon via clip-path */
.iso-shape--hex {
    width: 50px;
    height: 50px;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    background: var(--accent-dim);
    border: none;
}

/* Flat isometric cube face */
.iso-shape--cube {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--accent-dim) 0%, transparent 70%);
    transform: rotateX(55deg) rotateZ(-45deg);
    border-radius: 4px;
}

/* Small circle / dot */
.iso-shape--dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
    border: none;
    opacity: 0.4;
    animation: isoPulse 4s ease-in-out infinite;
}

/* Isometric ring */
.iso-shape--ring {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    transform: rotateX(65deg);
    animation: isoSpin 15s linear infinite;
}

/* Color variants */
.iso-shape--purple { border-color: var(--accent-purple-dim); }
.iso-shape--purple.iso-shape--hex { background: var(--accent-purple-dim); }
.iso-shape--purple.iso-shape--cube { background: linear-gradient(135deg, var(--accent-purple-dim) 0%, transparent 70%); }
.iso-shape--purple.iso-shape--dot { background: var(--accent-purple); }

.iso-shape--magenta { border-color: var(--accent-magenta-dim); }
.iso-shape--magenta.iso-shape--hex { background: var(--accent-magenta-dim); }
.iso-shape--magenta.iso-shape--cube { background: linear-gradient(135deg, var(--accent-magenta-dim) 0%, transparent 70%); }
.iso-shape--magenta.iso-shape--dot { background: var(--accent-magenta); }

/* Animation delays set via inline style, but defaults: */
@keyframes isoFloat {
    0%, 100% { transform: var(--iso-base-transform, rotate(45deg)) translateY(0); }
    50% { transform: var(--iso-base-transform, rotate(45deg)) translateY(-20px); }
}

@keyframes isoPulse {
    0%, 100% { opacity: 0.2; transform: scale(1); }
    50% { opacity: 0.6; transform: scale(1.5); }
}

@keyframes isoSpin {
    from { transform: rotateX(65deg) rotateZ(0deg); }
    to { transform: rotateX(65deg) rotateZ(360deg); }
}


/* ==========================================================================
   ISOMETRIC SECTION DIVIDERS
   ========================================================================== */

.iso-divider {
    position: relative;
    height: 80px;
    overflow: hidden;
    background: transparent;
}

.iso-divider::before,
.iso-divider::after {
    content: '';
    position: absolute;
    left: -5%;
    right: -5%;
    height: 100%;
}

.iso-divider--down::before {
    top: 0;
    background: var(--bg-section);
    transform: skewY(-2deg);
    transform-origin: top left;
}

.iso-divider--up::before {
    bottom: 0;
    background: var(--bg-section-alt);
    transform: skewY(2deg);
    transform-origin: bottom right;
}

.iso-divider--accent::after {
    top: 50%;
    height: 1px;
    background: linear-gradient(90deg, transparent 5%, var(--accent-dim) 30%, var(--accent) 50%, var(--accent-dim) 70%, transparent 95%);
    transform: skewY(-2deg);
}


/* ==========================================================================
   HERO SECTION
   ========================================================================== */

.hero-section {
    position: relative;
    padding: 10rem 0 6rem;
    min-height: 85vh;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.min-vh-hero {
    min-height: 50vh;
}

.hero-eyebrow {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--accent);
    letter-spacing: 0.15em;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--accent) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
    max-width: 560px;
    line-height: 1.8;
}

.hero-actions {
    margin-top: 2.5rem;
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}


/* ---------- Isometric Hero Graphic (expanded) ---------- */
.hero-iso-graphic {
    position: relative;
    width: 100%;
    height: 450px;
    perspective: 1000px;
}

.iso-platform {
    position: absolute;
    border: 1.5px solid var(--border-strong);
    border-radius: var(--radius);
    background: linear-gradient(135deg, var(--accent-dim) 0%, transparent 50%);
    transform: rotateX(55deg) rotateZ(-45deg);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.iso-platform--main {
    width: 220px;
    height: 220px;
    top: 80px;
    left: 40px;
    animation: platformFloat 6s ease-in-out infinite;
}

.iso-platform--secondary {
    width: 120px;
    height: 120px;
    top: 30px;
    left: 220px;
    animation: platformFloat 6s ease-in-out infinite -1.5s;
    border-color: var(--accent-purple-dim);
    background: linear-gradient(135deg, var(--accent-purple-dim) 0%, transparent 50%);
}

.iso-platform--tertiary {
    width: 80px;
    height: 80px;
    top: 200px;
    left: 250px;
    animation: platformFloat 6s ease-in-out infinite -3s;
    border-color: var(--accent-magenta-dim);
    background: linear-gradient(135deg, var(--accent-magenta-dim) 0%, transparent 50%);
}

/* 3D depth layers on main platform */
.iso-platform--main::before {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 8px;
    right: -8px;
    top: 8px;
    border: 1px solid rgba(0, 229, 255, 0.06);
    background: rgba(0, 229, 255, 0.03);
    border-radius: var(--radius);
    z-index: -1;
}

.iso-platform--main::after {
    content: '';
    position: absolute;
    bottom: -22px;
    left: 14px;
    right: -14px;
    top: 14px;
    border: 1px solid rgba(0, 229, 255, 0.03);
    background: rgba(0, 229, 255, 0.015);
    border-radius: var(--radius);
    z-index: -2;
}

/* Vertical connector lines between platforms */
.iso-connector {
    position: absolute;
    width: 2px;
    background: linear-gradient(to bottom, var(--accent), transparent);
    opacity: 0.3;
}

.iso-connector--1 {
    height: 60px;
    top: 20px;
    left: 150px;
    transform: rotateX(55deg) rotateZ(-45deg);
    animation: connectorPulse 3s ease-in-out infinite;
}

.iso-connector--2 {
    height: 40px;
    top: 160px;
    left: 280px;
    transform: rotateX(55deg) rotateZ(-45deg);
    animation: connectorPulse 3s ease-in-out infinite -1s;
}

/* Data streams — animated dots flowing between platforms */
.iso-stream {
    position: absolute;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 8px var(--accent-glow);
}

.iso-stream--1 {
    top: 60px;
    left: 170px;
    animation: streamFlow1 4s linear infinite;
}

.iso-stream--2 {
    top: 100px;
    left: 200px;
    animation: streamFlow2 5s linear infinite -1s;
}

.iso-stream--3 {
    top: 140px;
    left: 190px;
    animation: streamFlow1 3.5s linear infinite -2s;
    background: var(--accent-purple);
    box-shadow: 0 0 8px var(--accent-purple-glow);
}

/* Orbiting ring */
.iso-orbit {
    position: absolute;
    top: 60px;
    left: 30px;
    width: 260px;
    height: 260px;
    border: 1.5px solid var(--accent-dim);
    border-radius: 50%;
    transform: rotateX(65deg) rotateZ(-10deg);
    animation: isoSpin 20s linear infinite;
}

.iso-orbit::before {
    content: '';
    position: absolute;
    top: -4px;
    left: 50%;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 12px var(--accent-glow);
}

/* Floating hex in hero */
.iso-hero-hex {
    position: absolute;
    width: 30px;
    height: 30px;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
}

.iso-hero-hex--1 {
    top: 20px;
    left: 300px;
    background: var(--accent-dim);
    animation: isoFloat 5s ease-in-out infinite;
    --iso-base-transform: none;
}

.iso-hero-hex--2 {
    top: 300px;
    left: 20px;
    background: var(--accent-purple-dim);
    animation: isoFloat 7s ease-in-out infinite -2s;
    --iso-base-transform: none;
}

.iso-hero-hex--3 {
    top: 280px;
    left: 300px;
    background: var(--accent-magenta-dim);
    animation: isoFloat 6s ease-in-out infinite -4s;
    --iso-base-transform: none;
    width: 20px;
    height: 20px;
}

@keyframes platformFloat {
    0%, 100% { transform: rotateX(55deg) rotateZ(-45deg) translateZ(0); }
    50% { transform: rotateX(55deg) rotateZ(-45deg) translateZ(15px); }
}

@keyframes connectorPulse {
    0%, 100% { opacity: 0.2; }
    50% { opacity: 0.6; }
}

@keyframes streamFlow1 {
    0% { transform: translate(0, 0); opacity: 0; }
    10% { opacity: 1; }
    90% { opacity: 1; }
    100% { transform: translate(80px, -60px); opacity: 0; }
}

@keyframes streamFlow2 {
    0% { transform: translate(0, 0); opacity: 0; }
    10% { opacity: 1; }
    90% { opacity: 1; }
    100% { transform: translate(-60px, 80px); opacity: 0; }
}


/* ==========================================================================
   BUTTONS
   ========================================================================== */

.btn-accent {
    background: var(--accent);
    color: var(--bg-primary);
    border: none;
    font-weight: 600;
    font-family: var(--font-display);
    letter-spacing: 0.02em;
    padding: 0.75rem 2rem;
    border-radius: var(--radius);
    transition: var(--transition);
    box-shadow: 0 0 20px var(--accent-glow);
}

.btn-accent:hover {
    background: #33ebff;
    color: var(--bg-primary);
    box-shadow: 0 0 30px var(--accent-glow), 0 0 60px rgba(0, 229, 255, 0.15);
    transform: translateY(-2px);
}


/* ==========================================================================
   SECTIONS
   ========================================================================== */

.section-dark {
    padding: 6rem 0;
    background: var(--bg-section);
    position: relative;
}

.section-darker {
    padding: 6rem 0;
    background: var(--bg-section-alt);
    position: relative;
}

.section-cta {
    padding: 6rem 0;
    background: var(--bg-section);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    position: relative;
}

.section-heading {
    font-size: clamp(1.8rem, 3vw, 2.5rem);
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.section-body {
    font-size: 1.15rem;
}


/* ---------- Page Hero (inner pages) ---------- */
.page-hero {
    position: relative;
    padding: 10rem 0 4rem;
    background: var(--bg-section-alt);
    overflow: hidden;
}

.page-hero-title {
    font-size: clamp(2rem, 4vw, 3.5rem);
    font-weight: 700;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--accent) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.page-hero-subtitle {
    font-size: 1.15rem;
    color: var(--text-secondary);
    margin-top: 1rem;
    max-width: 600px;
}


/* ==========================================================================
   ISOMETRIC CARDS
   ========================================================================== */

.iso-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 2rem;
    position: relative;
    transition: var(--transition);
    overflow: hidden;
    /* Subtle default isometric tilt */
    transform: perspective(800px) rotateX(-1deg) rotateY(0.5deg);
}

/* Top glow line */
.iso-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    opacity: 0;
    transition: opacity var(--transition);
}

/* Bottom shadow layer for depth */
.iso-card::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 6px;
    right: -6px;
    top: 6px;
    background: rgba(0, 229, 255, 0.02);
    border: 1px solid rgba(0, 229, 255, 0.04);
    border-radius: var(--radius-lg);
    z-index: -1;
    transition: var(--transition);
}

.iso-card:hover,
.iso-card.in-view {
    border-color: var(--border-strong);
    background: var(--bg-card-hover);
    transform: perspective(800px) rotateX(-3deg) rotateY(1.5deg) translateY(-6px);
    box-shadow:
        0 25px 50px rgba(0, 0, 0, 0.5),
        0 0 40px var(--accent-dim);
}

.iso-card:hover::before,
.iso-card.in-view::before {
    opacity: 1;
}

.iso-card:hover::after,
.iso-card.in-view::after {
    bottom: -10px;
    left: 10px;
    right: -10px;
    top: 10px;
    background: rgba(0, 229, 255, 0.03);
}


/* ==========================================================================
   SCENARIO CARD
   ========================================================================== */

.scenario-card {
    padding: 2.5rem;
}

.scenario-label {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--accent-magenta);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1rem;
}

.scenario-item {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
    height: 100%;
    transition: var(--transition);
    transform: perspective(600px) rotateX(-1deg);
}

.scenario-item:hover,
.scenario-item.in-view {
    transform: perspective(600px) rotateX(-3deg) translateY(-4px);
    border-color: var(--accent-magenta-dim);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
}

.scenario-icon {
    font-size: 1.5rem;
    color: var(--accent-magenta);
    margin-bottom: 0.75rem;
}

.scenario-item p {
    font-size: 1rem;
    color: var(--text-secondary);
    margin: 0;
}

.scenario-punchline {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 1.1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border);
}


/* ---------- Scenario Tabs ---------- */
.scenario-tabs {
    position: relative;
}

.scenario-tab-nav {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0;
    position: relative;
    z-index: 2;
}

.scenario-tab-btn {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    letter-spacing: 0.05em;
    padding: 0.75rem 1.5rem;
    background: var(--bg-card);
    color: var(--text-muted);
    border: 1px solid var(--border);
    border-bottom: none;
    border-radius: var(--radius) var(--radius) 0 0;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
}

.scenario-tab-btn:hover,
.scenario-tab-btn.in-view {
    color: var(--text-secondary);
    background: var(--bg-card-hover);
}

.scenario-tab-btn.active {
    color: var(--accent);
    background: var(--bg-card);
    border-color: var(--border-strong);
}

.scenario-tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--bg-card);
    z-index: 3;
}

.scenario-tab-panel {
    display: none;
}

.scenario-tab-panel.active {
    display: block;
    animation: tabFadeIn 0.35s ease;
}

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

.scenario-tab-panel .scenario-card {
    border-top-left-radius: 0;
    margin-top: 0;
}

/* Scenario context */
.scenario-context p {
    font-size: 1.05rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.scenario-context code {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--accent);
    background: rgba(0, 229, 255, 0.08);
    padding: 0.15rem 0.4rem;
    border-radius: 4px;
}

.scenario-time {
    font-family: var(--font-mono);
    font-size: 0.9rem !important;
    color: var(--accent-magenta) !important;
    letter-spacing: 0.02em;
}

/* Before/After outcome */
.scenario-outcome {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
}

.scenario-outcome-without,
.scenario-outcome-with {
    padding: 1.25rem;
    border-radius: var(--radius);
    font-size: 0.95rem;
    line-height: 1.6;
}

.scenario-outcome-without {
    background: rgba(239, 68, 68, 0.06);
    border: 1px solid rgba(239, 68, 68, 0.15);
    color: var(--text-secondary);
}

.scenario-outcome-with {
    background: rgba(16, 185, 129, 0.06);
    border: 1px solid rgba(16, 185, 129, 0.15);
    color: var(--text-primary);
}

.scenario-outcome-label {
    display: block;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.scenario-outcome-without .scenario-outcome-label {
    color: #ef4444;
}

.scenario-outcome-with .scenario-outcome-label {
    color: var(--accent-purple);
}

@media (max-width: 767.98px) {
    .scenario-tab-nav {
        flex-direction: column;
    }

    .scenario-tab-btn {
        border-radius: var(--radius);
        border-bottom: 1px solid var(--border);
    }

    .scenario-tab-btn.active::after {
        display: none;
    }

    .scenario-tab-panel .scenario-card {
        border-top-left-radius: var(--radius-lg);
    }

    .scenario-outcome {
        grid-template-columns: 1fr;
    }
}


/* ==========================================================================
   INTELLIGENCE CYCLE GRID (used on inner pages)
   ========================================================================== */

.cycle-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.cycle-card {
    text-align: center;
    position: relative;
}

.cycle-card[data-step]::before {
    content: attr(data-step);
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
    letter-spacing: 0.1em;
    z-index: 2;
}

/* Hexagonal icon containers (shared by cycle-card, pipeline-card, beyond-card) */
.cycle-icon {
    width: 64px;
    height: 64px;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    background: var(--accent-dim);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.25rem;
    font-size: 1.4rem;
    color: var(--accent);
    transition: var(--transition);
    position: relative;
}

/* Hex outline ring */
.cycle-icon::after {
    content: '';
    position: absolute;
    inset: -4px;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    background: var(--border);
    z-index: -1;
    transition: var(--transition);
}

.cycle-card:hover .cycle-icon,
.pipeline-card:hover .cycle-icon,
.cycle-card.in-view .cycle-icon,
.pipeline-card.in-view .cycle-icon {
    background: rgba(0, 229, 255, 0.25);
    filter: drop-shadow(0 0 15px var(--accent-glow));
}

.cycle-card:hover .cycle-icon::after,
.pipeline-card:hover .cycle-icon::after,
.cycle-card.in-view .cycle-icon::after,
.pipeline-card.in-view .cycle-icon::after {
    background: var(--accent-dim);
}

.cycle-card h3 {
    font-size: 1.2rem;
    margin-bottom: 0.75rem;
}

.cycle-card p {
    font-size: 1rem;
    color: var(--text-secondary);
    margin: 0;
}


/* ==========================================================================
   TWO-TIER PIPELINE (homepage)
   ========================================================================== */

.pipeline {
    position: relative;
}

.pipeline-tier {
    margin-bottom: 0;
}

.pipeline-tier-label {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.pipeline-tier-tag {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--accent);
    background: var(--accent-dim);
    border: 1px solid var(--border-strong);
    padding: 0.4rem 1rem;
    border-radius: var(--radius);
    white-space: nowrap;
}

.pipeline-tier-tag--action {
    color: var(--accent-purple);
    background: var(--accent-purple-dim);
    border-color: rgba(16, 185, 129, 0.25);
}

.pipeline-tier-desc {
    font-size: 0.95rem;
    color: var(--text-muted);
}

/* Flow row: cards with arrows between */
.pipeline-flow {
    display: flex;
    align-items: stretch;
    gap: 0;
}

.pipeline-card {
    flex: 1;
    text-align: center;
    position: relative;
}

.pipeline-card[data-step]::before {
    content: attr(data-step);
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
    letter-spacing: 0.1em;
    z-index: 2;
}

.pipeline-card h3 {
    font-size: 1.2rem;
    margin-bottom: 0.75rem;
}

.pipeline-card p {
    font-size: 1rem;
    color: var(--text-secondary);
    margin: 0;
}

/* Arrows between cards */
.pipeline-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 0.6rem;
    color: var(--accent);
    font-size: 1.2rem;
    opacity: 0.4;
    flex-shrink: 0;
    animation: pipelinePulse 2s ease-in-out infinite;
}

.pipeline-flow .pipeline-arrow:nth-child(4) {
    animation-delay: -0.7s;
}

@keyframes pipelinePulse {
    0%, 100% { opacity: 0.25; transform: translateX(0); }
    50% { opacity: 0.7; transform: translateX(3px); }
}

/* Bridge between tiers */
.pipeline-bridge {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 2rem 0;
}

.pipeline-bridge-line {
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent-dim), var(--accent), var(--accent-dim), transparent);
}

.pipeline-bridge-label {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--accent);
    letter-spacing: 0.06em;
    white-space: nowrap;
    text-transform: uppercase;
    opacity: 0.7;
}

/* Loop-back indicator */
.pipeline-loop {
    text-align: center;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-muted);
    letter-spacing: 0.03em;
}

.pipeline-loop i {
    color: var(--accent);
    opacity: 0.6;
}

/* Pipeline responsive */
@media (max-width: 991.98px) {
    .pipeline-flow {
        flex-direction: column;
        gap: 0.75rem;
    }

    .pipeline-arrow {
        padding: 0.25rem 0;
        animation: pipelinePulseVert 2s ease-in-out infinite;
    }

    @keyframes pipelinePulseVert {
        0%, 100% { opacity: 0.25; transform: rotate(90deg) translateX(0); }
        50% { opacity: 0.7; transform: rotate(90deg) translateX(3px); }
    }

    .pipeline-bridge {
        flex-direction: column;
        padding: 1.5rem 0;
        gap: 0.75rem;
    }

    .pipeline-bridge-line {
        width: 60%;
        height: 1px;
    }
}


/* ==========================================================================
   STAT CARDS — Isometric stack
   ========================================================================== */

.stat-card {
    padding: 2.5rem 1.5rem;
    position: relative;
}

/* Stacked depth layers */
.stat-card .stat-depth {
    position: absolute;
    bottom: -8px;
    left: 8px;
    right: -8px;
    top: 8px;
    background: rgba(0, 229, 255, 0.02);
    border: 1px solid rgba(0, 229, 255, 0.05);
    border-radius: var(--radius-lg);
    z-index: -1;
}

.stat-card .stat-depth-2 {
    position: absolute;
    bottom: -14px;
    left: 14px;
    right: -14px;
    top: 14px;
    background: rgba(0, 229, 255, 0.01);
    border: 1px solid rgba(0, 229, 255, 0.03);
    border-radius: var(--radius-lg);
    z-index: -2;
}

.stat-value {
    font-family: var(--font-mono);
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 0.5rem;
    text-shadow: 0 0 30px var(--accent-glow);
}

.stat-label {
    font-size: 1rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.stat-compare {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-muted);
}


/* ==========================================================================
   CTA FLOW — Isometric pipeline
   ========================================================================== */

.cta-flow {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
    flex-wrap: wrap;
    perspective: 600px;
}

.cta-flow-item {
    font-family: var(--font-mono);
    font-size: 1rem;
    padding: 0.75rem 1.5rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--bg-card);
    color: var(--text-secondary);
    transform: perspective(600px) rotateY(-2deg) rotateX(-1deg);
    transition: var(--transition);
}

.cta-flow-item:hover {
    transform: perspective(600px) rotateY(-4deg) rotateX(-2deg) translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.cta-flow-item--accent {
    border-color: var(--accent);
    color: var(--accent);
    background: var(--accent-dim);
    box-shadow: 0 0 25px var(--accent-dim);
    font-weight: 600;
    transform: perspective(600px) rotateY(0deg) rotateX(0deg) scale(1.05);
}

.cta-flow-item--accent:hover {
    transform: perspective(600px) rotateY(0deg) rotateX(0deg) scale(1.1) translateY(-3px);
    box-shadow: 0 0 40px var(--accent-dim), 0 15px 30px rgba(0, 0, 0, 0.3);
}

.cta-flow-arrow {
    color: var(--accent);
    font-size: 1.2rem;
    opacity: 0.5;
    animation: arrowPulse 2s ease-in-out infinite;
}

.cta-flow-arrow:nth-child(4) {
    animation-delay: -0.5s;
}

@keyframes arrowPulse {
    0%, 100% { opacity: 0.3; transform: translateX(0); }
    50% { opacity: 0.8; transform: translateX(3px); }
}


/* ==========================================================================
   ISOMETRIC DATA VISUALISATION (section background element)
   ========================================================================== */

.iso-bars {
    display: flex;
    align-items: flex-end;
    gap: 12px;
    transform: perspective(400px) rotateX(10deg) rotateY(-15deg);
    padding: 2rem;
}

.iso-bar {
    width: 30px;
    border-radius: 4px 4px 0 0;
    background: linear-gradient(to top, var(--accent-dim), var(--accent));
    position: relative;
    transition: var(--transition);
    opacity: 0.6;
}

.iso-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.05));
    border-radius: 4px 4px 0 0;
}

.iso-bar--purple {
    background: linear-gradient(to top, var(--accent-purple-dim), var(--accent-purple));
}


/* ==========================================================================
   FORMS
   ========================================================================== */

.aicap-form .form-label {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    letter-spacing: 0.02em;
}

.aicap-input {
    background: var(--bg-card) !important;
    border: 1px solid var(--border) !important;
    color: var(--text-primary) !important;
    border-radius: var(--radius) !important;
    padding: 0.75rem 1rem !important;
    font-family: var(--font-display);
    transition: var(--transition);
}

.aicap-input:focus {
    border-color: var(--accent) !important;
    box-shadow: 0 0 0 3px var(--accent-dim) !important;
    outline: none;
}

.aicap-input::placeholder {
    color: var(--text-muted) !important;
}


/* ==========================================================================
   INTRO TEXT
   ========================================================================== */

.intro-text {
    font-size: 1.15rem;
    color: var(--text-secondary);
    line-height: 1.9;
}

.intro-text p:first-child {
    font-size: 1.25rem;
    color: var(--text-primary);
}


/* ==========================================================================
   FOOTER
   ========================================================================== */

.site-footer {
    padding: 4rem 0 0;
    background: var(--bg-primary);
    border-top: 1px solid var(--border);
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.footer-tagline {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.7;
}

.footer-heading {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--accent);
    margin-bottom: 1rem;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    transition: color var(--transition);
}

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

.footer-text {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.footer-dng-link {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color var(--transition);
}

.footer-dng-link:hover {
    color: var(--accent);
}

.footer-uk {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.footer-bar {
    margin-top: 3rem;
    padding: 1.5rem 0;
    border-top: 1px solid var(--border);
}

.footer-bar p {
    margin: 0;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.footer-version {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
    opacity: 0.5;
    margin-top: 0.25rem;
}


/* ==========================================================================
   SEARCH
   ========================================================================== */

.search-result-link {
    color: var(--accent);
    text-decoration: none;
    font-weight: 500;
    font-size: 1.1rem;
    transition: color var(--transition);
}

.search-result-link:hover {
    color: #33ebff;
}


/* ==========================================================================
   OUTLINE BUTTON
   ========================================================================== */

.btn-outline-accent {
    background: transparent;
    color: var(--accent);
    border: 1.5px solid var(--accent);
    font-weight: 600;
    font-family: var(--font-display);
    letter-spacing: 0.02em;
    padding: 0.75rem 2rem;
    border-radius: var(--radius);
    transition: var(--transition);
    text-decoration: none;
}

.btn-outline-accent:hover {
    background: var(--accent-dim);
    color: var(--accent);
    box-shadow: 0 0 20px var(--accent-dim);
    transform: translateY(-2px);
}


/* ==========================================================================
   PERSONA CARDS
   ========================================================================== */

.persona-card {
    text-align: center;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.persona-icon {
    width: 56px;
    height: 56px;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    background: var(--accent-purple-dim);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.25rem;
    font-size: 1.3rem;
    color: var(--accent-purple);
    transition: var(--transition);
}

.persona-card:hover .persona-icon,
.persona-card.in-view .persona-icon {
    background: rgba(124, 58, 237, 0.25);
    filter: drop-shadow(0 0 12px var(--accent-purple-glow));
}

.persona-role {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--accent-purple);
    margin-bottom: 0.5rem;
}

.persona-headline {
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}

.persona-desc {
    font-size: 1rem;
    color: var(--text-secondary);
    margin: 0;
    flex-grow: 1;
}


/* ==========================================================================
   STAT CONTRASTS (Months → Minutes style)
   ========================================================================== */

.stat-contrast {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.stat-from {
    font-family: var(--font-mono);
    font-size: 1.05rem;
    color: var(--text-muted);
    text-decoration: line-through;
    text-decoration-color: rgba(236, 72, 153, 0.5);
}

.stat-arrow {
    color: var(--accent);
    font-size: 1rem;
    opacity: 0.7;
}

.stat-to {
    font-family: var(--font-mono);
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--accent);
    text-shadow: 0 0 20px var(--accent-glow);
}


/* ==========================================================================
   SCENARIO AICAP COUNTER
   ========================================================================== */

.scenario-with-aicap {
    display: block;
    margin-top: 0.5rem;
    color: var(--accent);
    font-weight: 500;
    font-size: 0.95rem;
}


/* ==========================================================================
   BEYOND DEFENCE CARDS
   ========================================================================== */

.beyond-card {
    height: 100%;
}

.beyond-card h3 {
    font-size: 1.15rem;
    margin-bottom: 0.75rem;
}

.beyond-card p {
    font-size: 1rem;
    color: var(--text-secondary);
    margin: 0;
}


/* ==========================================================================
   CTA ACTIONS
   ========================================================================== */

.cta-actions {
    margin-top: 1rem;
}


/* ==========================================================================
   SCROLL REVEAL
   ========================================================================== */

.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}


/* ==========================================================================
   RESPONSIVE
   ========================================================================== */

@media (max-width: 991.98px) {
    .hero-section {
        padding: 8rem 0 4rem;
        min-height: auto;
    }

    .page-hero {
        padding: 8rem 0 3rem;
    }

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

    .section-dark,
    .section-darker,
    .section-cta {
        padding: 4rem 0;
    }

    .iso-shapes {
        display: none;
    }

    .iso-divider {
        height: 40px;
    }
}

@media (max-width: 575.98px) {
    .cycle-grid {
        grid-template-columns: 1fr;
    }

    .hero-title {
        font-size: 2rem;
    }

    .cta-flow {
        flex-direction: column;
    }

    .cta-flow-arrow {
        transform: rotate(90deg);
    }
}
