/* GroupOliver — brand tokens (mix of Plaquette + Source/delivery) */
:root {
  /* Gold preserved for the logo only */
  --or: #C4921A;
  --or-dim: #A07712;
  --or-soft: rgba(196, 146, 26, 0.12);
  --or-line: rgba(196, 146, 26, 0.35);
  /* Source/delivery cyan — primary accent for links, highlights, eyebrows */
  --cyan: #3BC8FF;
  --cyan-dim: #1FA8DC;
  --cyan-soft: rgba(59,200,255,0.14);
  /* Source/delivery near-black */
  --noir: #0E1216;
  --noir-deep: #070A0D;
  --noir-muted: #4A5159;
  --gris: #8A9099;
  --blanc: #FFFFFF;
  --creme: #F4F2EC;
  --rule: rgba(14,18,22,0.10);
  --rule-strong: rgba(14,18,22,0.22);

  --ff-display: "Raleway", "Helvetica Neue", Arial, sans-serif;
  --ff-headline: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --ff-body: "Nunito Sans", "Helvetica Neue", Arial, sans-serif;

  --max-w: 1280px;
  --gutter: clamp(20px, 4vw, 56px);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--ff-body);
  font-weight: 300;
  font-size: 14px;
  line-height: 1.65;
  color: var(--noir);
  background: var(--creme);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: inherit; text-decoration: none; }
a:hover { color: var(--cyan); }

/* Inline cyan emphasis links — Source/delivery treatment */
.cy { color: var(--cyan); }
.cy-link { color: var(--cyan); border-bottom: 1px solid currentColor; padding-bottom: 1px; }

img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; }

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

/* Type scale — Plaquette light + Source/delivery bold uppercase headlines */
h1, h2, h3, h4 { margin: 0; color: var(--noir); }
h1 { font-family: var(--ff-headline); font-weight: 800; font-size: clamp(40px, 6.5vw, 92px); line-height: 1.0; letter-spacing: -0.02em; text-transform: uppercase; }
h2 { font-family: var(--ff-headline); font-weight: 700; font-size: clamp(30px, 4vw, 56px); line-height: 1.05; letter-spacing: -0.015em; text-transform: uppercase; }
h3 { font-family: var(--ff-display); font-weight: 300; font-size: clamp(20px, 2vw, 26px); line-height: 1.25; }
h4 { font-family: var(--ff-display); font-weight: 400; font-size: 16px; line-height: 1.3; }

p { margin: 0 0 1em; }

.eyebrow {
  font-family: var(--ff-body);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--cyan);
}
.eyebrow.gold { color: var(--or); }
.eyebrow.muted { color: var(--noir-muted); }

.numeral {
  font-family: var(--ff-display);
  font-weight: 100;
  font-size: 28px;
  color: var(--or);
  display: inline-block;
  margin-right: 8px;
  letter-spacing: -0.01em;
}

.gold-rule {
  width: 36px;
  height: 1px;
  background: var(--or);
  display: block;
  margin: 14px 0;
}

.rule { border: 0; height: 1px; background: var(--rule); margin: 0; }

/* ========== HEADER ========== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--creme);
  border-bottom: 1px solid var(--rule);
  backdrop-filter: blur(8px);
  background: rgba(248, 246, 240, 0.92);
}
.site-header .inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 78px;
  gap: 24px;
}
.site-nav {
  display: flex;
  align-items: center;
  gap: 36px;
}
.site-nav a {
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--noir-muted);
  position: relative;
  padding: 6px 0;
  transition: color .2s;
}
.site-nav a:hover, .site-nav a.active { color: var(--noir); }
.site-nav a.active::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -2px;
  height: 2px; background: var(--cyan);
}

.lang-switch {
  display: flex;
  align-items: center;
  gap: 0;
  border: 1px solid var(--rule-strong);
  border-radius: 0;
}
.lang-switch button {
  background: transparent;
  border: 0;
  font-family: var(--ff-body);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--gris);
  padding: 7px 10px;
  border-right: 1px solid var(--rule-strong);
}
.lang-switch button:last-child { border-right: 0; }
.lang-switch button.active { color: var(--noir); background: var(--blanc); }
.lang-switch button:hover { color: var(--noir); }

/* ========== LOGO ========== */
.logo {
  font-family: var(--ff-display);
  font-weight: 300;
  font-size: 28px;
  line-height: 1;
  letter-spacing: -0.005em;
  display: inline-flex;
  align-items: baseline;
  position: relative;
  padding-bottom: 6px;
  color: var(--noir);
}
.logo .l-group { color: var(--noir); position: relative; }
/* Gold underline runs across "Group" */
.logo .l-underline {
  position: absolute;
  bottom: -5px;
  height: 1.5px;
  background: var(--or);
  /* width set inline based on the Group span */
}
.logo .l-o { color: var(--or); }
.logo .l-liver { color: var(--noir); }
/* Triangle points UP (▲) — not down */
.logo .l-tri {
  display: inline-block;
  width: 0; height: 0;
  border-left: 12px solid transparent;
  border-right: 12px solid transparent;
  border-bottom: 18px solid var(--noir);
  margin-left: 6px;
  transform: translateY(-1px);
}
.logo small {
  display: block;
  font-family: var(--ff-body);
  font-weight: 400;
  font-size: 8px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gris);
  margin-top: 5px;
}

/* On dark backgrounds — triangle becomes gold */
.logo.on-dark .l-group, .logo.on-dark .l-liver { color: var(--blanc); }
.logo.on-dark .l-tri { border-bottom-color: var(--or); }
.logo.on-dark small { color: rgba(240,240,240,0.6); }

/* On gold backgrounds — triangle and "O" become noir */
.logo.on-gold .l-group, .logo.on-gold .l-liver, .logo.on-gold .l-o { color: var(--noir); }
.logo.on-gold .l-tri { border-bottom-color: var(--noir); }
.logo.on-gold .l-underline { background: var(--noir); }
.logo.on-gold small { color: rgba(43,39,34,0.55); }

/* ========== BUTTONS ========== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px;
  font-family: var(--ff-body);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  border: 1px solid var(--noir);
  background: var(--noir);
  color: var(--creme);
  transition: all .2s ease;
  cursor: pointer;
}
.btn:hover { background: var(--cyan); border-color: var(--cyan); color: var(--noir); }
.btn-ghost {
  background: transparent;
  color: var(--noir);
  border: 1px solid var(--noir);
}
.btn-ghost:hover { background: var(--noir); color: var(--creme); }
.btn-link {
  background: transparent;
  border: 0;
  padding: 0;
  color: var(--noir);
  font-family: var(--ff-body);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
}
.btn-link::after {
  content: "→";
  transition: transform .2s;
}
.btn-link:hover { color: var(--cyan); }
.btn-link:hover::after { transform: translateX(4px); }

/* ========== SECTION ========== */
section { padding: clamp(72px, 9vw, 120px) 0; }
section.tight { padding: clamp(48px, 6vw, 80px) 0; }
.section-head {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 40px;
  margin-bottom: 56px;
}
@media (max-width: 800px) {
  .section-head { grid-template-columns: 1fr; gap: 16px; margin-bottom: 32px; }
}

.section-num {
  font-family: var(--ff-headline);
  font-weight: 800;
  font-size: 72px;
  line-height: 1;
  color: var(--cyan);
  opacity: 0.95;
}

/* ========== FOOTER ========== */
.site-footer {
  background: var(--noir);
  color: var(--blanc);
  padding: 80px 0 28px;
  font-size: 13px;
}
.site-footer .grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 56px;
  border-bottom: 1px solid rgba(240,240,240,0.10);
}
@media (max-width: 800px) {
  .site-footer .grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}
.site-footer h5 {
  font-family: var(--ff-body);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--cyan);
  margin: 0 0 18px;
}
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 10px; color: rgba(240,240,240,0.7); }
.site-footer li a:hover { color: var(--cyan); }
.site-footer .legal {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 22px;
  font-size: 11px;
  color: rgba(240,240,240,0.45);
  letter-spacing: 0.06em;
}
.site-footer .tagline {
  font-family: var(--ff-headline);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(240,240,240,0.55);
  margin-top: 8px;
}

/* ========== UTILITIES ========== */
.gold { color: var(--or); }
.muted { color: var(--noir-muted); }
.center { text-align: center; }

/* Arrow utility — Source/delivery hallmark, framed ↗ */
.arr {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px; height: 22px;
  border: 1px solid currentColor;
  font-size: 12px;
  line-height: 1;
  flex-shrink: 0;
  color: var(--noir);
}
.arr::before { content: "↗"; transform: translateY(-1px); }
.arr.cy { color: var(--cyan); }
.arr.light { color: var(--creme); }
.arr.lg { width: 32px; height: 32px; font-size: 16px; }

/* Triangle utility — reserved for the logo mark only now */
.tri {
  display: inline-block;
  width: 0; height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-bottom: 7px solid var(--or);
}
.tri.lg {
  border-left-width: 9px;
  border-right-width: 9px;
  border-bottom-width: 13px;
}
.tri.dark { border-bottom-color: var(--noir); }
.tri.light { border-bottom-color: var(--creme); }
.tri.cy { border-bottom-color: var(--cyan); }

/* Placeholder image */
.ph {
  background:
    repeating-linear-gradient(135deg,
      rgba(13,13,13,0.04) 0,
      rgba(13,13,13,0.04) 1px,
      transparent 1px,
      transparent 8px),
    var(--blanc);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gris);
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.ph.dark {
  background:
    repeating-linear-gradient(135deg,
      rgba(255,255,255,0.04) 0,
      rgba(255,255,255,0.04) 1px,
      transparent 1px,
      transparent 8px),
    #1a1a1a;
  color: rgba(240,240,240,0.45);
}

/* Card */
.card {
  background: var(--blanc);
  border: 1px solid var(--rule);
  padding: 32px 28px;
  transition: border-color .2s, transform .2s;
}
.card:hover { border-color: var(--cyan); }

/* Diagonal mask — Source/delivery hallmark for image cuts */
.diag-l { clip-path: polygon(0 0, 100% 0, 100% 100%, 18% 100%); }
.diag-r { clip-path: polygon(0 0, 82% 0, 100% 100%, 0 100%); }
.diag-bl { clip-path: polygon(20% 0, 100% 0, 100% 100%, 0 100%); }

/* Footer ribbon at section bottoms (Source/delivery footer line) */
.ribbon-foot {
  font-family: var(--ff-headline);
  font-weight: 700;
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--noir-muted);
  border-top: 1px solid var(--rule);
  padding: 14px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Tweaks-only utility (will be set by JS) */
[data-density="airy"] section { padding: clamp(96px, 11vw, 160px) 0; }
[data-density="dense"] section { padding: clamp(56px, 7vw, 88px) 0; }

/* ============ Accessibility ============ */
/* Skip link — invisible until keyboard-focused */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 10000;
  background: var(--noir);
  color: var(--blanc);
  padding: 12px 18px;
  font-size: 13px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-weight: 600;
}
.skip-link:focus, .skip-link:focus-visible {
  left: 16px;
  top: 16px;
  outline: 2px solid var(--cyan);
  outline-offset: 2px;
}

/* Visible focus ring for keyboard navigation across all interactive elements */
:focus { outline: none; }
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 2px;
}
main:focus { outline: none; }

/* ============ Responsive ============ */
/* Many layouts use inline gridTemplateColumns in JSX (style={{...}}), which
   external CSS can only override with `!important`. The blocks below target
   that pattern via the [style*="..."] attribute selector — pragmatic and
   surgical: they kick in only at narrow viewports, and the cascade leaves
   desktop styling untouched. */

/* Tablet: shrink 4-col grids to 2-col (covers domain index, advantages, etc.) */
@media (max-width: 1024px) and (min-width: 721px) {
  main [style*="grid-template-columns: repeat(4"] {
    grid-template-columns: repeat(2, 1fr) !important;
  }
  main [style*="gap: 80px"], main [style*="gap: 60px"] {
    gap: 40px !important;
  }
}

/* Mobile: collapse every inline grid to a single column, wrap the header,
   and pull oversized inline paddings down to mobile-sane values. */
@media (max-width: 720px) {
  /* Header — let logo + lang on top row and nav wrap below, scroll if needed */
  .site-header .inner {
    flex-wrap: wrap;
    height: auto;
    padding: 12px 0;
    gap: 12px;
  }
  .site-nav {
    order: 3;
    flex-basis: 100%;
    justify-content: flex-start;
    gap: 18px;
    overflow-x: auto;
    padding-bottom: 4px;
  }
  .site-nav a {
    font-size: 11px;
    letter-spacing: 0.1em;
    flex-shrink: 0;
  }
  .lang-switch button { padding: 4px 6px; font-size: 11px; }

  /* Every inline grid in the main content area collapses to one column */
  main [style*="grid-template-columns"] {
    grid-template-columns: 1fr !important;
    gap: 24px !important;
  }

  /* Footer grid simplifies fully */
  .site-footer .grid { grid-template-columns: 1fr !important; gap: 28px !important; }

  /* Tame oversized inline paddings (cards, sections) */
  main [style*="padding: 48px 40px"],
  main [style*="padding: 40px 36px"],
  main [style*="padding: 32px 28px"] {
    padding: 26px 20px !important;
  }
  main [style*="padding-top: 60px"] { padding-top: 32px !important; }
  main [style*="padding-bottom: 60px"] { padding-bottom: 32px !important; }
  main [style*="padding-bottom: 64px"] { padding-bottom: 32px !important; }

  /* CTA block (chrome.jsx CtaBlock) is inline gridded too — flatten */
  section [style*="grid-template-columns: 1.2fr 1fr"] {
    grid-template-columns: 1fr !important;
    gap: 28px !important;
  }
  section [style*="justify-content: flex-end"] { justify-content: flex-start !important; }

  /* Hero typography pull-down so it fits a 360px viewport */
  h1 { font-size: clamp(36px, 9vw, 56px) !important; line-height: 1.05 !important; }
  h2 { font-size: clamp(26px, 7vw, 40px) !important; }

  /* Aspect-ratio cards sometimes have minHeight inline that's too tall */
  main [style*="min-height: 400px"] { min-height: 240px !important; }

  /* Slideshow on the coverage page — shorter on mobile */
  section [style*="min(78vh, 680px)"] { height: min(60vh, 460px) !important; }

  /* Make sure no horizontal overflow leaks */
  body { overflow-x: hidden; }
}

/* Honour user motion preferences */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
