/* ==========================================================================
   Design tokens
   osu!'s song/mode-select screen, rebuilt as the site's own grammar: a
   spinning hit-circle you click open, a radial mode fan, rank-letter chips
   and difficulty-style rows standing in for cards.
   ========================================================================== */

:root {
    /* Recolored from a supplied Figma palette (a 4-family violet/indigo
       ramp — primary/secondary/tertiary/quaternary, 100-700 — plus a
       neutral grey ramp). Ground and the primary/secondary accent pair
       are drawn straight from that palette; --pink/--blue keep their
       token names for minimal churn even though neither is literally
       pink or cyan anymore — see DESIGN.md. */
    --void: #0e0e27;
    /* primary/700 */
    --void-raised: #272757;
    /* primary/600 */
    --void-line: rgba(224, 224, 239, 0.14);
    /* primary/100, tinted */
    --void-line-soft: rgba(224, 224, 239, 0.07);

    --paper: #e0e0ef;
    /* primary/100 */
    --ash: #8686ac;
    /* secondary/300 */
    --ash-dim: #7474a0;
    /* tertiary/400 — currently unused; kept close to AA for whenever it is */

    /* Rank ladder: S/A/B/C get their own hues, drawn from rhythm-game
       rank-letter convention rather than invented as decoration. Gold/
       green/rust are kept as-is (outside the supplied palette) so the
       four rank tiers stay visually distinct — collapsing them into the
       same violet family would erase the one thing the ladder needs to
       do at a glance. */
    --pink: #9796e6;
    /* quaternary/300 — primary interactive accent. quaternary/400 (#6d6cda)
       was the first pick but only cleared 4.3:1 on void — this is the
       nearest palette step that clears WCAG AA (7.04:1). */
    --pink-dim: rgba(151, 150, 230, 0.18);
    --pink-soft: rgba(151, 150, 230, 0.09);
    --blue: #9a9abb;
    /* tertiary/300 — secondary/informational accent + rank B (6.94:1) */
    --blue-dim: rgba(154, 154, 187, 0.18);
    --gold: #ffcf4d;
    --gold-dim: rgba(255, 207, 77, 0.14);
    --green: #6fe3a6;
    --green-dim: rgba(111, 227, 166, 0.14);
    --rust: #e08a5c;
    --rust-dim: rgba(224, 138, 92, 0.16);

    --font-display: 'Exo 2', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-body: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-mono: 'JetBrains Mono', 'SFMono-Regular', Consolas, monospace;

    --beat: 640ms;
    /* shared timing grid every authored motion locks to */
}

/* ==========================================================================
   Reset and base
   ========================================================================== */

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    line-height: 1.6;
    color: var(--paper);
    background-color: var(--void);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    position: relative;
    overflow-x: hidden;
    min-height: 100vh;
}

::selection {
    background-color: var(--pink);
    color: var(--void);
}

button {
    font: inherit;
    color: inherit;
    background: none;
    border: none;
    cursor: pointer;
}

a {
    color: inherit;
}

::-webkit-scrollbar {
    width: 12px;
}

::-webkit-scrollbar-track {
    background: var(--void);
}

::-webkit-scrollbar-thumb {
    background: var(--void-line);
    border-radius: 6px;
    border: 3px solid var(--void);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--pink-dim);
}

a:focus-visible,
button:focus-visible {
    outline: 2px solid var(--pink);
    outline-offset: 3px;
    border-radius: 2px;
}

/* ==========================================================================
   Backdrop — the playfield both gate and stage sit on
   ========================================================================== */

.backdrop {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
}

.backdrop-glow {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 46% 40% at 50% 42%, rgba(255, 79, 163, 0.10), transparent 68%),
        radial-gradient(ellipse 38% 32% at 50% 42%, rgba(73, 211, 255, 0.06), transparent 70%);
    transition: opacity 0.6s ease;
}

body.is-entered .backdrop-glow {
    opacity: 0.55;
}

/* ==========================================================================
   Gate — the start screen
   ========================================================================== */

.gate {
    position: fixed;
    inset: 0;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    padding-bottom: 9vh;
    text-align: center;
    pointer-events: none;
    transition: opacity 0.5s ease, transform 0.5s ease;
}

body.is-entered .gate {
    opacity: 0;
    transform: translateY(-18px);
}

.gate-name {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: clamp(30px, 5.4vw, 52px);
    letter-spacing: -0.02em;
    color: var(--paper);
    margin-top: clamp(150px, 24vw, 250px);
}

.gate-tagline {
    margin-top: 10px;
    font-size: clamp(13px, 1.6vw, 16px);
    color: var(--ash);
}

.gate-hint {
    margin-top: 22px;
    font-family: var(--font-mono);
    font-size: 12px;
    letter-spacing: 0.04em;
    color: var(--pink);
    opacity: 0.85;
}

/* ==========================================================================
   Signature: the hit-circle
   ========================================================================== */

.hit-circle {
    position: fixed;
    z-index: 3;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;

    top: 42%;
    left: 50%;
    width: clamp(130px, 20vw, 200px);
    height: clamp(130px, 20vw, 200px);
    transform: translate(-50%, -50%);
    transition: top var(--beat) cubic-bezier(0.22, 1, 0.36, 1),
        left var(--beat) cubic-bezier(0.22, 1, 0.36, 1),
        width var(--beat) cubic-bezier(0.22, 1, 0.36, 1),
        height var(--beat) cubic-bezier(0.22, 1, 0.36, 1),
        transform var(--beat) cubic-bezier(0.22, 1, 0.36, 1);
}

body.is-entered .hit-circle {
    top: 32px;
    left: 32px;
    width: 46px;
    height: 46px;
    transform: translate(0, 0);
}

.hit-photo {
    position: relative;
    display: block;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid var(--pink);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), 0 0 0 6px var(--void) inset;
}

.hit-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Idle tick ring — mirrors a beatmap's spinner ticks */
.hit-ring {
    position: absolute;
    inset: -14%;
    border-radius: 50%;
    background: repeating-conic-gradient(from 0deg,
            var(--ash) 0deg 1.2deg,
            transparent 1.2deg 30deg);
    -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 3px), #000 calc(100% - 3px));
    mask: radial-gradient(farthest-side, transparent calc(100% - 3px), #000 calc(100% - 3px));
    opacity: 0.5;
    pointer-events: none;
    animation: hit-ring-spin 16s linear infinite;
}

@keyframes hit-ring-spin {
    to {
        transform: rotate(360deg);
    }
}

body.is-entered .hit-ring {
    inset: -6%;
    animation-duration: 30s;
}

/* ==========================================================================
   Radial mode-select menu
   ========================================================================== */

.mode-fan {
    position: fixed;
    z-index: 2;
    top: 42%;
    left: 50%;
    width: 0;
    height: 0;
    pointer-events: none;
}

/* Docked state: the fan stays a circle, anchored just past the small
   avatar. Rotation (wheel, drag, or keyboard focus) spins it like a jog
   wheel — script.js swings items around this anchor and fades/hides
   whichever fall outside the visible window, so three read at a time
   and the rest are dialed in rather than laid out in a line. */
body.is-entered .mode-fan {
    top: 68px;
    left: 68px;
    cursor: grab;
}

body.is-entered.is-open .mode-fan {
    pointer-events: auto;
}

body.is-entered.is-open .mode-fan:active {
    cursor: grabbing;
}

.mode-item {
    position: absolute;
    top: 0;
    left: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    width: 84px;
    margin-left: -42px;
    margin-top: -42px;
    opacity: 0;
    transform: translate(0, 0) scale(0.4);
    transition: transform 0.22s ease, opacity 0.18s ease;
    transition-delay: 0s;
    pointer-events: none;
}

body.is-open .mode-item {
    opacity: 1;
    transform: translate(var(--tx, 0px), var(--ty, 0px)) scale(1);
    pointer-events: auto;
    transition: transform 0.42s cubic-bezier(0.22, 1, 0.36, 1),
        opacity 0.3s ease;
    transition-delay: calc(var(--i) * 55ms);
}

.mode-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: var(--void-raised);
    border: 1.5px solid var(--void-line);
    color: var(--ash);
    transition: border-color 0.18s ease, color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

/* Rotation-driven positioning: script.js writes transform/opacity/
   pointer-events inline per item every frame the dial turns, so this
   rule only supplies sizing and the transition that smooths those
   inline writes into motion. */
body.is-entered .mode-item {
    width: 58px;
    margin-left: -29px;
    margin-top: -29px;
    transition: transform 0.18s ease, opacity 0.25s ease;
    transition-delay: 0s;
}

body.is-entered .mode-icon {
    width: 34px;
    height: 34px;
}

.mode-item:hover .mode-icon,
.mode-item:focus-visible .mode-icon {
    border-color: var(--pink);
    color: var(--pink);
    background: var(--pink-soft);
    transform: translateY(-3px);
}

.mode-item.is-active .mode-icon {
    border-color: var(--pink);
    color: var(--pink);
    background: var(--pink-dim);
}

.mode-item.is-active .mode-label {
    color: var(--paper);
}

.mode-label {
    font-family: var(--font-mono);
    font-size: 11px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--ash);
}

.mode-item:hover .mode-label,
.mode-item:focus-visible .mode-label {
    color: var(--paper);
}

/* ==========================================================================
   Stage — entered state
   ========================================================================== */

.stage {
    position: relative;
    z-index: 1;
    max-width: 900px;
    margin: 0 auto;
    padding: 108px 24px 96px;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.4s ease 0.15s, transform 0.4s ease 0.15s, filter 0.25s ease;
}

body.is-entered .stage {
    opacity: 1;
    transform: translateY(0);
}

/* Reopening the fan over the stage pauses the content behind it, so
   fanned labels never collide with panel text. */
body.is-open.is-entered .stage {
    filter: blur(3px);
    opacity: 0.3;
    pointer-events: none;
}

.stage-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 26px 24px 0 112px;
    transition: filter 0.25s ease, opacity 0.25s ease;
}

body.is-open.is-entered .stage-bar {
    filter: blur(3px);
    opacity: 0.3;
    pointer-events: none;
}

.stage-exit {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    color: var(--ash);
    border: 1.5px solid var(--void-line);
    transition: color 0.18s ease, border-color 0.18s ease;
}

.stage-exit:hover {
    color: var(--pink);
    border-color: var(--pink);
}

/* ==========================================================================
   Panels
   ========================================================================== */

.panel {
    animation: panel-fade-in 0.35s ease;
}

@keyframes panel-fade-in {
    from {
        opacity: 0;
        transform: translateY(6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.panel h2 {
    font-family: var(--font-display);
    font-size: clamp(26px, 4vw, 34px);
    font-weight: 700;
    color: var(--paper);
    letter-spacing: -0.02em;
    margin-bottom: 28px;
}

.panel-overview {
    font-size: 16px;
    color: var(--ash);
    line-height: 1.75;
    max-width: 640px;
    margin-bottom: 8px;
}

/* Angled pennant tab — a direct structural quote of osu.ppy.sh's own
   diagonal section-cut convention, reserved for section-level wayfinding
   (subheads here, the current-section tab in the stage bar) rather than
   applied to every row. */
.panel-subhead {
    display: inline-flex;
    align-items: center;
    font-family: var(--font-mono);
    font-size: 11px;
    font-weight: 600;
    color: var(--paper);
    text-transform: uppercase;
    letter-spacing: 0.14em;
    margin: 44px 0 20px;
    padding: 8px 26px 8px 16px;
    background: var(--void-raised);
    border-left: 2px solid var(--pink);
    clip-path: polygon(0 0, 100% 0, calc(100% - 16px) 100%, 0 100%);
}

.panel>.panel-subhead:first-of-type {
    margin-top: 8px;
}

/* ==========================================================================
   About — records (education) and chips (skills)
   ========================================================================== */

.record {
    padding: 22px 0;
    border-top: 1px solid var(--void-line);
}

.record:last-of-type {
    padding-bottom: 0;
}

.record-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 16px;
}

.record-main {
    flex: 1;
    min-width: 200px;
}

.record-main h4 {
    font-family: var(--font-display);
    font-size: 18px;
    font-weight: 600;
    color: var(--paper);
    margin-bottom: 4px;
}

.record-line {
    font-size: 14.5px;
    color: var(--ash);
    margin-bottom: 4px;
    line-height: 1.6;
}

.record-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    text-align: right;
}

.record-place {
    font-size: 12.5px;
    color: var(--ash);
}

.record-date {
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--blue);
}

.record-note {
    margin-top: 12px;
    font-size: 13px;
    color: var(--ash);
    line-height: 1.6;
    opacity: 0.9;
}

.record-note strong {
    color: var(--ash);
    font-weight: 600;
}

.skill-group {
    margin-bottom: 24px;
}

.skill-group:last-of-type {
    margin-bottom: 0;
}

.skill-group-title {
    font-family: var(--font-mono);
    font-size: 11px;
    font-weight: 600;
    color: var(--ash);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 12px;
}

.chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.chip {
    display: inline-flex;
    align-items: center;
    padding: 5px 12px;
    background: transparent;
    border: 1px solid var(--void-line);
    border-radius: 4px;
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 500;
    color: var(--paper);
    text-decoration: none;
    transition: border-color 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.chip--accent {
    border-color: rgba(255, 207, 77, 0.35);
    color: var(--gold);
}

.chip--gold {
    border-color: var(--gold);
    color: var(--gold);
    cursor: default;
}

.chip--green {
    border-color: var(--green);
    color: var(--green);
    cursor: default;
}

.chip--blue {
    border-color: var(--blue);
    color: var(--blue);
    cursor: default;
}

.chip--muted {
    border-color: var(--rust);
    color: var(--rust);
    cursor: default;
}

.chip--link {
    border-color: var(--pink);
    color: var(--pink);
}

.chip--link:hover {
    background: var(--pink);
    color: var(--void);
}

/* Difficulty-star tag treatment, reused across skill and tech-stack chips */
.chip--tag {
    gap: 6px;
}

.chip--tag::before {
    content: '\2605';
    font-size: 8px;
    color: var(--pink);
    line-height: 1;
}

.chip--tech {
    border-color: var(--blue);
    color: var(--blue);
}

/* Rank-letter badge, reused inside award/status chips */
.rank-dot {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 2px;
    margin-right: 7px;
    border-radius: 50%;
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: 11px;
    line-height: 1;
    color: var(--void);
}

.rank-dot[data-rank="S"] {
    background: var(--gold);
}

.rank-dot[data-rank="A"] {
    background: var(--green);
}

.rank-dot[data-rank="B"] {
    background: var(--blue);
}

.rank-dot[data-rank="C"] {
    background: var(--rust);
}

/* ==========================================================================
   Experience — timeline
   ========================================================================== */

.timeline {
    position: relative;
    margin-left: 26px;
    padding-left: 20px;
    border-left: 1px solid var(--void-line);
}

.timeline-item {
    position: relative;
    margin-bottom: 32px;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -25px;
    top: 5px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--void);
    border: 2px solid var(--pink);
}

.timeline-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 6px;
    flex-wrap: wrap;
    gap: 12px;
}

.timeline-head h4 {
    font-family: var(--font-display);
    font-size: 17px;
    font-weight: 600;
    color: var(--paper);
}

.timeline-date {
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--blue);
    white-space: nowrap;
}

.timeline-org {
    font-size: 14.5px;
    color: var(--ash);
    margin-bottom: 10px;
}

.timeline-bullets {
    list-style: none;
}

.timeline-bullets li {
    font-size: 14.5px;
    color: var(--ash);
    line-height: 1.7;
    margin-bottom: 8px;
    padding-left: 16px;
    position: relative;
}

.timeline-bullets li::before {
    content: '';
    position: absolute;
    left: 2px;
    top: 9px;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--pink);
}

.timeline-bullets li:last-child {
    margin-bottom: 0;
}

/* ==========================================================================
   Projects — tracklist rows
   ========================================================================== */

.entry {
    padding: 22px 0;
    border-top: 1px solid var(--void-line);
}

.entry:last-child {
    padding-bottom: 0;
}

.entry-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 6px;
    flex-wrap: wrap;
    gap: 12px;
}

.entry-head h4 {
    font-family: var(--font-display);
    font-size: 17px;
    font-weight: 600;
    color: var(--paper);
}

.entry-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.entry-context {
    font-size: 13px;
    color: var(--ash);
    margin-bottom: 8px;
}

.entry-tech-row {
    margin-bottom: 10px;
}

.entry-desc {
    font-size: 14.5px;
    color: var(--ash);
    line-height: 1.7;
    max-width: 660px;
}

.entry-desc code {
    background: var(--void-raised);
    padding: 1px 6px;
    border-radius: 3px;
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--pink);
}

/* ==========================================================================
   Resume
   ========================================================================== */

.resume-card {
    display: grid;
    grid-template-columns: minmax(240px, 420px) minmax(200px, 260px);
    align-items: start;
    gap: 36px;
    max-width: 740px;
    padding: 28px;
    background: var(--void-raised);
    border: 1px solid var(--void-line);
    border-radius: 6px;
}

.resume-preview {
    width: 100%;
    border-radius: 4px;
    overflow: hidden;
    border: 1px solid var(--void-line);
}

.resume-preview-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 12px;
    background: var(--void);
    border-bottom: 1px solid var(--void-line);
}

.resume-preview-icon {
    flex-shrink: 0;
    color: var(--pink);
}

.resume-preview-name {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.04em;
    color: var(--ash);
}

.resume-preview iframe {
    width: 100%;
    aspect-ratio: 8.5 / 11;
    border: 0;
    display: block;
    background: var(--paper);
}

/* Real file facts, computed by script.js from the actual PDF response —
   never hand-typed, so they can't drift when the resume is replaced. */
.resume-meta {
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding-top: 2px;
}

.resume-meta-line {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--void-line);
}

.resume-meta-label {
    font-family: var(--font-mono);
    font-size: 11px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--ash);
}

.resume-meta-value {
    font-family: var(--font-mono);
    font-size: 13px;
    color: var(--paper);
}

.resume-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 8px;
}

.resume-download,
.resume-open {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 22px;
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    text-decoration: none;
    border-radius: 4px;
    transition: transform 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.resume-download {
    background: var(--pink);
    color: var(--void);
    border: 1px solid var(--pink);
}

.resume-download:hover {
    transform: translateY(-1px);
    background: #c1c0f0;
    /* quaternary/200 — a lighten step up from --pink, still void-text-legible */
}

.resume-open {
    background: transparent;
    color: var(--pink);
    border: 1px solid var(--pink);
}

.resume-open:hover {
    background: var(--pink);
    color: var(--void);
    transform: translateY(-1px);
}

/* ==========================================================================
   Contact
   ========================================================================== */

.contact-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 560px;
    margin-top: 4px;
}

/* Each row is a non-interactive wrapper around two independent controls —
   the platform link and a standalone copy button — since a <button>
   can't nest inside an <a> without breaking semantics and hit-testing. */
.contact-row {
    display: flex;
    align-items: stretch;
    gap: 10px;
}

.contact-link {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    border: 1px solid var(--void-line);
    border-radius: 8px;
    text-decoration: none;
    transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.contact-link:hover,
.contact-link:focus-visible {
    border-color: var(--pink);
    background: var(--pink-soft);
    transform: translateX(4px);
}

.contact-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--void-raised);
    border: 1.5px solid var(--void-line);
    color: var(--pink);
    flex-shrink: 0;
    transition: border-color 0.18s ease;
}

.contact-link:hover .contact-badge,
.contact-link:focus-visible .contact-badge {
    border-color: var(--pink);
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.contact-label {
    font-family: var(--font-mono);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--ash);
}

.contact-handle {
    font-size: 15px;
    color: var(--paper);
}

.contact-copy {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    border-radius: 8px;
    background: transparent;
    border: 1px solid var(--void-line);
    color: var(--ash);
    transition: border-color 0.18s ease, color 0.18s ease, background 0.18s ease;
}

.contact-copy:hover,
.contact-copy:focus-visible {
    border-color: var(--pink);
    color: var(--pink);
}

.contact-copy-check {
    display: none;
}

.contact-copy.is-copied {
    border-color: var(--green);
    color: var(--green);
    background: var(--green-dim);
}

.contact-copy.is-copied .contact-copy-icon {
    display: none;
}

.contact-copy.is-copied .contact-copy-check {
    display: block;
}

/* ==========================================================================
   Blog — honest empty state
   ========================================================================== */

.empty-state {
    padding: 36px 0 12px;
    max-width: 480px;
}

.empty-ring {
    display: block;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    border: 2px solid var(--void-line);
    margin-bottom: 22px;
    position: relative;
}

.empty-ring::after {
    content: '';
    position: absolute;
    inset: 12px;
    border-radius: 50%;
    border: 1.5px solid var(--void-line);
}

.empty-title {
    font-family: var(--font-display);
    font-size: 19px;
    font-weight: 600;
    color: var(--paper);
    margin-bottom: 8px;
}

.empty-body {
    font-size: 14.5px;
    color: var(--ash);
    line-height: 1.7;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 640px) {
    .hit-circle {
        top: 36%;
    }

    .gate {
        padding-bottom: 34vh;
    }

    .gate-name {
        margin-top: 0;
    }

    .mode-fan {
        position: fixed;
        top: auto;
        bottom: 0;
        left: 0;
        right: 0;
        width: auto;
        height: auto;
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px;
        padding: 18px 16px calc(18px + env(safe-area-inset-bottom));
        background: linear-gradient(to top, var(--void) 60%, transparent);
    }

    body.is-entered .mode-fan {
        top: auto;
    }

    .mode-item {
        position: static;
        margin: 0;
        width: 72px;
        transform: none !important;
        transition: opacity 0.28s ease;
        transition-delay: calc(var(--i) * 45ms);
    }

    body.is-open .mode-item {
        transform: none !important;
    }

    .mode-icon {
        width: 46px;
        height: 46px;
    }

    .stage-bar {
        padding-left: 96px;
    }

    .stage {
        padding-top: 96px;
    }

    .resume-card {
        grid-template-columns: 1fr;
        max-width: 420px;
    }
}

@media (max-width: 480px) {
    .panel h2 {
        font-size: 24px;
    }

    .timeline {
        margin-left: 14px;
        padding-left: 16px;
    }

    .record-head,
    .timeline-head,
    .entry-head {
        flex-direction: column;
    }

    .record-meta {
        align-items: flex-start;
        text-align: left;
    }
}

/* Respect reduced-motion preferences */
@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
    }
}
