/* ============================================================
   Reyes Family Dentistry — main stylesheet
   Palette drawn from practice branding:
   navy #16335B · sky blue #2FA9E0 · gold #E8A33D · mint #EAF7F4
   ============================================================ */

:root {
  --navy: #16335b;
  --navy-dark: #0f2440;
  --blue: #2fa9e0;
  --blue-dark: #1d84b5;
  --gold: #e8a33d;
  --gold-dark: #c9871f;
  --mint: #eaf7f4;
  --mint-deep: #d7efe9;
  --ink: #2a3542;
  --muted: #5c6b7a;
  --line: #e3e9ef;
  --white: #ffffff;
  --radius: 14px;
  --shadow: 0 10px 30px rgba(22, 51, 91, 0.10);
  --shadow-sm: 0 4px 14px rgba(22, 51, 91, 0.08);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: "Nunito Sans", "Segoe UI", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--white);
}

img { max-width: 100%; display: block; }

h1, h2, h3, h4 {
  font-family: "Poppins", "Segoe UI", Arial, sans-serif;
  color: var(--navy);
  line-height: 1.25;
}

h1 { font-size: clamp(2rem, 4.5vw, 3.1rem); font-weight: 700; }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 700; }
h3 { font-size: 1.25rem; font-weight: 600; }

p { margin-bottom: 1rem; }

a { color: var(--blue-dark); text-decoration: none; }
a:hover { text-decoration: underline; }

.container {
  width: min(1140px, 92%);
  margin: 0 auto;
}

section { padding: 72px 0; }

.section-kicker {
  display: inline-block;
  font-family: "Poppins", sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--blue-dark);
  background: var(--mint);
  border-radius: 999px;
  padding: 6px 16px;
  margin-bottom: 14px;
}

.section-intro { max-width: 720px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  font-family: "Poppins", sans-serif;
  font-weight: 600;
  font-size: 1rem;
  padding: 14px 28px;
  border-radius: 999px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  text-decoration: none !important;
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-sm); }

.btn-gold { background: var(--gold); color: var(--navy-dark); }
.btn-gold:hover { background: #f0b054; }

.btn-navy { background: var(--navy); color: var(--white); }
.btn-navy:hover { background: var(--navy-dark); }

.btn-outline-light { border-color: rgba(255,255,255,0.85); color: var(--white); }
.btn-outline-light:hover { background: rgba(255,255,255,0.12); }

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

/* ---------- Top bar ---------- */
.topbar {
  background: var(--navy-dark);
  color: rgba(255,255,255,0.92);
  font-size: 0.9rem;
  padding: 8px 0;
}
.topbar .container {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.topbar a { color: var(--white); font-weight: 600; }
.topbar .hours { color: rgba(255,255,255,0.85); }

/* ---------- Header / nav ---------- */
header.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--white);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 2px 10px rgba(22,51,91,0.05);
}
.navwrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 12px 0;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none !important;
}
.brand img { height: 52px; width: auto; }
.brand .brand-text { line-height: 1.15; }
.brand .brand-name {
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--navy);
  display: block;
}
.brand .brand-sub {
  font-size: 0.78rem;
  color: var(--muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

nav.main-nav { display: flex; align-items: center; gap: 26px; }
nav.main-nav a {
  font-family: "Poppins", sans-serif;
  font-weight: 500;
  font-size: 0.98rem;
  color: var(--ink);
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
  text-decoration: none !important;
}
nav.main-nav a:hover { color: var(--blue-dark); }
nav.main-nav a.active {
  color: var(--navy);
  border-bottom-color: var(--gold);
  font-weight: 600;
}
nav.main-nav .btn { padding: 11px 22px; font-size: 0.92rem; }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.nav-toggle span {
  display: block;
  width: 26px;
  height: 3px;
  background: var(--navy);
  margin: 5px 0;
  border-radius: 2px;
  transition: 0.2s;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  color: var(--white);
  padding: 110px 0 120px;
  background:
    linear-gradient(100deg, rgba(15,36,64,0.88) 0%, rgba(22,51,91,0.72) 45%, rgba(22,51,91,0.35) 100%),
    var(--hero-img, url("../images/hero-operatory.webp")) center/cover no-repeat;
}
.hero h1 { color: var(--white); max-width: 640px; }
.hero p.lede {
  font-size: 1.18rem;
  max-width: 560px;
  color: rgba(255,255,255,0.92);
  margin: 18px 0 30px;
}
.hero .hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; }

.hero .offer-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: rgba(232,163,61,0.16);
  border: 1px solid rgba(232,163,61,0.65);
  color: #ffd899;
  border-radius: 999px;
  padding: 7px 18px;
  font-size: 0.92rem;
  font-weight: 600;
  margin-bottom: 22px;
}

.hero.hero-sub {
  padding: 72px 0 78px;
}
.hero.hero-sub p.lede { margin-bottom: 0; }

/* ---------- Offer banner ---------- */
.offer-banner {
  background: linear-gradient(115deg, var(--navy) 0%, var(--navy-dark) 100%);
  border-radius: var(--radius);
  color: var(--white);
  padding: 40px 44px;
  display: flex;
  align-items: center;
  gap: 36px;
  flex-wrap: wrap;
  box-shadow: var(--shadow);
}
.offer-banner .price {
  font-family: "Poppins", sans-serif;
  font-size: 3.2rem;
  font-weight: 700;
  color: var(--gold);
  line-height: 1;
  white-space: nowrap;
}
.offer-banner .price small {
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  color: rgba(255,255,255,0.75);
  margin-top: 6px;
}
.offer-banner .offer-body { flex: 1; min-width: 260px; }
.offer-banner h3 { color: var(--white); margin-bottom: 6px; font-size: 1.35rem; }
.offer-banner ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 6px 22px;
  margin: 10px 0 0;
  padding: 0;
  color: rgba(255,255,255,0.9);
}
.offer-banner ul li::before { content: "✓ "; color: var(--gold); font-weight: 700; }
.offer-banner .fine {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.6);
  margin-top: 10px;
  margin-bottom: 0;
}

/* ---------- Cards ---------- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 26px;
  margin-top: 40px;
}
.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
}
.card img { height: 210px; object-fit: cover; width: 100%; }
.card .card-body { padding: 26px 26px 30px; flex: 1; }
.card h3 { margin-bottom: 10px; }
.card ul { margin: 0 0 6px 18px; color: var(--muted); }
.card ul li { margin-bottom: 6px; }

/* ---------- Split sections ---------- */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}
.split .split-img img {
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  width: 100%;
  height: 100%;
  max-height: 560px;
  object-fit: cover;
}
.quote {
  border-left: 4px solid var(--gold);
  background: var(--mint);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 18px 22px;
  font-style: italic;
  color: var(--navy);
  font-size: 1.06rem;
  margin: 22px 0;
}

/* ---------- Feature strip ---------- */
.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 22px;
  margin-top: 40px;
}
.feature {
  background: var(--mint);
  border-radius: var(--radius);
  padding: 26px 24px;
}
.feature .icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 14px;
  box-shadow: var(--shadow-sm);
}
.feature h3 { font-size: 1.05rem; margin-bottom: 6px; }
.feature p { color: var(--muted); font-size: 0.95rem; margin: 0; }

/* ---------- Team ---------- */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 28px;
  margin-top: 40px;
}
.team-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  text-align: center;
}
.team-card img {
  width: 100%;
  height: 340px;
  object-fit: cover;
  object-position: center 20%;
}
.team-card .team-body { padding: 20px 18px 24px; }
.team-card h3 { margin-bottom: 2px; }
.team-card .role {
  color: var(--blue-dark);
  font-weight: 600;
  font-size: 0.92rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* ---------- Service detail blocks ---------- */
.service-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
  padding: 44px 0;
  border-bottom: 1px solid var(--line);
}
.service-block:last-of-type { border-bottom: none; }
.service-block img {
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  height: 320px;
  width: 100%;
  object-fit: cover;
}
.service-block.reverse .service-img { order: 2; }
.service-list {
  list-style: none;
  margin-top: 16px;
  padding: 0;
}
.service-list li {
  padding: 10px 0 10px 34px;
  position: relative;
  border-bottom: 1px dashed var(--line);
}
.service-list li:last-child { border-bottom: none; }
.service-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 9px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--mint-deep);
  color: var(--navy);
  font-size: 0.8rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
.service-list li strong { color: var(--navy); }
.service-list li span { color: var(--muted); font-size: 0.95rem; }

/* ---------- CTA strip ---------- */
.cta-strip {
  background:
    linear-gradient(100deg, rgba(15,36,64,0.92) 0%, rgba(29,132,181,0.82) 100%),
    url("../images/reception.webp") center/cover no-repeat;
  color: var(--white);
  text-align: center;
  border-radius: var(--radius);
  padding: 60px 30px;
}
.cta-strip h2 { color: var(--white); margin-bottom: 12px; }
.cta-strip p { color: rgba(255,255,255,0.9); max-width: 560px; margin: 0 auto 26px; }
.cta-strip .hero-ctas { justify-content: center; display: flex; gap: 14px; flex-wrap: wrap; }

/* ---------- Contact page ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: start;
}
.contact-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: 34px;
}
.contact-card h3 { margin-bottom: 18px; }

form .field { margin-bottom: 18px; }
form label {
  display: block;
  font-family: "Poppins", sans-serif;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--navy);
  margin-bottom: 6px;
}
form input, form textarea, form select {
  width: 100%;
  padding: 13px 15px;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  font-family: inherit;
  font-size: 1rem;
  color: var(--ink);
  background: #fbfcfe;
  transition: border-color 0.15s;
}
form input:focus, form textarea:focus {
  outline: none;
  border-color: var(--blue);
  background: var(--white);
}
form textarea { min-height: 120px; resize: vertical; }
form .required { color: var(--gold-dark); }

.info-list { list-style: none; padding: 0; margin: 0; }
.info-list li {
  display: flex;
  gap: 14px;
  padding: 13px 0;
  border-bottom: 1px dashed var(--line);
  align-items: flex-start;
}
.info-list li:last-child { border-bottom: none; }
.info-list .icon { font-size: 1.25rem; line-height: 1.5; }
.info-list strong { display: block; color: var(--navy); font-family: "Poppins", sans-serif; font-size: 0.92rem; }
.info-list a { font-weight: 600; }

table.hours { width: 100%; border-collapse: collapse; }
table.hours td { padding: 9px 0; border-bottom: 1px dashed var(--line); }
table.hours tr:last-child td { border-bottom: none; }
table.hours td:last-child { text-align: right; font-weight: 600; color: var(--navy); }
table.hours tr.closed td:last-child { color: var(--muted); font-weight: 500; }

.map-embed {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  margin-top: 48px;
}
.map-embed iframe { width: 100%; height: 380px; border: 0; display: block; }

/* ---------- Gallery ---------- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 22px;
  margin-top: 36px;
}
.gallery-grid img {
  border-radius: var(--radius);
  height: 260px;
  width: 100%;
  object-fit: cover;
  box-shadow: var(--shadow-sm);
}

/* ---------- Footer ---------- */
footer.site-footer {
  background: var(--navy-dark);
  color: rgba(255,255,255,0.85);
  padding: 60px 0 0;
  margin-top: 40px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 44px;
  padding-bottom: 44px;
}
.footer-grid img.footer-logo { height: 72px; width: auto; margin-bottom: 16px; }
.footer-grid h4 {
  color: var(--white);
  font-size: 1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 16px;
}
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid ul li { margin-bottom: 10px; }
.footer-grid a { color: rgba(255,255,255,0.85); }
.footer-grid a:hover { color: var(--gold); text-decoration: none; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.15);
  padding: 18px 0;
  font-size: 0.85rem;
  color: rgba(255,255,255,0.6);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  section { padding: 54px 0; }
  .split, .service-block, .contact-grid { grid-template-columns: 1fr; gap: 32px; }
  .service-block.reverse .service-img { order: 0; }
  .footer-grid { grid-template-columns: 1fr; gap: 30px; }
  .team-card img { height: 300px; }
}

@media (max-width: 1080px) {
  .nav-toggle { display: block; }
  nav.main-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 10px 4%;
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
  }
  nav.main-nav.open { display: flex; }
  nav.main-nav a { padding: 14px 6px; border-bottom: 1px solid var(--line); }
  nav.main-nav a.active { border-bottom-color: var(--line); }
  nav.main-nav .btn { margin: 14px 0 8px; text-align: center; }
}

@media (max-width: 820px) {
  .topbar .hours { display: none; }
  .hero { padding: 80px 0 88px; }
  .offer-banner { padding: 32px 26px; gap: 22px; }
}

/* ============================================================
   Additions for the CMS rebuild
   ============================================================ */

.alt-bg { background: var(--mint); }
.container.narrow { width: min(820px, 92%); }
.center { text-align: center; }
.section-more { margin-top: 34px; }
.lede-dark { font-size: 1.1rem; color: var(--muted); max-width: 720px; }

/* Page head (simple hero for text pages) */
.page-head {
  background: linear-gradient(115deg, var(--navy) 0%, var(--navy-dark) 100%);
  color: var(--white);
  padding: 56px 0;
}
.page-head h1 { color: var(--white); }
.page-head .lede-dark { color: rgba(255,255,255,0.88); margin-top: 12px; }
.page-head .lede-dark a { color: #9fd8f2; }
.page-head .post-date { color: rgba(255,255,255,0.7); margin-bottom: 8px; }
.page-head .post-date a { color: #9fd8f2; }

/* Prose (markdown bodies) */
.prose { max-width: 780px; }
.prose h2 { margin: 34px 0 12px; }
.prose h3 { margin: 26px 0 10px; }
.prose ul, .prose ol { margin: 0 0 18px 24px; }
.prose li { margin-bottom: 8px; }
.prose img { border-radius: var(--radius); box-shadow: var(--shadow-sm); margin: 18px 0; }
.prose blockquote {
  border-left: 4px solid var(--gold);
  background: var(--mint);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 16px 20px;
  color: var(--navy);
  margin: 20px 0;
}

/* Related links */
.related-links { margin-top: 44px; background: var(--mint); border-radius: var(--radius); padding: 24px 28px; max-width: 780px; }
.related-links h3 { margin-bottom: 10px; }
.related-links ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 22px; }
.related-links a { font-weight: 600; }

/* Reviews */
.review-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: 24px; margin-top: 36px; }
.review-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px 26px; box-shadow: var(--shadow-sm); }
.review-card .stars { color: var(--gold); font-size: 1.2rem; letter-spacing: 2px; margin-bottom: 12px; }
.review-text { color: var(--ink); font-style: italic; }
.review-name { color: var(--muted); font-weight: 600; margin: 0; }
.review-cta { margin-top: 30px; }

/* Insurance */
.insurance-section { background: var(--white); }
.insurance-list { list-style: none; padding: 0; margin: 28px 0 18px; display: flex; flex-wrap: wrap; gap: 12px; }
.insurance-list li {
  background: var(--mint); color: var(--navy); font-family: "Poppins", sans-serif; font-weight: 600;
  border: 1px solid var(--mint-deep); border-radius: 999px; padding: 10px 22px;
}
.insurance-note { color: var(--muted); max-width: 720px; }

/* Form extras */
.form-card { scroll-margin-top: 90px; }
.form-reassure { color: var(--muted); font-size: 0.98rem; }
.form-submit { width: 100%; }
.form-badges { margin: 16px 0 0; font-size: 0.85rem; color: var(--muted); text-align: center; }
.hidden-field { display: none; }
.info-spacer { margin-bottom: 26px; }

/* FAQ */
.faq-item { border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 14px; background: var(--white); box-shadow: var(--shadow-sm); }
.faq-item summary {
  cursor: pointer; padding: 18px 22px; font-family: "Poppins", sans-serif; font-weight: 600;
  color: var(--navy); font-size: 1.05rem; list-style: none; position: relative; padding-right: 46px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; position: absolute; right: 20px; top: 14px; font-size: 1.5rem; color: var(--blue-dark); }
.faq-item[open] summary::after { content: "–"; }
.faq-answer { padding: 0 22px 18px; color: var(--muted); }

/* Team bios */
.team-bio { padding: 34px 0; border-bottom: 1px solid var(--line); }
.team-bio:last-of-type { border-bottom: none; }
.team-bio .split-img img { max-height: 480px; }
.bio-reverse .split-img { order: 2; }

/* Blog */
.post-date { color: var(--muted); font-size: 0.88rem; margin-bottom: 6px; }
.post-hero { border-radius: var(--radius); box-shadow: var(--shadow); margin-bottom: 28px; width: 100%; max-height: 420px; object-fit: cover; }
.card h3 a { color: var(--navy); text-decoration: none; }

/* Sections rendered from macros */
.offer-section, .cta-section { padding-top: 0; }

/* Sticky mobile CTA bar */
.mobile-cta {
  display: none;
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 60;
  background: var(--white); border-top: 1px solid var(--line);
  padding: 10px 12px; gap: 10px;
  box-shadow: 0 -4px 16px rgba(22,51,91,0.12);
}
.mobile-cta .btn { flex: 1; text-align: center; padding: 12px 10px; font-size: 0.95rem; }

@media (max-width: 820px) {
  .mobile-cta { display: flex; }
  body { padding-bottom: 68px; }
  .bio-reverse .split-img { order: 0; }
}

/* Footer additions */
.footer-tagline { color: rgba(255,255,255,0.55); font-size: 0.88rem; border-top: 1px solid rgba(255,255,255,0.12); padding-top: 18px; }
.nap { line-height: 1.7; }
.footer-grid { grid-template-columns: 1.3fr 1fr 1fr 1fr; }
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .footer-grid { grid-template-columns: 1fr; } }

/* ============================================================
   Scroll animations (activated by js/main.js)
   ============================================================ */

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.65s cubic-bezier(0.22, 0.61, 0.36, 1),
              transform 0.65s cubic-bezier(0.22, 0.61, 0.36, 1);
  will-change: opacity, transform;
}
.reveal.in-view { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* Hero content rises gently on page load */
@keyframes heroUp {
  from { opacity: 0; transform: translateY(26px); }
  to   { opacity: 1; transform: none; }
}
.hero .container > * { animation: heroUp 0.7s cubic-bezier(0.22, 0.61, 0.36, 1) both; }
.hero .container > *:nth-child(2) { animation-delay: 0.12s; }
.hero .container > *:nth-child(3) { animation-delay: 0.24s; }
.hero .container > *:nth-child(4) { animation-delay: 0.36s; }
@media (prefers-reduced-motion: reduce) {
  .hero .container > * { animation: none; }
}

/* Subtle parallax on hero images (desktop only — iOS handles fixed poorly) */
@media (min-width: 900px) and (prefers-reduced-motion: no-preference) {
  .hero { background-attachment: fixed; }
}

/* Header shadow appears on scroll */
.site-header { transition: box-shadow 0.25s ease; }
.site-header.scrolled { box-shadow: 0 4px 18px rgba(22, 51, 91, 0.14); }

/* Gentle hover lift on gallery images */
.gallery-grid img { transition: transform 0.3s ease, box-shadow 0.3s ease; }
.gallery-grid img:hover { transform: scale(1.025); box-shadow: var(--shadow); }

/* Location band under the hero */
.location-band .split-img img { max-height: 520px; object-fit: cover; }
.location-info { margin: 6px 0 22px; }
.location-info li { border-bottom: none; padding: 6px 0; }

/* Accessibility: skip link + visible keyboard focus */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--navy);
  color: var(--white);
  padding: 12px 22px;
  border-radius: 0 0 10px 0;
  font-weight: 600;
}
.skip-link:focus { left: 0; }
a:focus-visible, button:focus-visible, input:focus-visible,
textarea:focus-visible, summary:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ============================================================
   Dynamic hero: slow Ken Burns drift + wave divider + CTA pulse
   ============================================================ */

.hero {
  background: var(--navy-dark);   /* replaces static image bg; image now animates on ::before */
  position: relative;
  overflow: hidden;
  isolation: isolate;
}
.hero::before {
  content: "";
  position: absolute;
  inset: -6%;
  background: var(--hero-img, url("../images/hero-operatory.webp")) center/cover no-repeat;
  z-index: -2;
  animation: kenburns 24s ease-in-out infinite alternate;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, rgba(15,36,64,0.88) 0%, rgba(22,51,91,0.72) 45%, rgba(22,51,91,0.35) 100%);
  z-index: -1;
}
.hero .container { position: relative; z-index: 1; }

@keyframes kenburns {
  from { transform: scale(1) translateY(0); }
  to   { transform: scale(1.08) translateY(-1.5%); }
}

/* Wave divider at the bottom of heroes (echoes the flyer's wave motif) */
.hero-wave {
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  z-index: 1;
  line-height: 0;
  pointer-events: none;
}
.hero-wave svg { width: 100%; height: 56px; display: block; }
@media (max-width: 600px) { .hero-wave svg { height: 32px; } }

/* Gentle attention pulse on the hero's main CTA */
@keyframes ctaGlow {
  0%, 100% { box-shadow: 0 0 0 0 rgba(232, 163, 61, 0.45); }
  60%      { box-shadow: 0 0 0 14px rgba(232, 163, 61, 0); }
}
.hero .hero-ctas .btn-gold { animation: ctaGlow 2.8s ease-out infinite; }

@media (prefers-reduced-motion: reduce) {
  .hero::before { animation: none; }
  .hero .hero-ctas .btn-gold { animation: none; }
}

/* ============================================================
   Hero background slideshow
   ============================================================ */

.hero-slides {
  position: absolute;
  inset: 0;
  z-index: -2;
  overflow: hidden;
}
.hero-slide {
  position: absolute;
  inset: -6%;
  background: center/cover no-repeat;
  opacity: 0;
  transition: opacity 1.8s ease-in-out;
}
.hero-slide.active {
  opacity: 1;
  animation: kenburns 24s ease-in-out infinite alternate;
}
/* No-JS fallback: first slide visible without the .active class */
.no-js-check .hero-slide:first-child { opacity: 1; }

@media (prefers-reduced-motion: reduce) {
  .hero-slide { transition: none; }
  .hero-slide.active { animation: none; }
  .hero-slide:first-child { opacity: 1; }
}

/* Review photo card (patient photo wall) */
.review-photo { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.review-photo img { width: 100%; height: 240px; object-fit: cover; object-position: center 30%; }
.review-photo .review-name { padding: 14px 18px; margin: 0; font-size: 0.9rem; }

/* Brand tooth-logo watermark accents */
.offer-banner, .cta-strip { position: relative; overflow: hidden; }
.offer-banner::after, .cta-strip::after {
  content: "";
  position: absolute;
  right: -40px;
  bottom: -60px;
  width: 260px;
  height: 346px;
  background: url("../images/logo-white.png") center/contain no-repeat;
  opacity: 0.07;
  transform: rotate(-12deg);
  pointer-events: none;
}

/* Google review summary line */
.review-summary {
  font-family: "Poppins", sans-serif;
  font-weight: 600;
  color: var(--gold-dark);
  margin: 8px 0 0;
}

/* ============================================================
   Lightbox (click photos to expand)
   ============================================================ */

img.lightboxable { cursor: zoom-in; }

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(15, 36, 64, 0.94);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 4vh 4vw;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
  cursor: zoom-out;
}
.lightbox.open { opacity: 1; visibility: visible; }

.lightbox img {
  max-width: 92vw;
  max-height: 82vh;
  width: auto;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}
.lightbox-caption {
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.95rem;
  margin-top: 14px;
  text-align: center;
  max-width: 720px;
}
.lightbox-close {
  position: absolute;
  top: 18px;
  right: 22px;
  background: none;
  border: none;
  color: var(--white);
  font-size: 2.6rem;
  line-height: 1;
  cursor: pointer;
  padding: 6px 12px;
}
.lightbox-close:hover { color: var(--gold); }

body.lightbox-open { overflow: hidden; }

@media (prefers-reduced-motion: reduce) {
  .lightbox { transition: none; }
}

.form-privacy { font-size: 0.82rem; color: var(--muted); margin: -6px 0 14px; }


/* ============================================================
   Responsive refinements (phone + tablet audit)
   ============================================================ */

/* Small-laptop / iPad-landscape: condense nav so it never wraps */
@media (min-width: 1081px) and (max-width: 1260px) {
  nav.main-nav { gap: 16px; }
  nav.main-nav a { font-size: 0.9rem; }
  .brand .brand-sub { display: none; }
}

/* Small phones */
@media (max-width: 480px) {
  .topbar { font-size: 0.8rem; }
  .topbar .container > span:first-child { display: none; }  /* hide address; it's in the footer */
  .hero h1 { font-size: 1.7rem; }
  .hero .hero-ctas .btn, .cta-strip .hero-ctas .btn { width: 100%; text-align: center; }
  .offer-banner .price { font-size: 2.4rem; }
  .offer-banner { text-align: left; }
  .offer-banner > .btn { width: 100%; text-align: center; }
  .container { width: 94%; }
  section { padding: 44px 0; }
  .page-head { padding: 40px 0; }
  .split { gap: 24px; }
  .review-summary { font-size: 0.95rem; }
}

/* Touch devices: no hover-dependent behavior needed; make tap targets comfy */
@media (hover: none) {
  nav.main-nav a { padding-top: 12px; padding-bottom: 12px; }
  .faq-item summary { padding-top: 16px; padding-bottom: 16px; }
}

/* iPad portrait: two-column grids that feel cramped go single/double gracefully */
@media (min-width: 600px) and (max-width: 900px) {
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .features { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
}
