:root {
  --bg: oklch(0.985 0.004 75);
  --surface: oklch(0.96 0.004 75);
  --text: oklch(0.20 0.005 60);
  --muted: oklch(0.50 0.008 60);
  --line: oklch(0.88 0.004 75);
  --accent: oklch(0.62 0.12 45);
  --font-display: 'Cormorant Garamond', 'Times New Roman', serif;
  --font-body: 'Inter', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

.site {
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  transition: background 220ms ease, color 220ms ease;
}

/* ───── shared rhythm ───── */
.section,
.hero-inner,
.header-inner,
.footer-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 48px;
}

.site[data-align="center"] .section,
.site[data-align="center"] .hero-inner {
  text-align: center;
}
.site[data-align="center"] .section-label {
  justify-content: center;
}
.site[data-align="center"] .services {
  justify-items: center;
}
.site[data-align="center"] .project {
  justify-content: center;
}

/* ───── header ───── */
.header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: color-mix(in oklch, var(--bg) 92%, transparent);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.logo {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--text);
}
.logo-bracket {
  color: var(--accent);
  transition: transform 220ms cubic-bezier(0.2, 0.7, 0.2, 1);
  display: inline-block;
}
.logo-bracket:first-child { margin-right: 4px; }
.logo-bracket:last-child  { margin-left: 4px; }
.logo:hover .logo-bracket:first-child { transform: translateX(-2px); }
.logo:hover .logo-bracket:last-child  { transform: translateX(2px); }
.logo-text { display: inline-block; }
.nav {
  display: flex;
  gap: 32px;
}
.nav a {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--muted);
  position: relative;
  padding: 4px 0;
  white-space: nowrap;
  transition: color 160ms ease;
}
.nav a:hover { color: var(--text); }
.nav a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 220ms ease;
}
.nav a:hover::after { transform: scaleX(1); }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0;
  width: 36px;
  height: 36px;
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  transition: border-color 160ms ease;
}
.nav-toggle:hover { border-color: color-mix(in oklch, var(--text) 30%, var(--line)); }
.nav-toggle span {
  display: block;
  width: 16px;
  height: 1.5px;
  background: var(--text);
  border-radius: 1px;
  transition: transform 220ms cubic-bezier(0.2, 0.7, 0.2, 1), opacity 160ms ease;
  transform-origin: center;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(6.5px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-6.5px) rotate(-45deg);
}

/* ───── hero ───── */
.hero {
  position: relative;
  padding: 160px 0 140px;
  border-bottom: 1px solid var(--line);
  overflow: hidden;
  --mx: 0;
  --my: 0;
}

.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}
.hero-grid {
  position: absolute;
  inset: -2px;
  background-image:
    linear-gradient(to right, color-mix(in oklch, var(--text) 6%, transparent) 1px, transparent 1px),
    linear-gradient(to bottom, color-mix(in oklch, var(--text) 6%, transparent) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 80% 70% at 30% 40%, black 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 30% 40%, black 30%, transparent 75%);
  opacity: 0.65;
  animation: drift 32s linear infinite;
  transform: translate3d(calc(var(--mx) * -16px), calc(var(--my) * -16px), 0);
  transition: transform 600ms cubic-bezier(0.2, 0.7, 0.2, 1);
}
.hero-glow {
  position: absolute;
  width: 520px; height: 520px;
  top: -120px; right: -160px;
  border-radius: 50%;
  background: radial-gradient(circle, color-mix(in oklch, var(--accent) 22%, transparent) 0%, transparent 65%);
  filter: blur(20px);
  animation: float 14s ease-in-out infinite;
  transform: translate3d(calc(var(--mx) * 40px), calc(var(--my) * 40px), 0);
  transition: transform 800ms cubic-bezier(0.2, 0.7, 0.2, 1);
}
.hero-glow-2 {
  width: 380px; height: 380px;
  top: auto; right: auto;
  bottom: -120px; left: -100px;
  background: radial-gradient(circle, color-mix(in oklch, var(--accent) 14%, transparent) 0%, transparent 65%);
  animation: float 18s ease-in-out -6s infinite reverse;
  transform: translate3d(calc(var(--mx) * -30px), calc(var(--my) * -30px), 0);
}
@keyframes drift {
  from { background-position: 0 0; }
  to   { background-position: 64px 64px; }
}
@keyframes float {
  0%, 100% { transform: translate(0, 0) scale(1); opacity: 0.9; }
  50%      { transform: translate(-30px, 20px) scale(1.08); opacity: 1; }
}

.hero-inner { position: relative; z-index: 1; }

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 40px;
  padding: 6px 14px 6px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: color-mix(in oklch, var(--bg) 60%, transparent);
  backdrop-filter: blur(6px);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  animation: fadeUp 700ms cubic-bezier(0.2, 0.7, 0.2, 1) both;
}
.hero-eyebrow-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 0 color-mix(in oklch, var(--accent) 50%, transparent);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 color-mix(in oklch, var(--accent) 50%, transparent); }
  50%      { box-shadow: 0 0 0 6px color-mix(in oklch, var(--accent) 0%, transparent); }
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.rotator {
  display: inline-flex; align-items: center; gap: 6px;
}
.rotator-prefix { color: var(--accent); }
.rotator-text {
  display: inline-block;
  color: var(--text);
  white-space: nowrap;
  transition: opacity 240ms ease, transform 240ms cubic-bezier(0.2, 0.7, 0.2, 1), filter 240ms ease;
}
.rotator-text.is-changing {
  opacity: 0;
  transform: translateY(40%);
  filter: blur(4px);
}

.word {
  display: inline-block;
  opacity: 0;
  transform: translateY(0.4em);
  filter: blur(6px);
  animation: wordIn 720ms cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
}
@keyframes wordIn {
  to { opacity: 1; transform: translateY(0); filter: blur(0); }
}

.clock {
  display: inline-flex; align-items: center; gap: 6px;
  font-variant-numeric: tabular-nums;
}
.clock-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent);
  animation: pulseDot 2s ease-in-out infinite;
}
.clock-sec { color: var(--line); }
@keyframes pulseDot {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0.35; }
}

.marquee {
  position: absolute;
  left: 0; right: 0; bottom: 24px;
  z-index: 1;
  overflow: hidden;
  pointer-events: none;
  mask-image: linear-gradient(to right, transparent, black 8%, black 92%, transparent);
  -webkit-mask-image: linear-gradient(to right, transparent, black 8%, black 92%, transparent);
}
.marquee-track {
  display: inline-flex;
  white-space: nowrap;
  animation: marquee 38s linear infinite;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  opacity: 0.7;
}
.marquee-item {
  display: inline-flex; align-items: center; gap: 14px;
  padding-right: 28px;
}
.marquee-bullet { color: var(--accent); font-size: 6px; }
@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

.service {
  animation: fadeUp 700ms cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

@media (prefers-reduced-motion: reduce) {
  .word { animation: none; opacity: 1; transform: none; filter: none; }
  .hero-grid, .hero-glow, .clock-dot, .hero-eyebrow-dot { animation: none; }
  .hero-grid, .hero-glow { transform: none !important; }
  .marquee-track { animation: none; }
  .rotator-text { transition: none; }
  .rotator-text.is-changing { opacity: 1; transform: none; filter: none; }
  .section-index, .section-line::after, .service, .hero-eyebrow { animation: none; }
}
.availability {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 56px;
  padding: 6px 12px 6px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
}
.dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 0 color-mix(in oklch, var(--accent) 50%, transparent);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 color-mix(in oklch, var(--accent) 50%, transparent); }
  50%      { box-shadow: 0 0 0 6px color-mix(in oklch, var(--accent) 0%, transparent); }
}

.display {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(36px, 5.6vw, 72px);
  line-height: 1.1;
  letter-spacing: -0.015em;
  margin-bottom: 48px;
  max-width: 920px;
  text-wrap: balance;
}
.site[data-align="center"] .display { margin-left: auto; margin-right: auto; }

.lede {
  font-family: var(--font-body);
  font-size: 22px;
  line-height: 1.45;
  max-width: 640px;
  color: var(--text);
  text-wrap: pretty;
  margin-bottom: 48px;
}
.site[data-align="center"] .lede { margin-left: auto; margin-right: auto; }

.hero-meta {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}
.site[data-align="center"] .hero-meta { justify-content: center; }

.meta {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--muted);
  text-transform: uppercase;
}
.meta-sep { color: var(--line); }

/* ───── section label ───── */
.section { padding-top: 120px; padding-bottom: 120px; border-bottom: 1px solid var(--line); }
.section-label {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 64px;
}
.section-index {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--accent);
  display: inline-block;
  animation: indexIn 600ms cubic-bezier(0.2, 0.7, 0.2, 1) both;
}
@keyframes indexIn {
  from { opacity: 0; transform: translateX(-6px); }
  to   { opacity: 1; transform: translateX(0); }
}
.section-line {
  flex: 0 0 48px;
  height: 1px;
  background: var(--line);
  position: relative;
  overflow: hidden;
}
.section-line::after {
  content: "";
  position: absolute; inset: 0;
  background: var(--accent);
  transform: translateX(-100%);
  animation: lineSweep 1.4s cubic-bezier(0.2, 0.7, 0.2, 1) 0.2s both;
}
@keyframes lineSweep {
  0%   { transform: translateX(-100%); }
  60%  { transform: translateX(0); }
  100% { transform: translateX(100%); }
}
.section-title {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ───── services ───── */
.services {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px;
}
.service {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  position: relative;
  transition: transform 320ms cubic-bezier(0.2, 0.7, 0.2, 1);
}
.service::before {
  content: "";
  position: absolute;
  top: -1px; left: 0;
  height: 1px; width: 0;
  background: var(--accent);
  transition: width 480ms cubic-bezier(0.2, 0.7, 0.2, 1);
}
.service:hover { transform: translateY(-2px); }
.service:hover::before { width: 48px; }
.service-no {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.08em;
}
.service-title {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.15;
}
.service-desc {
  font-size: 15px;
  line-height: 1.55;
  color: var(--muted);
  text-wrap: pretty;
}

/* ───── projects ───── */
.projects {
  list-style: none;
  display: flex;
  flex-direction: column;
}
.project {
  display: grid;
  grid-template-columns: 80px 1.2fr 1fr 1.5fr;
  gap: 32px;
  padding: 28px 0;
  border-top: 1px solid var(--line);
  align-items: baseline;
}
.project:last-child { border-bottom: 1px solid var(--line); }

.project-year {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.04em;
}
.project-client {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 400;
  letter-spacing: -0.01em;
}
.project-kind {
  font-size: 14px;
  color: var(--accent);
}
.project-note {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.5;
}

.footnote {
  margin-top: 32px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.02em;
}

/* ───── about ───── */
.about {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  max-width: 880px;
}
.site[data-align="center"] .about {
  margin-left: auto;
  margin-right: auto;
}
.prose {
  font-family: var(--font-display);
  font-size: 24px;
  line-height: 1.4;
  font-weight: 400;
  letter-spacing: -0.005em;
  text-wrap: pretty;
}
.prose.muted {
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--muted);
  line-height: 1.65;
  letter-spacing: 0;
}

/* ───── contact ───── */
.contact-grid {
  display: flex;
  flex-direction: column;
}
.contact-row {
  display: grid;
  grid-template-columns: 120px 1fr 24px;
  gap: 24px;
  align-items: center;
  padding: 24px 0;
  border-top: 1px solid var(--line);
  transition: padding 220ms ease, color 160ms ease;
}
.contact-row:last-child { border-bottom: 1px solid var(--line); }
.contact-row:hover { padding-left: 8px; }
.contact-row:hover .contact-arrow { transform: translateX(4px); color: var(--accent); }

.contact-label {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.contact-value {
  font-family: var(--font-display);
  font-size: 24px;
  letter-spacing: -0.01em;
}
.contact-arrow {
  font-family: var(--font-mono);
  font-size: 18px;
  color: var(--muted);
  transition: transform 220ms ease, color 160ms ease;
  text-align: right;
}

/* ───── footer ───── */
.footer {
  padding: 32px 0 48px;
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 24px;
}

/* ───── responsive ───── */
@media (max-width: 760px) {
  .section, .hero-inner, .header-inner, .footer-inner {
    padding: 0 24px;
  }
  .hero { padding: 96px 0 80px; }
  .marquee { display: none; }
  .section { padding-top: 80px; padding-bottom: 80px; }
  .services { grid-template-columns: 1fr; gap: 32px; }
  .project {
    grid-template-columns: 1fr;
    gap: 6px;
  }
  .about { grid-template-columns: 1fr; gap: 24px; }
  .contact-row { grid-template-columns: 90px 1fr 20px; gap: 16px; }
  .contact-value { font-size: 18px; }
  .nav-toggle { display: inline-flex; }
  .hero-eyebrow .rotator { display: none; }
  .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    padding: 8px 24px 16px;
    background: color-mix(in oklch, var(--bg) 96%, transparent);
    backdrop-filter: saturate(140%) blur(8px);
    border-bottom: 1px solid var(--line);
  }
  .nav.is-open { display: flex; }
  .nav a { padding: 12px 0; font-size: 14px; }
  .nav a::after { display: none; }
  .footer-inner { flex-direction: column; gap: 8px; }
}
