/* ============================================================
   MODERN CSS RESET — Andrew O'Bryan Wills & Estates
   ============================================================ */

/* ------------------------------------------------------------
   Box sizing
   ------------------------------------------------------------ */

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

/* ------------------------------------------------------------
   Remove default margins and paddings
   ------------------------------------------------------------ */

* {
  margin: 0;
  padding: 0;
}

/* ------------------------------------------------------------
   Core root settings
   ------------------------------------------------------------ */

html {
  font-size: 100%;          /* 16px base; respects user browser settings */
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  tab-size: 4;
}

/* ------------------------------------------------------------
   Body defaults
   ------------------------------------------------------------ */

body {
  line-height: var(--leading-relaxed, 1.7);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* ------------------------------------------------------------
   Inherit line-height and font
   ------------------------------------------------------------ */

h1, h2, h3, h4, h5, h6,
p, blockquote, dl, dd,
figure, figcaption,
pre, code, kbd, samp {
  line-height: inherit;
}

/* ------------------------------------------------------------
   Media elements
   ------------------------------------------------------------ */

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

img,
video {
  height: auto;
}

svg {
  overflow: hidden;
}

/* ------------------------------------------------------------
   Form elements — inherit typography
   ------------------------------------------------------------ */

input,
button,
textarea,
select,
optgroup {
  font: inherit;
  color: inherit;
  letter-spacing: inherit;
  word-spacing: inherit;
}

textarea {
  resize: vertical;
}

button {
  background: none;
  border: none;
  cursor: pointer;
}

/* Remove default fieldset styles */
fieldset {
  border: none;
}

legend {
  padding: 0;
}

/* ------------------------------------------------------------
   List role reset — semantic lists with role="list"
   ------------------------------------------------------------ */

ul[role="list"],
ol[role="list"] {
  list-style: none;
}

/* Remove list style when class is present (utility) */
.list-none {
  list-style: none;
}

/* ------------------------------------------------------------
   Table defaults
   ------------------------------------------------------------ */

table {
  border-collapse: collapse;
  border-spacing: 0;
}

/* ------------------------------------------------------------
   Focus-visible — accessible keyboard outline
   ------------------------------------------------------------ */

*:focus {
  outline: none;
}

*:focus-visible {
  outline: 2px solid var(--color-navy, #1B3A6B);
  outline-offset: 3px;
  border-radius: 2px;
}

/* On dark backgrounds */
.section--navy *:focus-visible,
.site-footer *:focus-visible,
.cta-band *:focus-visible,
.trust-bar *:focus-visible {
  outline-color: var(--color-gold, #C9A96E);
}

/* ------------------------------------------------------------
   Anchor defaults
   ------------------------------------------------------------ */

a {
  color: inherit;
  text-decoration: none;
}

/* ------------------------------------------------------------
   Horizontal rule
   ------------------------------------------------------------ */

hr {
  border: none;
  border-top: var(--border-width, 1px) solid var(--color-border, #E5E7EB);
  color: inherit;
  height: 0;
  overflow: visible;
}

/* ------------------------------------------------------------
   Abbreviations
   ------------------------------------------------------------ */

abbr[title] {
  text-decoration: underline dotted;
  cursor: help;
}

/* ------------------------------------------------------------
   Strong / bold
   ------------------------------------------------------------ */

b,
strong {
  font-weight: bolder;
}

/* ------------------------------------------------------------
   Code
   ------------------------------------------------------------ */

code,
kbd,
samp,
pre {
  font-family: var(--font-mono, monospace);
  font-size: 0.9em;
}

/* ------------------------------------------------------------
   Small
   ------------------------------------------------------------ */

small {
  font-size: 0.875em;
}

/* ------------------------------------------------------------
   Sub / sup
   ------------------------------------------------------------ */

sub,
sup {
  font-size: 0.75em;
  line-height: 0;
  position: relative;
  vertical-align: baseline;
}

sub { bottom: -0.25em; }
sup { top: -0.5em; }

/* ------------------------------------------------------------
   Hidden attribute
   ------------------------------------------------------------ */

[hidden] {
  display: none !important;
}

/* ------------------------------------------------------------
   Disabled state
   ------------------------------------------------------------ */

:disabled {
  cursor: not-allowed;
  opacity: 0.6;
}

/* ------------------------------------------------------------
   Overflow wrap
   ------------------------------------------------------------ */

p,
h1, h2, h3, h4, h5, h6 {
  overflow-wrap: break-word;
  word-break: break-word;
  hyphens: auto;
}

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

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

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
