/* =====================================================
   TOKENS
   ===================================================== */
:root {
   --c-bg:       #ffffff;          /* pure white hero */
   --c-fg:       #121212;
   --c-menu:     #0e0e0f;
   --c-menu-fg:  #ecebe4;
   --c-accent:   #ff5a1f;

   --ff-serif:   'Fraunces', Georgia, serif;
   --ff-display: 'Anton', 'Arial Black', sans-serif;   /* heavy condensed sans for hero */
   --ff-sans:    'Inter', system-ui, sans-serif;
   --ease:       cubic-bezier(0.76, 0, 0.24, 1);
}

/* =====================================================
   RESET
   ===================================================== */
*, *::before, *::after {
   box-sizing: border-box;
   margin: 0;
   padding: 0;
}

html, body {
   height: 100%;
   overflow: hidden;
}

body {
   background: var(--c-bg);
   color: var(--c-fg);
   font-family: var(--ff-sans);
   font-size: 15px;
   -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button {
   font: inherit;
   color: inherit;
   background: none;
   border: 0;
   cursor: pointer;
}
img { display: block; max-width: 100%; }
em { font-style: italic; }

/* =====================================================
   HEADER — z-index above menu so toggle always clickable
   ===================================================== */
.header {
   position: fixed;
   top: 0;
   left: 0;
   right: 0;
   z-index: 50;
   display: flex;
   justify-content: space-between;
   align-items: center;
   padding: 28px 40px;

   transition-property: color;
   transition-duration: 0.5s;
   transition-timing-function: var(--ease);
   transition-delay: 0.4s; /* delay when class is removed */
}

body.is-open .header {
   color: var(--c-menu-fg);
   transition-delay: 0.3s; /* delay when class is added */
}

.brand {
   font-family: var(--ff-serif);
   font-size: 26px;
   font-weight: 400;
   letter-spacing: -0.01em;
   color: inherit;
}

.brand span {
   font-style: italic;
   color: var(--c-accent);
}

/* =====================================================
   TOGGLE — circular button with gooey hover
   ===================================================== */
.toggle {
   position: relative;
   width: 72px;
   height: 72px;
   border-radius: 50%;
   background: var(--c-fg);
   color: var(--c-bg);
   transition: border-radius 0.5s var(--ease),
               background 0.5s var(--ease);
}

.toggle:hover {
   border-radius: 48% 52% 42% 58% / 55% 44% 56% 45%;
   background: var(--c-accent);
}

body.is-open .toggle {
   background: var(--c-menu-fg);
   color: var(--c-menu);
}

.toggle__inner {
   position: absolute;
   inset: 0;
   display: flex;
   flex-direction: column;
   justify-content: center;
   align-items: center;
   gap: 5px;
}

/* Three asymmetric horizontal lines (hamburger icon).
   Each line uses currentColor so it inverts with the
   toggle's color state automatically. */
.toggle__line {
   display: block;
   height: 1.5px;
   background: currentColor;
   border-radius: 2px;
   transition: width 0.5s var(--ease),
               transform 0.5s var(--ease),
               opacity 0.4s var(--ease);
}

.toggle__line:nth-child(1) { width: 22px; }
.toggle__line:nth-child(2) { width: 14px; }    /* middle is shorter */
.toggle__line:nth-child(3) { width: 18px; }

/* When menu is open → the 3 lines become a + (plus sign):
   - middle line stays horizontal, grows to full width
   - top line rotates -90deg and overlaps middle → becomes vertical bar
   - bottom line fades away */
body.is-open .toggle__line:nth-child(1) {
   width: 22px;
   transform: translateY(8.5px) rotate(-90deg);
}
body.is-open .toggle__line:nth-child(2) {
   width: 22px;
}
body.is-open .toggle__line:nth-child(3) {
   opacity: 0;
   transform: translateY(-2px);
}

/* =====================================================
   HERO
   ===================================================== */
.hero {
   position: relative;
   height: 100vh;
   display: grid;
   place-items: center;
   padding: 40px;
   background: var(--c-bg);
}

/* Hero background image removed from the visible layout — kept
   in DOM but hidden so the HTML stays intact. */
.hero__bg {
   display: none;
}

/* Title uses the heavy condensed display font for a big punchy
   look, with an italic serif word for contrast. */
.hero__title {
   font-family: var(--ff-display);
   font-weight: 400;
   font-size: clamp(88px, 16vw, 260px);
   line-height: 0.88;
   letter-spacing: -0.02em;
   text-transform: uppercase;
   color: var(--c-fg);
   text-align: center;
}

/* The italic word uses the serif — mixed styles = awwwards editorial */
.hero__title em {
   font-family: var(--ff-serif);
   font-style: italic;
   font-weight: 400;
   text-transform: none;
   letter-spacing: -0.03em;
   color: var(--c-accent);
}

/* =====================================================
   MENU OVERLAY
   Two-layer approach:
     .menu__svg    = dark fill clipped by the animated circle
     .menu__content = actual interactive HTML (also clipped to match)
   ===================================================== */
.menu {
   position: fixed;
   inset: 0;
   z-index: 30;
   pointer-events: none;
}

.menu.is-open { pointer-events: auto; }

.menu__svg {
   position: absolute;
   inset: 0;
   width: 100%;
   height: 100%;
   display: block;
}

.menu__fill {
   fill: var(--c-menu);
}

/* Content is clipped with CSS to the same animated circle
   (inline circle() function driven by JS variables). */
.menu__content {
   position: absolute;
   inset: 0;
   padding: 120px 40px 40px;
   display: flex;
   flex-direction: column;
   justify-content: center;
   color: var(--c-menu-fg);
   clip-path: circle(var(--cr, 0px) at var(--cx, 100%) var(--cy, 0%));
   will-change: clip-path;
}

/* =====================================================
   NAV — letters morph on hover
   ===================================================== */
.nav {
   flex: 1;
   display: flex;
   align-items: center;
   padding: 0 60px;
}

.nav__list {
   display: flex;
   flex-direction: column;
   gap: 10px;
   width: 100%;
}

.nav__item {
   /* overflow:hidden clips BOTH text layers inside this row —
      prevents the hover-translated text from bleeding into
      neighbouring rows (the bug on the previous screenshot). */
   overflow: hidden;
   border-top: 1px solid rgba(236, 235, 228, 0.12);
}

.nav__item:last-child {
   border-bottom: 1px solid rgba(236, 235, 228, 0.12);
}

.nav__link {
   display: grid;
   grid-template-columns: 60px 1fr;
   align-items: center;
   gap: 32px;
   padding: 22px 0;
   will-change: transform, opacity;
}

.nav__num {
   font-family: var(--ff-sans);
   font-size: 12px;
   letter-spacing: 0.06em;
   color: rgba(236, 235, 228, 0.5);
}

/* ─────── Link hover morph ───────
   Two text layers stacked inside a fixed-height wrapper
   (1em tall). On hover, wrapper translates up exactly 1em —
   so both layers move in lockstep (no overlap/drift).

   Wrapper            Visible
   ┌──────────┐
   │  Work    │  ← default (accent hidden below, out of frame)
   │  Work★   │  ← after hover → italic accent slides up
   └──────────┘                                                 */
.nav__text {
   position: relative;
   display: block;
   height: 1em;               /* fixed — equal to one line-height */
   line-height: 1;
   font-family: var(--ff-display);
   font-weight: 400;
   font-size: clamp(60px, 9vw, 128px);
   letter-spacing: -0.02em;
   text-transform: uppercase;
   overflow: hidden;
   transition: transform 0.6s var(--ease);
}

/* Default (main) text sits at 0 */
.nav__text__main {
   display: block;
}

/* Accent (italic serif) layer sits ONE line BELOW the main text.
   Not absolutely positioned — it flows after .nav__text__main
   so both occupy exactly 1em each, total 2em inside the wrapper. */
.nav__text__alt {
   display: block;
   font-family: var(--ff-serif);
   font-style: italic;
   text-transform: none;
   font-weight: 400;
   color: var(--c-accent);
}


/* =====================================================
   RESPONSIVE
   ===================================================== */
@media (max-width: 720px) {
   .header { padding: 16px 20px; }
   .toggle { width: 56px; height: 56px; }
   .nav { padding: 0 20px; }
   .nav__text { font-size: 52px; }
   .menu__content { padding: 100px 20px 20px; }
}
