/* ==========================================================================
   Hampton Chiropractic Clinic — site styles
   Recreates the original WordPress (Salient theme) look without the theme.
   Breakpoints match the old theme: phone < 690px, tablet 690–999px,
   desktop >= 1000px, large desktop >= 1300px.
   ========================================================================== */

@font-face {
  font-family: "DM Sans";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(../fonts/dm-sans-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "DM Sans";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(../fonts/dm-sans-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "DM Sans";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(../fonts/dm-sans-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "DM Sans";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(../fonts/dm-sans-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --navy: #375673;
  --blush: rgba(235, 208, 198, 0.9);
  --cream: #fdf7ef;
  --sky: #c8e2f1;
  --text: #676767;
  --heading: #444;
  --link-dark: #3b4b5a;
  --sans: "DM Sans", "Helvetica Neue", Arial, sans-serif;
  --serif: Georgia, serif;
  --ease: cubic-bezier(0.25, 1, 0.33, 1);
  --ease-open: cubic-bezier(0.4, 0, 0.2, 1);  /* even ease-in-out for the FAQ open/close */
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
/* The old site loaded Google's static DM Sans (optical size 14). Our variable file
   would otherwise auto-switch to the tighter "display" optical size at large sizes. */
* { font-optical-sizing: none; font-variation-settings: "opsz" 14; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  background: #fff;
  color: var(--text);
  font-family: var(--serif);
  font-size: 18px;
  line-height: 32.4px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1, h2, h3, h4, h5, h6, p, ul, ol, figure, address { margin: 0; padding: 0; }
h1, h2, h3, h4, h5, h6 { color: var(--heading); font-family: var(--sans); letter-spacing: 0; }
img { max-width: 100%; height: auto; }
picture { display: block; }
a { color: inherit; text-decoration: none; transition: color 0.3s, opacity 0.3s; }
:focus-visible { outline: 2px solid var(--navy); outline-offset: 3px; }

.visually-hidden {
  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: 12px; top: -60px; z-index: 1000;
  background: #fff; color: var(--navy); font: 700 16px/1 var(--sans);
  padding: 14px 18px; border-radius: 4px; transition: top 0.2s;
}
.skip-link:focus { top: 12px; }
.preview-banner {
  position: sticky; top: 0; z-index: 1001; background: #fff3c4; color: #5a4700;
  font: 700 15px/1.4 var(--sans); text-align: center; padding: 10px 16px;
  border-bottom: 1px solid #e6d27a;
}

/* ---------- type scale (matches the old theme settings) ---------- */
.h3 { font-family: var(--sans); font-weight: 500; font-size: 36px; line-height: 44px; color: var(--heading); }

/* ---------- layout ---------- */
.container { width: 100%; max-width: 320px; margin: 0 auto; }
@media (max-width: 321px) { .container { max-width: 300px; } }
@media (min-width: 480px) { .container { max-width: 420px; } }
@media (min-width: 690px) { .container { max-width: 600px; } }
@media (min-width: 1000px) { .container { max-width: 1425px; padding: 0 90px; } }

.col { position: relative; }
@media (min-width: 1000px) {
  .grid { display: flex; flex-wrap: wrap; margin: 0 -1%; }
  .grid--middle { align-items: center; }
  .col { padding: 0 1%; }
  .col-4 { width: 33.3333%; }
  .col-6 { width: 50%; }
  .col-8 { width: 66.6667%; }
}

/* ---------- buttons ---------- */
.btn-jumbo {
  display: inline-flex; align-items: center;
  min-height: 64px; padding: 10px 11px 10px 36px; margin-bottom: 10px;
  background: var(--blush); color: var(--navy); border-radius: 4px;
  font: 700 18px/20px var(--sans);
  transition: background-color 0.3s var(--ease), box-shadow 0.3s var(--ease), transform 0.3s var(--ease);
}
.btn-jumbo span { margin-right: 19px; }
.btn-jumbo i {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 50%; flex: none;
}
.btn-jumbo .icon { position: relative; top: -1px; }
/* Hover: button lifts and turns cream. */
.btn-jumbo:hover, .btn-jumbo:focus-visible {
  background: var(--cream);
  box-shadow: 0 10px 24px rgba(16, 32, 48, 0.28);
  transform: translateY(-2px);
}
.btn-jumbo:active { transform: translateY(0); box-shadow: 0 4px 12px rgba(16, 32, 48, 0.24); }
.btn-jumbo:focus-visible { outline-color: #fff; }
@media (hover: none) { .btn-jumbo:hover { transform: none; box-shadow: none; } }

.btn-outline {
  display: inline-block; margin-bottom: 10px; padding: 13px 35px;
  border: 2px solid var(--navy); border-radius: 4px; background: transparent;
  color: var(--navy); font: 700 14px/20px var(--sans);
  transition: background-color 0.45s var(--ease), color 0.45s var(--ease), border-color 0.45s var(--ease);
}
.btn-outline:hover { background: var(--navy); color: #fff; }

/* ---------- rich text (FAQ answers, bios) ---------- */
.rich > * + * { margin-top: 1.5em; }
.rich a { text-decoration: underline; text-underline-offset: 3px; color: var(--navy); }
.dot-list { list-style: none; margin: 0; padding: 0; }
.dot-list li { position: relative; padding-left: 30px; margin-bottom: 5px; }
.dot-list li::before { content: "."; position: absolute; left: 0; top: 9px; line-height: 0; font-size: 26px; }

/* ==========================================================================
   Top banner (hero)
   ========================================================================== */
.hero { position: relative; overflow: hidden; background: var(--navy); color: #fff; padding-top: 4vw; }
.hero__media { position: absolute; inset: 0; overflow: hidden; }
.hero__parallax { position: absolute; left: 0; right: 0; top: 0; bottom: 0; }
.hero__parallax picture { height: 100%; }
.hero__img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center center; }
.hero__overlay {
  position: absolute; inset: 0; opacity: 0.8;
  background: linear-gradient(to bottom, rgba(55, 86, 115, 0.75) 0%, #375673 100%);
}
.hero__inner { position: relative; z-index: 1; }
.hero__logo { line-height: 0; }
.hero__logo img { display: block; width: 100%; height: auto; margin: 0 auto; }
.hero__cta { text-align: center; }
.hero__prompt { color: #fff; font: 500 22px/32px var(--sans); margin-bottom: 16px; }
.hero__buttons { display: flex; flex-wrap: wrap; justify-content: center; column-gap: 25px; }

@media (min-width: 1000px) {
  .hero__parallax { top: -60px; will-change: transform; }
  .hero__inner {
    padding-top: calc(-9px + 5vw);
    padding-bottom: calc((min(100vw, 1425px) - 180px) * 0.0816 + 25px);
  }
  .hero__brand { padding-left: calc(1% + (-21.6px + 12vw)); padding-right: calc(1% + (-21.6px + 12vw)); }
  .hero__cta { margin-top: 50px; padding-left: calc(1% + (-14.4px + 8vw)); padding-right: calc(1% + (-14.4px + 8vw)); }
}
@media (min-width: 1425px) {
  .hero__inner { padding-top: 62.25px; }
  .hero__brand { padding-left: calc(1% + 149.4px); padding-right: calc(1% + 149.4px); }
  .hero__cta { padding-left: calc(1% + 99.6px); padding-right: calc(1% + 99.6px); }
}
@media (max-width: 999px) {
  .hero__inner { padding-top: min(26vw, 130px); padding-bottom: 45px; }
  .hero__logo img { width: clamp(150px, 39.5vw, 240px); }
  .hero__cta { margin-top: 67px; }
  .hero__prompt { margin-bottom: 25px; }
  .hero__buttons { column-gap: 40px; row-gap: 12px; }
}
@media (max-width: 689px) {
  .hero__prompt { font-size: 19.8px; line-height: 28.8px; }
}
@media (max-width: 440px) {
  /* Small phones: keep both buttons on one line (the old site wrapped "Book Now"). */
  .hero__buttons { column-gap: 12px; }
  .hero__buttons .btn-jumbo { padding-left: 22px; padding-right: 8px; }
  .hero__buttons .btn-jumbo span { margin-right: 12px; }
}

/* ==========================================================================
   Welcome message
   ========================================================================== */
.intro { padding: 8vw 0; background: #fff; }
.intro__text { margin-bottom: 8px; }
@media (max-width: 999px) { .intro { padding-bottom: calc(8vw + 25px); } }
.highlight {
  font-style: normal;
  line-height: 1em;
  background-image: linear-gradient(to right, var(--sky) 0, #fff 100%);
  background-repeat: no-repeat;
  background-position: left 90%;
  background-size: 100% 3px;
}
@media (min-width: 1000px) {
  .js .highlight { background-size: 0 3px; transition: background-size 0.9s cubic-bezier(0.15, 0.75, 0.4, 1); }
  .js .highlight.is-visible { background-size: 100% 3px; }
}

/* ==========================================================================
   FAQ accordion
   ========================================================================== */
.faq { position: relative; z-index: 1; background: var(--cream); padding: 12vw 0; }
.faq__item { margin-bottom: 2.4em; }
.faq__q {
  position: relative; display: inline-block; padding-bottom: 4px;
  font-weight: 500; font-size: 36px; line-height: 44px;
}
.faq__q button {
  appearance: none; -webkit-appearance: none; background: none; border: 0; margin: 0; padding: 0;
  font: inherit; color: rgba(0, 0, 0, 0.65); text-align: left; cursor: pointer;
  transition: color 0.2s linear;
}
.faq__q::before, .faq__q::after {
  content: ""; position: absolute; left: 0; bottom: 0; width: 100%; height: 2px;
  background: rgba(0, 0, 0, 0.1); pointer-events: none;
}
.faq__q::after { background: #000; transform: scaleX(0); transform-origin: left center; transition: transform 0.5s cubic-bezier(0.3, 0.4, 0.1, 1); }
.faq__item.is-open .faq__q::after, .faq__item:hover .faq__q::after { transform: scaleX(1); }
.faq__item.is-open .faq__q button, .faq__item:hover .faq__q button { color: #000; }
.faq__inner { padding: 1.4em 14px 0; }
/* Open/close: the panel's height animates (grid rows 0fr → 1fr) while the answer fades. */
.js .faq__a {
  display: grid; grid-template-rows: 0fr; visibility: hidden;
  transition: grid-template-rows 0.4s var(--ease-open), visibility 0s 0.4s;
}
.js .faq__item.is-open .faq__a { grid-template-rows: 1fr; visibility: visible; transition: grid-template-rows 0.4s var(--ease-open), visibility 0s; }
.faq-moving { overflow-anchor: none; }
.js .faq__clip { overflow: hidden; min-height: 0; }
.js .faq__inner { opacity: 0; transition: opacity 0.2s linear; }
.js .faq__item.is-open .faq__inner { opacity: 1; transition: opacity 0.3s linear 0.1s; }
@media (min-width: 690px) and (max-width: 999px) {
  .faq__list { padding: 0 20%; }
}

/* ==========================================================================
   Team
   ========================================================================== */
.doctor { padding: 4vw 0; background: #fff; }
.doctor:first-child { padding-top: 8vw; }
.doctor:last-child { padding-bottom: 8vw; }
.doctor__name { font-weight: 700; font-size: 46px; line-height: 75.9px; margin-bottom: 7px; }
.doctor__bio { padding-right: 15%; margin-bottom: 27px; }
@media (max-width: 999px) { .doctor__bio { padding-right: 0; } }
.doctor__photo img { display: block; width: 100%; height: auto; }
@media (max-width: 999px) {
  .doctor__grid { display: flex; flex-direction: column; }
  .doctor__grid > .col { margin-bottom: 25px; }
  .doctor__grid > .col:last-child { margin-bottom: 0; }
}
@media (max-width: 689px) {
  .doctor__grid { flex-direction: column-reverse; }
  .doctor__grid > .col:last-child { margin-bottom: 25px; }
  .doctor__grid > .col:first-child { margin-bottom: 0; }
}

/* ==========================================================================
   Contact + map
   ========================================================================== */
.contact { display: flex; background: var(--navy); }
.contact__map { flex: 0 0 50%; position: relative; }
.map { position: relative; z-index: 0; height: 850px; background: #d6d6d6; }
.map noscript a { display: block; padding: 24px; color: #fff; }
.contact__text { flex: 0 0 50%; padding: 8vw; background: rgba(253, 247, 239, 0.9); color: var(--navy); }
.contact__heading { color: inherit; margin-bottom: 67px; }
.contact__label { color: inherit; font: 700 14px/24px var(--sans); margin-bottom: 7px; }
.contact__block { font-style: normal; margin-bottom: 34px; }
.contact__block a { color: var(--link-dark); opacity: 0.7; }
.contact__block a:hover { opacity: 1; }
@media (max-width: 999px) {
  .contact { flex-direction: column; }
  .contact__map { order: 2; }
  .map { height: 400px; }
}
@media (max-width: 689px) {
  .map { height: 300px; }
}

/* Leaflet map look: greyscale tiles + pulsing navy dot (as on the old site) */
.map .leaflet-tile-pane { filter: grayscale(100%); }
.map .leaflet-marker-icon.hc-marker { background: transparent; border: none; overflow: visible; }
.hc-dot { width: 20px; height: 20px; left: -9px; top: -5px; position: relative; }
.hc-dot__middle, .hc-dot__signal, .hc-dot__signal2 { background-color: var(--navy); position: absolute; transform-origin: 50% 50%; }
.hc-dot__middle { width: 16px; height: 16px; border-radius: 30px; left: 2px; top: 2px; }
.hc-dot__signal, .hc-dot__signal2 {
  width: 180px; height: 180px; border-radius: 200px; left: -80px; top: -80px; opacity: 0; pointer-events: none;
  animation: hcSignal 2s cubic-bezier(0, 0.55, 0.55, 1) 0.78s infinite forwards;
}
.hc-dot__signal2 { animation-delay: 1s; }
@keyframes hcSignal {
  0% { opacity: 0; transform: scale(0); }
  1% { opacity: 0.25; }
  20% { opacity: 0.25; }
  60% { transform: scale(1); opacity: 0; }
}

/* ==========================================================================
   Responsive type (same steps as the old theme)
   ========================================================================== */
@media (max-width: 1300px) { body { line-height: 32px; } }
@media (min-width: 1000px) and (max-width: 1300px) {
  .h3, .faq__q { font-size: 30.6px; line-height: 37.4px; }
  .doctor__name { font-size: 39.1px; line-height: 63.75px; }
}
@media (max-width: 999px) {
  .h3, .faq__q { font-size: 28.8px; line-height: 35.2px; }
  .doctor__name { font-size: 36.8px; line-height: 60px; }
}
@media (max-width: 689px) {
  .doctor__name { font-size: 34.5px; line-height: 56.25px; }
}

/* ==========================================================================
   Phones (< 690px): tighter spacing so visitors reach the information sooner
   ========================================================================== */
@media (max-width: 689px) {
  body { font-size: 17px; line-height: 28px; }
  .container { width: auto; max-width: none; margin-left: 26px; margin-right: 26px; }
  .rich > * + * { margin-top: 1em; }
  .h3, .faq__q { font-size: 23px; line-height: 30px; }

  .hero__inner { padding-top: 14vw; padding-bottom: 32px; }
  .hero__cta { margin-top: 36px; }
  .hero__prompt { margin-bottom: 14px; }

  .intro { padding: 36px 0 40px; }

  .faq { padding: 36px 0 40px; }
  .faq__item { margin-bottom: 20px; }
  .faq__item:last-child { margin-bottom: 0; }
  .faq__inner { padding: 12px 0 4px; }

  .doctor, .doctor:first-child { padding: 36px 0 0; }
  .doctor:last-child { padding-bottom: 40px; }
  .doctor__name { font-size: 30px; line-height: 36px; margin-bottom: 12px; }
  .doctor__bio { margin-bottom: 20px; }
  .doctor__grid > .col:last-child { margin-bottom: 20px; }

  .contact__text { padding: 36px 26px 32px; }
  .contact__heading { margin-bottom: 28px; }
  .contact__block { margin-bottom: 20px; }
  .contact__block:last-child { margin-bottom: 0; }
  .map { height: 260px; }
}

/* ==========================================================================
   Entrance animations: a gentle fade as each part scrolls into view
   (off for anyone who has asked their device for reduced motion)
   ========================================================================== */
@media (prefers-reduced-motion: no-preference) {
  .js .reveal { opacity: 0; }
  .js .reveal.is-visible { animation: hcFadeIn 0.8s ease-out both; }
  /* Doctor sections: name, then bio, then button, in a quick sequence */
  .js .doctor__bio.is-visible { animation-delay: 0.12s; }
  .js .doctor .btn-outline.is-visible { animation-delay: 0.24s; }
}
@media (min-width: 1000px) and (prefers-reduced-motion: no-preference) {
  .hero__img { animation: hcFadeIn 0.55s ease-out both; }
}
@keyframes hcFadeIn { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}

/* ==========================================================================
   404 page
   ========================================================================== */
.page-404 { background: var(--navy); color: #fff; }
.notfound { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 48px 24px; gap: 28px; }
.notfound__logo img { width: 180px; }
.notfound .h3 { color: #fff; }
.notfound .btn-jumbo { padding: 10px 36px; }
.notfound .btn-jumbo span { margin: 0; }
.notfound__contact a { text-decoration: underline; text-underline-offset: 3px; }
