/* ---------- Font faces ---------- */
@font-face {
  font-family: 'Sloop';
  src: url('../fonts/sloop/Sloop-ScriptThree.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'HelvComp';
  src: url('../fonts/helvetica-255/helvetica-compressed-5871d14b6903a.otf') format('opentype');
  font-display: swap;
}

@font-face {
  font-family: 'Helv';
  src: url('../fonts/helvetica-255/Helvetica.ttf') format('truetype');
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: 'Helv';
  src: url('../fonts/helvetica-255/Helvetica-Bold.ttf') format('truetype');
  font-weight: 700;
  font-display: swap;
}

@font-face {
  font-family: 'Helv';
  src: url('../fonts/helvetica-255/helvetica-light-587ebe5a59211.ttf') format('truetype');
  font-weight: 300;
  font-display: swap;
}

/* ---------- Tokens ---------- */
:root {
  --bg: #FAF7F2;
  --bg-elevated: #F2EDE4;
  --ink: #1A1A1A;
  --ink-2: #3A3A3A;
  --ink-3: #6B6B6B;
  --rule: #E2DBCE;
  --rule-2: #D5CCBA;
  --accent: #0F4C9C;
  --accent-soft: #E6EDF7;
  --accent-ink: #0A356E;

  --serif: 'Fraunces', Georgia, serif;
  --sans: 'Helv', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, monospace;
  --script: 'Sloop', Georgia, serif;
  --compressed: 'HelvComp', 'Arial Narrow', sans-serif;

  --container: 1280px;
  --gutter: clamp(20px, 4vw, 56px);
  --r-sm: 6px;
  --r-md: 10px;
  --r-lg: 16px;
}

/* ---------- Dark theme ---------- */
[data-theme="dark"] {
  --bg: #141210;
  --bg-elevated: #1E1C19;
  --ink: #EDE9E2;
  --ink-2: #B8B3AA;
  --ink-3: #9A948A;
  --rule: #2A2723;
  --rule-2: #3A3630;
  --accent: #4A90D9;
  --accent-soft: #1C2A3E;
  --accent-ink: #7AB3E8;
}

/* ---------- Reset & base ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img,
svg {
  max-width: 100%;
  display: block;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

button {
  font: inherit;
  cursor: pointer;
}

/* ---------- Layout ---------- */
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

section {
  padding: clamp(64px, 9vw, 128px) 0;
  scroll-margin-top: 64px;
}

section+section {
  border-top: 1px solid var(--rule);
}

#about {
  border-top: none;
  border-bottom: none;
}

.about-copy {
  max-width: 660px;
  margin: 0 auto;
  text-align: left;
}

.about-copy p {
  margin-left: auto;
  margin-right: auto;
}

#contact {
  border-top: none;
}

/* ---------- Type ---------- */
h1,
h2,
h3,
h4 {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.02em;
  margin: 0;
  text-wrap: balance;
}

h2 {
  font-size: clamp(36px, 4.8vw, 72px);
  line-height: 1.02;
  font-weight: 700;
}

.h-script {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 300;
  font-size: 1em;
}

h3 {
  font-size: clamp(24px, 2.6vw, 38px);
  line-height: 1.15;
}

h4 {
  font-size: clamp(18px, 1.4vw, 22px);
  line-height: 1.3;
  font-family: var(--sans);
  font-weight: 600;
  letter-spacing: 0;
}

p {
  margin: 0 0 1em;
  max-width: 64ch;
  text-wrap: pretty;
}

.eyebrow {
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.eyebrow .dot {
  color: var(--accent);
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--rule);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 64px;
  gap: 24px;
}

.header-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

.brand {
  display: flex;
  align-items: center;
}

.brand-avatar {
  display: block;
  width: 32px;
  height: 32px;
  object-fit: cover;
}

[data-theme="light"] .brand-avatar--dark {
  display: none;
}

[data-theme="dark"] .brand-avatar--light {
  display: none;
}

.site-header nav {
  display: flex;
  gap: 24px;
  align-items: center;
}

.site-header nav a {
  color: var(--ink-2);
  font-size: 14px;
  font-weight: 500;
}

.site-header nav a:hover {
  color: var(--ink);
  text-decoration: none;
}

.icon-btn {
  background: transparent;
  border: 1px solid var(--rule-2);
  color: var(--ink-2);
  height: 36px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: background 120ms, border-color 120ms;
}

.icon-btn:hover {
  background: var(--bg-elevated);
  border-color: var(--ink-3);
}

.mobile-menu-btn {
  display: none;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
}

@media (max-width: 760px) {
  .brand {
    display: none;
  }

  .mobile-menu-btn {
    display: flex;
    align-items: center;
  }

  .site-header nav {
    display: none;
    position: fixed;
    top: 64px;
    left: 0;
    right: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--rule);
    flex-direction: column;
    gap: 0;
    padding: 8px 0;
    z-index: 49;
  }

  .site-header nav.open {
    display: flex;
  }

  .site-header nav a {
    padding: 14px var(--gutter);
    font-size: 15px;
    border-bottom: 1px solid var(--rule);
  }

  .site-header nav a:last-child {
    border-bottom: none;
  }
}

/* ---------- Cover page ---------- */

/* Two-column grid: text | photo.
   Everything is sized in svh so the whole page
   fits exactly one viewport on any screen. */
.cover {
  background: var(--bg-elevated);
  height: calc(100svh - 64px);
  overflow: hidden;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 4vw;
  padding: 3svh 5vw;
}

/* Left column: all text stacked */
.cover-left {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 1.5svh;
}

/* Big headline — svh so 4 lines always fit vertically */
.cover-big {
  font-family: var(--sans);
  font-weight: 700;
  font-size: min(9svh, 11vw);
  line-height: 0.93;
  text-transform: uppercase;
  color: var(--ink);
  margin: 0;
  letter-spacing: -0.025em;
}

/* Script line — indented, svh-scaled */
.cover-script {
  font-family: var(--script);
  font-size: min(10svh, 17vw);
  color: var(--ink);
  margin: 0.5svh 0 0.5svh 8%;
  line-height: 1.05;
}

/* Small caps subtitle */
.cover-small {
  font-family: var(--sans);
  font-size: max(14px, min(1.6svh, 1.6vw));
  color: var(--ink-3);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  line-height: 1.5;
  margin: 0.5svh 0 0;
  max-width: none;
}

/* Right column: photo fills ~85% of cover height */
.cover-photo-wrap {
  position: relative;
  height: 85svh;
  max-height: calc(100svh - 64px - 6svh);
  aspect-ratio: 2/3;
  border-radius: 18px;
  border: 1.5px dashed var(--rule-2);
  background: var(--bg);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.cover-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  border-radius: 18px;
  transition: opacity 200ms;
}

[data-theme="dark"] .cover-photo {
  filter: grayscale(100%);
}

.cover-photo-hint {
  font-size: max(10px, 1.2svh);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-3);
  text-align: center;
  line-height: 1.8;
  pointer-events: none;
  position: relative;
  z-index: 1;
}

/* Portrait (mobile & tablet): stack text above photo */
@media (orientation: portrait) {
  .cover {
    grid-template-columns: 1fr;
    grid-template-rows: 1fr auto;
    align-items: start;
    gap: 2svh;
  }

  .cover-big {
    font-size: min(7.5svh, 14vw);
  }

  .cover-script {
    font-size: min(5svh, 11vw);
    margin-left: 5%;
  }

  .cover-small {
    font-size: max(10px, min(1.8svh, 3vw));
  }

  .cover-photo-wrap {
    height: auto;
    max-height: none;
    width: 38%;
    margin: 0 auto;
  }
}

@media (max-width: 760px) {
  .cover-photo-wrap {
    display: none;
  }
}

/* ---------- Section header ---------- */
.section-head {
  text-align: center;
  margin-bottom: clamp(40px, 5vw, 72px);
}

.section-banner {
  display: block;
  width: 50%;
  height: auto;
  border-radius: 8px;
  margin: 0 auto clamp(24px, 3vw, 40px);
}

.section-head .right p,
.section-head>div>p {
  color: var(--ink-2);
  font-size: 18px;
  max-width: 60ch;
  margin-top: 16px;
  margin-left: auto;
  margin-right: auto;
}

/* ---------- Project ---------- */
.project {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: clamp(20px, 4vw, 56px);
  padding: clamp(40px, 6vw, 80px) 0;
  border-top: 1px solid var(--rule);
}


@media (max-width: 900px) {
  .project {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .project-meta {
    display: none;
  }
}

.project-meta {
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: sticky;
  top: 64px;
  align-self: start;
  background: var(--bg);
  padding: 32px 0 8px;
  z-index: 10;
}

.project-meta .num {
  font-family: var(--serif);
  font-size: 56px;
  line-height: 1;
  color: var(--accent);
  font-weight: 300;
}

.project-meta .year {
  font-size: 12px;
  color: var(--ink-3);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.project-meta .kicker {
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-2);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.project-title {
  margin-bottom: 8px;
}

.project-sub {
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(20px, 2vw, 26px);
  color: var(--ink-2);
  margin: 0 0 32px;
  max-width: 56ch;
  line-height: 1.35;
}

/* ---------- Case blocks ---------- */
.case-blocks {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px 40px;
  margin-bottom: 40px;
}

@media (max-width: 760px) {
  .case-blocks {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}

.case-block.full {
  grid-column: 1 / -1;
}

.case-block .label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 8px;
}

.case-block p {
  font-size: 15.5px;
  color: var(--ink-2);
  line-height: 1.55;
  max-width: none;
  margin: 0;
}

.outcomes {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.outcome-pill {
  background: var(--accent-soft);
  color: var(--accent-ink);
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
}

.stack-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.stack-list li {
  background: var(--bg-elevated);
  border: 1px solid var(--rule);
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12.5px;
  color: var(--ink-2);
  font-family: var(--mono);
}

/* ---------- NDA note ---------- */
.nda-note {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  margin-top: 24px;
  padding: 16px 20px;
  border: 1.5px dashed var(--rule-2);
  border-radius: 8px;
  background: var(--bg-elevated);
}

.nda-badge {
  font-family: var(--mono, 'JetBrains Mono', monospace);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.1em;
  color: var(--ink-3);
  border: 1px solid var(--rule-2);
  border-radius: 4px;
  padding: 3px 7px;
  white-space: nowrap;
  flex-shrink: 0;
  margin-top: 3px;
}

.nda-note strong {
  display: block;
  font-size: 13px;
  color: var(--ink-2);
  margin-bottom: 6px;
}

.nda-note p {
  font-size: 13px;
  color: var(--ink-3);
  margin: 0;
  line-height: 1.6;
  max-width: none;
}

/* ---------- Matrix ---------- */
.matrix {
  margin-top: 32px;
  border-top: 1px solid var(--rule);
}

.matrix-title {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
  padding: 16px 0 12px;
}

.matrix table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.matrix th,
.matrix td {
  text-align: left;
  padding: 12px 16px 12px 0;
  border-bottom: 1px solid var(--rule);
  vertical-align: top;
}

.matrix th {
  width: 38%;
  color: var(--ink);
  font-weight: 600;
  font-size: 13.5px;
}

.matrix td {
  color: var(--ink-2);
}

.matrix td.empty {
  color: var(--ink-3);
  font-style: italic;
}

/* ---------- Visual placeholders ---------- */
.visual {
  aspect-ratio: 16/9;
  background: var(--bg-elevated);
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  margin-bottom: 32px;
  position: relative;
  overflow: hidden;
}

.visual-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.visual-clio {
  background: linear-gradient(135deg, #0F4C9C 0%, #1E6BB8 50%, #6FA1E0 100%);
}

.visual-retifica {
  background: linear-gradient(135deg, #B83C7A 0%, #D86CA0 100%);
}

.visual-ariel {
  background: linear-gradient(135deg, #2E6E4F 0%, #5BA582 100%);
}

.visual-clube {
  background: linear-gradient(135deg, #B6541E 0%, #E08146 100%);
}

.visual-gestus {
  background: linear-gradient(135deg, #6B3FA0 0%, #A176D8 100%);
}

.visual-simulador {
  background: linear-gradient(135deg, #0A356E 0%, #1E6BB8 100%);
}

.visual-mark {
  position: absolute;
  bottom: 24px;
  left: 24px;
  color: rgba(255, 255, 255, 0.95);
  font-family: var(--serif);
  font-size: clamp(28px, 4vw, 56px);
  font-weight: 300;
  letter-spacing: -0.02em;
}

.visual-tag {
  position: absolute;
  top: 24px;
  right: 24px;
  color: rgba(255, 255, 255, 0.85);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  background: rgba(0, 0, 0, 0.18);
  padding: 6px 12px;
  border-radius: 999px;
  backdrop-filter: blur(6px);
}

/* ---------- Scientific ---------- */
.science-list {
  display: flex;
  flex-direction: column;
}

.science-item {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 32px;
  padding: 24px 0;
  border-bottom: 1px solid var(--rule);
}

.science-item .y {
  font-family: var(--serif);
  font-size: 32px;
  color: var(--accent);
  font-weight: 300;
}

.science-item h3 {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 400;
  line-height: 1.3;
  margin-bottom: 6px;
  letter-spacing: -0.01em;
}

.science-item .where {
  color: var(--ink-2);
  font-size: 15px;
  margin-bottom: 4px;
}

.science-item .meta {
  color: var(--ink-3);
  font-size: 13px;
}

/* ---------- Skills ---------- */

.skills-grid li::before {
  content: "—  ";
  color: var(--accent);
}

/* ---------- About ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: clamp(32px, 5vw, 80px);
}

@media (max-width: 900px) {
  .about-grid {
    grid-template-columns: 1fr;
  }
}

.about-grid p {
  margin-bottom: 0;
  color: var(--ink-2);
  font-size: 18px;
}

.hero-meta {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  border-top: 1px solid var(--rule);
  padding-top: 24px;
}

.hero-meta .row {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 12px 0;
  border-bottom: 1px solid var(--rule);
}

.hero-meta .k {
  font-size: 11px;
  color: var(--ink-3);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.hero-meta .v {
  font-size: 14px;
  color: var(--ink);
}

/* ---------- Contact ---------- */
.contact-card {
  background: var(--bg-elevated);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  padding: clamp(32px, 4vw, 56px);
  margin-top: 24px;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: clamp(24px, 4vw, 56px);
  align-items: center;
}

.contact-tagline {
  margin: 0;
  color: var(--ink);
  font-family: 'Fraunces', Georgia, serif;
  font-size: 44px;
  font-style: italic;
  line-height: 1.3;
}

.contact-label {
  color: var(--ink-3);
  font-size: 11px;
  letter-spacing: .1em;
  text-transform: uppercase;
}

@media (max-width: 760px) {
  .contact-card {
    grid-template-columns: 1fr;
  }
}

.contact-card .links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.contact-link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
  border: 1px solid var(--rule-2);
  border-radius: var(--r-md);
  background: var(--bg);
  color: var(--ink);
  font-size: 15px;
}

.contact-link:hover {
  border-color: var(--accent);
  text-decoration: none;
}

.contact-link .arr {
  color: var(--accent);
}

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--rule);
  padding: 32px 0;
  display: flex;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--ink-3);
}

/* ---------- Print ---------- */
@media print {
  @page {
    size: A4;
    margin: 18mm 16mm;
  }

  html,
  body {
    background: #fff;
    color: #111;
    font-size: 11pt;
  }

  .site-header,
  .icon-btn {
    display: none !important;
  }

  .cover {
    min-height: 0;
    background: #fff;
    break-after: page;
  }

  section {
    padding: 16pt 0;
    border-top: 0.5pt solid #ccc;
    break-inside: avoid;
  }

  h2 {
    font-size: 22pt;
  }

  h3 {
    font-size: 14pt;
  }

  .project {
    break-inside: avoid;
    padding: 12pt 0;
    grid-template-columns: 90px 1fr;
  }

  .project-meta {
    display: flex !important;
    position: static;
  }

  .visual {
    aspect-ratio: 5/2;
    max-height: 90mm;
  }

  a {
    color: #0F4C9C;
  }

  .case-blocks {
    gap: 8pt 16pt;
  }

  .matrix table {
    font-size: 9.5pt;
  }

  .stack-list li,
  .outcome-pill {
    background: #f0f0f0 !important;
    color: #111 !important;
    border: 0.5pt solid #ccc;
  }

  .contact-card {
    background: #fff;
    border: 0.5pt solid #ccc;
  }
}

/* SEO: visually hidden heading */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

.seo-intro { max-width: 760px; margin-top: 18px; color: var(--ink-2); font: 300 clamp(17px, 1.6vw, 22px)/1.55 'Fraunces', serif; }

/* ---------- Search landing and case-study pages ---------- */
.case-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 18px 0 8px;
  padding: 12px 16px;
  border: 1px solid var(--rule-2);
  border-radius: 999px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .02em;
}

.case-link:hover { border-color: var(--accent); text-decoration: none; }

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 28px;
}

.service-card {
  display: flex;
  min-height: 260px;
  flex-direction: column;
  justify-content: space-between;
  padding: 28px;
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  background: var(--bg-elevated);
  color: var(--ink);
}

.service-card:hover { border-color: var(--accent); text-decoration: none; }
.service-card .label { color: var(--accent); }
.service-card h3 { margin: 22px 0 12px; font-size: clamp(26px, 3vw, 40px); }
.service-card p { color: var(--ink-2); }
.service-card .arr { color: var(--accent); font-size: 22px; }

.detail-header {
  position: sticky;
  z-index: 30;
  top: 0;
  border-bottom: 1px solid var(--rule);
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(12px);
}

.detail-header .container {
  display: flex;
  min-height: 70px;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.detail-header nav { display: flex; flex-wrap: wrap; gap: 18px; font-size: 12px; }
.detail-header a { color: var(--ink); }
.detail-brand { font-family: 'Fraunces', Georgia, serif; font-size: 22px; font-weight: 600; }

.detail-main { padding-bottom: 80px; }
.detail-hero { padding: clamp(72px, 10vw, 150px) 0 clamp(44px, 7vw, 90px); }
.detail-eyebrow { color: var(--accent); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; }
.detail-hero h1 { max-width: 980px; margin: 18px 0 24px; font-size: clamp(44px, 8vw, 104px); line-height: .98; }
.detail-lede { max-width: 820px; color: var(--ink-2); font: 300 clamp(20px, 2.4vw, 32px)/1.45 'Fraunces', Georgia, serif; }
.detail-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px; }
.detail-tags span { padding: 8px 12px; border: 1px solid var(--rule-2); border-radius: 999px; color: var(--ink-2); font-size: 12px; }
.detail-visual { display: block; width: 100%; max-height: 760px; border-radius: var(--r-lg); object-fit: cover; }

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: clamp(36px, 7vw, 100px);
  padding: clamp(52px, 8vw, 110px) 0;
}

.detail-copy { max-width: 780px; }
.detail-copy section { padding: 0 0 48px; border: 0; }
.detail-copy h2 { margin-bottom: 16px; font-size: clamp(30px, 4vw, 52px); }
.detail-copy p, .detail-copy li { color: var(--ink-2); font-size: 18px; line-height: 1.72; }
.detail-copy ul { padding-left: 22px; }
.detail-aside { align-self: start; position: sticky; top: 100px; }
.detail-aside dl { margin: 0; border-top: 1px solid var(--rule); }
.detail-aside div { padding: 16px 0; border-bottom: 1px solid var(--rule); }
.detail-aside dt { margin-bottom: 4px; color: var(--ink-3); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; }
.detail-aside dd { margin: 0; color: var(--ink); }

.related-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.related-card { padding: 22px; border: 1px solid var(--rule); border-radius: var(--r-md); color: var(--ink); }
.related-card:hover { border-color: var(--accent); text-decoration: none; }

@media (max-width: 820px) {
  .services-grid, .related-grid { grid-template-columns: 1fr; }
  .detail-grid { grid-template-columns: 1fr; }
  .detail-aside { position: static; }
  .detail-header nav { display: none; }
}

/* Keep inline links distinguishable without relying on color alone. */
.about-copy a {
  text-decoration: underline;
  text-underline-offset: 3px;
}
