:root,
html[data-theme="lime"] {
    --bg: #05070a;
    --bg-elevated: #0c1016;
    --bg-soft: #11161f;
    --line: rgba(232, 236, 243, 0.08);
    --line-strong: rgba(232, 236, 243, 0.16);
    --text: #eef2f7;
    --text-muted: #8b95a7;
    --text-dim: #5d6778;
    --accent: #b8ff3c;
    --accent-soft: rgba(184, 255, 60, 0.14);
    --accent-ink: #0a1200;
    --accent-glow: rgba(184, 255, 60, 0.28);
    --steel: #7eb6ff;
    --font-display: "Syne", sans-serif;
    --font-sans: "Manrope", sans-serif;
    --font-mono: "JetBrains Mono", ui-monospace, monospace;
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
    --nav-h: 72px;
    --container: 1120px;
}

html[data-theme="steel"] {
    --accent: #7eb6ff;
    --accent-soft: rgba(126, 182, 255, 0.16);
    --accent-ink: #071018;
    --accent-glow: rgba(126, 182, 255, 0.3);
}

html[data-theme="amber"] {
    --accent: #ffb84d;
    --accent-soft: rgba(255, 184, 77, 0.16);
    --accent-ink: #140d00;
    --accent-glow: rgba(255, 184, 77, 0.3);
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--nav-h) + 16px);
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

body {
    font-family: var(--font-sans);
    background: var(--bg);
    color: var(--text);
    line-height: 1.65;
    overflow-x: hidden;
    min-height: 100vh;
    min-height: 100dvh;
    padding-left: env(safe-area-inset-left);
    padding-right: env(safe-area-inset-right);
    -webkit-font-smoothing: antialiased;
}

body.nav-open {
    overflow: hidden;
    touch-action: none;
}

img {
    max-width: 100%;
    display: block;
    height: auto;
}

a {
    color: inherit;
    text-decoration: none;
}

::selection {
    background: var(--accent);
    color: var(--accent-ink);
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.container {
    width: min(100% - 40px, var(--container));
    margin-inline: auto;
}

/* Ambient */
.ambient {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.ambient-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.55;
    animation: drift 18s var(--ease) infinite alternate;
}

.ambient-orb-a {
    width: 55vw;
    height: 55vw;
    top: -18%;
    right: -12%;
    background: radial-gradient(circle, rgba(184, 255, 60, 0.18), transparent 70%);
}

.ambient-orb-b {
    width: 45vw;
    height: 45vw;
    bottom: -10%;
    left: -15%;
    background: radial-gradient(circle, rgba(126, 182, 255, 0.14), transparent 70%);
    animation-delay: -6s;
}

.ambient-noise {
    position: absolute;
    inset: 0;
    opacity: 0.035;
    background-image:
        radial-gradient(circle at 1px 1px, #fff 1px, transparent 0);
    background-size: 3px 3px;
}

@keyframes drift {
    from { transform: translate3d(0, 0, 0) scale(1); }
    to { transform: translate3d(-4%, 6%, 0) scale(1.08); }
}

/* Nav */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    height: calc(var(--nav-h) + env(safe-area-inset-top));
    padding-top: env(safe-area-inset-top);
    background: rgba(5, 7, 10, 0.55);
    backdrop-filter: blur(18px) saturate(140%);
    -webkit-backdrop-filter: blur(18px) saturate(140%);
    border-bottom: 1px solid transparent;
    transition: border-color 0.3s ease, background 0.3s ease;
}

.nav.is-scrolled {
    border-bottom-color: var(--line);
    background: rgba(5, 7, 10, 0.82);
}

.nav-inner {
    width: min(100% - 40px, var(--container));
    margin: 0 auto;
    height: var(--nav-h);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.nav-left {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.lang-switch {
    position: relative;
    z-index: 120;
}

.lang-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 36px;
    padding: 0 10px;
    border: 1px solid var(--line-strong);
    border-radius: 10px;
    background: rgba(17, 22, 31, 0.72);
    color: var(--text);
    font-family: var(--font-mono);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    cursor: pointer;
    transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
    -webkit-tap-highlight-color: transparent;
}

.lang-btn:hover,
.lang-switch.is-open .lang-btn {
    border-color: rgba(184, 255, 60, 0.45);
    color: var(--accent);
    background: rgba(184, 255, 60, 0.08);
}

.lang-btn-chevron {
    font-size: 0.7rem;
    opacity: 0.7;
    transition: transform 0.2s var(--ease);
}

.lang-switch.is-open .lang-btn-chevron {
    transform: rotate(180deg);
}

.lang-menu {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    min-width: 148px;
    margin: 0;
    padding: 6px;
    list-style: none;
    border: 1px solid var(--line-strong);
    border-radius: 12px;
    background: rgba(8, 11, 16, 0.96);
    backdrop-filter: blur(16px) saturate(140%);
    -webkit-backdrop-filter: blur(16px) saturate(140%);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
}

.lang-menu[hidden] {
    display: none;
}

.lang-menu button {
    width: 100%;
    display: block;
    text-align: left;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: var(--text-muted);
    font-family: var(--font-sans);
    font-size: 0.92rem;
    font-weight: 500;
    padding: 10px 12px;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
}

.lang-menu button:hover,
.lang-menu button[aria-selected="true"] {
    background: var(--accent-soft);
    color: var(--accent);
}

.theme-switch {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 8px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(17, 22, 31, 0.55);
}

.theme-dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 2px solid transparent;
    cursor: pointer;
    padding: 0;
    transition: transform 0.2s var(--ease), box-shadow 0.2s ease, border-color 0.2s ease;
}

.theme-dot[data-theme="lime"] { background: #b8ff3c; }
.theme-dot[data-theme="steel"] { background: #7eb6ff; }
.theme-dot[data-theme="amber"] { background: #ffb84d; }

.theme-dot:hover {
    transform: scale(1.12);
}

.theme-dot[aria-pressed="true"] {
    border-color: #fff;
    box-shadow: 0 0 0 3px var(--accent-soft);
}

.nav-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-display);
    font-weight: 700;
    letter-spacing: -0.03em;
}

.nav-logo-mark {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border-radius: 9px;
    background: var(--accent);
    color: var(--accent-ink);
    font-size: 0.95rem;
    font-weight: 800;
}

.nav-logo-text {
    font-size: 1.05rem;
    color: var(--text);
}

.nav-links {
    display: flex;
    gap: 28px;
    list-style: none;
}

.nav-links a {
    font-size: 0.92rem;
    font-weight: 500;
    color: var(--text-muted);
    transition: color 0.25s ease;
}

.nav-links a:hover {
    color: var(--text);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    min-width: 44px;
    min-height: 44px;
    border-radius: 10px;
    -webkit-tap-highlight-color: transparent;
}

.nav-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text);
    transition: transform 0.25s ease, opacity 0.25s ease;
    transform-origin: center;
}

.nav-toggle.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.nav-toggle.active span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* Hero — one composition, brand first, full-bleed media */
.hero {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    min-height: 100dvh;
    display: grid;
    align-items: end;
    padding:
        calc(var(--nav-h) + env(safe-area-inset-top) + 24px)
        0
        clamp(28px, 5vh, 56px);
    overflow: hidden;
}

.hero-media {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero-media-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 18%;
    transform: scale(1.04);
    animation: heroZoom 12s var(--ease) both;
    filter: saturate(0.92) contrast(1.05);
}

.hero-media-shade {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(5, 7, 10, 0.92) 0%, rgba(5, 7, 10, 0.72) 42%, rgba(5, 7, 10, 0.28) 100%),
        linear-gradient(180deg, rgba(5, 7, 10, 0.35) 0%, rgba(5, 7, 10, 0.15) 35%, rgba(5, 7, 10, 0.92) 100%);
}

@keyframes heroZoom {
    from { transform: scale(1.12); }
    to { transform: scale(1.04); }
}

.hero-content {
    position: relative;
    z-index: 1;
    width: min(100% - 40px, var(--container));
    margin: 0 auto;
    padding-bottom: 18px;
}

.hero-brand {
    font-family: var(--font-display);
    font-size: clamp(3.8rem, 13vw, 8.6rem);
    font-weight: 800;
    line-height: 0.86;
    letter-spacing: -0.07em;
    color: var(--text);
    margin-bottom: clamp(12px, 2.4vh, 20px);
    text-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(1.35rem, 2.8vw, 2.05rem);
    font-weight: 700;
    line-height: 1.12;
    letter-spacing: -0.04em;
    max-width: 16ch;
    margin-bottom: 12px;
    color: rgba(238, 242, 247, 0.9);
}

.hero-lead {
    font-family: var(--font-mono);
    font-size: clamp(0.82rem, 1.2vw, 0.92rem);
    color: rgba(238, 242, 247, 0.72);
    max-width: 42ch;
    margin-bottom: 22px;
    letter-spacing: 0.01em;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 22px;
    border-radius: 999px;
    font-family: var(--font-sans);
    font-size: 0.95rem;
    font-weight: 600;
    transition: transform 0.25s var(--ease), background 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn-primary {
    background: var(--accent);
    color: var(--accent-ink);
}

.btn-primary:hover {
    filter: brightness(1.08);
    color: var(--accent-ink);
}

.btn-ghost {
    border: 1px solid var(--line-strong);
    background: rgba(5, 7, 10, 0.35);
    color: var(--text);
    backdrop-filter: blur(8px);
}

.btn-ghost:hover {
    border-color: rgba(238, 242, 247, 0.35);
    background: rgba(5, 7, 10, 0.55);
}

.hero-meta {
    position: relative;
    z-index: 1;
    width: min(100% - 40px, var(--container));
    margin: 18px auto 0;
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: var(--font-mono);
    font-size: 0.78rem;
    color: var(--text-muted);
    letter-spacing: 0.02em;
}

.hero-meta-dot {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 0 4px var(--accent-soft);
}

/* Now playing */
.now-playing {
    margin-top: 20px;
    width: min(100%, 420px);
    display: grid;
    grid-template-columns: 56px 1fr auto;
    grid-template-areas:
        "art meta controls"
        "progress progress progress";
    gap: 8px 12px;
    align-items: center;
    padding: 10px 12px;
    border-radius: 16px;
    border: 1px solid rgba(238, 242, 247, 0.12);
    background:
        linear-gradient(135deg, var(--accent-soft), rgba(5, 7, 10, 0.55) 42%, rgba(126, 182, 255, 0.06)),
        rgba(8, 11, 16, 0.72);
    backdrop-filter: blur(18px) saturate(140%);
    -webkit-backdrop-filter: blur(18px) saturate(140%);
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.3);
    position: relative;
}

.now-playing.is-playing {
    border-color: color-mix(in srgb, var(--accent) 40%, transparent);
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.3), 0 0 0 1px var(--accent-soft);
}

.np-art-wrap {
    grid-area: art;
    position: relative;
    width: 56px;
    height: 56px;
}

.np-art {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    object-fit: cover;
    display: block;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.now-playing.is-playing .np-art {
    box-shadow: 0 8px 24px var(--accent-glow);
}

.np-eq {
    position: absolute;
    right: -4px;
    bottom: -4px;
    display: flex;
    align-items: flex-end;
    gap: 2px;
    height: 16px;
    padding: 3px 4px;
    border-radius: 8px;
    background: rgba(5, 7, 10, 0.85);
    border: 1px solid rgba(184, 255, 60, 0.25);
    opacity: 0;
    transition: opacity 0.25s ease;
}

.now-playing.is-playing .np-eq {
    opacity: 1;
}

.np-eq span {
    width: 3px;
    height: 6px;
    border-radius: 2px;
    background: var(--accent);
    transform-origin: bottom;
    animation: npBar 0.9s ease-in-out infinite alternate;
}

.np-eq span:nth-child(2) { animation-delay: 0.15s; height: 10px; }
.np-eq span:nth-child(3) { animation-delay: 0.3s; height: 8px; }
.np-eq span:nth-child(4) { animation-delay: 0.45s; height: 12px; }

@keyframes npBar {
    from { transform: scaleY(0.35); }
    to { transform: scaleY(1); }
}

.np-meta {
    grid-area: meta;
    min-width: 0;
}

.np-label {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 4px;
}

.np-title {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.15;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.np-artist {
    color: var(--text-muted);
    font-size: 0.8rem;
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.np-controls {
    grid-area: controls;
}

.np-btn {
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 50%;
    background: var(--accent);
    color: var(--accent-ink);
    display: grid;
    place-items: center;
    cursor: pointer;
    transition: transform 0.2s var(--ease), filter 0.2s ease;
    box-shadow: 0 8px 20px var(--accent-glow);
}

.np-btn:hover {
    transform: scale(1.05);
    filter: brightness(1.08);
}

.np-btn.is-playing .np-icon-play { display: none; }
.np-btn.is-playing .np-icon-pause { display: block; }
.np-btn:not(.is-playing) .np-icon-pause { display: none; }

.np-progress-block {
    grid-area: progress;
    display: grid;
    gap: 6px;
}

.np-seek {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 6px;
    border-radius: 999px;
    background: rgba(238, 242, 247, 0.12);
    outline: none;
    cursor: pointer;
}

.np-seek::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--accent);
    border: 2px solid var(--accent-ink);
    box-shadow: 0 0 0 4px var(--accent-soft);
    cursor: pointer;
}

.np-seek::-moz-range-thumb {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--accent);
    border: 2px solid #0a1200;
    cursor: pointer;
}

.np-time {
    display: flex;
    justify-content: space-between;
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--text-dim);
}

.np-link {
    position: absolute;
    top: 10px;
    right: 12px;
    font-size: 0.85rem;
    color: var(--text-dim);
    opacity: 0.7;
    transition: color 0.2s ease, opacity 0.2s ease;
}

.np-link:hover {
    color: var(--accent);
    opacity: 1;
}

.yt-host {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    opacity: 0;
    pointer-events: none;
}

@media (max-width: 520px) {
    .now-playing {
        grid-template-columns: 56px 1fr auto;
        width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .np-eq span {
        animation: none !important;
    }
}

.cursor-blink {
    animation: blink 1s steps(1) infinite;
    color: var(--accent);
}

@keyframes blink {
    50% { opacity: 0; }
}

.reveal-hero {
    opacity: 0;
    transform: translateY(28px);
    animation: rise 0.9s var(--ease) forwards;
}

.reveal-hero:nth-child(1) { animation-delay: 0.08s; }
.reveal-hero:nth-child(2) { animation-delay: 0.18s; }
.reveal-hero:nth-child(3) { animation-delay: 0.28s; }
.reveal-hero:nth-child(4) { animation-delay: 0.38s; }

.hero-meta.reveal-hero { animation-delay: 0.5s; }

@keyframes rise {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Sections */
.section {
    position: relative;
    z-index: 1;
    padding: clamp(72px, 12vh, 120px) 0;
}

.section-experience,
.section-contact {
    background:
        linear-gradient(180deg, transparent, rgba(17, 22, 31, 0.55), transparent);
}

.section-head {
    margin-bottom: clamp(36px, 6vh, 56px);
    max-width: 34rem;
}

.section-index {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--accent);
    margin-bottom: 12px;
    letter-spacing: 0.08em;
}

.section-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4.5vw, 3.25rem);
    font-weight: 700;
    letter-spacing: -0.045em;
    line-height: 1.05;
    margin-bottom: 14px;
}

.section-desc {
    color: var(--text-muted);
    font-size: 1.05rem;
}

/* Watchlist — satirical AC subscriptions */
.section-watchlist {
    background:
        radial-gradient(ellipse 70% 50% at 10% 0%, rgba(184, 255, 60, 0.05), transparent 55%),
        radial-gradient(ellipse 55% 45% at 90% 30%, rgba(126, 182, 255, 0.06), transparent 50%);
}

.watch-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.watch-card {
    position: relative;
    padding: 22px 22px 20px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background:
        linear-gradient(165deg, rgba(17, 22, 31, 0.92), rgba(8, 11, 16, 0.78));
    overflow: hidden;
    transition: border-color 0.25s ease, transform 0.35s var(--ease);
}

.watch-card::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 3px;
    background: var(--accent);
    opacity: 0.55;
}

.watch-card[data-ac="be"]::before,
.watch-card[data-ac="ace"]::before {
    background: #ff6b6b;
}

.watch-card[data-ac="vanguard"]::before {
    background: var(--steel);
}

.watch-card:hover {
    border-color: color-mix(in srgb, var(--accent) 35%, var(--line-strong));
    transform: translateY(-2px);
}

.watch-card:hover::before {
    opacity: 1;
    box-shadow: 0 0 18px var(--accent-glow);
}

.watch-card:hover .watch-pill {
    filter: brightness(1.12);
}

.watch-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.watch-badge {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    letter-spacing: 0.12em;
    color: var(--text-dim);
}

.watch-pill {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    letter-spacing: 0.02em;
    padding: 4px 8px;
    border-radius: 999px;
    border: 1px solid transparent;
    white-space: nowrap;
}

.watch-pill.warn {
    color: #f0c35a;
    background: rgba(240, 195, 90, 0.1);
    border-color: rgba(240, 195, 90, 0.28);
    animation: pillPulse 2.4s ease-in-out infinite;
}

.watch-pill.crit {
    color: #ff8f8f;
    background: rgba(255, 107, 107, 0.1);
    border-color: rgba(255, 107, 107, 0.28);
    animation: pillPulse 1.8s ease-in-out infinite;
}

@keyframes pillPulse {
    0%, 100% { opacity: 0.72; box-shadow: none; }
    50% { opacity: 1; box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.04); }
}

.watch-card h3 {
    font-family: var(--font-display);
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    margin-bottom: 14px;
}

.watch-code {
    margin: 0 0 14px;
    padding: 14px 14px 12px;
    border-radius: 10px;
    border: 1px solid var(--line);
    background: rgba(0, 0, 0, 0.35);
    color: #9ad0ff;
    font-family: var(--font-mono);
    font-size: 0.78rem;
    line-height: 1.55;
    white-space: pre-wrap;
    overflow-x: auto;
}

.watch-note {
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.5;
}

.watch-note::before {
    content: "// ";
    color: var(--text-dim);
    font-family: var(--font-mono);
    font-size: 0.82em;
}

/* About */
.about-layout {
    display: grid;
    grid-template-columns: 1.4fr 0.8fr;
    gap: clamp(32px, 6vw, 72px);
    align-items: start;
}

.about-copy {
    display: grid;
    gap: 18px;
    font-size: 1.06rem;
    color: rgba(238, 242, 247, 0.86);
}

.about-copy strong {
    color: var(--text);
    font-weight: 700;
}

.link {
    color: var(--accent);
    border-bottom: 1px solid rgba(184, 255, 60, 0.35);
    transition: border-color 0.2s ease, color 0.2s ease;
}

.link:hover {
    color: #d6ff7a;
    border-bottom-color: rgba(214, 255, 122, 0.7);
}

.about-metrics {
    display: grid;
    gap: 0;
    border-top: 1px solid var(--line);
}

.about-metrics > div {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 16px;
    align-items: baseline;
    padding: 22px 0;
    border-bottom: 1px solid var(--line);
}

.about-metrics dt {
    font-family: var(--font-display);
    font-size: clamp(2rem, 3vw, 2.6rem);
    font-weight: 700;
    letter-spacing: -0.04em;
    color: var(--accent);
    line-height: 1;
}

.about-metrics dd {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* Experience track — editorial, not card stack */
.track {
    list-style: none;
    display: grid;
    gap: 0;
    border-top: 1px solid var(--line);
}

.track-item {
    display: grid;
    grid-template-columns: minmax(140px, 200px) 1fr;
    gap: 24px;
    padding: 28px 0;
    border-bottom: 1px solid var(--line);
    transition: background 0.3s ease;
}

.track-item.current .track-year {
    color: var(--accent);
}

.track-year {
    font-family: var(--font-mono);
    font-size: 0.82rem;
    color: var(--text-dim);
    padding-top: 6px;
}

.track-body h3 {
    font-family: var(--font-display);
    font-size: clamp(1.15rem, 2vw, 1.45rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    margin-bottom: 6px;
}

.track-org {
    color: var(--text);
    font-weight: 600;
    margin-bottom: 8px;
}

.track-org a {
    color: var(--steel);
    transition: color 0.2s ease;
}

.track-org a:hover {
    color: #a8ceff;
}

.project-trigger {
    appearance: none;
    border: 0;
    background: none;
    padding: 0;
    margin: 0;
    font: inherit;
    color: var(--steel);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: color 0.2s ease;
}

.project-trigger:hover,
.project-trigger:focus-visible {
    color: var(--accent);
    outline: none;
}

.project-trigger-hint {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-dim);
    border: 1px solid var(--line-strong);
    border-radius: 999px;
    padding: 3px 8px;
}

.project-trigger:hover .project-trigger-hint {
    color: var(--accent);
    border-color: rgba(184, 255, 60, 0.35);
}

.project-trigger-inline {
    color: var(--accent);
    border-bottom: 1px solid rgba(184, 255, 60, 0.35);
    border-radius: 0;
    display: inline;
    gap: 0;
}

.project-trigger-inline:hover {
    color: #d6ff7a;
    border-bottom-color: rgba(214, 255, 122, 0.7);
}

.track-tags {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* Gallery modal — cinematic lightbox */
.gallery-modal {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: grid;
    place-items: center;
    padding:
        max(12px, env(safe-area-inset-top))
        16px
        max(12px, env(safe-area-inset-bottom));
}

.gallery-modal[hidden] {
    display: none;
}

.gallery-backdrop {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 80% 60% at 50% 20%, rgba(184, 255, 60, 0.06), transparent 55%),
        rgba(2, 4, 8, 0.88);
    backdrop-filter: blur(18px) saturate(120%);
    -webkit-backdrop-filter: blur(18px) saturate(120%);
}

.gallery-dialog {
    position: relative;
    z-index: 1;
    width: min(100%, 1100px);
    max-height: min(94vh, 920px);
    display: grid;
    grid-template-rows: auto 1fr auto;
    gap: 18px;
    padding: 0;
    border: 0;
    background: transparent;
    animation: galleryIn 0.4s var(--ease);
}

@keyframes galleryIn {
    from { opacity: 0; transform: translateY(20px) scale(0.985); }
    to { opacity: 1; transform: none; }
}

.gallery-top {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 12px;
}

.gallery-top-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.gallery-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 0 6px rgba(184, 255, 60, 0.12);
}

.gallery-kicker {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 2px;
}

.gallery-top h2 {
    font-family: var(--font-display);
    font-size: clamp(1.25rem, 2.4vw, 1.7rem);
    letter-spacing: -0.04em;
    line-height: 1;
}

.gallery-counter {
    font-family: var(--font-mono);
    font-size: 0.78rem;
    color: var(--text-dim);
    justify-self: center;
}

.gallery-top-right {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 8px;
}

.gallery-site {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text);
    border: 1px solid rgba(238, 242, 247, 0.14);
    border-radius: 999px;
    padding: 9px 14px;
    background: rgba(255, 255, 255, 0.03);
    transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.gallery-site:hover {
    color: var(--accent);
    border-color: rgba(184, 255, 60, 0.35);
    background: rgba(184, 255, 60, 0.06);
}

.gallery-close {
    width: 40px;
    height: 40px;
    border: 1px solid rgba(238, 242, 247, 0.14);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.03);
    color: var(--text);
    display: grid;
    place-items: center;
    cursor: pointer;
    transition: border-color 0.2s ease, background 0.2s ease;
}

.gallery-close:hover {
    border-color: rgba(238, 242, 247, 0.3);
    background: rgba(255, 255, 255, 0.06);
}

.gallery-stage {
    position: relative;
    display: grid;
    grid-template-columns: 48px 1fr 48px;
    gap: 14px;
    align-items: center;
    min-height: 0;
}

.gallery-browser {
    min-height: 0;
    border-radius: 18px;
    overflow: hidden;
    border: 1px solid rgba(238, 242, 247, 0.1);
    background: #0a0d12;
    box-shadow:
        0 40px 100px rgba(0, 0, 0, 0.55),
        0 0 0 1px rgba(184, 255, 60, 0.04);
}

.gallery-browser-bar {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 10px 14px;
    background: linear-gradient(180deg, #151a22, #10141b);
    border-bottom: 1px solid rgba(238, 242, 247, 0.06);
}

.gallery-browser-bar > span {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #ff5f57;
}

.gallery-browser-bar > span:nth-child(2) { background: #febc2e; }
.gallery-browser-bar > span:nth-child(3) { background: #28c840; }

.gallery-browser-url {
    margin-left: 8px;
    flex: 1;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: var(--text-dim);
    background: rgba(0, 0, 0, 0.28);
    border-radius: 8px;
    padding: 6px 10px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.gallery-figure {
    margin: 0;
    background: #070a0f;
}

.gallery-figure img {
    width: 100%;
    max-height: min(62vh, 620px);
    object-fit: cover;
    object-position: top center;
    display: block;
    opacity: 1;
    transition: opacity 0.28s ease;
}

.gallery-figure img.is-switching {
    opacity: 0;
}

.gallery-nav {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid rgba(238, 242, 247, 0.12);
    background: rgba(10, 13, 18, 0.7);
    color: var(--text);
    display: grid;
    place-items: center;
    cursor: pointer;
    backdrop-filter: blur(10px);
    transition: border-color 0.2s ease, color 0.2s ease, transform 0.2s var(--ease);
}

.gallery-nav:hover {
    border-color: rgba(184, 255, 60, 0.4);
    color: var(--accent);
    transform: scale(1.05);
}

.gallery-bottom {
    display: grid;
    gap: 12px;
    justify-items: center;
}

.gallery-caption {
    font-family: var(--font-mono);
    font-size: 0.78rem;
    color: var(--text-muted);
    text-align: center;
    min-height: 1.2em;
}

.gallery-thumbs {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    max-width: 100%;
}

.gallery-thumb {
    width: 88px;
    border: 1px solid transparent;
    border-radius: 10px;
    overflow: hidden;
    padding: 0;
    background: #070a0f;
    cursor: pointer;
    opacity: 0.45;
    transition: opacity 0.2s ease, border-color 0.2s ease, transform 0.2s var(--ease);
}

.gallery-thumb img {
    width: 100%;
    height: 52px;
    object-fit: cover;
    object-position: top center;
    display: block;
}

.gallery-thumb.is-active,
.gallery-thumb:hover {
    opacity: 1;
    border-color: rgba(184, 255, 60, 0.55);
    transform: translateY(-2px);
}

body.gallery-open {
    overflow: hidden;
}

@media (max-width: 820px) {
    .gallery-stage {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .gallery-nav {
        position: absolute;
        z-index: 2;
        top: 48%;
        transform: translateY(-50%);
    }

    .gallery-prev { left: 10px; }
    .gallery-next { right: 10px; }

    .gallery-nav:hover {
        transform: translateY(-50%) scale(1.05);
    }

    .gallery-top {
        grid-template-columns: 1fr auto;
    }

    .gallery-counter {
        display: none;
    }

    .gallery-figure img {
        max-height: min(56vh, 480px);
    }
}

/* Projects showcase */
.projects-showcase {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.project-tile {
    position: relative;
    display: block;
    width: 100%;
    border: 0;
    padding: 0;
    overflow: hidden;
    cursor: pointer;
    background: #000;
    text-align: left;
    min-height: 280px;
    isolation: isolate;
    transition: transform 0.35s var(--ease);
}

.project-tile img {
    width: 100%;
    height: 100%;
    min-height: 280px;
    object-fit: cover;
    object-position: top center;
    transform: scale(1.03);
    transition: transform 0.5s var(--ease), filter 0.35s ease;
    filter: saturate(0.92) brightness(0.86);
}

.project-tile-shade {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, transparent 28%, rgba(5, 7, 10, 0.88) 100%),
        linear-gradient(90deg, rgba(5, 7, 10, 0.25), transparent 50%);
    z-index: 1;
}

.project-tile-body {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2;
    padding: 22px 20px;
    display: grid;
    gap: 6px;
}

.project-tile-name {
    font-family: var(--font-display);
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    color: var(--text);
}

.project-tile-note {
    color: rgba(238, 242, 247, 0.72);
    font-size: 0.9rem;
}

.project-tile-cta {
    margin-top: 8px;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent);
}

.project-tile:hover img,
.project-tile:focus-visible img {
    transform: scale(1.07);
    filter: saturate(1) brightness(0.95);
}

.project-tile:hover,
.project-tile:focus-visible {
    transform: translateY(-2px);
}

.project-tile:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
}

/* Skills — stack in battle */
.skills-battle {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0;
    border-top: 1px solid var(--line);
}

.skill-battle {
    padding: 28px 18px 26px 0;
    border-bottom: 1px solid var(--line);
    border-right: 1px solid var(--line);
}

.skill-battle:last-child {
    border-right: 0;
    padding-right: 0;
}

.skill-battle h3 {
    font-family: var(--font-display);
    font-size: clamp(1.2rem, 2vw, 1.45rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    margin-bottom: 10px;
    color: var(--accent);
}

.skill-battle p {
    color: var(--text-muted);
    font-size: 0.92rem;
    line-height: 1.45;
    max-width: 16ch;
}

/* Contact */
.contact-panel {
    border-top: 1px solid var(--line);
    padding-top: 28px;
}

.contact-status {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 28px;
}

.status-live {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 0 0 var(--accent-glow);
    animation: pulse 2s ease infinite;
}

@keyframes pulse {
    70% { box-shadow: 0 0 0 10px transparent; }
    100% { box-shadow: 0 0 0 0 transparent; }
}

.contact-links {
    display: grid;
    gap: 0;
}

.contact-link {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 16px;
    align-items: baseline;
    padding: 22px 0;
    border-bottom: 1px solid var(--line);
    transition: color 0.2s ease, padding-left 0.25s var(--ease);
}

a.contact-link:hover,
button.contact-link-copy:hover {
    color: var(--accent);
    padding-left: 8px;
}

.contact-link-label {
    font-family: var(--font-mono);
    font-size: 0.78rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.contact-link-value {
    font-family: var(--font-display);
    font-size: clamp(1.2rem, 2.5vw, 1.7rem);
    font-weight: 700;
    letter-spacing: -0.03em;
}

.contact-link-copy {
    width: 100%;
    background: none;
    border: 0;
    color: inherit;
    cursor: pointer;
    font: inherit;
    text-align: left;
}

.copy-hint {
    display: inline-block;
    margin-left: 10px;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.04em;
    color: var(--text-dim);
    vertical-align: middle;
}

.toast {
    position: fixed;
    left: 50%;
    bottom: calc(24px + env(safe-area-inset-bottom));
    transform: translateX(-50%) translateY(12px);
    z-index: 300;
    padding: 12px 18px;
    border-radius: 12px;
    border: 1px solid var(--line-strong);
    background: rgba(8, 11, 16, 0.96);
    color: var(--text);
    font-family: var(--font-mono);
    font-size: 0.82rem;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease, transform 0.25s var(--ease);
}

.toast.is-on {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.toast[hidden] {
    display: none;
}

/* FAQ */
.faq-list {
    border-top: 1px solid var(--line);
}

.faq-item {
    border-bottom: 1px solid var(--line);
    padding: 8px 0;
}

.faq-item summary {
    list-style: none;
    cursor: pointer;
    font-family: var(--font-display);
    font-size: clamp(1.1rem, 2.2vw, 1.4rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    padding: 18px 0;
    color: var(--text);
}

.faq-item summary::-webkit-details-marker {
    display: none;
}

.faq-item summary::after {
    content: "+";
    float: right;
    color: var(--accent);
    font-weight: 700;
}

.faq-item[open] summary::after {
    content: "–";
}

.faq-item p {
    color: var(--text-muted);
    max-width: 52rem;
    padding-bottom: 18px;
    line-height: 1.7;
}

/* Footer */
.footer {
    position: relative;
    z-index: 1;
    padding: 40px 0 calc(40px + env(safe-area-inset-bottom));
    border-top: 1px solid var(--line);
}

.footer-inner {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 16px 24px;
}

.footer-brand {
    font-family: var(--font-display);
    font-weight: 700;
    letter-spacing: -0.03em;
}

.footer-meta {
    font-family: var(--font-mono);
    font-size: 0.74rem;
    color: var(--text-dim);
    letter-spacing: 0.02em;
    justify-self: center;
    display: inline-flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
}

.footer-sep {
    opacity: 0.55;
}

.footer-copy {
    font-family: var(--font-mono);
    font-size: 0.78rem;
    color: var(--text-dim);
    justify-self: end;
}

/* Reveal on scroll */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Mobile */
@media (max-width: 860px) {
    .about-layout {
        grid-template-columns: 1fr;
        gap: 36px;
    }

    .watch-grid {
        grid-template-columns: 1fr;
    }

    .projects-showcase {
        grid-template-columns: 1fr;
    }

    .skills-battle {
        grid-template-columns: 1fr 1fr;
    }

    .skill-battle:nth-child(2n) {
        border-right: 0;
        padding-right: 0;
    }

    .skill-battle {
        padding-right: 14px;
    }

    .track-item {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .footer-inner {
        grid-template-columns: 1fr;
        justify-items: start;
    }

    .footer-meta,
    .footer-copy {
        justify-self: start;
    }

    .track-year {
        padding-top: 0;
    }

    .hero-media-shade {
        background:
            linear-gradient(180deg, rgba(5, 7, 10, 0.45) 0%, rgba(5, 7, 10, 0.25) 30%, rgba(5, 7, 10, 0.94) 78%),
            linear-gradient(90deg, rgba(5, 7, 10, 0.55), rgba(5, 7, 10, 0.2));
    }

    .hero-media-img {
        object-position: center 12%;
    }
}

@media (max-width: 640px) {
    .nav-left {
        gap: 10px;
    }

    .nav-logo-text {
        display: none;
    }

    .lang-btn {
        min-height: 40px;
        padding: 0 12px;
    }

    .theme-switch {
        padding: 5px 7px;
        gap: 7px;
    }

    .skills-battle {
        grid-template-columns: 1fr;
    }

    .skill-battle {
        border-right: 0;
        padding-right: 0;
    }

    .nav-links {
        position: fixed;
        inset: calc(var(--nav-h) + env(safe-area-inset-top)) 0 0 0;
        flex-direction: column;
        gap: 0;
        padding: 24px 20px calc(24px + env(safe-area-inset-bottom));
        background: rgba(5, 7, 10, 0.96);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        transform: translateX(100%);
        transition: transform 0.35s var(--ease);
        z-index: 99;
    }

    .nav-links.open {
        transform: translateX(0);
    }

    .nav-links a {
        display: block;
        padding: 18px 8px;
        font-size: 1.2rem;
        font-family: var(--font-display);
        font-weight: 700;
        letter-spacing: -0.03em;
        color: var(--text);
        border-bottom: 1px solid var(--line);
    }

    .nav-toggle {
        display: flex;
    }

    .contact-link {
        grid-template-columns: 1fr;
        gap: 6px;
    }

    .hero-actions {
        width: 100%;
    }

    .btn {
        flex: 1 1 auto;
    }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .ambient-orb,
    .hero-media-img,
    .cursor-blink,
    .status-live,
    .watch-pill,
    .reveal-hero {
        animation: none !important;
    }
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
    .reveal-hero {
        opacity: 1;
        transform: none;
    }
}
