/* ============================================================
   逆天小金龙 - Editorial redesign
   Layout language: oversized serif type, hairline dividers,
   left-aligned hero, index-list platforms, one marquee ribbon.
   Color rule: monochrome chrome, per-platform brand color on
   hover only, MC lime green as the single saturated accent.
   ============================================================ */

:root[data-theme="dark"] {
    --bg: #0c0e17;
    --surface: #131726;
    --on-surface: #f2f4fb;
    --on-surface-muted: #97a0bc;
    --hairline: rgba(242, 244, 251, 0.16);
    --hairline-soft: rgba(242, 244, 251, 0.07);
    --accent: #8dff2e;
    --accent-dim: rgba(141, 255, 46, 0.12);
    --overlay-color: rgba(12, 14, 23, 0.87);
    --glow-ambient-1: rgba(141, 255, 46, 0.06);
    --glow-ambient-2: rgba(0, 195, 255, 0.05);
    --modal-bg: #131726;
}

:root[data-theme="light"] {
    --bg: #faf7f2;
    --surface: #ffffff;
    --on-surface: #1c1815;
    --on-surface-muted: #6d665b;
    --hairline: rgba(28, 24, 21, 0.18);
    --hairline-soft: rgba(28, 24, 21, 0.07);
    --accent: #3f7d0c;
    --accent-dim: rgba(63, 125, 12, 0.1);
    --overlay-color: rgba(250, 247, 242, 0.88);
    --glow-ambient-1: rgba(63, 125, 12, 0.06);
    --glow-ambient-2: rgba(0, 130, 180, 0.05);
    --modal-bg: #ffffff;
}

:root {
    --radius-frame: 8px;
    --radius-card: 14px;

    --font-serif: 'Fraunces', 'Noto Serif SC', 'Noto Serif TC', serif;   /* hero title only */

    /* nav / chrome */
    --f-brand: 'Fraunces', 'Noto Serif SC', 'Noto Serif TC', serif;                  /* site name */
    --f-dock: 'Space Grotesk', 'Noto Sans TC', 'Noto Sans SC', sans-serif;           /* dock links */
    --f-lang: 'Space Grotesk', 'Noto Sans TC', 'Noto Sans SC', sans-serif;           /* language buttons */

    /* hero */
    --f-tag: 'Space Grotesk', 'Noto Sans SC', sans-serif;                            /* MC ANIMATOR tag */
    --f-meta: 'Space Grotesk', 'Noto Sans TC', 'Noto Sans SC', sans-serif;           /* hero meta line */
    --f-contact: 'Plus Jakarta Sans', 'Noto Sans SC', 'Noto Sans TC', sans-serif;    /* contact pill */
    --f-badge: 'Syne', 'Noto Sans SC', sans-serif;                                   /* copy badge */
    --f-xp: 'Space Grotesk', sans-serif;                                             /* XP level 64 */

    /* section headers and status chips */
    --f-sec-title: 'Fraunces', 'Noto Serif SC', 'Noto Serif TC', serif;              /* section titles */
    --f-chip-new: 'Space Grotesk', sans-serif;                                       /* NEW chip */
    --f-chip-3d: 'Space Grotesk', 'Noto Sans SC', sans-serif;                        /* 3D / 360 chip */
    --f-eyebrow: 'Space Grotesk', 'Noto Sans SC', sans-serif;                        /* WATCH EVERYWHERE */
    --f-status: 'Space Grotesk', 'Noto Sans SC', sans-serif;                         /* LOADING / error */

    /* latest work */
    --f-fallback: 'Noto Sans SC', 'Noto Sans TC', 'Plus Jakarta Sans', sans-serif;   /* bilibili fallback link */

    /* avatar viewer */
    --f-hint: 'Space Grotesk', 'Noto Sans SC', sans-serif;                           /* drag/zoom hint */

    /* marquee */
    --f-marquee: 'Fraunces', 'Noto Serif SC', 'Noto Serif TC', serif;                /* ribbon text */

    /* platform list */
    --f-index: 'Space Grotesk', sans-serif;                                          /* row indices */
    --f-row-name: 'Fraunces', 'Noto Serif SC', 'Noto Serif TC', serif;               /* platform names */
    --f-sub: 'Space Grotesk', 'Plus Jakarta Sans', sans-serif;                       /* row sub labels */

    /* footer */
    --f-footer-label: 'Syne', 'Noto Sans SC', sans-serif;                            /* special thanks */
    --f-footer-credits: 'Plus Jakarta Sans', 'Noto Sans SC', sans-serif;             /* credits */
    --f-footer-copy: 'Space Grotesk', sans-serif;                                    /* copyright line */

    /* modal */
    --f-modal-badge: 'Syne', 'Noto Sans SC', sans-serif;                             /* WECHAT VIDEO */
    --f-modal-title: 'Fraunces', 'Noto Serif SC', 'Noto Serif TC', serif;            /* modal title */
    --f-modal-hint: 'Plus Jakarta Sans', 'Noto Sans SC', sans-serif;                 /* scan hint */

    /* base stacks (body default + generic fallbacks) */
    --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

    --spring-bounce: 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    --spring-smooth: 0.45s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-fast: 0.2s cubic-bezier(0.2, 0, 0, 1);
}

/* Reset and base styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-tap-highlight-color: transparent;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg);
    color: var(--on-surface);
    font-family: var(--font-sans);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 2rem 4rem;
    overflow-x: hidden;
    transition: background-color var(--spring-smooth), color var(--spring-smooth);
    position: relative;
}

::selection {
    background: var(--accent);
    color: var(--bg);
}

/* Custom interactive cursor */
.custom-cursor {
    display: none;
}

@media (hover: hover) and (pointer: fine) {
    body,
    body * {
        cursor: none !important;
    }

    .custom-cursor {
        display: block;
        position: fixed;
        top: 0;
        left: 0;
        pointer-events: none;
        z-index: 99999;
        mix-blend-mode: difference;
        will-change: transform;
    }

    .cursor-crosshair {
        position: absolute;
        top: -12px;
        left: -12px;
        transition: transform var(--spring-bounce);
    }

    .custom-cursor.morph-active .cursor-crosshair {
        transform: scale(1.5) rotate(45deg);
    }
}

/* Background layers: restrained MC canvas + overlays */
.mc-bg-canvas {
    position: fixed;
    top: -5%;
    left: -5%;
    width: 110%;
    height: 110%;
    z-index: -3;
    pointer-events: none;
    image-rendering: pixelated;
    filter: blur(2px) saturate(0.8) brightness(0.9);
    transition: transform 0.12s ease-out;
}

:root[data-theme="light"] .mc-bg-canvas {
    filter: blur(2.5px) saturate(0.55) brightness(1.05);
}

.bg-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: var(--overlay-color);
    z-index: -2;
    pointer-events: none;
    transition: background var(--spring-smooth);
}

.grid-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-size: 38px 38px;
    background-image: linear-gradient(to right, var(--hairline-soft) 1px, transparent 1px),
                      linear-gradient(to bottom, var(--hairline-soft) 1px, transparent 1px);
    z-index: -2;
    pointer-events: none;
    opacity: 0.5;
}

.ambient-glow {
    position: fixed;
    border-radius: 50%;
    filter: blur(130px);
    z-index: -1;
    pointer-events: none;
    opacity: 0.7;
    transition: background var(--spring-smooth);
}

.glow-1 {
    width: 65vw;
    height: 65vw;
    top: -20%;
    left: -15%;
    background: radial-gradient(circle, var(--glow-ambient-1) 0%, transparent 68%);
}

.glow-2 {
    width: 60vw;
    height: 60vw;
    bottom: -15%;
    right: -10%;
    background: radial-gradient(circle, var(--glow-ambient-2) 0%, transparent 68%);
}

/* Film grain, fixed and non-interactive */
.noise-overlay {
    position: fixed;
    inset: 0;
    z-index: 2000;
    pointer-events: none;
    opacity: 0.05;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
    background-size: 180px 180px;
}

/* Studio navigation bar */
.studio-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1.1rem 2.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 100;
    pointer-events: none;
    /* Solid frosted bar: page content scrolling underneath must never
       collide visually with the brand / dock text. */
    background: color-mix(in srgb, var(--bg) 82%, transparent);
    backdrop-filter: blur(16px) saturate(1.05);
    -webkit-backdrop-filter: blur(16px) saturate(1.05);
    border-bottom: 1px solid var(--hairline-soft);
}

.studio-nav > * {
    pointer-events: auto;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    transition: transform var(--spring-bounce);
}

.nav-brand:hover {
    transform: translateY(-1px);
}

.brand-mark {
    width: 9px;
    height: 9px;
    background: var(--accent);
    box-shadow: 0 0 10px var(--accent);
    flex-shrink: 0;
}

.brand-title {
    font-family: var(--f-brand);
    font-weight: 900;
    font-size: 1.08rem;
    color: var(--on-surface);
    letter-spacing: 0.01em;
}

/* Desktop dock navigation */
.dock-nav {
    display: flex;
    align-items: center;
    gap: 1.7rem;
}

.dock-link {
    font-family: var(--f-dock);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.13em;
    text-transform: uppercase;
    color: var(--on-surface-muted);
    text-decoration: none;
    position: relative;
    padding: 0.35rem 0;
    transition: color var(--transition-fast);
}

.dock-link::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 2px;
    background: var(--accent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--spring-smooth);
}

.dock-link:hover,
.dock-link.active {
    color: var(--on-surface);
}

.dock-link:hover::after,
.dock-link.active::after {
    transform: scaleX(1);
}

.control-btn.dock-toggle {
    display: none;
}

/* Mobile dropdown menu */
.dock-menu {
    position: fixed;
    top: 4.7rem;
    right: 1.2rem;
    z-index: 99;
    min-width: 218px;
    display: flex;
    flex-direction: column;
    padding: 0.55rem;
    background: color-mix(in srgb, var(--surface) 90%, transparent);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--hairline);
    border-radius: var(--radius-card);
    box-shadow: 0 18px 44px rgba(0, 0, 0, 0.3);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity var(--spring-smooth), transform var(--spring-smooth), visibility var(--spring-smooth);
}

.dock-menu.open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dock-menu a {
    display: flex;
    align-items: baseline;
    gap: 0.85rem;
    padding: 0.78rem 0.95rem;
    border-radius: var(--radius-frame);
    color: var(--on-surface);
    text-decoration: none;
    font-family: var(--f-dock);
    font-size: 0.92rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    transition: background var(--transition-fast), color var(--transition-fast);
}

.dock-menu a:hover,
.dock-menu a.active {
    background: var(--accent-dim);
    color: var(--accent);
}

.dock-idx {
    font-family: var(--f-index);
    font-size: 0.62rem;
    color: var(--on-surface-muted);
}

.dock-menu a.active .dock-idx,
.dock-menu a:hover .dock-idx {
    color: var(--accent);
}

/* Anchor scroll offset below the fixed header */
#hero {
    scroll-margin-top: 6.5rem;
}

/* Scroll-down hint: floats at the bottom of the first screen to nudge
   users (especially on desktop) to keep scrolling */
.scroll-hint {
    position: fixed;
    left: 50%;
    bottom: 1.5rem;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.58rem 1.1rem;
    background: color-mix(in srgb, var(--bg) 74%, transparent);
    backdrop-filter: blur(14px) saturate(1.05);
    -webkit-backdrop-filter: blur(14px) saturate(1.05);
    border: 1px solid var(--hairline);
    border-radius: 999px;
    color: var(--on-surface-muted);
    font-family: var(--f-eyebrow);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    z-index: 90;
    cursor: pointer;
    transition: color var(--transition-fast), border-color var(--transition-fast),
        opacity var(--spring-smooth), transform var(--spring-smooth), visibility var(--spring-smooth);
}

.scroll-hint:hover {
    color: var(--on-surface);
    border-color: var(--accent);
}

.scroll-hint-arrow {
    color: var(--accent);
    animation: scrollHintBounce 1.6s ease-in-out infinite;
}

.scroll-hint.hidden {
    opacity: 0;
    visibility: hidden;
    transform: translateX(-50%) translateY(14px);
    pointer-events: none;
}

@keyframes scrollHintBounce {

    0%,
    100% {
        transform: translateY(-1px);
    }

    50% {
        transform: translateY(3px);
    }
}

#latestwork,
#avatarpre,
#allplat {
    scroll-margin-top: 5.5rem;
}

.top-controls {
    display: flex;
    align-items: center;
    gap: 1.1rem;
}

.control-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: transparent;
    border: 1px solid var(--hairline);
    border-radius: var(--radius-full, 9999px);
    color: var(--on-surface);
    transition: transform var(--spring-bounce), background var(--transition-fast), color var(--transition-fast), border-color var(--transition-fast);
}

.control-btn:hover {
    transform: rotate(18deg) scale(1.06);
    background: var(--on-surface);
    color: var(--bg);
    border-color: var(--on-surface);
}

.control-btn:active {
    transform: scale(0.92);
}

.lang-switcher {
    display: flex;
    align-items: center;
}

/* Mobile-only trigger: icon button that opens the language panel */
.lang-toggle {
    display: none;
}

.control-btn .material-symbols-outlined {
    font-size: 20px;
    line-height: 1;
    user-select: none;
}

.lang-buttons {
    display: flex;
    gap: 0.3rem;
}

.lang-buttons button {
    background: transparent;
    border: none;
    font-family: var(--f-lang);
    font-size: 0.88rem;
    font-weight: 700;
    padding: 0.4rem 0.55rem;
    color: var(--on-surface-muted);
    position: relative;
    transition: color var(--transition-fast);
    cursor: pointer;
}

.lang-buttons button::after {
    content: '';
    position: absolute;
    left: 0.55rem;
    right: 0.55rem;
    bottom: 0.05rem;
    height: 2px;
    background: var(--accent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--spring-smooth);
}

.lang-buttons button:hover {
    color: var(--on-surface);
}

.lang-buttons button.active {
    color: var(--on-surface);
}

.lang-buttons button.active::after {
    transform: scaleX(1);
}

/* Layout container */
.container.studio-canvas {
    width: 100%;
    max-width: 1140px;
    display: flex;
    flex-direction: column;
    gap: 4.5rem;
    margin-top: 6.5rem;
    position: relative;
    z-index: 10;
}

/* Hero: left-aligned editorial stage */
.hero-stage {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2.1rem;
    padding: clamp(1.5rem, 6vh, 4.5rem) 0 0.5rem;
    min-height: min(72vh, 760px);
    justify-content: center;
}

.hero-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    row-gap: 0.6rem;
}

.meta-tag {
    font-family: var(--f-tag);
    font-size: 0.74rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--accent);
    background: var(--accent-dim);
    border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
    padding: 0.32rem 0.7rem;
    border-radius: 4px;
}

.meta-sep {
    width: 1px;
    height: 14px;
    background: var(--hairline);
}

.meta-text {
    font-family: var(--f-meta);
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--on-surface-muted);
    letter-spacing: 0.01em;
}

/* Oversized display title with line-mask reveal */
.title.hero-title {
    font-family: var(--font-serif);
    font-weight: 900;
    font-size: clamp(4rem, 13.5vw, 10rem);
    line-height: 1.02;
    letter-spacing: -0.015em;
    color: var(--on-surface);
    user-select: none;
}

.hero-line {
    display: block;
    overflow: hidden;
    padding-bottom: 0.07em;
    margin-bottom: -0.03em;
}

.hero-line-inner {
    display: inline-block;
    transform: translateY(112%);
    animation: lineReveal 1.1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    will-change: transform;
}

.hero-title .hero-line:nth-child(1) .hero-line-inner {
    animation-delay: 0.18s;
}

.hero-title .hero-line:nth-child(2) .hero-line-inner {
    animation-delay: 0.36s;
}

.hero-line-outline .hero-line-inner {
    color: transparent;
    -webkit-text-stroke: 2.5px var(--on-surface);
}

.hero-star {
    font-style: normal;
    color: var(--accent);
    -webkit-text-stroke-width: 0;
    font-size: 0.28em;
    vertical-align: 1.9em;
    margin-left: 0.2em;
    text-shadow: 0 0 18px var(--accent);
}

/* Business contact capsule */
.contact-pill {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.8rem 0.85rem 0.8rem 1.3rem;
    background: color-mix(in srgb, var(--surface) 55%, transparent);
    border: 1px solid var(--hairline);
    border-radius: 999px;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    color: var(--on-surface);
    outline: none;
    user-select: none;
    max-width: 640px;
    width: fit-content;
    transition: transform var(--spring-bounce), border-color var(--transition-fast), background var(--transition-fast);
    cursor: pointer;
}

.contact-pill:hover,
.contact-pill:focus-visible {
    transform: translateY(-2px);
    border-color: var(--on-surface);
}

.contact-pill:active {
    transform: translateY(1px) scale(0.99);
}

.contact-pill-content {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    min-width: 0;
}

.contact-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--accent-dim);
    color: var(--accent);
    flex-shrink: 0;
}

.contact-text {
    font-family: var(--f-contact);
    font-size: 0.92rem;
    font-weight: 600;
    line-height: 1.5;
    color: var(--on-surface);
    text-align: left;
    overflow-wrap: anywhere;
}

.copy-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.38rem 0.85rem;
    background: var(--on-surface);
    border: 1px solid var(--on-surface);
    border-radius: 999px;
    font-family: var(--f-badge);
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--bg);
    white-space: nowrap;
    flex-shrink: 0;
    transition: transform var(--spring-bounce), background var(--transition-fast), color var(--transition-fast), box-shadow var(--spring-smooth);
}

.copy-badge.copied {
    background: #07c160;
    border-color: #07c160;
    color: #ffffff;
    transform: scale(1.06);
    box-shadow: 0 4px 16px rgba(7, 193, 96, 0.4);
}

/* Hero action group (Contact capsule + Alt account button) */
.hero-action-group {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    max-width: 100%;
}

.alt-account-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.8rem 1.35rem;
    background: var(--accent-dim);
    border: 1px solid color-mix(in srgb, var(--accent) 38%, transparent);
    border-radius: 999px;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    color: var(--accent);
    text-decoration: none;
    font-family: var(--f-tag);
    font-size: 0.92rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    outline: none;
    user-select: none;
    transition: transform var(--spring-bounce), border-color var(--transition-fast), background var(--transition-fast), color var(--transition-fast);
    cursor: pointer;
}

.alt-account-pill:hover,
.alt-account-pill:focus-visible {
    transform: translateY(-2px);
    background: var(--accent);
    color: var(--bg);
    border-color: var(--accent);
}

.alt-account-pill:active {
    transform: translateY(1px) scale(0.98);
}

.alt-pill-dot {
    font-size: 0.9rem;
    line-height: 1;
}

.alt-pill-arrow {
    display: inline-flex;
    align-items: center;
    transition: transform var(--spring-bounce);
}

.alt-account-pill:hover .alt-pill-arrow {
    transform: translateX(3px);
}

/* Alt Account Page specific styling */
.alt-hero-stage {
    min-height: auto;
    padding: clamp(2.5rem, 8vh, 5.5rem) 0 1.2rem;
    gap: 1.6rem;
}

.alt-subtitle-wrap {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.alt-subtitle {
    font-family: var(--f-meta);
    font-size: clamp(1.2rem, 2.5vw, 1.65rem);
    font-weight: 700;
    color: var(--on-surface-muted);
    letter-spacing: 0.05em;
    background: var(--hairline-soft);
    border: 1px solid var(--hairline);
    padding: 0.4rem 1.1rem;
    border-radius: 999px;
}

.brand-tag {
    font-family: var(--f-tag);
    font-size: 0.65rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    padding: 0.15rem 0.45rem;
    border-radius: 4px;
    background: var(--accent);
    color: var(--bg);
    margin-left: 0.5rem;
    vertical-align: middle;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-family: var(--f-meta);
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--on-surface-muted);
    text-decoration: none;
    transition: color var(--transition-fast), transform var(--spring-bounce);
}

.back-link:hover {
    color: var(--on-surface);
    transform: translateX(-3px);
}

/* Entrance banner for alt accounts at bottom of platforms section */
.alt-entrance-box {
    margin-top: 2.5rem;
    padding: 1.4rem 1.8rem;
    background: color-mix(in srgb, var(--surface) 40%, transparent);
    border: 1px dashed var(--hairline);
    border-radius: var(--radius-card);
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

.alt-entrance-text {
    font-family: var(--f-meta);
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--on-surface-muted);
}

.alt-entrance-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--f-dock);
    font-size: 0.92rem;
    font-weight: 700;
    color: var(--accent);
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 999px;
    background: var(--accent-dim);
    transition: transform var(--spring-bounce), background var(--transition-fast), color var(--transition-fast);
}

.alt-entrance-link:hover {
    transform: translateX(4px);
    background: var(--accent);
    color: var(--bg);
}

/* Minecraft experience bar (scroll progress) */
.mc-xp-bar {
    width: 100%;
    max-width: 620px;
    height: 12px;
    background: #000000;
    border: 2px solid var(--hairline);
    border-radius: 999px;
    position: relative;
    overflow: visible;
}

.mc-xp-progress {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #80FF20 0%, #55aa15 100%);
    border-radius: 999px;
    box-shadow: 0 0 12px rgba(128, 255, 32, 0.6);
    transition: width 0.1s linear;
}

.mc-xp-level {
    font-family: var(--f-xp);
    position: absolute;
    top: -30px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 1.15rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    color: #80FF20;
    text-shadow: 2px 2px 0px #000000, -2px -2px 0px #000000, 2px -2px 0px #000000, -2px 2px 0px #000000;
}

:root[data-theme="light"] .mc-xp-level {
    color: #4a8f10;
    text-shadow: 2px 2px 0px #ffffff, -2px -2px 0px #ffffff, 2px -2px 0px #ffffff, -2px 2px 0px #ffffff;
}

/* Shared section header */
.section-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1.2rem;
    padding-bottom: 1.1rem;
    border-bottom: 1px solid var(--hairline);
    margin-bottom: 1.9rem;
}

.section-title {
    font-family: var(--f-sec-title);
    font-size: clamp(1.8rem, 4vw, 2.7rem);
    font-weight: 900;
    color: var(--on-surface);
    letter-spacing: -0.01em;
    line-height: 1.1;
}

.section-count {
    font-family: var(--f-eyebrow);
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--on-surface-muted);
    white-space: nowrap;
}

.live-chip {
    font-family: var(--f-chip-new);
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--accent);
    white-space: nowrap;
}

.pulse-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 10px var(--accent);
    animation: pulseLive 2s infinite ease-in-out;
}

@keyframes pulseLive {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.35; transform: scale(0.85); }
}

/* Latest work frame */
.video-wrapper {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    border-radius: var(--radius-frame);
    border: 1px solid var(--hairline);
    margin-bottom: 1.2rem;
    background: #000000;
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* Placeholder shown while the region check picks YouTube or Bilibili */
.video-skeleton {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: color-mix(in srgb, var(--surface) 60%, transparent);
}

.video-skeleton-label {
    font-family: var(--f-status);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.22em;
    color: var(--on-surface-muted);
    animation: statusBlink 1.4s steps(1) infinite;
}

.fallback-link {
    font-family: var(--f-fallback);
    display: inline-flex;
    align-items: center;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--on-surface-muted);
    text-decoration: none;
    transition: color var(--transition-fast), transform var(--spring-bounce);
    line-height: 1.6;
    padding: 0.3rem 0;
}

.fallback-link:hover {
    color: var(--on-surface);
    transform: translateX(6px);
}

/* Avatar 3D viewer */
.viewer-frame {
    position: relative;
    aspect-ratio: 16 / 10;
    border: 1px solid var(--hairline);
    border-radius: var(--radius-frame);
    background:
        radial-gradient(120% 90% at 50% 0%, color-mix(in srgb, var(--surface) 72%, transparent), transparent 62%),
        color-mix(in srgb, var(--surface) 24%, transparent);
    overflow: hidden;
}

.viewer-frame canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
    touch-action: pan-y;
}

.viewer-hint {
    font-family: var(--f-hint);
    position: absolute;
    left: 1.1rem;
    bottom: 0.95rem;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--on-surface-muted);
    letter-spacing: 0.08em;
    pointer-events: none;
    z-index: 1;
}

.viewer-status {
    font-family: var(--f-status);
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--accent);
    letter-spacing: 0.22em;
    pointer-events: none;
}

.viewer-frame.loaded .viewer-status {
    display: none;
}

.viewer-frame .viewer-error {
    font-family: var(--f-status);
    display: none;
    position: absolute;
    inset: 0;
    align-items: center;
    justify-content: center;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--on-surface-muted);
    letter-spacing: 0.18em;
    pointer-events: none;
}

.viewer-frame.error .viewer-error {
    display: flex;
}

.status-blink {
    animation: statusBlink 1.1s steps(1) infinite;
}

@keyframes statusBlink {
    50% { opacity: 0; }
}

/* Marquee ribbon, full bleed */
.marquee {
    width: 100vw;
    margin-left: calc(50% - 50vw);
    border-top: 1px solid var(--hairline);
    border-bottom: 1px solid var(--hairline);
    overflow: hidden;
    padding: 1.15rem 0;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
    mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
}

.marquee-track {
    display: flex;
    width: max-content;
    animation: marqueeScroll 32s linear infinite;
}

.marquee:hover .marquee-track,
.marquee:focus-within .marquee-track {
    animation-play-state: paused;
}

.marquee-group {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.marquee-item {
    font-family: var(--f-marquee);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--on-surface-muted);
    white-space: nowrap;
    padding: 0 1.7rem;
}

.marquee-star {
    color: var(--accent);
    font-size: 0.85rem;
    display: flex;
    align-items: center;
}

@keyframes marqueeScroll {
    to { transform: translateX(-50%); }
}

/* Platform index list */
.platform-list {
    display: flex;
    flex-direction: column;
}

.platform-row {
    position: relative;
    display: grid;
    grid-template-columns: 3.4rem 2.3rem minmax(0, 1fr) auto 2.6rem;
    align-items: center;
    gap: 1.5rem;
    padding: 1.7rem 0.7rem;
    border: none;
    border-bottom: 1px solid var(--hairline);
    background: transparent;
    color: var(--on-surface);
    text-decoration: none;
    font-family: inherit;
    text-align: left;
    width: 100%;
    cursor: pointer;
    outline: none;
}

.platform-row:first-child {
    border-top: 1px solid var(--hairline);
}

/* Brand color underline sweep */
.platform-row::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: -1px;
    height: 2px;
    background: var(--row-color);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 1;
}

/* Brand color wash, fading to the right */
.platform-row::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, color-mix(in srgb, var(--row-color) 13%, transparent), transparent 72%);
    opacity: 0;
    transition: opacity 0.45s cubic-bezier(0.16, 1, 0.3, 1);
    pointer-events: none;
}

.platform-row:hover,
.platform-row:focus-visible {
    outline: none;
}

.platform-row:hover::before,
.platform-row:focus-visible::before {
    transform: scaleX(1);
}

.platform-row:hover::after,
.platform-row:focus-visible::after {
    opacity: 1;
}

.row-index {
    font-family: var(--f-index);
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    color: var(--on-surface-muted);
    transition: color var(--transition-fast);
}

.row-icon {
    width: 30px;
    height: 30px;
    color: var(--on-surface-muted);
    transition: color 0.3s cubic-bezier(0.16, 1, 0.3, 1), transform var(--spring-bounce);
    position: relative;
    z-index: 1;
}

.row-icon svg {
    width: 100%;
    height: 100%;
    fill: currentColor;
    display: block;
}

.row-name {
    font-family: var(--f-row-name);
    font-size: clamp(1.5rem, 3vw, 2.4rem);
    font-weight: 900;
    line-height: 1.15;
    letter-spacing: 0.005em;
    color: var(--on-surface);
    overflow-wrap: anywhere;
    position: relative;
    z-index: 1;
    transition: color 0.3s cubic-bezier(0.16, 1, 0.3, 1), transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.row-sub {
    font-family: var(--f-sub);
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    color: var(--on-surface-muted);
    white-space: nowrap;
    position: relative;
    z-index: 1;
    transition: color var(--transition-fast);
}

.row-arrow {
    width: 26px;
    height: 26px;
    color: var(--on-surface-muted);
    justify-self: end;
    position: relative;
    z-index: 1;
    transition: transform var(--spring-bounce), color var(--transition-fast);
}

.row-arrow svg {
    width: 100%;
    height: 100%;
    display: block;
}

.platform-row:hover .row-index,
.platform-row:focus-visible .row-index {
    color: var(--on-surface);
}

.platform-row:hover .row-icon,
.platform-row:focus-visible .row-icon {
    color: var(--row-color);
    transform: rotate(-6deg) scale(1.1);
}

.platform-row:hover .row-name,
.platform-row:focus-visible .row-name {
    color: var(--row-color);
    transform: translateX(10px);
}

.platform-row:hover .row-sub,
.platform-row:focus-visible .row-sub {
    color: var(--on-surface);
}

.platform-row:hover .row-arrow,
.platform-row:focus-visible .row-arrow {
    color: var(--row-color);
    transform: translate(4px, -4px);
}

/* Site footer */
.site-footer {
    border-top: 1px solid var(--hairline);
    padding-top: 2.4rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-row {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 0.6rem 1.1rem;
}

.footer-label {
    font-family: var(--f-footer-label);
    font-size: 0.78rem;
    font-weight: 800;
    color: var(--on-surface-muted);
    text-transform: uppercase;
    letter-spacing: 0.14em;
}

.footer-credits {
    font-family: var(--f-footer-credits);
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 0.6rem;
    font-size: 0.98rem;
    font-weight: 600;
    color: var(--on-surface);
}

.footer-sep {
    color: var(--on-surface-muted);
}

.footer-copy {
    font-family: var(--f-footer-copy);
    font-size: 0.72rem;
    font-weight: 500;
    color: var(--on-surface-muted);
    letter-spacing: 0.14em;
}

/* Modal dialog */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(8, 10, 18, 0.78);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    padding: 1.5rem;
    transition: opacity var(--spring-smooth), visibility var(--spring-smooth);
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-container {
    background: var(--modal-bg);
    padding: 2.8rem 2.4rem;
    border-radius: var(--radius-card);
    border: 1px solid var(--hairline);
    box-shadow: 0 28px 64px rgba(0, 0, 0, 0.5);
    position: relative;
    transform: scale(0.9) translateY(28px);
    transition: transform var(--spring-bounce);
    width: 100%;
    max-width: 440px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.modal-overlay.active .modal-container {
    transform: scale(1) translateY(0);
}

.modal-close {
    position: absolute;
    top: -1.15rem;
    right: -1.15rem;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--on-surface);
    border: 1px solid var(--on-surface);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform var(--spring-bounce), background var(--transition-fast), color var(--transition-fast);
    color: var(--bg);
    cursor: pointer;
}

.modal-close:hover {
    transform: scale(1.1) rotate(90deg);
}

.modal-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.45rem;
    margin-bottom: 1.6rem;
}

.modal-badge {
    font-family: var(--f-modal-badge);
    font-size: 0.7rem;
    color: var(--accent);
    letter-spacing: 0.14em;
}

.modal-title {
    font-family: var(--f-modal-title);
    font-size: 1.9rem;
    font-weight: 900;
    color: var(--on-surface);
}

.qr-code {
    width: 300px;
    height: 300px;
    max-width: 100%;
    object-fit: contain;
    border-radius: var(--radius-frame);
    background: #FFFFFF;
    padding: 1rem;
    border: 1px solid var(--hairline);
}

.modal-hint {
    font-family: var(--f-modal-hint);
    margin-top: 1.3rem;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--on-surface-muted);
}

/* Text transition effect on language switch */
.i18n-text {
    transition: opacity var(--transition-fast), transform var(--transition-fast);
    display: inline-block;
}

.i18n-text.fade-out {
    opacity: 0;
    transform: translateY(4px);
}

/* Entry animations */
@keyframes fadeInUp {
    0% {
        opacity: 0;
        transform: translateY(26px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes lineReveal {
    to {
        transform: translateY(0);
    }
}

@keyframes rowReveal {
    0% {
        opacity: 0;
        transform: translateY(26px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.stagger-1 {
    opacity: 0;
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.1s forwards;
}

.fade-item {
    opacity: 0;
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.fade-1 { animation-delay: 0.6s; }
.fade-2 { animation-delay: 0.75s; }
.fade-3 { animation-delay: 0.9s; }

/* Scroll-triggered reveal */
.reveal {
    opacity: 0;
    transform: translateY(36px);
    transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: opacity, transform;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered reveal for platform rows */
.reveal.visible .platform-row {
    opacity: 0;
    animation: rowReveal 0.7s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.reveal.visible .platform-row:nth-child(1) { animation-delay: 0.05s; }
.reveal.visible .platform-row:nth-child(2) { animation-delay: 0.12s; }
.reveal.visible .platform-row:nth-child(3) { animation-delay: 0.19s; }
.reveal.visible .platform-row:nth-child(4) { animation-delay: 0.26s; }
.reveal.visible .platform-row:nth-child(5) { animation-delay: 0.33s; }
.reveal.visible .platform-row:nth-child(6) { animation-delay: 0.4s; }
.reveal.visible .platform-row:nth-child(7) { animation-delay: 0.47s; }

/* Reduced motion: everything readable, nothing moving */
@media (prefers-reduced-motion: reduce) {
    .marquee-track {
        animation: none;
    }

    .hero-line-inner {
        animation: none;
        transform: none;
    }

    .fade-item,
    .stagger-1 {
        animation: none;
        opacity: 1;
    }

    .reveal.visible .platform-row {
        animation: none;
        opacity: 1;
    }

    .pulse-dot {
        animation: none;
    }

    .scroll-hint-arrow {
        animation: none;
    }

    .status-blink {
        animation: none;
    }

    * {
        transition-duration: 0.01ms !important;
    }
}

/* Responsive adjustments */
@media (max-width: 1024px) {
    .container.studio-canvas {
        max-width: 100%;
        padding: 0 0.5rem;
    }
}

@media (max-width: 900px) {
    .dock-nav {
        display: none;
    }

    .control-btn.dock-toggle {
        display: flex;
    }
}

@media (max-width: 768px) {
    body {
        padding: 0 1.1rem 3rem;
    }

    .studio-nav {
        padding: 1rem 1.2rem;
    }

    .brand-title {
        white-space: nowrap;
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        font-size: 0.98rem;
    }

    .nav-brand {
        min-width: 0;
    }

    .top-controls {
        gap: 0.65rem;
    }

    .scroll-hint {
        bottom: 0.9rem;
        padding: 0.5rem 0.9rem;
        font-size: 0.66rem;
        letter-spacing: 0.18em;
    }

    /* Language switcher compresses into a single icon button with a
       dropdown panel (same visual language as the dock menu). */
    .lang-toggle {
        display: flex;
    }

    .lang-switcher {
        position: relative;
    }

    .lang-buttons {
        position: absolute;
        top: calc(100% + 0.6rem);
        right: 0;
        flex-direction: column;
        gap: 0.15rem;
        min-width: 148px;
        padding: 0.45rem;
        background: color-mix(in srgb, var(--surface) 90%, transparent);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border: 1px solid var(--hairline);
        border-radius: var(--radius-card);
        box-shadow: 0 18px 44px rgba(0, 0, 0, 0.3);
        opacity: 0;
        visibility: hidden;
        transform: translateY(-8px);
        transition: opacity var(--spring-smooth), transform var(--spring-smooth), visibility var(--spring-smooth);
        z-index: 99;
    }

    .lang-switcher.open .lang-buttons {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    .lang-buttons button {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 0.8rem;
        width: 100%;
        text-align: left;
        padding: 0.62rem 0.8rem;
        font-size: 0.92rem;
        border-radius: var(--radius-frame);
    }

    .lang-buttons button::after {
        content: '';
        left: auto;
        right: 0.8rem;
        bottom: calc(50% - 1px);
        width: 0.42rem;
        height: 0.42rem;
        transform: scale(0);
        background: var(--accent);
        box-shadow: 0 0 6px var(--accent);
    }

    .lang-buttons button.active {
        background: var(--accent-dim);
        color: var(--accent);
    }

    .lang-buttons button.active::after {
        transform: scale(1);
    }

    .container.studio-canvas {
        margin-top: 5.5rem;
        gap: 3.2rem;
    }

    .hero-stage {
        min-height: auto;
        padding-top: 1.5rem;
        gap: 1.9rem;
    }

    #hero {
        scroll-margin-top: 5.5rem;
    }

    .hero-line-outline .hero-line-inner {
        -webkit-text-stroke-width: 1.5px;
    }

    .contact-pill {
        flex-direction: column;
        align-items: stretch;
        border-radius: var(--radius-card);
        padding: 0.95rem 1.15rem;
        gap: 0.8rem;
        width: 100%;
        max-width: none;
    }

    .copy-badge {
        align-self: flex-end;
    }

    .platform-row {
        grid-template-columns: 2.1rem 2rem minmax(0, 1fr) 2.2rem;
        gap: 1rem;
        padding: 1.45rem 0.35rem;
    }

    .row-sub {
        display: none;
    }

    .row-name {
        font-size: 1.45rem;
    }

    .row-icon {
        width: 26px;
        height: 26px;
    }

    .marquee-item {
        font-size: 1.05rem;
        padding: 0 1.3rem;
    }

    .viewer-frame {
        aspect-ratio: 4 / 3;
    }

    .modal-container {
        padding: 2.2rem 1.5rem;
    }

    .modal-close {
        top: -0.85rem;
        right: -0.85rem;
        width: 44px;
        height: 44px;
    }

    .qr-code {
        width: 250px;
        height: 250px;
    }

    .footer-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.7rem;
    }
}

@media (max-width: 480px) {
    .row-index {
        display: none;
    }

    .platform-row {
        grid-template-columns: 2rem minmax(0, 1fr) 2.2rem;
    }

    .section-count {
        display: none;
    }
}
