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

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--site-nav-height) + 12px);
}

.robot-season-page {
    background: var(--hud-ink);
    color: var(--hud-text);
    font-family: var(--site-font);
    color-scheme: dark;
}

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

a:focus-visible {
    outline: 2px solid var(--hud-signal);
    outline-offset: 4px;
}

.navbar {
    position: sticky;
}

.navbar .nav-divider {
    background: var(--hud-line);
}

.season-header {
    max-width: 1440px;
    margin: 0 auto;
    padding: 42px var(--site-nav-gutter) 34px;
}

.archive-return {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    color: var(--hud-muted);
    font-size: 14px;
}

.archive-return:hover,
.season-footer a:hover {
    color: var(--hud-text);
}

/* The list remains available to screen readers while visual comments repeat. */
.danmaku-window {
    position: relative;
    margin: 12px 0 28px;
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: var(--radius-card);
    background: #101512;
    background-clip: padding-box;
}

.danmaku-toolbar {
    padding: 12px 16px;
    border-bottom: 1px solid rgba(148, 163, 184, 0.14);
}

.danmaku-toolbar h2 {
    color: var(--hud-text);
    font-size: 16px;
    font-weight: 600;
    line-height: 1.5;
}

.danmaku-stage {
    display: none;
    position: relative;
    height: 176px;
    overflow: hidden;
    mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent);
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent);
}

.is-animated .danmaku-stage {
    display: block;
}

.danmaku-item {
    position: absolute;
    left: 0;
    white-space: nowrap;
    color: #cbd5e1;
    font-size: 16px;
    font-weight: 500;
    line-height: 1.5;
    will-change: transform;
}

.danmaku-item.is-accent {
    color: #a0dfbc;
}

.danmaku-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px 24px;
    padding: 24px;
    list-style: none;
    color: #cbd5e1;
    font-size: 14px;
    line-height: 1.6;
}

.is-animated .danmaku-list {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
}

@media (max-width: 700px) {
    .danmaku-stage { height: 160px; }
    .danmaku-item { font-size: 14px; }
    .danmaku-toolbar h2 { font-size: 14px; }
    .danmaku-list {
        grid-template-columns: minmax(0, 1fr);
        gap: 12px;
        padding: 20px 16px;
    }
}

.season-header h1 {
    margin: 6px 0 22px;
    font-size: clamp(36px, 5vw, 64px);
    font-weight: 800;
    line-height: 1.15;
}

.season-header h1 span {
    font-size: 0.55em;
    font-weight: 600;
    color: var(--hud-muted);
}

.robot-index {
    display: grid;
    grid-template-columns: repeat(9, minmax(0, 1fr));
    gap: 10px;
    padding-top: 22px;
    border-top: 1px solid rgba(148, 163, 184, 0.16);
}

.robot-index a {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
    min-height: 64px;
    padding: 14px 16px;
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: var(--radius-control);
    background: rgba(226, 232, 240, 0.035);
    background-clip: padding-box;
    color: #cbd5e1;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.5;
    text-align: center;
    transition: background-color 180ms ease, border-color 180ms ease, color 180ms ease;
}

.robot-index-label {
    white-space: nowrap;
}

@media (hover: hover) {
    .robot-index a:hover {
        background-color: rgba(226, 232, 240, 0.075);
        border-color: rgba(148, 163, 184, 0.4);
        color: #f8fafc;
    }
}

.robot-index a[aria-current="location"] {
    background-color: rgba(83, 246, 161, 0.08);
    border-color: rgba(83, 246, 161, 0.42);
    color: #f8fafc;
}

@media (max-width: 1200px) {
    .robot-index {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

.robot-lineup {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    padding: 0 8px 8px;
}

.robot-panel {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 0;
    overflow: hidden;
    border-radius: var(--radius-media);
    background: #f2f1f5;
    background-clip: padding-box;
    color: #16191d;
    color-scheme: light;
}

.robot-panel-wide {
    grid-column: 1 / -1;
}

.robot-copy {
    position: relative;
    z-index: 1;
    width: 100%;
    padding: 44px 28px 14px;
    text-align: center;
}

.robot-copy h2 {
    color: inherit;
    font-size: clamp(36px, 4vw, 56px);
    line-height: 1.1;
    font-weight: 700;
}

.robot-copy p {
    max-width: 32em;
    margin: 12px auto 0;
    color: #444951;
    font-size: clamp(18px, 1.6vw, 24px);
    line-height: 1.4;
    font-weight: 500;
    text-wrap: balance;
}

.robot-photo {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 3 / 2;
    object-fit: contain;
}

.robot-panel-wide .robot-photo {
    max-width: 1200px;
    max-height: min(72svh, 800px);
}

.season-footer {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 12px;
    min-height: 160px;
    padding: 32px 22px;
    color: var(--hud-muted);
    font-size: 13px;
    line-height: 1.6;
    text-align: center;
}

.season-footer a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    font-size: 14px;
}

@media (max-width: 700px) {
    .season-header {
        padding-top: 24px;
        padding-bottom: 24px;
    }

    .season-header h1 {
        margin-bottom: 12px;
    }

    .robot-index {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
        padding-top: 16px;
    }

    .robot-index a {
        min-height: 48px;
        padding: 10px 4px;
        font-size: 13px;
    }

    .robot-lineup {
        grid-template-columns: minmax(0, 1fr);
        padding: 0 6px 6px;
        gap: 6px;
    }

    .robot-copy {
        padding: 36px 22px 12px;
    }

    .robot-copy h2 {
        font-size: 36px;
    }

    .robot-copy p {
        margin-top: 10px;
        font-size: 18px;
    }

    .robot-panel-wide .robot-photo {
        max-height: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .robot-index a { transition: none; }
}
