/* Reset & Base Variables */
:root {
    --color-brand: #7c4bd1;
    --color-brand-dark: #5c35a3;
    --color-brand-light: #f1edfa;
    --color-surface: #ffffff;
    --color-surface-alt: #f8f7fa;
    --color-surface-deep: #161224;
    --color-text-apex: #1a1525;
    --color-text-stream: #4a4559;
    --color-text-inverse: #ffffff;
    --color-border: #e6e2f0;
    
    --radius-sm: 5px;
    --radius-md: 8px;
    --radius-lg: 11px;
    
    --shadow-soft: 0 4px 12px rgba(26, 21, 37, 0.05);
    --shadow-hover: 0 8px 24px rgba(124, 75, 209, 0.12);
    
    --transition: all 0.15s ease;
    --layout-max: 1240px;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: var(--color-surface-alt);
    color: var(--color-text-stream);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

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

/* Typography */
.apex-portal {
    color: var(--color-text-inverse);
    font-size: clamp(2rem, 4vw, 2.8rem);
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: -0.02em;
    white-space: normal;
    margin-bottom: 1.5rem;
}

.apex-node {
    color: var(--color-text-apex);
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.4;
    white-space: normal;
    margin-bottom: 1rem;
}

.apex-cell {
    color: var(--color-text-apex);
    font-size: 1.125rem;
    font-weight: 600;
    line-height: 1.4;
    white-space: normal;
}

.stream-primary {
    word-break: break-word;
    overflow-wrap: break-word;
    word-break: keep-all;
}

/* Layout Utilities */
.tunnel-tunnel {
    max-width: var(--layout-max);
    margin: 0 auto;
    padding: 0 2rem;
    width: 100%;
}

/* Header (Mandatory structure) */
.crown-top {
    background-color: var(--color-surface);
    border-bottom: 1px solid var(--color-border);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nexus-tunnel {
    max-width: var(--layout-max);
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
}

.nexus-tunnel > * {
    min-width: 0;
}

.sigil img {
    height: 32px;
    width: auto;
    display: block;
}

.mesh-routes {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    align-items: center;
}

.wire-route {
    color: var(--color-text-stream);
    font-weight: 500;
    font-size: 0.95rem;
    padding: 0.5rem 0;
    position: relative;
}

.wire-route:hover,
.wire-route.active {
    color: var(--color-brand);
}

.wire-route.active::after {
    content: '';
    position: absolute;
    bottom: -1rem;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--color-brand);
    border-radius: 3px 3px 0 0;
}

/* Section 1: Acquire (Hero variant) */
.portal-split {
    background-color: var(--color-surface-deep);
    padding: 5rem 0;
    position: relative;
    overflow: hidden;
}

.portal-split::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 80%;
    height: 200%;
    background: radial-gradient(circle, rgba(124, 75, 209, 0.15) 0%, transparent 70%);
    transform: rotate(-15deg);
    pointer-events: none;
}

.tunnel-acquire {
    display: flex;
    flex-wrap: wrap;
    gap: 4rem;
    align-items: center;
}

.tunnel-acquire > * {
    min-width: 0;
}

.flare-cloak {
    flex: 1 1 500px;
    position: relative;
    z-index: 2;
}

.stream-inverse {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.125rem;
    margin-bottom: 3rem;
}

.cluster-nodes {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.cluster-nodes > * {
    min-width: 0;
}

.node-acquire {
    background-color: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    flex: 1 1 280px;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.node-acquire:hover {
    background-color: rgba(255, 255, 255, 0.08);
    border-color: var(--color-brand);
    transform: translateY(-4px);
}

.glyph-surface {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--color-brand) 0%, var(--color-brand-dark) 100%);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.glyph-surface svg {
    width: 24px;
    height: 24px;
    fill: var(--color-text-inverse);
}

.apex-inverse {
    color: var(--color-text-inverse);
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.stream-muted {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.875rem;
    margin-bottom: 1.5rem;
    flex-grow: 1;
}

.pulse-acquire {
    background-color: var(--color-surface);
    color: var(--color-surface-deep);
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-md);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    align-self: flex-start;
}

.pulse-acquire:hover {
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.2);
}

.pulse-alt {
    background-color: transparent;
    color: var(--color-surface);
    border: 1px solid rgba(255, 255, 255, 0.3);
}
.pulse-alt:hover {
    background-color: rgba(255, 255, 255, 0.1);
    box-shadow: none;
}

.flare-lens {
    flex: 1 1 400px;
    position: relative;
    z-index: 2;
}

.lens-showcase {
    width: 100%;
    height: auto;
    border-radius: var(--radius-lg);
    box-shadow: 0 24px 48px rgba(0,0,0,0.4);
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: block;
}

/* Section 2: Architecture Matrix (Aside) */
.cloak-matrix {
    padding: 5rem 0;
    background-color: var(--color-surface-alt);
}

.tunnel-matrix {
    display: flex;
    flex-wrap: wrap;
    gap: 3rem;
}

.tunnel-matrix > * {
    min-width: 0;
}

.realm-desc {
    flex: 1 1 400px;
}

.track-matrix {
    flex: 2 1 600px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.cell-matrix {
    background-color: var(--color-surface);
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
    padding: 2rem;
    box-shadow: var(--shadow-soft);
}

.cell-matrix:hover {
    box-shadow: var(--shadow-hover);
}

.glyph-accent {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--color-brand-light);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.25rem;
}

.glyph-accent svg {
    width: 20px;
    height: 20px;
    fill: var(--color-brand);
}

.lens-node {
    width: 100%;
    border-radius: var(--radius-md);
    margin-top: 2rem;
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--color-border);
}

/* Section 3: Dependencies (Aside) */
.cloak-patch {
    padding: 4rem 0;
    background-color: var(--color-surface);
    border-top: 1px solid var(--color-border);
}

.tunnel-patch {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    background-color: #fff9f0;
    border: 1px solid #ffe4b5;
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    align-items: center;
}

.tunnel-patch > * {
    min-width: 0;
}

.realm-patch-info {
    flex: 1 1 300px;
}

.apex-patch {
    color: #b06500;
    font-size: 1.25rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}

.stream-patch {
    color: #8a5300;
    font-size: 0.95rem;
}

.cluster-patch {
    flex: 2 1 400px;
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.pulse-patch {
    background-color: var(--color-surface);
    color: var(--color-text-stream);
    border: 1px solid var(--color-border);
    padding: 0.75rem 1.25rem;
    border-radius: var(--radius-md);
    font-weight: 500;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    flex: 1 1 200px;
}

.pulse-patch:hover {
    border-color: var(--color-brand);
    color: var(--color-brand);
    background-color: var(--color-brand-light);
}

.pulse-patch svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

/* Section 4: Steps (Div) */
.cloak-guide {
    padding: 5rem 0;
    background-color: var(--color-surface-alt);
    border-top: 1px solid var(--color-border);
}

.mesh-steps {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    margin-top: 3rem;
}

.mesh-steps > * {
    min-width: 0;
}

.peer-step {
    flex: 1 1 300px;
    background-color: var(--color-surface);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    border: 1px solid var(--color-border);
    position: relative;
    box-shadow: var(--shadow-soft);
}

.peer-step::before {
    content: counter(step-counter);
    counter-increment: step-counter;
    position: absolute;
    top: -15px;
    left: 2.5rem;
    width: 32px;
    height: 32px;
    background-color: var(--color-brand);
    color: var(--color-surface);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1rem;
    box-shadow: 0 4px 10px rgba(124, 75, 209, 0.3);
}

.mesh-steps {
    counter-reset: step-counter;
}

.code-block {
    background-color: var(--color-surface-alt);
    padding: 1rem;
    border-radius: var(--radius-sm);
    font-family: monospace;
    font-size: 0.85rem;
    color: var(--color-text-apex);
    margin-top: 1rem;
    border: 1px dashed var(--color-border);
    word-break: break-all;
}

/* Footer */
.tail-basin {
    background-color: var(--color-surface-deep);
    color: rgba(255, 255, 255, 0.6);
    padding: 4rem 0 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.tunnel-tail {
    display: flex;
    flex-wrap: wrap;
    gap: 3rem;
    justify-content: space-between;
}

.tunnel-tail > * {
    min-width: 0;
}

.realm-brand {
    flex: 1 1 250px;
}

.apex-brand {
    color: var(--color-text-inverse);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.mesh-tail {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    flex: 2 1 400px;
}

.track-tail {
    flex: 1 1 150px;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.track-tail strong {
    color: var(--color-text-inverse);
    margin-bottom: 0.5rem;
}

.wire-tail {
    font-size: 0.9rem;
}

.wire-tail:hover {
    color: var(--color-brand-light);
}

.realm-copyright {
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    text-align: center;
    font-size: 0.85rem;
}

/* Responsive */
@media (max-width: 768px) {
    .nexus-tunnel {
        flex-direction: column;
        gap: 1rem;
    }
    
    .apex-portal {
        font-size: 2rem;
    }
    
    .tunnel-acquire,
    .tunnel-matrix,
    .tunnel-patch,
    .mesh-steps {
        flex-direction: column;
    }
    
    .lens-showcase,
    .lens-node {
        width: 100%;
        height: auto;
    }
    
    .portal-split {
        padding: 3rem 0;
    }
}

.nexus-crown-top {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.7;
    color: var(--color-text-stream);
}
.nexus-crown-top,
.nexus-crown-top *,
.nexus-crown-top *::before,
.nexus-crown-top *::after {
    box-sizing: border-box;
}

.nexus-crown-top nav,
.nexus-crown-top div,
.nexus-crown-top section,
.nexus-crown-top article,
.nexus-crown-top aside,
.nexus-crown-top p,
.nexus-crown-top h1,
.nexus-crown-top h2,
.nexus-crown-top h3,
.nexus-crown-top h4,
.nexus-crown-top h5,
.nexus-crown-top h6,
.nexus-crown-top a {
    margin: 0;
    padding: 0;
    font: inherit;
    color: inherit;
    letter-spacing: inherit;
    line-height: inherit;
}

.nexus-crown-top p,
.nexus-crown-top h1,
.nexus-crown-top h2,
.nexus-crown-top h3,
.nexus-crown-top h4,
.nexus-crown-top h5,
.nexus-crown-top h6 {
    text-decoration: none;
}

.nexus-crown-top img {
    display: block;
    max-width: 100%;
    height: auto;
    border: 0;
}

.nexus-crown-top {
    box-shadow: none;
    filter: none;
    text-shadow: none;
    background-image: none;
    border-top: none;
    border-left: none;
    border-right: none;
    outline: none;
}

.nexus-crown-top a.nexus-wire.nexus-wire-route {
    --aisite-shell-nav-padding: 0.5rem 0;
    --aisite-shell-nav-margin: 0;
    --aisite-shell-nav-line-height: normal;
    --aisite-shell-nav-display: inline;
    --aisite-shell-nav-height: auto;
    --aisite-shell-nav-min-height: auto;
}

.nexus-crown-top a.nexus-wire.nexus-wire-route,
.nexus-crown-top a.nexus-wire.nexus-wire-route:hover,
.nexus-crown-top a.nexus-wire.nexus-wire-route:focus,
.nexus-crown-top a.nexus-wire.nexus-wire-route:active,
.nexus-crown-top a.nexus-wire.nexus-wire-route.active,
.nexus-crown-top a.nexus-wire.nexus-wire-route[aria-current="page"] {
    background: transparent;
    border: none;
    border-bottom: none;
    box-shadow: none;
    outline: none;
    text-decoration: none;
    padding: var(--aisite-shell-nav-padding, 0);
    margin: var(--aisite-shell-nav-margin, 0);
    line-height: var(--aisite-shell-nav-line-height, normal);
    display: var(--aisite-shell-nav-display, inline);
    height: var(--aisite-shell-nav-height, auto);
    min-height: var(--aisite-shell-nav-min-height, auto);
}

.nexus-crown-top .nexus-mesh{
            display: flex;
            flex-wrap: wrap;
        }

.nexus-crown-top .nexus-mesh > *{
            min-width: 0;
        }

.nexus-crown-top{
            background-color: rgba(255, 255, 255, 0.95);
            backdrop-filter: blur(10px);
            border-bottom: 1px solid #e6e2f0;
            position: sticky;
            top: 0;
            z-index: 100;
        }

.nexus-crown-top .nexus-nexus-tunnel{
            max-width: 1180px;
            margin: 0 auto;
            padding: 1rem 2rem;
            display: flex;
            flex-wrap: wrap;
            align-items: center;
            justify-content: space-between;
        }

.nexus-crown-top .nexus-sigil img{
            height: 32px;
            width: auto;
            display: block;
        }

.nexus-crown-top .nexus-mesh-routes{
            display: flex;
            flex-wrap: wrap;
            gap: 1.5rem;
            align-items: center;
        }

.nexus-crown-top .nexus-wire-route{
            text-decoration: none;
            color: #4a4559;
            font-weight: 500;
            font-size: 0.95rem;
            padding: 0.5rem 0;
            border-bottom: 2px solid transparent;
            transition: border-color 0.15s ease, color 0.15s ease;
        }

.nexus-crown-top .nexus-wire-route:hover, .nexus-crown-top .nexus-wire-route.active{
            color: #7c4bd1;
            border-bottom-color: #7c4bd1;
        }

@media (max-width: 768px){.nexus-crown-top .nexus-nexus-tunnel{
                flex-direction: column;
                gap: 1rem;
            }

.nexus-crown-top .nexus-mesh-routes{
                width: 100%;
                justify-content: center;
            }}

.nexus-crown-top {
    background: rgb(255, 255, 255);
    background-image: none;
}

.anchor-tail-anchor {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.7;
    color: var(--color-text-stream);
}
.anchor-tail-anchor,
.anchor-tail-anchor *,
.anchor-tail-anchor *::before,
.anchor-tail-anchor *::after {
    box-sizing: border-box;
}

.anchor-tail-anchor nav,
.anchor-tail-anchor div,
.anchor-tail-anchor section,
.anchor-tail-anchor article,
.anchor-tail-anchor aside,
.anchor-tail-anchor p,
.anchor-tail-anchor h1,
.anchor-tail-anchor h2,
.anchor-tail-anchor h3,
.anchor-tail-anchor h4,
.anchor-tail-anchor h5,
.anchor-tail-anchor h6,
.anchor-tail-anchor a {
    margin: 0;
    padding: 0;
    font: inherit;
    color: inherit;
    letter-spacing: inherit;
    line-height: inherit;
}

.anchor-tail-anchor p,
.anchor-tail-anchor h1,
.anchor-tail-anchor h2,
.anchor-tail-anchor h3,
.anchor-tail-anchor h4,
.anchor-tail-anchor h5,
.anchor-tail-anchor h6 {
    text-decoration: none;
}

.anchor-tail-anchor img {
    display: block;
    max-width: 100%;
    height: auto;
    border: 0;
}

.anchor-tail-anchor {
    box-shadow: none;
    filter: none;
    text-shadow: none;
    background-image: none;
    border-top: none;
    border-left: none;
    border-right: none;
    outline: none;
}

.anchor-tail-anchor a,
.anchor-tail-anchor a:hover,
.anchor-tail-anchor a:focus,
.anchor-tail-anchor a:active {
    background: transparent;
    box-shadow: none;
    outline: none;
    text-decoration: none;
}

.anchor-tail-anchor .anchor-track-tags{
            display: flex;
            flex-wrap: wrap;
            gap: 0.8rem;
            margin-bottom: 2rem;
        }

.anchor-tail-anchor{
            background-color: #161224;
            color: rgba(255, 255, 255, 0.7);
            padding: 4rem 2rem 2rem;
            margin-top: auto;
        }

.anchor-tail-anchor .anchor-basin-inner{
            max-width: 1180px;
            margin: 0 auto;
            display: flex;
            flex-direction: column;
            align-items: center;
            text-align: center;
        }

.anchor-tail-anchor .anchor-apex-brand{
            color: #ffffff;
            font-size: 1.5rem;
            font-weight: 700;
            margin-bottom: 1rem;
            letter-spacing: 1px;
        }

.anchor-tail-anchor .anchor-stream-legal{
            font-size: 0.85rem;
            border-top: 1px solid rgba(255,255,255,0.1);
            padding-top: 2rem;
            width: 100%;
            margin-top: 2rem;
        }