/* assets/css/main.css
   OMW Factory Design System — v2
   Uses CSS custom properties injected by head/css-vars.html partial.
   Tailwind utility layer is applied via PostCSS.
   ────────────────────────────────────────────────────────────────────────── */

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

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

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-surface);
  line-height: 1.6;
}

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

a { color: var(--color-primary); text-decoration: underline; }
a:hover { color: var(--color-accent); }

/* ── Layout ─────────────────────────────────────────────────────────────────── */
.container {
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: clamp(1rem, 5vw, 2rem);
}

.section-gap { padding-block: var(--section-gap); }

/* ── Typography ─────────────────────────────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-header);
  line-height: 1.2;
  font-weight: 700;
}

h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.5rem, 4vw, 2.5rem); }
h3 { font-size: clamp(1.25rem, 3vw, 1.75rem); }

.section-title    { color: var(--color-primary); }
.section-subtitle { color: var(--color-muted); margin-top: 0.5rem; font-size: 1.1rem; }

/* ── Buttons ────────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-ui);
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  transition:
    background-color var(--transition-fast),
    color var(--transition-fast),
    border-color var(--transition-fast),
    transform var(--transition-fast);
  white-space: nowrap;
}
.btn:hover  { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn:focus-visible { outline: 3px solid var(--color-accent); outline-offset: 3px; }

.btn--primary  { background: var(--color-primary); color: var(--color-white); }
.btn--primary:hover { background: var(--color-accent); color: var(--color-white); }

.btn--outline  { border-color: var(--color-primary); color: var(--color-primary); }
.btn--outline:hover { background: var(--color-primary); color: var(--color-white); }

.btn--ghost    { color: var(--color-muted); }
.btn--ghost:hover { color: var(--color-primary); }

.btn--full     { width: 100%; }
.btn--sm       { padding: 0.4rem 0.9rem; font-size: 0.85rem; }

/* ── Header ─────────────────────────────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--color-white);
  border-bottom: 1px solid var(--color-border);
  box-shadow: 0 1px 4px rgba(0,0,0,.06);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 0.85rem;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: clamp(1rem, 5vw, 2rem);
}

.site-logo {
  font-family: var(--font-header);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-primary);
  text-decoration: none;
}

.nav-list {
  display: none;
  list-style: none;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .nav-list { display: flex; align-items: center; }
}

.nav-list a {
  color: var(--color-text);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  padding: 0.25rem 0;
  border-bottom: 2px solid transparent;
  transition: color var(--transition-fast), border-color var(--transition-fast);
}
.nav-list a:hover,
.nav-list a[aria-current="page"] {
  color: var(--color-primary);
  border-bottom-color: var(--color-accent);
}

.nav-highlight a {
  background: var(--color-accent);
  color: var(--color-white) !important;
  border-radius: var(--radius-ui);
  padding: 0.4rem 0.9rem !important;
  border: none !important;
}

.nav-toggle {
  display: flex;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-primary);
  transition: transform var(--transition-fast);
}
@media (min-width: 768px) { .nav-toggle { display: none; } }

/* ── Hero ────────────────────────────────────────────────────────────────────── */
.hero { background: var(--color-primary); color: var(--color-white); }
.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
  align-items: center;
}
@media (min-width: 768px) {
  .hero-grid { grid-template-columns: 1fr 1fr; }
}

.hero-title   { color: var(--color-white); margin-bottom: 1rem; }
.hero-desc    { opacity: 0.85; font-size: 1.1rem; margin-bottom: 2rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 1rem; }

.hero-image-wrap { position: relative; }
.hero-image-accent {
  position: absolute;
  inset: 1rem -1rem -1rem 1rem;
  background: var(--color-accent);
  border-radius: var(--radius-ui);
  z-index: 0;
}
.hero-image {
  position: relative;
  z-index: 1;
  border-radius: var(--radius-ui);
  -o-object-fit: cover;
     object-fit: cover;
  width: 100%;
  aspect-ratio: 4/3;
}

/* ── Price Search ────────────────────────────────────────────────────────────── */
.search-bar-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
  margin-block: 2rem;
}

.search-input-wrap { position: relative; flex: 1; min-width: 280px; }
.search-input {
  width: 100%;
  padding: 0.85rem 3rem 0.85rem 1rem;
  border: 2px solid var(--color-border);
  border-radius: var(--radius-ui);
  font-size: 1rem;
  transition: border-color var(--transition-fast);
}
.search-input:focus {
  outline: none;
  border-color: var(--color-accent);
}
.search-clear {
  position: absolute;
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: var(--color-muted);
}

/* ── Results Table ───────────────────────────────────────────────────────────── */
.table-wrap { overflow-x: auto; margin-top: 1.5rem; border-radius: var(--radius-ui); border: 1px solid var(--color-border); }
.price-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.price-table th {
  background: var(--color-primary);
  color: var(--color-white);
  padding: 0.75rem 1rem;
  text-align: left;
  font-weight: 600;
  white-space: nowrap;
}
.price-table td { padding: 0.75rem 1rem; border-bottom: 1px solid var(--color-border); vertical-align: top; }
.price-table tr:last-child td { border-bottom: none; }
.price-table tr:hover td { background: var(--color-surface); }

.td-code       { font-family: monospace; white-space: nowrap; }
.td-brand      { }
.brand-link    { font-weight: 600; color: var(--color-primary); text-decoration: none; }
.brand-sub     { display: block; font-size: 0.8rem; color: var(--color-muted); }
.td-size       { white-space: nowrap; color: var(--color-muted); }
.td-price      { text-align: right; white-space: nowrap; }
.price         { font-weight: 700; font-size: 1rem; }
.price--sale   { color: var(--color-accent); }
.price--mxb    { color: var(--color-primary); }
.price-original{ text-decoration: line-through; color: var(--color-muted); font-size: 0.8rem; margin-left: 0.5rem; }
.price-was     { text-decoration: line-through; color: var(--color-muted); font-size: 0.85rem; }

/* ── Badges ──────────────────────────────────────────────────────────────────── */
.badge { display: inline-block; padding: 0.15rem 0.5rem; border-radius: 999px; font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; }
.badge--sale { background: var(--color-accent); color: var(--color-white); }
.badge--mxb  { background: var(--color-primary); color: var(--color-white); }

/* ── Results meta ────────────────────────────────────────────────────────────── */
.results-meta { display: flex; gap: 1rem; align-items: center; font-size: 0.9rem; color: var(--color-muted); }
.sale-count   { color: var(--color-accent); font-weight: 600; }

/* ── No results / empty state ────────────────────────────────────────────────── */
.empty-state, .no-results { padding: 3rem; text-align: center; color: var(--color-muted); }

/* ── Specials Grid ───────────────────────────────────────────────────────────── */
.specials-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 2rem; }
.specials-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.5rem; }

.special-card {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-ui);
  padding: 1.5rem;
  position: relative;
  transition: box-shadow var(--transition-fast);
}
.special-card:hover { box-shadow: 0 8px 24px rgba(0,0,0,.08); }

.special-badge { position: absolute; top: -0.75rem; right: 1rem; background: var(--color-accent); color: var(--color-white); padding: 0.25rem 0.75rem; border-radius: 999px; font-size: 0.8rem; font-weight: 700; }
.special-category { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--color-muted); }
.special-name { font-size: 1.1rem; font-weight: 700; margin-block: 0.25rem; color: var(--color-primary); }
.special-size { color: var(--color-muted); font-size: 0.9rem; }
.special-footer { display: flex; justify-content: space-between; align-items: center; margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--color-border); }
.special-price { font-size: 1.5rem; font-weight: 800; color: var(--color-accent); }
.special-was   { text-decoration: line-through; color: var(--color-muted); font-size: 0.85rem; }
.special-code  { font-size: 0.7rem; color: var(--color-muted); margin-top: 0.75rem; font-family: monospace; }

/* ── Age Gate ────────────────────────────────────────────────────────────────── */
.age-gate {
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(0,0,0,0.8);
  display: flex; align-items: center; justify-content: center;
  padding: 1rem;
}
.age-gate-card {
  background: var(--color-white);
  border-radius: var(--radius-ui);
  padding: 2.5rem;
  max-width: 480px;
  width: 100%;
  text-align: center;
}
.age-gate-icon   { font-size: 3rem; }
.age-gate-title  { font-size: 1.75rem; color: var(--color-primary); margin-block: 0.75rem; }
.age-gate-desc   { color: var(--color-muted); margin-bottom: 2rem; }
.age-gate-actions{ display: flex; flex-wrap: wrap; gap: 1rem; justify-content: center; }
.age-gate-legal  { margin-top: 1.5rem; font-size: 0.8rem; color: var(--color-muted); }

/* ── Forms ───────────────────────────────────────────────────────────────────── */
.lead-form-grid  { display: grid; gap: 3rem; }
@media (min-width: 768px) { .lead-form-grid { grid-template-columns: 1fr 1.5fr; } }

.form-group  { display: flex; flex-direction: column; gap: 0.4rem; }
.form-row    { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-group label { font-weight: 600; font-size: 0.9rem; }

.form-group input,
.form-group select,
.form-group textarea {
  padding: 0.75rem;
  border: 2px solid var(--color-border);
  border-radius: var(--radius-ui);
  font-size: 1rem;
  font-family: var(--font-body);
  transition: border-color var(--transition-fast);
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--color-accent);
}

.lead-form { display: flex; flex-direction: column; gap: 1.25rem; margin-bottom: 2rem; }
.form-success { padding: 1rem; background: #d1fae5; color: #065f46; border-radius: var(--radius-ui); }
.form-error   { padding: 1rem; background: #fee2e2; color: #991b1b; border-radius: var(--radius-ui); }
.honeypot     { position: absolute; opacity: 0; pointer-events: none; left: -9999px; }

/* ── Mobile Action Bar ───────────────────────────────────────────────────────── */
.mobile-action-bar {
  display: flex;
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 50;
  background: var(--color-white);
  border-top: 1px solid var(--color-border);
  box-shadow: 0 -4px 16px rgba(0,0,0,.08);
}
@media (min-width: 768px) { .mobile-action-bar { display: none; } }
.mobile-action-spacer { display: block; height: 72px; }
@media (min-width: 768px) { .mobile-action-spacer { display: none; } }

.action-bar-grid { display: grid; grid-template-columns: repeat(3, 1fr); width: 100%; }
.action-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  padding: 0.75rem 0.5rem;
  text-decoration: none;
  color: var(--color-primary);
  font-size: 0.7rem;
  font-weight: 600;
  border-right: 1px solid var(--color-border);
  transition: background var(--transition-fast);
}
.action-btn:last-child { border-right: none; }
.action-btn:hover { background: var(--color-surface); }
.action-btn--accent { background: var(--color-accent); color: var(--color-white); }
.action-btn--accent:hover { background: var(--color-primary); color: var(--color-white); }

/* ── Footer ──────────────────────────────────────────────────────────────────── */
.site-footer { background: var(--color-primary); color: rgba(255,255,255,0.85); padding-block: 3rem; }
.footer-inner { max-width: var(--container-max); margin-inline: auto; padding-inline: clamp(1rem,5vw,2rem); display: flex; flex-wrap: wrap; gap: 2rem; justify-content: space-between; }
.footer-name  { font-family: var(--font-header); font-size: 1.25rem; color: white; font-weight: 700; }
.footer-legal { font-size: 0.8rem; margin-top: 0.5rem; opacity: 0.7; }
.footer-links { display: flex; gap: 1.5rem; flex-wrap: wrap; align-items: flex-start; }
.footer-links a { color: rgba(255,255,255,0.75); text-decoration: none; font-size: 0.9rem; transition: color var(--transition-fast); }
.footer-links a:hover { color: var(--color-accent); }
.footer-bottom { max-width: var(--container-max); margin-inline: auto; padding-inline: clamp(1rem,5vw,2rem); padding-top: 2rem; margin-top: 2rem; border-top: 1px solid rgba(255,255,255,0.1); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 1rem; font-size: 0.8rem; opacity: 0.6; }
.footer-powered a { color: var(--color-accent); text-decoration: none; }

/* ── Accessibility ───────────────────────────────────────────────────────────── */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }
:focus-visible { outline: 3px solid var(--color-accent); outline-offset: 3px; }

/* ── Alert Banner ────────────────────────────────────────────────────────────── */
.alert-banner { background: var(--color-accent); color: var(--color-white); text-align: center; padding: 0.5rem 1rem; font-size: 0.9rem; font-weight: 600; }

/* ── Print ───────────────────────────────────────────────────────────────────── */
@media print {
  nav, footer, .no-print, #age-gate, .alert-banner, .mobile-action-bar { display: none !important; }
  body { background: white; color: black; }
  .section-gap { padding-block: 1rem; }
  .btn { display: none; }
}

/* ── Utilities ───────────────────────────────────────────────────────────────── */
.hidden   { display: none !important; }
.text-right  { text-align: right; }
.text-center { text-align: center; }

/* ── MXB Toggle ──────────────────────────────────────────────────────────────── */
.mxb-toggle-wrap { display: flex; align-items: center; }
.toggle-label    { display: flex; align-items: center; gap: 0.5rem; cursor: pointer; font-size: 0.9rem; font-weight: 500; }
.toggle-label input { display: none; }
.toggle-track {
  display: inline-block;
  width: 40px; height: 22px;
  background: var(--color-border);
  border-radius: 999px;
  position: relative;
  transition: background var(--transition-fast);
}
.toggle-track::after {
  content: "";
  position: absolute;
  left: 3px; top: 3px;
  width: 16px; height: 16px;
  background: white;
  border-radius: 50%;
  transition: transform var(--transition-fast);
}
.toggle-label input:checked + .toggle-track { background: var(--color-accent); }
.toggle-label input:checked + .toggle-track::after { transform: translateX(18px); }

/* ── Hero Overlay Styles (overlay_dark + overlay_brand) ──────────────────────
   Full-bleed image hero with text overlaid on a scrim.
   hero_style = "overlay_brand" → uses --color-primary as scrim (default)
   hero_style = "overlay_dark"  → uses dark gradient scrim (strong local photo)
   Both variants share .hero--overlay base rules.
   Split layout (legacy) uses existing .hero / .hero-grid rules above.
────────────────────────────────────────────────────────────────────────────── */

.hero--overlay {
  position: relative;
  width: 100%;
  min-height: 480px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
  color: var(--color-white);
}
@media (min-width: 768px) {
  .hero--overlay { min-height: 540px; }
}

/* Background image — fills the container, cropped to focal point */
.hero-bg-picture {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
}
.hero-bg-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  -o-object-fit: cover;
     object-fit: cover;
  -o-object-position: center bottom;
     object-position: center bottom;
  max-width: none; /* override global img rule */
}

/* Scrim — sits between image and content */
.hero-scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
}

/* overlay_brand: primary color bleeds up from bottom, nearly transparent at top */
.hero--overlay_brand .hero-scrim {
  background: linear-gradient(
    to top,
    color-mix(in srgb, var(--color-primary) 92%, transparent) 0%,
    color-mix(in srgb, var(--color-primary) 55%, transparent) 50%,
    color-mix(in srgb, var(--color-primary) 10%, transparent) 100%
  );
}

/* overlay_dark: neutral dark gradient — works with any photo */
.hero--overlay_dark .hero-scrim {
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.82) 0%,
    rgba(0, 0, 0, 0.45) 45%,
    rgba(0, 0, 0, 0.10) 100%
  );
}

/* Fallback for browsers without color-mix: solid primary at reduced opacity */
@supports not (background: color-mix(in srgb, red 50%, blue)) {
  .hero--overlay_brand .hero-scrim {
    background: linear-gradient(
      to top,
      rgba(0, 0, 0, 0.88) 0%,
      rgba(0, 0, 0, 0.50) 50%,
      rgba(0, 0, 0, 0.10) 100%
    );
  }
}

/* Content sits above scrim */
.hero-overlay-content {
  position: relative;
  z-index: 2;
  padding: clamp(2rem, 5vw, 4rem) clamp(1.25rem, 5vw, 4rem);
  max-width: 720px;
}

/* Eyebrow label above the h1 */
.hero-eyebrow {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: 0.75rem;
  opacity: 0.9;
}

/* h1 inherits .hero-title white color from existing rule */
.hero--overlay .hero-title {
  font-size: clamp(2rem, 6vw, 3.5rem);
  margin-bottom: 1rem;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
}

/* Description */
.hero--overlay .hero-desc {
  font-size: clamp(1rem, 2vw, 1.15rem);
  opacity: 0.88;
  margin-bottom: 2rem;
  max-width: 520px;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.3);
}

/* Overlay-specific button variants */
.btn--accent-solid {
  background: var(--color-accent);
  color: #111;
  border-color: var(--color-accent);
}
.btn--accent-solid:hover {
  background: var(--color-white);
  color: var(--color-primary);
  border-color: var(--color-white);
  transform: translateY(-1px);
}

.btn--overlay-outline {
  background: transparent;
  color: var(--color-white);
  border-color: rgba(255, 255, 255, 0.65);
}
.btn--overlay-outline:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: var(--color-white);
  color: var(--color-white);
  transform: translateY(-1px);
}

/* ── Content Page Shared Styles (about, faq, policies, employment) ────────────
   Shared header + prose + sidebar used across ABC content section layouts.
   Individual layout head-extra blocks add page-specific overrides only.
──────────────────────────────────────────────────────────────────────────── */

.content-page-header {
  padding-block: 2.5rem;
  background: var(--color-primary);
  color: var(--color-white);
}
.content-page-title {
  color: var(--color-white);
  margin-top: 0.5rem;
}
.content-page-desc {
  color: rgba(255, 255, 255, 0.82);
  max-width: 60ch;
  margin-top: 0.5rem;
  font-size: 1.05rem;
}
.breadcrumb--light a {
  color: rgba(255, 255, 255, 0.75);
  text-decoration: none;
}
.breadcrumb--light a:hover { color: var(--color-white); }
.breadcrumb--light span { color: rgba(255, 255, 255, 0.5); }

.content-page-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
  align-items: flex-start;
}
@media (min-width: 768px) {
  .content-page-grid { grid-template-columns: 1fr 260px; }
}

/* Prose body */
.prose h2 {
  color: var(--color-primary);
  margin-top: 2.5rem;
  margin-bottom: 0.75rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--color-border);
  font-size: 1.4rem;
}
.prose h3 {
  color: var(--color-primary);
  margin-top: 1.75rem;
  margin-bottom: 0.5rem;
  font-size: 1.1rem;
}
.prose p {
  color: var(--color-text);
  line-height: 1.8;
  margin-bottom: 1rem;
  font-size: 0.975rem;
}
.prose ul {
  padding-left: 1.5rem;
  margin-bottom: 1rem;
}
.prose li {
  margin-bottom: 0.5rem;
  color: var(--color-text);
  line-height: 1.7;
  font-size: 0.975rem;
}
.prose strong { color: var(--color-primary); font-weight: 700; }
.prose a { color: var(--color-accent); }

/* Sidebar */
.content-sidebar-card {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-ui);
  padding: 1.25rem;
  margin-bottom: 1rem;
}
.content-sidebar-card--primary {
  background: var(--color-primary);
  border-color: transparent;
  color: var(--color-white);
}
.content-sidebar-card--primary h3 { color: var(--color-white); }
.content-sidebar-card--primary p {
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.85rem;
  margin-bottom: 1rem;
}
.content-sidebar-card h3 {
  font-size: 0.95rem;
  color: var(--color-primary);
  margin-bottom: 0.5rem;
  font-weight: 700;
}
.content-sidebar-card p { font-size: 0.875rem; margin-bottom: 0.35rem; }
.content-sidebar-card a { color: var(--color-primary); text-decoration: none; font-size: 0.875rem; }
.sidebar-link {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-accent);
  text-decoration: none;
  padding: 0.2rem 0;
}

/* ── Narrow Page Header (secondary content pages) ────────────────────────────
   Used on about, faq, policies, employment, and any future content section.
   Two variants: --photo (image + scrim) and --pattern (CSS diagonal, no image).
   Height is intentionally narrow — decorative strip, not a hero.
────────────────────────────────────────────────────────────────────────────── */

.page-header {
  position: relative;
  width: 100%;
  min-height: 180px;
  height: 180px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
  color: var(--color-white);
}
@media (min-width: 768px) {
  .page-header { min-height: 220px; height: 220px; }
}

/* Photo variant — background image */
.page-header-bg {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
}
.page-header-bg-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  -o-object-fit: cover;
     object-fit: cover;
  -o-object-position: center center;
     object-position: center center;
  max-width: none;
}

/* Scrim — brand primary gradient for both variants */
.page-header-scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    to right,
    color-mix(in srgb, var(--color-primary) 88%, transparent) 0%,
    color-mix(in srgb, var(--color-primary) 60%, transparent) 50%,
    color-mix(in srgb, var(--color-primary) 25%, transparent) 100%
  );
}

/* Fallback for browsers without color-mix */
@supports not (background: color-mix(in srgb, red 50%, blue)) {
  .page-header-scrim {
    background: linear-gradient(
      to right,
      rgba(0, 0, 0, 0.82) 0%,
      rgba(0, 0, 0, 0.55) 50%,
      rgba(0, 0, 0, 0.20) 100%
    );
  }
}

/* Pattern variant — CSS diagonal stripe, no image needed */
.page-header--pattern {
  background-color: var(--color-primary);
}
.page-header--pattern::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(
    -45deg,
    transparent,
    transparent 8px,
    rgba(255, 255, 255, 0.04) 8px,
    rgba(255, 255, 255, 0.04) 16px
  );
  z-index: 1;
}
.page-header--pattern .page-header-scrim {
  display: none;
}

/* Content sits above scrim/pattern */
.page-header-content {
  position: relative;
  z-index: 2;
  padding-block: 1.75rem 1.5rem;
}

.page-header-title {
  color: var(--color-white);
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  margin-top: 0.5rem;
  margin-bottom: 0;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.3);
}

.page-header-desc {
  color: rgba(255, 255, 255, 0.85);
  font-size: 1rem;
  margin-top: 0.4rem;
  margin-bottom: 0;
  max-width: 55ch;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
}
