/* ==========================================================================
   Apheresa — IPFA
   Single-page marketing site. No JavaScript.
   Design language: "the typeset ledger" — warm paper, iron-gall navy ink,
   pale ledger feints, an IPFA-blue margin rule, tabular figures.
   ========================================================================== */

:root {
  --paper: #faf9f4;
  --paper-raised: #fffefb;
  --paper-deep: #f1efe6;
  --ink: #1c2b39;
  --ink-soft: #51606e;
  /* Faintest text tone still allowed: 4.65:1 on --paper-deep, the darkest
     surface it ever sits on (WCAG 1.4.3 needs 4.5:1 for this size). */
  --ink-faint: #616c78;
  --feint: #c9d8e4;
  --feint-weak: #e2eaf1;
  /* Boundary of an interactive control that has no fill of its own.
     3.4:1 on --paper — WCAG 1.4.11 needs 3:1. --feint is decorative only. */
  --edge-ui: #7a8896;
  /* IPFA blue. --seal is the brand's light-mode value; --seal-deep is it
     darkened to 0.84 for hover and emphasis, the same step the palette used
     before. --seal-on-ink is the brand's dark-mode value, and belongs on
     --ink surfaces only: it is too light to hold 4.5:1 on paper. */
  --seal: #2a56aa;
  --seal-deep: #234890;
  --seal-on-ink: #4e80ee;
  --credit: #1e6e51;

  --font-display: "Besley", "Georgia", serif;
  --font-body: "Public Sans", -apple-system, "Segoe UI", sans-serif;
  --font-mono: "Spline Sans Mono", "SFMono-Regular", "Consolas", monospace;

  --measure: 34em;
  --site-width: 71rem;

  --radius: 14px;
  --radius-sm: 6px;
  --radius-xs: 4px;
  --radius-pill: 999px;

  /* Every shadow is cast in --ink rather than black, which is what keeps them
     reading as warm paper shadow instead of grey. */
  --shadow-drop: 0 24px 48px -24px color-mix(in srgb, var(--ink) 25%, transparent);
  --shadow-contact: 0 2px 6px color-mix(in srgb, var(--ink) 6%, transparent);
  --shadow-card: 0 18px 40px -22px color-mix(in srgb, var(--ink) 22%, transparent);
  --shadow-lift: 0 14px 30px -18px color-mix(in srgb, var(--ink) 30%, transparent);

  color-scheme: light;
}

/* --------------------------------------------------------------------------
   Reset & base
   -------------------------------------------------------------------------- */

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 5rem;
}

body {
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background-color: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

a {
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--seal);
  outline-offset: 3px;
  border-radius: 2px;
}

/* --seal only reaches 2.1:1 against --ink — both are blues — so the ring
   would fall below the 3:1 that WCAG 1.4.11 asks of a focus indicator
   inside the dark band. --seal-on-ink would clear it, but paper is the more
   legible ring and keeps the indicator one colour sitewide. */
.band--ink :focus-visible {
  outline-color: var(--paper);
}

::selection {
  background: var(--feint);
}

/* Available to assistive technology, invisible on screen. */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  border: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  inset-inline-start: 1rem;
  top: -4rem;
  z-index: 100;
  background: var(--ink);
  color: var(--paper);
  padding: 0.6rem 1rem;
  border-radius: 0 0 8px 8px;
  text-decoration: none;
  font-weight: 600;
  transition: top 0.15s ease;
}

.skip-link:focus {
  top: 0;
}

/* --------------------------------------------------------------------------
   Type helpers
   -------------------------------------------------------------------------- */

/* 700 is a real cut of Spline Sans Mono, not a synthesised one — each page
   requests it explicitly. At 0.95rem the label is still under the 18.66px
   that WCAG calls large text, so it stays held to 4.5:1 wherever it sits. */
.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--seal);
  margin-bottom: 1.1rem;
}

h1,
h2 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

h1 {
  font-size: clamp(2.4rem, 5.2vw, 4.1rem);
}

h2 {
  font-size: clamp(1.8rem, 3.4vw, 2.6rem);
  margin-bottom: 1.2rem;
}

h1 em,
h2 em {
  font-style: italic;
  font-weight: 600;
  color: var(--seal-deep);
}

.lede {
  font-size: clamp(1.05rem, 1.6vw, 1.2rem);
  color: var(--ink-soft);
  max-width: var(--measure);
}

.num {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

/* --------------------------------------------------------------------------
   Header
   -------------------------------------------------------------------------- */

.site-head {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--paper) 85%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--feint-weak);
}

.site-head__inner {
  max-width: var(--site-width);
  margin: 0 auto;
  padding: 0.85rem 1.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 2rem;
}

.brand {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.3rem;
  text-decoration: none;
  letter-spacing: -0.01em;
}

.brand__accent {
  color: var(--seal);
}

.site-nav {
  display: flex;
  gap: 1.6rem;
  margin-inline-end: auto;
}

.site-nav a {
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--ink-soft);
  transition: color 0.15s ease;
  /* Keeps the target over 24px tall even if the reader overrides
     line-height down to 1.5 (WCAG 2.5.8 with 1.4.12 applied). */
  padding-block: 0.3rem;
}

.site-nav a:hover {
  color: var(--ink);
}

.head-actions {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  margin-inline-start: auto;
}

.site-nav + .head-actions {
  margin-inline-start: 0;
}

.lang-switch {
  flex-wrap: wrap;
}

.lang-switch {
  display: flex;
  gap: 0.15rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 500;
}

.lang-switch a {
  text-decoration: none;
  color: var(--ink-faint);
  padding: 0.25rem 0.45rem;
  border-radius: var(--radius-sm);
  transition: color 0.15s ease, background-color 0.15s ease;
}

.lang-switch a:hover {
  color: var(--ink);
  background: var(--feint-weak);
}

.lang-switch a[aria-current="page"] {
  color: var(--ink);
  font-weight: 600;
  background: var(--feint-weak);
}

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */

.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  padding: 0.7rem 1.35rem;
  border-radius: var(--radius-pill);
  transition: background-color 0.15s ease, color 0.15s ease,
    transform 0.15s ease;
}

.btn--primary {
  background: var(--seal);
  color: var(--paper-raised);
}

.btn--primary:hover {
  background: var(--seal-deep);
  transform: translateY(-1px);
}

.btn--ghost {
  color: var(--ink);
  box-shadow: inset 0 0 0 1.5px var(--edge-ui);
}

.btn--ghost:hover {
  box-shadow: inset 0 0 0 1.5px var(--ink);
}

.btn--small {
  font-size: 0.85rem;
  padding: 0.45rem 1rem;
}

/* --------------------------------------------------------------------------
   Layout scaffolding
   -------------------------------------------------------------------------- */

.section {
  max-width: var(--site-width);
  margin: 0 auto;
  padding: 6.5rem 1.5rem 0;
}

.section--flush {
  padding-top: 5rem;
}

.band {
  margin-top: 6.5rem;
  background: var(--paper-deep);
  border-top: 1px solid var(--feint-weak);
  border-bottom: 1px solid var(--feint-weak);
}

.band > .section,
.band.section {
  padding-top: 5.5rem;
  padding-bottom: 5.5rem;
  margin-top: 0;
}

.band--ink {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}

.split {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(2.5rem, 5vw, 5rem);
  align-items: center;
}

/* Keep wide children (the ledger table) scrolling inside their column
   instead of stretching the grid past the viewport. */
.split > * {
  min-width: 0;
}

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero {
  padding-top: clamp(3.5rem, 7vw, 6rem);
}

.hero .lede {
  margin-top: 1.4rem;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-top: 2.2rem;
}

.dev-note {
  margin-top: 1.6rem;
  font-size: 0.88rem;
  color: var(--ink-soft);
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.dev-note::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--seal);
  animation: pulse 2.4s ease-in-out infinite;
}

@keyframes pulse {
  0%,
  100% {
    box-shadow: 0 0 0 0 color-mix(in srgb, var(--seal) 45%, transparent);
  }
  50% {
    box-shadow: 0 0 0 6px transparent;
  }
}

/* --------------------------------------------------------------------------
   The ledger — signature element
   -------------------------------------------------------------------------- */

.ledger-wrap {
  position: relative;
}

.ledger {
  background: var(--paper-raised);
  border: 1px solid var(--feint-weak);
  border-radius: var(--radius);
  box-shadow: var(--shadow-drop), var(--shadow-contact);
  overflow: hidden;
  font-size: 0.85rem;
}

.ledger__scroll {
  overflow-x: auto;
}

.ledger table {
  width: 100%;
  min-width: 21rem;
  border-collapse: collapse;
  table-layout: fixed;
}

.ledger__head {
  padding: 0.85rem 1.1rem;
  border-bottom: 1px solid var(--feint);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: var(--ink-soft);
  display: flex;
  justify-content: space-between;
  gap: 1rem;
}

.ledger__head strong {
  color: var(--ink);
  font-weight: 600;
}

.ledger td,
.ledger th {
  padding: 0.62rem 0.9rem;
  vertical-align: top;
  text-align: start;
  font-weight: 400;
  border-bottom: 1px solid var(--feint-weak);
}

/* The column headers name the columns for assistive technology only — the
   ledger reads as a picture, so the row must not show. The cells themselves
   stay in the layout: with table-layout:fixed the first row is what sets the
   column widths, so collapsing them (rather than hiding the row) is what
   keeps the date and amount columns their intended size. */
.ledger thead th,
/* .ledger .l-date is two classes deep and would otherwise keep its accent
   margin rule on the collapsed header cell. */
.ledger thead .l-date {
  padding: 0;
  height: 0;
  border: 0;
}

/* The accent margin rule: dates sit in the ledger margin */
.ledger .l-date {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--ink-faint);
  white-space: nowrap;
  width: 4.6rem;
  border-inline-end: 1px solid color-mix(in srgb, var(--seal) 55%, transparent);
}

.ledger .l-desc strong {
  font-weight: 600;
  display: block;
}

.ledger .l-desc small {
  display: block;
  color: var(--ink-faint);
  font-size: 0.76rem;
  margin-top: 0.1rem;
}

.ledger .l-amt {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  text-align: right;
  white-space: nowrap;
  font-size: 0.82rem;
  width: 9rem;
  /* Amounts stay left-to-right even on RTL pages */
  direction: ltr;
  unicode-bidi: isolate;
}

.ledger .is-credit .l-amt {
  color: var(--credit);
}

.ledger .cur {
  display: inline-block;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
  border: 1px solid var(--feint);
  border-radius: var(--radius-xs);
  padding: 0 0.3rem;
  margin-inline-start: 0.4rem;
  vertical-align: 0.1em;
}

.ledger tfoot td {
  border-bottom: none;
  border-top: 1px solid var(--ink);
  padding-top: 0.7rem;
  padding-bottom: 0.8rem;
  font-weight: 600;
}

.ledger tfoot .l-amt {
  border-bottom: 3px double var(--ink);
  font-weight: 600;
}

.ledger tfoot small {
  display: block;
  font-weight: 400;
  color: var(--ink-faint);
  font-size: 0.74rem;
  margin-top: 0.15rem;
}

.ledger .approx {
  color: var(--seal);
}

/* Staggered row entrance */
.ledger tbody tr {
  opacity: 0;
  transform: translateY(6px);
  animation: row-in 0.5s ease forwards;
}

.ledger tbody tr:nth-child(1) { animation-delay: 0.15s; }
.ledger tbody tr:nth-child(2) { animation-delay: 0.3s; }
.ledger tbody tr:nth-child(3) { animation-delay: 0.45s; }
.ledger tbody tr:nth-child(4) { animation-delay: 0.6s; }
.ledger tbody tr:nth-child(5) { animation-delay: 0.75s; }
.ledger tbody tr:nth-child(6) { animation-delay: 0.9s; }

.ledger tfoot tr {
  opacity: 0;
  animation: row-in 0.5s ease 1.15s forwards;
}

@keyframes row-in {
  to {
    opacity: 1;
    transform: none;
  }
}

/* Rubber stamp: the product is not live yet, and says so */
.stamp {
  position: absolute;
  top: -1.1rem;
  inset-inline-end: -0.4rem;
  transform: rotate(6deg);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--seal);
  border: 2px solid var(--seal);
  border-radius: var(--radius-sm);
  padding: 0.35rem 0.7rem;
  background: color-mix(in srgb, var(--paper-raised) 82%, transparent);
  opacity: 0.92;
  pointer-events: none;
}

/* --------------------------------------------------------------------------
   Privacy: the file chip
   -------------------------------------------------------------------------- */

.file-card {
  background: var(--paper-raised);
  border: 1px solid var(--feint-weak);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  padding: 1.6rem;
  max-width: 24rem;
}

.file-card__chip {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}

.file-card__icon {
  flex: none;
  width: 46px;
  height: 56px;
  border: 1.5px solid var(--ink-soft);
  border-radius: 6px 12px 6px 6px;
  position: relative;
  background: linear-gradient(
    var(--feint-weak) 1px,
    transparent 1px
  );
  background-size: 100% 9px;
  background-position: 0 14px;
}

.file-card__icon::after {
  content: "";
  position: absolute;
  inset: auto auto -7px 50%;
  translate: -50% 0;
  width: 14px;
  height: 14px;
  border: 1.5px solid var(--ink-soft);
  border-radius: var(--radius-xs);
  background: var(--seal);
  box-shadow: inset 0 0 0 2.5px var(--paper-raised);
}

.file-card__name {
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 0.95rem;
}

.file-card__meta {
  font-size: 0.8rem;
  color: var(--ink-soft);
  margin-top: 0.15rem;
}

.file-card__foot {
  margin-top: 1.3rem;
  padding-top: 1.1rem;
  border-top: 1px solid var(--feint-weak);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.05em;
  color: var(--ink-faint);
  display: flex;
  justify-content: space-between;
  gap: 1rem;
}

.checklist {
  list-style: none;
  margin-top: 1.6rem;
  display: grid;
  gap: 0.7rem;
  max-width: var(--measure);
}

.checklist li {
  padding-inline-start: 1.7rem;
  position: relative;
  color: var(--ink-soft);
}

.checklist li::before {
  content: "✓";
  position: absolute;
  inset-inline-start: 0;
  top: 0;
  color: var(--credit);
  font-weight: 700;
}

.checklist strong {
  color: var(--ink);
  font-weight: 600;
}

/* --------------------------------------------------------------------------
   Countries grid
   -------------------------------------------------------------------------- */

.section-intro {
  max-width: 44rem;
}

.section-intro .lede {
  margin-top: 0.4rem;
  max-width: none;
}

.country-grid {
  margin-top: 3rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15.5rem, 1fr));
  gap: 1.1rem;
}

.country-card {
  background: var(--paper-raised);
  border: 1px solid var(--feint-weak);
  border-radius: var(--radius);
  padding: 1.4rem 1.4rem 1.5rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.country-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lift);
}

.country-card__code {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--seal);
  border: 1px solid color-mix(in srgb, var(--seal) 45%, transparent);
  border-radius: var(--radius-xs);
  padding: 0.15rem 0.5rem;
  margin-bottom: 0.9rem;
}

.country-card h3 {
  font-family: var(--font-display);
  font-size: 1.12rem;
  font-weight: 700;
  margin-bottom: 0.45rem;
}

.country-card p {
  font-size: 0.9rem;
  color: var(--ink-soft);
}

.countries-note {
  margin-top: 2.2rem;
  font-size: 0.95rem;
  color: var(--ink-soft);
  border-inline-start: 3px solid var(--seal);
  padding-inline-start: 1.1rem;
  max-width: var(--measure);
}

/* --------------------------------------------------------------------------
   Loans: the term sheet
   -------------------------------------------------------------------------- */

.feature-points {
  list-style: none;
  margin-top: 1.8rem;
  display: grid;
  gap: 1.1rem;
  max-width: var(--measure);
}

.feature-points li {
  padding-inline-start: 1.6rem;
  position: relative;
  color: var(--ink-soft);
  font-size: 0.98rem;
}

.feature-points li::before {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  top: 0.55em;
  width: 0.7rem;
  height: 1.5px;
  background: var(--seal);
}

.feature-points strong {
  color: var(--ink);
  font-weight: 600;
}

.term-sheet {
  background: var(--paper-raised);
  border: 1px solid var(--feint-weak);
  border-radius: var(--radius);
  box-shadow: var(--shadow-drop);
  overflow: hidden;
  font-size: 0.88rem;
}

.term-sheet__head {
  padding: 0.9rem 1.4rem;
  border-bottom: 1px solid var(--feint);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
  display: flex;
  justify-content: space-between;
  gap: 1rem;
}

.term-sheet__head strong {
  color: var(--ink);
}

.term-sheet dl {
  padding: 0.6rem 0;
}

.term-sheet .ts-row {
  display: flex;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 0.5rem 1.4rem;
}

.term-sheet .ts-row:nth-child(even) {
  background: color-mix(in srgb, var(--paper-deep) 45%, transparent);
}

.term-sheet dt {
  color: var(--ink-soft);
}

.term-sheet dd {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: 0.82rem;
  text-align: end;
}

.term-sheet__foot {
  padding: 0.8rem 1.4rem 1rem;
  border-top: 1px solid var(--feint-weak);
  font-size: 0.78rem;
  color: var(--ink-faint);
  font-style: italic;
}

/* --------------------------------------------------------------------------
   Feature index
   -------------------------------------------------------------------------- */

.feature-grid {
  margin-top: 3rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 2.2rem 2.5rem;
}

.feature-grid h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
  padding-top: 0.7rem;
  border-top: 2px solid var(--ink);
}

.feature-grid p {
  font-size: 0.9rem;
  color: var(--ink-soft);
}

/* --------------------------------------------------------------------------
   Honesty band
   -------------------------------------------------------------------------- */

/* The dark-mode blue alone is 3.9:1 on --ink — fine for the large glyph
   below, short of the 4.5:1 WCAG 1.4.3 wants for text this small. A fifth of
   paper lifts it to 5.1:1 without reading as a different colour. */
.band--ink .eyebrow {
  color: color-mix(in srgb, var(--seal-on-ink) 80%, var(--paper));
}

.honesty {
  position: relative;
  overflow: hidden;
}

.honesty__mark {
  position: absolute;
  inset-inline-end: -1rem;
  top: 50%;
  translate: 0 -50%;
  font-family: var(--font-display);
  font-size: clamp(14rem, 30vw, 24rem);
  line-height: 1;
  color: color-mix(in srgb, var(--paper) 7%, transparent);
  pointer-events: none;
  user-select: none;
}

.honesty h2 {
  max-width: 20em;
}

.principles {
  margin-top: 3rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 2.5rem;
  position: relative;
}

.principles h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.principles p {
  font-size: 0.93rem;
  color: color-mix(in srgb, var(--paper) 72%, var(--ink));
}

.principles .glyph {
  font-family: var(--font-mono);
  color: var(--seal);
  font-weight: 600;
  display: block;
  font-size: 1.5rem;
  margin-bottom: 0.7rem;
}

/* 24px clears WCAG's large-text bar, so the dark-mode blue stands unmixed
   here at 3.9:1 against the 3:1 that size is held to. */
.band--ink .principles .glyph {
  color: var(--seal-on-ink);
}

/* --------------------------------------------------------------------------
   Final CTA
   -------------------------------------------------------------------------- */

.cta-final {
  text-align: center;
  padding-bottom: 6.5rem;
}

.cta-final .lede {
  margin: 0 auto;
}

.cta-final .fineprint {
  margin-top: 1.6rem;
  font-size: 0.82rem;
  color: var(--ink-faint);
}

.platform-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.9rem;
  margin-top: 2.2rem;
}

.platform {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink);
  border: 1.5px solid var(--feint);
  border-radius: var(--radius-pill);
  padding: 0.6rem 1.3rem;
  background: var(--paper-raised);
}

.platform svg {
  width: 18px;
  height: 18px;
  stroke: var(--seal);
  fill: none;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.stay-tuned {
  margin-top: 2rem;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.25rem;
  color: var(--seal-deep);
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */

.site-foot {
  border-top: 1px solid var(--feint-weak);
  background: var(--paper-deep);
}

.site-foot__inner {
  max-width: var(--site-width);
  margin: 0 auto;
  padding: 2.2rem 1.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 2.5rem;
  font-size: 0.84rem;
  color: var(--ink-soft);
}

.site-foot .brand {
  font-size: 1.05rem;
}

.site-foot__legal {
  margin-inline-start: auto;
  text-align: end;
}

.site-foot a:not(.brand) {
  color: var(--ink-soft);
}

/* --------------------------------------------------------------------------
   Root fallback page (dist/index.html)
   Lives here rather than in a <style> block so the Content-Security-Policy
   can refuse inline styles outright.
   -------------------------------------------------------------------------- */

.redirect-page {
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 1.5rem;
  text-align: center;
}

.redirect-page a {
  color: var(--seal-deep);
  /* These links sit inside a sentence, so colour alone must not be what
     marks them (WCAG 1.4.1). */
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 60rem) {
  .split {
    grid-template-columns: 1fr;
  }

  .hero .ledger-wrap {
    margin-top: 1.5rem;
  }

  .split--reverse .split__visual {
    order: 2;
  }
}

@media (max-width: 45rem) {
  /* The sticky header wraps to two rows here (brand above the language
     switch), so anchor targets need more clearance to land below it —
     WCAG 2.4.11 Focus Not Obscured. */
  html {
    scroll-padding-top: 7rem;
  }

  .site-nav {
    display: none;
  }

  .section {
    padding-top: 4.5rem;
  }

  .band {
    margin-top: 4.5rem;
  }

  .honesty__mark {
    display: none;
  }

  .site-foot__legal {
    margin-inline-start: 0;
    text-align: start;
  }

  .site-head .btn {
    display: none;
  }

  /* 0.3rem left the two-letter codes a hair under the 24px minimum target
     width of WCAG 2.5.8 once font fallback kicks in. */
  .lang-switch a {
    padding: 0.25rem 0.4rem;
  }
}

/* --------------------------------------------------------------------------
   Language-specific typography
   Latin pages use the default stacks; Japanese and Arabic swap in faces
   that carry their scripts, drop italics (which those scripts don't have),
   and remove letter-spacing where the script forbids it.
   -------------------------------------------------------------------------- */

html[lang="ja"] {
  --font-display: "Hiragino Mincho ProN", "Yu Mincho", "Noto Serif JP", serif;
  --font-body: "Hiragino Sans", "Yu Gothic", "Meiryo", "Noto Sans JP",
    sans-serif;
}

html[lang="ja"] h1,
html[lang="ja"] h2 {
  line-height: 1.3;
  letter-spacing: 0;
}

html[lang="ja"] em,
html[lang="ja"] .stay-tuned,
html[lang="ja"] .term-sheet__foot {
  font-style: normal;
}

html[lang="ar"] {
  --font-display: "Amiri", "Noto Naskh Arabic", "Geeza Pro", serif;
  --font-body: "Noto Sans Arabic", "Segoe UI", "Geeza Pro", sans-serif;
  --font-mono: "Spline Sans Mono", "Noto Sans Arabic", "Geeza Pro", monospace;
}

html[lang="ar"] h1,
html[lang="ar"] h2 {
  line-height: 1.5;
  letter-spacing: 0;
}

html[lang="ar"] em,
html[lang="ar"] .stay-tuned,
html[lang="ar"] .term-sheet__foot {
  font-style: normal;
}

/* Connected script: tracking would break letter joining */
html[lang="ar"] .eyebrow,
html[lang="ar"] .stamp,
html[lang="ar"] .country-card__code,
html[lang="ar"] .term-sheet__head,
html[lang="ar"] .platform,
html[lang="ar"] .file-card__foot,
html[lang="ar"] .ledger__head,
html[lang="ar"] .lang-switch {
  letter-spacing: 0;
}

/* --------------------------------------------------------------------------
   Reduced motion
   -------------------------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  .ledger tbody tr,
  .ledger tfoot tr {
    opacity: 1;
    transform: none;
  }
}

/* --------------------------------------------------------------------------
   Print
   -------------------------------------------------------------------------- */

@media print {
  .site-head,
  .skip-link,
  .cta-row {
    display: none;
  }
}
