/* Bard Watch base: fonts, colors, type, forms, buttons, utilities. Fonts are self-hosted (OFL, see
   site/fonts/); there are no external requests. Warm cream pages, parchment cards, forest green
   buttons, cardinal red accents. */

@font-face {
  font-family: "Fraunces";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../fonts/fraunces-latin-600-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Fraunces";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/fraunces-latin-700-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Fraunces";
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("../fonts/fraunces-latin-800-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Source Serif 4";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/source-serif-4-latin-400-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Source Serif 4";
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/source-serif-4-latin-400-italic.woff2") format("woff2");
}
@font-face {
  font-family: "Source Serif 4";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../fonts/source-serif-4-latin-600-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Source Serif 4";
  font-style: italic;
  font-weight: 600;
  font-display: swap;
  src: url("../fonts/source-serif-4-latin-600-italic.woff2") format("woff2");
}

:root {
  /* Palette (sampled from the approved mockups). Contrast on cream: ink 12.9, forest 9.9, cardinal 5.4;
     on parchment: ink 11.3, forest 8.7, cardinal 4.8; cream on forest 9.9, cream on cardinal 5.4. */
  --cream: #faf3e7;
  --parchment: #f4e4c9;
  --parchment-line: #e4d2b0;
  --forest: #154530;
  --forest-deep: #0b3f2a;
  --forest-press: #072e1e;
  --cardinal: #be2530;
  --ink: #2b2b28;
  --ink-soft: #5a5648;
  --tan: #cdbb98;
  --hill: #8fb79a;

  --bg: var(--cream);
  --panel: var(--parchment);
  --panel-line: var(--parchment-line);
  --field-bg: #fffbf2;
  --text: var(--ink);
  --text-soft: var(--ink-soft);
  --err: #8a1218;
  --err-bg: #f8e1df;
  --info-bg: #eaeedd;
  --focus: var(--cardinal);

  --font-text: "Source Serif 4", Georgia, "Times New Roman", serif;
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --radius: 20px;
  --page-max: 1280px;
}

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

[hidden] {
  display: none !important;
}

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

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-text);
  font-size: 1.0625rem;
  line-height: 1.45;
  overflow-wrap: anywhere;
}
body.has-sheet {
  overflow: hidden;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--forest);
  line-height: 1.15;
  margin: 0 0 0.5rem;
}
h1 {
  font-size: clamp(1.8rem, 6vw, 2.6rem);
  font-weight: 800;
}
h2 {
  font-size: 1.35rem;
}
h3 {
  font-size: 1.15rem;
}
h4 {
  font-size: 1rem;
}

p {
  margin: 0 0 0.75rem;
}

a {
  color: var(--forest);
  text-underline-offset: 3px;
}

ul,
ol {
  padding-left: 1.25rem;
}

img {
  max-width: 100%;
}

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}
.topbar :focus-visible,
.tabbar :focus-visible,
.booking-bar:focus-visible,
.btn-primary:focus-visible {
  outline-color: var(--cream);
  box-shadow: 0 0 0 5px var(--forest);
}

[tabindex="-1"]:focus {
  outline: none;
}

.sr-only {
  position: absolute !important;
  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;
  left: 8px;
  top: -80px;
  z-index: 200;
  background: var(--forest-deep);
  color: var(--cream);
  padding: 0.75rem 1rem;
  border-radius: 10px;
}
.skip-link:focus {
  top: 8px;
}

.icon {
  width: 1.25em;
  height: 1.25em;
  flex: none;
  vertical-align: -0.22em;
}

.small {
  font-size: 0.92rem;
  color: var(--text-soft);
}

/* ---- forms ------------------------------------------------------------------------------- */

.label,
legend.label {
  display: block;
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--forest);
  margin-bottom: 0.3rem;
  padding: 0;
}

.input {
  display: block;
  width: 100%;
  min-height: 48px;
  padding: 0.55rem 1rem;
  border: 2px solid var(--forest);
  border-radius: 16px;
  background: var(--field-bg);
  color: var(--text);
  font: inherit;
}
.input::placeholder {
  color: var(--ink-soft);
  opacity: 0.85;
}
.input:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}
select.input {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 2.4rem;
  background-image: linear-gradient(45deg, transparent 50%, var(--forest) 50%), linear-gradient(135deg, var(--forest) 50%, transparent 50%);
  background-position: calc(100% - 20px) 55%, calc(100% - 14px) 55%;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}
.textarea {
  min-height: 9rem;
  resize: vertical;
  border-radius: 14px;
}
input[type="file"].input {
  padding: 0.5rem 0.75rem;
}

.field {
  margin: 0 0 1rem;
}
.field-hint {
  margin: 0.3rem 0 0;
  color: var(--text-soft);
  font-size: 0.9rem;
}
.field-hint.is-error {
  color: var(--err);
  font-weight: 600;
}
.fieldset {
  border: 0;
  padding: 0;
  margin: 0 0 1rem;
  min-width: 0;
}

.check-field {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  min-height: 44px;
  margin: 0 0 0.25rem;
}
.check-field input[type="checkbox"],
.check-field input[type="radio"],
.check-item input[type="checkbox"],
.check-item input[type="radio"] {
  flex: none;
  width: 24px;
  height: 24px;
  margin: 0;
  accent-color: var(--forest);
}
.check-field label {
  flex: 1;
  min-height: 44px;
  display: flex;
  align-items: center;
}

/* ---- buttons ----------------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: 48px;
  min-width: 44px;
  padding: 0.5rem 1.4rem;
  border: 2px solid transparent;
  border-radius: 999px;
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  background: transparent;
  color: var(--forest);
}
.btn:disabled,
.btn[aria-disabled="true"] {
  opacity: 0.55;
  cursor: not-allowed;
}
.btn-primary {
  background: var(--forest);
  border-color: var(--forest);
  color: var(--cream);
}
.btn-primary:hover:not(:disabled),
.btn-primary:active:not(:disabled) {
  background: var(--forest-deep);
  border-color: var(--forest-deep);
}
.btn-primary:active:not(:disabled) {
  background: var(--forest-press);
}
.btn-secondary {
  border-color: var(--forest);
  color: var(--forest);
  background: transparent;
}
.btn-secondary:hover:not(:disabled) {
  background: rgba(21, 69, 48, 0.09);
}
.btn-quiet,
.btn-ghost {
  border-color: transparent;
  color: var(--forest);
  text-decoration: underline;
  font-weight: 600;
}
.btn-danger-quiet {
  border-color: var(--err);
  color: var(--err);
  min-height: 44px;
  font-size: 0.95rem;
}
.btn-danger {
  background: var(--cardinal);
  border-color: var(--cardinal);
  color: #fff;
  min-height: 44px;
  font-size: 0.95rem;
}
.btn-wide,
.btn-block {
  display: flex;
  width: 100%;
}
.btn-small {
  min-height: 44px;
  padding: 0.35rem 1.1rem;
  font-size: 0.98rem;
}
.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 0.5rem;
}

/* ---- progress meter (My Profile) ------------------------------------------------------------ */

progress.meter {
  display: block;
  width: 100%;
  height: 14px;
  appearance: none;
  -webkit-appearance: none;
  border: 0;
  border-radius: 999px;
  overflow: hidden;
  background: var(--tan);
}
progress.meter::-webkit-progress-bar {
  background: var(--tan);
  border-radius: 999px;
}
progress.meter::-webkit-progress-value {
  background: var(--forest);
  border-radius: 999px;
}
progress.meter::-moz-progress-bar {
  background: var(--forest);
  border-radius: 999px;
}

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

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