:root {
  --black: #000000;
  --white: #ffffff;
  --white-soft: rgba(255, 255, 255, .72);
  --oxblood: #6d0f1c;
  /* Oxblood lifted just enough to stay legible as small text on black. */
  --oxblood-text: #b0303f;
  --sans: "Jost", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: "Cormorant Garamond", "Iowan Old Style", Georgia, serif;
  --ease: cubic-bezier(.22, .61, .36, 1);
  --pad: clamp(20px, 4vw, 64px);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--sans);
  font-weight: 300;
  color: var(--white);
  background: var(--black);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

/* ---------- Hero shell ---------- */

.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  overflow: hidden;
  background: var(--black);
}

.hero::after {
  /* Faint oxblood warmth behind the character; the page itself stays black. */
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(ellipse 52% 60% at 63% 52%, rgba(109, 15, 28, .38) 0%, rgba(109, 15, 28, 0) 100%);
}

.hero > * { position: relative; z-index: 1; }
.hero::after { z-index: 0; }

/* ---------- Navigation ---------- */

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 26px var(--pad);
}

.nav__brand {
  font-family: var(--serif);
  font-size: 28px;
  font-weight: 500;
  letter-spacing: .01em;
  line-height: 1;
}

.nav__links {
  display: flex;
  gap: clamp(18px, 2.4vw, 36px);
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 15px;
  font-weight: 300;
  letter-spacing: .04em;
}

.nav__links a {
  position: relative;
  padding: 6px 0;
  opacity: .78;
  transition: opacity .3s var(--ease);
}

.nav__links a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .4s var(--ease);
}

.nav__links a:hover { opacity: 1; }
.nav__links a:hover::after { transform: scaleX(1); }

/* ---------- Body layout ---------- */

.hero__body {
  display: grid;
  grid-template-columns: minmax(230px, .34fr) 1fr;
  align-items: center;
  gap: clamp(20px, 3vw, 56px);
  padding: 0 var(--pad);
  min-height: 0;
}

/* ---------- Intro note ---------- */

.intro { max-width: 340px; }

.intro__note {
  margin: 0;
  font-weight: 400;
  display: grid;
  gap: 6px;
}

.intro__hello {
  font-size: 16px;
  font-weight: 300;
  letter-spacing: .06em;
  color: var(--oxblood-text);
}

.intro__name {
  font-family: var(--serif);
  font-size: clamp(44px, 4.6vw, 68px);
  font-weight: 500;
  line-height: .98;
  letter-spacing: -.01em;
}

.intro__role {
  margin-top: 8px;
  font-size: 17px;
  line-height: 1.5;
  font-weight: 300;
  color: var(--white-soft);
  max-width: 24ch;
}

.hint {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 34px 0 0;
  font-size: 15px;
  font-weight: 300;
  letter-spacing: .04em;
  color: var(--oxblood-text);
}

.hint__cursor {
  display: inline-grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  color: var(--white);
  background: var(--oxblood);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .12);
}

.hint__cursor svg { animation: cursor-drift 3.2s var(--ease) infinite; }

@keyframes cursor-drift {
  0%, 100% { transform: translate(-4px, 1px); }
  50%      { transform: translate(4px, -1px); }
}

.hint__text--touch { display: none; }

/* Three ticks that mirror the active interaction zone. */
.zones {
  display: flex;
  gap: 6px;
  margin-top: 16px;
}

.zones i {
  width: 26px;
  height: 2px;
  border-radius: 2px;
  background: rgba(255, 255, 255, .2);
  transition: background .35s var(--ease), width .35s var(--ease);
}

.hero[data-zone="left"] .zones [data-z="left"],
.hero[data-zone="center"] .zones [data-z="center"],
.hero[data-zone="right"] .zones [data-z="right"] {
  width: 40px;
  background: var(--oxblood-text);
}

/* ---------- Character stage ---------- */

.stage {
  position: relative;
  justify-self: center;
  width: min(100%, calc((100vh - 215px) * 16 / 9));
  width: min(100%, calc((100svh - 215px) * 16 / 9));
  aspect-ratio: 16 / 9;
}

.stage::before {
  /* Soft oxblood glow focused behind the character. */
  content: "";
  position: absolute;
  inset: -10% -7%;
  background: radial-gradient(closest-side, rgba(109, 15, 28, .55) 50%, rgba(109, 15, 28, 0) 100%);
  filter: blur(34px);
  pointer-events: none;
}

.stage__frame {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: clamp(18px, 2vw, 30px);
  overflow: hidden;
  background: #17110f url("../assets/frames/frame_0030.webp") center / cover no-repeat;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, .14),
    0 0 0 9px rgba(255, 255, 255, .04),
    0 44px 90px -36px rgba(109, 15, 28, .8);
}

.stage__canvas {
  display: block;
  width: 100%;
  height: 100%;
}

/* ---------- Contextual message ---------- */

.bubble {
  position: absolute;
  top: 0;
  left: 50%;
  margin: 0;
  padding: 9px 16px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 400;
  letter-spacing: .02em;
  white-space: nowrap;
  color: var(--oxblood);
  background: var(--white);
  box-shadow: 0 10px 28px -10px rgba(0, 0, 0, .7);
  opacity: 0;
  transform: translate(-50%, -30%) scale(.96);
  transition: opacity .28s var(--ease), transform .28s var(--ease);
  pointer-events: none;
}

.bubble.is-on {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.bubble[data-side="left"]  { left: 18%; }
.bubble[data-side="right"] { left: 82%; }

/* ---------- Portfolio cue ---------- */

.cue {
  justify-self: center;
  display: grid;
  justify-items: center;
  gap: 10px;
  padding: 18px 0 22px;
  font-size: 13px;
  font-weight: 300;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--white);
}

.cue__line {
  position: relative;
  width: 1px;
  height: 30px;
  background: rgba(255, 255, 255, .18);
  overflow: hidden;
}

.cue__line::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--oxblood-text);
  animation: cue-drop 2.4s var(--ease) infinite;
}

@keyframes cue-drop {
  0%   { transform: translateY(-100%); }
  60%, 100% { transform: translateY(100%); }
}

/* ---------- Mobile: centre experience only ---------- */

@media (max-width: 820px) {
  .hero::after {
    background: radial-gradient(ellipse 110% 42% at 50% 60%, rgba(109, 15, 28, .38) 0%, rgba(109, 15, 28, 0) 100%);
  }

  .nav { padding: 20px var(--pad); }
  .nav__brand { font-size: 24px; }
  .nav__links { font-size: 14px; gap: 16px; }

  .hero__body {
    grid-template-columns: 1fr;
    align-content: center;
    gap: 34px;
    padding: 12px 16px 0;
  }

  .intro {
    max-width: none;
    text-align: center;
    justify-self: center;
  }

  .intro__note { justify-items: center; }
  .intro__name { font-size: clamp(40px, 12vw, 54px); }
  .intro__role { max-width: 30ch; }
  .hint { margin-top: 20px; }
  .zones { display: none; }

  .stage {
    width: min(100%, 560px);
    aspect-ratio: 4 / 3;
  }

  .bubble[data-side] { left: 50%; }
}

@media (hover: none) {
  .hint__text--pointer { display: none; }
  .hint__text--touch { display: inline; }
  .hint__cursor svg { animation-name: cursor-tap; }
}

@keyframes cursor-tap {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(.82); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hint__cursor svg, .cue__line::after { animation: none; }
}
