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

* {
  margin: 0;
}

/* Components set their own display; `hidden` must still win. */
[hidden] {
  display: none !important;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 1.5rem);
}

body {
  min-height: 100vh;
  background-color: var(--wall);
  background-image: var(--fresco-grain), var(--fresco-mottle);
  color: var(--plaster);
  font-family: var(--font-text);
  font-size: var(--text-base);
  line-height: 1.6;
  font-kerning: normal;
  font-variant-numeric: oldstyle-nums proportional-nums;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: inherit;
  text-underline-offset: 0.2em;
  text-decoration-thickness: 1px;
}

button,
input,
textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
}

h1,
h2,
h3,
h4 {
  font-weight: 400;
  line-height: 1.1;
  text-wrap: balance;
}

p {
  text-wrap: pretty;
}

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

.surface-parchment :focus-visible {
  outline-color: var(--wall);
}

::selection {
  background: var(--gold);
  color: var(--night);
}

.container {
  width: min(100% - 2 * var(--gutter), var(--max-width));
  margin-inline: auto;
}

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

.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

/* Icons come from the inline sprite; stroke styles must be set here to reach <use>. */
.icon {
  flex: none;
  width: 1.25em;
  height: 1.25em;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.skip-link {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 100;
  padding: 0.75rem 1rem;
  border-radius: var(--r-sm);
  background: var(--gold);
  color: var(--night);
  font-family: var(--font-ui);
  font-weight: 600;
  translate: 0 -200%;
}

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

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-ui);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--on-wall-muted);
}

.eyebrow::before {
  content: "";
  width: 1.5rem;
  height: 1px;
  background: currentColor;
  opacity: 0.7;
}

.eyebrow--plain {
  display: inline-block;
}

.eyebrow--plain::before {
  display: none;
}

.surface-night .eyebrow,
.card .eyebrow {
  color: var(--gold);
}

.surface-parchment .eyebrow {
  color: var(--wall);
}

.interpunct {
  padding-inline: 0.4em;
}

.la {
  font-style: italic;
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}
