/* Responsive tiers: mobile <=700px; tablet 701–1200px; desktop >=1201px.
   Aspect ratio, orientation, motion and hover queries handle device capabilities. */
/* ==========================================================
   STUDY CLONE – structure inspired by a creative-developer
   portfolio. Placeholder content only.
   Concepts to study: CSS variables, grid, clamp(), sticky
   header, full-screen overlay menu, marquee, accordion,
   scroll-reveal, custom cursor.
   ========================================================== */
:root {
    color-scheme: light;
    --bg: #eef0ff;
    --fg: #051118;
    --muted: #d3d3ea;
    --accent: #152eff;
    --line: rgba(5, 17, 24, 0.18);
    --font-body: "Martian Mono", "Courier New", monospace;
    --font-display: "Agoka Family", Georgia, serif;
    --pad: clamp(16px, 3vw, 48px);
    --ease: cubic-bezier(0.76, 0, 0.24, 1);
    --nav-icon-size: clamp(29px, max(2.4vw, 3.6vh), 58px);
}

@font-face {
    font-family: "Celattin";
    src: url("fonts/celattin-font.otf") format("opentype");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@property --hello-white-progress {
    syntax: "<percentage>";
    inherits: true;
    initial-value: 0%;
}

@font-face {
    font-family: "Agoka Family";
    src: url("assets/AgokaFamily.otf") format("opentype");
    font-style: normal;
    font-weight: 400;
    font-display: swap;
}

@font-face {
    font-family: "Innovar Elegant";
    src: local("Innovar Elegant"), local("INNOVAR ELEGANT REGULAR");
    font-style: normal;
    font-weight: 400;
    font-display: swap;
}

.brand-name {
    font-family: "Celattin", sans-serif;
    font-style: italic;
}

@font-face {
    font-family: "Innovar Elegant";
    src: local("Innovar Elegant Italic"), local("INNOVAR ELEGANT REGULAR ITALIC");
    font-style: italic;
    font-weight: 400;
    font-display: swap;
}

body[data-theme="dark"] {
    color-scheme: dark;
    --bg: #051118;
    --fg: #f8f8ff;
    --muted: #b1b1da;
    --accent: #d0f4ff;
    --line: rgba(248, 248, 255, 0.14);
}

body[data-theme="dark"] .site-header {
    color: var(--fg);
}

body[data-theme="dark"] .site-header .logo,
body[data-theme="dark"] .site-header .theme-btn,
body[data-theme="dark"] .site-header .menu-btn {
    color: var(--accent);
}

body[data-theme="dark"]:has(.hero--gallery) {
    background-color: var(--bg);
}

body[data-theme="dark"] section.hero--gallery {
    color: var(--accent);
}

body[data-theme="dark"] section.hero--gallery::before {
    filter: brightness(0.72) blur(var(--hero-blur, 0px));
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    text-wrap: pretty;
}

html {
    scroll-behavior: smooth;
    scroll-snap-type: y proximity;
}

html:has(.hero--gallery) {
    scroll-snap-type: y mandatory;
}

html:has(.hero--gallery).home-scroll-through-tall {
    scroll-snap-type: y proximity;
}

html:has(.hero--gallery).home-wheel-animating {
    scroll-snap-type: none;
    scroll-behavior: auto;
}

html:has(.hero--gallery).home-wheel-holding {
    scroll-snap-type: none;
    scroll-behavior: auto;
}

html,
body {
    scrollbar-width: none;
    -ms-overflow-style: none;
}

html::-webkit-scrollbar,
body::-webkit-scrollbar {
    display: none;
}

body {
    background: var(--bg);
    color: var(--fg);
    font-family: var(--font-body);
    line-height: 1.5;
    overflow-x: hidden;
    user-select: none;
    -webkit-user-select: none;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    display: block;
    -webkit-user-drag: none;
    user-drag: none;
}

/* ---------- Header + overlay menu ---------- */
.site-header {
    position: fixed;
    inset: 0 0 auto 0;
    z-index: 50;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: clamp(8px, 0.625vw, 12px) clamp(16px, 3.5vw, 68px) clamp(8px, 0.625vw, 12px) clamp(12px, 1.8vw, 35px);
    color: var(--accent);
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 0;
    width: max-content;
    min-height: var(--nav-icon-size);
    color: var(--accent);
    font-weight: 700;
    font-size: clamp(12px, 1.25vw, 24px);
    letter-spacing: -0.03em;
}

.logo-mark {
    display: block;
    width: var(--nav-icon-size);
    height: var(--nav-icon-size);
    flex: 0 0 var(--nav-icon-size);
    animation: logo-gentle-rotate 24s linear infinite;
}

@keyframes logo-gentle-rotate {
    to {
        transform: rotate(360deg);
    }
}

.logo-label {
    display: inline-block;
    max-width: 0;
    overflow: hidden;
    opacity: 0;
    transform: translateX(-8px);
    transition: max-width 0.45s var(--ease), opacity 0.45s var(--ease), transform 0.45s var(--ease), margin-left 0.45s var(--ease);
    white-space: nowrap;
}

.logo:hover .logo-label,
.logo:focus-visible .logo-label {
    max-width: 7ch;
    margin-left: 9px;
    opacity: 1;
    transform: translateX(0);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: clamp(12px, 1.05vw, 20px);
}

.theme-btn-placeholder {
    flex: 0 0 var(--nav-icon-size);
    width: var(--nav-icon-size);
    height: var(--nav-icon-size);
}

.theme-btn {
    position: relative;
    display: grid;
    width: var(--nav-icon-size);
    height: var(--nav-icon-size);
    flex: 0 0 var(--nav-icon-size);
    place-items: center;
    padding: 0;
    background: none;
    border: 0;
    color: var(--accent);
    cursor: pointer;
}

.theme-icon {
    position: absolute;
    left: 50%;
    top: 50%;
    display: block;
    width: var(--nav-icon-size);
    height: var(--nav-icon-size);
    overflow: visible;
    transform: translate(-50%, -50%);
}

.theme-icon__base {
    fill: currentColor;
}

.theme-icon__base-spin {
    transform-box: fill-box;
    transform-origin: center;
}

.theme-icon__overlay {
    fill: var(--fg);
    stroke: var(--accent);
    stroke-width: 0.25px;
    stroke-miterlimit: 10;
}

.theme-icon__rotator {
    transform-box: fill-box;
    transform-origin: center;
    animation: theme-icon-spin 12s linear infinite;
}

.theme-btn.is-spinning .theme-icon__base-spin {
    animation: theme-icon-spin 0.6s linear 1;
}

.theme-btn.is-spinning .theme-icon__rotator {
    animation: theme-icon-spin 0.6s linear 1;
}

.theme-btn.is-spinning .theme-icon__base {
    animation: theme-icon-color-invert 0.6s ease-in-out 1;
}

@keyframes theme-icon-spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes theme-icon-color-invert {
    0%,
            100% {
        fill: var(--accent);
    }

    50% {
        fill: var(--fg);
    }
}

.theme-btn:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 4px;
}

.theme-btn.is-transition-floating {
    position: fixed;
    z-index: 130;
    margin: 0;
}

.menu-btn {
    --menu-mark-size: clamp(18px, 1.6vw, 28px);
    --menu-cross-size: clamp(13px, 1.13vw, 20px);
    --menu-line-top: clamp(-14px, -0.8vw, -9px);
    --menu-line-bottom: clamp(9px, 0.8vw, 14px);
    position: relative;
    display: grid;
    width: var(--nav-icon-size);
    height: var(--nav-icon-size);
    flex: 0 0 var(--nav-icon-size);
    place-items: center;
    background: none;
    border: 0;
    color: inherit;
    border-radius: 0;
    cursor: pointer;
}

.menu-btn span {
    position: absolute;
    width: var(--menu-mark-size);
    height: clamp(1px, 0.08vw, 2px);
    background: currentColor;
    transition: width 0.35s var(--ease), transform 0.35s var(--ease), opacity 0.2s ease;
}

.menu-btn span:nth-child(1) {
    transform: translateY(var(--menu-line-top));
}

.menu-btn span:nth-child(3) {
    transform: translateY(var(--menu-line-bottom));
}

.menu-btn[aria-expanded="true"] span:nth-child(1) {
    width: var(--menu-cross-size);
    transform: rotate(45deg);
}

.menu-btn[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
}

.menu-btn[aria-expanded="true"] span:nth-child(3) {
    width: var(--menu-cross-size);
    transform: rotate(-45deg);
}

.menu-btn:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 4px;
}

.menu {
    position: fixed;
    inset: 0;
    z-index: 40;
    background: var(--bg);
    display: grid;
    grid-template-columns: 1fr 1fr;
    padding: 120px var(--pad) var(--pad);
    max-height: 100vh;
    max-height: 100dvh;
    overflow-y: scroll;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
    clip-path: inset(0 0 100% 0);
    transition: clip-path 0.8s var(--ease);
}

.menu.open {
    clip-path: inset(0 0 0 0);
}

.menu {
    scrollbar-width: none;
}

.menu::-webkit-scrollbar {
    display: none;
}

.menu ul {
    list-style: none;
    align-self: center;
}

.menu li a {
    display: block;
    font-size: clamp(2.5rem, 7vw, 6rem);
    font-weight: 700;
    letter-spacing: -0.04em;
    line-height: 1.05;
    color: var(--muted);
    transition: color 0.3s, transform 0.3s;
}

.menu li a:hover {
    color: var(--fg);
    transform: translateX(16px);
}

.menu-preview {
    border-radius: 12px;
    transition: background 0.5s;
}

/* ---------- Hero ---------- */
.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: var(--pad);
}

.hero small {
    color: var(--muted);
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.hero h1 {
    font-size: clamp(3rem, 11vw, 11rem);
    line-height: 0.92;
    letter-spacing: -0.05em;
    margin: 16px 0 32px;
}

.hero h1 .word {
    display: inline-block;
    overflow: hidden;
    vertical-align: top;
}

.hero h1 .word > span {
    display: inline-block;
    transform: translateY(110%);
    animation: rise 1s var(--ease) forwards;
}

@keyframes rise {
    to {
        transform: translateY(0);
    }
}

.hero-meta {
    display: flex;
    justify-content: space-between;
    color: var(--muted);
    border-top: 1px solid var(--line);
    padding-top: 16px;
}

.tags {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 24px;
}

.tag {
    border: 1px solid var(--line);
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 0.85rem;
}

/* ---------- Screenshot-matched homepage hero ---------- */
section.hero {
    display: flex;
    height: 100vh;
    height: 100svh;
    min-height: 640px;
    flex-direction: column;
    justify-content: flex-end;
    padding: 2rem var(--pad) 18vh;
}

.hero .tags {
    gap: 10px;
    margin-bottom: 18px;
}

.hero .tag {
    padding: 4px 12px;
    border-color: var(--line);
    color: var(--fg);
    font-size: 0.7rem;
    font-weight: 600;
}

.hero__eyebrow {
    margin-bottom: 16px;
    color: var(--muted);
    font-size: 0.68rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.hero h1.hero__title {
    margin: 0 0 24px;
    color: var(--fg);
    font-size: clamp(3rem, 8vw, 8rem);
    font-weight: 700;
    letter-spacing: -0.055em;
    line-height: 0.94;
}

@media (min-width:800px) {
    .hero__title span {
        display: block;
    }
}

.hero-meta {
    gap: 1rem;
    padding-top: 14px;
    border-color: var(--line);
    color: var(--muted);
    font-size: 0.68rem;
}

.hero-meta b {
    color: var(--fg);
    font-weight: 600;
}

@media (min-width: 1201px) {
    section.hero {
        padding-right: 2vw;
        padding-left: 2vw;
    }
}

@media (min-width: 701px) and (max-width: 1200px) {
    .hero h1.hero__title {
        font-size: clamp(3rem, 6.67vw, 6rem);
    }
}

@media (max-width: 700px) {
    section.hero {
        min-height: 680px;
        padding: 7rem var(--pad) 14vh;
    }

    .hero .tags {
        gap: 7px;
    }

    .hero .tag {
        padding: 4px 9px;
        font-size: 0.59rem;
    }

    .hero h1.hero__title {
        font-size: clamp(2.8rem, 11vw, 4.5rem);
    }

    .hero-meta {
        align-items: flex-start;
        font-size: 0.58rem;
    }

    .hero-meta span:last-child {
        text-align: right;
    }
}

/* ---------- SVG-inspired gallery homepage hero ---------- */
section.hero--gallery {
    position: sticky;
    top: 0;
    z-index: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    width: 100%;
    height: 100vh;
    height: max(100vh, 100dvh);
    min-height: max(100vh, 100dvh);
    overflow: clip;
    padding: 0 clamp(16px, 2vw, 40px) clamp(16px, 2vw, 40px);
    background: transparent;
    color: var(--accent);
}

section.hero--gallery::before {
    position: absolute;
    z-index: -1;
    inset: 0;
    content: "";
    background-color: #808080;
    background-image: url("assets/hero-design-background.jpg");
    background-position: center center;
    background-repeat: no-repeat;
    background-size: cover;
    filter: blur(var(--hero-blur, 0px));
    transition: filter 360ms ease;
    will-change: filter;
}

section.hero--gallery::after {
    display: none;
}

@media (orientation: portrait) {
    section.hero--gallery::before {
        background-position: 62% center;
    }
}

.theme-transition[hidden] {
    display: none;
}

.theme-transition {
    position: fixed;
    inset: 0;
    z-index: 120;
    display: grid;
    place-items: center;
    overflow: hidden;
    background: var(--accent);
    color: #fff;
    pointer-events: none;
    will-change: transform;
}

.theme-transition span {
    font-size: clamp(1.5rem, 5vw, 5rem);
    font-weight: 500;
    letter-spacing: 0.12em;
}

html.page-transition-pending {
    background: var(--accent);
}

html.page-transition-pending body > :not(#themeTransition) {
    visibility: hidden;
}

html.page-transition-pending body > #themeTransition {
    visibility: visible;
}

.hero__composition {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1fr) max-content;
    grid-template-areas: "main main"
    "meta experience";
    column-gap: clamp(12px, 2vw, 36px);
    align-items: baseline;
    justify-content: space-between;
    row-gap: clamp(14px, 3.5vw, 48px);
    width: 100%;
    margin-bottom: clamp(10px, 1.8vw, 32px);
    transform: translateY(var(--hero-content-shift, 0px));
    transition: row-gap 220ms cubic-bezier(0.2, 0.7, 0.2, 1),
    margin-bottom 220ms cubic-bezier(0.2, 0.7, 0.2, 1);
}

.hero--gallery h1.hero__title {
    display: contents;
    color: inherit;
}

.hero--gallery .hero__title-brand {
    display: inline-flex;
    align-items: baseline;
    white-space: nowrap;
}

.hero--gallery .hero__title-name-star,
.hero--gallery .hero__title-suffix {
    display: inline-block;
    flex: 0 0 auto;
    white-space: nowrap;
}

.hero__title-brand {
    display: inline-block;
    font-family: "Celattin", sans-serif;
    font-size: 1em;
    font-weight: 400;
    letter-spacing: normal;
    line-height: inherit;
    white-space: nowrap;
    flex: 0 0 auto;
}

.hero__title-name-star {
    display: inline-block;
    font-size: 1.3em;
    line-height: inherit;
    white-space: nowrap;
}

.hero__title-name-star > .brand-name {
    font-size: 1em;
    font-style: normal;
    line-height: inherit;
}

.hero--gallery .hero__title-main {
    display: flex;
    flex-wrap: nowrap;
    align-items: baseline;
    grid-area: main;
    justify-self: start;
    position: static;
    color: inherit;
    font-family: var(--font-display);
    font-size: clamp(48px, 8vw, 160px);
    font-weight: 400;
    letter-spacing: 0;
    line-height: 1;
    transform: none;
    transform-origin: left center;
    white-space: nowrap;
    transition: none;
}

.hero__title-main .hero__title-art {
    display: inline-block;
    flex: 0 0 auto;
    margin-left: 0.2em;
    font-family: "Agoka Family", serif;
    font-size: 0.58em;
    font-weight: 400;
    white-space: normal;
}

.hero__title-main .hero-gallery-word {
    display: inline-block;
    white-space: nowrap;
    line-height: 1;
}

.hero__title-main .hero-gallery-y {
    display: inline;
}

.hero-dark-2 {
    display: inline-block;
    width: 1em;
    height: 1em;
    margin-left: 0.35em;
    vertical-align: -0.15em;
    overflow: visible;
    fill: #eef0ff;
    stroke: var(--accent);
    stroke-width: 0.25px;
    pointer-events: none;
}

.hero-dark-2__rotator {
    transform-box: fill-box;
    transform-origin: center;
    animation: theme-icon-spin 24s linear infinite;
}

.hero__outline-layout {
    display: none;
}

.hero__outline-clock {
    display: none;
}

@media (min-width: 1201px) and (min-aspect-ratio: 7/4) and (max-aspect-ratio: 9/5) {
    .hero__title-main .hero-gallery-y {
        display: inline-block;
        position: relative;
    }

    .hero-dark-2 {
        position: absolute;
        left: calc(100% - 0.4em);
        top: -0.3em;
        margin: 0;
    }
}

.hero__title-last {
    grid-area: experience;
    position: static;
    justify-self: end;
    color: inherit;
    font-family: var(--font-display);
    font-size: clamp(48px, 8vw, 160px);
    font-weight: 400;
    letter-spacing: 0;
    line-height: 1;
    transform: scaleX(0.82);
    transform-origin: right center;
    white-space: nowrap;
    transition: none;
}

.hero--gallery .hero__asterisk {
    display: inline-block;
    margin-right: 0;
    font-size: 1em;
    line-height: inherit;
    transform: none;
    vertical-align: baseline;
}

.hero--gallery .hero-meta {
    grid-area: meta;
    display: flex;
    align-items: baseline;
    width: 100%;
    justify-content: space-between;
    align-self: baseline;
    gap: clamp(6px, 1vw, 18px);
    min-width: 0;
    padding: 0;
    border: 0;
    color: inherit;
    font-family: "Martian Mono", "Courier New", monospace;
    font-size: clamp(7px, max(1.05vw, 0.9vh), 19px);
    font-weight: 300;
    letter-spacing: 0.02em;
    line-height: 1;
    transform: none;
    transition: none;
}

.hero--gallery .hero-meta > span:last-child {
    display: flex;
    align-items: baseline;
    gap: 0.45em;
    margin-left: auto;
    white-space: nowrap;
    text-align: right;
}

.hero--gallery .hero-meta b {
    color: inherit;
    font-weight: 300;
}

@media (min-width:800px) {
    .hero--gallery .hero-meta .hero-clock {
        font-size: inherit;
        font-weight: 900;
    }
}

.hero-time-label-short {
    display: none;
}

body:has(.hero--gallery) {
    --nav-icon-size: clamp(29px, max(2.4vw, 3.6vh), 58px);
    background-color: #808080;
}

body:has(.hero--gallery) .site-header {
    padding: clamp(8px, 0.625vw, 12px) clamp(16px, 3.5vw, 68px) clamp(8px, 0.625vw, 12px) clamp(12px, 1.8vw, 35px);
    color: var(--accent);
}

body:has(.hero--gallery) .logo {
    width: max-content;
    min-height: var(--nav-icon-size);
    font-size: clamp(12px, 1.25vw, 24px);
}

body:has(.hero--gallery) .logo-mark {
    display: block;
    width: var(--nav-icon-size);
    height: var(--nav-icon-size);
    flex-basis: var(--nav-icon-size);
}

body:has(.hero--gallery) .header-actions {
    gap: clamp(12px, 1.05vw, 20px);
}

body:has(.hero--gallery) .theme-btn {
    position: relative;
    width: var(--nav-icon-size);
    height: var(--nav-icon-size);
    flex: 0 0 var(--nav-icon-size);
    color: var(--accent);
}

body:has(.hero--gallery) .theme-btn.is-transition-floating {
    position: fixed;
}

body:has(.hero--gallery) .theme-btn-placeholder {
    flex: 0 0 var(--nav-icon-size);
    width: var(--nav-icon-size);
    height: var(--nav-icon-size);
}

body:has(.hero--gallery) .theme-icon {
    position: absolute;
    left: 50%;
    top: 50%;
    width: var(--nav-icon-size);
    height: var(--nav-icon-size);
    transform: translate(-50%, -50%);
}

body:has(.hero--gallery) .menu-btn {
    color: inherit;
}

body:has(.hero--gallery) .menu-btn {
    --menu-mark-size: clamp(18px, 1.6vw, 28px);
    --menu-cross-size: clamp(13px, 1.13vw, 20px);
    --menu-line-top: clamp(-14px, -0.8vw, -9px);
    --menu-line-bottom: clamp(9px, 0.8vw, 14px);
    width: var(--nav-icon-size);
    height: var(--nav-icon-size);
    flex: 0 0 var(--nav-icon-size);
}

body:has(.hero--gallery) .menu-btn span {
    height: clamp(1px, 0.08vw, 2px);
}

body[data-theme="dark"] .hero--gallery::before {
    background-color: var(--bg);
    color: var(--fg);
}

body[data-theme="dark"]:has(.hero--gallery) .site-header {
    color: var(--fg);
}

body:has(.hero--gallery) > section:not(.hero--gallery):not(.hello-page),
body:has(.hero--gallery) > .marquee,
body:has(.hero--gallery) > footer {
    position: relative;
    z-index: 1;
    background: var(--bg);
}

@media (max-width: 700px) {
    .site-header {
        padding: clamp(8px, 1.5vw, 12px) clamp(16px, 5vw, 35px);
    }

    section.hero--gallery {
        padding: 0 clamp(16px, 5vw, 35px) clamp(16px, 4vw, 28px);
    }

    .hero__composition {
        grid-template-columns: minmax(0, 1fr) max-content;
        grid-template-areas: "main main"
      "meta experience";
        row-gap: clamp(12px, 3vw, 24px);
        margin-bottom: clamp(8px, 1.8vw, 14px);
    }

    .hero__title-main {
        max-width: 90vw;
        font-size: clamp(30px, 10vw, 64px);
        white-space: normal;
        transform: none;
    }

    .hero__title-last {
        justify-self: end;
        font-size: clamp(18px, 5.5vw, 40px);
        transform: none;
        white-space: nowrap;
    }

    .hero--gallery .hero-meta {
        grid-template-columns: minmax(0, 1fr) max-content;
        column-gap: clamp(4px, 1vw, 8px);
        font-size: clamp(7px, 0.9vh, 10px);
        white-space: nowrap;
    }

    .hero--gallery .hero-meta > span:last-child {
        text-align: right;
    }

    body:has(.hero--gallery) .site-header {
        padding: clamp(8px, 1.5vw, 12px) clamp(16px, 5vw, 35px);
    }
}

@media (min-width: 701px) and (max-width: 1200px) {
    .hero__composition {
        grid-template-columns: minmax(0, 1fr) max-content;
        grid-template-areas: "main main"
      "meta experience";
        row-gap: clamp(10px, 2vh, 24px);
    }

    .hero--gallery .hero-meta {
        width: 100%;
    }
}

@media (max-width: 700px) and (max-aspect-ratio: 9/16) {
    .hero--gallery .hero-meta {
        font-size: clamp(9px, 1.2vh, 12px);
    }

    .hero-dark-2 {
        width: 1em;
        height: 1em;
    }
}

@media (max-width: 1200px), (orientation: portrait) {
    .hero__composition {
        grid-template-columns: minmax(0, 1fr) max-content;
        grid-template-areas: "main main"
      "meta experience";
        row-gap: clamp(8px, 1.5vh, 20px);
        margin-bottom: clamp(8px, 1.5vh, 20px);
    }

    .hero__title-main,
            .hero__title-last {
        font-size: clamp(24px, min(calc(10vw + 3vh), 12vw), 88px);
        line-height: 0.95;
        min-width: 0;
        overflow-wrap: anywhere;
    }

    .hero__title-main {
        max-width: 100%;
        font-size: clamp(20px, 8.5vw, 72px);
        white-space: nowrap;
        transform: none;
    }

    .hero__title-last {
        justify-self: end;
        max-width: 100%;
        font-size: clamp(18px, 5.5vw, 40px);
        white-space: nowrap;
        text-align: right;
        transform: none;
    }

    .hero--gallery .hero-meta {
        grid-template-columns: minmax(0, 1fr) max-content;
        align-items: baseline;
        column-gap: clamp(8px, 2vw, 20px);
        min-width: 0;
        font-size: clamp(7px, 0.9vh, 10px);
        white-space: nowrap;
    }

    .hero--gallery .hero-meta > span:first-child {
        min-width: 0;
    }

    .hero--gallery .hero-meta > span:last-child {
        text-align: right;
    }

    .hero-time-label-full {
        display: none;
    }

    .hero-time-label-short {
        display: inline;
    }
}

@media (min-width: 701px) and (max-width: 1200px) and (orientation: landscape) {
    .hero__title-last {
        transform: scaleX(1.2);
    }
}

@media (prefers-reduced-motion: reduce) {
    .theme-icon__rotator,
            .hero-dark-2__rotator {
        animation: none;
    }

    section.hero--gallery,
            .hero__composition,
            .hero__title-main,
            .hero__title-last,
            .hero--gallery .hero-meta {
        transition: none;
    }

    .logo-mark {
        animation: none;
    }

    .hero--gallery .hero-meta {
        animation: none;
        opacity: 1;
        transform: none;
    }
}

/* ---------- Sections ---------- */
section {
    padding: 120px var(--pad);
}

.hello-page {
    --hello-edge: clamp(8px, 1.2vw, 24px);
    position: relative;
    z-index: 1;
    isolation: isolate;
    display: flex;
    align-items: flex-start;
    width: 100%;
    min-height: 100vh;
    min-height: 100dvh;
    min-height: max(100vh, 100dvh);
    overflow: visible;
    padding: 10vh var(--hello-edge) clamp(40px, 6vh, 80px);
    color: var(--accent);
    cursor: none;
    background-color: #eef0ff;
    background-image: none;
    transition: --hello-white-progress 150ms ease;
}

/* Content boxes keep the heading, label and introduction in page flow. */
.hello-page__layout {
    display: grid;
    gap: clamp(24px, 3vh, 48px);
    width: 100%;
    min-width: 0;
}

.hello-page__heading {
    display: grid;
    gap: 12px;
    width: max-content;
    max-width: 100%;
}

.hello-page__label-box {
    justify-self: end;
}

.hello-page__body {
    display: flex;
    align-items: flex-start;
    gap: clamp(24px, 4vw, 76px);
    padding-left: calc(clamp(24px, 7vw, 132px) - var(--hello-edge));
    min-width: 0;
}

.hello-page__portrait-box {
    flex: 0 0 auto;
}

.hello-page__copy-box {
    flex: 1 1 0;
    min-width: 0;
}

body[data-theme="dark"] .hello-page {
    color: #d0f4ff;
    background-color: #051118;
}

body[data-theme="dark"] .hello-page::before {
    background: linear-gradient(
        to bottom,
        rgba(5, 17, 24, 0) 0%,
        rgba(5, 17, 24, 0.32) 32%,
        rgba(5, 17, 24, 0.76) 72%,
        #051118 100%
    );
}

body[data-theme="dark"] .hello-page__title,
body[data-theme="dark"] .hello-page__profile,
body[data-theme="dark"] .hello-page__orb {
    color: #d0f4ff;
}

body[data-theme="dark"] .hello-page__copy span {
    background-image: linear-gradient(135deg, var(--accent) 0, var(--accent) var(--hello-white-progress, 10%), var(--fg) var(--hello-white-progress, 10%), var(--fg) 100%);
}

.hello-page::before {
    position: absolute;
    z-index: 0;
    top: -50vh;
    right: 0;
    left: 0;
    height: 50vh;
    content: "";
    pointer-events: none;
    background: linear-gradient(
        to bottom,
        rgba(248, 248, 255, 0) 0%,
        rgba(248, 248, 255, 0.32) 32%,
        rgba(248, 248, 255, 0.76) 72%,
        #eef0ff 100%
    );
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 36%);
    mask-image: linear-gradient(to bottom, transparent 0%, #000 36%);
    opacity: var(--hero-frost-opacity, 0);
    backdrop-filter: blur(var(--hero-frost-blur, 0px));
    -webkit-backdrop-filter: blur(var(--hero-frost-blur, 0px));
    will-change: opacity, backdrop-filter;
}

.hello-page::after {
    position: absolute;
    z-index: -1;
    inset: 0;
    content: "";
    pointer-events: none;
    background: none;
}

.hello-page__title {
    position: relative;
    color: var(--accent);
    font-size: clamp(7rem, 18vw, 23rem);
    font-weight: 300;
    letter-spacing: -0.075em;
    line-height: 0.86;
    opacity: 0;
    transform: translateY(36px);
    transition: opacity 760ms ease, transform 760ms cubic-bezier(0.2, 0.7, 0.2, 1);
}

.hello-page__profile {
    display: block;
    color: var(--accent);
    font-size: clamp(0.65rem, 0.8vw, 0.85rem);
    letter-spacing: 0.02em;
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 760ms ease 100ms, transform 760ms cubic-bezier(0.2, 0.7, 0.2, 1) 100ms;
}

.hello-page__portrait {
    position: relative;
    z-index: 0;
    display: grid;
    width: calc(var(--hello-copy-height, 300px) * 2 / 3);
    aspect-ratio: 4 / 6;
    place-items: center;
    overflow: hidden;
    border: 2px solid var(--accent);
    border-radius: 0;
    background: linear-gradient(145deg, #d6fbff, #a9bbff 58%, #8b82d8);
    box-shadow: none;
    opacity: 0;
    transform: translateY(28px) scale(0.96);
    transition: opacity 760ms ease 140ms, transform 760ms cubic-bezier(0.2, 0.7, 0.2, 1) 140ms;
}

.hello-page__portrait svg {
    width: 72%;
    height: 72%;
    fill: rgba(21, 46, 255, 0.62);
}

.hello-page__orb {
    position: fixed;
    z-index: 101;
    top: -100px;
    left: -100px;
    display: grid;
    width: clamp(66px, 8vw, 132px);
    aspect-ratio: 1;
    place-items: center;
    border-radius: 50%;
    background: rgba(180, 237, 255, 0.38);
    border: 1px solid rgba(21, 46, 255, 0.22);
    color: var(--accent);
    font-size: 1rem;
    opacity: 0;
    pointer-events: none;
    transform: translate(-50%, -50%);
    transition: opacity 180ms ease;
    backdrop-filter: blur(9px);
}

.hello-page__orb.is-visible {
    opacity: 1;
}

.hello-page__copy {
    position: relative;
    z-index: 1;
    width: 100%;
    margin: 0;
    font-size: clamp(1.35rem, 2.7vw, 3.2rem);
    letter-spacing: -0.045em;
    line-height: 1.22;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 900ms ease 180ms, transform 900ms cubic-bezier(0.2, 0.7, 0.2, 1) 180ms;
}

.hello-page.is-entered .hello-page__title,
.hello-page.is-entered .hello-page__profile,
.hello-page.is-entered .hello-page__portrait,
.hello-page.is-entered .hello-page__copy {
    opacity: 1;
    transform: translateY(0);
}

.hello-page.is-entered .hello-page__portrait {
    transform: translateY(0) scale(1);
}

.hello-page__copy span {
    display: block;
    color: transparent;
    background-image: linear-gradient(135deg, var(--accent) 0, var(--accent) var(--hello-white-progress, 10%), var(--fg) var(--hello-white-progress, 10%), var(--fg) 100%);
    background-size: 100% 100%;
    background-position: left center;
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hello-page__copy em {
    font-family: var(--font-display);
    font-weight: 400;
}

body:has(.hello-page:hover) .cursor {
    opacity: 0 !important;
}

body:has(.hello-page) > footer {
    min-height: 100vh;
    min-height: 100dvh;
    min-height: max(100vh, 100dvh);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: clamp(28px, 6vh, 72px) var(--pad) clamp(20px, 3vh, 36px);
    border-top: 0;
}

body:has(.hero--gallery) > .home-snap-target {
    scroll-snap-align: start;
    scroll-snap-stop: normal;
}

body:has(.hero--gallery) > .home-snap-tall {
    scroll-snap-align: none;
}

body:has(.hero--gallery) > .home-scroll-hold {
    scroll-snap-align: none;
}

body:has(.hello-page) > footer .cta {
    margin-block: auto;
}

@media (max-width: 1200px) {
    .hello-page {
        --hello-edge: 18px;
        align-items: flex-start;
        min-height: 100vh;
        min-height: 100dvh;
        min-height: max(100vh, 100dvh);
        padding: 10vh var(--hello-edge) 40px;
    }

    .hello-page__body {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        gap: 28px;
        padding-left: 0;
    }

    .hello-page__title {
        font-size: clamp(7rem, 23vw, 12rem);
    }

    .hello-page__portrait {
        width: min(56vw, 280px);
    }

    .hello-page__copy {
        width: 100%;
        margin: 0;
        font-size: clamp(1.35rem, 5.4vw, 2.25rem);
        line-height: 1.28;
    }

    .hello-page {
        transition: --hello-white-progress 150ms ease;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .hello-page__title,
            .hello-page__profile,
            .hello-page__portrait,
            .hello-page__copy {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .hello-page__copy span {
        animation: none;
    }
}

@media (hover: none) {
    .hello-page__orb {
        display: none;
    }
}

.section-title {
    font-size: clamp(2rem, 5vw, 4rem);
    letter-spacing: -0.04em;
    margin-bottom: 48px;
}

.page-hero {
    padding-top: 180px;
}

.page-hero h1 {
    font-size: clamp(3rem, 9vw, 9rem);
    letter-spacing: -0.05em;
    line-height: 0.95;
}

/* Project list with hover preview */
.project {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 16px;
    align-items: end;
    padding: 32px 0;
    border-top: 1px solid var(--line);
    cursor: pointer;
    transition: padding 0.4s var(--ease);
}

.project:last-child {
    border-bottom: 1px solid var(--line);
}

.project:hover {
    padding-left: 24px;
}

.project h3 {
    font-size: clamp(1.8rem, 4vw, 3.5rem);
    letter-spacing: -0.04em;
}

.project p {
    color: var(--muted);
}

.project .open {
    color: var(--accent);
}

.project-thumb {
    position: fixed;
    width: 320px;
    height: 220px;
    border-radius: 10px;
    pointer-events: none;
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.8);
    transition: opacity 0.3s, transform 0.3s;
    z-index: 30;
}

.project-thumb.show {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

/* Playground grid */
.grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.card .thumb {
    aspect-ratio: 4 / 3;
    border-radius: 12px;
    margin-bottom: 12px;
    transition: transform 0.5s var(--ease);
}

.card:hover .thumb {
    transform: scale(0.97) rotate(-1deg);
}

.card p {
    color: var(--muted);
    font-size: 0.9rem;
}

/* Marquee */
.marquee {
    overflow: hidden;
    border-block: 1px solid var(--line);
    padding: 28px 0;
}

.marquee-track {
    display: flex;
    gap: 48px;
    width: max-content;
    animation: scroll 25s linear infinite;
}

.marquee-track span {
    font-size: clamp(2rem, 5vw, 4.5rem);
    letter-spacing: -0.04em;
    white-space: nowrap;
}

@keyframes scroll {
    to {
        transform: translateX(-50%);
    }
}

/* Accordion (FAQ) */
.faq-item {
    border-top: 1px solid var(--line);
}

.faq-q {
    width: 100%;
    background: none;
    border: 0;
    color: inherit;
    font: inherit;
    font-size: 1.4rem;
    text-align: left;
    padding: 24px 0;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
}

.faq-a {
    max-height: 0;
    overflow: hidden;
    color: var(--muted);
    transition: max-height 0.5s var(--ease);
}

.faq-a p {
    padding-bottom: 24px;
    max-width: 60ch;
}

.faq-item.open .faq-a {
    max-height: 200px;
}

.faq-item.open .plus {
    transform: rotate(45deg);
}

.plus {
    transition: transform 0.3s;
}

/* About / Contact */
.two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
}

.portrait {
    aspect-ratio: 3 / 4;
    border-radius: 16px;
    background: linear-gradient(135deg, #3a3a4a, #14141a);
}

form {
    display: grid;
    gap: 20px;
    max-width: 640px;
}

input,
textarea {
    -webkit-user-select: text;
    user-select: text;
}

input,
textarea {
    background: transparent;
    border: 0;
    border-bottom: 1px solid var(--line);
    color: var(--fg);
    font: inherit;
    padding: 14px 0;
    outline: none;
}

input:focus,
textarea:focus {
    border-color: var(--accent);
}

.btn {
    display: inline-block;
    background: var(--accent);
    color: #000;
    border: 0;
    padding: 16px 32px;
    border-radius: 999px;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.3s;
}

.btn:hover {
    transform: scale(1.05);
}

/* Footer */
footer {
    padding: 80px var(--pad) 32px;
    border-top: 1px solid var(--line);
}

footer .cta {
    font-size: clamp(2.5rem, 8vw, 8rem);
    letter-spacing: -0.05em;
    display: block;
    margin-bottom: 48px;
}

.foot-row {
    display: flex;
    justify-content: space-between;
    color: var(--muted);
    flex-wrap: wrap;
    gap: 12px;
}

/* Scroll reveal */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
}

.reveal.in {
    opacity: 1;
    transform: none;
}

/* Custom cursor */
.cursor {
    position: fixed;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: rgba(21, 46, 255, 0.48);
    border: 0;
    overflow: hidden;
    backdrop-filter: invert(1);
    -webkit-backdrop-filter: invert(1);
    pointer-events: none;
    z-index: 100;
    opacity: 0;
    transform: translate(-50%, -50%);
    transition: width 0.25s, height 0.25s, opacity 0.15s;
}

.cursor.is-visible {
    opacity: 1;
}

.cursor.big,
.cursor.is-nav {
    width: clamp(32px, 3vw, 56px);
    height: clamp(32px, 3vw, 56px);
    background: rgba(21, 46, 255, 0.58);
}

.cursor.is-nav {
    border: 1.5px solid var(--accent);
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}

.page-loader {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    --loader-logo-size: clamp(32px, 4vw, 56px);
    --loader-edge: clamp(22px, 4.5vh, 56px);
    background: var(--accent);
    color: #eef0ff;
    opacity: 1;
    transform: translateY(0);
    transition: transform 0.5s cubic-bezier(0.65, 0, 0.35, 1),
    visibility 0s linear 0.5s;
}

.page-loader__name {
    position: absolute;
    z-index: 1;
    left: 50%;
    top: 0;
    display: block;
    transform: translateX(-50%);
    opacity: 1;
    white-space: nowrap;
    font-family: var(--font-display);
    font-size: clamp(48px, 8vw, 160px);
    font-weight: 400;
    letter-spacing: 0;
    line-height: 1;
}

body:has(.page-loader):not(.hero-ready) .hero__title-main,
body:has(.page-loader):not(.hero-ready) .hero__title-last,
body:has(.page-loader):not(.hero-ready) .hero--gallery .hero-meta {
    opacity: 0;
    translate: 0 max(48px, 100vh);
}

body.hero-transitioning .hero--gallery .hero__composition {
    opacity: 0 !important;
    visibility: hidden !important;
}

.page-loader__progress {
    position: absolute;
    right: calc(var(--loader-edge) + var(--loader-logo-size) + clamp(12px, 2vw, 24px));
    bottom: calc(var(--loader-edge) + var(--loader-logo-size) / 2 - 2px);
    left: clamp(20px, 4vw, 64px);
    height: 4px;
    --loader-duration: 1.5s;
}

.page-loader__track {
    position: absolute;
    inset: 0;
    height: 4px;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(248, 248, 255, 0.42);
}

.page-loader__fill {
    display: block;
    width: 0;
    height: 100%;
    border-radius: inherit;
    background: #eef0ff;
    transition: width 0.24s cubic-bezier(0.22, 1, 0.36, 1);
}

.page-loader__percent {
    position: absolute;
    top: -24px;
    left: 0;
    transform: translateX(-100%);
    transition: left 0.24s cubic-bezier(0.22, 1, 0.36, 1);
    font-family: "Martian Mono", "Courier New", monospace;
    font-size: clamp(9px, 1vw, 13px);
    letter-spacing: 0.12em;
}

.page-loader__logo {
    position: absolute;
    right: var(--loader-edge);
    bottom: var(--loader-edge);
    width: var(--loader-logo-size);
    height: var(--loader-logo-size);
    transform: rotate(0deg);
    transition: transform 0.03s linear;
}

.page-loader__logo.is-complete {
    transition: none;
}

.page-loader.is-loaded {
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-100%);
}

.page-loader__logo.is-complete {
    animation-play-state: paused;
}

@media (prefers-reduced-motion: reduce) {
    .page-loader__logo {
        transition: none;
    }

    .page-loader__fill,
            .page-loader__percent {
        transition: none;
    }
}

@media (max-width: 1200px), (orientation: portrait) {
    .page-loader__name {
        font-size: clamp(24px, min(calc(10vw + 3vh), 12vw), 88px);
    }
}

/* Responsive */
@media (max-width: 700px) {
    .grid,
            .two-col,
            .menu {
        grid-template-columns: 1fr;
    }

    .menu-preview {
        display: none;
    }

    .project-thumb {
        display: none;
    }

    .cursor {
        display: none;
    }
}

