@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&display=swap');

:root {
    color-scheme: dark;
    --bg: #020811;
    --surface: #05101d;
    --accent: #2995ff;
    --light: #65b7ff;
    --glow: rgba(8, 124, 255, .12);
    --line: #ffffff14;
    --text: #eef3fa;
    --muted: #8491a4;
    --radius: 26px;
    font-family: Manrope, Arial, sans-serif
}

* {
    box-sizing: border-box
}

html[data-theme=human] {
    --bg: #070402;
    --surface: #100903;
    --accent: #ffb52e;
    --light: #ffd06a;
    --glow: rgba(255, 152, 0, .10);
    --muted: #a39786
}

body {
    margin: 0;
    background: #030507;
    color: var(--text);
    font-size: 14px;
    line-height: 1.65;
    min-width: 0;
    background-image: radial-gradient(ellipse at 50% 30%, #101925 0, transparent 65%)
}

a {
    color: inherit;
    text-decoration: none
}

button,
input,
textarea,
select {
    font: inherit
}

button,
a,
input,
textarea,
select {
    outline-offset: 5px
}

button {
    cursor: pointer
}

button:disabled {
    cursor: wait;
    opacity: .55
}

button:focus-visible,
a:focus-visible {
    outline: 2px solid var(--accent)
}

[hidden] {
    display: none !important
}

svg {
    display: block
}

h1,
h2,
p {
    margin: 0
}

h2 {
    font-size: clamp(17px, 1.5vw, 22px);
    font-weight: 600;
    letter-spacing: -.04em
}

input,
textarea,
select {
    background: #ffffff04;
    color: var(--text);
    border: 1px solid var(--line);
    border-radius: 9px;
    padding: 12px;
    min-width: 0
}

select option {
    background: #07101b
}

textarea {
    resize: vertical
}

input:focus,
textarea:focus,
select:focus {
    border-color: var(--accent);
    outline: none
}

.tablet {
    width: 86%;
    max-width: 1680px;
    margin: clamp(16px, 4.5vh, 60px) auto;
    background: var(--bg);
    border: 1px solid #3b4859;
    border-radius: var(--radius);
    box-shadow: 0 0 0 6px #0a0d11, 0 0 0 7px #222931, 0 24px 90px #000b, 0 0 70px var(--glow);
    overflow: hidden;
    min-height: 86vh;
    display: flex;
    flex-direction: column
}

.header {
    min-height: 90px;
    padding: 20px clamp(20px, 3vw, 52px);
    display: flex;
    align-items: center;
    gap: clamp(18px, 2.5vw, 46px);
    border-bottom: 1px solid var(--line);
    position: relative;
    z-index: 5;
    background: var(--bg)
}

.brand {
    font-size: 25px;
    font-weight: 800;
    letter-spacing: -1.5px;
    display: flex;
    gap: 7px;
    align-items: center
}

.brand-mark {
    border: 1px solid var(--accent);
    font-size: 21px;
    line-height: 28px;
    width: 29px;
    text-align: center;
    color: var(--accent);
    border-radius: 8px;
    font-weight: 400
}

.brand-slash {
    font-size: 20px;
    color: var(--accent);
    margin-left: 0
}

nav {
    display: flex;
    gap: clamp(13px, 1.5vw, 26px);
    align-items: center;
    flex: 1;
    white-space: nowrap
}

nav a {
    font-size: 12px;
    color: var(--muted);
    padding: 12px 0;
    position: relative
}

nav a:hover,
nav a[aria-current] {
    color: var(--text)
}

nav a[aria-current]:after {
    content: '';
    position: absolute;
    bottom: 3px;
    left: 0;
    width: 18px;
    height: 2px;
    background: var(--accent)
}

.header-controls {
    display: flex;
    align-items: center;
    gap: 18px
}

.icon-button {
    background: none;
    border: 0;
    color: var(--muted);
    min-width: 34px;
    min-height: 40px;
    display: grid;
    place-items: center;
    font-size: 24px
}

.language-switch {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
    letter-spacing: .1em
}

.language-switch span {
    color: #465165
}

.language-switch a {
    color: var(--muted);
    min-height: 40px;
    display: flex;
    align-items: center
}

.language-switch a[aria-current] {
    color: var(--text)
}

.theme-toggle {
    display: flex;
    border: 1px solid var(--line);
    border-radius: 20px;
    padding: 4px;
    background: none;
    color: var(--muted);
    font-size: 9px;
    letter-spacing: .05em
}

.theme-toggle span {
    padding: 7px 9px;
    border-radius: 15px
}

html[data-theme=ai] .theme-toggle span:last-child,
html[data-theme=human] .theme-toggle span:first-child {
    background: var(--glow);
    color: var(--accent)
}

.mobile-menu {
    display: none
}

main {
    flex: 1
}

footer {
    min-height: 63px;
    border-top: 1px solid var(--line);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 14px clamp(20px, 3vw, 52px);
    font-size: 9px;
    letter-spacing: .12em;
    color: var(--muted)
}

footer>span {
    display: flex;
    align-items: center;
    gap: 10px
}

.status-dot {
    display: inline-block;
    width: 5px;
    height: 5px;
    min-width: 5px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 10px var(--accent)
}

.footer-line {
    display: inline-block;
    width: 28px;
    height: 1px;
    background: var(--line)
}

.eyebrow {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: .22em;
    color: var(--accent);
    margin-bottom: 24px
}

.tiny-cross {
    font-size: 16px;
    margin-right: 12px
}

.accent {
    color: var(--accent)
}

.hero {
    position: relative;
    min-height: 650px;
    height: calc(86vh - 153px);
    max-height: 950px;
    isolation: isolate;
    overflow: hidden
}

.hero-layer {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    align-items: center;
    padding: clamp(30px, 5vw, 84px);
    overflow: hidden;
    background-color: var(--bg);
    background-image: linear-gradient(#ffffff03 1px, transparent 1px), linear-gradient(90deg, #ffffff03 1px, transparent 1px), radial-gradient(ellipse at 80% 40%, var(--glow), transparent 65%);
    background-size: 60px 60px, 60px 60px, 100% 100%
}

.human-layer {
    --bg: #070402;
    --surface: #100903;
    --accent: #ffb52e;
    --light: #ffd06a;
    --glow: #ff980010;
    --muted: #a39786
}

.ai-layer {
    --bg: #020811;
    --surface: #05101d;
    --accent: #2995ff;
    --light: #65b7ff;
    --glow: #087cff18;
    --muted: #8491a4;
    clip-path: inset(0 0 0 var(--reveal));
    z-index: 2
}

.hero-copy {
    position: relative;
    z-index: 2;
    align-self: center
}

.hero h1 {
    font-size: clamp(32px, 3.65vw, 66px);
    line-height: 1.22;
    letter-spacing: -.065em;
    font-weight: 500;
    min-height: 2.44em
}

.hero h1 span {
    display: block;
    white-space: nowrap
}

.hero-description {
    font-size: clamp(13px, 1.1vw, 17px);
    max-width: 420px;
    color: var(--muted);
    line-height: 1.9;
    margin: 28px 0 35px;
    min-height: 5.7em
}

.primary-button {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
    min-height: 49px;
    min-width: 200px;
    padding: 13px 23px;
    background: var(--accent);
    color: var(--bg);
    font-weight: 700;
    border: 0;
    border-radius: 7px;
    font-size: 12px
}

.primary-button span {
    font-size: 20px
}

.primary-button:hover {
    filter: brightness(1.15)
}

.hero-visual {
    height: 100%;
    min-height: 400px;
    position: relative;
    display: grid;
    place-items: center;
    color: var(--accent)
}

.mind {
    width: min(100%, 480px);
    height: 90%;
    filter: drop-shadow(0 0 25px var(--glow));
    position: relative;
    z-index: 1
}

.orbit {
    position: absolute;
    top: 50%;
    left: 50%;
    border: 1px solid currentColor;
    opacity: .09;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    width: 80%;
    aspect-ratio: 1
}

.orbit-two {
    width: 98%;
    border-style: dashed;
    opacity: .12
}

.orbit-three {
    width: 61%;
    opacity: .1
}

.visual-label {
    position: absolute;
    font-size: 9px;
    letter-spacing: .14em;
    color: var(--muted)
}

.label-top {
    top: 10%;
    right: 0
}

.label-bottom {
    bottom: 8%;
    right: 5%
}

.reveal-divider {
    position: absolute;
    z-index: 3;
    left: var(--reveal);
    top: 0;
    bottom: 0;
    width: 1px;
    background: linear-gradient(#ffc16280, #cce7ff, #57aaff80);
    box-shadow: 0 0 12px #9dcaff60;
    pointer-events: none
}

.reveal-divider button {
    pointer-events: auto;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 44px;
    height: 44px;
    border: 1px solid #92a5b4;
    border-radius: 50%;
    color: #d9e4ec;
    font-size: 22px;
    background: #0c131a;
    box-shadow: 0 0 30px #9dcaff20;
    touch-action: none;
    cursor: ew-resize;
    user-select: none
}

.reveal-caption {
    position: absolute;
    bottom: 24px;
    left: clamp(24px, 5vw, 84px);
    right: clamp(24px, 5vw, 84px);
    z-index: 4;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    font-size: 9px;
    letter-spacing: .12em;
    pointer-events: none;
    color: #8692a0
}

.reveal-caption>span:first-child {
    color: #ffb52e
}

.reveal-caption>span:last-child {
    color: #65b7ff
}

.page-content {
    padding: clamp(24px, 4vw, 65px);
    max-width: 1400px;
    margin: auto
}

.page-heading {
    max-width: 850px;
    margin-bottom: 38px
}

.page-heading .eyebrow {
    margin-bottom: 16px
}

.page-heading h1 {
    font-size: clamp(28px, 3.3vw, 46px);
    line-height: 1.25;
    font-weight: 500;
    letter-spacing: -.05em
}

.page-heading>p:last-child {
    color: var(--muted);
    margin-top: 17px;
    font-size: 14px;
    max-width: 660px;
    min-height: 3.3em
}

.segmented {
    display: inline-flex;
    gap: 2px;
    padding: 3px;
    border: 1px solid var(--line);
    border-radius: 8px;
    margin-bottom: 28px
}

.segmented button {
    border: 0;
    background: none;
    color: var(--muted);
    min-width: 63px;
    min-height: 38px;
    border-radius: 5px;
    font-size: 11px
}

.segmented button[aria-pressed=true] {
    color: var(--accent);
    background: var(--glow)
}

.dataset-block {
    display: grid;
    grid-template-columns: 80px 1fr;
    gap: 30px;
    border-top: 1px solid var(--line);
    padding: 32px 0
}

.dataset-index {
    font-size: 30px;
    font-weight: 500;
    color: var(--accent)
}

.dataset-index span {
    display: block;
    font-size: 10px;
    letter-spacing: .15em;
    color: var(--muted)
}

.dataset-main>p {
    color: var(--muted);
    font-size: 13px;
    margin-top: 8px;
    max-width: 740px
}

.dataset-stats,
.model-metrics {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin: 25px 0;
    max-width: 700px
}

.dataset-stats strong,
.model-metrics strong {
    display: block;
    font-size: clamp(22px, 2.5vw, 32px);
    font-weight: 500;
    letter-spacing: -.04em
}

.dataset-stats span,
.model-metrics span {
    display: block;
    font-size: 10px;
    color: var(--muted)
}

.dataset-fields {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    align-items: center;
    margin-bottom: 20px
}

.dataset-fields small {
    color: var(--muted);
    margin-right: 8px
}

code {
    font-family: Consolas, monospace;
    font-size: 11px;
    color: var(--light);
    overflow-wrap: anywhere
}

.dataset-fields code {
    padding: 3px 7px;
    border: 1px solid var(--line);
    border-radius: 4px
}

details {
    margin: 18px 0;
    color: var(--muted);
    font-size: 12px
}

summary {
    cursor: pointer;
    min-height: 30px
}

details p {
    margin: 10px 0
}

blockquote {
    border-left: 2px solid var(--accent);
    margin: 12px 0;
    padding: 8px 15px;
    color: var(--text);
    background: var(--glow);
    font-size: 12px
}

.text-link {
    font-size: 11px;
    color: var(--accent);
    display: inline-block;
    min-height: 32px
}

.fine-print {
    font-size: 11px;
    color: var(--muted);
    line-height: 1.8
}

.empty-state {
    padding: 24px 0;
    color: var(--muted);
    font-size: 12px
}

.model-section {
    display: grid;
    grid-template-columns: 60px 1fr;
    gap: 30px;
    padding: 30px 0;
    border-top: 1px solid var(--line)
}

.model-number {
    color: var(--accent);
    font-size: 23px
}

.model-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap
}

.badge {
    font-size: 9px;
    color: var(--accent);
    padding: 5px 10px;
    border: 1px solid var(--line);
    border-radius: 20px;
    letter-spacing: .06em
}

.model-body>p {
    font-size: 12px;
    color: var(--muted);
    margin-top: 8px
}

.preprocess-input {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 14px;
    align-items: center;
    max-width: 1000px
}

.preprocess-input label {
    grid-column: 1/-1;
    font-size: 11px;
    color: var(--muted)
}

.preprocess-input textarea {
    height: 78px
}

.pipeline {
    margin: 35px 0
}

.pipeline-step {
    position: relative;
    padding: 0 0 28px 38px;
    border-left: 1px solid var(--line);
    margin-left: 9px
}

.pipeline-step:last-child {
    border-left-color: transparent
}

.pipeline-node {
    position: absolute;
    top: 8px;
    left: -5px;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 14px var(--glow)
}

.pipeline-step h2 {
    font-size: 15px
}

.step-result {
    color: var(--muted);
    font-size: 12px;
    margin-top: 8px;
    white-space: pre-wrap;
    overflow-wrap: anywhere
}

.token {
    display: inline-block;
    padding: 3px 7px;
    background: var(--glow);
    color: var(--light);
    border: 1px solid var(--line);
    border-radius: 5px;
    margin: 3px
}

.dialogue-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) minmax(280px, 1fr);
    gap: 24px
}

.chat-panel,
.analysis-panel,
.chart-panel {
    border: 1px solid var(--line);
    border-radius: 14px;
    background: linear-gradient(135deg, #ffffff02, transparent);
    min-width: 0
}

.panel-header {
    padding: 20px;
    border-bottom: 1px solid var(--line);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px
}

.panel-header h2 {
    font-size: 13px
}

.text-button {
    background: none;
    color: var(--accent);
    font-size: 10px;
    border: 0;
    min-height: 34px
}

.chat-panel {
    display: flex;
    flex-direction: column;
    min-height: 480px
}

.welcome {
    padding: 35px 25px;
    color: var(--muted);
    max-width: 420px;
    font-size: 13px
}

.ai-symbol {
    display: block;
    color: var(--accent);
    font-size: 30px;
    margin-bottom: 16px
}

#chat-messages {
    height: 350px;
    overflow-y: auto;
    padding: 15px;
    scroll-behavior: smooth;
    flex: 1
}

.message {
    padding: 12px 15px;
    font-size: 12px;
    border: 1px solid var(--line);
    border-radius: 12px;
    margin: 10px 0;
    max-width: 90%;
    white-space: pre-wrap;
    overflow-wrap: anywhere
}

.message.user {
    margin-left: auto;
    background: var(--glow);
    border-color: color-mix(in srgb, var(--accent) 25%, transparent)
}

.message.assistant {
    margin-right: auto;
    background: #ffffff03
}

.message-role {
    display: block;
    font-size: 8px;
    letter-spacing: .15em;
    color: var(--accent);
    margin-bottom: 6px
}

#chat-form {
    margin: 15px;
    position: relative
}

#chat-form textarea {
    width: 100%;
    padding-right: 60px;
    min-height: 75px;
    max-height: 180px;
    resize: vertical
}

.send-button {
    position: absolute;
    right: 12px;
    bottom: 17px;
    border: 0;
    border-radius: 9px;
    width: 36px;
    height: 36px;
    background: var(--accent);
    color: var(--bg);
    font-size: 23px
}

.chat-note {
    padding: 0 18px 16px;
    font-size: 9px
}

.analysis-panel>label {
    display: block;
    margin: 18px 20px 5px
}

.analysis-panel>select {
    margin: 0 20px;
    width: calc(100% - 40px);
    font-size: 11px
}

#analysis-output {
    padding: 20px
}

.analysis-row {
    padding: 12px 0;
    border-bottom: 1px solid var(--line)
}

.analysis-row>span {
    display: block;
    font-size: 9px;
    letter-spacing: .1em;
    color: var(--muted);
    margin-bottom: 7px
}

.analysis-value {
    font-size: 12px;
    color: var(--light);
    overflow-wrap: anywhere
}

.analysis-value pre {
    white-space: pre-wrap;
    font-size: 10px;
    margin: 0;
    color: var(--text)
}

[role=alert] {
    color: #f48b80;
    font-size: 12px;
    margin-top: 14px
}

.analytics-filters {
    display: flex;
    align-items: end;
    gap: 18px;
    flex-wrap: wrap;
    margin-bottom: 28px
}

.analytics-filters label {
    display: flex;
    flex-direction: column;
    font-size: 10px;
    color: var(--muted);
    gap: 7px
}

.analytics-filters select {
    font-size: 12px;
    min-width: 125px
}

.analytics-filters>.text-link {
    margin-left: auto
}

.dashboard {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px
}

.chart-panel {
    padding: 24px
}

.chart-panel.wide {
    grid-column: 1/-1
}

.chart-panel h2 {
    font-size: 15px;
    margin-bottom: 25px
}

.bar-row {
    display: grid;
    grid-template-columns: minmax(110px, 1.3fr) minmax(0, 2fr) 45px;
    gap: 12px;
    align-items: center;
    margin: 13px 0;
    font-size: 10px
}

.bar-label {
    overflow-wrap: anywhere;
    color: var(--muted)
}

.bar-track {
    height: 5px;
    border-radius: 5px;
    background: #ffffff07
}

.bar-fill {
    height: 100%;
    background: var(--accent);
    border-radius: 5px;
    min-width: 1px
}

.bar-value {
    color: var(--light);
    text-align: right;
    font-variant-numeric: tabular-nums
}

.matrix-scroll,
.table-scroll {
    overflow: auto;
    max-width: 100%;
    max-height: 330px
}

table {
    border-collapse: collapse;
    width: 100%;
    font-size: 10px
}

th,
td {
    padding: 8px;
    text-align: left;
    border-bottom: 1px solid var(--line);
    overflow-wrap: anywhere
}

th {
    color: var(--muted);
    font-weight: 500
}

.matrix-table th {
    font-size: 8px;
    min-width: 65px
}

.matrix-table td {
    text-align: center;
    min-width: 30px;
    border: 2px solid var(--bg)
}

.experiment-note {
    color: var(--muted);
    font-size: 10px;
    margin: 15px 0;
    overflow-wrap: anywhere
}

dialog {
    max-width: min(90vw, 540px);
    width: 100%;
    border: 1px solid #3b4859;
    background: var(--bg);
    color: var(--text);
    border-radius: 16px;
    padding: 30px;
    box-shadow: 0 20px 100px #000a
}

dialog::backdrop {
    background: #000b;
    backdrop-filter: blur(5px)
}

dialog>label {
    display: block;
    margin-bottom: 15px
}

dialog input {
    width: 100%
}

.close-search {
    position: absolute;
    right: 10px;
    top: 10px
}

#search-results {
    display: grid;
    margin-top: 15px
}

#search-results a {
    padding: 10px;
    border-bottom: 1px solid var(--line);
    font-size: 13px
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0)
}

body>input[name=csrfmiddlewaretoken] {
    display: none
}

@media(min-width:1024px) and (max-width:1439px) {
    .tablet {
        width: 92%
    }

    .header {
        gap: 20px;
        padding: 18px 25px
    }

    nav {
        gap: 15px
    }

    nav a {
        font-size: 11px
    }

    .header-controls {
        gap: 10px
    }

    .hero h1 {
        font-size: clamp(30px, 3.65vw, 52px)
    }

    .hero-layer {
        padding: 45px
    }

    .hero-description {
        max-width: 340px
    }

    .theme-toggle span {
        padding: 6px
    }
}

@media(max-width:1023px) {
    .tablet {
        width: 97%;
        margin: 18px auto;
        border-radius: 20px;
        box-shadow: 0 0 0 3px #0a0d11, 0 0 0 4px #222931, 0 20px 70px #000a
    }

    .header {
        min-height: 77px;
        padding: 14px 22px;
        gap: 20px
    }

    .mobile-menu {
        display: grid;
        margin-left: auto
    }

    .header-controls {
        gap: 12px
    }

    nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        padding: 18px 22px;
        background: var(--bg);
        border-bottom: 1px solid var(--line);
        grid-template-columns: repeat(3, 1fr);
        gap: 10px
    }

    nav.open {
        display: grid
    }

    nav a {
        padding: 12px;
        font-size: 13px
    }

    .hero {
        min-height: 630px;
        height: calc(86vh - 140px)
    }

    .hero-layer {
        padding: 35px
    }

    .hero h1 {
        font-size: clamp(27px, 3.6vw, 40px)
    }

    .hero-description {
        max-width: 290px;
        font-size: 13px
    }

    .hero-visual {
        min-height: 330px
    }

    .primary-button {
        min-width: 180px
    }

    .page-heading {
        margin-bottom: 26px
    }

    .dialogue-grid {
        grid-template-columns: minmax(0, 1.2fr) minmax(250px, 1fr)
    }

    .panel-header {
        padding: 14px
    }

    .panel-header h2 {
        font-size: 12px
    }

    .dataset-block {
        gap: 20px;
        grid-template-columns: 55px 1fr
    }
}

@media(max-width:767px) {
    body {
        font-size: 13px
    }

    .tablet {
        width: calc(100% - 18px);
        margin: 12px auto;
        min-height: calc(100vh - 24px);
        border-radius: 17px
    }

    .header {
        gap: 8px;
        padding: 12px 15px;
        min-height: 72px;
        flex-wrap: wrap
    }

    .brand {
        font-size: 22px
    }

    .brand-mark {
        width: 26px;
        line-height: 25px
    }

    .header-controls {
        gap: 6px
    }

    .theme-toggle {
        font-size: 8px
    }

    .theme-toggle span {
        padding: 5px
    }

    .language-switch {
        gap: 5px
    }

    .icon-button {
        min-width: 30px
    }

    nav {
        grid-template-columns: repeat(2, 1fr)
    }

    .hero {
        height: 780px;
        min-height: 780px;
        max-height: none
    }

    .hero-layer {
        grid-template-columns: 1fr;
        grid-template-rows: 350px 1fr;
        padding: 30px 24px 65px;
        align-items: start
    }

    .hero-copy {
        align-self: start;
        padding-top: 18px
    }

    .hero h1 {
        font-size: clamp(23px, 6.1vw, 42px);
        line-height: 1.25
    }

    .hero h1 span {
        white-space: normal
    }

    .hero-description {
        margin: 22px 0;
        max-width: 310px;
        min-height: 5.7em;
        font-size: 12px
    }

    .eyebrow {
        font-size: 8px;
        margin-bottom: 21px
    }

    .hero-visual {
        height: 340px;
        min-height: 0;
        width: 100%;
        max-width: 420px;
        justify-self: center
    }

    .mind {
        height: 100%
    }

    .label-top {
        top: 1%;
        right: 5%
    }

    .label-bottom {
        bottom: 0
    }

    .reveal-caption {
        left: 22px;
        right: 22px;
        bottom: 20px;
        font-size: 7px;
        gap: 10px
    }

    .reveal-caption>span:nth-child(2) {
        text-align: center;
        max-width: 150px
    }

    .reveal-divider button {
        width: 42px;
        height: 42px
    }

    footer {
        font-size: 7px;
        gap: 10px;
        padding: 15px;
        align-items: start
    }

    footer>span {
        gap: 7px;
        flex-wrap: wrap
    }

    footer>span:last-child {
        justify-content: end;
        text-align: right
    }

    .page-content {
        padding: 30px 20px
    }

    .page-heading h1 {
        font-size: 30px
    }

    .page-heading>p:last-child {
        font-size: 12px
    }

    .dataset-block {
        grid-template-columns: 1fr;
        gap: 12px;
        padding: 24px 0
    }

    .dataset-index {
        font-size: 20px;
        display: flex;
        gap: 12px;
        align-items: center
    }

    .dataset-stats,
    .model-metrics {
        grid-template-columns: repeat(2, 1fr);
        gap: 18px
    }

    .dataset-main h2 {
        font-size: 19px;
        overflow-wrap: anywhere
    }

    .model-section {
        grid-template-columns: 1fr;
        gap: 12px
    }

    .model-title {
        align-items: start
    }

    .model-title h2 {
        font-size: 19px
    }

    .preprocess-input {
        grid-template-columns: 1fr
    }

    .preprocess-input .primary-button {
        justify-self: start
    }

    .pipeline-step {
        padding-left: 24px
    }

    .dialogue-grid {
        grid-template-columns: 1fr;
        gap: 18px
    }

    .chat-panel {
        min-height: 400px
    }

    #chat-messages {
        height: 310px;
        min-height: 240px;
        flex: auto
    }

    .analysis-panel {
        min-height: 200px
    }

    .panel-header h2 {
        font-size: 13px
    }

    .dashboard {
        grid-template-columns: 1fr
    }

    .chart-panel.wide {
        grid-column: auto
    }

    .chart-panel {
        padding: 20px
    }

    .analytics-filters {
        gap: 12px
    }

    .analytics-filters label {
        flex: 1;
        min-width: 90px
    }

    .analytics-filters select {
        min-width: 0;
        width: 100%;
        padding: 10px 6px;
        font-size: 10px
    }

    .analytics-filters>.text-link {
        margin-left: 0
    }

    .bar-row {
        grid-template-columns: minmax(70px, 1fr) minmax(60px, 1fr) 38px;
        gap: 8px;
        font-size: 9px
    }
}

@media(prefers-reduced-motion:reduce) {
    * {
        scroll-behavior: auto !important;
        transition: none !important
    }
}

.hero .primary-button {
    width: 230px;
    max-width: 100%;
    min-width: 0;
    gap: 15px
}

@media(max-width:767px) {

    .icon-button,
    .mobile-menu {
        min-width: 40px;
        min-height: 44px
    }

    .language-switch a {
        min-height: 44px
    }

    .theme-toggle {
        min-height: 44px
    }

    .send-button {
        width: 44px;
        height: 44px
    }

    .segmented button {
        min-height: 44px
    }

    .text-button {
        min-height: 44px
    }

    .header-controls {
        margin-left: auto
    }
}

/* Reference-led cinematic homepage. Inner research pages retain their layout. */
body[data-section=home] {
    background: #0b1425;
    background-image: radial-gradient(ellipse at 52% 87%, #18386680, transparent 48%), radial-gradient(ellipse at 50% 8%, #24324880, transparent 68%);
    min-height: 100vh;
    padding: 1px 0 70px
}

body[data-section=home] .tablet {
    --reveal: 50%;
    width: 92%;
    max-width: 1520px;
    margin: clamp(85px, 17vh, 190px) auto 35px;
    min-height: 0;
    position: relative;
    overflow: visible;
    border-radius: 22px;
    border: 1px solid #79695380;
    background: #030608;
    box-shadow: 0 0 0 3px #020304, 0 0 0 4px #81776540, 0 35px 80px #000b
}

body[data-section=home] .tablet:before {
    content: '←  HUMAN           AI  →';
    position: absolute;
    top: -43px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 17px;
    letter-spacing: 5px;
    white-space: pre;
    color: #eef6ff;
    text-shadow: -66px 0 13px #ffae5c, 66px 0 13px #138aff
}

body[data-section=home] .tablet:after {
    content: '';
    position: absolute;
    top: -105px;
    bottom: -105px;
    left: var(--reveal);
    width: 2px;
    background: linear-gradient(transparent, #ffd6aa 19%, #fff4df 48%, #bde8ff 64%, #328fff 85%, transparent);
    box-shadow: -3px 0 15px #ffb96699, 3px 0 17px #208dffcc;
    z-index: 6;
    pointer-events: none
}

body[data-section=home] .header {
    height: 78px;
    min-height: 78px;
    padding: 15px 4.2%;
    background: #05070ab3;
    border-radius: 21px 21px 0 0;
    border-bottom: 0;
    gap: 5.5%
}

body[data-section=home] .brand {
    font-size: 25px;
    font-weight: 500;
    letter-spacing: 5px;
    white-space: nowrap
}

body[data-section=home] .brand-mark {
    display: none
}

body[data-section=home] .brand-slash {
    font-size: 0;
    margin-left: -4px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #ffcb95;
    box-shadow: 0 0 10px #ffb36b88
}

body[data-section=home] nav {
    gap: clamp(13px, 2vw, 31px)
}

body[data-section=home] nav a {
    font-size: 10px;
    letter-spacing: .12em;
    color: #c2c2c8
}

body[data-section=home] nav a[aria-current]:after {
    background: #3c9fff;
    box-shadow: 0 0 8px #208aff
}

body[data-section=home] footer {
    display: none
}

body[data-section=home] .hero {
    height: clamp(550px, 65vh, 760px);
    min-height: 550px;
    max-height: none;
    border-radius: 0 0 21px 21px;
    overflow: hidden
}

body[data-section=home] .hero-layer {
    display: block;
    padding: 0;
    background: #04070b;
    background-image: linear-gradient(90deg, #ffffff04 1px, transparent 1px);
    background-size: 8.3% 100%
}

body[data-section=home] .human-layer {
    background-color: #090807
}

.hero-atmosphere {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: radial-gradient(ellipse at 18% 8%, #d17b3130, transparent 35%), radial-gradient(ellipse at 36% 96%, #be74342b, transparent 34%), radial-gradient(ellipse at 52% 52%, #9e72451b, transparent 55%)
}

.hero-atmosphere:after {
    content: '';
    position: absolute;
    inset: 0;
    opacity: .32;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 350 350' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.75' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' opacity='.27' filter='url(%23n)'/%3E%3C/svg%3E");
    mix-blend-mode: screen
}

.ai-layer .hero-atmosphere {
    background: radial-gradient(ellipse at 45% 65%, #0933713b, transparent 65%)
}

body[data-section=home] .hero-copy {
    position: absolute;
    left: 15%;
    top: 15%;
    width: 36%;
    z-index: 3
}

body[data-section=home] .eyebrow {
    font-size: 9px;
    letter-spacing: .28em;
    margin-bottom: 19px;
    color: #ddd8d1;
    font-weight: 500;
    white-space: nowrap
}

body[data-section=home] .eyebrow span {
    margin: 0 7px;
    color: #aea295
}

body[data-section=home] .eyebrow strong {
    font-weight: 600;
    color: #ffcb97;
    text-shadow: 0 0 15px #ffb05688
}

.ai-layer .eyebrow strong {
    color: #64b8ff !important;
    text-shadow: 0 0 15px #208dff !important
}

body[data-section=home] .hero h1 {
    font-family: Arial, sans-serif;
    font-size: clamp(104px, 10.5vw, 175px);
    font-weight: 400;
    letter-spacing: .075em;
    line-height: 1;
    min-height: 0;
    margin-left: -8px;
    color: #f3f4f7;
    background: linear-gradient(110deg, #ffcb88 3%, #fff1dc 22%, #fbfbff 58%);
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(-7px 0 17px #ffba7135)
}

body[data-section=home] .ai-layer h1 {
    background-image: linear-gradient(110deg, #7bbdff, #f5faff 55%);
    filter: drop-shadow(-7px 0 17px #408fff45)
}

.hero-subtitle {
    font-size: clamp(12px, 1.25vw, 20px);
    letter-spacing: .38em;
    line-height: 1.85;
    font-weight: 500;
    margin-top: 14px;
    color: #f3f3f4;
    white-space: nowrap
}

body[data-section=home] .hero-description {
    font-size: clamp(12px, 1.08vw, 17px);
    line-height: 1.6;
    color: #c5c3c1;
    min-height: 0;
    margin: 24px 0 39px;
    padding-left: 22px;
    border-left: 2px solid #ffc891;
    box-shadow: -8px 0 14px -10px #ffbd70;
    max-width: 420px
}

body[data-section=home] .hero .primary-button {
    width: 205px;
    min-height: 50px;
    max-width: 100%;
    background: #0002;
    border: 1px solid #d1a471;
    border-radius: 0;
    color: #f7f4ef;
    font-size: 10px;
    letter-spacing: .24em;
    text-transform: uppercase;
    box-shadow: inset 0 0 22px #b7772510;
    padding: 12px 23px
}

body[data-section=home] .hero .primary-button span {
    color: #ffcd91;
    font-size: 23px;
    text-shadow: 0 0 9px #ffb777
}

body[data-section=home] .ai-layer .primary-button {
    border-color: #379afa
}

.ai-layer .primary-button span {
    color: #6bbfff !important;
    text-shadow: 0 0 9px #1c85ff !important
}

body[data-section=home] .hero-visual {
    position: absolute;
    right: 0;
    bottom: 0;
    width: 53%;
    height: 100%;
    min-height: 0;
    display: block
}

.ai-portrait {
    position: absolute;
    height: 112%;
    width: 112%;
    object-fit: contain;
    object-position: center bottom;
    bottom: -3%;
    left: -5%;
    max-width: none;
    mask-image: linear-gradient(to right, transparent 0%, #000 12%, #000 94%, transparent), linear-gradient(to bottom, transparent, #000 9%, #000 93%, transparent);
    mask-composite: intersect
}

.human-layer .ai-portrait {
    filter: sepia(1) saturate(1.55) hue-rotate(345deg);
    opacity: .85
}

.portrait-note {
    position: absolute;
    color: #c7ccd6;
    z-index: 2;
    font-size: 12px;
    line-height: 1.5;
    font-weight: 400
}

.portrait-note b {
    color: #2999ff;
    font-weight: 400
}

.human-layer .portrait-note b {
    color: #ffbc75
}

.note-understanding {
    left: 3%;
    top: 19%;
    font-size: 10px
}

.note-bubble {
    right: 7%;
    top: 11%;
    border: 1px solid #207dfc80;
    border-radius: 18px;
    padding: 11px 18px;
    background: #020a16b3;
    box-shadow: inset 0 0 20px #045ec033;
    color: #eff5ff;
    white-space: nowrap
}

.note-bubble:first-letter {
    color: #57aaff
}

.note-meaning {
    right: 6%;
    top: 53%
}

.note-dialogue {
    right: 8%;
    bottom: 17%;
    font-size: 13px
}

.human-layer .note-bubble {
    border-color: #ffba7770;
    background: #120a06b3
}

.portrait-cross {
    position: absolute;
    color: #78b4ec;
    font-size: 17px;
    opacity: .7
}

.cross-one {
    top: 15%;
    left: 0
}

.cross-two {
    right: 14%;
    bottom: 30%
}

.hero-index {
    position: absolute;
    left: 3.3%;
    top: 40%;
    display: grid;
    gap: 20px;
    color: #969293;
    font-size: 9px;
    letter-spacing: .1em
}

.hero-index span:first-child {
    color: #ffd0a0;
    text-shadow: 0 0 10px #ffb169
}

.hero-index:after {
    content: '';
    position: absolute;
    left: -10px;
    top: 27px;
    bottom: -7px;
    width: 1px;
    background: linear-gradient(#f5c394, #857b6860)
}

.hero-dots {
    position: absolute;
    bottom: 6%;
    left: 4%;
    font-size: 22px;
    line-height: .5;
    letter-spacing: 3px;
    color: #ffd4aa;
    opacity: .7
}

body[data-section=home] .reveal-divider {
    z-index: 7;
    background: #fff4db;
    box-shadow: -4px 0 20px #ffb565, 4px 0 20px #1a87ff
}

body[data-section=home] .reveal-divider button {
    width: 58px;
    height: 58px;
    font-size: 0;
    border: 1px solid #d4edff;
    background: #02070ded;
    box-shadow: -5px 0 12px #ffb16c, 5px 0 12px #138dff;
    color: #f2f7fc
}

body[data-section=home] .reveal-divider button:after {
    content: '‹ ›';
    font-size: 25px;
    letter-spacing: 3px
}

body[data-section=home] .reveal-caption {
    bottom: 12px;
    justify-content: center;
    font-size: 10px;
    letter-spacing: .12em;
    opacity: .55
}

body[data-section=home] .reveal-caption>span:first-child,
body[data-section=home] .reveal-caption>span:last-child {
    display: none
}

@media(max-width:1100px) {
    body[data-section=home] .header {
        gap: 25px;
        padding: 12px 3%
    }

    body[data-section=home] .hero-copy {
        left: 12%;
        top: 17%;
        width: 39%
    }

    body[data-section=home] .hero h1 {
        font-size: 12vw
    }

    .hero-subtitle {
        font-size: 1.4vw;
        letter-spacing: .3em
    }

    .note-understanding {
        display: none
    }

    .note-meaning {
        right: 4%;
        font-size: 10px
    }

    .note-dialogue {
        font-size: 11px
    }

    .note-bubble {
        right: 4%;
        padding: 8px 12px;
        font-size: 10px
    }
}

@media(max-width:767px) {
    body[data-section=home] {
        padding-bottom: 25px
    }

    body[data-section=home] .tablet {
        width: calc(100% - 24px);
        margin: 80px auto 25px;
        border-radius: 17px
    }

    body[data-section=home] .tablet:before {
        font-size: 11px;
        letter-spacing: 3px;
        top: -35px
    }

    body[data-section=home] .tablet:after {
        top: -55px;
        bottom: -30px
    }

    body[data-section=home] .header {
        min-height: 74px;
        height: auto;
        padding: 12px 15px;
        gap: 8px;
        border-radius: 17px 17px 0 0
    }

    body[data-section=home] .brand {
        font-size: 22px;
        letter-spacing: 3px
    }

    body[data-section=home] nav {
        background: #060a11;
        gap: 10px
    }

    body[data-section=home] nav a {
        font-size: 11px;
        letter-spacing: .04em
    }

    body[data-section=home] .hero {
        height: 790px;
        min-height: 790px;
        border-radius: 0 0 16px 16px
    }

    body[data-section=home] .hero-copy {
        left: 12%;
        top: 5%;
        width: 80%;
        padding: 0
    }

    body[data-section=home] .eyebrow {
        font-size: 7px;
        letter-spacing: .17em;
        margin-bottom: 16px
    }

    body[data-section=home] .eyebrow span {
        margin: 0 3px
    }

    body[data-section=home] .hero h1 {
        font-size: clamp(86px, 23vw, 155px);
        letter-spacing: .05em;
        margin-left: -5px
    }

    .hero-subtitle {
        font-size: 11px;
        letter-spacing: .28em;
        margin-top: 10px;
        line-height: 1.9
    }

    body[data-section=home] .hero-description {
        font-size: 11px;
        margin: 20px 0 24px;
        padding-left: 12px
    }

    body[data-section=home] .hero .primary-button {
        width: 195px;
        font-size: 9px;
        padding: 10px 16px;
        min-height: 46px
    }

    body[data-section=home] .hero-visual {
        width: 100%;
        height: 420px;
        bottom: 0;
        max-width: none
    }

    .ai-portrait {
        width: 115%;
        height: 115%;
        left: -5%;
        bottom: -7%
    }

    .note-bubble {
        top: 11%;
        right: 3%;
        font-size: 9px;
        padding: 8px 10px
    }

    .note-meaning {
        top: 55%;
        font-size: 9px;
        right: 3%
    }

    .note-dialogue {
        bottom: 15%;
        font-size: 9px;
        right: 4%
    }

    .hero-index {
        left: 4%;
        top: 16%;
        gap: 12px;
        font-size: 7px
    }

    .hero-index:after {
        left: -5px;
        top: 20px
    }

    .hero-dots {
        display: none
    }

    .portrait-cross {
        font-size: 12px
    }

    .cross-one {
        top: 7%;
        left: 7%
    }

    body[data-section=home] .reveal-divider button {
        width: 46px;
        height: 46px
    }

    body[data-section=home] .reveal-caption {
        bottom: 7px;
        font-size: 9px
    }

    .note-understanding {
        display: none
    }
}

body[data-section=home] .hero {
    isolation: auto
}

body[data-section=home] .hero h1 {
    mask-image: linear-gradient(to bottom, #000 0%, #000 34%, transparent 34%, transparent 37%, #000 37%, #000 100%)
}

.hero-atmosphere:after {
    opacity: .13
}

body[data-section=home] .reveal-divider button:after {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    white-space: nowrap;
    font-size: 25px;
    line-height: 1;
    letter-spacing: 2px
}

.ai-portrait {
    mask-image: linear-gradient(to right, transparent 0%, #000 16%, #000 86%, transparent 100%);
    mask-composite: add
}

body[data-section=home] .hero h1 {
    mask-image: none
}

/* Stronger amber / electric-blue grade, matched to the supplied colour reference. */
body[data-section=home] {
    background-color: #020304;
    background-image: radial-gradient(ellipse at 20% 43%, #a451082b, transparent 54%), radial-gradient(ellipse at 78% 49%, #075ad92e, transparent 55%), radial-gradient(ellipse at 50% 94%, #ff900022, transparent 40%)
}

body[data-section=home] .tablet {
    border-color: #ffc169b0;
    box-shadow: 0 0 0 3px #020304, 0 0 0 4px #a274292a, -20px 8px 100px #ff850014, 20px 8px 100px #087aff16, 0 35px 80px #000b
}

body[data-section=home] .human-layer {
    background-color: #050300;
    --accent: #ffb014;
    --light: #ffe08a
}

.hero-atmosphere {
    background-image: radial-gradient(ellipse at 0% 10%, #ff93003b, transparent 31%), radial-gradient(ellipse at 46% 90%, #ff920034, transparent 35%), linear-gradient(#0005, #0004), url('images/amber-nebula-v3.png');
    background-size: cover;
    background-position: center;
    opacity: .85
}

.ai-layer .hero-atmosphere {
    background-image: radial-gradient(ellipse at 12% 10%, #ff930030, transparent 40%), linear-gradient(#0008, #0005), url('images/amber-nebula-v3.png');
    filter: hue-rotate(175deg) saturate(1.3);
    background-size: cover;
    background-position: center;
    opacity: .55
}

.human-layer .ai-portrait {
    filter: sepia(1) saturate(4.4) hue-rotate(346deg) brightness(1.22) contrast(1.12) drop-shadow(0 0 14px #ffac0040);
    opacity: 1
}

.ai-layer .ai-portrait {
    filter: saturate(1.35) contrast(1.1) brightness(1.08) drop-shadow(0 0 14px #008cff33)
}

body[data-section=home] .hero h1 {
    background-image: linear-gradient(105deg, #ffc94c 3%, #ffda83 27%, #fff3d8 48%, #fff 75%);
    filter: drop-shadow(-5px 0 16px #ff9f0080)
}

body[data-section=home] .ai-layer h1 {
    background-image: linear-gradient(105deg, #45a6ff, #c5e8ff 48%, #fff 75%);
    filter: drop-shadow(-5px 0 16px #007eff80)
}

body[data-section=home] .eyebrow strong {
    color: #ffbe37;
    text-shadow: 0 0 6px #ff8c00, 0 0 18px #ff9700
}

body[data-section=home] .hero-description {
    color: #e1ddd5;
    border-left-color: #ffbf3e;
    box-shadow: -7px 0 16px -7px #ffa600
}

body[data-section=home] .ai-layer .hero-description {
    border-left-color: #43b1ff;
    box-shadow: -7px 0 16px -7px #148dff
}

body[data-section=home] .hero .primary-button {
    border-color: #ffb722;
    box-shadow: -2px 0 9px #ff9b0055, inset 0 0 20px #ff9f0010;
    color: #fff6e2
}

body[data-section=home] .hero .primary-button:hover {
    background: #ffb31c18;
    box-shadow: 0 0 23px #ff9b0040
}

body[data-section=home] .ai-layer .primary-button {
    border-color: #37acff;
    box-shadow: -2px 0 9px #008cff66, inset 0 0 20px #008cff10
}

body[data-section=home] nav a[aria-current]:after {
    background: #ffb520;
    box-shadow: 0 0 10px #ff9a00
}

body[data-section=home] .brand-slash {
    background: #ffb62c;
    box-shadow: 0 0 6px #ffc72f, 0 0 15px #ff8500
}

.human-layer .note-bubble {
    border-color: #ffae2ba8;
    box-shadow: inset 0 0 22px #ff900025, 0 0 18px #ff950017;
    color: #fff0bf;
    background: #0c0601db
}

.human-layer .portrait-note b,
.human-layer .portrait-cross {
    color: #ffc342;
    text-shadow: 0 0 8px #ff9800
}

.human-layer .hero-index span:first-child,
.human-layer .hero-dots {
    color: #ffc550;
    text-shadow: 0 0 10px #ff9200
}

body[data-section=home] .tablet:after {
    box-shadow: -4px 0 22px #ffac00bb, 4px 0 22px #008affcc
}

/* Isolate both scenes: Human copy must never paint above the clipped AI scene. */
body[data-section=home] .human-layer {
    z-index: 1
}

body[data-section=home] .reveal-divider button {
    transform: translate(calc(-50% + var(--handle-offset, 0px)), -50%)
}

body[data-section=home][data-reveal-mode=ai] {
    background-image: radial-gradient(ellipse at 50% 50%, #075ad935, transparent 65%)
}

body[data-section=home][data-reveal-mode=ai] .tablet {
    border-color: #48acffd0;
    box-shadow: 0 0 0 3px #020304, 0 0 0 4px #2360a040, 0 0 100px #087aff25, 0 35px 80px #000b
}

body[data-section=home][data-reveal-mode=ai] .brand-slash {
    background: #55b9ff;
    box-shadow: 0 0 6px #63bfff, 0 0 15px #008aff
}

body[data-section=home][data-reveal-mode=ai] nav a[aria-current]:after {
    background: #48b5ff;
    box-shadow: 0 0 10px #008cff
}

body[data-section=home][data-reveal-mode=ai] .tablet:after {
    background: linear-gradient(transparent, #48b5ff 19%, #d7efff 48%, #48b5ff 85%, transparent);
    box-shadow: 0 0 22px #008affcc
}

body[data-section=home][data-reveal-mode=ai] .reveal-divider {
    background: #76c9ff;
    box-shadow: 0 0 20px #008cff
}

body[data-section=home][data-reveal-mode=ai] .reveal-divider button {
    border-color: #76c9ff;
    box-shadow: 0 0 14px #008aff
}

body[data-section=home][data-reveal-mode=human] .tablet:after {
    background: linear-gradient(transparent, #ffb73a 19%, #fff2cb 48%, #ffb73a 85%, transparent);
    box-shadow: 0 0 22px #ffac00bb
}

body[data-section=home][data-reveal-mode=human] .reveal-divider {
    background: #ffd36c;
    box-shadow: 0 0 20px #ffa600
}

body[data-section=home][data-reveal-mode=human] .reveal-divider button {
    border-color: #ffd36c;
    box-shadow: 0 0 14px #ffa600
}

.ai-layer .hero-index span:first-child,
.ai-layer .hero-dots {
    color: #69c0ff;
    text-shadow: 0 0 10px #008cff
}

.ai-layer .hero-index:after {
    background: linear-gradient(#69c0ff, #23528560)
}

body[data-section=home][data-reveal-mode=ai] {
    --accent: #48b5ff;
    --light: #a2dcff;
    --glow: #008fff22;
    --muted: #8491a4
}

body[data-section=home][data-reveal-mode=human] {
    --accent: #ffb722;
    --light: #ffe3a2;
    --glow: #ffaa0022;
    --muted: #a39786
}

body[data-section=home][data-reveal-mode=ai] .tablet:before {
    text-shadow: 0 0 15px #138aff
}

body[data-section=home][data-reveal-mode=human] .tablet:before {
    text-shadow: 0 0 15px #ffae5c
}

body[data-section=home] .reveal-divider button {
    left: 0
}

/* Compact handle; endpoint scenes remain clear until the edge is hovered or keyboard-focused. */
body[data-section=home] .reveal-divider button {
    width: 34px;
    height: 34px;
    box-shadow: -2px 0 8px #ffb16c88, 2px 0 8px #138dff88;
    transition: opacity .18s ease
}

body[data-section=home] .reveal-divider button:after {
    font-size: 19px;
    letter-spacing: 1px
}

body[data-section=home][data-reveal-mode=ai] .reveal-divider button,
body[data-section=home][data-reveal-mode=human] .reveal-divider button {
    opacity: 0;
    box-shadow: none
}

body[data-section=home][data-reveal-mode=ai] .reveal-divider button:hover,
body[data-section=home][data-reveal-mode=human] .reveal-divider button:hover,
body[data-section=home][data-reveal-mode=ai] .reveal-divider button:focus-visible,
body[data-section=home][data-reveal-mode=human] .reveal-divider button:focus-visible {
    opacity: 1
}

@media(max-width:767px) {
    body[data-section=home] .reveal-divider button {
        width: 32px;
        height: 32px
    }
}

@media(prefers-reduced-motion:reduce) {
    body[data-section=home] .reveal-divider button {
        transition: none
    }
}

/* Handle follows the pointer along the divider and hides at every resting position. */
body[data-section=home] .reveal-divider button {
    top: var(--handle-y, 50%);
    opacity: 0
}

body[data-section=home] .hero.reveal-active .reveal-divider button,
body[data-section=home] .hero .reveal-divider button:focus-visible {
    opacity: 1
}

/* Symmetric mode labels with equal columns and a shared baseline. */
body[data-section=home] .tablet:before {
    content: none
}

.world-labels {
    position: absolute;
    top: -44px;
    left: 50%;
    transform: translateX(-50%);
    width: 360px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    pointer-events: none;
    z-index: 8
}

.world-label {
    display: grid;
    grid-template-columns: 24px 1fr 24px;
    align-items: center;
    text-align: center;
    font-size: 16px;
    letter-spacing: 4px;
    line-height: 24px;
    font-weight: 500;
    color: #f2f7fc;
    white-space: nowrap
}

.world-label i {
    font-style: normal;
    font-size: 20px;
    letter-spacing: 0;
    line-height: 24px
}

.human-label {
    color: #ffdfb3;
    text-shadow: 0 0 5px #ffae60, 0 0 14px #ff982dcc, 0 0 24px #ff850066
}

.ai-label {
    color: #bce8ff;
    text-shadow: 0 0 5px #46b5ff, 0 0 14px #078aff, 0 0 24px #007aff88
}

body[data-section=home][data-reveal-mode=human] .world-label {
    color: #ffdfb3;
    text-shadow: 0 0 5px #ffae60, 0 0 14px #ff982dcc, 0 0 24px #ff850066
}

body[data-section=home][data-reveal-mode=ai] .world-label {
    color: #bce8ff;
    text-shadow: 0 0 5px #46b5ff, 0 0 14px #078aff, 0 0 24px #007aff88
}

@media(max-width:767px) {
    .world-labels {
        width: 260px;
        gap: 28px;
        top: -37px
    }

    .world-label {
        grid-template-columns: 18px 1fr 18px;
        font-size: 11px;
        letter-spacing: 2px;
        line-height: 22px
    }

    .world-label i {
        font-size: 16px;
        line-height: 22px
    }
}

/* Apply feathering to the artwork itself, not a wider letterboxed image box. */
body[data-section=home] .ai-portrait {
    width: auto;
    height: 112%;
    aspect-ratio: 1086/1448;
    left: 50%;
    transform: translateX(-50%);
    object-fit: fill;
    mask-image: linear-gradient(to right, transparent 0%, #000 13%, #000 83%, transparent 100%);
    mask-size: 100% 100%;
    mask-repeat: no-repeat
}

@media(max-width:767px) {
    body[data-section=home] .ai-portrait {
        height: 115%;
        bottom: -7%
    }
}

/* Both frame strokes use the same clipping boundary as the two hero scenes. */
body[data-section=home] .tablet,
body[data-section=home][data-reveal-mode=ai] .tablet,
body[data-section=home][data-reveal-mode=human] .tablet {
    border-color: transparent;
    box-shadow: 0 0 0 3px #020304, 0 0 0 4px #26313e55, 0 35px 80px #000b
}

.world-frame {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    z-index: 8;
    pointer-events: none
}

.world-frame>span {
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    border: 1px solid #ffc169;
    pointer-events: none
}

.world-frame .world-frame-ai {
    border-color: #48acff;
    clip-path: inset(0 0 0 calc(var(--reveal, 50%) + var(--frame-clip-offset, 0px)))
}

/* Rounded dialogue action with a restrained glow in each scene's own colour. */
html[lang=en] body[data-section=home] .hero .primary-button {
    width: 290px;
    letter-spacing: .14em
}

body[data-section=home] .hero .primary-button {
    --button-rgb: 255, 183, 34;
    width: 248px;
    min-height: 57px;
    min-width: 0;
    padding: 15px 25px;
    gap: 24px;
    border: 1px solid rgba(var(--button-rgb), .9);
    border-radius: 10px;
    background: linear-gradient(120deg, rgba(var(--button-rgb), .07), #030405c9 60%, rgba(var(--button-rgb), .06));
    color: #f6f6f3;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: .19em;
    white-space: nowrap;
    box-shadow: 0 0 13px rgba(var(--button-rgb), .22), inset 0 0 16px rgba(var(--button-rgb), .06);
    transition: background .2s ease, box-shadow .2s ease, border-color .2s ease;
    filter: none
}

body[data-section=home] .ai-layer .primary-button {
    --button-rgb: 55, 172, 255
}

body[data-section=home] .hero .primary-button:hover {
    background: linear-gradient(120deg, rgba(var(--button-rgb), .14), #030405c9 60%, rgba(var(--button-rgb), .12));
    box-shadow: 0 0 21px rgba(var(--button-rgb), .32), inset 0 0 18px rgba(var(--button-rgb), .09);
    filter: none
}

body[data-section=home] .hero .primary-button span {
    position: relative;
    display: block;
    width: 28px;
    height: 20px;
    flex: 0 0 28px;
    font-size: 0;
    color: inherit !important;
    text-shadow: none !important;
    transition: transform .2s ease
}

body[data-section=home] .hero .primary-button span:before {
    content: '';
    position: absolute;
    left: 0;
    right: 1px;
    top: 9px;
    height: 1px;
    background: currentColor
}

body[data-section=home] .hero .primary-button span:after {
    content: '';
    position: absolute;
    right: 1px;
    top: 4px;
    width: 10px;
    height: 10px;
    border-top: 1px solid currentColor;
    border-right: 1px solid currentColor;
    transform: rotate(45deg)
}

body[data-section=home] .hero .primary-button:hover span {
    transform: translateX(3px)
}

@media(max-width:767px) {
    body[data-section=home] .hero .primary-button {
        width: 230px;
        min-height: 53px;
        padding: 14px 20px;
        font-size: 10px;
        letter-spacing: .16em;
        gap: 20px
    }
}

@media(max-width:767px) {
    html[lang=en] body[data-section=home] .hero .primary-button {
        width: 260px;
        letter-spacing: .1em
    }
}

@media(prefers-reduced-motion:reduce) {

    body[data-section=home] .hero .primary-button,
    body[data-section=home] .hero .primary-button span {
        transition: none
    }
}

/* The navigation overlays the continuous scene instead of forming an opaque strip. */
/* Glow belongs to the slim accent line, never to the text's rectangular box. */
body[data-section=home] .hero-description,
body[data-section=home] .ai-layer .hero-description {
    position: relative;
    background: none;
    border: 0;
    box-shadow: none
}

body[data-section=home] .hero-description:before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--accent);
    box-shadow: 0 0 8px var(--accent)
}

/* Two-line menu trigger and a compact popover at the right edge. */
body[data-section=home] .tablet:after {
    left: calc(var(--reveal) + var(--frame-offset, 0px));
    top: -9px;
    bottom: -9px;
    clip-path: inset(0 -24px)
}

body[data-section=home][data-reveal-mode=ai] .tablet:after,
body[data-section=home][data-reveal-mode=human] .tablet:after {
    display: none
}

body[data-section=home] .hero .reveal-divider {
    background: transparent;
    box-shadow: none
}

body[data-section=home][data-reveal-mode=ai] .reveal-divider,
body[data-section=home][data-reveal-mode=human] .reveal-divider {
    background: transparent;
    box-shadow: none
}

/* A narrow black bezel separates the scene from the outer frame. */
body[data-section=home] .tablet,
body[data-section=home][data-reveal-mode=ai] .tablet,
body[data-section=home][data-reveal-mode=human] .tablet {
    border: 9px solid #020304;
    box-shadow: 0 0 0 1px #26313e55, 0 35px 80px #000b
}

body[data-section=home] .world-frame {
    inset: -9px
}

body[data-section=home] .world-frame>span {
    inset: 0
}

body[data-section=home] .hero {
    border-radius: 17px
}

@media(max-width:767px) {
    body[data-section=home] .hero {
        border-radius: 12px
    }
}

@media(min-width:1440px) {
    body[data-section=home] .header-controls {
        margin-left: auto
    }

    body[data-section=home] .header #navigation {
        position: absolute;
        left: 14%;
        right: calc(50% + 18px);
        top: 50%;
        transform: translateY(-50%);
        display: flex;
        justify-content: space-between;
        gap: 8px;
        min-width: 0
    }

    body[data-section=home] .header #navigation a {
        font-size: 10px;
        letter-spacing: .06em
    }
}

@media(min-width:1024px) and (max-width:1439px) {
    body[data-section=home] .header-controls {
        margin-left: auto
    }

    body[data-section=home] .mobile-menu {
        display: grid;
        margin-left: 3px;
        min-width: 40px;
        min-height: 44px
    }

    body[data-section=home] .header #navigation {
        display: none;
        position: absolute;
        left: auto;
        right: 4.2%;
        top: calc(100% - 2px);
        width: 145px;
        padding: 5px;
        grid-template-columns: 1fr;
        gap: 2px;
        background: #09111a;
        border: 1px solid #87b8e42c;
        border-radius: 14px;
        box-shadow: 0 14px 35px #0008
    }

    body[data-section=home] .header #navigation.open {
        display: grid
    }

    body[data-section=home] .header #navigation a {
        padding: 10px 7px;
        min-height: 42px;
        border-radius: 7px;
        font-size: 12px;
        letter-spacing: 0;
        color: #becbda
    }

    body[data-section=home] .header #navigation a:hover {
        background: #5cafff12;
        color: #fff
    }

    body[data-section=home] .header #navigation a[aria-current] {
        background: #3b9df91a;
        color: #aedaff
    }

    body[data-section=home] .header #navigation a[aria-current]:after {
        display: none
    }
}

.menu-lines {
    display: block;
    position: relative;
    width: 22px;
    height: 10px;
    border-top: 1px solid currentColor;
    border-bottom: 1px solid currentColor
}

body[data-section=home] .brand {
    gap: 9px;
    letter-spacing: 0
}

body[data-section=home] .brand-stencil {
    width: 76px;
    height: 25px;
    flex-shrink: 0;
    color: #f2f4f6
}

body[data-section=home] .brand-slash {
    margin-left: 0
}

@media(max-width:767px) {
    body[data-section=home] .brand-stencil {
        width: 68px;
        height: 23px
    }
}

.mobile-menu[aria-expanded=true] {
    color: var(--accent)
}

@media(max-width:1023px) {
    .header-controls {
        margin-left: auto
    }

    .mobile-menu {
        margin-left: 3px;
        min-width: 40px;
        min-height: 44px
    }

    .header #navigation {
        left: auto;
        right: 22px;
        top: calc(100% - 2px);
        width: 244px;
        max-width: calc(100vw - 48px);
        padding: 9px;
        grid-template-columns: 1fr;
        gap: 2px;
        background: #09111a;
        border: 1px solid #87b8e42c;
        border-radius: 14px;
        box-shadow: 0 14px 35px #0008
    }

    .header #navigation a {
        padding: 11px 14px;
        min-height: 42px;
        border-radius: 7px;
        font-size: 12px;
        letter-spacing: .04em;
        color: #becbda
    }

    .header #navigation a:hover {
        background: #5cafff12;
        color: #fff
    }

    .header #navigation a[aria-current] {
        background: #3b9df91a;
        color: #aedaff
    }

    .header #navigation a[aria-current]:after {
        display: none
    }

    body[data-section=home] .header #navigation {
        right: 4.2%
    }

    body[data-section=home] .header-controls {
        gap: 12px
    }
}

@media(max-width:767px) {

    .header #navigation,
    body[data-section=home] .header #navigation {
        right: 12px
    }

    body[data-section=home] .header-controls {
        gap: 6px
    }
}

body[data-section=home] .tablet {
    --header-height: 78px;
    --scene-height: clamp(550px, 65vh, 760px)
}

body[data-section=home] .header {
    background: linear-gradient(#030507b8, #03050766 65%, transparent);
    margin-bottom: calc(-1 * var(--header-height));
    z-index: 5
}

@media(max-width:1023px) {
    .header #navigation {
        width: 145px;
        padding: 5px
    }

    .header #navigation a {
        padding: 10px 7px;
        letter-spacing: 0
    }
}

body[data-section=home] .hero {
    height: calc(var(--scene-height) + var(--header-height));
    min-height: calc(550px + var(--header-height));
    border-radius: 17px
}

body[data-section=home] .hero-copy {
    top: calc(var(--header-height) + var(--scene-height) * .15)
}

body[data-section=home] .hero-visual {
    height: calc(100% - var(--header-height))
}

body[data-section=home] .ai-portrait {
    mask-image: linear-gradient(to right, transparent 0%, #000 13%, #000 83%, transparent 100%), linear-gradient(to bottom, transparent 0%, #000 18%);
    mask-composite: intersect
}

@media(max-width:767px) {
    body[data-section=home] .tablet {
        --header-height: 74px;
        --scene-height: 790px
    }

    body[data-section=home] .header {
        height: 74px;
        flex-wrap: nowrap
    }

    body[data-section=home] .hero {
        height: 864px;
        min-height: 864px;
        border-radius: 16px
    }

    body[data-section=home] .hero-copy {
        top: calc(var(--header-height) + 39.5px)
    }

    body[data-section=home] .hero-visual {
        height: 420px
    }
}

/* Ambient light follows the reveal; endpoint scenes illuminate the whole page in one colour. */
/* Gentle moving highlight on the large wordmark, matching its scene. */
body[data-section=home] .hero h1 {
    background-image: linear-gradient(105deg, #ffb92d 0%, #ffd56e 25%, #ffdb86 40%, #fff6dc 48%, #fffdfa 51%, #ffdda0 57%, #ffd56e 70%, #ffb92d 100%);
    background-size: 250% 100%;
    animation: nlp-wordmark-shimmer 5s ease-in-out infinite alternate
}

body[data-section=home] .ai-layer h1 {
    background-image: linear-gradient(105deg, #3b9dff 0%, #86caff 25%, #b4e0ff 40%, #eefaff 48%, #fff 51%, #b6e8ff 57%, #86caff 70%, #3b9dff 100%)
}

@keyframes nlp-wordmark-shimmer {
    from {
        background-position: 100% 50%
    }

    to {
        background-position: 0% 50%
    }
}

@media(prefers-reduced-motion:reduce) {
    body[data-section=home] .hero h1 {
        animation: none;
        background-position: 50% 50%
    }
}

body[data-section=home] .language-switch a[aria-current] {
    color: var(--language-color, #bce8ff);
    text-shadow: 0 0 5px var(--language-glow, #078aff), 0 0 12px var(--language-glow, #078aff)
}

body[data-section=home][data-reveal-mode] .world-label {
    color: var(--label-color, #bce8ff);
    text-shadow: 0 0 5px var(--label-glow, #078aff), 0 0 14px var(--label-glow, #078aff)
}

body[data-section=home] .world-label>span {
    background: linear-gradient(90deg, #ffdfb3 0%, #ffdfb3 var(--label-warm-fill, 0%), #bce8ff var(--label-warm-fill, 0%), #bce8ff 100%);
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
    text-shadow: none;
    filter: drop-shadow(0 0 5px var(--label-glow, #078aff))
}

body[data-section=home][data-reveal-mode] {
    background-color: var(--ambient-background, #1e1d24);
    background-image: radial-gradient(ellipse at 22% 50%, var(--ambient-warm, #ff9b194d) 0%, transparent 72%), radial-gradient(ellipse at 78% 50%, var(--ambient-cool, #1487ff4d) 0%, transparent 72%);
    background-attachment: fixed;
    background-size: cover
}

body[data-section=home][data-reveal-mode] .tablet {
    box-shadow: 0 0 0 1px #26313e55, -15px 0 60px var(--ambient-warm, #ff9b194d), 15px 0 60px var(--ambient-cool, #1487ff4d), 0 24px 45px #0007
}

/* Transparent Anthe CTA: shared geometry for both languages and worlds. */
/* Centre the three section actions while retaining their original footprint. */
body[data-section] #dataset-open,
body[data-section] #preprocessing-open,
body[data-section] .models-page .models-comparison-button {
    justify-content: center;
    text-align: center;
    gap: 0;
}
body[data-section] #dataset-open > span,
body[data-section] #preprocessing-open > span,
body[data-section] .models-page .models-comparison-button > span {
    display: none;
}
body[data-section] #dataset-open::before,
body[data-section] #dataset-open::after,
body[data-section] #preprocessing-open::before,
body[data-section] #preprocessing-open::after,
body[data-section] .models-page .models-comparison-button::before,
body[data-section] .models-page .models-comparison-button::after {
    content: '';
    flex: 0 0 23px;
}
html[lang] body[data-section] button.section-anthe {
    position: relative;
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 248px;
    max-width: 100%;
    height: 58px;
    min-height: 58px;
    min-width: 0;
    padding: 0 24px;
    gap: 0;
    border: 0;
    border-radius: 10px;
    background: transparent;
    box-shadow: none;
    color: #f6f6f3;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: .14em;
    text-align: center;
}
html[lang] body[data-section] .models-page button.section-anthe { width: 440px; }
html[lang] body[data-section] #dataset-open.section-anthe,
html[lang] body[data-section] #preprocessing-open.section-anthe,
html[lang] body[data-section] .models-page button.section-anthe:is(:hover, :focus-visible) {
    background: transparent;
    box-shadow: none;
    border: 0;
}
html[lang] body[data-section] button.section-anthe::before,
html[lang] body[data-section] button.section-anthe::after { content: none; }
body[data-section] .section-anthe-outline {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    fill: none;
    stroke: color-mix(in srgb, var(--accent) 80%, transparent);
    stroke-width: 1;
    overflow: visible;
}
body[data-section] .section-anthe-outline path {
    vector-effect: non-scaling-stroke;
    transition: d .4s cubic-bezier(.2, 1, .8, 1);
}
body[data-section] .section-anthe-label { position: relative; font: inherit; }
body[data-section] .section-anthe:is(:hover, :focus-visible) .section-anthe-outline path {
    d: path('M11 1 H210 Q216 1 220 6 L247 29 L220 52 Q216 57 210 57 H11 Q1 57 1 47 V11 Q1 1 11 1 Z');
}
@media(max-width:767px) {
    /* At least 230px, wider when the label needs it ("Показать пример", "Explore datasets"), so it stays on one line. */
    html[lang] body[data-section] button.section-anthe { width:auto; min-width:230px; height:54px; min-height:54px; white-space:nowrap; }
    html[lang] body[data-section] .models-page button.section-anthe { height:auto; padding:16px 24px; white-space:normal; }
}
@media(prefers-reduced-motion:reduce) {
    body[data-section] .section-anthe-outline path { transition:none; }
}
html[lang] body[data-section=home] .hero .primary-button.dialogue-anthe {
    position: relative;
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 248px;
    max-width: 100%;
    height: 58px;
    min-height: 58px;
    padding: 0 24px;
    gap: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
    filter: none;
    letter-spacing: .14em;
    font-size: 13px;
}
body[data-section=home] .dialogue-anthe-outline {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    fill: none;
    stroke: rgba(var(--button-rgb), .8);
    stroke-width: 1;
    overflow: visible;
}
body[data-section=home] .dialogue-anthe-outline path {
    vector-effect: non-scaling-stroke;
    transition: d .4s cubic-bezier(.2, 1, .8, 1);
}
body[data-section=home] .dialogue-anthe-label {
    position: relative;
    font: inherit;
    text-align: center;
    white-space: nowrap;
}
body[data-section=home] .dialogue-anthe:is(:hover, :focus-visible) .dialogue-anthe-outline path {
    d: path('M11 1 H210 Q216 1 220 6 L247 29 L220 52 Q216 57 210 57 H11 Q1 57 1 47 V11 Q1 1 11 1 Z');
}
@media(max-width:767px) {
    html[lang] body[data-section=home] .hero .primary-button.dialogue-anthe {
        width: 230px;
        height: 54px;
        min-height: 54px;
    }
}
@media(prefers-reduced-motion:reduce) {
    body[data-section=home] .dialogue-anthe-outline path { transition: none; }
}
