:root {
    color-scheme: dark;
    --bg: #050706;
    --panel: #0d1210;
    --panel-2: #121a17;
    --text: #eef7f2;
    --muted: #9eb3aa;
    --line: rgba(173, 255, 210, 0.14);
    --accent: #20f6a2;
    --accent-2: #42c7ff;
    --danger: #ff6b8b;
    --shadow: 0 24px 80px rgba(0, 0, 0, 0.36);
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    background: radial-gradient(circle at top left, rgba(32, 246, 162, 0.12), transparent 32rem), var(--bg);
    color: var(--text);
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
}

body.anti-inspect-lock {
    overflow: hidden;
}

body.anti-inspect-lock > :not(.anti-inspect-overlay) {
    visibility: hidden;
}

.anti-inspect-overlay {
    position: fixed;
    z-index: 999999;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 1.25rem;
    background:
        radial-gradient(circle at top left, rgba(32, 246, 162, 0.18), transparent 34rem),
        #030504;
}

.anti-inspect-card {
    width: min(100%, 34rem);
    border: 1px solid rgba(32, 246, 162, 0.38);
    padding: clamp(1.2rem, 5vw, 2rem);
    background: rgba(13, 18, 16, 0.96);
    box-shadow: var(--shadow);
    text-align: center;
}

.anti-inspect-card p {
    margin: 0 0 0.65rem;
    color: var(--accent);
    font-family: "JetBrains Mono", monospace;
    font-weight: 800;
    text-transform: uppercase;
}

.anti-inspect-card strong {
    display: block;
    font-size: clamp(1.35rem, 5vw, 2.4rem);
    line-height: 1.15;
}

.safe-context-menu {
    position: fixed;
    z-index: 999998;
    min-width: 12rem;
    overflow: hidden;
    border: 1px solid rgba(173, 255, 210, 0.18);
    background: rgba(13, 18, 16, 0.98);
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.38);
}

.safe-context-menu button,
.safe-context-menu span {
    display: block;
    width: 100%;
    border: 0;
    padding: 0.72rem 0.9rem;
    background: transparent;
    color: var(--text);
    text-align: left;
}

.safe-context-menu button {
    cursor: pointer;
}

.safe-context-menu button:hover {
    background: rgba(32, 246, 162, 0.12);
}

.safe-context-menu span {
    color: var(--muted);
}

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

button,
input {
    font: inherit;
}

.shell-grid {
    position: fixed;
    inset: 0;
    pointer-events: none;
    background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
    background-size: 56px 56px;
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.7), transparent 72%);
    translate: 0 var(--parallax-grid-y, 0);
    animation: gridDrift 18s linear infinite;
    will-change: translate;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 20;
    display: grid;
    grid-template-columns: auto 1fr auto auto auto;
    align-items: center;
    gap: 1rem;
    padding: 1rem clamp(1rem, 4vw, 3.5rem);
    border-bottom: 1px solid var(--line);
    background: rgba(5, 7, 6, 0.82);
    backdrop-filter: blur(18px);
    transition: padding 220ms var(--ease-out), background 220ms var(--ease-out), border-color 220ms var(--ease-out);
}

.site-header.is-scrolled {
    padding-block: 0.7rem;
    border-color: rgba(173, 255, 210, 0.22);
    background: rgba(5, 7, 6, 0.93);
}

.brand,
.mode-toggle,
.nav,
.hero-actions,
.card-meta,
.game-hud,
.share-row,
.admin-chip {
    display: flex;
    align-items: center;
}

.brand {
    min-width: 0;
    gap: 0.75rem;
    transition: transform 220ms var(--ease-out);
}

.brand:hover {
    transform: translateY(-1px);
}

.brand-mark {
    display: grid;
    width: 2.6rem;
    height: 2.6rem;
    place-items: center;
    border: 1px solid var(--accent);
    color: var(--accent);
    font-family: "JetBrains Mono", monospace;
    font-weight: 800;
    animation: markPulse 3.4s ease-in-out infinite;
}

.article-card span,
.tool-card span,
.game-card span,
.eyebrow,
.card-meta,
.site-footer,
.profile-card a {
    color: var(--muted);
}

.nav {
    justify-content: center;
    gap: 0.25rem;
}

.menu-toggle {
    display: none;
    width: 2.75rem;
    height: 2.75rem;
    border: 1px solid var(--line);
    border-radius: 0.5rem;
    background: var(--panel);
    color: var(--text);
    cursor: pointer;
    place-items: center;
    padding: 0.65rem;
}

.menu-toggle span {
    display: block;
    width: 1.2rem;
    height: 2px;
    border-radius: 999px;
    background: var(--text);
    transition: transform 180ms ease, opacity 180ms ease;
}

.menu-toggle span + span {
    margin-top: 0.28rem;
}

.menu-toggle.is-open span:first-child {
    transform: translateY(0.38rem) rotate(45deg);
}

.menu-toggle.is-open span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.is-open span:last-child {
    transform: translateY(-0.38rem) rotate(-45deg);
}

.mobile-mode-toggle {
    display: none;
}

.mobile-nav-tools {
    display: none;
}

.nav > a,
.chip,
.mode-toggle {
    border: 1px solid transparent;
    border-radius: 999px;
    padding: 0.62rem 0.9rem;
    color: var(--muted);
    transition: transform 180ms var(--ease-out), border-color 180ms var(--ease-out), background 180ms var(--ease-out), color 180ms var(--ease-out);
}

.nav > a:hover,
.nav > a.is-active,
.chip.is-active {
    border-color: var(--line);
    background: rgba(255, 255, 255, 0.06);
    color: var(--text);
    transform: translateY(-1px);
}

.mode-toggle {
    gap: 0.55rem;
    background: var(--panel);
    border-color: var(--line);
    color: var(--text);
    cursor: pointer;
    transition: transform 180ms var(--ease-out), box-shadow 180ms var(--ease-out), border-color 180ms var(--ease-out);
}

.admin-login,
.admin-chip {
    min-height: 2.6rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--panel);
    color: var(--text);
    transition: transform 180ms var(--ease-out), box-shadow 180ms var(--ease-out), border-color 180ms var(--ease-out), background 180ms var(--ease-out);
}

.admin-login {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.35rem 0.85rem;
    font-weight: 800;
}

.admin-chip {
    gap: 0.55rem;
    max-width: 12rem;
    padding: 0.28rem 0.75rem 0.28rem 0.28rem;
}

.admin-avatar {
    display: inline-grid;
    width: 2rem;
    height: 2rem;
    flex: 0 0 auto;
    place-items: center;
    border: 1px solid rgba(32, 246, 162, 0.35);
    border-radius: 50%;
    overflow: hidden;
    background: rgba(32, 246, 162, 0.1);
    color: var(--accent);
    font-weight: 900;
}

.admin-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.admin-chip-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 0.92rem;
    font-weight: 800;
}

.lang-switch {
    display: inline-flex;
    align-items: center;
    min-height: 2.6rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    overflow: hidden;
    background: var(--panel);
}

.lang-switch a {
    display: grid;
    min-width: 2.35rem;
    min-height: 2.6rem;
    place-items: center;
    color: var(--muted);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.78rem;
    font-weight: 800;
}

.lang-switch a.is-active {
    background: var(--accent);
    color: #03110b;
}

.mobile-admin-link,
.mobile-admin-chip,
.mobile-lang-switch a {
    min-height: 2.9rem;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.035);
}

.mobile-admin-link,
.mobile-admin-chip {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    border-radius: 0.5rem;
    padding: 0 0.85rem;
    color: var(--text);
    font-weight: 800;
}

.mobile-admin-chip {
    gap: 0.55rem;
    min-width: 0;
}

.mobile-admin-chip span:last-child {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mobile-lang-switch {
    display: inline-flex;
    overflow: hidden;
    border-radius: 0.5rem;
}

.mobile-lang-switch a {
    display: grid;
    min-width: 2.65rem;
    place-items: center;
    color: var(--muted);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.74rem;
    font-weight: 800;
}

.mobile-lang-switch a + a {
    border-left: 0;
}

.mobile-lang-switch a.is-active {
    background: var(--accent);
    color: #03110b;
}

.mode-toggle:hover,
.menu-toggle:hover,
.admin-login:hover,
.admin-chip:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 34px rgba(32, 246, 162, 0.12);
}

.mode-dot {
    width: 0.72rem;
    height: 0.72rem;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 18px var(--accent);
    animation: dotBreathe 1.8s ease-in-out infinite;
}

main {
    position: relative;
    width: min(1160px, calc(100% - 2rem));
    margin: 0 auto;
}

.ad-slot {
    width: 100%;
    min-height: 6rem;
    margin: 1.5rem 0;
    overflow: hidden;
    content-visibility: auto;
    contain-intrinsic-size: 7rem;
}

.ad-slot-below_header {
    margin-top: 1rem;
}

.ad-slot-before_footer {
    margin-bottom: 2rem;
}

.hero,
.showcase-band,
.arcade,
.about-layout,
.article-layout {
    display: grid;
    gap: clamp(1rem, 4vw, 3rem);
}

.hero {
    min-height: calc(100vh - 5.5rem);
    grid-template-columns: minmax(0, 1.08fr) minmax(18rem, 0.72fr);
    align-items: center;
    padding: 4rem 0 2rem;
}

.hero-copy {
    translate: 0 var(--parallax-hero-y, 0);
    animation: heroIn 760ms var(--ease-out) both;
    will-change: translate;
}

.runtime-panel {
    animation: heroIn 860ms 120ms var(--ease-out) both, floatPanel 6s ease-in-out infinite 1s;
}

.eyebrow {
    margin: 0 0 0.75rem;
    font-family: "JetBrains Mono", monospace;
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: uppercase;
}

h1,
h2 {
    margin: 0;
    line-height: 1.05;
}

h1 {
    max-width: 12ch;
    font-size: clamp(3.5rem, 13vw, 8.8rem);
}

h2 {
    font-size: clamp(1.6rem, 4vw, 3rem);
}

.tagline,
.page-title p,
.showcase-band p,
.about-layout p {
    max-width: 45rem;
    color: var(--muted);
    font-size: clamp(1rem, 2vw, 1.2rem);
}

.terminal,
.runtime-panel,
.article-card,
.tool-card,
.profile-card,
.game-stage,
.dev-story {
    border: 1px solid var(--line);
    background: linear-gradient(145deg, rgba(18, 26, 23, 0.9), rgba(8, 11, 10, 0.9));
    box-shadow: var(--shadow);
    transition: transform 220ms var(--ease-out), border-color 220ms var(--ease-out), box-shadow 220ms var(--ease-out);
}

.terminal {
    width: min(100%, 42rem);
    margin: 1.7rem 0;
    overflow: hidden;
}

.terminal:hover,
.article-card:hover,
.tool-card:hover,
.game-card:hover,
.profile-card:hover {
    transform: translateY(-4px);
    border-color: rgba(32, 246, 162, 0.35);
    box-shadow: 0 30px 90px rgba(0, 0, 0, 0.46);
}

.runtime-panel:hover {
    border-color: rgba(32, 246, 162, 0.35);
    box-shadow: 0 30px 90px rgba(0, 0, 0, 0.46);
}

.terminal-top {
    display: flex;
    gap: 0.45rem;
    padding: 0.8rem;
    border-bottom: 1px solid var(--line);
}

.terminal-top span {
    width: 0.72rem;
    height: 0.72rem;
    border-radius: 50%;
    background: var(--danger);
}

.terminal-top span:nth-child(2) {
    background: #ffd166;
}

.terminal-top span:nth-child(3) {
    background: var(--accent);
}

.terminal code {
    display: block;
    min-height: 3.4rem;
    padding: 1rem;
    color: var(--accent);
    font-family: "JetBrains Mono", monospace;
    overflow-wrap: anywhere;
}

.terminal code::after {
    content: "";
    display: inline-block;
    width: 0.56rem;
    height: 1em;
    margin-left: 0.16rem;
    background: var(--accent);
    vertical-align: -0.12em;
    animation: cursorBlink 1s steps(2, start) infinite;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2.8rem;
    border: 1px solid var(--line);
    border-radius: 0.5rem;
    padding: 0.75rem 1rem;
    cursor: pointer;
    transition: transform 180ms var(--ease-out), box-shadow 180ms var(--ease-out), border-color 180ms var(--ease-out), background 180ms var(--ease-out);
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 38px rgba(32, 246, 162, 0.12);
}

.btn.primary {
    background: var(--accent);
    border-color: var(--accent);
    color: #03110b;
    font-weight: 800;
}

.btn.ghost {
    background: rgba(255, 255, 255, 0.04);
    color: var(--text);
}

.btn.small {
    min-height: 2.35rem;
    padding: 0.48rem 0.72rem;
    font-size: 0.88rem;
}

.hero-actions {
    flex-wrap: wrap;
    gap: 0.75rem;
}

.hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
}

.hero-badges span {
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.045);
    color: var(--muted);
    font-size: 0.9rem;
    padding: 0.45rem 0.72rem;
}

.runtime-panel {
    padding: clamp(1rem, 4vw, 2rem);
    transform: perspective(900px) translate3d(var(--parallax-panel-x, 0), var(--parallax-panel-y, 0), 0) rotateX(var(--tilt-x, 0deg)) rotateY(var(--tilt-y, 0deg));
    will-change: transform, translate;
}

.hero-illustration {
    position: relative;
    display: grid;
    min-height: 31rem;
    overflow: hidden;
    align-content: end;
    background:
        radial-gradient(circle at 74% 18%, rgba(66, 199, 255, 0.16), transparent 16rem),
        linear-gradient(145deg, rgba(18, 26, 23, 0.92), rgba(5, 7, 6, 0.94));
}

.scene-window {
    position: absolute;
    inset: 1rem 1rem auto;
    display: flex;
    gap: 0.42rem;
    z-index: 2;
}

.scene-window span {
    width: 0.58rem;
    height: 0.58rem;
    border-radius: 50%;
    background: var(--danger);
}

.scene-window span:nth-child(2) {
    background: #ffd166;
}

.scene-window span:nth-child(3) {
    background: var(--accent);
}

.scene-modes {
    position: absolute;
    top: 3.2rem;
    left: 1rem;
    z-index: 3;
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.scene-modes span {
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 0.35rem 0.55rem;
    background: rgba(255, 255, 255, 0.045);
    color: var(--muted);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
}

.scene-modes span:nth-child(1) {
    animation: modeCoding 8s steps(1, end) infinite;
}

.scene-modes span:nth-child(2) {
    animation: modeNgupil 8s steps(1, end) infinite;
}

.scene-modes span:nth-child(3) {
    animation: modeTidur 8s steps(1, end) infinite;
}

.scene-modes span:nth-child(4) {
    animation: modeNgopi 8s steps(1, end) infinite;
}

.scene-sun {
    position: absolute;
    top: 3.5rem;
    right: 2.4rem;
    width: 5rem;
    aspect-ratio: 1;
    border-radius: 50%;
    background: rgba(32, 246, 162, 0.14);
    box-shadow: 0 0 60px rgba(32, 246, 162, 0.16);
    animation: sleepySun 6s ease-in-out infinite;
}

.wave-scene {
    position: relative;
    z-index: 3;
    height: 24rem;
    margin-top: 3rem;
    overflow: hidden;
}

.wave-person {
    position: absolute;
    left: 50%;
    bottom: 7.4rem;
    width: 13rem;
    height: 17rem;
    transform: translateX(-50%);
    animation: personBreathe 4.8s ease-in-out infinite;
}

.wave-head {
    position: absolute;
    top: 0;
    left: 3.6rem;
    width: 5.8rem;
    height: 5.8rem;
    border: 2px solid rgba(32, 246, 162, 0.82);
    border-radius: 50%;
    background:
        radial-gradient(circle at 35% 42%, #06100c 0 0.2rem, transparent 0.22rem),
        radial-gradient(circle at 65% 42%, #06100c 0 0.2rem, transparent 0.22rem),
        #f1fff9;
    box-shadow: 0 0 38px rgba(32, 246, 162, 0.24);
}

.wave-head::after {
    content: "";
    position: absolute;
    left: 2rem;
    bottom: 1.35rem;
    width: 1.6rem;
    height: 0.7rem;
    border-bottom: 4px solid #06100c;
    border-radius: 50%;
}

.wave-body {
    position: absolute;
    top: 5.6rem;
    left: 3rem;
    width: 7rem;
    height: 9.4rem;
    border: 2px solid rgba(32, 246, 162, 0.58);
    border-radius: 2.3rem 2.3rem 0.8rem 0.8rem;
    background: linear-gradient(160deg, rgba(32, 246, 162, 0.42), rgba(66, 199, 255, 0.18));
}

.wave-arm {
    position: absolute;
    top: 7rem;
    width: 5.6rem;
    height: 1rem;
    border-radius: 999px;
    background: #f1fff9;
    box-shadow: 0 0 14px rgba(241, 255, 249, 0.2);
    transform-origin: left center;
}

.wave-arm.left {
    left: 2rem;
    rotate: 25deg;
}

.wave-arm.right {
    left: 9rem;
    rotate: -55deg;
    animation: waveHand 1.5s ease-in-out infinite;
}

.wave-desk {
    position: absolute;
    left: 8%;
    right: 8%;
    bottom: 2.4rem;
    z-index: 8;
    height: 7rem;
    border: 1px solid var(--line);
    background: linear-gradient(180deg, rgba(18, 26, 23, 0.98), rgba(5, 7, 6, 0.98));
    box-shadow: 0 -20px 60px rgba(0, 0, 0, 0.32);
}

.wave-desk::before {
    content: "";
    position: absolute;
    left: -1rem;
    right: -1rem;
    top: -0.9rem;
    height: 1rem;
    border: 1px solid rgba(32, 246, 162, 0.24);
    background: linear-gradient(90deg, rgba(32, 246, 162, 0.24), rgba(66, 199, 255, 0.12));
}

.wave-desk span {
    position: absolute;
    left: 1rem;
    right: 1rem;
    top: 1.3rem;
    height: 0.4rem;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--accent), transparent);
    opacity: 0.65;
}

.wave-monitor {
    position: absolute;
    right: 13%;
    bottom: 8rem;
    z-index: 9;
    display: grid;
    gap: 0.45rem;
    width: 9.6rem;
    height: 6.3rem;
    border: 2px solid rgba(32, 246, 162, 0.72);
    border-radius: 0.45rem;
    padding: 1rem;
    background: #07100c;
    box-shadow: 0 0 32px rgba(32, 246, 162, 0.2);
}

.wave-monitor::after {
    content: "";
    position: absolute;
    left: 3.5rem;
    right: 3.5rem;
    bottom: -2rem;
    height: 2rem;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.06);
}

.wave-monitor i {
    display: block;
    height: 0.34rem;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--accent), transparent);
    animation: codeBlink 1.8s ease-in-out infinite;
}

.wave-monitor i:nth-child(2) {
    width: 72%;
    animation-delay: 0.25s;
}

.wave-monitor i:nth-child(3) {
    width: 48%;
    animation-delay: 0.5s;
}

.speech-bubble {
    position: absolute;
    left: 20%;
    top: 4.7rem;
    z-index: 10;
    border: 1px solid rgba(32, 246, 162, 0.55);
    border-radius: 0.8rem 0.8rem 0.8rem 0.2rem;
    padding: 0.65rem 0.85rem;
    background: rgba(5, 7, 6, 0.9);
    color: var(--accent);
    font-family: "JetBrains Mono", monospace;
    font-weight: 900;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.24);
    animation: bubbleTalk 3s ease-in-out infinite;
}

.desk-scene {
    position: relative;
    z-index: 2;
    display: block;
    width: 100%;
    height: auto;
    min-height: 23rem;
    margin-top: 3rem;
}

.scene-person-overlay {
    position: absolute;
    left: 13%;
    right: 8%;
    bottom: 6.8rem;
    z-index: 4;
    height: 16rem;
    pointer-events: none;
}

.overlay-head {
    position: absolute;
    left: 7.2rem;
    top: 1rem;
    width: 5.1rem;
    height: 5.1rem;
    border: 2px solid rgba(32, 246, 162, 0.78);
    border-radius: 50%;
    background:
        radial-gradient(circle at 35% 42%, #06100c 0 0.18rem, transparent 0.2rem),
        radial-gradient(circle at 65% 42%, #06100c 0 0.18rem, transparent 0.2rem),
        #f1fff9;
    box-shadow: 0 0 28px rgba(32, 246, 162, 0.22);
    animation: overlayHeadLoop 8s ease-in-out infinite;
}

.overlay-head::before {
    content: "z";
    position: absolute;
    top: -1.5rem;
    right: -0.8rem;
    color: var(--accent);
    font-family: "JetBrains Mono", monospace;
    font-weight: 900;
    opacity: 0;
    animation: overlaySleepNote 8s ease-in-out infinite;
}

.overlay-head::after {
    content: "";
    position: absolute;
    left: 1.7rem;
    bottom: 1.25rem;
    width: 1.4rem;
    height: 0.55rem;
    border-bottom: 3px solid #06100c;
    border-radius: 50%;
}

.overlay-body {
    position: absolute;
    left: 6.35rem;
    top: 6rem;
    width: 6.8rem;
    height: 8.5rem;
    border: 2px solid rgba(32, 246, 162, 0.58);
    border-radius: 2.2rem 2.2rem 0.7rem 0.7rem;
    background: linear-gradient(160deg, rgba(32, 246, 162, 0.42), rgba(66, 199, 255, 0.18));
}

.overlay-arm {
    position: absolute;
    top: 7.6rem;
    width: 5rem;
    height: 1rem;
    border-radius: 999px;
    background: #f1fff9;
    box-shadow: 0 0 14px rgba(241, 255, 249, 0.18);
    transform-origin: left center;
}

.overlay-left {
    left: 5.6rem;
    rotate: 18deg;
}

.overlay-right {
    left: 11rem;
    animation: overlayRightArmLoop 8s ease-in-out infinite;
}

.overlay-laptop {
    position: absolute;
    right: 2rem;
    bottom: 1.6rem;
    width: 8.6rem;
    height: 5.7rem;
    border: 2px solid rgba(32, 246, 162, 0.72);
    border-radius: 0.45rem;
    background:
        linear-gradient(90deg, var(--accent) 0 62%, transparent 62%) 1rem 1rem / 5.6rem 0.34rem no-repeat,
        linear-gradient(90deg, var(--accent-2) 0 48%, transparent 48%) 1rem 1.9rem / 5.2rem 0.34rem no-repeat,
        linear-gradient(90deg, var(--accent) 0 42%, transparent 42%) 1rem 2.8rem / 5.2rem 0.34rem no-repeat,
        #07100c;
    box-shadow: 0 0 32px rgba(32, 246, 162, 0.2);
}

.overlay-laptop::after {
    content: "";
    position: absolute;
    left: -1.5rem;
    right: -1.5rem;
    bottom: -1.2rem;
    height: 1.2rem;
    background: rgba(255, 255, 255, 0.08);
    transform: perspective(8rem) rotateX(45deg);
    transform-origin: top;
}

.overlay-cup {
    position: absolute;
    right: 0.25rem;
    bottom: 1.8rem;
    width: 2.2rem;
    height: 2.6rem;
    border: 2px solid rgba(173, 255, 210, 0.42);
    border-radius: 0 0 0.65rem 0.65rem;
    background: rgba(255, 255, 255, 0.1);
    animation: overlayCupLoop 8s ease-in-out infinite;
}

.overlay-cup::before,
.overlay-cup::after {
    content: "";
    position: absolute;
    top: -2rem;
    width: 0.22rem;
    height: 1.4rem;
    border-radius: 999px;
    background: rgba(238, 247, 242, 0.34);
    animation: steam 2.4s ease-in-out infinite;
}

.overlay-cup::before {
    left: 0.55rem;
}

.overlay-cup::after {
    left: 1.25rem;
    animation-delay: 0.45s;
}

.desk {
    position: absolute;
    left: 7%;
    right: 7%;
    bottom: 3.8rem;
    height: 0.9rem;
    border: 1px solid var(--line);
    background: linear-gradient(90deg, rgba(32, 246, 162, 0.18), rgba(66, 199, 255, 0.14));
}

.person {
    position: absolute;
    left: 13%;
    bottom: 4.6rem;
    width: 10rem;
    height: 13rem;
}

.person .head {
    position: absolute;
    top: 0.8rem;
    left: 3.3rem;
    width: 4.2rem;
    aspect-ratio: 1;
    border: 1px solid var(--line);
    border-radius: 45% 45% 52% 52%;
    background: #dff7ed;
    animation: headLoop 8s ease-in-out infinite;
}

.person .head::after {
    content: "";
    position: absolute;
    top: 2rem;
    right: 0.45rem;
    width: 0.42rem;
    height: 0.32rem;
    border-radius: 50%;
    background: rgba(5, 7, 6, 0.72);
    opacity: 0;
    animation: noseSignal 8s steps(1, end) infinite;
}

.person .head::before {
    content: "z";
    position: absolute;
    top: -1.2rem;
    right: -0.65rem;
    color: var(--accent);
    font-family: "JetBrains Mono", monospace;
    font-weight: 800;
    animation: sleepNote 8s ease-in-out infinite;
}

.person .body {
    position: absolute;
    left: 2.6rem;
    bottom: 0;
    width: 5.4rem;
    height: 8.2rem;
    border: 1px solid rgba(32, 246, 162, 0.32);
    border-radius: 2rem 2rem 0.5rem 0.5rem;
    background: linear-gradient(160deg, rgba(32, 246, 162, 0.22), rgba(66, 199, 255, 0.08));
}

.person .arm {
    position: absolute;
    top: 6.6rem;
    width: 4.2rem;
    height: 0.75rem;
    border-radius: 999px;
    background: #dff7ed;
    transform-origin: left center;
}

.person .arm.left {
    left: 1.2rem;
    rotate: 18deg;
}

.person .arm.right {
    left: 5.4rem;
    rotate: 10deg;
    animation: idleHandLoop 8s ease-in-out infinite;
}

.laptop {
    position: absolute;
    right: 12%;
    bottom: 4.7rem;
    width: 13rem;
}

.laptop .screen {
    display: grid;
    gap: 0.45rem;
    height: 8rem;
    border: 1px solid rgba(32, 246, 162, 0.34);
    padding: 1rem;
    background: #07100c;
    box-shadow: 0 0 42px rgba(32, 246, 162, 0.14);
}

.laptop .screen i {
    display: block;
    height: 0.5rem;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--accent), transparent);
    animation: codeBlink 1.8s ease-in-out infinite;
}

.laptop .screen i:nth-child(2) {
    width: 70%;
    animation-delay: 0.25s;
}

.laptop .screen i:nth-child(3) {
    width: 46%;
    animation-delay: 0.5s;
}

.laptop .keyboard {
    height: 1rem;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.06);
    transform: perspective(8rem) rotateX(44deg);
    transform-origin: top;
}

.cup {
    position: absolute;
    right: 8%;
    bottom: 5rem;
    width: 2.4rem;
    height: 2.7rem;
    border: 1px solid var(--line);
    border-radius: 0 0 0.7rem 0.7rem;
    background: rgba(255, 255, 255, 0.07);
    animation: cupLoop 8s ease-in-out infinite;
}

.cup span {
    position: absolute;
    bottom: 3rem;
    width: 0.28rem;
    height: 1.7rem;
    border-radius: 999px;
    background: rgba(238, 247, 242, 0.28);
    animation: steam 2.4s ease-in-out infinite;
}

.cup span:first-child {
    left: 0.65rem;
}

.cup span:last-child {
    left: 1.35rem;
    animation-delay: 0.45s;
}

.scene-caption {
    position: relative;
    z-index: 2;
    display: grid;
    gap: 0.3rem;
    border-top: 1px solid var(--line);
    padding-top: 1rem;
}

.scene-caption strong {
    color: var(--text);
}

.scene-caption small {
    color: var(--muted);
}

.home-metrics {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0;
    margin: 1rem 0 3rem;
    border-block: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.025);
}

.home-metrics span {
    display: grid;
    gap: 0.2rem;
    padding: 1.15rem;
    border-right: 1px solid var(--line);
}

.home-metrics span:last-child {
    border-right: 0;
}

.home-metrics strong {
    color: var(--text);
    font-size: clamp(1.4rem, 3vw, 2.2rem);
    line-height: 1;
}

.home-metrics small {
    color: var(--muted);
}

.section-head,
.site-footer {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 1rem;
}

.section-head {
    margin: 2rem 0 1rem;
}

.article-grid,
.tool-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

.article-card,
.tool-card,
.game-card,
.profile-card,
.dev-story {
    padding: 1.15rem;
}

.article-card,
.tool-card,
.game-card {
    min-height: 16rem;
    content-visibility: auto;
    contain-intrinsic-size: 16rem;
}

.article-card h2,
.tool-card h2 {
    margin-top: 0.6rem;
    font-size: 1.35rem;
    line-height: 1.18;
}

.article-card p,
.tool-card p,
.game-card small {
    color: var(--muted);
}

.card-meta {
    gap: 0.8rem;
    margin: 1rem 0;
}

.article-card a {
    color: var(--accent);
    font-weight: 800;
}

.showcase-band {
    grid-template-columns: 0.85fr 1.15fr;
    align-items: center;
    margin: 4rem 0;
    padding: clamp(1.25rem, 5vw, 3rem);
    border-block: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.035);
    translate: 0 var(--parallax-band-y, 0);
    will-change: translate;
    content-visibility: auto;
    contain-intrinsic-size: 24rem;
}

#pulseCanvas,
#gameCanvas {
    width: 100%;
    height: auto;
    display: block;
}

.page-title {
    padding: 4rem 0 2rem;
    content-visibility: auto;
    contain-intrinsic-size: 22rem;
}

.arcade,
.dev-story,
.about-layout,
.about-system,
.about-timeline,
.article-layout {
    content-visibility: auto;
    contain-intrinsic-size: 34rem;
}

.page-title h1 {
    max-width: none;
    font-size: clamp(3rem, 10vw, 7rem);
}

.search {
    width: min(100%, 42rem);
    min-height: 3.2rem;
    margin-top: 1rem;
    border: 1px solid var(--line);
    border-radius: 0.5rem;
    padding: 0 1rem;
    background: var(--panel);
    color: var(--text);
}

.chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
    margin-bottom: 1rem;
}

.chip {
    background: transparent;
    cursor: pointer;
}

.article-layout {
    grid-template-columns: 14rem minmax(0, 1fr);
    align-items: start;
    padding: 3rem 0;
}

.toc {
    position: sticky;
    top: 6rem;
    display: grid;
    gap: 0.55rem;
    color: var(--muted);
}

.toc a {
    font-size: 0.92rem;
}

.article-body {
    max-width: 760px;
}

.article-body h1 {
    max-width: 18ch;
    margin-bottom: 1rem;
    font-size: clamp(2.15rem, 5.8vw, 4.25rem);
    line-height: 1.02;
    overflow-wrap: anywhere;
}

.article-body h2,
.article-body h3 {
    margin-top: 2rem;
}

.article-body p,
.article-body li {
    color: #d8e5df;
}

.article-body .code-block {
    position: relative;
    overflow: hidden;
    margin: 1.25rem 0;
    border: 1px solid var(--line);
    border-radius: 0.45rem;
    background: #111820;
}

.article-body .code-copy {
    position: absolute;
    top: 0.55rem;
    right: 0.55rem;
    z-index: 2;
    display: grid;
    width: 2.05rem;
    height: 2.05rem;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 0.35rem;
    padding: 0;
    background: rgba(17, 24, 32, 0.9);
    color: var(--text);
    cursor: pointer;
}

.article-body .code-copy svg {
    width: 1rem;
    height: 1rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.4;
}

.article-body .copy-label {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.article-body .code-copy.is-copied {
    width: auto;
    padding: 0 0.55rem;
}

.article-body .code-copy.is-copied .copy-icon {
    display: none;
}

.article-body .code-copy.is-copied .copy-label {
    position: static;
    width: auto;
    height: auto;
    overflow: visible;
    clip: auto;
    font-size: 0.76rem;
}

.article-body pre {
    overflow: auto;
    margin: 0;
    padding: 1rem 3.8rem 1rem 1rem;
    background: #111820;
}

.article-body blockquote {
    margin: 1.2rem 0;
    border-left: 3px solid var(--accent);
    padding: 0.2rem 0 0.2rem 1rem;
    color: var(--muted);
}

.article-body .table-wrap {
    overflow-x: auto;
    margin: 1.25rem 0;
    border: 1px solid var(--line);
}

.article-body table {
    width: 100%;
    min-width: 34rem;
    border-collapse: collapse;
}

.article-body th,
.article-body td {
    padding: 0.72rem;
    border-bottom: 1px solid var(--line);
}

.article-body th {
    background: rgba(255, 255, 255, 0.06);
}

.article-body hr {
    border: 0;
    border-top: 1px solid var(--line);
    margin: 2rem 0;
}

.article-body mark {
    border-radius: 0.25rem;
    padding: 0.05rem 0.22rem;
    background: rgba(32, 246, 162, 0.2);
    color: var(--text);
}

.article-body .task-list {
    padding-left: 0;
    list-style: none;
}

.article-body .task-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.article-body .footnote {
    margin: 1rem 0;
    border-top: 1px solid var(--line);
    padding-top: 0.75rem;
    color: var(--muted);
    font-size: 0.92rem;
}

.article-body code {
    color: var(--accent);
    font-family: "JetBrains Mono", monospace;
}

.back-link {
    color: var(--accent);
}

.share-row {
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.article-author {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    margin: 0 0 1rem;
    color: var(--muted);
}

.article-author strong {
    color: var(--text);
}

.article-body figure {
    margin: 1.25rem auto;
}

.article-body img,
.article-body video {
    display: block;
    width: 100%;
    max-height: 36rem;
    border: 1px solid var(--line);
    object-fit: contain;
    background: #030504;
}

.article-body .media-size-small {
    max-width: 34%;
}

.article-body .media-size-medium {
    max-width: 58%;
}

.article-body .media-size-large {
    max-width: 78%;
}

.article-body .media-size-full {
    max-width: 100%;
}

.external-article-card {
    display: grid;
    gap: 1rem;
    margin: 2rem 0;
    border: 1px solid var(--line);
    padding: clamp(1rem, 4vw, 1.5rem);
    background: linear-gradient(145deg, rgba(32, 246, 162, 0.1), rgba(255, 255, 255, 0.03));
    box-shadow: var(--shadow);
}

.external-article-card h2 {
    max-width: 14ch;
}

.external-article-card p:not(.eyebrow) {
    color: var(--muted);
}

.external-article-card .btn {
    width: fit-content;
}

.medium-reader {
    max-height: 68rem;
    overflow: auto;
    border: 1px solid var(--line);
    padding: clamp(1rem, 4vw, 1.5rem);
    background: rgba(255, 255, 255, 0.035);
}

.medium-reader h1 {
    max-width: none;
    font-size: clamp(2rem, 6vw, 3.8rem);
}

.medium-reader img {
    max-height: 32rem;
}

.external-fallback {
    margin: 0;
    color: var(--muted);
    font-size: 0.95rem;
}

.comments {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--line);
}

.section-head.compact {
    margin: 0 0 1rem;
}

.section-head.compact h2 {
    font-size: clamp(1.6rem, 4vw, 2.5rem);
}

.comment-notice {
    border: 1px solid rgba(32, 246, 162, 0.3);
    padding: 0.75rem;
    background: rgba(32, 246, 162, 0.08);
    color: var(--accent);
}

.comment-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.comment-form label {
    display: grid;
    gap: 0.35rem;
    color: var(--muted);
}

.comment-form input,
.comment-form textarea {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 0.5rem;
    padding: 0.8rem;
    background: var(--panel);
    color: var(--text);
}

.comment-form .wide {
    grid-column: 1 / -1;
}

.hide-field {
    position: absolute;
    left: -9999px;
}

.comment-list {
    display: grid;
    gap: 0.75rem;
}

.comment-card {
    border: 1px solid var(--line);
    padding: 0.9rem;
    background: rgba(255, 255, 255, 0.04);
}

.comment-card small {
    display: block;
    color: var(--muted);
}

.arcade {
    grid-template-columns: 1fr;
    align-items: start;
    gap: 1rem;
}

.game-stage {
    position: relative;
    overflow: hidden;
}

.game-stage canvas {
    aspect-ratio: 900 / 520;
}

.game-hud {
    justify-content: space-between;
    padding: 0.8rem;
    border-top: 1px solid var(--line);
}

.game-list {
    display: grid;
    gap: 0.75rem;
}

.game-card {
    width: 100%;
    min-height: 9rem;
    border: 1px solid var(--line);
    background: var(--panel);
    color: var(--text);
    text-align: left;
    cursor: pointer;
}

.game-card strong,
.game-card small {
    display: block;
}

.game-card strong {
    margin: 0.25rem 0;
    font-size: 1.3rem;
}

.game-card.is-active {
    border-color: var(--accent);
}

.dev-story {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin: 1rem 0 4rem;
}

.dev-story > div {
    min-width: 0;
}

.dev-story .btn {
    flex: 0 0 auto;
}

.about-layout {
    grid-template-columns: minmax(0, 1.05fr) minmax(19rem, 0.95fr);
    min-height: calc(100vh - 9rem);
    align-items: center;
    padding: 4rem 0 2rem;
}

.about-hero {
    display: grid;
    gap: 1.15rem;
    translate: 0 var(--parallax-about-y, 0);
    animation: heroIn 760ms var(--ease-out) both;
    will-change: translate;
}

.about-hero h1 {
    max-width: 10.8ch;
    font-size: clamp(3rem, 9vw, 7.2rem);
}

.about-hero p {
    max-width: 42rem;
    color: var(--muted);
    font-size: clamp(1rem, 2vw, 1.15rem);
}

.about-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.75rem;
    margin-top: 0.5rem;
}

.about-stats span,
.about-timeline article,
.profile-card {
    border: 1px solid var(--line);
    background: linear-gradient(145deg, rgba(18, 26, 23, 0.86), rgba(8, 11, 10, 0.86));
    box-shadow: var(--shadow);
}

.about-stats span {
    display: grid;
    gap: 0.15rem;
    min-height: 5rem;
    padding: 0.9rem;
}

.about-stats strong {
    color: var(--text);
    line-height: 1.15;
}

.about-stats small,
.profile-card p,
.about-timeline p {
    color: var(--muted);
}

.profile-card {
    position: relative;
    display: grid;
    gap: 1rem;
    overflow: hidden;
    min-height: 31rem;
    padding: clamp(1rem, 4vw, 1.4rem);
    animation: heroIn 860ms 120ms var(--ease-out) both, floatPanel 6s ease-in-out infinite 1s;
}

.profile-card::before {
    content: "";
    position: absolute;
    inset: -30% auto auto 30%;
    width: 22rem;
    aspect-ratio: 1;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(32, 246, 162, 0.22), transparent 64%);
    pointer-events: none;
}

.architect-console {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(32, 246, 162, 0.26);
    background: rgba(5, 7, 6, 0.62);
    transform: translateY(var(--parallax-console-y, 0));
    will-change: transform;
}

.architect-console::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, transparent, rgba(32, 246, 162, 0.12), transparent);
    translate: -100% 0;
    animation: consoleSweep 5.4s ease-in-out infinite;
}

.console-top {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.75rem;
    border-bottom: 1px solid var(--line);
}

.console-top span {
    width: 0.62rem;
    height: 0.62rem;
    border-radius: 50%;
    background: var(--danger);
}

.console-top span:nth-child(2) {
    background: #ffd166;
}

.console-top span:nth-child(3) {
    background: var(--accent);
}

.console-top strong {
    margin-left: auto;
    color: var(--muted);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.78rem;
}

.console-body {
    position: relative;
    display: grid;
    gap: 0.9rem;
    padding: 1rem;
}

.console-body p {
    margin: 0;
    color: var(--muted);
    font-family: "JetBrains Mono", monospace;
}

.console-body p span {
    color: var(--accent);
}

.console-body > strong {
    font-size: clamp(1.2rem, 3vw, 1.55rem);
    line-height: 1.15;
}

.console-meter {
    display: grid;
    gap: 0.7rem;
}

.console-meter span {
    display: grid;
    gap: 0.34rem;
    color: var(--muted);
    font-size: 0.9rem;
}

.console-meter b {
    display: block;
    height: 0.48rem;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--accent), var(--accent-2));
    transform-origin: left;
    animation: barLoad 900ms var(--ease-out) both;
}

.profile-card h2 {
    position: relative;
    font-size: clamp(1.45rem, 3vw, 2rem);
}

.profile-card p,
.profile-links {
    position: relative;
}

.profile-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
}

.profile-links a {
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 0.5rem 0.75rem;
    color: var(--text);
    background: rgba(255, 255, 255, 0.05);
}

.about-system {
    display: grid;
    grid-template-columns: minmax(0, 0.74fr) minmax(0, 1.26fr);
    gap: clamp(1rem, 4vw, 3rem);
    align-items: start;
    margin: 1rem 0;
    padding: clamp(1.25rem, 4vw, 2rem) 0;
    border-block: 1px solid var(--line);
}

.about-system h2 {
    max-width: 14ch;
}

.stack-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
}

.stack-cloud span {
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 0.48rem 0.72rem;
    background: rgba(255, 255, 255, 0.04);
    color: var(--text);
}

.about-timeline {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    margin: 2rem 0 4rem;
}

.about-timeline article {
    display: grid;
    gap: 0.8rem;
    min-height: 15rem;
    padding: 1rem;
    transition: transform 220ms var(--ease-out), border-color 220ms var(--ease-out), box-shadow 220ms var(--ease-out);
}

.about-timeline article:hover {
    transform: translateY(-4px);
    border-color: rgba(32, 246, 162, 0.35);
    box-shadow: 0 30px 90px rgba(0, 0, 0, 0.46);
}

.about-timeline span {
    color: var(--accent);
    font-family: "JetBrains Mono", monospace;
    font-weight: 900;
}

.about-timeline h2 {
    font-size: 1.45rem;
}

.site-footer {
    position: relative;
    width: min(1160px, calc(100% - 2rem));
    margin: 4rem auto 0;
    padding: 1.5rem 0;
    border-top: 1px solid var(--line);
}

[data-mode="focus"] {
    --bg: #07090d;
    --panel: #10151d;
    --panel-2: #141c27;
    --accent: #42c7ff;
    --accent-2: #20f6a2;
}

[data-mode="focus"] .tagline::after {
    content: " Delivery-oriented, recruiter-safe, and aggressively documented.";
}

[hidden] {
    display: none !important;
}

.reveal {
    opacity: 0;
    transform: translateY(22px);
    transition: opacity 620ms var(--ease-out), transform 620ms var(--ease-out);
}

.reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal:nth-child(2) {
    transition-delay: 60ms;
}

.reveal:nth-child(3) {
    transition-delay: 120ms;
}

@keyframes heroIn {
    from {
        opacity: 0;
        transform: translateY(24px) scale(0.985);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes gridDrift {
    from {
        background-position: 0 0, 0 0;
    }
    to {
        background-position: 56px 56px, 56px 56px;
    }
}

@keyframes markPulse {
    0%,
    100% {
        box-shadow: 0 0 0 rgba(32, 246, 162, 0);
    }
    50% {
        box-shadow: 0 0 24px rgba(32, 246, 162, 0.22);
    }
}

@keyframes dotBreathe {
    0%,
    100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.18);
    }
}

@keyframes cursorBlink {
    0%,
    45% {
        opacity: 1;
    }
    46%,
    100% {
        opacity: 0;
    }
}

@keyframes ringGlow {
    0%,
    100% {
        filter: drop-shadow(0 0 0 rgba(32, 246, 162, 0));
    }
    50% {
        filter: drop-shadow(0 0 18px rgba(32, 246, 162, 0.25));
    }
}

@keyframes floatPanel {
    0%,
    100% {
        translate: 0 0;
    }
    50% {
        translate: 0 -8px;
    }
}

@keyframes consoleSweep {
    0%,
    52% {
        translate: -100% 0;
    }
    74%,
    100% {
        translate: 100% 0;
    }
}

@keyframes codeBlink {
    0%,
    100% {
        opacity: 0.45;
        transform: scaleX(0.72);
    }
    50% {
        opacity: 1;
        transform: scaleX(1);
    }
}

@keyframes steam {
    0% {
        opacity: 0;
        transform: translateY(0) scaleY(0.7);
    }
    45% {
        opacity: 0.75;
    }
    100% {
        opacity: 0;
        transform: translateY(-1.2rem) scaleY(1);
    }
}

@keyframes sleepNote {
    0%,
    49%,
    75%,
    100% {
        opacity: 0;
        transform: translateY(0);
    }
    56%,
    68% {
        opacity: 1;
        transform: translateY(-0.7rem);
    }
}

@keyframes sleepySun {
    0%,
    100% {
        transform: translateY(0) scale(1);
    }
    50% {
        transform: translateY(0.45rem) scale(0.94);
    }
}

@keyframes personBreathe {
    0%,
    100% {
        transform: translateX(-50%) translateY(0);
    }
    50% {
        transform: translateX(-50%) translateY(0.35rem);
    }
}

@keyframes waveHand {
    0%,
    100% {
        rotate: -55deg;
    }
    45% {
        rotate: -82deg;
    }
}

@keyframes bubbleTalk {
    0%,
    100% {
        transform: translateY(0) scale(1);
        opacity: 0.82;
    }
    50% {
        transform: translateY(-0.25rem) scale(1.04);
        opacity: 1;
    }
}

@keyframes headLoop {
    0%,
    24%,
    75%,
    100% {
        translate: 0 0;
        rotate: 0deg;
    }
    31%,
    43% {
        translate: 0 0.05rem;
        rotate: -7deg;
    }
    54%,
    68% {
        translate: 0 0.45rem;
        rotate: -12deg;
    }
    82%,
    92% {
        translate: 0 -0.08rem;
        rotate: 4deg;
    }
}

@keyframes idleHandLoop {
    0%,
    12%,
    24% {
        translate: 0 0;
        rotate: 10deg;
    }
    6%,
    18% {
        translate: 0.15rem 0.05rem;
        rotate: -5deg;
    }
    31%,
    43% {
        translate: -2.1rem -4.2rem;
        rotate: -58deg;
    }
    52%,
    68% {
        translate: -1.3rem -1.2rem;
        rotate: -18deg;
    }
    79%,
    92% {
        translate: 3.2rem -3.8rem;
        rotate: -72deg;
    }
    100% {
        translate: 0 0;
        rotate: 10deg;
    }
}

@keyframes noseSignal {
    0%,
    24%,
    49%,
    100% {
        opacity: 0;
    }
    31%,
    43% {
        opacity: 1;
    }
}

@keyframes cupLoop {
    0%,
    74%,
    100% {
        translate: 0 0;
        rotate: 0deg;
    }
    82%,
    92% {
        translate: -2.4rem -2.6rem;
        rotate: -10deg;
    }
}

@keyframes overlayHeadLoop {
    0%,
    24%,
    75%,
    100% {
        translate: 0 0;
        rotate: 0deg;
    }
    31%,
    43% {
        translate: 0.1rem 0.05rem;
        rotate: -7deg;
    }
    54%,
    68% {
        translate: -0.15rem 0.8rem;
        rotate: -12deg;
    }
    82%,
    92% {
        translate: 0 -0.12rem;
        rotate: 4deg;
    }
}

@keyframes overlayRightArmLoop {
    0%,
    12%,
    24% {
        translate: 0 0;
        rotate: 10deg;
    }
    6%,
    18% {
        translate: 0.2rem 0.08rem;
        rotate: -7deg;
    }
    31%,
    43% {
        translate: -3.4rem -4.7rem;
        rotate: -62deg;
    }
    52%,
    68% {
        translate: -1.1rem -1.5rem;
        rotate: -20deg;
    }
    79%,
    92% {
        translate: 4.6rem -3.3rem;
        rotate: -68deg;
    }
    100% {
        translate: 0 0;
        rotate: 10deg;
    }
}

@keyframes overlayCupLoop {
    0%,
    74%,
    100% {
        translate: 0 0;
        rotate: 0deg;
    }
    82%,
    92% {
        translate: -4.2rem -3.4rem;
        rotate: -12deg;
    }
}

@keyframes overlaySleepNote {
    0%,
    49%,
    75%,
    100% {
        opacity: 0;
        transform: translateY(0);
    }
    56%,
    68% {
        opacity: 1;
        transform: translateY(-0.9rem);
    }
}

@keyframes modeCoding {
    0%,
    24% {
        color: var(--accent);
        border-color: rgba(32, 246, 162, 0.5);
        background: rgba(32, 246, 162, 0.12);
    }
    25%,
    100% {
        color: var(--muted);
        border-color: var(--line);
        background: rgba(255, 255, 255, 0.045);
    }
}

@keyframes modeNgupil {
    0%,
    24%,
    50%,
    100% {
        color: var(--muted);
        border-color: var(--line);
        background: rgba(255, 255, 255, 0.045);
    }
    25%,
    49% {
        color: var(--accent);
        border-color: rgba(32, 246, 162, 0.5);
        background: rgba(32, 246, 162, 0.12);
    }
}

@keyframes modeTidur {
    0%,
    49%,
    75%,
    100% {
        color: var(--muted);
        border-color: var(--line);
        background: rgba(255, 255, 255, 0.045);
    }
    50%,
    74% {
        color: var(--accent);
        border-color: rgba(32, 246, 162, 0.5);
        background: rgba(32, 246, 162, 0.12);
    }
}

@keyframes modeNgopi {
    0%,
    74%,
    100% {
        color: var(--muted);
        border-color: var(--line);
        background: rgba(255, 255, 255, 0.045);
    }
    75%,
    99% {
        color: var(--accent);
        border-color: rgba(32, 246, 162, 0.5);
        background: rgba(32, 246, 162, 0.12);
    }
}

@keyframes barLoad {
    from {
        transform: scaleX(0.12);
    }
    to {
        transform: scaleX(1);
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
        transition-duration: 0.001ms !important;
    }

    .reveal {
        opacity: 1;
        transform: none;
    }

    .wave-person {
        animation: none !important;
        transform: translateX(-50%) translateY(0);
    }

    .wave-arm.right {
        animation: none !important;
        rotate: -55deg;
    }
}

@media (max-width: 920px) {
    body.menu-open {
        overflow: hidden;
    }

    .site-header {
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 0.65rem;
    }

    .menu-toggle {
        display: grid;
    }

    .desktop-mode-toggle,
    .site-header > .admin-login,
    .site-header > .admin-chip,
    .site-header > .lang-switch {
        display: none;
    }

    .nav {
        position: fixed;
        inset: 4.9rem 1rem auto;
        display: grid;
        justify-content: stretch;
        gap: 0.55rem;
        padding: 0.75rem;
        border: 1px solid var(--line);
        background: rgba(13, 18, 16, 0.98);
        box-shadow: var(--shadow);
        transform: translateY(-0.8rem);
        opacity: 0;
        pointer-events: none;
        transition: opacity 160ms ease, transform 160ms ease;
    }

    .nav.is-open {
        transform: translateY(0);
        opacity: 1;
        pointer-events: auto;
    }

    .mobile-nav-tools {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: center;
        gap: 0.55rem;
        margin-top: 0.15rem;
    }

    .nav > a,
    .mobile-mode-toggle {
        width: 100%;
        min-height: 2.9rem;
        justify-content: flex-start;
        border-radius: 0.5rem;
        padding-inline: 0.85rem;
        font-size: 0.95rem;
    }

    .mobile-mode-toggle {
        display: flex;
        margin-top: 0.25rem;
    }

    .hero,
    .showcase-band,
    .arcade,
    .about-layout,
    .about-system,
    .article-layout {
        grid-template-columns: 1fr;
    }

    .about-layout {
        min-height: auto;
        padding-top: 3rem;
    }

    .hero-illustration {
        display: none;
    }

    .about-hero h1 {
        max-width: 12ch;
    }

    .about-timeline {
        grid-template-columns: 1fr;
    }

    .about-timeline article {
        min-height: auto;
    }

    .toc {
        position: static;
        display: flex;
        flex-wrap: wrap;
    }

    .article-grid,
    .tool-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .home-metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .home-metrics span:nth-child(2) {
        border-right: 0;
    }

    .home-metrics span:nth-child(-n + 2) {
        border-bottom: 1px solid var(--line);
    }

    .dev-story {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media (max-width: 640px) {
    main,
    .site-footer {
        width: min(100% - 1rem, 1160px);
    }

    .site-header {
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 0.45rem;
        padding-inline: 0.5rem;
    }

    .brand {
        min-width: 0;
    }

    .brand-mark {
        width: 2.35rem;
        height: 2.35rem;
    }

    .brand strong {
        display: block;
        overflow: hidden;
        max-width: 9.5rem;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .menu-toggle {
        width: auto;
        min-width: 2.65rem;
        min-height: 2.65rem;
    }

    .nav {
        inset-inline: 0.5rem;
    }

    .mobile-nav-tools {
        grid-template-columns: 1fr;
    }

    .mobile-lang-switch {
        width: 100%;
    }

    .mobile-lang-switch a {
        flex: 1 1 50%;
    }

    .hero {
        min-height: auto;
        padding-top: 2rem;
    }

    h1 {
        font-size: clamp(3rem, 18vw, 5rem);
    }

    .article-body h1 {
        max-width: none;
        font-size: clamp(2rem, 11vw, 3.1rem);
    }

    .article-grid,
    .tool-grid,
    .about-stats,
    .home-metrics,
    .comment-form {
        grid-template-columns: 1fr;
    }

    .home-metrics span,
    .home-metrics span:nth-child(2),
    .home-metrics span:nth-child(-n + 2) {
        border-right: 0;
        border-bottom: 1px solid var(--line);
    }

    .home-metrics span:last-child {
        border-bottom: 0;
    }

    .profile-card {
        min-height: auto;
    }

    .article-card,
    .tool-card {
        min-height: auto;
    }

    .section-head,
    .site-footer {
        align-items: flex-start;
        flex-direction: column;
    }
}
