*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

:root {
  --bg: #08090a;
  --text: #f4f6f7;
  --muted: #9aa4ac;
  --faint: #7f8a93;
  --footer: #4a5158;
  --line: rgba(232,234,237,0.18);
  --line-soft: rgba(232,234,237,0.22);
  --hover-line: rgba(232,234,237,0.5);
  --hover-fill: rgba(232,234,237,0.07);
  --fill: rgba(232,234,237,0.02);
  --accent: #64d2c0;
  --accent-glow: rgba(100,210,192,0.8);
  --glow-1: rgba(120,150,180,0.10);
  --glow-2: rgba(90,120,150,0.07);
  --portrait-filter: grayscale(0.15) contrast(1.03);
  --portrait-mask: radial-gradient(120% 100% at 50% 40%, #000 55%, transparent 100%);
  --portrait-border: 1px solid transparent;
  --portrait-shadow: none;
}

[data-theme="light"] {
  --bg: #f4f4f2;
  --text: #16181a;
  --muted: #5c646b;
  --faint: #6d757c;
  --footer: #9aa1a7;
  --line: rgba(22,24,26,0.18);
  --line-soft: rgba(22,24,26,0.22);
  --hover-line: rgba(22,24,26,0.5);
  --hover-fill: rgba(22,24,26,0.06);
  --fill: rgba(22,24,26,0.02);
  --accent: #12897a;
  --accent-glow: rgba(18,137,122,0.5);
  --glow-1: rgba(90,120,150,0.10);
  --glow-2: rgba(90,120,150,0.06);
  --portrait-filter: grayscale(0.1) contrast(1.02) brightness(1.02);
  --portrait-mask: linear-gradient(#000, #000);
  --portrait-border: 1px solid rgba(22,24,26,0.12);
  --portrait-shadow: 0 18px 40px -24px rgba(22,24,26,0.45);
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Space Grotesk', system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
  transition: background 0.4s ease, color 0.4s ease;
}

a { color: var(--text); }

.stage {
  position: relative;
  overflow: hidden;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: 56px 24px 72px;
}

.glow { position: absolute; inset: 0; pointer-events: none; }
.glow-top { background: radial-gradient(70% 55% at 50% 0%, var(--glow-1), transparent 70%); }
.glow-corner { background: radial-gradient(40% 40% at 85% 95%, var(--glow-2), transparent 70%); }

.theme-toggle {
  position: absolute;
  top: 22px;
  right: 22px;
  z-index: 2;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: var(--fill);
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.25s ease, background 0.25s ease;
}

.theme-toggle:hover, .theme-toggle:focus-visible {
  border-color: var(--hover-line);
  background: var(--hover-fill);
  outline: none;
}

.theme-toggle svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.4;
  stroke-linecap: round;
}

.layout {
  position: relative;
  width: 100%;
  max-width: 980px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: clamp(32px, 6vw, 76px);
  animation: fadeIn 0.9s ease both;
}

.portrait {
  flex: 0 0 auto;
  width: clamp(190px, 40vw, 300px);
  animation: riseIn 1s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.portrait img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 3px;
  filter: var(--portrait-filter);
  border: var(--portrait-border);
  box-shadow: var(--portrait-shadow);
  transition: box-shadow 0.4s ease, border-color 0.4s ease;
  -webkit-mask-image: var(--portrait-mask);
  mask-image: var(--portrait-mask);
}

.intro {
  flex: 1 1 340px;
  min-width: 280px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 26px;
  animation: riseIn 1s 0.08s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--faint);
}

.dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent-glow);
}

h1 {
  margin: 0;
  font-size: clamp(44px, 8.5vw, 82px);
  font-weight: 500;
  line-height: 0.95;
  letter-spacing: -0.035em;
  color: var(--text);
}

.blurb {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: 42ch;
}

.intro p {
  margin: 0;
  font-size: clamp(15px, 1.5vw, 17px);
  line-height: 1.65;
  color: var(--muted);
  text-wrap: pretty;
}

.intro .note {
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--footer);
}

.rule {
  width: 100%;
  max-width: 340px;
  height: 1px;
  background: linear-gradient(90deg, var(--line-soft), transparent);
}

.cta {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 14px 22px;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: var(--fill);
  text-decoration: none;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  transition: border-color 0.25s ease, background 0.25s ease, transform 0.25s ease;
}

.cta:hover, .cta:focus-visible {
  border-color: var(--hover-line);
  background: var(--hover-fill);
  transform: translateY(-1px);
  outline: none;
}

.cta svg { width: 15px; height: 15px; fill: currentColor; }

.footer {
  position: absolute;
  bottom: 22px;
  left: 0;
  right: 0;
  text-align: center;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--footer);
}

@keyframes riseIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

@media (prefers-reduced-motion: reduce) {
  .layout, .portrait, .intro { animation: none; }
}
