/* ── Entrance animations ──────────────────────────────────────────────── */
/* Elements tagged [data-pw-animate] start invisible; anime.js reveals them.
   The :not([data-pw-done]) guard ensures re-navigating to a page re-animates
   fresh elements while leaving already-played ones untouched. */
[data-pw-animate]:not([data-pw-done]) {
    opacity: 0;
    transform: translateY(18px);
}

/* ── Tokens (dark interior + sage scene) ─────────────────────────────── */
:root {
    --pw-bg: #07090f;
    --pw-bg-alt: #0d111a;
    --pw-text: #e7eaf0;
    --pw-muted: #8a93a5;
    --pw-border: #1f2533;
    --pw-card: #11151f;
    --pw-card-elev: #161c27;
    --pw-accent: #4d8cff;
    --pw-accent-2: #00d4f5;
    --pw-shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 12px 32px rgba(0, 0, 0, 0.45);

    /* Scene (outside the laptop) */
    --scene-bg:        #4a5d4a;
    --scene-bg-deep:   #3a4d3a;
    --scene-ink:       #f5f0e6;
    --scene-ink-muted: #c5c5b5;

    /* Laptop chassis */
    --laptop-bezel:    #8b7355;
    --laptop-base:     #6b5b45;
    --laptop-keys:     #2a2a2a;
    --laptop-key-cap:  #1a1a1a;

    /* Browser chrome (cream) */
    --chrome-bg:       #e8e3d5;
    --chrome-bg-light: #f5f0e6;
    --chrome-border:   #d5d0c2;
    --chrome-ink:      #5a5a4a;
    --chrome-ink-muted:#9a9a8a;
}

html, body {
    font-family: 'Inter', 'Segoe UI', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    color: var(--pw-text);
    background-color: var(--pw-bg);
}

body {
    background: var(--pw-bg);
    min-height: 100vh;
}

/* ── Site shell (replaces the laptop scene) ───────────────────────────── */
.site-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: var(--pw-bg);
}

.site-main {
    flex: 1;
}

.site-footer {
    border-top: 1px solid var(--pw-border);
    background: var(--pw-bg);
}

/* The browser-chrome tabs were originally cream-on-cream for the laptop scene.
   On a dark site shell they need a dark variant. */
.browser-chrome {
    background: #0a0d14;
    border-bottom: 1px solid var(--pw-border);
    --chrome-bg: #0a0d14;
    --chrome-bg-light: #11151f;
    --chrome-border: #1f2533;
    --chrome-ink: #cfd5e0;
    --chrome-ink-muted: #6c7484;
}
.browser-titlebar { background: #0a0d14; }
.browser-tab {
    background: #11151f;
    color: #8a93a5;
    border-color: transparent;
}
.browser-tab:hover {
    background: #161c27;
    color: #cfd5e0;
}
.browser-tab.is-active {
    background: var(--pw-bg);
    color: var(--pw-accent);
    border-color: var(--pw-border);
}
.browser-tab.is-active::after { background: var(--pw-bg); }
.browser-urlbar { background: #0a0d14; border-top-color: var(--pw-border); color: var(--chrome-ink); }
.urlbar-input { background: #11151f; border-color: var(--pw-border); }

a, .btn-link {
    color: var(--pw-accent);
    text-decoration: none;
}

a:hover, .btn-link:hover {
    color: #7aa9ff;
    text-decoration: underline;
}

.btn-primary {
    color: #fff;
    background-color: var(--pw-accent);
    border-color: var(--pw-accent);
}

.btn-primary:hover, .btn-primary:focus {
    background-color: #3a76f0;
    border-color: #3a76f0;
}

.btn-outline-secondary {
    color: var(--pw-text);
    border-color: var(--pw-border);
    background: transparent;
}

.btn-outline-secondary:hover, .btn-outline-secondary:focus {
    color: var(--pw-text);
    background-color: var(--pw-card-elev);
    border-color: var(--pw-border);
}

.btn:focus, .btn:active:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.15rem rgba(77, 140, 255, 0.35);
}

/* Override Bootstrap defaults for dark surface */
.text-muted, .small.text-muted {
    color: var(--pw-muted) !important;
}

.form-control, .form-select {
    background-color: var(--pw-card);
    color: var(--pw-text);
    border-color: var(--pw-border);
}

.form-control:focus, .form-select:focus {
    background-color: var(--pw-card);
    color: var(--pw-text);
    border-color: var(--pw-accent);
}

.form-control::placeholder {
    color: var(--pw-muted);
    opacity: 1;
}

.form-label {
    color: var(--pw-text);
    font-weight: 500;
}

.badge.bg-light {
    background-color: var(--pw-card-elev) !important;
    color: var(--pw-muted) !important;
    border: 1px solid var(--pw-border) !important;
}

/* ╔══════════════════════════════════════════════════════════════════════╗
   ║  Home v2 — dark studio with soft aurora glows + scroll-stack         ║
   ╚══════════════════════════════════════════════════════════════════════╝ */

.home-shell {
    position: relative;
    overflow-x: clip;
}

/* Aurora — fixed-position blurred blobs that drift in the background. */
.aurora {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.aurora-blob {
    position: absolute;
    width: 60vw;
    height: 60vw;
    max-width: 900px;
    max-height: 900px;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.32;
    will-change: transform;
}

.aurora-1 {
    background: radial-gradient(circle at 30% 30%, #4d8cff 0%, transparent 60%);
    top: -15vw;
    left: -10vw;
    animation: aurora-drift-1 28s ease-in-out infinite alternate;
}

.aurora-2 {
    background: radial-gradient(circle at 60% 60%, #00d4f5 0%, transparent 65%);
    bottom: -20vw;
    right: -10vw;
    opacity: 0.22;
    animation: aurora-drift-2 34s ease-in-out infinite alternate;
}

.aurora-3 {
    background: radial-gradient(circle at 50% 50%, #c084fc 0%, transparent 65%);
    top: 40%;
    left: 35%;
    width: 35vw;
    height: 35vw;
    opacity: 0.18;
    animation: aurora-drift-3 24s ease-in-out infinite alternate;
}

@keyframes aurora-drift-1 {
    from { transform: translate3d(0, 0, 0); }
    to   { transform: translate3d(8vw, 6vw, 0); }
}
@keyframes aurora-drift-2 {
    from { transform: translate3d(0, 0, 0); }
    to   { transform: translate3d(-10vw, -4vw, 0); }
}
@keyframes aurora-drift-3 {
    from { transform: translate3d(0, 0, 0); }
    to   { transform: translate3d(-5vw, 4vw, 0); }
}

/* All home content sits above the aurora. */
.home-shell > section,
.home-shell > div { position: relative; z-index: 1; }

/* draw-words: the h1 container stays visible; individual .pw-word spans are
   the animated units and start at opacity:0 set by JS before the stagger. */
[data-pw-animate="draw-words"]:not([data-pw-done]) {
    opacity: 1;
    transform: none;
}
.pw-word { display: inline; }

/* ── typewriter ───────────────────────────────────────────────────────────
   The heading types out char-by-char. Until JS splits it into .pw-char spans
   the whole element is hidden (visibility, so it still reserves layout) to
   avoid a flash of the full text. Once split, chars start at opacity:0 and are
   revealed in reading order. They keep their box (no reflow) the whole time. */
[data-pw-animate="typewriter"]:not([data-pw-done]) {
    opacity: 1;
    transform: none;
}
.hero-v2-title.pw-typing { visibility: hidden; }

.pw-char { opacity: 0; }
.pw-char.pw-space { white-space: pre-wrap; }
.pw-char.is-typed {
    opacity: 1;
    transition: opacity 70ms linear;
}

/* Zero-width inline anchor; the visible bar is drawn by ::after so inserting
   the caret between chars never nudges the layout. */
.pw-caret {
    display: inline-block;
    position: relative;
    width: 0;
}
.pw-caret::after {
    content: "";
    position: absolute;
    left: 0;
    /* The caret's box is empty, so it sits on the text baseline; draw the bar
       upward from there so it spans the letters instead of dropping below. */
    top: -0.74em;
    height: 0.78em;
    width: 0.055em;
    border-radius: 1px;
    background: var(--pw-accent);
    animation: pw-caret-blink 1.05s steps(1, end) infinite;
}
.pw-caret-hide::after {
    animation: none;
    opacity: 0;
    transition: opacity 0.45s ease;
}
@keyframes pw-caret-blink {
    0%, 49%   { opacity: 1; }
    50%, 100% { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
    .pw-char { opacity: 1; transition: none; }
    .pw-caret::after { animation: none; opacity: 0; }
}

/* ── CRT "power-on" intro ──────────────────────────────────────────────────
   A one-time, full-viewport overlay that "opens" the page in stages:
     1. a spark ignites at dead centre,
     2. a glowing beam draws out to the LEFT/RIGHT edges,
     3. the beam expands out to the TOP/BOTTOM edges, filling the screen,
     4. the screen flickers ("something happens"),
     5. the bright field fades away to reveal the loaded page.
   The overlay is created/removed by animations.js (powerOnIntro). Timings are
   percentages of one shared 1.6s clock so the stages stay in lock-step. */
.pw-crt {
    position: fixed;
    inset: 0;
    z-index: 9999;
    pointer-events: none;
    overflow: hidden;
    background: var(--pw-bg, #07090f); /* the "off" screen */
    animation: pw-crt-out 1.6s ease-out forwards;
}

.pw-crt-beam {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 0;
    height: 2px;
    border-radius: 3px;
    background: linear-gradient(90deg,
        transparent 0%, rgba(180, 205, 255, 0.6) 5%, #c4d8ff 50%, rgba(180, 205, 255, 0.6) 95%, transparent 100%);
    box-shadow: 0 0 14px 2px rgba(77, 140, 255, 0.75),
                0 0 48px 10px rgba(77, 140, 255, 0.4);
    animation: pw-crt-beam 1.6s cubic-bezier(0.76, 0, 0.24, 1) forwards;
}

/* Stage 2 → 3: grow to the side edges, then to the top/bottom edges. The thin
   line draws bright, but the beam dims as it fills the screen so the full-screen
   moment is a soft blue glow rather than a harsh white flash. */
@keyframes pw-crt-beam {
    0%   { width: 0;     height: 2px;     opacity: 0; }
    6%   { width: 0;     height: 2px;     opacity: 1; }    /* spark */
    34%  { width: 100vw; height: 2px;     opacity: 1; }    /* → side edges */
    44%  { width: 100vw; height: 2px;     opacity: 0.9; }  /* brief hold */
    70%  { width: 100vw; height: 100vh;   opacity: 0.32; } /* → top/bottom, softened */
    100% { width: 100vw; height: 100vh;   opacity: 0.28; }
}

/* Stage 4 → 5: hold, flicker, then fade the whole overlay out to show the page. */
@keyframes pw-crt-out {
    0%, 72% { opacity: 1; }
    76%     { opacity: 0.78; }   /* flicker */
    80%     { opacity: 1; }
    85%     { opacity: 0.88; }   /* flicker */
    88%     { opacity: 1; }
    100%    { opacity: 0; }      /* reveal */
}

/* ── Hero v2 ──────────────────────────────────────────────────────────── */
.hero-v2 {
    min-height: 72vh;
    padding: 8rem 0 5rem;
    display: flex;
    align-items: center;
}

/* ── Hero profile card ────────────────────────────────────────────────── */
.hero-profile-card {
    background: var(--pw-card);
    border: 1px solid var(--pw-border);
    border-radius: 1.25rem;
    padding: 2rem 1.75rem 1.75rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.25rem;
    box-shadow: var(--pw-shadow);
}

.hero-profile-img {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--pw-border);
    box-shadow: 0 0 0 4px rgba(77, 140, 255, 0.18);
}

.hero-profile-placeholder {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    background: var(--pw-card-elev);
    border: 2px dashed var(--pw-border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: var(--pw-muted);
}

.hero-profile-bullets {
    list-style: none;
    padding: 0;
    margin: 0;
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.hero-profile-bullets li {
    font-size: 0.92rem;
    color: var(--pw-muted);
    padding-left: 1.25rem;
    position: relative;
    line-height: 1.45;
}

.hero-profile-bullets li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.5em;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--pw-accent), var(--pw-accent-2));
}

.hero-v2-eyebrow {
    color: var(--pw-accent-2);
    text-transform: uppercase;
    letter-spacing: 0.18em;
    font-size: 0.78rem;
    font-weight: 600;
    margin: 0 0 1.5rem;
    opacity: 0.85;
}

.hero-v2-title {
    font-size: clamp(2.5rem, 6vw, 5rem);
    font-weight: 700;
    line-height: 1.05;
    letter-spacing: -0.025em;
    margin: 0 0 1.5rem;
    max-width: 26ch;
    overflow-wrap: break-word;
}

.hero-v2-accent {
    font-style: italic;
    font-weight: 700;
    background: linear-gradient(120deg, var(--pw-accent) 0%, var(--pw-accent-2) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-v2-actions {
    margin-top: 2.25rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
}

/* ── Highlights strip ─────────────────────────────────────────────────── */
.highlights-strip {
    padding: 2rem 0 4.5rem;
}

.highlights-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.1rem;
}

.highlight-pod {
    --pod-1: #4d8cff;
    --pod-2: #38bdf8;
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 0.95rem;
    padding: 1.35rem 1.3rem;
    background: linear-gradient(165deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.012));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 1rem;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    overflow: hidden;
    isolation: isolate;
    transition: transform 260ms cubic-bezier(0.4, 0, 0.2, 1),
                border-color 260ms ease,
                box-shadow 260ms ease;
}

/* Ambient colour glow bleeding out from behind the icon. */
.highlight-pod::before {
    content: "";
    position: absolute;
    z-index: -1;
    top: -40%;
    left: -20%;
    width: 60%;
    height: 130%;
    background: radial-gradient(closest-side, var(--pod-1), transparent);
    opacity: 0.13;
    filter: blur(18px);
    transition: opacity 260ms ease;
}

/* Gradient hairline that sweeps across the top edge on hover. */
.highlight-pod::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--pod-1), var(--pod-2), transparent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 380ms cubic-bezier(0.4, 0, 0.2, 1);
}

.highlight-pod:hover {
    transform: translateY(-5px);
    border-color: color-mix(in srgb, var(--pod-1) 55%, transparent);
    box-shadow: 0 14px 32px -16px var(--pod-1),
                0 6px 16px -10px rgba(0, 0, 0, 0.6);
}
.highlight-pod:hover::before { opacity: 0.3; }
.highlight-pod:hover::after  { transform: scaleX(1); }

/* While being dragged: we drive transform directly from JS, so kill the CSS
   transition (otherwise it lags the cursor) and raise the card above its peers. */
.highlight-pod.pw-grabbed {
    transition: none;
    cursor: grabbing;
    user-select: none;
    z-index: 5;
    box-shadow: 0 24px 48px -18px var(--pod-1),
                0 12px 24px -12px rgba(0, 0, 0, 0.7);
}
.highlight-pod.pw-grabbed::before { opacity: 0.35; }

/* Distinct cool-spectrum accent per pod. */
.highlight-pod:nth-child(1) { --pod-1: #4d8cff; --pod-2: #38bdf8; } /* blue → sky   */
.highlight-pod:nth-child(2) { --pod-1: #a855f7; --pod-2: #6366f1; } /* violet → indigo */
.highlight-pod:nth-child(3) { --pod-1: #22d3ee; --pod-2: #2dd4bf; } /* cyan → teal  */
.highlight-pod:nth-child(4) { --pod-1: #34d399; --pod-2: #22d3ee; } /* emerald → cyan */

.hp-icon {
    width: 2.7rem;
    height: 2.7rem;
    flex-shrink: 0;
    border-radius: 0.7rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--pod-2) 0%, var(--pod-1) 100%);
    color: #07090f;
    font-size: 1.2rem;
    box-shadow: 0 6px 18px -6px var(--pod-1),
                inset 0 1px 0 rgba(255, 255, 255, 0.35);
    transition: transform 260ms cubic-bezier(0.34, 1.56, 0.64, 1),
                box-shadow 260ms ease;
}
.highlight-pod:hover .hp-icon {
    transform: scale(1.08) rotate(-3deg);
    box-shadow: 0 10px 26px -6px var(--pod-1),
                inset 0 1px 0 rgba(255, 255, 255, 0.45);
}

.hp-title {
    color: var(--pw-text);
    font-weight: 600;
    font-size: 0.96rem;
    line-height: 1.25;
    letter-spacing: -0.01em;
}

.hp-desc {
    color: var(--pw-muted);
    font-size: 0.83rem;
    line-height: 1.5;
    margin-top: 0.3rem;
}

/* ── Stack header (intro for the scroll-stack) ────────────────────────── */
.stack-header {
    padding: 4rem 0 2rem;
}

.stack-header-lede {
    color: var(--pw-muted);
    margin-top: 0.5rem;
    font-size: 0.95rem;
}

/* ── Scroll-stacked project cards ─────────────────────────────────────── */
/* Each .stack-card is position: sticky at top: 0 with min-height: 100vh.
   Later siblings in the DOM paint on top, so they "stack" visually as you scroll. */

.project-stack {
    position: relative;
    z-index: 1;
}

.stack-card {
    position: sticky;
    top: 0;
    min-height: 78vh;
    display: flex;
    align-items: center;
    padding: 1.5rem 0;
    overflow: hidden;
    background: var(--pw-bg);
    border-top: 1px solid var(--pw-border);
}

/* Each card gets a different colored glow keyed off --glow-hue. */
.stack-card-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
}

.stack-glow {
    position: absolute;
    width: 65vw;
    height: 65vw;
    max-width: 1000px;
    max-height: 1000px;
    border-radius: 50%;
    top: 50%;
    left: 30%;
    transform: translate(-50%, -50%);
    background: radial-gradient(
        circle at center,
        hsla(var(--glow-hue, 220), 80%, 60%, 0.30) 0%,
        hsla(var(--glow-hue, 220), 80%, 60%, 0.12) 30%,
        transparent 65%
    );
    filter: blur(60px);
}

.stack-card-inner {
    position: relative;
    z-index: 1;
    width: 100%;
}

.stack-media-col {
    display: flex;
    justify-content: center;
}

.stack-icon-wrap {
    position: relative;
    width: clamp(180px, 22vw, 300px);
    aspect-ratio: 1 / 1;
    border-radius: 1.25rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.01) 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow:
        0 30px 80px rgba(0, 0, 0, 0.55),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
}

.stack-icon {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.stack-icon-placeholder {
    color: var(--pw-muted);
    font-size: 4rem;
    opacity: 0.4;
}

.stack-text-col {
    color: var(--pw-text);
}

.stack-index {
    font-family: 'JetBrains Mono', 'Fira Code', Consolas, monospace;
    color: var(--pw-accent-2);
    font-size: 0.8rem;
    letter-spacing: 0.15em;
    margin: 0 0 1rem;
    opacity: 0.7;
}

.stack-title {
    font-size: clamp(2.25rem, 5vw, 4rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.05;
    margin: 0 0 0.85rem;
    color: var(--pw-text);
}

.stack-meta {
    color: var(--pw-muted);
    font-size: 0.95rem;
    margin-bottom: 1.4rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
    align-items: center;
}

.stack-dot { opacity: 0.5; }

.stack-desc {
    font-size: 1.1rem;
    line-height: 1.55;
    color: var(--pw-text);
    opacity: 0.92;
    max-width: 36rem;
    margin: 0 0 1.5rem;
}

.stack-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1.5rem;
    color: var(--pw-accent);
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    transition: gap 150ms ease;
}

.stack-link:hover {
    color: #7aa9ff;
    gap: 0.85rem;
    text-decoration: none;
}

/* ── Timeline section (under the stack) ───────────────────────────────── */
.timeline-section {
    padding: 6rem 0 4rem;
    background: linear-gradient(180deg, var(--pw-bg) 0%, var(--pw-bg-alt) 100%);
    border-top: 1px solid var(--pw-border);
}

/* ── Mobile fallback: stop being sticky on small screens ──────────────── */
@media (max-width: 768px) {
    .stack-card {
        position: relative;
        min-height: auto;
        padding: 4rem 0;
    }
    .stack-media-col {
        margin-bottom: 1.5rem;
    }
    .hero-v2 {
        padding: 5rem 0 3rem;
        min-height: auto;
    }
    .hero-profile-card {
        max-width: 320px;
        margin: 0 auto 2rem;
    }
}

/* ╔══════════════════════════════════════════════════════════════════════╗
   ║  Projects list + Detail (dark studio vibe)                           ║
   ╚══════════════════════════════════════════════════════════════════════╝ */

.page-shell {
    position: relative;
    overflow-x: clip;
    min-height: calc(100vh - 4rem);
}

/* A quieter aurora for inner pages — fewer blobs, lower opacity. */
.aurora-quiet .aurora-blob {
    opacity: 0.18;
}

.page-shell > section,
.page-shell > div { position: relative; z-index: 1; }

/* Inner-page hero */
.page-hero {
    padding: 5rem 0 2.5rem;
}

.page-hero-title {
    font-size: clamp(2.25rem, 4.5vw, 3.75rem);
    font-weight: 700;
    line-height: 1.05;
    letter-spacing: -0.025em;
    color: var(--pw-text);
    margin: 0 0 0.6rem;
}

.page-hero-lede {
    color: var(--pw-muted);
    font-size: 1.1rem;
    max-width: 42rem;
    margin: 0;
}

/* Search input with icon prefix */
.search-wrap {
    position: relative;
    flex: 1;
    max-width: 26rem;
}

.search-icon {
    position: absolute;
    left: 0.85rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--pw-muted);
    pointer-events: none;
    font-size: 0.95rem;
}

.project-search {
    padding-left: 2.2rem;
    background: rgba(255, 255, 255, 0.025);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--pw-text);
    border-radius: 999px;
}

.project-search:focus {
    background: rgba(77, 140, 255, 0.06);
    border-color: var(--pw-accent);
    color: var(--pw-text);
    box-shadow: 0 0 0 0.15rem rgba(77, 140, 255, 0.18);
}

/* Project grid */
.proj-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.25rem;
}

.proj-tile {
    display: flex;
    flex-direction: column;
    color: inherit;
    text-decoration: none;
    background: rgba(255, 255, 255, 0.025);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 1rem;
    overflow: hidden;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transition: transform 220ms ease, border-color 220ms ease, box-shadow 220ms ease;
}

.proj-tile:hover {
    transform: translateY(-3px);
    border-color: rgba(77, 140, 255, 0.45);
    box-shadow: 0 18px 40px rgba(77, 140, 255, 0.12), 0 4px 14px rgba(0, 0, 0, 0.35);
    color: inherit;
    text-decoration: none;
}

.proj-tile-media {
    position: relative;
    aspect-ratio: 16 / 9;
    background:
        radial-gradient(circle at 30% 40%, rgba(77, 140, 255, 0.18) 0%, transparent 55%),
        radial-gradient(circle at 70% 60%, rgba(0, 212, 245, 0.12) 0%, transparent 55%),
        #0a0d14;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.proj-tile-media img {
    max-width: 60%;
    max-height: 70%;
    object-fit: contain;
}

.proj-tile-placeholder {
    color: var(--pw-muted);
    font-size: 2.5rem;
    opacity: 0.5;
}

.proj-tile-year {
    position: absolute;
    top: 0.65rem;
    right: 0.65rem;
    background: rgba(7, 9, 15, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    padding: 0.15rem 0.6rem;
    font-size: 0.7rem;
    color: var(--pw-text);
    font-family: 'JetBrains Mono', 'Fira Code', Consolas, monospace;
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

.proj-tile-body {
    padding: 1.1rem 1.2rem 1.2rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

/* When a project has no icon/cover, the media well is dropped entirely and the
   year moves into the body as a small chip so the tile still shows it. */
.proj-tile-year-chip {
    align-self: flex-start;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    padding: 0.1rem 0.6rem;
    margin-bottom: 0.6rem;
    font-size: 0.7rem;
    color: var(--pw-muted);
    font-family: 'JetBrains Mono', 'Fira Code', Consolas, monospace;
}

.proj-tile-title {
    font-size: 1.15rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    color: var(--pw-text);
    margin: 0 0 0.4rem;
}

.proj-tile-desc {
    font-size: 0.88rem;
    line-height: 1.5;
    color: var(--pw-muted);
    margin: 0 0 0.85rem;
    flex: 1;
}

.tech-chip-more {
    background: rgba(255, 255, 255, 0.05);
    color: var(--pw-muted);
    border-color: rgba(255, 255, 255, 0.1);
}

.proj-tile-arrow {
    color: var(--pw-accent);
    font-weight: 600;
    font-size: 0.85rem;
    margin-top: 0.85rem;
    padding-top: 0.85rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    transition: gap 150ms ease;
}

.proj-tile:hover .proj-tile-arrow {
    gap: 0.7rem;
}

/* ── Project detail hero ──────────────────────────────────────────────── */
.detail-hero {
    padding: 4rem 0 2rem;
}

.detail-hero-grid {
    display: flex;
    gap: 2rem;
    align-items: center;
    flex-wrap: wrap;
}

.detail-icon-wrap {
    width: clamp(96px, 14vw, 144px);
    aspect-ratio: 1 / 1;
    border-radius: 1.25rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.01));
    border: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    flex-shrink: 0;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}

.detail-icon-wrap img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.detail-hero-text {
    flex: 1;
    min-width: 280px;
}

.detail-title {
    font-size: clamp(2rem, 4.5vw, 3.5rem);
    font-weight: 700;
    line-height: 1.05;
    letter-spacing: -0.025em;
    color: var(--pw-text);
    margin: 0.4rem 0 0.85rem;
}

.detail-subtitle {
    font-size: 1.15rem;
    line-height: 1.5;
    color: var(--pw-muted);
    margin: 0 0 1.5rem;
    max-width: 50rem;
}

.detail-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

/* ── Project detail body ─────────────────────────────────────────────── */
.detail-cover {
    border-radius: 1rem;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: #0a0d14;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
}

.detail-cover img,
.detail-cover video {
    width: 100%;
    height: auto;
    display: block;
}

/* ── Media carousel (cover + gallery combined) ───────────────────────── */
.detail-carousel {
    position: relative;
    border-radius: 1rem;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: #0a0d14;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
}

.carousel-stage {
    aspect-ratio: 16 / 9;
    background: #07090f;
    display: flex;
    align-items: center;
    justify-content: center;
}

.carousel-stage img,
.carousel-stage video {
    max-width: 100%;
    max-height: 100%;
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.carousel-stage iframe {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
    background: #07090f;
}

.carousel-arrow {
    position: absolute;
    top: calc(50% - 40px);
    transform: translateY(-50%);
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    background: rgba(7, 9, 15, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.18);
    color: #e7eaf0;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 2;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: background 150ms ease, transform 150ms ease, opacity 150ms ease;
    font-size: 1.2rem;
}

.carousel-arrow:hover:not(:disabled) {
    background: rgba(77, 140, 255, 0.85);
    border-color: rgba(77, 140, 255, 0.85);
    transform: translateY(-50%) scale(1.05);
}

.carousel-arrow:disabled {
    opacity: 0.25;
    cursor: not-allowed;
}

.carousel-arrow-prev { left: 1rem; }
.carousel-arrow-next { right: 1rem; }

.carousel-counter {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(7, 9, 15, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #e7eaf0;
    font-family: 'JetBrains Mono', 'Fira Code', Consolas, monospace;
    font-size: 0.78rem;
    padding: 0.2rem 0.6rem;
    border-radius: 999px;
    z-index: 2;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.carousel-thumbs {
    display: flex;
    gap: 0.5rem;
    padding: 0.65rem;
    background: rgba(0, 0, 0, 0.35);
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    overflow-x: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.15) transparent;
}

.carousel-thumbs::-webkit-scrollbar { height: 6px; }
.carousel-thumbs::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.15); border-radius: 3px; }

.carousel-thumb {
    flex: 0 0 80px;
    width: 80px;
    height: 56px;
    border-radius: 0.4rem;
    overflow: hidden;
    border: 2px solid transparent;
    background: #11151f;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: border-color 150ms ease, transform 150ms ease;
}

.carousel-thumb:hover {
    border-color: rgba(77, 140, 255, 0.6);
}

.carousel-thumb.active {
    border-color: #4d8cff;
    transform: scale(1.04);
}

.carousel-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.carousel-thumb i {
    color: #8a93a5;
    font-size: 1.4rem;
}

.detail-cover-placeholder {
    aspect-ratio: 16 / 9;
    border-radius: 1rem;
    border: 1px dashed rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.02);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--pw-muted);
}

.detail-cover-placeholder i {
    font-size: 2.5rem;
    margin-bottom: .5rem;
    opacity: .5;
}

.detail-section-title {
    color: var(--pw-text);
    font-weight: 600;
    letter-spacing: -0.01em;
    margin: 0 0 1rem;
}

.detail-prose {
    color: var(--pw-text);
    opacity: 0.92;
    font-size: 1.05rem;
    line-height: 1.65;
    max-width: 50rem;
}

.detail-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 0.85rem;
}

.detail-gallery-item {
    border-radius: 0.75rem;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.06);
    background: #0a0d14;
    aspect-ratio: 4 / 3;
}

.detail-gallery-item img,
.detail-gallery-item video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Side cards already styled by .side-card but lighten on dark studio */
.side-card {
    background: rgba(255, 255, 255, 0.025);
    border-color: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

/* ── Contributors sidebar card on project detail ─────────────────────── */
.contributor-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.contributor-item {
    padding: .6rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    display: flex;
    flex-direction: column;
    gap: .1rem;
}

.contributor-item:first-child {
    border-top: none;
    padding-top: 0;
}

.contributor-name {
    font-weight: 600;
    color: var(--pw-text);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: .3rem;
}

a.contributor-name {
    color: var(--pw-accent);
}

a.contributor-name:hover {
    color: #7aa9ff;
    text-decoration: underline;
}

.contributor-role {
    color: var(--pw-muted);
    font-size: .82rem;
}

/* ── Legacy hero (kept for any pages still referencing the laptop card) ── */
/* ── Hero ────────────────────────────────────────────────────────────── */
.hero {
    padding-top: 2rem;
    position: relative;
}

.hero-eyebrow {
    color: var(--pw-accent-2);
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-size: 0.8rem;
    margin: 0;
}

.hero-title {
    font-size: clamp(2rem, 4vw, 3.25rem);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.02em;
    color: var(--pw-text);
}

.hero-lede {
    font-size: 1.125rem;
    color: var(--pw-muted);
    max-width: 36rem;
}

.hero-card {
    background: #050810;
    color: #d4dbe8;
    border: 1px solid var(--pw-border);
    border-radius: 0.85rem;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}

.hero-card-header {
    background: #03060c;
    padding: 0.6rem 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.35rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.hero-card-header .text-muted {
    color: #8a98ad !important;
}

.dot {
    width: 0.65rem;
    height: 0.65rem;
    border-radius: 50%;
    display: inline-block;
}
.dot-r { background: #ff5f57; }
.dot-y { background: #febc2e; }
.dot-g { background: #28c840; }

.hero-code {
    margin: 0;
    padding: 1.2rem;
    font-family: 'JetBrains Mono', 'Fira Code', Consolas, 'Courier New', monospace;
    font-size: 0.85rem;
    line-height: 1.6;
    color: #d4dbe8;
    background: transparent;
}

.c-key { color: #c792ea; }
.c-type { color: #82aaff; }
.c-str { color: #c3e88d; }

/* ── Sections ────────────────────────────────────────────────────────── */
.section {
    padding: 4rem 0;
}

.section-alt {
    background-color: var(--pw-bg-alt);
    border-top: 1px solid var(--pw-border);
    border-bottom: 1px solid var(--pw-border);
}

.section-eyebrow {
    color: var(--pw-accent-2);
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-size: 0.78rem;
    margin: 0 0 0.4rem;
}

.section-title {
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    margin: 0;
    color: var(--pw-text);
}

/* ── Page header ─────────────────────────────────────────────────────── */
.page-header {
    background: linear-gradient(180deg, var(--pw-bg-alt) 0%, var(--pw-bg) 100%);
    padding: 3rem 0 2rem;
    border-bottom: 1px solid var(--pw-border);
}

.page-title {
    font-size: clamp(1.75rem, 3vw, 2.5rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin: 0;
    color: var(--pw-text);
}

.page-subtitle {
    color: var(--pw-muted);
    margin-top: 0.5rem;
    max-width: 42rem;
}

/* ── Cards ───────────────────────────────────────────────────────────── */
.highlight-card,
.project-card,
.side-card,
.form-card,
.cta-card {
    background: var(--pw-card);
    border: 1px solid var(--pw-border);
    border-radius: 0.85rem;
    padding: 1.5rem;
    box-shadow: var(--pw-shadow);
    transition: transform 150ms ease, box-shadow 150ms ease, border-color 150ms ease;
}

.highlight-card:hover,
.project-card:hover {
    transform: translateY(-2px);
    border-color: rgba(77, 140, 255, 0.45);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.5), 0 18px 40px rgba(77, 140, 255, 0.12);
}

.project-card-link {
    display: block;
    color: inherit;
    text-decoration: none;
    height: 100%;
}

.project-card-link:hover {
    color: inherit;
    text-decoration: none;
}

.project-card {
    display: flex;
    flex-direction: column;
}

.project-card-footer {
    margin-top: auto;
    padding-top: 0.75rem;
}

.read-more {
    color: var(--pw-accent);
    font-weight: 600;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    transition: gap 120ms ease;
}

.project-card-link:hover .read-more {
    gap: 0.6rem;
}

.highlight-icon {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.6rem;
    background: linear-gradient(135deg, var(--pw-accent-2) 0%, var(--pw-accent) 100%);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.cta-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.5rem;
    flex-wrap: wrap;
    background: linear-gradient(135deg, var(--pw-card) 0%, #182236 100%);
}

/* ── Chips ───────────────────────────────────────────────────────────── */
.tech-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.tech-chip {
    background: rgba(77, 140, 255, 0.08);
    color: #cfdcff;
    border: 1px solid rgba(77, 140, 255, 0.25);
    border-radius: 999px;
    padding: 0.18rem 0.7rem;
    font-size: 0.78rem;
    font-weight: 500;
}

/* ── About / skills ──────────────────────────────────────────────────── */
.skill-group + .skill-group {
    margin-top: 1.1rem;
}

.skill-label {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--pw-muted);
    margin: 0 0 0.4rem;
    font-weight: 600;
}

.value-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.value-list li {
    padding: 0.5rem 0;
    border-top: 1px solid var(--pw-border);
    color: var(--pw-text);
}

.value-list li:first-child {
    border-top: none;
}

/* ── About: $ now card ───────────────────────────────────────────────── */
.now-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.now-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.7rem;
    padding: 0.65rem 0;
    border-top: 1px solid var(--pw-border);
    color: var(--pw-text);
    font-size: 0.95rem;
    line-height: 1.45;
}

.now-list li:first-child { border-top: none; padding-top: 0; }

.now-list li > i {
    color: var(--pw-accent-2);
    font-size: 1.05rem;
    line-height: 1.45;
    flex-shrink: 0;
}

/* ── About: stat counters ────────────────────────────────────────────── */
.stat-band {
    border-top: 1px solid var(--pw-border);
    border-bottom: 1px solid var(--pw-border);
    background:
        linear-gradient(180deg, rgba(77, 140, 255, 0.04) 0%, transparent 70%);
}

.stat-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
}

.stat {
    position: relative;
    padding: 1.5rem 1.4rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--pw-border);
    border-radius: 0.9rem;
    overflow: hidden;
}

.stat::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 3px;
    background: linear-gradient(180deg, var(--pw-accent), var(--pw-accent-2));
    opacity: 0.7;
}

.stat-num {
    display: flex;
    align-items: baseline;
    font-variant-numeric: tabular-nums;
    line-height: 1;
}

.stat-value {
    font-size: clamp(2.1rem, 4.4vw, 3rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    background: linear-gradient(120deg, var(--pw-text) 0%, var(--pw-accent-2) 130%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.stat-label {
    margin-top: 0.55rem;
    color: var(--pw-muted);
    font-size: 0.86rem;
    line-height: 1.4;
}

@media (max-width: 768px) {
    .stat-grid { grid-template-columns: repeat(2, 1fr); gap: 0.85rem; }
}

/* ── About: two worlds ───────────────────────────────────────────────── */
.duo-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
}

.duo-card {
    background: var(--pw-card);
    border: 1px solid var(--pw-border);
    border-radius: 1rem;
    padding: 1.6rem;
    transition: transform 200ms ease, border-color 200ms ease, box-shadow 200ms ease;
}

.duo-card:hover {
    transform: translateY(-3px);
    border-color: rgba(77, 140, 255, 0.4);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.5), 0 22px 48px rgba(77, 140, 255, 0.12);
}

.duo-head {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    margin-bottom: 0.8rem;
}

.duo-icon {
    width: 2.7rem;
    height: 2.7rem;
    border-radius: 0.7rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    color: #fff;
    background: linear-gradient(135deg, #6366f1 0%, var(--pw-accent) 100%);
    flex-shrink: 0;
}

.duo-icon-alt {
    background: linear-gradient(135deg, var(--pw-accent) 0%, var(--pw-accent-2) 100%);
}

.duo-title {
    font-size: 1.2rem;
    font-weight: 700;
    margin: 0;
    color: var(--pw-text);
}

.duo-lede {
    color: var(--pw-muted);
    font-size: 0.95rem;
    margin: 0 0 1rem;
}

.duo-list {
    list-style: none;
    padding: 0;
    margin: 0 0 1.1rem;
}

.duo-list li {
    position: relative;
    padding: 0.35rem 0 0.35rem 1.4rem;
    color: var(--pw-text);
    font-size: 0.92rem;
}

.duo-list li::before {
    content: "›";
    position: absolute;
    left: 0.2rem;
    color: var(--pw-accent-2);
    font-weight: 700;
}

@media (max-width: 768px) {
    .duo-grid { grid-template-columns: 1fr; }
}

/* ── About: certifications card ──────────────────────────────────────── */
.cert-row {
    display: flex;
    align-items: center;
    gap: 0.9rem;
}

.cert-row + .cert-row {
    margin-top: 0.85rem;
    padding-top: 0.85rem;
    border-top: 1px solid var(--pw-border);
}

.cert-icon {
    width: 2.7rem;
    height: 2.7rem;
    border-radius: 0.7rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    color: #fff;
    background: linear-gradient(135deg, #f43f5e 0%, #fb7185 100%);
    flex-shrink: 0;
}

.cert-title {
    font-weight: 600;
    color: var(--pw-text);
    font-size: 0.95rem;
}

.cert-meta {
    color: var(--pw-muted);
    font-size: 0.82rem;
    margin-top: 0.15rem;
}

/* ── About: toolbox grid ─────────────────────────────────────────────── */
.toolbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 1rem;
}

.toolbox-group {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--pw-border);
    border-radius: 0.85rem;
    padding: 1.1rem 1.2rem;
}

.toolbox-group .skill-label {
    margin-bottom: 0.65rem;
}

/* ── About: beyond the code ──────────────────────────────────────────── */
.beyond-grid {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 1.25rem;
    align-items: stretch;
}

.beyond-feature {
    background: linear-gradient(135deg, var(--pw-card) 0%, #1a1530 100%);
    border-color: rgba(168, 85, 247, 0.25);
}

.beyond-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.74rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #d8b4fe;
    background: rgba(168, 85, 247, 0.14);
    border: 1px solid rgba(168, 85, 247, 0.3);
    border-radius: 999px;
    padding: 0.25rem 0.7rem;
    margin-bottom: 0.9rem;
}

.beyond-col {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.beyond-mini {
    display: flex;
    align-items: flex-start;
    gap: 0.9rem;
    flex: 1;
}

.beyond-mini-icon {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.7rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: #fff;
    background: linear-gradient(135deg, var(--pw-accent-2) 0%, var(--pw-accent) 100%);
    flex-shrink: 0;
}

.beyond-mini-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--pw-text);
    margin: 0 0 0.25rem;
}

.beyond-mini-text {
    color: var(--pw-muted);
    font-size: 0.9rem;
    line-height: 1.5;
    margin: 0;
}

@media (max-width: 860px) {
    .beyond-grid { grid-template-columns: 1fr; }
}

/* ── About: resume CTA ───────────────────────────────────────────────── */
.resume-cta {
    align-items: center;
}

.resume-cta-btn {
    flex-shrink: 0;
    white-space: nowrap;
}

/* ── About: mobile polish ────────────────────────────────────────────── */
@media (max-width: 575.98px) {
    .page-hero { padding: 3.25rem 0 1.75rem; }

    .stat-grid { grid-template-columns: 1fr 1fr; gap: 0.7rem; }
    .stat { padding: 1.1rem 1rem; }
    .stat-label { font-size: 0.8rem; }

    .duo-card { padding: 1.25rem; }

    /* The CTA stacks: text over a full-width button. */
    .resume-cta { flex-direction: column; align-items: flex-start; }
    .resume-cta-btn { width: 100%; justify-content: center; }
}

/* ── Resume timeline ─────────────────────────────────────────────────── */
.timeline {
    position: relative;
    padding-left: 1.5rem;
}

.timeline::before {
    content: "";
    position: absolute;
    left: 0.45rem;
    top: 0.3rem;
    bottom: 0.3rem;
    width: 2px;
    background: var(--pw-border);
}

.timeline-item {
    position: relative;
    padding-bottom: 2rem;
}

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

.timeline-marker {
    position: absolute;
    left: -1.5rem;
    top: 0.45rem;
    width: 1rem;
    height: 1rem;
    border-radius: 50%;
    background: var(--pw-bg);
    border: 3px solid var(--pw-accent);
    box-shadow: 0 0 0 3px rgba(77, 140, 255, 0.15);
}

.timeline-content .company {
    color: var(--pw-accent);
    font-weight: 600;
    margin: 0;
}

/* ── Project search ──────────────────────────────────────────────────── */
.project-search {
    max-width: 22rem;
}

.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    background: var(--pw-card);
    border: 1px dashed var(--pw-border);
    border-radius: 0.85rem;
    color: var(--pw-muted);
}

.empty-state i {
    font-size: 2rem;
    display: block;
    margin-bottom: 0.5rem;
}

/* ── Project detail ──────────────────────────────────────────────────── */
.back-link {
    color: var(--pw-muted);
    font-size: 0.9rem;
    text-decoration: none;
}

.back-link:hover {
    color: var(--pw-accent);
    text-decoration: none;
}

.media-frame {
    border-radius: 0.85rem;
    overflow: hidden;
    border: 1px solid var(--pw-border);
    background: var(--pw-bg-alt);
}

.media-placeholder {
    aspect-ratio: 16 / 9;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--pw-muted);
    background:
        repeating-linear-gradient(
            45deg,
            var(--pw-bg-alt),
            var(--pw-bg-alt) 12px,
            #141a26 12px,
            #141a26 24px
        );
}

.media-placeholder i {
    font-size: 2.5rem;
    margin-bottom: 0.4rem;
    opacity: 0.6;
}

.gallery-thumb {
    border: 1px solid var(--pw-border);
    object-fit: cover;
    aspect-ratio: 4 / 3;
    width: 100%;
}

.detail-list {
    display: grid;
    grid-template-columns: max-content 1fr;
    column-gap: 1rem;
    row-gap: 0.55rem;
    font-size: 0.92rem;
}

.detail-list dt {
    color: var(--pw-muted);
    font-weight: 500;
}

.detail-list dd {
    margin: 0;
    color: var(--pw-text);
}

/* ── Contact ─────────────────────────────────────────────────────────── */
.contact-list li {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.4rem 0;
}

.contact-list li i {
    color: var(--pw-accent);
    width: 1.25rem;
    text-align: center;
}

.contact-list li a {
    color: var(--pw-text);
}

.contact-list li a:hover {
    color: var(--pw-accent);
}

.coursework-list li {
    padding: 0.4rem 0;
    border-top: 1px solid var(--pw-border);
    color: var(--pw-text);
    font-size: 0.92rem;
}

.coursework-list li:first-child {
    border-top: none;
}

.snapshot-label {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--pw-accent-2);
    font-weight: 700;
    margin: 0 0 0.75rem;
}

/* ── Git graph timeline (SVG-based) ──────────────────────────────────── */
.git-graph-box {
    background: #1e1e1e;
    border: 1px solid var(--pw-border);
    border-radius: 0.6rem;
    overflow: hidden;
    box-shadow: var(--pw-shadow);
    font-family: 'JetBrains Mono', 'Fira Code', Consolas, 'Segoe UI', monospace;
}

.git-graph-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.55rem 0.9rem;
    background: #161616;
    border-bottom: 1px solid #2a2a2a;
    font-size: 0.72rem;
}

.gh-title {
    color: #fff;
    font-weight: 600;
    letter-spacing: 0.06em;
}

.gh-meta {
    color: #808080;
}

.git-graph-body {
    position: relative;
}

.git-graph-svg {
    position: absolute;
    left: 0;
    top: 0;
    pointer-events: none;
}

.git-graph-rows {
    position: relative;
    z-index: 1;
}

.git-graph-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding-right: 0.9rem;
    cursor: pointer;
    transition: background-color 100ms ease;
    outline: none;
    font-family: 'Inter', 'Segoe UI', sans-serif;
    border-left: 2px solid transparent;
}

.git-graph-row:hover,
.git-graph-row:focus-visible,
.git-graph-row.is-selected {
    background-color: rgba(77, 140, 255, 0.06);
}

.git-graph-row.is-selected {
    background-color: rgba(77, 140, 255, 0.12);
    border-left-color: var(--pw-accent);
}

.gr-title {
    color: #e6e6e6;
    font-weight: 500;
    font-size: 0.9rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex-shrink: 1;
    min-width: 0;
}

.gr-author {
    color: #808080;
    font-size: 0.78rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
    flex-shrink: 1;
}

.gr-badge {
    margin-left: auto;
    font-family: 'JetBrains Mono', 'Fira Code', Consolas, monospace;
    font-size: 0.68rem;
    padding: 0.1rem 0.5rem;
    border-radius: 0.25rem;
    white-space: nowrap;
    flex-shrink: 0;
    border: 1px solid;
}

/* Category color tokens (used for badges + snapshot labels) */
.cat-education   { --cat: #f97316; }
.cat-achievement { --cat: #f97316; }
.cat-work        { --cat: #facc15; }
.cat-campus      { --cat: #ec4899; }
.cat-leadership  { --cat: #ec4899; }
.cat-coursework  { --cat: #06b6d4; }

.gr-badge.cat-education,
.gr-badge.cat-achievement,
.gr-badge.cat-work,
.gr-badge.cat-campus,
.gr-badge.cat-leadership,
.gr-badge.cat-coursework {
    color: var(--cat);
    border-color: color-mix(in srgb, var(--cat) 40%, transparent);
    background: color-mix(in srgb, var(--cat) 12%, transparent);
}

.snapshot-label.cat-education,
.snapshot-label.cat-achievement,
.snapshot-label.cat-work,
.snapshot-label.cat-campus,
.snapshot-label.cat-leadership,
.snapshot-label.cat-coursework {
    color: var(--cat);
}

/* Detail panel */
.git-detail-sticky {
    position: sticky;
    top: 5rem;
}

/* Fixed-height frame for the detail panel in the resume sidebar so the
   coursework card below it doesn't shift when the selected item changes. */
.timeline-detail-frame {
    height: 360px;
    overflow-y: auto;
    margin-bottom: 1.5rem;
}

.git-detail {
    background: var(--pw-card);
    border: 1px solid var(--pw-border);
    border-radius: 0.85rem;
    padding: 1.5rem;
    box-shadow: var(--pw-shadow);
    transition: border-color 150ms ease;
}

.git-detail:hover {
    border-color: rgba(77, 140, 255, 0.4);
}

.g-date-detail {
    color: var(--pw-accent);
    font-family: 'JetBrains Mono', 'Fira Code', Consolas, monospace;
    font-weight: 500;
}

/* ── Validation ──────────────────────────────────────────────────────── */
.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid #ff5470;
}

.validation-message {
    color: #ff7088;
    font-size: 0.85rem;
}

/* ── Error boundary ──────────────────────────────────────────────────── */
.blazor-error-boundary {
    background: #5c1010;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

.blazor-error-boundary::after {
    content: "An error has occurred.";
}

#blazor-error-ui {
    color-scheme: light only;
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    box-sizing: border-box;
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 0.75rem;
        top: 0.5rem;
    }

/* ╔══════════════════════════════════════════════════════════════════════╗
   ║  Scene — laptop on a desk                                            ║
   ╚══════════════════════════════════════════════════════════════════════╝ */

.scene {
    min-height: 100vh;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 1.25rem;
    padding: 2rem 1.5rem;
    position: relative;
    overflow-x: clip;
}

.scene-header {
    flex: 0 0 320px;
    max-width: 320px;
    color: var(--scene-ink);
    text-align: center;
    margin: 0;
    align-self: flex-start;
    padding-top: 0;
}

.scene-title {
    white-space: nowrap;
}

.scene-eyebrow {
    font-family: 'JetBrains Mono', 'Fira Code', Consolas, monospace;
    color: var(--scene-ink-muted);
    font-size: 0.85rem;
    letter-spacing: 0.08em;
    margin: 0 0 0.5rem;
    text-transform: lowercase;
}

.scene-title {
    color: var(--scene-ink);
    font-size: clamp(1.4rem, 1.9vw, 1.9rem);
    font-weight: 500;
    margin: 0;
    letter-spacing: -0.01em;
    line-height: 1.2;
}

.scene-footer {
    padding: 1.6rem 1rem;
    text-align: center;
    border-top: 1px solid var(--pw-border);
    margin-top: 4rem;
    color: var(--pw-muted);
}

.scene-footer .text-muted {
    color: var(--pw-muted) !important;
}

/* Fullscreen toggle (floats in top-right of the scene) ─────────────────── */
.site-fullscreen-btn {
    position: fixed;
    top: 1rem;
    right: 1rem;
    width: 2.5rem;
    height: 2.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.18);
    background: rgba(0, 0, 0, 0.35);
    color: var(--scene-ink, #e8e8e8);
    border-radius: 0.5rem;
    cursor: pointer;
    z-index: 1000;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transition: background-color 120ms ease, border-color 120ms ease, transform 120ms ease;
    font-size: 1rem;
    line-height: 1;
    padding: 0;
}

.site-fullscreen-btn:hover {
    background: rgba(0, 0, 0, 0.55);
    border-color: rgba(255, 255, 255, 0.35);
    transform: translateY(-1px);
}

.site-fullscreen-btn:focus-visible {
    outline: 2px solid var(--pw-accent, #4d8cff);
    outline-offset: 2px;
}

/* Laptop frame (SVG illustration + HTML overlay) ───────────────────────── */
.laptop-frame {
    position: relative;
    width: 100%;
    max-width: 1400px;
    aspect-ratio: 680 / 430;
    margin: 0 auto;
    z-index: 5;
    filter: drop-shadow(0 30px 50px rgba(0, 0, 0, 0.45));
}

.laptop-svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
    user-select: none;
    pointer-events: none;
}

/* Overlay positioned over the SVG's cream screen rectangle.
   Screen rect in viewBox (-285 -115 680 430): x=-187.6, y=-94.2, w=484.6, h=302.6
   → left 14.32%, top 4.84%, width 71.26%, height 70.37% */
.laptop-screen-overlay {
    position: absolute;
    left: 14.32%;
    top: 4.84%;
    width: 71.26%;
    height: 70.37%;
    display: flex;
    flex-direction: column;
    background: var(--pw-bg);
    overflow: hidden;
    z-index: 2;
}

/* Browser viewport ─────────────────────────────────────────────────────── */
.browser-viewport {
    flex: 1;
    background: var(--pw-bg);
    color: var(--pw-text);
    overflow-y: auto;
    overflow-x: hidden;
    /* hide scrollbar but keep scrollability */
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.browser-viewport::-webkit-scrollbar {
    width: 0;
    height: 0;
    display: none;
}

/* ╔══════════════════════════════════════════════════════════════════════╗
   ║  Browser chrome (tabs + URL bar)                                     ║
   ╚══════════════════════════════════════════════════════════════════════╝ */

.browser-chrome {
    background: var(--chrome-bg);
    border-bottom: 1px solid var(--chrome-border);
    font-family: 'Inter', 'Segoe UI', sans-serif;
    user-select: none;
    position: sticky;
    top: 0;
    z-index: 1000;
}

/* Title bar = tab strip + Windows window controls */
.browser-titlebar {
    display: flex;
    align-items: flex-end;
    gap: 0.75rem;
    padding: 0.55rem 0.85rem 0;
    background: var(--chrome-bg);
}

/* Windows-style window controls (minimize / maximize / close) on the right */
.win-controls {
    display: flex;
    align-items: stretch;
    margin-left: auto;
    margin-right: -0.85rem;          /* bleed to the right edge, Windows-style */
    align-self: stretch;
    flex-shrink: 0;
}

.win-btn {
    width: 2.85rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: default;
    transition: background 100ms ease;
}

.win-btn::before {
    content: "";
    display: block;
}

/* Minimize — a single bottom line */
.win-min::before {
    width: 0.7rem;
    height: 0;
    border-top: 1px solid var(--chrome-ink);
}

/* Maximize — a hollow square */
.win-max::before {
    width: 0.62rem;
    height: 0.62rem;
    border: 1px solid var(--chrome-ink);
}

/* Close — an X drawn from two rotated bars */
.win-close::before,
.win-close::after {
    content: "";
    position: absolute;
    width: 0.78rem;
    height: 1px;
    background: var(--chrome-ink);
}
.win-close::before { transform: rotate(45deg); }
.win-close::after  { transform: rotate(-45deg); }

.win-btn:hover { background: rgba(255, 255, 255, 0.08); }

.win-close:hover { background: #e81123; }      /* Windows red close hover */
.win-close:hover::before,
.win-close:hover::after { background: #fff; }

.browser-tabs {
    display: flex;
    align-items: flex-end;
    gap: 0;
    flex: 1;
    overflow-x: auto;
    scrollbar-width: none;
}

.browser-tabs::-webkit-scrollbar { display: none; }

.browser-tab {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 0.85rem 0.5rem;
    border-radius: 0.45rem 0.45rem 0 0;
    background: var(--chrome-border);
    color: var(--chrome-ink-muted);
    text-decoration: none;
    font-size: 0.78rem;
    line-height: 1;
    border: 1px solid transparent;
    border-bottom: none;
    margin-right: 0.15rem;
    min-width: 100px;
    max-width: 200px;
    position: relative;
    flex: 0 0 auto;
    transition: background 100ms ease, color 100ms ease;
}

.browser-tab:hover {
    background: #ddd8ca;
    color: var(--chrome-ink);
    text-decoration: none;
}

.browser-tab.is-active {
    background: var(--pw-bg);
    color: var(--scene-ink);
    border-color: var(--chrome-border);
    z-index: 1;
    margin-bottom: -1px;
}

.browser-tab.is-active::after {
    /* extend active tab visually into the URL bar */
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -2px;
    height: 2px;
    background: var(--pw-bg);
}

.tab-favicon {
    width: 0.7rem;
    height: 0.7rem;
    border-radius: 0.15rem;
    display: inline-block;
    flex-shrink: 0;
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.15);
}

.tab-label {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex: 1;
}

.tab-close {
    color: var(--chrome-ink-muted);
    font-size: 0.95rem;
    line-height: 1;
    opacity: 0.6;
    flex-shrink: 0;
}

.browser-tab:hover .tab-close { opacity: 1; }

.tab-newtab {
    color: var(--chrome-ink-muted);
    padding: 0.35rem 0.7rem 0.5rem;
    font-size: 1rem;
    cursor: default;
    line-height: 1;
    flex-shrink: 0;
}

/* URL bar */
.browser-urlbar {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.55rem 0.85rem;
    background: var(--chrome-bg);
    border-top: 1px solid var(--chrome-border);
    font-size: 0.8rem;
    color: var(--chrome-ink);
}

.urlbar-controls,
.urlbar-actions {
    display: flex;
    gap: 0.35rem;
    flex-shrink: 0;
}

.ub-btn {
    color: var(--chrome-ink-muted);
    width: 1.4rem;
    height: 1.4rem;
    border-radius: 0.25rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    line-height: 1;
}

.ub-btn.ub-disabled {
    opacity: 0.4;
}

.urlbar-input {
    flex: 1;
    background: var(--chrome-bg-light);
    border: 1px solid var(--chrome-border);
    border-radius: 999px;
    padding: 0.3rem 0.85rem;
    display: flex;
    align-items: center;
    gap: 0.45rem;
    font-family: 'JetBrains Mono', 'Fira Code', Consolas, monospace;
    font-size: 0.75rem;
    color: var(--chrome-ink);
    overflow: hidden;
    white-space: nowrap;
}

.ub-lock {
    color: #4a8a4a;
    font-size: 0.7rem;
    flex-shrink: 0;
}

.ub-host {
    color: var(--chrome-ink);
}

.ub-path {
    color: var(--chrome-ink-muted);
}

/* ╔══════════════════════════════════════════════════════════════════════╗
   ║  Resume viewer (embedded Google Doc + download)                      ║
   ╚══════════════════════════════════════════════════════════════════════╝ */

.resume-viewer-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.resume-viewer-frame {
    width: 100%;
    margin-top: 1rem;
    background: #525659; /* matches the PDF/Docs viewer canvas */
    border: 1px solid var(--pw-border);
    border-radius: 0.9rem;
    overflow: hidden;
    box-shadow: var(--pw-shadow);
}

.resume-viewer-frame iframe {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
}

.resume-viewer-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    padding: 2.5rem 1rem;
    color: var(--pw-muted);
}

/* On phones a fixed 800–900px embed is unreadable; cap it to the viewport and
   let the Google Docs/PDF viewer scroll inside the frame instead. The inline
   height set by the component is overridden here. */
@media (max-width: 768px) {
    .resume-viewer-frame {
        height: 72vh !important;
        min-height: 440px;
    }
    .resume-viewer-controls .btn {
        flex: 1 1 auto;
        justify-content: center;
    }
}

/* ╔══════════════════════════════════════════════════════════════════════╗
   ║  Desk decorations (pinned to viewport)                               ║
   ╚══════════════════════════════════════════════════════════════════════╝ */

/* Coffee mug ───────────────────────────────────────────────────────────── */
.desk-mug {
    position: fixed;
    right: clamp(1.5rem, 6vw, 5rem);
    bottom: 9rem;
    width: 90px;
    z-index: 4;
}

.mug-body {
    position: relative;
    width: 80px;
    height: 96px;
    background: linear-gradient(180deg, #e55039 0%, #c1392f 100%);
    border-radius: 0 0 12px 12px;
    margin: 0 auto;
    box-shadow: 0 10px 18px rgba(0, 0, 0, 0.3);
}

.mug-rim {
    position: absolute;
    top: 8px;
    left: 8px;
    right: 8px;
    height: 14px;
    background: #c9a227;
    border-radius: 50%;
    box-shadow: inset 0 -2px 4px rgba(0, 0, 0, 0.3);
}

.mug-handle {
    position: absolute;
    right: -22px;
    top: 18px;
    width: 24px;
    height: 44px;
    border: 6px solid #e55039;
    border-left: none;
    border-radius: 0 24px 24px 0;
}

.mug-saucer {
    width: 96px;
    height: 10px;
    background: #f5f0e6;
    border-radius: 50%;
    margin: -4px auto 0;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.25);
}

.mug-steam {
    position: absolute;
    left: 50%;
    top: -28px;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    pointer-events: none;
}

.steam {
    display: block;
    width: 3px;
    height: 20px;
    background: rgba(245, 240, 230, 0.5);
    border-radius: 3px;
    animation: steam 2.4s ease-in-out infinite;
}

.steam.s1 { animation-delay: 0s; }
.steam.s2 { animation-delay: 0.4s; height: 28px; }
.steam.s3 { animation-delay: 0.8s; height: 18px; }

@keyframes steam {
    0%   { opacity: 0; transform: translateY(10px) scaleY(0.6); }
    25%  { opacity: 0.7; }
    100% { opacity: 0; transform: translateY(-18px) scaleY(1); }
}

/* Monster can ──────────────────────────────────────────────────────────── */
.desk-can {
    position: fixed;
    right: clamp(1rem, 3vw, 3rem);
    bottom: 4rem;
    width: clamp(120px, 11vw, 180px);
    z-index: 4;
    filter: drop-shadow(0 18px 26px rgba(0, 0, 0, 0.45));
    pointer-events: none;
}

.monster-can-svg {
    display: block;
    width: 100%;
    height: auto;
}

/* ╔══════════════════════════════════════════════════════════════════════╗
   ║  Fullscreen toggle — strip the laptop chrome and fill the viewport   ║
   ╚══════════════════════════════════════════════════════════════════════╝ */
body.is-fullscreen .scene {
    padding: 0;
    min-height: 100vh;
    gap: 0;
}
body.is-fullscreen .scene-header,
body.is-fullscreen .desk-can,
body.is-fullscreen .desk-mug,
body.is-fullscreen .laptop-svg {
    display: none;
}
body.is-fullscreen .laptop-frame {
    max-width: 100%;
    width: 100%;
    aspect-ratio: auto;
    filter: none;
    min-height: 100vh;
    margin: 0;
}
body.is-fullscreen .laptop-screen-overlay {
    position: static;
    left: 0;
    top: 0;
    width: 100%;
    height: auto;
    min-height: 100vh;
}
body.is-fullscreen .browser-viewport {
    overflow-y: auto;
    min-height: 0;
    height: auto;
}

@media (max-width: 768px) {
    .site-fullscreen-btn {
        display: none;
    }
}

/* ╔══════════════════════════════════════════════════════════════════════╗
   ║  Mobile fallback — hide the scene chrome, keep the content readable  ║
   ╚══════════════════════════════════════════════════════════════════════╝ */
@media (max-width: 1200px) {
    .scene-header {
        display: none;
    }
    .scene {
        flex-direction: column;
    }
}

@media (max-width: 768px) {
    .scene {
        padding: 0;
    }
    .scene-header {
        display: none;
    }
    .laptop-frame {
        max-width: 100%;
        aspect-ratio: auto;
        filter: none;
        min-height: 100vh;
    }
    .laptop-svg {
        display: none;
    }
    .laptop-screen-overlay {
        position: static;
        width: 100%;
        height: auto;
        min-height: 100vh;
    }
    .desk-mug,
    .desk-can {
        display: none;
    }
    .browser-viewport {
        overflow: visible;
        min-height: 100vh;
    }
    .browser-titlebar {
        padding: 0.4rem 0.6rem 0;
    }
    .win-controls { display: none; }
    .browser-tab {
        min-width: auto;
        padding: 0.4rem 0.6rem;
        font-size: 0.72rem;
    }
    .tab-close { display: none; }
    .browser-urlbar { display: none; }
}
