/* =========================================================================
   BASE — reset, global typography, accessibility primitives
   ========================================================================= */

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

/* Defensive override: several components (.btn, .booking__progress, etc.)
   set their own `display`, which has the same specificity as the
   browser's built-in `[hidden] { display: none }` rule and — being an
   author-stylesheet rule vs. the UA stylesheet — would otherwise win and
   make [hidden] elements visible. This keeps [hidden] authoritative
   everywhere on the site. */
[hidden] { display: none !important; }

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

@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;
  }
}

body {
  margin: 0;
  background: var(--surface-primary);
  color: var(--text-on-light);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Lock scroll while the booking modal is open */
body.no-scroll { overflow: hidden; height: 100vh; }

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

h1, h2, h3, h4, p, figure { margin: 0; }

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

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

ul { list-style: none; margin: 0; padding: 0; }

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

/* ---- Accessibility primitives ------------------------------------------ */

.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: fixed;
  top: -100%;
  left: var(--space-sm);
  z-index: 1000;
  background: var(--color-gold-500);
  color: var(--text-on-dark);
  padding: var(--space-2xs) var(--space-sm);
  font-family: var(--font-body);
  font-weight: 600;
  border-radius: var(--radius-sm);
  transition: top var(--dur-fast) var(--ease-out-soft);
}

.skip-link:focus {
  top: var(--space-sm);
}

/* Visible, brand-consistent focus ring for every interactive element,
   keyboard users only (mouse/touch clicks don't trigger :focus-visible). */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

/* ---- Typography ---------------------------------------------------------*/

.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-size: var(--fs-eyebrow);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--text-accent);
}

.display-xl {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--fs-display-xl);
  line-height: 0.98;
  letter-spacing: 0.01em;
}

.display-lg {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--fs-display-lg);
  line-height: 1.04;
}

.display-md {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--fs-display-md);
  line-height: 1.08;
}

.heading {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--fs-heading);
  line-height: 1.2;
}

.body-lg {
  font-size: var(--fs-body-lg);
  font-weight: 300;
}

.text-muted-on-dark { color: var(--text-on-dark-muted); }
.text-muted-on-light { color: var(--text-on-light-muted); }

/* ---- Layout helpers -------------------------------------------------- */

/* Offsets native anchor scrolling so section tops clear the fixed nav —
   this is what makes #links work without any JS at all. */
section[id] {
  scroll-margin-top: 84px;
}

.section {
  position: relative;
  padding-block: var(--space-2xl);
}

.section--tight { padding-block: var(--space-xl); }

.wrap {
  max-width: var(--content-max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.wrap--narrow {
  max-width: var(--content-narrow);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.theme-light {
  background: var(--surface-light);
  color: var(--text-on-light);
}

.theme-elevated {
  background: var(--surface-elevated);
}

/* ---- Buttons ------------------------------------------------------------*/

.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2xs);
  padding: var(--space-xs) var(--space-md);
  font-size: var(--fs-small);
  letter-spacing: var(--tracking-mid);
  text-transform: uppercase;
  border: 1px solid currentColor;
  border-radius: var(--radius-sm);
  transition: background var(--dur-fast) var(--ease-out-soft),
              color var(--dur-fast) var(--ease-out-soft),
              transform var(--dur-fast) var(--ease-out-soft),
              border-color var(--dur-fast) var(--ease-out-soft);
}

.btn:hover, .btn:focus-visible {
  transform: translateY(-1px);
}

.btn--primary {
  background: var(--color-gold-500);
  border-color: var(--color-gold-500);
  color: var(--text-on-dark);
}
.btn--primary:hover, .btn--primary:focus-visible {
  background: var(--color-gold-600);
  border-color: var(--color-gold-600);
}

.btn--ghost-dark {
  color: var(--text-on-dark);
  border-color: var(--border-on-dark);
}
.btn--ghost-dark:hover, .btn--ghost-dark:focus-visible {
  border-color: var(--color-gold-500);
  color: var(--color-gold-500);
}

.btn--ghost-light {
  color: var(--text-on-light);
  border-color: var(--border-on-light);
}
.btn--ghost-light:hover, .btn--ghost-light:focus-visible {
  border-color: var(--color-gold-600);
  color: var(--color-gold-600);
}

.btn--text {
  border: 0;
  padding: 0;
  text-transform: none;
  letter-spacing: normal;
  font-size: var(--fs-body-lg);
  border-bottom: 1px solid var(--border-accent);
  border-radius: 0;
}

/* ---- Media ---------------------------------------------------------------
   Shared figure treatment for every real photograph on the site (see
   js/data.js for the asset paths). object-fit keeps future re-crops —
   full-bleed, portrait, landscape — working without layout changes. */

.media {
  position: relative;
  overflow: hidden;
  background: var(--surface-elevated);
}

.media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
