/* ============================================
   Dorma Health; design tokens + base styles
   Navy-forward; white primary, cream as subtle accent,
   warm orange highlight, refined editorial serif.
   ============================================ */

:root {
  /* Brand */
  --ink:        #0F1E3D;        /* deep navy; primary brand */
  --ink-2:      #1B2A4E;
  --ink-soft:   #2B3A66;
  --paper:      #FFFFFF;        /* primary page surface */
  --paper-2:    #FBFAF7;        /* off-white lifted surface */
  --cream:      #F5EFE4;        /* warm accent (used sparingly) */
  --cream-2:    #F8F5EE;        /* very subtle warm tint */
  --cream-3:    #EFE7D5;
  --sage:       #6B8E76;        /* sage badge / calm accent */
  --sage-soft:  #E2EBE3;
  --sand:       #D9C3A3;
  --sand-soft:  #F4EEE1;
  --orange:     #F08A4B;        /* warm highlight (asterisks, hover) */
  --orange-soft:#FBE7D6;
  --rule:       #E5E3DD;        /* hairline border, near-white */
  --rule-2:     #D6D3CB;

  /* Text */
  --text:       #16213D;
  --text-muted: #5C6478;
  --text-on-ink:#F5EFE4;

  /* Type scale */
  --font-serif: 'Newsreader', 'Source Serif 4', 'Source Serif Pro', Georgia, 'Times New Roman', serif;
  --font-sans:  'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;

  /* Spacing */
  --container: 1200px;
  --pad-x: clamp(20px, 4vw, 48px);

  /* Radii */
  --r-sm: 8px;
  --r-md: 14px;
  --r-lg: 22px;
  --r-pill: 999px;

  /* Shadows */
  --shadow-1: 0 1px 2px rgba(15,30,61,.06), 0 6px 18px rgba(15,30,61,.06);
  --shadow-2: 0 2px 4px rgba(15,30,61,.08), 0 18px 40px rgba(15,30,61,.10);

  /* Transitions */
  --t-fast: 140ms cubic-bezier(.2,.6,.2,1);
  --t-base: 220ms cubic-bezier(.2,.6,.2,1);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; }
button { font: inherit; cursor: pointer; }

/* Typography */
h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 500;
  color: var(--ink);
  letter-spacing: -0.01em;
  margin: 0 0 .4em;
  font-variation-settings: "opsz" 36;
}
h1 {
  font-size: clamp(38px, 5.6vw, 64px);
  line-height: 1.08;
  letter-spacing: -0.015em;
  font-variation-settings: "opsz" 72;
  font-weight: 500;
}
h2 {
  font-size: clamp(28px, 3.8vw, 44px);
  line-height: 1.12;
  font-variation-settings: "opsz" 60;
}
h3 { font-size: clamp(22px, 2.4vw, 28px); line-height: 1.25; font-variation-settings: "opsz" 24; }
h4 { font-size: 19px; line-height: 1.3; font-variation-settings: "opsz" 18; }
p  { margin: 0 0 1em; color: var(--text); }
.lede { font-size: clamp(18px, 1.6vw, 21px); color: var(--ink-soft); }

.eyebrow {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2.2px;
  text-transform: uppercase;
  color: #436C53;
  padding: 6px 10px;
  background: var(--sage-soft);
  border-radius: var(--r-pill);
  margin-bottom: 18px;
}
.eyebrow.sand { color: #8A5A2B; background: var(--orange-soft); }

/* Layout */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding-left: var(--pad-x);
  padding-right: var(--pad-x);
}
.section { padding: clamp(64px, 9vw, 128px) 0; }
.section-tight { padding: clamp(40px, 6vw, 80px) 0; }
.section.cream-2 { background: var(--paper-2); }
.section.ink { background: var(--ink); color: var(--text-on-ink); }
.section.ink h1, .section.ink h2, .section.ink h3 { color: var(--cream); }
.section.ink p { color: rgba(245,239,228,.82); }
.section.sand { background: var(--cream-2); }

.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0,1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0,1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0,1fr)); }
@media (max-width: 880px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px 28px;
  border-radius: var(--r-pill);
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 16px;
  letter-spacing: .01em;
  text-decoration: none !important;
  transition: transform var(--t-fast), background var(--t-base), color var(--t-base), border-color var(--t-base);
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary {
  background: var(--ink);
  color: var(--cream);
}
.btn-primary:hover { background: var(--ink-soft); }
.btn-secondary {
  background: var(--paper);
  color: var(--ink);
  border-color: var(--ink);
}
.btn-secondary:hover { background: var(--cream-2); }
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: transparent;
  padding-left: 0;
  padding-right: 0;
}
.btn-ghost:hover { text-decoration: underline; }
.btn-block { display: flex; width: 100%; }
.btn-lg { padding: 18px 34px; font-size: 17px; }

/* Navigation */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--rule);
}
.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  gap: 24px;
}
.nav-brand img { height: 32px; width: auto; display: block; }
.nav-links {
  display: flex;
  gap: 28px;
  align-items: center;
}
.nav-links a {
  font-size: 15px;
  color: var(--ink);
  font-weight: 500;
}
.nav-links a:hover { color: var(--ink-soft); text-decoration: none; opacity: .8; }
.nav-cta { display: flex; gap: 10px; align-items: center; }
.nav-cta .btn { padding: 11px 20px; font-size: 14px; }

.nav-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--rule-2);
  border-radius: var(--r-pill);
  padding: 8px 14px;
  color: var(--ink);
  font-weight: 600;
}

@media (max-width: 880px) {
  .nav-links { display: none; }
  .nav-cta .btn-secondary { display: none; }
  .nav-toggle { display: inline-flex; }
  .nav-links.open {
    display: flex;
    position: absolute;
    top: 72px; left: 0; right: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--rule);
    padding: 18px var(--pad-x) 24px;
    flex-direction: column;
    gap: 18px;
    align-items: flex-start;
  }
}

/* Hero */
.hero {
  padding-top: clamp(48px, 7vw, 96px);
  padding-bottom: clamp(48px, 7vw, 96px);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: clamp(28px, 4vw, 64px);
  align-items: center;
}
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; }
}
.hero h1 { margin-bottom: 18px; }
.hero .lede { margin-bottom: 28px; max-width: 560px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 22px; }
.hero-meta {
  display: flex; flex-wrap: wrap; gap: 18px 26px;
  font-size: 14px; color: var(--text-muted);
}
.hero-meta span { display: inline-flex; align-items: center; gap: 8px; }
.hero-meta .dot { width: 6px; height: 6px; border-radius: 999px; background: var(--sage); }

.hero-art {
  border-radius: 28px;
  overflow: hidden;
  background: linear-gradient(180deg, #FBFAF7 0%, #ECE4D4 100%);
  aspect-ratio: 1 / 1;
  position: relative;
  box-shadow: var(--shadow-2);
}
.hero-art img { width: 100%; height: 100%; object-fit: cover; }
.hero-badge {
  position: absolute; left: 18px; bottom: 18px;
  background: var(--paper);
  border-radius: var(--r-pill);
  padding: 10px 16px;
  font-size: 13px; font-weight: 600;
  color: var(--ink);
  box-shadow: var(--shadow-1);
  display: inline-flex; align-items: center; gap: 8px;
}
.hero-badge .pulse {
  width: 8px; height: 8px; border-radius: 999px;
  background: var(--sage);
  box-shadow: 0 0 0 0 rgba(107,142,118,.6);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(107,142,118,.55); }
  70%  { box-shadow: 0 0 0 10px rgba(107,142,118,0); }
  100% { box-shadow: 0 0 0 0 rgba(107,142,118,0); }
}

/* Trust strip */
.trust {
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  background: var(--paper-2);
  padding: 22px 0;
}
.trust-row {
  display: flex; flex-wrap: wrap; gap: 18px 36px;
  align-items: center; justify-content: space-between;
}
.trust-item {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 13px; font-weight: 600; letter-spacing: .04em;
  color: var(--ink-soft);
  text-transform: uppercase;
}
.trust-item svg { width: 18px; height: 18px; }
@media (max-width: 880px) {
  .trust-row { justify-content: center; }
}

/* Step cards (How it works) */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
@media (max-width: 880px) { .steps { grid-template-columns: 1fr; } }
.step {
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  padding: 28px 26px;
  position: relative;
  min-height: 100%;
}
.step .num {
  font-family: var(--font-serif);
  font-size: 28px;
  color: var(--ink);
  margin-bottom: 14px;
  display: inline-flex;
  width: 44px; height: 44px;
  align-items: center; justify-content: center;
  background: var(--sage-soft);
  border-radius: 999px;
}
.step h3 { margin-bottom: 10px; }
.step p { color: var(--text-muted); margin: 0; }

/* Feature cards (Why Dorma) */
.feat-card {
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  padding: 28px 26px;
}
.feat-card h3 { font-size: 22px; }
.feat-card p { color: var(--text-muted); margin: 0; }
.feat-card .icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  background: var(--orange-soft);
  display: inline-flex;
  align-items: center; justify-content: center;
  margin-bottom: 14px;
}
.feat-card .icon svg { width: 22px; height: 22px; stroke: #B25E2A; }

/* Product detail */
.product {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(28px, 5vw, 64px);
  align-items: center;
}
@media (max-width: 980px) { .product { grid-template-columns: 1fr; } }
.product-gallery {
  background: linear-gradient(180deg, #FBFAF7 0%, #E6DCC4 100%);
  border-radius: 28px;
  padding: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1 / 1;
}
.product-list {
  list-style: none;
  padding: 0; margin: 22px 0;
}
.product-list li {
  display: flex; gap: 12px;
  padding: 12px 0;
  border-top: 1px solid var(--rule);
  font-size: 16px;
  color: var(--text);
}
.product-list li:last-child { border-bottom: 1px solid var(--rule); }
.product-list li .check {
  flex: 0 0 22px;
  width: 22px; height: 22px;
  border-radius: 999px;
  background: var(--sage);
  color: white;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 13px;
}

/* Pricing card */
.price-card {
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  padding: 32px;
  box-shadow: var(--shadow-1);
}
.price-card .price {
  font-family: var(--font-serif);
  font-size: 64px;
  line-height: 1;
  color: var(--ink);
  letter-spacing: -1px;
}
.price-card .price small {
  font-family: var(--font-sans);
  font-size: 14px;
  color: var(--text-muted);
  font-weight: 500;
  margin-left: 6px;
}
.price-card .included {
  list-style: none; padding: 0; margin: 18px 0 24px;
}
.price-card .included li {
  padding: 8px 0;
  display: flex; gap: 10px; align-items: flex-start;
  font-size: 15px; color: var(--text);
}
.price-card .included li::before {
  content: "✓";
  color: var(--sage);
  font-weight: 700;
}

/* Comparison table (How it compares) */
.compare-wrap {
  overflow-x: auto;
  border-radius: var(--r-lg);
  border: 1px solid var(--rule);
  background: var(--paper);
  box-shadow: var(--shadow-1);
  -webkit-overflow-scrolling: touch;
}
.compare {
  width: 100%;
  min-width: 720px;
  border-collapse: separate;
  border-spacing: 0;
  font-family: var(--font-sans);
  font-size: 15px;
  background: var(--paper);
}
.compare th, .compare td {
  padding: 18px 14px;
  text-align: center;
  vertical-align: middle;
  border-bottom: 1px solid var(--rule);
  color: var(--text);
}
.compare thead th {
  font-weight: 600;
  color: var(--text-muted);
  font-size: 12px;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  padding: 18px 12px;
  background: var(--paper-2);
}
.compare thead th.hero {
  background: var(--ink);
  color: var(--cream);
  font-size: 16px;
  letter-spacing: .02em;
  text-transform: none;
  font-family: var(--font-serif);
  font-weight: 500;
  padding: 22px 14px;
  border-top-left-radius: var(--r-md);
  border-top-right-radius: var(--r-md);
}
.compare th[scope="row"] {
  text-align: left;
  font-weight: 500;
  color: var(--ink);
  background: var(--paper);
  min-width: 200px;
  font-size: 15px;
  letter-spacing: 0;
  text-transform: none;
}
.compare tbody tr:last-child th[scope="row"],
.compare tbody tr:last-child td { border-bottom: 0; }
.compare td.hero {
  background: var(--ink);
  color: var(--cream);
  font-weight: 600;
}
.compare td.hero strong {
  color: var(--cream);
  font-family: var(--font-serif);
  font-size: 26px;
  font-weight: 500;
}
.compare tbody tr:last-child td.hero {
  border-bottom-left-radius: var(--r-md);
  border-bottom-right-radius: var(--r-md);
}
.compare .tick,
.compare .cross {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px; height: 32px;
  border-radius: 999px;
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
}
.compare .tick {
  background: var(--paper);
  color: var(--ink);
}
.compare .cross {
  background: var(--cream-2);
  color: var(--text-muted);
  font-weight: 500;
}
@media (max-width: 720px) {
  .compare-wrap {
    /* Hint that the table scrolls on mobile */
    background: linear-gradient(to right, var(--paper) 30%, rgba(255,255,255,0)), linear-gradient(to right, rgba(255,255,255,0), var(--paper) 70%) 100% 0;
    background-repeat: no-repeat;
    background-size: 40px 100%, 40px 100%;
    background-attachment: local, local;
  }
}

/* Reviews */
.review-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
@media (max-width: 980px) { .review-grid { grid-template-columns: 1fr; } }
.review {
  background: var(--paper-2);
  border-radius: var(--r-lg);
  padding: 26px;
  border: 1px solid var(--rule);
}
.review .stars {
  color: #D9A21C;
  letter-spacing: 1px;
  margin-bottom: 10px;
}
.review blockquote {
  margin: 0 0 14px;
  font-family: var(--font-serif);
  font-size: 20px;
  line-height: 1.35;
  color: var(--ink);
}
.review cite {
  font-style: normal;
  font-size: 14px;
  color: var(--text-muted);
}

/* FAQ accordion */
.faq-list { border-top: 1px solid var(--rule); }
.faq-item {
  border-bottom: 1px solid var(--rule);
}
.faq-q {
  width: 100%;
  background: transparent;
  border: 0;
  padding: 22px 0;
  text-align: left;
  display: flex; justify-content: space-between; align-items: center;
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 500;
  color: var(--ink);
  cursor: pointer;
}
.faq-q .chev {
  width: 28px; height: 28px;
  border-radius: 999px;
  background: var(--paper-2);
  border: 1px solid var(--rule);
  display: inline-flex; align-items: center; justify-content: center;
  transition: transform var(--t-base);
}
.faq-item.open .faq-q .chev { transform: rotate(45deg); }
.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--t-base);
  color: var(--text-muted);
}
.faq-item.open .faq-a { max-height: 600px; }
.faq-a .inner { padding: 0 0 22px; max-width: 760px; }

/* CTA band */
.cta-band {
  background: var(--ink);
  color: var(--cream);
  border-radius: 28px;
  padding: clamp(36px, 5vw, 64px);
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 32px;
  align-items: center;
}
@media (max-width: 880px) { .cta-band { grid-template-columns: 1fr; } }
.cta-band h2 { color: var(--cream); }
.cta-band p { color: rgba(245,239,228,.78); margin: 0; }
.cta-band .btn-primary { background: var(--cream); color: var(--ink); }
.cta-band .btn-primary:hover { background: var(--paper); }

/* Footer */
.footer {
  background: var(--ink);
  color: var(--cream);
  padding: 72px 0 28px;
  margin-top: 0;
}
.footer a { color: var(--cream); opacity: .8; }
.footer a:hover { opacity: 1; text-decoration: underline; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 32px;
  margin-bottom: 48px;
}
@media (max-width: 880px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; } }
.footer h4 {
  color: var(--cream);
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 16px;
  opacity: .7;
}
.footer ul { list-style: none; padding: 0; margin: 0; }
.footer li { padding: 6px 0; font-size: 15px; }
.footer-brand img { height: 32px; }
.footer-brand p {
  color: rgba(245,239,228,.7);
  font-size: 14px;
  max-width: 320px;
  margin-top: 16px;
}
.footer-fine {
  border-top: 1px solid rgba(245,239,228,.12);
  padding-top: 22px;
  display: flex; flex-wrap: wrap; gap: 18px; justify-content: space-between;
  color: rgba(245,239,228,.6);
  font-size: 12px;
}
.footer-fine p { margin: 0; color: rgba(245,239,228,.6); }

/* Misc */
.kicker { color: var(--sage); font-weight: 600; }
.center { text-align: center; }
.max-680 { max-width: 680px; margin-left: auto; margin-right: auto; }
.max-880 { max-width: 880px; margin-left: auto; margin-right: auto; }

/* Page header (sub-pages) */
.page-header {
  padding: clamp(80px, 10vw, 140px) 0 clamp(48px, 6vw, 80px);
  text-align: center;
}
.page-header .lede { max-width: 720px; margin: 0 auto; }

/* Prose (legal pages) */
.prose {
  max-width: 760px;
  margin: 0 auto;
  font-size: 17px;
  line-height: 1.7;
}
.prose h2 { font-size: 26px; margin-top: 32px; }
.prose h3 { font-size: 20px; margin-top: 24px; }
.prose p, .prose li { color: var(--text); }
.prose ul { padding-left: 22px; }

/* Form */
.form { display: grid; gap: 16px; }
.field label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-soft);
  margin-bottom: 6px;
  letter-spacing: .02em;
}
.field input, .field select, .field textarea {
  width: 100%;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid var(--rule-2);
  background: var(--paper);
  font-size: 16px;
  color: var(--ink);
  font-family: inherit;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none;
  border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(15,30,61,.10);
}

/* Cart summary */
.summary {
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  padding: 24px;
}
.summary .row { display: flex; justify-content: space-between; padding: 8px 0; font-size: 15px; }
.summary .row.total { border-top: 1px solid var(--rule); padding-top: 14px; margin-top: 8px; font-weight: 600; font-size: 18px; color: var(--ink); }
.summary .pill {
  display: inline-block;
  font-size: 12px; font-weight: 600;
  color: var(--sage);
  background: var(--sage-soft);
  padding: 3px 10px;
  border-radius: 999px;
  margin-left: 6px;
}

/* Fine print */
.fine {
  font-size: 12px;
  color: var(--text-muted);
  max-width: 900px;
  margin: 24px auto 0;
  text-align: center;
  line-height: 1.55;
}

/* Utility: hide on small */
@media (max-width: 720px) { .hide-sm { display: none; } }
