/* Adapt the current four-point content to the selected blue-first palette only. */
.approach-point { border-top-color: color-mix(in srgb, var(--paper) 32%, var(--blue)); }
.approach-point h2 { color: var(--paper); }
@media (forced-colors: active) {
  .approach-point { border-top-color: CanvasText; }
  .approach-point h2 { color: CanvasText; }
}
@media print {
  .approach-point { border-top-color: var(--ink); }
  .approach-point h2 { color: var(--ink); }
}

/* Lead hierarchy: a prominent supporting statement beneath the headline and tangle. */
.hero-introduction { max-width: none; }
.hero-introduction p { font-size: clamp(1.8rem, 1.25rem + 1vw, 2.375rem); line-height: 1.28; letter-spacing: -.03em; font-weight: 600; }
@media (min-width: 600px) and (max-width: 799px) {
  .hero-introduction p { font-size: 26px; line-height: 1.28; }
}
@media (max-width: 599px) {
  .hero-introduction p { font-size: clamp(1.5625rem, 1.25rem + 1.3vw, 1.625rem); line-height: 1.28; }
}

/* Recent projects: one open editorial row on desktop; compact readable rows below. */
.selected-work { padding-top: 48px; padding-bottom: 48px; }
.selected-work .section-heading { margin-bottom: 26px; }
.selected-work .section-heading h2 { font-size: clamp(2rem, 1.5rem + 1vw, 2.75rem); }
.projects { display: grid; gap: 26px; }
.project { min-width: 0; display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 16px 20px; align-items: center; padding: 22px 0 0; }
.project-logo { display: block; width: 64px; height: 64px; object-fit: contain; }
.project h3 { font-size: 24px; line-height: 1.15; letter-spacing: -.035em; }
.project .desktop-break { display: none; }
.project p { grid-column: 1 / -1; max-width: none; margin: 0; font-size: 17px; line-height: 1.5; }

@media (min-width: 1100px) {
  .projects { grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: clamp(24px, 2.5vw, 48px); row-gap: 16px; }
  .project { grid-row: span 3; grid-template-columns: minmax(0, 1fr); grid-template-rows: subgrid; gap: 16px; align-items: start; padding-top: 24px; }
  .project-logo { width: 88px; height: 88px; }
  .project h3 { font-size: clamp(1.375rem, 1rem + .5vw, 1.625rem); }
  .project p { font-size: 17px; }
}
@media (max-width: 699px) {
  .selected-work { padding-top: 36px; padding-bottom: 36px; }
  .selected-work .section-heading { margin-bottom: 22px; }
  .project h3 { font-size: 22px; }
  .project-logo { width: 56px; height: 56px; }
  .project { grid-template-columns: 56px minmax(0, 1fr); gap: 14px 16px; }
}
@media print {
  .projects { display: block; }
  .project { break-inside: avoid; margin-bottom: 22px; grid-template-columns: 64px minmax(0, 1fr); grid-template-rows: auto auto; }
  .project-logo { width: 64px; height: 64px; }
  .project p { grid-column: 1 / -1; }
}

/* Testimonials: a reader-controlled card rail, not a timed rotation. The next card
   stays partly in view so the set reads as a sequence before anyone touches it. */
.testimonials { --card: 84%; --card-gap: 40px; position: relative; background: var(--blue); color: var(--paper); padding: 75px 23vw 72px 7vw; }
.testimonials-heading, .testimonials-frame, .testimonials-controls { position: relative; z-index: 2; }
.testimonials-heading { display: flex; justify-content: space-between; align-items: baseline; gap: 20px; padding-bottom: 23px; border-bottom: 1px solid color-mix(in srgb, var(--paper) 35%, var(--blue)); }
.testimonials-heading h2 { font-size: clamp(1.25rem, 1rem + .5vw, 1.6rem); letter-spacing: -.025em; line-height: 1.2; }

.testimonials-frame { margin: 0 -7px; padding: 0 7px; border-radius: 6px; }
.testimonials-track { display: flex; gap: var(--card-gap); overflow-x: auto; scroll-snap-type: x mandatory; overscroll-behavior-x: contain; scrollbar-width: thin; scrollbar-color: var(--paper) var(--blue); padding: 0 0 12px; }
.testimonials-track:focus-visible { outline: 2px solid var(--paper); outline-offset: 4px; }
/* The neighbouring card dissolves toward the strings rather than stopping hard against them.
   At the last quote the previous card peeks from the left instead, so the fade moves there. */
.testimonials[data-carousel] .testimonials-track { --fade: calc((100% - var(--card) - var(--card-gap)) * .7);
  -webkit-mask-image: linear-gradient(to right, #000 calc(100% - var(--fade)), transparent);
  mask-image: linear-gradient(to right, #000 calc(100% - var(--fade)), transparent); }
.testimonials[data-carousel][data-edge='end'] .testimonials-track {
  -webkit-mask-image: linear-gradient(to left, #000 calc(100% - var(--fade)), transparent);
  mask-image: linear-gradient(to left, #000 calc(100% - var(--fade)), transparent); }
/* A mask would also hide the rail's own focus ring, so the unmasked frame draws it. */
.testimonials[data-carousel] .testimonials-track:focus-visible { outline: none; }
.testimonials[data-carousel] .testimonials-frame:has(.testimonials-track:focus-visible) { outline: 2px solid var(--paper); outline-offset: 4px; }
.testimonial { position: relative; flex: 0 0 var(--card); min-width: 0; margin: 0; padding: 64px 44px 34px; border-radius: 4px; background: color-mix(in srgb, var(--paper) 8%, var(--blue)); scroll-snap-align: start; display: flex; flex-direction: column; }
.testimonial::before { content: '“'; position: absolute; top: 20px; left: 41px; color: var(--mustard); font-size: 90px; font-weight: 750; line-height: 1; }
.testimonials[data-carousel] .testimonial { transition: opacity .35s ease; }
.testimonials[data-carousel] .testimonial:not([data-current]) { opacity: .5; cursor: pointer; }
.testimonials[data-carousel] .testimonial:not([data-current]):hover { opacity: .7; }
/* One short sideways breath the first time the rail is seen, then still. */
.testimonials[data-nudge] .testimonial { animation: testimonial-nudge .9s cubic-bezier(.45, 0, .25, 1) 1; }
@keyframes testimonial-nudge { 0%, 100% { transform: none; } 45% { transform: translateX(calc(-1 * min(56px, 9vw))); } }
html[data-motion='off'] .testimonials .testimonial { transition: none; animation: none; }
.testimonial blockquote { margin: 0; flex: 1; }
.testimonial blockquote p { margin: 0; max-width: 48ch; font-size: clamp(1.5rem, 1rem + 1.45vw, 2.5rem); line-height: 1.36; letter-spacing: -.03em; font-weight: 500; }
.testimonial figcaption { margin-top: 30px; line-height: 1.5; }
.testimonial-name, .testimonial-role { display: block; }
.testimonial-name { font-size: 18px; font-weight: 700; }
.testimonial-role { margin-top: 3px; font-size: 15px; }
.testimonials-controls { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 14px 20px; margin-top: 15px; }
.testimonials-controls[hidden] { display: none; }
.testimonials-index, .testimonials-arrows { display: flex; align-items: center; }
.testimonials-index { gap: 4px; }
.testimonials-controls button { min-width: 44px; min-height: 44px; padding: 8px; border: 0; border-bottom: 2px solid transparent; background: none; color: inherit; }
.testimonials-index button { font-size: 13px; font-variant-numeric: tabular-nums; }
.testimonials-index [aria-current='true'] { border-bottom-color: var(--mustard); font-weight: 750; }
.testimonials-controls button:hover { border-bottom-color: currentColor; }
.testimonials-arrows { gap: 10px; margin-left: auto; }
/* Controls belong to the quote being read, so they end where its card ends. */
@media (min-width: 800px) { .testimonials-controls { width: var(--card); } }
.testimonials-arrows button { font-size: 28px; line-height: 1; }
.testimonials-arrows [aria-disabled='true'] { opacity: .45; cursor: default; }
.testimonials-arrows [aria-disabled='true']:hover { border-bottom-color: transparent; }
.testimonials-status { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
@media (max-width: 799px) {
  .testimonials { --card-gap: 14px; padding: 52px 17vw 50px 7vw; }
  .testimonial blockquote p { font-size: clamp(1.3rem, 1rem + 1vw, 1.6rem); line-height: 1.4; }
  .testimonial { padding: 58px 18px 22px; }
  .testimonial::before { top: 18px; left: 15px; font-size: 80px; }
  .testimonial-name { font-size: 17px; }
  .testimonial-role { font-size: 14px; }
}
@media (prefers-reduced-motion: reduce) {
  .testimonials .testimonial { transition: none; animation: none; }
}
@media (forced-colors: active) {
  .testimonials { background: Canvas; color: CanvasText; }
  .testimonial { border: 1px solid CanvasText; }
  .testimonials[data-carousel] .testimonial:not([data-current]) { opacity: 1; }
  .testimonial::before { color: CanvasText; }
  .testimonials-heading { border-bottom-color: CanvasText; }
  .testimonials-track:focus-visible { outline-color: Highlight; }
  .testimonials-index [aria-current='true'] { border-bottom-color: Highlight; }
}
@media print {
  .testimonials { padding: 30px 24px; color: var(--ink); background: white; }
  .testimonials-track { display: block; overflow: visible; }
  .testimonials[data-carousel] .testimonials-track { -webkit-mask-image: none; mask-image: none; }
  .testimonials[data-carousel] .testimonial, .testimonial { display: block; break-inside: avoid; padding: 24px 0; background: none; opacity: 1; }
  .testimonial::before, .testimonials-controls { display: none; }
  .testimonials-heading { border-bottom-color: var(--ink); }
  .testimonial blockquote p { font-size: 18px; }
  .testimonial figcaption { margin-top: 16px; }
}
