/* Overpass, shared with the Corallo site. SIL Open Font License. */
@font-face {
  font-family: "Overpass";
  src: url("assets/fonts/overpass-latin.woff2") format("woff2");
  font-weight: 300 900;
  font-display: swap;
}

/* Colours sampled from the Radiante logo gradient */
:root {
  --ink: #221e4f; /* deep indigo from the logo, used for text, buttons and the dark band */
  --text-2: #4a4756;
  /* paper and lines carry a light coral tint from the logo */
  --line: #ebd2cc;
  --paper: #fbece7;
  --coral: #f04a52;
  --coral-text: #c8303a;
  --plum: #923eaa;
  --indigo: #4e4fad;
  --grad: linear-gradient(90deg, #f04a52, #923eaa 55%, #4e4fad);

  --sans: "Overpass", "Segoe UI", Arial, sans-serif;
  --wrap: 72rem;
  --gutter: clamp(1rem, 4vw, 2.5rem);
  --section-pad: clamp(2.25rem, 5vw, 3.75rem);
}

*, *::before, *::after { box-sizing: border-box; }
/* keeps anchored section headings clear of the sticky bar */
html { scroll-behavior: smooth; scroll-padding-top: 5.5rem; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  html .btn:hover, html .carousel__btn:hover { transform: none; }
  .hero__down-icon { animation: none; } /* html: outranks the later hover rule */
  /* no auto-slide: a static row you can scroll sideways */
  .clients { animation: none; }
  .marquee:not(.is-js) .clients[aria-hidden] { display: none; }
  .marquee:not(.is-js) { overflow-x: auto; mask-image: none; }
}
body {
  margin: 0;
  font: 400 1.0625rem/1.6 var(--sans);
  color: var(--ink);
  /* soft coral wash behind the hero cloud, fading into the tinted paper */
  background: radial-gradient(70rem 45rem at 85% -5%, rgba(240, 74, 82, .24), transparent 70%) no-repeat, var(--paper);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { margin: 0; line-height: 1.1; text-wrap: balance; }
p { margin: 0; text-wrap: pretty; }
ol, ul { margin: 0; padding: 0; list-style: none; }
a { color: var(--coral-text); }
:focus-visible { outline: 3px solid var(--indigo); outline-offset: 3px; }

.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 1rem; top: 1rem; z-index: 20; background: #fff; padding: .5rem 1rem; }

/* Header */
.top {
  position: sticky; top: 0; z-index: 10;
  background: rgba(251, 236, 231, .88); backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.top__inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-block: .9rem; }
.logo img { display: block; height: 44px; width: auto; }
nav { display: flex; align-items: center; gap: clamp(.75rem, 2.5vw, 2rem); font-size: .95rem; }
nav a { color: var(--ink); text-decoration: none; }
nav a:hover { color: var(--coral-text); }
/* hover states ease in instead of snapping */
.btn, nav a, .carousel__btn, .contact__mail {
  transition: background-color .25s ease, color .25s ease, border-color .25s ease, box-shadow .25s ease, transform .25s ease;
}
.btn:hover, .carousel__btn:hover { transform: translateY(-1px); }
.btn:active, .carousel__btn:active { transform: translateY(0); transition-duration: .08s; }
/* call to action: a small primary button that opens an email */
nav .nav-cta { padding-inline: 1.15rem; font-size: .9rem; color: #fff; }
nav .nav-cta:hover { color: #fff; }
@media (max-width: 40rem) { nav a:not(.nav-cta) { display: none; } }

/* Hero: type does the work */
/* the hero fills the first screen below the bar (~4.6rem); the labelled down button says there is more */
.hero {
  position: relative;
  display: grid; gap: 2rem; align-items: center; align-content: center;
  min-height: calc(100svh - 4.6rem); padding-block: 2.5rem 6rem;
}
.hero + .section { border-top: 0; }
.hero__down {
  position: absolute; left: var(--gutter); bottom: 1.5rem;
  display: flex; align-items: center; gap: .75rem;
  color: var(--ink); font-weight: 700; text-decoration: none;
}
.hero__down-icon {
  display: grid; place-items: center; width: 2.75rem; height: 2.75rem;
  border: 1px solid var(--line); border-radius: 50%;
  transition: border-color .25s ease, transform .25s ease;
  /* one nudge after the hero cloud has formed (1 s pause + ~2.6 s draw), then still */
  animation: nudge 1.2s ease-in-out 3.8s 2;
}
.hero__down:hover .hero__down-icon { border-color: var(--ink); transform: translateY(2px); }
.hero__down svg { width: 1.1rem; height: 1.1rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
@keyframes nudge { 0%, 100% { transform: none; } 40% { transform: translateY(6px); } }
.hero__mark { display: block; width: 9rem; height: auto; order: -1; overflow: visible; }
@media (min-width: 60rem) {
  .hero { grid-template-columns: 1.4fr 1fr; }
  /* the logo's cloud, large and drifting off the right edge */
  .hero__mark { order: 0; width: 120%; max-width: none; margin-right: -20%; }
}
/* section headings: plain sentence case in the text face (no tracked all-caps labels) */
.label { font-size: clamp(1.6rem, 3vw, 2.1rem); font-weight: 800; letter-spacing: -.02em; line-height: 1.15; color: var(--ink); }
.hero h1 {
  margin-block: 0 1.75rem;
  font-size: clamp(2.4rem, min(7.5vw, 10svh), 6rem); font-weight: 800; letter-spacing: -.035em;
  max-width: 14ch;
}
.hero__cta { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.75rem; }
/* the badge file is white (for dark backgrounds); shown dark on the light hero */
.hero__partner { height: 34px; width: auto; filter: brightness(0); opacity: .7; }
.lede { font-size: clamp(1.1rem, 2vw, 1.35rem); color: var(--text-2); max-width: 36ch; margin-bottom: 2.25rem; }

/* Buttons */
.btn {
  /* Overpass sits high in its line box: extra top padding re-centres the caps */
  display: inline-block; padding: .95rem 1.4rem .75rem; border-radius: 999px;
  font-weight: 700; text-decoration: none; line-height: 1;
}
@supports (text-box: trim-both cap alphabetic) {
  .btn { text-box: trim-both cap alphabetic; padding-block: 1.05rem; }
}
.btn--primary { background: var(--ink); color: #fff; }
.btn--primary:hover { background: var(--indigo); }
.btn--ghost { color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }
.btn--ghost:hover { box-shadow: inset 0 0 0 1.5px var(--indigo); color: var(--indigo); }

/* Sections: label in a narrow left column, content on the right */
.section { padding-block: var(--section-pad); border-top: 1px solid var(--line); }
.split { display: grid; grid-template-columns: 1fr; gap: 1.5rem; }
@media (min-width: 52rem) { .split { grid-template-columns: 14rem 1fr; gap: 3rem; } }

.services { display: grid; column-gap: 3rem; }
.services li { display: grid; grid-template-columns: 2.5rem 1fr; align-content: start; column-gap: 1rem; padding-block: 1.1rem; border-top: 1px solid var(--line); }
.svc-mark { grid-row: span 2; width: 2.5rem; height: 2.5rem; margin-top: .1rem; }
.svc-mark g { fill: none; stroke: url(#svc-grad); stroke-width: 3.4; stroke-linejoin: round; }
/* holds the shared gradient; must stay rendered (display: none would break the url(#svc-grad) paint) */
.svc-defs { position: absolute; width: 0; height: 0; }
.services li:first-child { border-top: 0; padding-top: 0; }
@media (min-width: 64rem) {
  .services { grid-template-columns: 1fr 1fr; }
  .services li:nth-child(2) { border-top: 0; padding-top: 0; }
}
.services h3 { font-size: 1.3rem; font-weight: 700; letter-spacing: -.01em; }
.services p { color: var(--text-2); }

/* Approach: one flow that splits into two routes and joins again */
#approach .label { margin-bottom: 2rem; }
.flow { display: grid; gap: 1.5rem; justify-items: start; }
/* start and end points: bold text with a solid dot where the lines leave and arrive, not pills (they read as buttons) */
.flow__node { display: flex; align-items: center; gap: .75rem; font-size: 1.2rem; font-weight: 800; letter-spacing: -.01em; line-height: 1; }
.flow__node::after, .flow__node--end::before { content: ""; width: .85rem; height: .85rem; border-radius: 50%; background: #f04a52; flex-shrink: 0; }
.flow__node--end::after { content: none; }
.flow__node--end::before { background: #4e4fad; }
/* stacked layout: both dots lead the text */
@media (max-width: 59.99rem) { .flow__node:not(.flow__node--end) { flex-direction: row-reverse; } }
.flow__join { display: none; }
.flow__lanes { display: grid; gap: 1.5rem; width: 100%; }
.lane { padding: 1.25rem 1.5rem; border-left: 2px solid; border-image: linear-gradient(#f04a52, #4e4fad) 1; }
.lane h3 { margin-bottom: .75rem; font-size: 1rem; font-weight: 700; line-height: 1.4; color: var(--plum); }
.lane ol { display: grid; gap: .5rem; counter-reset: st; }
.lane li { counter-increment: st; }
.lane li::before { content: counter(st) "  "; white-space: pre; font-weight: 700; color: var(--text-2); }
@media (min-width: 40rem) { .flow__lanes { grid-template-columns: 1fr 1fr; } }

/* wide screens: horizontal diagram, nodes centred on the split */
@media (min-width: 60rem) {
  .flow { grid-template-columns: auto 4rem 1fr 4rem auto; gap: 0; align-items: center; justify-items: stretch; }
  .flow__join { display: block; width: 100%; height: 100%; overflow: visible; }
  .flow__join path { fill: none; stroke: #f04a52; stroke-width: 2; vector-effect: non-scaling-stroke; }
  .flow__join--end path { stroke: #4e4fad; }
  .flow__lanes { grid-template-columns: none; gap: 0; }
  /* each lane is half the diagram; its line sits on the lane's middle, where the curves meet it */
  .lane { position: relative; height: 8rem; padding: 0; border: 0; }
  .lane h3 { position: absolute; left: 0; bottom: calc(50% + 1rem); margin: 0; }
  .lane ol {
    /* -1px centres the 2px line on the curves' end points */
    position: absolute; inset: calc(50% - 1px) 0 auto; display: flex; justify-content: space-around; gap: 1rem;
    border-top: 2px solid; border-image: var(--grad) 1;
  }
  .lane li { position: relative; flex: 1; padding-top: .9rem; text-align: center; font-size: .95rem; line-height: 1.3; }
  .lane li::before { content: none; }
  .lane li::after {
    content: ""; position: absolute; left: 50%; top: 0; translate: -50% calc(-50% - 1px);
    width: .75rem; height: .75rem; border-radius: 50%;
    background: var(--paper); border: 2px solid var(--plum);
  }
}

.clients span { color: var(--text-2); }

/* Clients: a continuous horizontal slide; pauses on hover or focus */
#clients .label { margin-bottom: 1.5rem; }
.marquee {
  display: flex; overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
}
.clients { display: flex; flex-shrink: 0; animation: slide 50s linear infinite; }
.marquee:hover .clients, .marquee:focus-within .clients { animation-play-state: paused; }
@keyframes slide { to { transform: translateX(-100%); } }
/* with JS (assets/clients.js): the script moves the row, so it can be dragged and stepped with the arrows */
.carousel { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: .75rem; }
.marquee.is-js { cursor: grab; touch-action: pan-y; user-select: none; }
.marquee.is-js.is-dragging { cursor: grabbing; }
.marquee.is-js .clients { animation: none; will-change: transform; }
.marquee img { -webkit-user-drag: none; }
.carousel__btn {
  display: grid; place-items: center; width: 2.75rem; height: 2.75rem; padding: 0;
  border: 1px solid var(--line); border-radius: 50%; background: var(--paper); color: var(--ink); cursor: pointer;
}
.carousel__btn[hidden] { display: none; }
.carousel__btn:hover { border-color: var(--ink); }
.carousel__btn svg { width: 1.1rem; height: 1.1rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
@media (max-width: 40rem) { .carousel { gap: .25rem; } .carousel__btn { width: 2.25rem; height: 2.25rem; } }
.clients li {
  display: flex; flex-direction: column; gap: 1rem; flex-shrink: 0;
  width: 17rem; padding: 1.5rem 2.5rem 1.5rem 0; margin-right: 2.5rem;
  border-top: 1px solid var(--line); font-size: .95rem;
}
/* logos in their own brand colours, untouched */
/* every logo fits the same 150x36 box so wide and square marks weigh about the same */
.clients img { width: 150px; height: 36px; object-fit: contain; object-position: left center; }

/* Contact: the page ends on the dark band */
.dark { background: var(--ink); color: #fff; }
.dark .contact { padding-block: clamp(4rem, 10vw, 7rem) clamp(3rem, 6vw, 4rem); }
.contact h2 { font-size: clamp(2rem, 5vw, 3.5rem); font-weight: 800; letter-spacing: -.03em; max-width: 18ch; margin-bottom: 2rem; }
.contact p { color: var(--text-2); max-width: 40ch; margin-bottom: 2rem; }
.actions { display: flex; flex-wrap: wrap; gap: .75rem; }
.contact .signature { margin: -.75rem 0 2.5rem; color: rgba(255,255,255,.75); }
.signature b { display: block; color: #fff; }
.contact__mail {
  display: inline-block; margin-bottom: 2.5rem; padding-bottom: .3rem;
  font-size: clamp(1.5rem, 4.5vw, 3rem); font-weight: 300; letter-spacing: -.02em;
  color: #fff; text-decoration: none; overflow-wrap: anywhere;
  background: linear-gradient(90deg, #f04a52, #8a96e6) no-repeat 0 100% / 100% 3px;
}
.contact__mail:hover { color: #ffb3ad; }
.dark :focus-visible { outline-color: #8a96e6; }
.btn--light { background: #fff; color: var(--ink); }
.btn--light:hover { background: #e7e6f6; }
.btn--ghost-light { color: #fff; box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.5); }
.btn--ghost-light:hover { box-shadow: inset 0 0 0 1.5px #fff; }
.partner { display: block; margin-top: clamp(3rem, 8vw, 5rem); height: 40px; width: auto; opacity: .9; }

.foot {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem 2rem;
  padding-block: 2rem; border-top: 1px solid rgba(255,255,255,.14);
  font-size: .85rem; line-height: 1.5; color: rgba(255,255,255,.65);
}
