:root {
  --color-sand: #F2E8D5;
  --color-sand-deep: #E6D5B8;
  --color-burnt-orange: #C75B2A;
  --color-burnt-orange-deep: #A84A20;
  --color-dusty-pink: #D98C7A;
  --color-twilight-violet: #4A3B5C;
  --color-midnight-blue: #1E2433;
  --color-midnight-blue-soft: #3A4255;
  --color-horizon-white: #FBF7F0;
  --color-dune-shadow: #D4C4A8;
  --gradient-sunset: linear-gradient(180deg, #F2E8D5 0%, #D98C7A 45%, #4A3B5C 100%);

  --font-heading: 'Cormorant Garamond', Georgia, serif;
  --font-body: 'Inter', 'Helvetica Neue', Arial, sans-serif;

  --text-display: clamp(2.8rem, 7vw, 5.5rem);
  --text-h1: clamp(2.2rem, 5vw, 3.6rem);
  --text-h2: clamp(1.6rem, 3.5vw, 2.4rem);
  --text-h3: clamp(1.25rem, 2.5vw, 1.6rem);
  --text-body-large: 1.125rem;
  --text-body: 1rem;
  --text-small: 0.875rem;
  --text-label: 0.75rem;

  --leading-display: 1.05;
  --leading-h1: 1.1;
  --leading-h2: 1.2;
  --leading-h3: 1.3;
  --leading-body-large: 1.7;
  --leading-body: 1.65;
  --leading-small: 1.5;
  --leading-label: 1.4;

  --tracking-display: -0.02em;
  --tracking-h1: -0.01em;
  --tracking-small: 0.01em;
  --tracking-label: 0.12em;

  --space-2xs: 0.25rem;
  --space-xs: 0.5rem;
  --space-sm: 0.75rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2.5rem;
  --space-2xl: 4rem;
  --space-3xl: 6rem;
  --space-4xl: 9rem;

  --container-padding-mobile: 1.25rem;
  --container-padding-tablet: 2rem;
  --container-padding-desktop: 3rem;
  --container-max-reading: 720px;
  --container-max-wide: 1120px;

  --radius-interactive: 4px;
  --radius-card: 8px;
  --radius-pill: 999px;

  --shadow-soft: 0 8px 24px rgba(30, 36, 51, 0.08);

  --focus-outline-width: 2px;
  --focus-outline-offset: 2px;

  --transition-fast: 150ms ease-out;
  --transition-image: 400ms ease-out;
  --transition-overlay: 250ms ease-out;
}

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

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

body {
  font-family: var(--font-body);
  font-size: var(--text-body);
  line-height: var(--leading-body);
  font-weight: 400;
  color: var(--color-midnight-blue);
  background-color: var(--color-sand);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
  overflow-x: hidden;
}

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

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

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

a {
  color: var(--color-midnight-blue);
  text-decoration: underline;
  text-decoration-color: var(--color-burnt-orange);
  text-underline-offset: 3px;
  transition: text-decoration-color var(--transition-fast);
}

a:hover {
  text-decoration-color: var(--color-dusty-pink);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: var(--focus-outline-width) solid var(--color-burnt-orange);
  outline-offset: var(--focus-outline-offset);
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  color: var(--color-midnight-blue);
  font-weight: 400;
  margin-block-end: var(--space-md);
}

h1 {
  font-size: var(--text-h1);
  line-height: var(--leading-h1);
  font-weight: 300;
  letter-spacing: var(--tracking-h1);
  margin-block-end: var(--space-lg);
}

h2 {
  font-size: var(--text-h2);
  line-height: var(--leading-h2);
  margin-block-end: var(--space-lg);
}

h3 {
  font-size: var(--text-h3);
  line-height: var(--leading-h3);
  font-weight: 500;
  margin-block-end: var(--space-md);
}

h4 {
  font-size: var(--text-body-large);
  line-height: var(--leading-body-large);
  font-weight: 500;
  margin-block-end: var(--space-sm);
}

h5,
h6 {
  font-size: var(--text-body);
  line-height: var(--leading-body);
  font-weight: 500;
  margin-block-end: var(--space-sm);
}

p {
  margin-block-end: var(--space-md);
}

ul,
ol {
  margin-block-end: var(--space-md);
  padding-inline-start: var(--space-lg);
}

li {
  margin-block-end: var(--space-xs);
}

li:last-child {
  margin-block-end: 0;
}

blockquote {
  margin-block-end: var(--space-lg);
  padding-inline-start: var(--space-lg);
  border-inline-start: 2px solid var(--color-burnt-orange);
  font-family: var(--font-heading);
  font-size: var(--text-h2);
  line-height: var(--leading-h2);
  color: var(--color-midnight-blue);
}

figure {
  margin-block-end: var(--space-lg);
}

figcaption {
  font-size: var(--text-small);
  line-height: var(--leading-small);
  letter-spacing: var(--tracking-small);
  color: var(--color-midnight-blue-soft);
  margin-block-start: var(--space-sm);
  text-align: left;
}

dl {
  margin-block-end: var(--space-md);
}

dt {
  font-size: var(--text-label);
  line-height: var(--leading-label);
  font-weight: 500;
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--color-midnight-blue-soft);
  margin-block-end: var(--space-2xs);
}

dd {
  margin-block-end: var(--space-sm);
}

dd:last-child {
  margin-block-end: 0;
}

hr {
  border: none;
  border-top: 1px solid var(--color-dune-shadow);
  margin-block: var(--space-xl);
}

code,
pre,
kbd,
samp {
  font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
  font-size: 0.9em;
}

pre {
  margin-block-end: var(--space-md);
  padding: var(--space-md);
  background-color: var(--color-sand-deep);
  border-radius: var(--radius-card);
  overflow-x: auto;
}

small {
  font-size: var(--text-small);
  line-height: var(--leading-small);
  letter-spacing: var(--tracking-small);
}

strong {
  font-weight: 600;
}

em {
  font-style: italic;
}

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

mark {
  background-color: var(--color-dusty-pink);
  color: var(--color-midnight-blue);
  padding-inline: 0.2em;
}

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

sub {
  bottom: -0.25em;
}

sup {
  top: -0.5em;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin-block-end: var(--space-md);
}

th,
td {
  padding: var(--space-sm) var(--space-md);
  text-align: left;
  border-bottom: 1px solid var(--color-dune-shadow);
}

th {
  font-size: var(--text-label);
  line-height: var(--leading-label);
  font-weight: 500;
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--color-midnight-blue-soft);
}

input,
textarea,
select {
  width: 100%;
  padding: var(--space-sm) var(--space-md);
  font-size: var(--text-body);
  line-height: var(--leading-body);
  color: var(--color-midnight-blue);
  background-color: var(--color-horizon-white);
  border: 1px solid var(--color-dune-shadow);
  border-radius: var(--radius-interactive);
  transition: border-color var(--transition-fast);
}

input::placeholder,
textarea::placeholder {
  color: var(--color-midnight-blue-soft);
  opacity: 0.7;
}

input:focus,
textarea:focus,
select:focus {
  border-color: var(--color-burnt-orange);
  outline: var(--focus-outline-width) solid var(--color-burnt-orange);
  outline-offset: var(--focus-outline-offset);
}

textarea {
  min-height: 8rem;
  resize: vertical;
}

select {
  appearance: auto;
  cursor: pointer;
}

label {
  display: block;
  font-size: var(--text-label);
  line-height: var(--leading-label);
  font-weight: 500;
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--color-midnight-blue-soft);
  margin-block-end: var(--space-xs);
}

fieldset {
  border: 1px solid var(--color-dune-shadow);
  border-radius: var(--radius-card);
  padding: var(--space-lg);
  margin-block-end: var(--space-lg);
}

legend {
  font-size: var(--text-label);
  line-height: var(--leading-label);
  font-weight: 500;
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--color-midnight-blue-soft);
  padding-inline: var(--space-xs);
}

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

.container--wide {
  max-width: var(--container-max-wide);
}

.container--full {
  max-width: none;
  padding-inline: 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
  padding: var(--space-md) var(--space-lg);
  font-size: var(--text-body);
  line-height: var(--leading-body);
  font-weight: 500;
  font-family: var(--font-body);
  color: var(--color-horizon-white);
  background-color: var(--color-burnt-orange);
  border: 1px solid var(--color-burnt-orange);
  border-radius: var(--radius-interactive);
  text-decoration: none;
  transition: background-color var(--transition-fast), border-color var(--transition-fast);
  min-height: 44px;
  cursor: pointer;
}

.btn:hover {
  background-color: var(--color-burnt-orange-deep);
  border-color: var(--color-burnt-orange-deep);
  color: var(--color-horizon-white);
  text-decoration: none;
}

.btn--secondary {
  background-color: transparent;
  color: var(--color-burnt-orange);
  border-color: var(--color-burnt-orange);
}

.btn--secondary:hover {
  background-color: var(--color-burnt-orange);
  border-color: var(--color-burnt-orange);
  color: var(--color-horizon-white);
}

.card {
  background-color: var(--color-sand-deep);
  border-radius: var(--radius-card);
  padding: var(--space-lg);
  border: 1px solid var(--color-dune-shadow);
}

.card > :last-child {
  margin-block-end: 0;
}

.surface-dark {
  background-color: var(--color-twilight-violet);
  color: var(--color-horizon-white);
}

.surface-dark h1,
.surface-dark h2,
.surface-dark h3,
.surface-dark h4,
.surface-dark h5,
.surface-dark h6 {
  color: var(--color-horizon-white);
}

.surface-dark a {
  color: var(--color-horizon-white);
  text-decoration-color: var(--color-dusty-pink);
}

.surface-dark a:hover {
  text-decoration-color: var(--color-burnt-orange);
}

.overline {
  display: block;
  font-size: var(--text-label);
  line-height: var(--leading-label);
  font-weight: 500;
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--color-dusty-pink);
  margin-block-end: var(--space-xs);
}

.tag {
  display: inline-block;
  padding: var(--space-2xs) var(--space-sm);
  font-size: var(--text-small);
  line-height: var(--leading-small);
  letter-spacing: var(--tracking-small);
  font-weight: 500;
  color: var(--color-midnight-blue);
  background-color: var(--color-dusty-pink);
  border-radius: var(--radius-pill);
}

.flex {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-md);
}

.flex > * {
  min-width: 0;
}

.flex--nowrap {
  flex-wrap: nowrap;
}

.flex--column {
  flex-direction: column;
}

.flex--align-center {
  align-items: center;
}

.flex--align-start {
  align-items: flex-start;
}

.flex--align-end {
  align-items: flex-end;
}

.flex--justify-start {
  justify-content: flex-start;
}

.flex--justify-center {
  justify-content: center;
}

.flex--justify-end {
  justify-content: flex-end;
}

.flex--justify-between {
  justify-content: space-between;
}

.flex--gap-xs {
  gap: var(--space-xs);
}

.flex--gap-sm {
  gap: var(--space-sm);
}

.flex--gap-lg {
  gap: var(--space-lg);
}

.flex--gap-xl {
  gap: var(--space-xl);
}

.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;
  top: -100%;
  left: var(--space-md);
  z-index: 1000;
  padding: var(--space-sm) var(--space-lg);
  background-color: var(--color-midnight-blue);
  color: var(--color-horizon-white);
  border-radius: var(--radius-interactive);
  text-decoration: none;
  transition: top var(--transition-fast);
}

.skip-link:focus {
  top: var(--space-md);
  outline: var(--focus-outline-width) solid var(--color-burnt-orange);
  outline-offset: var(--focus-outline-offset);
}

@media (min-width: 768px) {
  .container {
    padding-inline: var(--container-padding-tablet);
  }
}

@media (min-width: 1200px) {
  .container {
    padding-inline: var(--container-padding-desktop);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}