/* ==========================================================================
   LETTER — shared stylesheet
   Palette and typography sampled from cloudandthings.com
   (themes/cloudnthings2019/css/style.css + menu.css):
     orange  #f36817 / #f16929 / #f3872b
     blue    #3c4ea4 / #3b4ba7 / #234178
     navy    #1f233e
     type    Raleway (body), Roboto Condensed (display)
   Hand-rolled. No framework, no build step.
   ========================================================================== */

/* ==========================================================================
   SELF-HOSTED WEBFONTS — no external requests, no third-party dependency.
   Files in website/fonts/ (woff2, latin + latin-ext subsets), served from the
   same distribution as the pages. Both are variable faces, so one file per
   subset covers the whole 400-700 range the site uses.
   Raleway and Roboto Condensed are licensed under the SIL Open Font License
   1.1 — see website/fonts/OFL.txt.
   ========================================================================== */
@font-face {
  font-family: "Raleway";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("../fonts/raleway-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Raleway";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("../fonts/raleway-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Roboto Condensed";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("../fonts/roboto-condensed-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Roboto Condensed";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("../fonts/roboto-condensed-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ---------- tokens ---------- */
:root {
  --orange:        #f36817;
  --orange-lt:     #f3872b;
  --orange-soft:   #fdf1e9;
  --blue:          #3c4ea4;
  --blue-alt:      #3b4ba7;
  --blue-deep:     #234178;
  --navy:          #1f233e;
  --ink:           #22252f;
  --ink-soft:      #4f5566;
  --rule:          #dfe2ea;
  --bg:            #ffffff;
  --bg-alt:        #f6f7fa;
  --bg-tint:       #eef0f7;
  --white:         #ffffff;

  --font-body: "Raleway", "Segoe UI", -apple-system, BlinkMacSystemFont, Arial, Helvetica, sans-serif;
  --font-display: "Roboto Condensed", "Segoe UI", Arial, Helvetica, sans-serif;

  --wrap: 1180px;
  --gap: 1.6rem;
  --radius: 3px;
  --shadow: 0 2px 10px rgba(31, 35, 62, .08);
  --shadow-lg: 0 6px 26px rgba(31, 35, 62, .13);
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.68;
  color: var(--ink);
  background: var(--bg);
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--blue); text-decoration: none; }
a:hover, a:focus { color: var(--orange); text-decoration: underline; }
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.18; margin: 0 0 .6em; font-weight: 700; }
h1 { font-size: clamp(2rem, 5.2vw, 3.4rem); letter-spacing: -.01em; }
h2 { font-size: clamp(1.55rem, 3.4vw, 2.3rem); }
h3 { font-size: clamp(1.18rem, 2.2vw, 1.45rem); }
h4 { font-size: 1.05rem; }
p  { margin: 0 0 1.1em; }
ul, ol { margin: 0 0 1.2em; padding-left: 1.25em; }
li { margin-bottom: .45em; }
code, .mono { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: .92em; }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 2px; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 1.25rem; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 200;
  background: var(--orange); color: #fff; padding: .7rem 1.1rem; font-weight: 700;
}
.skip-link:focus { left: .5rem; top: .5rem; }

/* ==========================================================================
   HEADER + NAV — the cloudandthings.com pattern:
   dark bar, wordmark left, menu right, white links going orange on hover/active,
   dropdown panel in brand blue, hamburger collapse under 900px.
   ========================================================================== */
.site-header {
  background: var(--navy);
  position: sticky; top: 0; z-index: 100;
  border-bottom: 3px solid var(--orange);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; min-height: 74px;
}
.brand { display: flex; align-items: center; gap: .6rem; color: #fff; text-decoration: none; flex: 0 0 auto; }
.brand:hover, .brand:focus { color: #fff; text-decoration: none; }
.brand-mark {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.85rem; line-height: 1; color: var(--orange);
  border: 2px solid var(--orange); border-radius: var(--radius);
  width: 2.05rem; height: 2.05rem;
  display: flex; align-items: center; justify-content: center;
  flex: 0 0 auto;
}
.brand-name { font-family: var(--font-display); font-size: 1.5rem; font-weight: 700; letter-spacing: .14em; }
.brand-sub {
  display: block; font-family: var(--font-body); font-size: .62rem;
  letter-spacing: .09em; text-transform: uppercase; color: #aeb4cc;
  font-weight: 600; margin-top: -2px;
}

.nav-toggle {
  display: none; background: transparent; border: 1px solid #4a5070;
  border-radius: var(--radius); padding: .5rem .6rem; cursor: pointer;
}
.nav-toggle .bar { display: block; width: 22px; height: 2px; background: #fff; margin: 4px 0; }

.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; }
.site-nav li { margin: 0; position: relative; }
.site-nav a {
  display: block; color: #fff; font-family: var(--font-display);
  font-size: .96rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase;
  padding: 1.6rem .82rem; text-decoration: none;
  border-bottom: 3px solid transparent; margin-bottom: -3px;
}
.site-nav a:hover, .site-nav a:focus { color: var(--orange); text-decoration: none; }
.site-nav a[aria-current="page"] { color: var(--orange); border-bottom-color: var(--orange); }
.site-nav a.ext::after { content: "\2197"; font-size: .78em; margin-left: .22em; opacity: .75; }

/* dropdown, in the brand blue like the source site */
.has-sub > .sub {
  display: none; position: absolute; top: 100%; left: 0; min-width: 235px;
  background: var(--blue-alt); padding: 0; box-shadow: var(--shadow-lg); z-index: 120;
}
.has-sub:hover > .sub, .has-sub:focus-within > .sub { display: block; }
.has-sub .sub li { border-bottom: 1px dotted rgba(255,255,255,.35); }
.has-sub .sub li:last-child { border-bottom: none; }
.has-sub .sub a {
  padding: .68rem 1rem; font-size: .85rem; text-transform: none;
  letter-spacing: .01em; border-bottom: none; margin-bottom: 0;
}
.has-sub .sub a:hover { background: var(--blue-deep); color: #fff; }

/* ---------- hero ---------- */
.hero {
  background:
    radial-gradient(1100px 460px at 8% -30%, rgba(243,104,23,.30), transparent 62%),
    linear-gradient(135deg, var(--blue) 0%, var(--navy) 78%);
  color: #fff; padding: clamp(2.8rem, 8vw, 5.6rem) 0;
}
.hero h1 { color: #fff; margin-bottom: .2em; }
.hero .eyebrow {
  font-family: var(--font-display); text-transform: uppercase; letter-spacing: .2em;
  font-size: .8rem; font-weight: 700; color: var(--orange-lt); margin-bottom: 1rem;
}
.hero .lede { font-size: clamp(1.05rem, 2.1vw, 1.28rem); color: #dfe3f2; max-width: 44em; }

/* The name and expansion sit ABOVE the category statement, small — they
   identify the thing; the h1 below makes the claim. */
.hero .hero-name {
  font-family: var(--font-display); font-size: clamp(.82rem, 1.7vw, 1rem);
  text-transform: uppercase; letter-spacing: .13em; color: #aeb4cc;
  font-weight: 400; margin: 0 0 1.1rem;
}
.hero .hero-name b { color: var(--orange-lt); font-weight: 700; }

/* The subline directly under the category statement. */
.hero .hero-sub {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.15rem, 2.7vw, 1.75rem); line-height: 1.25;
  color: var(--orange-lt); margin: 0 0 1.25em;
}

/* The traceability sentence, now the proof line beneath the claim. */
.hero .hero-proof {
  font-size: clamp(1rem, 2vw, 1.22rem); color: #fff; font-weight: 600;
  margin: 0 0 1.2em; padding-left: .9rem; border-left: 4px solid var(--orange);
  max-width: 40em;
}
.page-head {
  background: linear-gradient(135deg, var(--blue) 0%, var(--navy) 85%);
  color: #fff; padding: clamp(2.1rem, 5vw, 3.4rem) 0;
}
.page-head h1 { color: #fff; margin-bottom: .3em; }
.page-head p { color: #dfe3f2; max-width: 48em; margin: 0; font-size: 1.06rem; }

/* ---------- buttons ---------- */
.btn {
  display: inline-block; font-family: var(--font-display); font-weight: 700;
  text-transform: uppercase; letter-spacing: .07em; font-size: .9rem;
  padding: .85rem 1.7rem; border-radius: var(--radius);
  background: var(--orange); color: #fff !important; border: 2px solid var(--orange);
  text-decoration: none !important; transition: background .15s, color .15s;
}
.btn:hover, .btn:focus { background: #d9560c; border-color: #d9560c; }
.btn-ghost { background: transparent; color: #fff !important; border-color: rgba(255,255,255,.65); }
.btn-ghost:hover, .btn-ghost:focus { background: #fff; color: var(--navy) !important; border-color: #fff; }
.btn-row { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.7rem; }

/* ---------- sections ---------- */
section { padding: clamp(2.4rem, 6vw, 4.2rem) 0; }
section.alt { background: var(--bg-alt); }
section.tint { background: var(--bg-tint); }
section.navy { background: var(--navy); color: #e7e9f3; }
section.navy h2, section.navy h3 { color: #fff; }
section.navy a { color: var(--orange-lt); }
.section-title { max-width: 46em; }
.section-title .kicker {
  font-family: var(--font-display); text-transform: uppercase; letter-spacing: .18em;
  font-size: .76rem; font-weight: 700; color: var(--orange); margin: 0 0 .5rem;
}
.lead { font-size: 1.1rem; color: var(--ink-soft); max-width: 46em; }
section.navy .lead { color: #c3c8dd; }

/* ---------- stat tiles ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(158px, 1fr)); gap: 1rem; margin: 2rem 0 0; }
.stat {
  background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.16);
  border-top: 3px solid var(--orange); border-radius: var(--radius);
  padding: 1.2rem 1rem; text-align: center;
}
.stat .n { font-family: var(--font-display); font-size: clamp(1.7rem, 4vw, 2.4rem); font-weight: 700; color: #fff; line-height: 1.05; }
.stat .l { font-size: .8rem; color: #c3c8dd; text-transform: uppercase; letter-spacing: .07em; margin-top: .3rem; }
.stats.on-light .stat { background: #fff; border-color: var(--rule); border-top-color: var(--orange); box-shadow: var(--shadow); }
.stats.on-light .stat .n { color: var(--navy); }
.stats.on-light .stat .l { color: var(--ink-soft); }

/* ---------- cards ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: var(--gap); margin-top: 2rem; }
.card {
  background: #fff; border: 1px solid var(--rule); border-radius: var(--radius);
  border-top: 3px solid var(--blue); padding: 1.5rem; box-shadow: var(--shadow);
}
.card.accent { border-top-color: var(--orange); }
.card h3 { margin-bottom: .5rem; color: var(--navy); }
.card p:last-child, .card ul:last-child { margin-bottom: 0; }
.card .num {
  font-family: var(--font-display); font-size: 1.9rem; font-weight: 700;
  color: var(--orange); line-height: 1; display: block; margin-bottom: .4rem;
}

/* ---------- steps ---------- */
.steps { counter-reset: step; margin-top: 2rem; display: grid; gap: 1.1rem; }
.step {
  display: grid; grid-template-columns: 3rem 1fr; gap: 1.1rem; align-items: start;
  background: #fff; border: 1px solid var(--rule); border-left: 4px solid var(--orange);
  border-radius: var(--radius); padding: 1.3rem 1.4rem; box-shadow: var(--shadow);
}
.step::before {
  counter-increment: step; content: counter(step);
  font-family: var(--font-display); font-size: 1.5rem; font-weight: 700;
  color: #fff; background: var(--blue); border-radius: 50%;
  width: 2.7rem; height: 2.7rem; display: flex; align-items: center; justify-content: center;
}
.step h3 { margin-bottom: .35rem; color: var(--navy); }
.step p:last-child, .step ul:last-child { margin-bottom: 0; }

/* ---------- callout ---------- */
.callout {
  background: var(--orange-soft); border: 1px solid #f6d3b8; border-left: 5px solid var(--orange);
  border-radius: var(--radius); padding: 1.3rem 1.5rem; margin: 2rem 0;
}
.callout h3 { color: #a8470c; margin-bottom: .45rem; }
.callout p:last-child { margin-bottom: 0; }
.callout.blue { background: #eef1fa; border-color: #ccd4ee; border-left-color: var(--blue); }
.callout.blue h3 { color: var(--blue-deep); }

/* ---------- figure ---------- */
figure.diagram { margin: 2rem 0 0; background: #fff; border: 1px solid var(--rule); border-radius: var(--radius); padding: 1rem; box-shadow: var(--shadow); }
figure.diagram img { margin: 0 auto; }
figure.diagram figcaption { font-size: .88rem; color: var(--ink-soft); margin-top: .9rem; text-align: center; }

/* ---------- tables ---------- */
.table-scroll { overflow-x: auto; margin: 1.6rem 0; -webkit-overflow-scrolling: touch; border: 1px solid var(--rule); border-radius: var(--radius); background: #fff; }
table { border-collapse: collapse; width: 100%; min-width: 560px; font-size: .93rem; }
caption { text-align: left; font-size: .88rem; color: var(--ink-soft); padding: .8rem 1rem; }
th, td { text-align: left; padding: .72rem .95rem; border-bottom: 1px solid var(--rule); vertical-align: top; }
thead th {
  background: var(--navy); color: #fff; font-family: var(--font-display);
  text-transform: uppercase; letter-spacing: .05em; font-size: .78rem; font-weight: 700;
  position: sticky; top: 0;
}
tbody tr:nth-child(even) { background: var(--bg-alt); }
tbody tr:hover { background: var(--orange-soft); }
td.cite { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: .84rem; color: var(--blue-deep); white-space: nowrap; }
td.type { font-size: .84rem; color: var(--ink-soft); text-transform: uppercase; letter-spacing: .04em; }

/* ---------- corpus / family blocks ---------- */
.family { background: #fff; border: 1px solid var(--rule); border-radius: var(--radius); box-shadow: var(--shadow); margin-bottom: 1.4rem; overflow: hidden; }
.family > header { background: var(--bg-alt); border-bottom: 1px solid var(--rule); border-left: 5px solid var(--orange); padding: 1rem 1.3rem; }
.family > header h3 { margin: 0; color: var(--navy); }
.family > header .count { font-family: var(--font-display); font-size: .82rem; text-transform: uppercase; letter-spacing: .09em; color: var(--orange); font-weight: 700; }
.family .body { padding: .4rem 1.3rem 1.1rem; }
.src-list { list-style: none; padding: 0; margin: 0; }
.src-list li { border-bottom: 1px dotted var(--rule); padding: .62rem 0; margin: 0; display: flex; flex-wrap: wrap; gap: .2rem .8rem; align-items: baseline; }
.src-list li:last-child { border-bottom: none; }
.src-list .cite { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: .87rem; color: var(--blue-deep); font-weight: 600; flex: 0 0 auto; }
.src-list .desc { color: var(--ink-soft); font-size: .92rem; }
.tag {
  display: inline-block; font-family: var(--font-display); font-size: .68rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .09em; padding: .16rem .5rem; border-radius: 2px;
  background: var(--bg-tint); color: var(--blue-deep); flex: 0 0 auto;
}
.tag.ny { background: #fdece0; color: #a8470c; }

/* ---------- timeline ---------- */
.span-bar { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; margin: 1.8rem 0; background: #fff; border: 1px solid var(--rule); border-radius: var(--radius); padding: 1.3rem 1.5rem; box-shadow: var(--shadow); }
.span-bar .year { font-family: var(--font-display); font-size: clamp(1.6rem, 4vw, 2.3rem); font-weight: 700; color: var(--orange); line-height: 1; }
.span-bar .track { flex: 1 1 200px; height: 6px; background: linear-gradient(90deg, var(--blue), var(--orange)); border-radius: 3px; min-width: 120px; }
.span-bar .note { flex: 1 1 100%; font-size: .93rem; color: var(--ink-soft); margin: 0; }

/* ---------- two-col ---------- */
.two-col { display: grid; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); gap: var(--gap); align-items: start; margin-top: 2rem; }

/* ---------- checklist ---------- */
.check { list-style: none; padding: 0; }
.check li { padding-left: 1.75rem; position: relative; }
.check li::before { content: "\00A7"; position: absolute; left: 0; top: -1px; color: var(--orange); font-weight: 700; font-family: Georgia, serif; font-size: 1.15em; }

/* ---------- footer ---------- */
.site-footer { background: var(--navy); color: #b9bfd6; padding: 2.8rem 0 1.6rem; font-size: .93rem; border-top: 3px solid var(--orange); }
.site-footer a { color: #dfe3f2; }
.site-footer a:hover, .site-footer a:focus { color: var(--orange-lt); }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 1.8rem; }
.site-footer h4 { color: #fff; font-size: .84rem; text-transform: uppercase; letter-spacing: .13em; margin-bottom: .8rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: .4rem; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.15); margin-top: 2rem; padding-top: 1.3rem; display: flex; flex-wrap: wrap; gap: .6rem 1.4rem; align-items: center; justify-content: space-between; }
.footer-bottom p { margin: 0; }
.footer-bottom .capability { color: #fff; }
.footer-bottom .capability b { color: var(--orange-lt); }

/* ==========================================================================
   RESPONSIVE — collapse the menu, drop to single column
   ========================================================================== */
@media (max-width: 900px) {
  .nav-toggle { display: block; }
  .site-nav {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    background: var(--navy); border-top: 1px solid rgba(255,255,255,.15);
    max-height: calc(100vh - 74px); overflow-y: auto; box-shadow: var(--shadow-lg);
  }
  .site-nav.open { display: block; }
  .site-nav ul { display: block; }
  .site-nav a { padding: .95rem 1.25rem; border-bottom: 1px solid rgba(255,255,255,.1); margin-bottom: 0; }
  .site-nav a[aria-current="page"] { border-bottom-color: rgba(255,255,255,.1); border-left: 4px solid var(--orange); padding-left: calc(1.25rem - 4px); }
  .has-sub > .sub { display: block; position: static; box-shadow: none; min-width: 0; background: rgba(0,0,0,.22); }
  .has-sub .sub a { padding-left: 2.4rem; }
  .header-inner { position: relative; }
}

@media (max-width: 620px) {
  body { font-size: 16px; }
  .brand-name { font-size: 1.25rem; letter-spacing: .1em; }
  .brand-mark { font-size: 1.5rem; width: 1.75rem; height: 1.75rem; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .step { grid-template-columns: 1fr; gap: .7rem; }
  .step::before { width: 2.3rem; height: 2.3rem; font-size: 1.25rem; }
  .btn { display: block; text-align: center; }
  .btn-row { display: grid; grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  section { padding: 2.2rem 0; }
}

@media (max-width: 380px) {
  .stats { grid-template-columns: 1fr; }
  .brand-sub { display: none; }
}

@media print {
  .site-header, .site-footer, .nav-toggle { display: none; }
  body { font-size: 11pt; color: #000; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; animation: none !important; }
}
