:root {
  --bg: oklch(0.09 0 0);
  --panel: oklch(0.14 0 0);
  --panel-alt: oklch(0.17 0 0);
  --ink: oklch(0.97 0 0);
  --muted: oklch(0.67 0 0);
  --line: oklch(0.97 0 0 / 0.16);
  --accent: oklch(0.92 0 0);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "DM Sans", sans-serif;
}

.grain { display: none; }

.page-shell {
  position: relative;
  width: min(1120px, calc(100% - 48px));
  margin: auto;
}

.topbar {
  display: flex;
  justify-content: space-between;
  padding: 27px 0;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: .62rem;
  letter-spacing: .16em;
}

.hero {
  position: relative;
  min-height: calc(100vh - 78px);
  display: grid;
  place-items: center;
  padding: 80px 0 130px;
  overflow: hidden;
  text-align: center;
}

.hero-copy {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
}

.motion-ready .hero-copy.is-visible .logo-frame {
  animation: logo-arrival 1.3s var(--ease) both;
}

.motion-ready .hero-copy.is-visible .eyebrow,
.motion-ready .hero-copy.is-visible h1,
.motion-ready .hero-copy.is-visible .hero-intro,
.motion-ready .hero-copy.is-visible .scroll-link {
  animation: hero-rise 1s var(--ease) both;
}

.motion-ready .hero-copy.is-visible h1 { animation-delay: 140ms; }
.motion-ready .hero-copy.is-visible .hero-intro { animation-delay: 260ms; }
.motion-ready .hero-copy.is-visible .scroll-link { animation-delay: 360ms; }

.logo-frame {
  width: 150px;
  height: 150px;
  margin-bottom: 33px;
  overflow: hidden;
  border: 1px solid oklch(0.97 0 0 / .34);
  border-radius: 50%;
  background: oklch(0 0 0);
  box-shadow: 0 0 0 8px oklch(0.97 0 0 / .035), 0 20px 55px oklch(0 0 0 / .48);
}

.logo-frame img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.eyebrow {
  margin: 0 0 18px;
  color: var(--accent);
  font-size: .62rem;
  font-weight: 700;
  letter-spacing: .19em;
  text-transform: uppercase;
}

.hero h1,
h2,
h3 {
  font-family: Manrope, sans-serif;
  font-weight: 700;
  letter-spacing: -.08em;
  line-height: .9;
}

.hero h1 {
  margin: 0;
  font-size: clamp(4.8rem, 13vw, 10.8rem);
}

.hero h1 span,
h2 span { color: var(--ink); }

.hero-intro {
  max-width: 430px;
  margin: 27px 0 35px;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.6;
}

.scroll-link,
.card-link,
.founder-copy a {
  padding-bottom: 8px;
  border-bottom: 1px solid var(--accent);
  color: var(--ink);
  font-size: .65rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-decoration: none;
  text-transform: uppercase;
  transition: color .25s, border-color .25s;
}

.scroll-link:hover,
.card-link:hover,
.founder-copy a:hover { color: var(--muted); }

.businesses {
  padding: 120px 0 145px;
  border-top: 1px solid var(--line);
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  margin-bottom: 38px;
}

.section-heading h2,
.founder h2 {
  margin: 0;
  font-size: clamp(3.8rem, 8vw, 7.5rem);
}

.business-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.business-card {
  min-height: 315px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 26px;
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--ink);
  overflow: hidden;
  transition: transform .55s var(--ease), background .35s, box-shadow .55s var(--ease), border-color .35s;
}

.business-card:nth-child(2),
.business-card:nth-child(4) { background: var(--panel-alt); }
.business-card:nth-child(3) { background: var(--panel); }
.business-card:hover {
  transform: translateY(-12px) scale(1.015);
  background: oklch(0.2 0 0);
  border-color: oklch(0.97 0 0 / .4);
  box-shadow: 0 34px 75px oklch(0 0 0 / .48);
}

.card-number {
  color: var(--muted);
  font-size: .65rem;
  letter-spacing: .16em;
}

.business-card h3 {
  margin: 0 0 18px;
  font-size: clamp(2.4rem, 5vw, 4.7rem);
}

.business-card p {
  max-width: 290px;
  margin: 0;
  color: var(--muted);
  font-size: .88rem;
  line-height: 1.5;
}

.card-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-top: 30px;
}

.text-button,
.submit-button,
.dialog-close {
  border: 0;
  font: inherit;
  cursor: pointer;
}

.text-button {
  min-height: 44px;
  padding: 0 19px;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: var(--bg);
  font-size: .63rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  transition: transform .3s var(--ease), background .3s, color .3s;
}

.text-button:hover,
.text-button:focus-visible {
  transform: scale(1.08);
  background: transparent;
  color: var(--ink);
}

.founder {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12%;
  align-items: end;
  padding: 120px 0 145px;
  border-top: 1px solid var(--line);
}

.founder-copy { max-width: 390px; }
.founder-copy p {
  margin: 0 0 32px;
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.65;
}

.footer {
  display: flex;
  justify-content: space-between;
  padding: 25px 0 34px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: .6rem;
  letter-spacing: .14em;
}

.reveal { opacity: 1; transform: none; }
.motion-ready .reveal {
  opacity: 0;
  filter: blur(10px);
  transform: translateY(70px) scale(.94);
  transition: opacity 1s var(--ease), transform 1.15s var(--ease), filter 1s var(--ease);
}
.motion-ready .reveal.is-visible { opacity: 1; filter: blur(0); transform: none; }
.motion-ready .business-card[data-direction="left"] { transform: translateX(-95px) rotate(-2deg) scale(.92); }
.motion-ready .business-card[data-direction="right"] { transform: translateX(95px) rotate(2deg) scale(.92); }
.motion-ready .business-card.is-visible { transform: none; }
.motion-ready .business-card.is-visible:hover { transform: translateY(-12px) scale(1.015); }
.motion-ready .business-card:nth-child(2) { transition-delay: 80ms; }
.motion-ready .business-card:nth-child(3) { transition-delay: 160ms; }
.motion-ready .business-card:nth-child(4) { transition-delay: 240ms; }

.contact-dialog {
  width: min(620px, calc(100% - 30px));
  max-height: min(820px, calc(100dvh - 30px));
  padding: 0;
  border: 1px solid oklch(0.97 0 0 / .28);
  background: var(--panel);
  color: var(--ink);
  box-shadow: 0 50px 140px oklch(0 0 0 / .85);
  opacity: 0;
  transform: translateY(60px) scale(.86) rotate(-1.5deg);
  transition: opacity .3s ease, transform .55s var(--ease);
  overflow-y: auto;
}

.contact-dialog.is-open { opacity: 1; transform: none; }
.contact-dialog::backdrop {
  background: oklch(0 0 0 / .78);
  backdrop-filter: blur(0);
  transition: backdrop-filter .5s ease;
}
.contact-dialog.is-open::backdrop { backdrop-filter: blur(12px); }

.dialog-topline {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 24px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: .6rem;
  letter-spacing: .15em;
  text-transform: uppercase;
}

.dialog-close {
  padding: 6px 0;
  background: transparent;
  color: var(--ink);
  font-size: .6rem;
  font-weight: 700;
  letter-spacing: .15em;
  text-transform: uppercase;
}

.dialog-heading { padding: 38px 40px 22px; }
.dialog-heading h2 {
  margin: 0 0 18px;
  font-size: clamp(3.2rem, 10vw, 5.7rem);
}
.dialog-heading > p:last-child {
  max-width: 440px;
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.contact-form {
  display: grid;
  gap: 18px;
  padding: 14px 40px 42px;
}

.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.contact-form label {
  display: grid;
  gap: 8px;
  color: var(--accent);
  font-size: .63rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 0;
  outline: 0;
  background: oklch(0.1 0 0);
  color: var(--ink);
  font: 500 1rem/1.4 "DM Sans", sans-serif;
  text-transform: none;
  transition: border-color .25s, box-shadow .25s, transform .25s var(--ease);
}
.contact-form input { height: 52px; padding: 0 14px; }
.contact-form textarea { resize: vertical; min-height: 98px; padding: 14px; }
.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--ink);
  box-shadow: 0 0 0 4px oklch(0.97 0 0 / .1);
  transform: translateY(-2px);
}
.field-note { color: var(--muted); font-size: .58rem; font-weight: 500; letter-spacing: .06em; text-transform: none; }

.submit-button {
  min-height: 57px;
  margin-top: 6px;
  background: var(--ink);
  color: var(--bg);
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
  transition: transform .3s var(--ease), box-shadow .3s;
}
.submit-button:hover,
.submit-button:focus-visible {
  transform: translateY(-4px) scale(1.015);
  box-shadow: 0 18px 45px oklch(0 0 0 / .45);
}

@keyframes logo-arrival {
  0% { opacity: 0; filter: blur(18px); transform: translateY(80px) scale(.42) rotate(-12deg); }
  65% { opacity: 1; filter: blur(0); transform: translateY(-14px) scale(1.1) rotate(2deg); }
  100% { transform: none; }
}

@keyframes hero-rise {
  from { opacity: 0; filter: blur(12px); transform: translateY(55px) scale(.96); }
  to { opacity: 1; filter: blur(0); transform: none; }
}

@media (max-width: 700px) {
  .page-shell { width: min(100% - 30px, 1120px); }
  .topbar { font-size: .5rem; }
  .hero { min-height: calc(100svh - 70px); padding: 65px 0 100px; }
  .logo-frame { width: 122px; height: 122px; }
  .hero h1 { font-size: clamp(4rem, 18vw, 7rem); }
  .hero-intro { font-size: .9rem; }
  .businesses,
  .founder { padding: 90px 0 105px; }
  .section-heading { display: block; }
  .section-heading .eyebrow { margin-bottom: 25px; }
  .business-grid { grid-template-columns: 1fr; }
  .business-card { min-height: 265px; }
  .card-actions { align-items: flex-start; flex-direction: column; }
  .text-button { width: 100%; }
  .founder { display: block; }
  .founder-copy { margin-top: 48px; }
  .footer { flex-wrap: wrap; gap: 12px; }
  .footer span:last-child { width: 100%; }
  .dialog-heading { padding: 30px 24px 18px; }
  .contact-form { padding: 12px 24px 28px; }
  .field-row { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .motion-ready .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .motion-ready .hero-copy.is-visible .logo-frame,
  .motion-ready .hero-copy.is-visible .eyebrow,
  .motion-ready .hero-copy.is-visible h1,
  .motion-ready .hero-copy.is-visible .hero-intro,
  .motion-ready .hero-copy.is-visible .scroll-link { animation: none; }
  .contact-dialog { transition: none; }
}
