/* ==========================================================================
   Scepter and Shield LLC — shared stylesheet (used by every page)
   Plain CSS, no build step. Sections:
     1. Design tokens      5. Buttons and links     9. Footer
     2. Base               6. Page intro           10. Utilities
     3. Layout             7. Sections and lists   11. Print
     4. Header             8. Tables
   ========================================================================== */

/* 1. Design tokens --------------------------------------------------------- */

:root {
  /* Colour. Gold is an accent only: rules, borders, and text on navy.
     It must never be used for text or links on white or off-white. */
  --color-navy: #0B1F3A;
  --color-navy-hover: #17355F;
  --color-gold: #C9A24B;
  --color-white: #FFFFFF;
  --color-paper: #F7F5F0;
  --color-text: #27313D;
  --color-text-muted: #4B5664;
  --color-rule: #D8D3C7;
  --color-on-navy: #FFFFFF;
  --color-on-navy-muted: #D5DBE4;

  /* Type. System font stacks only: no font files, no third-party requests. */
  --font-serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua",
    Georgia, "Times New Roman", serif;
  --font-sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue",
    Arial, sans-serif;

  --text-label: 0.8125rem;
  --text-small: 0.9375rem;
  --text-base: 1.0625rem;
  --text-lede: 1.1875rem;
  --text-h3: 1.1875rem;
  --text-h2: 1.5rem;
  --text-h1: clamp(2rem, 1.35rem + 2.9vw, 3.125rem);

  /* Space and measure */
  --page-width: 62rem;
  --measure: 40rem;
  --label-column: 14rem;
  --gutter: clamp(1.25rem, 4vw, 2.5rem);
  --space-section: clamp(2.25rem, 5vw, 3.5rem);
  --space-intro: clamp(2.5rem, 6vw, 4.5rem);

  --rule-thin: 1px;
  --rule-accent: 2px;
  --rule-band: 3px;
  --focus-width: 3px;
}

/* 2. Base ------------------------------------------------------------------ */

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  margin: 0;
  background: var(--color-white);
  color: var(--color-text);
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: 1.6;
}

main {
  flex: 1 0 auto;
}

h1,
h2,
h3 {
  color: var(--color-navy);
  font-family: var(--font-serif);
  line-height: 1.2;
}

p,
ul,
ol,
dl {
  margin: 0 0 1rem;
}

abbr[title] {
  text-decoration: none;
}

/* Lists without bullets use list-style-type: "" rather than "none", so that
   Safari and VoiceOver still announce them as lists. */

a[href^="tel:"] {
  white-space: nowrap;
}

/* 3. Layout ---------------------------------------------------------------- */

.container {
  width: 100%;
  max-width: var(--page-width);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* 4. Header ---------------------------------------------------------------- */

.site-header {
  background: var(--color-navy);
  border-bottom: var(--rule-band) solid var(--color-gold);
  color: var(--color-on-navy);
}

.site-header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  column-gap: 1.5rem;
  row-gap: 0.25rem;
  padding-block: 1.1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  padding-block: 0.15rem;
  color: var(--color-on-navy);
  text-decoration: none;
}

/* The crest from the company logo. The image is assets/logo-mark.png; to use
   a new version, save it over that file. Its width and height attributes in
   each page's header keep the layout from shifting while it loads. */
.brand-mark {
  display: block;
  flex: none;
  width: auto;
  height: 3.5rem;
}

@media (max-width: 30rem) {
  .brand {
    gap: 0.6rem;
  }

  .brand-mark {
    height: 2.75rem;
  }

  .wordmark {
    font-size: 1.0625rem;
    letter-spacing: 0.16em;
  }
}

.wordmark {
  font-family: var(--font-serif);
  font-size: 1.1875rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  white-space: nowrap;
}

.wordmark-and {
  color: var(--color-gold);
  font-size: 0.72em;
}

.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0 1.5rem;
  margin: 0;
  padding: 0;
  list-style-type: "";
}

.site-nav a {
  display: inline-block;
  padding: 0.55rem 0 0.35rem;
  border-bottom: var(--rule-accent) solid transparent;
  color: var(--color-on-navy);
  font-size: var(--text-small);
  font-weight: 500;
  text-decoration: none;
}

.site-nav a:hover {
  border-bottom-color: var(--color-on-navy-muted);
}

.site-nav a[aria-current="page"] {
  border-bottom-color: var(--color-gold);
}

/* 5. Buttons and links ----------------------------------------------------- */

a {
  color: var(--color-navy);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  text-decoration-thickness: 2px;
}

:focus-visible {
  outline: var(--focus-width) solid var(--color-navy);
  outline-offset: 3px;
}

.site-header :focus-visible,
.site-footer :focus-visible {
  outline-color: var(--color-gold);
}

.skip-link {
  position: absolute;
  top: -5rem;
  left: 0.75rem;
  z-index: 10;
  padding: 0.6rem 1rem;
  border: var(--rule-accent) solid var(--color-navy);
  background: var(--color-white);
  color: var(--color-navy);
  font-weight: 600;
}

.skip-link:focus {
  top: 0.75rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1.75rem 0 0;
}

.button {
  display: inline-block;
  padding: 0.8rem 1.4rem;
  border: var(--rule-accent) solid var(--color-navy);
  border-radius: 2px;
  background: var(--color-navy);
  color: var(--color-on-navy);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.3;
  text-decoration: none;
}

.button:hover {
  border-color: var(--color-navy-hover);
  background: var(--color-navy-hover);
  box-shadow: inset 0 calc(-1 * var(--rule-band)) 0 var(--color-gold);
}

.button:active {
  box-shadow: none;
}

.button-secondary {
  background: var(--color-white);
  color: var(--color-navy);
}

.button-secondary:hover {
  border-color: var(--color-navy);
  background: var(--color-navy);
  color: var(--color-on-navy);
  box-shadow: none;
}

/* 6. Page intro (off-white band under the header) -------------------------- */

.page-intro {
  padding-block: var(--space-intro);
  border-bottom: var(--rule-thin) solid var(--color-rule);
  background: var(--color-paper);
}

.page-intro h1 {
  max-width: 44rem;
  margin: 0;
  font-size: var(--text-h1);
  font-weight: 400;
  line-height: 1.12;
}

.lede {
  max-width: var(--measure);
  margin: 1.25rem 0 0;
  font-size: var(--text-lede);
}

.note {
  max-width: var(--measure);
  margin: 1rem 0 0;
  color: var(--color-text-muted);
  font-size: var(--text-small);
}

/* "At a glance" strip on the home page */

.glance {
  margin-top: 2.75rem;
  padding-top: 1.1rem;
  border-top: var(--rule-accent) solid var(--color-gold);
}

.glance-title,
.data-table thead th {
  color: var(--color-text-muted);
  font-family: var(--font-sans);
  font-size: var(--text-label);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.glance-title {
  margin: 0 0 0.9rem;
}

.glance-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
  gap: 1rem 0;
  margin: 0;
}

.glance-list > div {
  padding: 0.1rem 0.75rem 0.1rem 0.9rem;
  border-left: var(--rule-thin) solid var(--color-rule);
}

.glance-list dt {
  color: var(--color-text-muted);
  font-size: var(--text-label);
}

.glance-list dd {
  margin: 0;
  color: var(--color-navy);
  font-size: 1rem;
  font-weight: 600;
}

/* On phones the strip becomes a short label / value list, so identifiers
   such as the UEI are never broken across lines. */
@media (max-width: 30rem) {
  .glance-list {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .glance-list > div {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.55rem 0;
    border-bottom: var(--rule-thin) solid var(--color-rule);
    border-left: 0;
  }

  .glance-list > div:first-child {
    padding-top: 0;
  }

  .glance-list dd {
    text-align: right;
  }
}

/* 7. Sections and lists ---------------------------------------------------- */

.section {
  padding-block: var(--space-section);
  border-top: var(--rule-thin) solid var(--color-rule);
}

.page-intro + .section {
  border-top: 0;
}

.section-grid {
  display: grid;
  gap: 1.25rem;
}

/* On wide screens the section heading sits in a left-hand margin column,
   as in a printed specification. */
@media (min-width: 60rem) {
  .section-grid {
    grid-template-columns: var(--label-column) minmax(0, 1fr);
    column-gap: 3.5rem;
  }
}

.section h2 {
  margin: 0;
  font-size: var(--text-h2);
  font-weight: 600;
}

.section h2::before {
  content: "";
  display: block;
  width: 2.5rem;
  height: var(--rule-accent);
  margin-bottom: 0.9rem;
  background: var(--color-gold);
}

.section-body > :first-child {
  margin-top: 0;
}

.section-body > :last-child {
  margin-bottom: 0;
}

.section-body > p,
.section-body > ul {
  max-width: var(--measure);
}

.section-body .actions {
  margin-top: 1.5rem;
}

.plain-list {
  padding: 0;
  list-style-type: "";
}

.plain-list li {
  padding: 0.6rem 0;
  border-bottom: var(--rule-thin) solid var(--color-rule);
}

.plain-list li:first-child {
  padding-top: 0;
}

.meta {
  color: var(--color-text-muted);
  font-size: var(--text-small);
}

/* Numbered "How we work" steps */

.steps {
  max-width: var(--measure);
  margin: 0;
  padding: 0;
  list-style-type: "";
  counter-reset: step;
}

.steps li {
  display: grid;
  grid-template-columns: 3rem minmax(0, 1fr);
  column-gap: 1rem;
  padding-block: 1.1rem;
  border-top: var(--rule-thin) solid var(--color-rule);
  counter-increment: step;
}

.steps li:first-child {
  padding-top: 0;
  border-top: 0;
}

.steps li:last-child {
  padding-bottom: 0;
}

.steps li::before {
  content: counter(step);
  grid-row: 1 / span 2;
  grid-column: 1;
  color: var(--color-navy);
  font-family: var(--font-serif);
  font-size: 2rem;
  line-height: 1;
}

.steps li > * {
  grid-column: 2;
}

.steps h3 {
  margin: 0 0 0.25rem;
  font-size: var(--text-h3);
  font-weight: 600;
}

.steps p {
  margin: 0;
}

/* Label and value pairs (point of contact, contact details) */

.detail-list {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 0.55rem 1.75rem;
  max-width: var(--measure);
}

.detail-list dt {
  color: var(--color-text-muted);
  font-size: var(--text-small);
  line-height: 1.8;
}

.detail-list dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.detail-list .detail-name {
  color: var(--color-navy);
  font-weight: 600;
}

/* 8. Tables ---------------------------------------------------------------- */

.data-table {
  width: 100%;
  border-top: var(--rule-accent) solid var(--color-navy);
  border-collapse: collapse;
}

.data-table th,
.data-table td {
  padding: 0.8rem 1rem 0.8rem 0;
  border-bottom: var(--rule-thin) solid var(--color-rule);
  text-align: left;
  vertical-align: top;
}

.data-table td:last-child,
.data-table th:last-child {
  padding-right: 0;
}

.data-table tbody th {
  color: var(--color-navy);
  font-weight: 600;
}

.data-table thead th {
  padding-block: 0.6rem;
  background: var(--color-paper);
}

.data-table thead th:first-child {
  padding-left: 0.75rem;
}

.data-table-keyed tbody th {
  width: 36%;
}

.data-table-codes tbody th,
.data-table-codes tbody td:first-child {
  padding-left: 0.75rem;
}

.data-table-codes tbody th {
  width: 7rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.identifier {
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.tag {
  display: inline-block;
  margin-left: 0.5rem;
  padding: 0.05rem 0.45rem;
  border: var(--rule-thin) solid var(--color-navy);
  color: var(--color-navy);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

@media (max-width: 30rem) {
  .data-table th,
  .data-table td {
    padding-right: 0.75rem;
    font-size: 1rem;
  }

  .data-table-codes tbody th {
    width: 5.25rem;
  }

  .tag {
    margin-left: 0;
  }
}

/* 9. Footer ---------------------------------------------------------------- */

.site-footer {
  padding-block: 2.5rem;
  border-top: var(--rule-band) solid var(--color-gold);
  background: var(--color-navy);
  color: var(--color-on-navy-muted);
  font-size: var(--text-small);
}

.site-footer a {
  color: var(--color-on-navy);
}

.footer-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.5rem;
  margin: 0 0 1.25rem;
  padding: 0;
  list-style-type: "";
}

.footer-nav a {
  display: inline-block;
  padding-block: 0.3rem;
}

.footer-contact {
  margin: 0 0 1.5rem;
}

.footer-legal {
  margin: 0 0 0.5rem;
  padding-top: 1.25rem;
  border-top: var(--rule-thin) solid rgba(255, 255, 255, 0.22);
  color: var(--color-on-navy);
}

.footer-disclaimer {
  max-width: var(--measure);
  margin: 0;
}

/* 10. Utilities ------------------------------------------------------------ */

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* 11. Print ---------------------------------------------------------------- */

@media print {
  body {
    display: block;
    font-size: 11pt;
  }

  .skip-link,
  .site-nav,
  .footer-nav,
  .actions {
    display: none;
  }

  .site-header,
  .site-footer,
  .page-intro {
    border-color: #000;
    background: none;
    color: #000;
  }

  .brand,
  .wordmark-and,
  .site-footer a,
  .footer-legal {
    color: #000;
  }

  .section {
    padding-block: 1.25rem;
    break-inside: avoid;
  }
}
