:root {
  --paper: #f3f4f0;
  --surface: #fafbf8;
  --ink: #101211;
  --muted: #686d68;
  --line: #d8dcd6;
  --cobalt: #8accf3;
  --cobalt-dark: #5baedc;
  --blue-ink: #2677a5;
  --display: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --serif: "Iowan Old Style", "Baskerville", Georgia, serif;
  --max: 1180px;
  --radius: 26px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--display);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

body.modal-open { overflow: hidden; }

a { color: inherit; text-decoration: none; }
img, video { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; }

:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--cobalt) 55%, white);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  left: 20px;
  top: -100px;
  z-index: 100;
  padding: 12px 16px;
  border-radius: 999px;
  background: var(--ink);
  color: white;
}

.skip-link:focus { top: 16px; }

.site-header {
  position: sticky;
  top: 18px;
  z-index: 50;
  width: min(calc(100% - 36px), var(--max));
  margin: 18px auto 0;
}

.nav-shell {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  padding: 10px 12px 10px 24px;
  border: 1px solid rgba(16, 18, 17, .07);
  border-radius: 24px;
  background: rgba(250, 251, 248, .9);
  box-shadow: 0 14px 40px rgba(30, 34, 31, .07);
  backdrop-filter: blur(18px);
}

.brand {
  font-family: var(--serif);
  font-size: clamp(1.25rem, 2vw, 1.55rem);
  letter-spacing: -.025em;
  white-space: nowrap;
}

.brand span { color: var(--cobalt); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-links > a {
  padding: 12px 14px;
  border-radius: 999px;
  color: #353936;
  font-size: .92rem;
  transition: background .2s ease, color .2s ease;
}

.nav-links > a:hover,
.nav-links > a[aria-current="page"] { background: #eceee9; color: var(--ink); }

.nav-cta,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 20px;
  border: 1px solid transparent;
  border-radius: 16px;
  background: var(--cobalt);
  color: var(--ink);
  font-weight: 650;
  transition: transform .2s ease, background .2s ease;
}

.nav-cta:hover,
.button:hover { transform: translateY(-2px); background: var(--cobalt-dark); }

.button.secondary { background: transparent; border-color: var(--line); color: var(--ink); }
.button.secondary:hover { background: var(--surface); }

.menu-toggle {
  display: none;
  width: 46px;
  height: 46px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: transparent;
  cursor: pointer;
}

.menu-toggle span {
  width: 18px;
  height: 1.5px;
  display: block;
  margin: 5px auto;
  background: var(--ink);
}

main { overflow: clip; }

.container { width: min(calc(100% - 40px), var(--max)); margin-inline: auto; }

.hero {
  min-height: calc(100vh - 100px);
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(380px, .92fr);
  align-items: center;
  gap: clamp(44px, 8vw, 100px);
  padding-block: clamp(72px, 10vw, 132px) 90px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 22px;
  color: var(--muted);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cobalt);
}

h1, h2, h3, p { margin-top: 0; }

h1 {
  max-width: 780px;
  margin-bottom: 26px;
  font-size: clamp(3.4rem, 7vw, 6.9rem);
  line-height: .92;
  letter-spacing: -.065em;
  font-weight: 600;
}

h1 .serif { font-family: var(--serif); font-weight: 400; font-style: italic; letter-spacing: -.05em; }

.hero-copy > p:not(.eyebrow) {
  max-width: 580px;
  color: var(--muted);
  font-size: clamp(1.04rem, 1.8vw, 1.25rem);
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }

.hero-visual {
  position: relative;
  min-height: 640px;
}

.phone-card {
  position: absolute;
  width: min(66%, 320px);
  aspect-ratio: 9 / 16;
  overflow: hidden;
  border: 7px solid var(--surface);
  border-radius: 34px;
  box-shadow: 0 30px 80px rgba(18, 23, 19, .18);
  background: #ddd;
}

.phone-card video { width: 100%; height: 100%; object-fit: cover; }
.phone-card:first-child { top: 0; right: 0; transform: rotate(3.5deg); }
.phone-card:last-child { left: 0; bottom: 0; transform: rotate(-5deg); }

.floating-label {
  position: absolute;
  z-index: 2;
  right: 4%;
  bottom: 7%;
  padding: 12px 16px;
  border-radius: 999px;
  background: var(--ink);
  color: white;
  font-size: .8rem;
  box-shadow: 0 14px 30px rgba(0,0,0,.16);
}

.section { padding-block: clamp(82px, 10vw, 140px); }
.section + .section { border-top: 1px solid var(--line); }

.section-head {
  display: grid;
  grid-template-columns: 1fr minmax(280px, 520px);
  gap: 50px;
  align-items: end;
  margin-bottom: clamp(40px, 6vw, 72px);
}

.section-head h2,
.page-hero h1 {
  margin: 0;
  font-size: clamp(2.6rem, 5.5vw, 5.5rem);
  line-height: .98;
  letter-spacing: -.055em;
  font-weight: 600;
}

.section-head p { margin: 0; color: var(--muted); font-size: 1.05rem; }

.service-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }

.service-card {
  min-height: 360px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(28px, 4vw, 48px);
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line);
}

.service-card:nth-child(2) { background: var(--ink); color: white; border-color: var(--ink); }
.service-card .index { color: var(--muted); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .78rem; }
.service-card:nth-child(2) .index, .service-card:nth-child(2) p { color: #aeb4af; }
.service-card h3 { margin-bottom: 16px; font-size: clamp(2rem, 4vw, 3.6rem); letter-spacing: -.05em; }
.service-card p { max-width: 430px; margin: 0; color: var(--muted); }

.home-work-grid,
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px 16px;
}

.portfolio-section + .portfolio-section { margin-top: clamp(90px, 12vw, 150px); }
.portfolio-section-head {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  align-items: end;
  gap: 40px;
  margin-bottom: 34px;
}
.portfolio-section-head .eyebrow { margin-bottom: 16px; }
.portfolio-section-head h2 { max-width: 700px; }
.portfolio-section-head > p { max-width: 520px; margin: 0 0 4px; color: var(--muted); }
.commercial-grid { grid-template-columns: repeat(2, 1fr); }
.commercial-card .work-media { aspect-ratio: 16 / 9; }

.work-card {
  position: relative;
  display: block;
  border: 0;
  padding: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.work-media {
  position: relative;
  aspect-ratio: 9 / 16;
  overflow: hidden;
  border-radius: 18px;
  background: #d8d8d4;
}

.work-media::after {
  content: "View project ↗";
  position: absolute;
  right: 14px;
  bottom: 14px;
  padding: 10px 13px;
  border-radius: 999px;
  background: rgba(250, 251, 248, .92);
  color: var(--ink);
  font-size: .76rem;
  font-weight: 700;
  transform: translateY(8px);
  opacity: 0;
  transition: .22s ease;
}

.work-card:hover .work-media::after,
.work-card:focus-visible .work-media::after { opacity: 1; transform: translateY(0); }
.work-media video { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.work-card:hover .work-media video { transform: scale(1.025); }

.work-meta { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 14px 2px 0; }
.work-meta strong { font-size: 1.05rem; letter-spacing: -.02em; }
.work-meta span { color: var(--muted); font-size: .78rem; }

.page-hero { padding-block: clamp(90px, 12vw, 160px) clamp(64px, 8vw, 100px); }
.page-hero p { max-width: 650px; margin: 28px 0 0; color: var(--muted); font-size: 1.12rem; }
.page-hero .eyebrow { margin-bottom: 22px; }

.portfolio-note { display: flex; justify-content: space-between; gap: 20px; padding-bottom: 28px; color: var(--muted); font-size: .86rem; }

.profile-feature {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, .9fr);
  min-height: 660px;
  overflow: hidden;
  border-radius: 30px;
  background: var(--ink);
  color: white;
}

.profile-feature img { width: 100%; height: 100%; min-height: 520px; object-fit: cover; }
.profile-copy { display: flex; flex-direction: column; justify-content: center; padding: clamp(34px, 6vw, 78px); }
.profile-copy .status { align-self: flex-start; margin-bottom: 36px; padding: 8px 12px; border: 1px solid #3f4440; border-radius: 999px; color: #c4c9c5; font-size: .75rem; text-transform: uppercase; letter-spacing: .1em; }
.profile-copy h2 { margin-bottom: 20px; font-size: clamp(3rem, 6vw, 5.7rem); line-height: .9; letter-spacing: -.06em; }
.profile-copy h2 em { font-family: var(--serif); font-weight: 400; }
.profile-copy p { color: #b6bbb7; }
.profile-copy .button { align-self: flex-start; margin-top: 18px; }

.profile-detail-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.profile-detail { padding: 26px; border: 1px solid var(--line); border-radius: 20px; background: var(--surface); }
.profile-detail small { display: block; margin-bottom: 30px; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; }
.profile-detail h3 { margin-bottom: 8px; font-size: 1.4rem; }
.profile-detail p { margin: 0; color: var(--muted); }

.contact-layout { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(50px, 9vw, 120px); padding-bottom: 120px; }
.contact-intro h1 { font-size: clamp(3.6rem, 7vw, 6.6rem); }
.contact-intro p { max-width: 440px; color: var(--muted); }
.contact-form { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.field { display: grid; gap: 8px; }
.field.full { grid-column: 1 / -1; }
.field label { font-size: .82rem; font-weight: 700; }
.field input,
.field select,
.field textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  color: var(--ink);
  padding: 15px 16px;
}
.field textarea { min-height: 150px; resize: vertical; }
.contact-form .button { justify-self: start; border: 0; cursor: pointer; }
.form-status { grid-column: 1 / -1; min-height: 24px; margin: 0; color: var(--muted); font-size: .86rem; }

.cta-band {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 30px;
  padding: clamp(38px, 7vw, 76px);
  border-radius: 30px;
  background: var(--cobalt);
  color: var(--ink);
}
.cta-band h2 { max-width: 760px; margin: 0; font-size: clamp(2.6rem, 5.4vw, 5.5rem); line-height: .96; letter-spacing: -.055em; }
.cta-band .button { background: white; color: var(--ink); }

.site-footer { padding: 44px 0 32px; }
.footer-row { display: flex; justify-content: space-between; gap: 30px; padding-top: 30px; border-top: 1px solid var(--line); color: var(--muted); font-size: .82rem; }
.footer-links { display: flex; flex-wrap: wrap; gap: 20px; }

.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
  place-items: center;
  padding: 20px;
  background: rgba(10, 12, 11, .72);
  backdrop-filter: blur(14px);
}

.modal.is-open { display: grid; }
.modal-panel {
  position: relative;
  width: min(960px, 100%);
  max-height: calc(100vh - 40px);
  display: grid;
  grid-template-columns: minmax(300px, 430px) 1fr;
  overflow: auto;
  border-radius: 26px;
  background: var(--surface);
  box-shadow: 0 40px 100px rgba(0,0,0,.35);
}
.modal-video-wrap { min-height: 650px; background: #111; }
.modal-video-wrap video { width: 100%; height: 100%; max-height: calc(100vh - 40px); object-fit: contain; }
.modal-panel.is-landscape { width: min(1180px, 100%); grid-template-columns: minmax(0, 1.45fr) minmax(320px, .75fr); }
.modal-panel.is-landscape .modal-video-wrap { min-height: 520px; }
.modal-details { display: flex; flex-direction: column; padding: clamp(32px, 5vw, 56px); }
.modal-close { position: absolute; top: 18px; right: 18px; z-index: 2; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 50%; background: var(--surface); color: var(--ink); cursor: pointer; }
.modal-kicker { margin: 34px 0 14px; color: var(--blue-ink); font-size: .75rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.modal-details h2 { font-size: clamp(2.2rem, 4vw, 3.6rem); line-height: 1; letter-spacing: -.05em; }
.detail-list { margin: auto 0 0; }
.detail-row { display: grid; grid-template-columns: 90px 1fr; gap: 18px; padding: 18px 0; border-top: 1px solid var(--line); }
.detail-row dt { color: var(--muted); font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; }
.detail-row dd { margin: 0; }

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; min-height: auto; }
  .hero-visual { width: min(100%, 560px); min-height: 600px; margin-inline: auto; }
  .section-head { grid-template-columns: 1fr; gap: 24px; }
  .portfolio-section-head { grid-template-columns: 1fr; gap: 18px; }
  .home-work-grid, .portfolio-grid { grid-template-columns: repeat(2, 1fr); }
  .profile-feature { grid-template-columns: 1fr; }
  .profile-feature img { max-height: 680px; }
  .contact-layout { grid-template-columns: 1fr; }
  .cta-band { grid-template-columns: 1fr; align-items: start; }
  .cta-band .button { justify-self: start; }
}

@media (max-width: 720px) {
  .site-header { top: 10px; width: min(calc(100% - 20px), var(--max)); margin-top: 10px; }
  .nav-shell { min-height: 64px; padding: 8px 9px 8px 18px; }
  .menu-toggle { display: block; }
  .nav-links {
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    display: none;
    align-items: stretch;
    flex-direction: column;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: var(--surface);
    box-shadow: 0 20px 50px rgba(0,0,0,.1);
  }
  .nav-links.is-open { display: flex; }
  .nav-links > a { padding: 13px 14px; }
  .nav-cta { margin-top: 4px; }
  .container { width: min(calc(100% - 28px), var(--max)); }
  h1 { font-size: clamp(3.2rem, 16vw, 5.2rem); }
  .hero { padding-top: 80px; }
  .hero-visual { min-height: 510px; }
  .phone-card { width: min(65%, 260px); border-radius: 27px; }
  .service-grid, .profile-detail-grid { grid-template-columns: 1fr; }
  .service-card { min-height: 300px; }
  .modal { padding: 10px; }
  .modal-panel { grid-template-columns: 1fr; max-height: calc(100vh - 20px); }
  .modal-panel.is-landscape { grid-template-columns: 1fr; }
  .modal-video-wrap { min-height: auto; height: min(62vh, 620px); }
  .modal-panel.is-landscape .modal-video-wrap { min-height: auto; height: min(48vh, 430px); }
  .modal-details { min-height: 430px; }
  .modal-close { top: 12px; right: 12px; }
  .footer-row { flex-direction: column; }
}

@media (max-width: 500px) {
  .home-work-grid, .portfolio-grid { grid-template-columns: 1fr; }
  .contact-form { grid-template-columns: 1fr; }
  .field.full { grid-column: auto; }
  .hero-visual { min-height: 440px; }
  .phone-card { width: 62%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
