/* ============================================================
   CLUE MICROSITE STYLES — Dental Implants (Modern Essence)

   Loaded only by the dental implant microsite pages and the three
   missing-teeth pages that carry its subnav. Builds on client.css:
   the pages wrap their content in <div class="me-lux"> and reuse the
   site's elevated components (.me-split-hero, .me-glance, .me-journey,
   .hub-card, .me-eyebrow). Only the microsite-specific pieces live
   here: the subnav, the offer panel, the doctor intro, CTA bands, the
   disclaimer line, the process steps, quote cards and the candidacy
   check.

   Brand tokens (client.css):
     --primary-color    #04518e  logo blue
     --secondary-color  #28336f  logo indigo
     --accent-color     #87cff3  logo sky
   ============================================================ */

:root {
  --ms-blue: var(--primary-color, #04518e);
  --ms-indigo: var(--secondary-color, #28336f);
  --ms-sky: var(--accent-color, #87cff3);
  --ms-sky-soft: #e9f3fb;
  --ms-line: #dbe6f2;
  --ms-text-muted: #51607a;
}

/* Focus ring stays visible on the blue and indigo bands (the global ring
   is the brand blue, which disappears on a blue background). */
.treatment-band-dark :focus-visible,
.microsite-subnav :focus-visible,
.ms-cta-band :focus-visible,
.me-split-hero__text :focus-visible {
  outline-color: #fff;
}
/* ...but controls inside a white card on a dark band keep the blue ring. */
.treatment-band-dark .ms-tech-card :focus-visible,
.treatment-band-dark .ms-offer :focus-visible,
.treatment-band-dark .ms-doctor :focus-visible,
.treatment-band-dark .ms-quote :focus-visible,
.treatment-band-dark .quiz-card :focus-visible {
  outline-color: var(--ms-blue);
}

/* ---------- Microsite sub-navigation ---------- */
.microsite-subnav {
  background: var(--ms-indigo);
  padding: 0.55rem 0;
}
.microsite-subnav__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.35rem 0.4rem;
}
.microsite-subnav .subnav-link {
  display: inline-block;
  color: rgba(255, 255, 255, 0.88);
  text-decoration: none;
  padding: 0.42rem 1rem;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 600;
  white-space: nowrap;
  transition: background-color 0.2s ease, color 0.2s ease;
}
.microsite-subnav .subnav-link:hover {
  color: #fff;
  background-color: rgba(255, 255, 255, 0.14);
}
.microsite-subnav .subnav-link.active {
  color: var(--ms-indigo);
  background-color: var(--ms-sky);
}
/* Phones: the links wrap onto extra rows (no sideways scroll), so the
   current page is always in view. */
@media (max-width: 767.98px) {
  .microsite-subnav { padding: 0.5rem 0; }
  .microsite-subnav__list { gap: 0.3rem 0.25rem; }
  .microsite-subnav .subnav-link { font-size: 0.8rem; padding: 0.36rem 0.7rem; }
}

/* ---------- Hero tweaks on microsite pages ---------- */
.me-lux .me-split-hero__media img { object-position: center 30%; }
.ms-hero-note {
  margin: 1.1rem 0 0;
  font-size: 0.92rem;
  color: rgba(255, 255, 255, 0.85);
}
.ms-hero-note a { color: #fff; }

/* ---------- Section heads ---------- */
/* An eyebrow sits directly on its heading (clue.css gives h2 a top margin). */
.me-lux .me-eyebrow + h2,
.me-lux #content .me-eyebrow + h2,
.me-lux #content .ms-offer h2,
.me-lux #content .quiz-progress + h2 { margin-top: 0; }
.ms-head { max-width: 44rem; margin: 0 auto 2rem; text-align: center; }
.ms-head h2 { color: var(--ms-indigo); margin-bottom: 0.6rem; }
.ms-head p { color: var(--ms-text-muted); margin: 0; }
.treatment-band-dark .ms-head h2 { color: #fff; }
.treatment-band-dark .ms-head p { color: rgba(255, 255, 255, 0.9); }

/* ---------- Offer panel ---------- */
.ms-offer {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 1.25rem 2rem;
  align-items: center;
  background: #fff;
  border: 1px solid var(--ms-line);
  border-top: 5px solid var(--ms-blue);
  border-radius: 16px;
  box-shadow: 0 8px 26px rgba(40, 51, 111, 0.08);
  padding: 1.75rem 2rem;
}
.ms-offer__icon {
  width: 4rem;
  height: 4rem;
  border-radius: 50%;
  background: var(--ms-sky-soft);
  color: var(--ms-blue);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.9rem;
}
.ms-offer__label {
  display: inline-block;
  background: var(--ms-blue);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 0.28rem 0.8rem;
  border-radius: 999px;
  margin-bottom: 0.6rem;
}
.ms-offer h2 {
  margin-top: 0;
  font-size: 1.45rem;
  color: var(--ms-indigo);
  margin-bottom: 0.45rem;
}
.ms-offer p { margin-bottom: 0.35rem; color: #33405a; }
.ms-offer p.ms-offer__terms { font-size: 0.9rem; color: var(--ms-text-muted); margin-bottom: 0; }
.ms-offer__actions { display: flex; flex-direction: column; gap: 0.5rem; align-items: stretch; }
.ms-offer__actions .btn { white-space: nowrap; }
.ms-offer__more { font-size: 0.88rem; text-align: center; }
@media (max-width: 991.98px) {
  .ms-offer { grid-template-columns: auto 1fr; }
  .ms-offer__actions { grid-column: 1 / -1; flex-direction: row; flex-wrap: wrap; align-items: center; }
}
@media (max-width: 575.98px) {
  .ms-offer { grid-template-columns: 1fr; padding: 1.5rem 1.25rem; }
  .ms-offer__icon { width: 3.2rem; height: 3.2rem; font-size: 1.5rem; }
  .ms-offer__actions .btn { white-space: normal; }
}

/* ---------- Option cards (hub) ---------- */
/* clue.css underlines every link in a dark band; a whole-card link keeps
   its own text styles. */
.treatment-band-dark a.hub-card { text-decoration: none; }
.ms-option {
  display: flex;
  flex-direction: column;
  height: 100%;
}
.ms-option .ms-option__img {
  width: calc(100% + 3rem);
  margin: -1.5rem -1.5rem 1.1rem;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  display: block;
  background: #f3f6fa;
}
.ms-option__go {
  margin-top: auto;
  padding-top: 0.75rem;
  font-weight: 700;
  color: var(--ms-blue);
  font-size: 0.92rem;
}
.ms-option--quiz {
  background: linear-gradient(135deg, var(--ms-indigo) 0%, var(--ms-blue) 100%);
  border-color: transparent;
  color: #fff;
}
.ms-option--quiz h3,
.treatment-band-dark .ms-option--quiz h3,
.ms-option--quiz .ms-option__go { color: #fff; }
.ms-option--quiz p { color: rgba(255, 255, 255, 0.9); }
.ms-option--quiz .hub-card__icon { color: var(--ms-sky); }
.ms-option--quiz:hover,
.ms-option--quiz:focus-visible { color: #fff; }

/* ---------- Feature image (consistent framing) ---------- */
.ms-feature-img {
  width: 100%;
  max-width: 640px;
  height: auto;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: 16px;
  box-shadow: 0 12px 34px rgba(40, 51, 111, 0.14);
  display: block;
  margin: 0 auto;
}

/* ---------- Check list ---------- */
.ms-check-list { list-style: none; padding-left: 0; margin: 0 0 1rem; }
.ms-check-list li {
  display: flex;
  gap: 0.65rem;
  align-items: flex-start;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}
.ms-check-list li:last-child { border-bottom: 0; }
.ms-check-list .bi { color: var(--ms-blue); font-size: 1.05rem; flex-shrink: 0; margin-top: 0.15rem; }
.treatment-band-dark .ms-check-list li { border-bottom-color: rgba(255, 255, 255, 0.14); }
.treatment-band-dark .ms-check-list .bi { color: var(--ms-sky); }

/* ---------- Doctor intro ---------- */
.ms-doctor {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 2rem;
  align-items: center;
  background: #fff;
  border: 1px solid var(--ms-line);
  border-radius: 18px;
  padding: 2rem;
  box-shadow: 0 8px 26px rgba(40, 51, 111, 0.06);
}
.ms-doctor img {
  width: 180px;
  height: 220px;
  object-fit: cover;
  object-position: center top;
  border-radius: 14px;
  display: block;
}
.ms-doctor h2 { color: var(--ms-indigo); margin-bottom: 0.25rem; }
.ms-doctor__creds {
  font-size: 0.9rem;
  color: var(--ms-text-muted);
  margin-bottom: 0.9rem;
}
.ms-doctor p { color: #33405a; }
.ms-doctor__actions { display: flex; flex-wrap: wrap; gap: 0.5rem; }
@media (max-width: 767.98px) {
  .ms-doctor { grid-template-columns: 1fr; text-align: center; padding: 1.5rem 1.25rem; gap: 1.25rem; }
  .ms-doctor img { margin: 0 auto; width: 160px; height: 196px; }
  .ms-doctor__actions { justify-content: center; }
}

/* ---------- Technology cards ---------- */
.ms-tech-card {
  height: 100%;
  background: #fff;
  border: 1px solid var(--ms-line);
  border-radius: 14px;
  padding: 1.5rem;
}
.ms-tech-card .bi { font-size: 1.8rem; color: var(--ms-blue); display: block; margin-bottom: 0.6rem; }
.ms-tech-card h3 { font-size: 1.12rem; color: var(--ms-indigo); margin-bottom: 0.4rem; }
.ms-tech-card p { color: var(--ms-text-muted); margin-bottom: 0; font-size: 0.95rem; }
.treatment-band-dark .ms-tech-card h3 { color: var(--ms-indigo); }
.treatment-band-dark .ms-tech-card p { color: var(--ms-text-muted); }
.treatment-band-dark .ms-tech-card a:not(.btn) { color: var(--ms-blue); text-decoration-color: currentColor; }
.treatment-band-dark .ms-tech-card a:not(.btn):hover { color: var(--ms-indigo); }

/* ---------- Detailed process steps (how it works) ---------- */
.ms-steps { list-style: none; padding: 0; margin: 0; counter-reset: ms-step; }
.ms-steps > li {
  counter-increment: ms-step;
  position: relative;
  padding: 0 0 1.75rem 4rem;
}
.ms-steps > li::before {
  content: counter(ms-step);
  position: absolute;
  left: 0;
  top: 0;
  width: 2.8rem;
  height: 2.8rem;
  border-radius: 50%;
  background: var(--ms-blue);
  color: #fff;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
.ms-steps > li::after {
  content: "";
  position: absolute;
  left: 1.38rem;
  top: 3rem;
  bottom: 0.25rem;
  width: 2px;
  background: linear-gradient(180deg, var(--ms-sky), rgba(4, 81, 142, 0.25));
}
.ms-steps > li:last-child { padding-bottom: 0; }
.ms-steps > li:last-child::after { display: none; }
.ms-steps h3 { font-size: 1.2rem; color: var(--ms-indigo); margin-bottom: 0.35rem; padding-top: 0.45rem; }
.ms-steps p { color: #33405a; margin-bottom: 0; }

/* ---------- Quote cards ---------- */
.ms-quote {
  height: 100%;
  margin: 0;
  background: #fff;
  border: 1px solid var(--ms-line);
  border-left: 4px solid var(--ms-sky);
  border-radius: 12px;
  padding: 1.5rem;
}
.ms-quote blockquote { margin: 0 0 0.75rem; font-style: italic; color: #33405a; }
.ms-quote figcaption { font-weight: 700; color: var(--ms-indigo); }

/* ---------- CTA band ---------- */
.ms-cta-band {
  background: linear-gradient(135deg, var(--ms-indigo) 0%, var(--ms-blue) 100%);
  color: #fff;
  border-radius: 1rem;
  margin: 3rem 0.75rem;
  padding: 3rem 1.25rem;
  text-align: center;
}
@media (min-width: 768px) {
  .ms-cta-band { margin: 3rem 2rem; padding: 3.5rem 2rem; }
}
.ms-cta-band h2 { color: #fff; margin-bottom: 0.65rem; }
.ms-cta-band p { color: rgba(255, 255, 255, 0.92); max-width: 40rem; margin: 0 auto 1.5rem; }
.ms-cta-band__actions { display: flex; flex-wrap: wrap; gap: 0.65rem; justify-content: center; }
.ms-cta-band .btn { border-radius: 999px; font-weight: 600; padding: 0.72rem 1.65rem; }
.ms-btn-sky {
  background: var(--ms-sky);
  border: 1.5px solid var(--ms-sky);
  color: var(--ms-indigo);
}
.ms-btn-sky:hover,
.ms-btn-sky:focus-visible { background: #a9dcf7; border-color: #a9dcf7; color: var(--ms-indigo); }
.ms-btn-ghost {
  background: transparent;
  border: 1.5px solid rgba(255, 255, 255, 0.7);
  color: #fff;
}
.ms-btn-ghost:hover,
.ms-btn-ghost:focus-visible { background: rgba(255, 255, 255, 0.15); border-color: #fff; color: #fff; }

/* ---------- Specialty disclaimer ---------- */
.ms-disclaimer {
  max-width: 50rem;
  margin: 0 auto 2.5rem;
  padding: 0 1rem;
  text-align: center;
  font-size: 0.84rem;
  color: #5b6b82;
}

/* ============================================================
   CANDIDACY CHECK (quiz)
   Answers are <button aria-pressed> inside role="group". Step and
   result headings take focus from script only, so they get no ring.
   ============================================================ */
.quiz-container { max-width: 720px; margin: 0 auto; }
.quiz-card {
  background: #fff;
  border: 1px solid var(--ms-line);
  border-radius: 18px;
  box-shadow: 0 10px 30px rgba(40, 51, 111, 0.08);
  padding: 2rem;
}
@media (max-width: 575.98px) { .quiz-card { padding: 1.5rem 1rem; } }
.quiz-progress {
  display: block;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ms-blue);
  margin-bottom: 0.5rem;
}
.quiz-step h2,
.quiz-result h2 { color: var(--ms-indigo); }
.quiz-step h2 { font-size: 1.55rem; margin-bottom: 0.4rem; }
.quiz-step .quiz-hint { color: var(--ms-text-muted); margin-bottom: 1.25rem; }
.quiz-step h2[tabindex="-1"]:focus,
.quiz-result h2[tabindex="-1"]:focus { outline: none; }

.quiz-options { display: grid; gap: 0.6rem; }
.quiz-options--two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 575.98px) { .quiz-options--two { grid-template-columns: 1fr; } }

.quiz-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem;
  width: 100%;
  text-align: left;
  font: inherit;
  color: var(--text-primary, #212529);
  background: #fff;
  border: 2px solid var(--ms-line);
  border-radius: 12px;
  padding: 0.9rem 1rem;
  cursor: pointer;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}
.quiz-option:hover { border-color: var(--ms-blue); }
.quiz-option:focus-visible { outline: 3px solid var(--ms-blue); outline-offset: 2px; }
.quiz-option[aria-pressed="true"] {
  border-color: var(--ms-blue);
  background: var(--ms-sky-soft);
}
.quiz-option__text { display: flex; flex-direction: column; }
.quiz-option__text strong { font-weight: 700; color: var(--ms-indigo); }
.quiz-option__text small { color: var(--ms-text-muted); font-size: 0.86rem; margin-top: 0.1rem; }
.quiz-toggle {
  flex: 0 0 auto;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid #6b7a90; /* 4.3:1 on white */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1rem;
}
.quiz-toggle .bi { visibility: hidden; }
.quiz-option[aria-pressed="true"] .quiz-toggle {
  border-color: var(--ms-blue);
  background: var(--ms-blue);
}
.quiz-option[aria-pressed="true"] .quiz-toggle .bi { visibility: visible; }

.quiz-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  margin-top: 1.5rem;
}
.quiz-nav .btn { border-radius: 999px; font-weight: 600; }
.quiz-nav .quiz-next { margin-left: auto; }
.quiz-nav-note { font-size: 0.86rem; color: var(--ms-text-muted); margin: 0.75rem 0 0; text-align: right; }

.quiz-result { display: none; }
.quiz-result.show { display: block; }
.quiz-result__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3.4rem;
  height: 3.4rem;
  border-radius: 50%;
  background: var(--ms-sky-soft);
  color: var(--ms-blue);
  font-size: 1.6rem;
  margin-bottom: 0.85rem;
}
.quiz-result h2 { font-size: 1.55rem; margin-top: 0; margin-bottom: 0.6rem; }
.me-lux #content .quiz-result h2 { margin-top: 0; }
.quiz-result p { color: #33405a; }
.quiz-notes { list-style: none; padding: 0; margin: 0 0 1rem; }
.quiz-notes li {
  display: flex;
  gap: 0.6rem;
  padding: 0.45rem 0;
  color: #33405a;
}
.quiz-notes li[hidden] { display: none; }
.quiz-notes .bi { color: var(--ms-blue); flex-shrink: 0; margin-top: 0.15rem; }
.quiz-flags {
  background: #f6f8fb;
  border-left: 4px solid var(--ms-sky);
  border-radius: 10px;
  padding: 1rem 1.15rem;
  margin: 0 0 1.25rem;
}
.quiz-flags[hidden] { display: none; }
.quiz-flags p { margin-bottom: 0.4rem; }
.quiz-flags ul { margin: 0; padding-left: 1.2rem; color: #33405a; }
.quiz-flags li[hidden] { display: none; }
.quiz-result__actions { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 1.25rem 0 0.75rem; }
.quiz-result__actions .btn { border-radius: 999px; font-weight: 600; }
.quiz-result__fineprint { font-size: 0.86rem; color: var(--ms-text-muted); margin-bottom: 0; }
.quiz-restart {
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  font-size: 0.92rem;
  color: var(--ms-blue);
  text-decoration: underline;
  cursor: pointer;
}

/* ---------- Tap size for primary actions (44px minimum) ---------- */
.ms-offer__actions .btn,
.quiz-result__actions .btn,
.quiz-nav .btn,
.ms-btn-tap {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}

/* ---------- Footer separation ---------- */
.me-lux > .treatment-band:last-child { margin-bottom: 3rem; }

/* ---------- Motion sensitivity ---------- */
@media (prefers-reduced-motion: reduce) {
  .microsite-subnav .subnav-link,
  .quiz-option { transition: none; }
}
