/* GUANVI editorial design tokens, shared header, footer and page components. */

html:has(body.editorial) {
  --header-h: 84px;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body.editorial {
  --sans: "Helvetica Neue", "Neue Haas Grotesk Text Pro", Arial, sans-serif;
  --serif: "Iowan Old Style", Baskerville, "Times New Roman", serif;
  --white: #fffef9;
  --paper: #f1f0ea;
  --paper-2: #f8f7f2;
  --paper-3: #e8e7e0;
  --ink: #191b19;
  --ink-2: #292c28;
  --ink-3: #101211;
  --muted: #666960;
  --line: #c9c9c0;
  --line-2: #b5b5ac;
  --accent: #d94c2b;
  --accent-dark: #ba3b1e;
  --accent-light: #f0c8bc;
  --accent-wash: #f6e0d9;
  --on-ink: #fffef9;
  --on-ink-muted: #a6aaa0;
  --maxw: 1600px;
  --gutter: clamp(20px, 3.4vw, 52px);
  --section-y: clamp(76px, 8.5vw, 140px);
  --radius: 0;
  --glass-light: rgba(248, 247, 242, .96);
  --glass-border: rgba(201, 201, 192, .9);
  --glass-shadow: 0 18px 46px -22px rgba(25, 27, 25, .18), 0 2px 7px rgba(25, 27, 25, .04);
  --surface-shadow: 0 22px 60px -35px rgba(25, 27, 25, .18);
  --home-easing: cubic-bezier(.22, .68, 0, 1);
  --ease: 220ms var(--home-easing);
  --orange: #d94c2b;
  --orange-dark: #ba3b1e;
  background: var(--paper);
  color: var(--ink);
}

/* Header and navigation */
body.editorial .site-header {
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  max-width: none;
  margin: 0;
  border-radius: 0;
  background: rgba(241, 240, 234, .97);
  border: 0;
  border-bottom: 1px solid var(--line);
  box-shadow: none;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  z-index: 100;
}
body.editorial .site-header.is-scrolled { box-shadow: none; }
body.editorial .site-header::before,
body.editorial .site-header::after { content: none; }
body.editorial .nav-shell {
  max-width: var(--maxw);
  min-height: var(--header-h);
  padding-inline: var(--gutter);
  margin-inline: auto;
  gap: clamp(18px, 3vw, 48px);
}
body.editorial .brand {
  font-size: 1.04rem;
  font-weight: 650;
  letter-spacing: .18em;
  gap: 12px;
}
body.editorial .brand-mark {
  width: 30px;
  height: 30px;
  border-radius: 3px;
  border-color: var(--ink);
}
body.editorial .brand-mark::before,
body.editorial .brand-mark::after { border-color: var(--ink); }
body.editorial .site-header .brand-mark {
  flex-basis: 30px;
  border: 0;
  background: url("../assets/favicon.svg") center / contain no-repeat;
}
body.editorial .site-header .brand-mark::before,
body.editorial .site-header .brand-mark::after { content: none; }
body.editorial .brand-word { letter-spacing: .18em; }

body.editorial .nav-links {
  gap: clamp(20px, 2.2vw, 38px);
}
body.editorial .nav-links a {
  min-height: 44px;
  font-size: .76rem;
  font-weight: 500;
  color: var(--ink-2);
  border-bottom: 0;
  position: relative;
}
body.editorial .nav-links a::after {
  content: "";
  position: absolute;
  inset: auto 0 7px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform .45s var(--home-easing);
}
body.editorial .nav-links a:hover::after,
body.editorial .nav-links a:focus-visible::after,
body.editorial .nav-links a.active::after,
body.editorial .nav-links a[aria-current="page"]::after {
  transform: scaleX(1);
  transform-origin: left;
}

body.editorial .nav-cta {
  min-height: 44px;
  padding: 0 17px;
  border-radius: 0;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: var(--white);
  font-size: .74rem;
  font-weight: 550;
  letter-spacing: .02em;
  display: inline-flex;
  align-items: center;
  gap: 24px;
  box-shadow: none;
  transition: background-color .25s ease, color .25s ease, border-color .25s ease;
}
body.editorial .nav-cta:hover {
  background: var(--orange-dark);
  border-color: var(--orange-dark);
  color: var(--white);
}
body.editorial .nav-cta span { transition: transform .3s var(--home-easing); }
body.editorial .nav-cta:hover span { transform: translate(3px,-3px); }

body.editorial .lang-dropdown--desktop { display: block; }
body.editorial .lang-dropdown summary {
  min-height: 44px;
  padding: 0 12px;
  border-radius: 0;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  font-size: .73rem;
  font-weight: 600;
  letter-spacing: .05em;
  gap: 8px;
}
body.editorial .lang-globe { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1; }
body.editorial .lang-dropdown summary::after {
  content: "";
  width: 5px;
  height: 5px;
  border: solid currentColor;
  border-width: 0 1px 1px 0;
  transform: translateY(-1px) rotate(45deg);
}
body.editorial .lang-dropdown[open] summary::after { transform: translateY(1px) rotate(225deg); }
body.editorial .lang-compact { display: none; }
body.editorial .lang-label, body.editorial .lang-total { color: var(--muted); font-size: .65rem; font-weight: 500; }
body.editorial .lang-dropdown summary:hover,
body.editorial .lang-dropdown[open] summary { border-color: var(--ink); background: var(--paper-2); }
body.editorial .lang-panel {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  width: min(400px, calc(100vw - 40px));
  max-height: calc(100svh - var(--header-h) - 16px);
  overflow: auto;
  overscroll-behavior: contain;
  background: var(--paper-2);
  border: 1px solid var(--ink);
  box-shadow: 8px 8px 0 rgba(25, 27, 25, .12);
}
body.editorial .lang-dropdown:not([open]) .lang-panel { display: none; }
body.editorial .lang-dropdown[open] .lang-panel { animation: home-language-in .25s ease both; }
@keyframes home-language-in { from { opacity: 0; transform: translateY(-6px); } }
body.editorial .lang-current {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: var(--ink);
  color: var(--white);
  font-size: .78rem;
}
body.editorial .lang-dropdown .lang-options {
  position: static;
  width: auto;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  max-height: none;
  padding: 0 12px;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  backdrop-filter: none;
}
body.editorial .lang-options a {
  min-height: 44px;
  display: flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 0;
  border-bottom: 1px solid var(--line);
  font-size: .83rem;
  color: var(--ink);
  white-space: normal;
  overflow-wrap: anywhere;
}
body.editorial .lang-options a:hover,
body.editorial .lang-options a:focus-visible { background: var(--paper); color: var(--orange-dark); }
body.editorial .lang-options a[aria-current="true"] { background: var(--accent-wash); color: var(--orange-dark); }
body.editorial .lang-panel > p { margin: 14px 16px; color: var(--muted); font-size: .7rem; }

@media (max-width: 1240px) {
  body.editorial .site-header .nav-links {
    top: 100%;
    background: var(--paper-2);
    border: 1px solid var(--line);
    border-radius: 0;
    box-shadow: var(--glass-shadow);
    max-height: calc(100svh - var(--header-h) - 12px);
  }
  body.editorial .nav-links a { white-space: normal; border-radius: 0; }
  body.editorial .nav-tools { gap: 10px; }
  body.editorial .lang-label,
  body.editorial .lang-code,
  body.editorial .lang-total { display: none; }
  body.editorial .lang-compact { display: inline; font-size: .69rem; line-height: 1.2; text-wrap: balance; overflow-wrap: anywhere; }
  body.editorial .lang-globe { flex: 0 0 16px; }
}

body.editorial .nav-toggle {
  border: 1px solid var(--line);
  border-radius: 0;
}
body.editorial .nav-toggle span,
body.editorial .nav-toggle::before,
body.editorial .nav-toggle::after { background: var(--ink); }

body.editorial .closing {
  padding: clamp(72px, 8vw, 128px) 0;
  background: var(--orange-dark);
  color: var(--white);
}
body.editorial .closing-inner { gap: clamp(40px, 8vw, 100px); }
body.editorial .closing-inner > * { min-width: 0; }
body.editorial .closing h2 {
  overflow-wrap: anywhere;
  max-width: 14ch;
  margin: 0;
  font-size: clamp(2.75rem, 5.6vw, 5.8rem);
  line-height: .91;
  letter-spacing: -.065em;
}
body.editorial .closing h2 em {
  font-family: var(--serif);
  font-weight: 400;
  font-style: normal;
}
body.editorial .closing p {
  max-width: 51ch;
  color: var(--white);
  font-size: 1rem;
  line-height: 1.65;
}
body.editorial .closing .eyebrow { color: var(--white); }
body.editorial .closing .btn {
  border-radius: 0;
  background: var(--ink);
  border-color: var(--ink);
  color: var(--white);
  box-shadow: none;
}


/* Footer */
body.editorial .site-footer {
  background: var(--ink);
  color: var(--white);
  padding-top: clamp(60px, 7vw, 100px);
}
body.editorial .site-footer .brand,
body.editorial .site-footer h4 { color: var(--white); }
body.editorial .site-footer .brand-mark { border-color: var(--white); }
body.editorial .site-footer .brand-mark::before,
body.editorial .site-footer .brand-mark::after { border-color: var(--white); }
body.editorial .site-footer p,
body.editorial .site-footer li { color: #a6aaa0; }
body.editorial .site-footer a { color: var(--white); }
body.editorial .site-footer a:hover { color: var(--orange); }
body.editorial .footer-grid {
  display: grid;
  grid-template-columns: 2.2fr .7fr 1fr;
  gap: clamp(48px, 9vw, 140px);
  padding-bottom: clamp(70px, 9vw, 130px);
}
body.editorial .footer-brand > p {
  max-width: 49ch;
  margin-top: 30px;
  font-size: .82rem;
  line-height: 1.75;
}
body.editorial .footer-bottom {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 30px;
  align-items: center;
  padding-top: 24px;
  border-top: 1px solid #3b3e38;
  color: #a6aaa0;
  font-size: .63rem;
}
body.editorial .footer-bottom > a { justify-self: end; }

@media (max-width: 700px) {
  html:has(body.editorial) { --header-h: 68px; }
  body.editorial .nav-shell { gap: 6px; }
  body.editorial .brand { font-size: .88rem; gap: 9px; }
  body.editorial .brand-word { letter-spacing: .14em; }
  body.editorial .nav-tools { gap: 7px; }
  body.editorial .nav-tools .lang-dropdown { flex: 0 1 auto; min-width: 0; }
  body.editorial .nav-toggle { width: 44px; height: 44px; flex-basis: 44px; }
  body.editorial .lang-dropdown summary { min-width: 70px; padding-inline: 8px; gap: 6px; }
  body.editorial .site-header .nav-cta { display: none; }
  body.editorial .lang-panel { position: fixed; top: calc(var(--header-h) + 6px); left: 16px; right: 16px; width: auto; }
  body.editorial .closing h2 { font-size: clamp(2.65rem, 10.5vw, 4rem); }
  body.editorial .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 48px 28px; overflow-wrap: anywhere; }
  body.editorial .footer-brand { grid-column: 1 / -1; }
  body.editorial .footer-bottom { grid-template-columns: 1fr auto; gap: 12px 20px; }
  body.editorial .footer-bottom > p { grid-column: 1 / -1; }
}

@media (max-width: 360px) {
  body.editorial .nav-shell { padding-inline: 16px; gap: 8px; }
  body.editorial .brand { font-size: .78rem; letter-spacing: .12em; gap: 8px; }
  body.editorial .brand-mark { width: 24px; height: 24px; }
  body.editorial .lang-dropdown summary { min-width: 44px; padding: 0 7px; }
  body.editorial .nav-toggle { width: 44px; }
  body.editorial .closing h2 { font-size: 2.55rem; }
}

/* Each interior keeps its own layout while using the same typography and surfaces. */
body.editorial:not(.homepage) { --section-y: clamp(48px, 7vw, 112px); }
body.editorial .page-hero,
body.editorial .page-hero:not(.corp-hero):not(.page-hero--contact) {
  padding-block: clamp(48px, 7vw, 102px);
  color: var(--ink);
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}
body.editorial .page-hero::before { content: none; }
body.editorial .eyebrow { color: var(--orange-dark); }
body.editorial .closing .eyebrow { color: inherit; }

body.editorial .editorial-intro {
  display: grid;
  grid-template-columns: minmax(0, 1.22fr) minmax(0, .78fr);
  align-items: end;
  gap: clamp(28px, 6vw, 92px);
}
body.editorial .page-hero .display {
  max-width: 19ch;
  margin: 0;
  font-size: clamp(2.55rem, 5.85vw, 5.8rem);
  font-weight: 500;
  line-height: 1.02;
  letter-spacing: -.055em;
  color: var(--ink);
  overflow-wrap: anywhere;
  text-wrap: balance;
}
body.editorial .page-hero .display em {
  color: var(--orange-dark);
  font-family: var(--serif);
  font-weight: 400;
}
body.editorial .page-hero .lead { color: var(--ink-2); margin-block: 0; }
body.editorial .editorial-summary { min-width: 0; padding-bottom: 3px; }
body.editorial .corp-hero--about .editorial-intro { grid-template-columns: minmax(0, 1fr) minmax(0, .85fr); }
body.editorial .corp-hero--caps .editorial-intro { grid-template-columns: minmax(0, .98fr) minmax(0, 1fr); }
body.editorial .corp-hero--how .editorial-intro { grid-template-columns: minmax(0, 1fr); gap: 24px; }
body.editorial .corp-hero--how .display { max-width: 22ch; }

body.editorial .btn:not(.btn--outline, .btn--light) {
  border-radius: 0;
  color: var(--white);
  background: var(--ink);
  border-color: var(--ink);
  box-shadow: none;
}
body.editorial .btn:not(.btn--outline, .btn--light):hover {
  background: var(--orange-dark);
  border-color: var(--orange-dark);
}
body.editorial .closing .btn:hover {
  background: var(--white);
  border-color: var(--white);
  color: var(--ink);
}
body.editorial .btn--outline { border-radius: 0; }
body.editorial .btn, body.editorial .text-link { white-space: normal; overflow-wrap: anywhere; }
body.editorial .skip-link:focus { top: 12px; }
body.editorial :is(.btn, .text-link, .nav-toggle, .working-examples > summary):focus-visible { outline: 2px solid var(--orange-dark); outline-offset: 3px; }

body.editorial :is(.supply-detail, .methods-section, .reference-section, .about-section, .section--white) { background: var(--paper-2); }
body.editorial :is(.engagement-section, .mandate-section, .delivery-section) { background: var(--paper); }
body.editorial :is(.engagement-options article, .scope-strip, .cooperation-note, .cap-case, .chapter-output, .delivery-aside hr) { border-color: var(--line); }
body.editorial :is(.chapter-number, .capability-core .method-number, .stage-number, .chapter-output h3) { color: var(--orange-dark); }
body.editorial .supply-chapter {
  grid-template-columns: minmax(0, .72fr) minmax(0, 1.28fr);
  gap: clamp(28px, 6vw, 92px);
  scroll-margin-top: 0;
}
body.editorial .chapter-heading h2 {
  font-size: clamp(1.7rem, 3vw, 2.8rem);
  line-height: 1.08;
}
body.editorial .chapter-heading .text-link { min-height: 44px; }
body.editorial .chapter-body p { max-width: 66ch; line-height: 1.62; }
body.editorial .chapter-block + .chapter-block { margin-top: 22px; }
body.editorial .chapter-block h3,
body.editorial .chapter-output h3 {
  margin: 0 0 7px;
  color: var(--orange-dark);
  font-size: .82rem;
  font-weight: 650;
  letter-spacing: .035em;
}
body.editorial .chapter-block p { margin: 0; }
body.editorial .chapter-output .feature-list li { padding-block: 5px; font-size: .91rem; }
body.editorial .chapter-fit { border-color: var(--line-2); }
body.editorial .supply-path a:focus-visible { outline: 2px solid var(--orange-dark); outline-offset: 5px; }
@media (max-width: 760px) {
  body.editorial .supply-chapter { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  body.editorial .chapter-block + .chapter-block { margin-top: 18px; }
}
body.editorial .supply-path .path-num,
body.editorial .stage-number { border-color: var(--line-2); border-radius: 0; background: var(--paper-2); }
body.editorial :is(.working-examples, .delivery-aside, .form-wrap, .info-card) {
  border: 1px solid var(--line);
  border-radius: 0;
  background: var(--paper-2);
  box-shadow: none;
}
body.editorial .working-examples[open] > summary { border-color: var(--line); }
body.editorial .delivery-aside { top: calc(var(--header-h) + 26px); margin-top: 0; }
body.editorial .capability-object {
  top: calc(var(--header-h) + 26px);
  background: var(--ink);
  border-radius: 0;
  border-color: var(--line);
  box-shadow: none;
}
body.editorial .capability-object img { filter: grayscale(1) brightness(1.15); }
body.editorial .capability-object figcaption { color: var(--on-ink-muted); }
body.editorial .capability-object .network-label { background: var(--paper-2); color: var(--ink); border-radius: 0; border-color: var(--line); }
body.editorial .capability-object .network-hub { color: var(--white); background: var(--ink-2); border-color: var(--line-2); border-radius: 0; box-shadow: none; }

body.editorial .about-brand-panel {
  top: calc(var(--header-h) + 26px);
  min-height: clamp(185px, 19vw, 275px);
  color: var(--white);
  background: var(--ink);
  border: 0;
  border-radius: 0;
  box-shadow: none;
}
body.editorial .about-brand-panel::after { inset: 12px; border-radius: 0; }
body.editorial .about-brand-panel p { color: var(--on-ink-muted); }
body.editorial .cap-case dt { color: var(--orange-dark); }

body.editorial .page-hero--contact .display { max-width: 15ch; }
body.editorial .contact-layout { grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr); }
body.editorial .contact-quick { flex-wrap: wrap; }
body.editorial .contact-quick a { color: var(--ink); }
body.editorial .contact-quick .text-link { min-height: 44px; }
body.editorial .contact-quick a:hover { color: var(--orange-dark); }
body.editorial .form-wrap { border-top: 2px solid var(--orange-dark); }
body.editorial .info-card--direct { background: var(--paper); }
body.editorial .form-wrap :is(input, select, textarea):focus-visible { outline: 2px solid var(--orange-dark); outline-offset: 2px; }

@media (max-width: 860px) {
  body.editorial .editorial-intro,
  body.editorial .corp-hero--about .editorial-intro,
  body.editorial .corp-hero--caps .editorial-intro,
  body.editorial .contact-layout { grid-template-columns: minmax(0, 1fr); }
  body.editorial .capability-object, body.editorial .about-brand-panel { top: auto; }
}
@media (max-width: 700px) {
  body.editorial .page-hero:not(.corp-hero):not(.page-hero--contact) { padding-top: 44px; }
  body.editorial .page-hero .display {
    font-size: clamp(2.2rem, 9.2vw, 4rem);
    letter-spacing: -.045em;
  }
  body.editorial .form-wrap { margin-top: 0; }
  body.editorial .delivery-aside { position: static; }
  body.editorial .about-brand-panel p { bottom: 24px; }
}

/* Plain links remain available when the mobile disclosure cannot initialize. */
@media (max-width: 1240px) and (scripting: none) {
  body.editorial .site-header { position: static; }
  body.editorial .nav-shell { display: grid; grid-template-columns: 1fr auto; padding-block: 8px; gap: 4px 8px; }
  body.editorial .nav-tools { display: contents; }
  body.editorial .nav-tools > nav { grid-area: 2 / 1 / 3 / -1; }
  body.editorial .nav-toggle,
  body.editorial .site-header .nav-cta { display: none; }
  body.editorial .site-header .nav-links {
    position: static;
    display: flex;
    flex-flow: row wrap;
    gap: 0 12px;
    max-height: none;
    padding: 0;
    border: 0;
    box-shadow: none;
    background: transparent;
  }
  body.editorial .nav-links li { display: block; border: 0; }
  body.editorial .nav-links a { padding-inline: 3px; }
  body.editorial .lang-dropdown { grid-area: 1 / 2; }
  body.editorial .lang-panel { top: calc(100% + 6px); }
}
@media (max-width: 700px) and (scripting: none) {
  body.editorial .lang-panel { top: 60px; }
}

/* Reading and interaction states for the shared form and working documents. */
body.editorial .word-unit { white-space: nowrap; }
body.editorial .form-wrap :is(input, select, textarea):not([type="hidden"]) { border-color: #827e72; }
body.editorial .form-wrap .is-invalid :is(input, select, textarea) { border-color: #a33a26; }
body.editorial .form-wrap :is(input, select, textarea):focus { border-color: var(--ink); }
body.editorial .form-wrap :is(input, select, textarea):focus-visible,
body.editorial .table-wrap:focus-visible {
  outline: 2px solid var(--orange-dark);
  outline-offset: 2px;
}
body.editorial .form-wrap :is(button, input, select, textarea):disabled {
  background: var(--paper-3);
  border-color: #827e72;
  color: var(--ink-2);
  cursor: wait;
}
body.editorial .form-status { margin: 0; }
body.editorial .form-status:not(:empty) {
  margin-block: 12px;
  padding: 8px 12px;
  border-inline-start: 2px solid var(--ink);
  font-size: .9rem;
}
body.editorial .form-status:is([data-state="unknown"], [data-state="failed"]) { border-color: var(--orange-dark); }
body.editorial .details-guide { color: var(--ink-2); border-color: var(--orange-dark); }
body.editorial .sample-scroll-hint { display: none; }
@media (max-width: 700px) {
  body.editorial .sample-scroll-hint { display: block; }
  body.editorial .doc-table { min-width: 36rem; }
}
