/* ==========================================================================
   Road to Serenity Counseling — styles
   Palette drawn from the San Antonio Japanese Tea Garden photos:
   deep evergreen, limestone cream, sage, kintsugi gold, canna-lily coral.
   ========================================================================== */

:root {
  --green-950: #1c2b23;
  --green-900: #24382d;
  --green-700: #3c5a48;
  --green-500: #5d7c68;
  --sage: #8aa693;
  --sage-100: #e9efe8;
  --cream: #faf7f0;
  --sand: #efe8da;
  --sand-dark: #ddd2bd;
  --ink: #2b332c;
  --ink-soft: #55604f;
  --gold: #b08d3e;
  --gold-light: #d9bc72;
  --coral: #c96f55;
  --white: #ffffff;

  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Nunito Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --radius: 16px;
  --shadow-sm: 0 2px 8px rgba(28, 43, 35, 0.06);
  --shadow-md: 0 10px 30px rgba(28, 43, 35, 0.12);
  --container: 1140px;
}

/* ---------- Reset & base ---------- */

*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

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

:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  color: var(--green-900);
  margin: 0 0 1rem;
}

h1 { font-size: clamp(2.5rem, 6vw, 4.25rem); }
h2 { font-size: clamp(1.9rem, 4vw, 2.75rem); }
h3 { font-size: 1.25rem; line-height: 1.35; }

h1 em, h2 em {
  font-style: italic;
  color: var(--gold-light);
}
h2 em { color: var(--gold); }

p { margin: 0 0 1.1rem; }

a { color: var(--green-700); }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--green-900);
  color: var(--white);
  padding: 10px 18px;
  z-index: 200;
}
.skip-link:focus { left: 12px; top: 12px; }

/* ---------- Typography helpers ---------- */

.eyebrow {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--green-500);
  margin-bottom: 0.9rem;
}

.eyebrow-gold { color: var(--gold-light); }

.section-head {
  max-width: 640px;
  margin-bottom: 3rem;
}

.section-lede {
  font-size: 1.125rem;
  color: var(--ink-soft);
}

.text-link {
  display: inline-block;
  font-weight: 700;
  color: var(--green-700);
  text-decoration: none;
  border-bottom: 2px solid var(--gold-light);
  padding-bottom: 2px;
  transition: color 0.2s ease, border-color 0.2s ease;
}
.text-link:hover { color: var(--gold); border-color: var(--gold); }

/* ---------- Buttons ---------- */

.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 1rem;
  padding: 0.85rem 1.75rem;
  border-radius: 999px;
  text-decoration: none;
  text-align: center;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background-color 0.2s ease;
  cursor: pointer;
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: var(--green-900);
  color: var(--cream);
}
.btn-primary:hover { background: var(--green-700); }

.btn-gold {
  background: var(--gold-light);
  color: var(--green-950);
}
.btn-gold:hover { background: var(--gold); }

.btn-sm { padding: 0.55rem 1.25rem; font-size: 0.9rem; }

/* ---------- Header ---------- */

/* Transparent over the hero at the top of the page; gains the cream bar
   once scrolled (js toggles .scrolled past 40px). */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  padding: 14px 0;
  color: var(--cream);
  transition: background-color 0.3s ease, box-shadow 0.3s ease, padding 0.3s ease, color 0.3s ease;
}

.site-header.scrolled {
  background: rgba(250, 247, 240, 0.96);
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow-sm);
  padding: 8px 0;
  color: var(--green-900);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: inherit;
}

.brand-mark { width: 40px; height: 40px; flex-shrink: 0; }
.brand-path { color: var(--gold-light); }
.brand-sun { color: var(--gold-light); }
.site-header.scrolled .brand-path,
.site-header.scrolled .brand-sun { color: var(--gold); }

.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.15rem;
  white-space: nowrap;
}
.brand-sub {
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  opacity: 0.85;
  white-space: nowrap;
}

.site-nav ul {
  display: flex;
  align-items: center;
  gap: 26px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav a:not(.btn) {
  color: inherit;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  white-space: nowrap;
  opacity: 0.92;
  transition: opacity 0.2s ease;
}
.site-nav a:not(.btn):hover { opacity: 1; text-decoration: underline; text-underline-offset: 5px; text-decoration-color: var(--gold-light); }

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: none;
  border: none;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  height: 2px;
  width: 100%;
  background: currentColor;
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: center;
  color: var(--cream);
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(100deg, rgba(20, 32, 26, 0.95) 0%, rgba(20, 32, 26, 0.84) 45%, rgba(20, 32, 26, 0.52) 78%, rgba(20, 32, 26, 0.35) 100%),
    url("../assets/images/hero-garden.jpg");
  background-size: cover;
  background-position: center 65%;
}

.hero-content {
  position: relative;
  padding-top: 120px;
  padding-bottom: 80px;
  max-width: var(--container);
  width: 100%;
}

.hero h1 { color: var(--cream); margin-bottom: 1.25rem; }

.hero-lede {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  max-width: 34em;
  opacity: 0.94;
  margin-bottom: 2rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 28px;
  margin-bottom: 2rem;
}

.hero-link {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--cream);
  text-decoration: none;
  border-bottom: 2px solid var(--gold-light);
  padding-bottom: 3px;
  transition: color 0.2s ease, border-color 0.2s ease;
}
.hero-link .arrow { color: var(--gold-light); transition: transform 0.2s ease; display: inline-block; }
.hero-link:hover { color: var(--gold-light); }
.hero-link:hover .arrow { transform: translateX(3px); }

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: rgba(250, 247, 240, 0.82);
}

.hero-badges li { display: flex; align-items: center; }

.hero-badges li:not(:last-child)::after {
  content: "\00B7";
  margin: 0 0.65em;
  color: var(--gold-light);
}

.hero-scroll {
  position: absolute;
  left: 50%;
  bottom: 20px;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  color: rgba(250, 247, 240, 0.88);
  text-decoration: none;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-shadow: 0 1px 8px rgba(20, 32, 26, 0.6);
  transition: color 0.2s ease;
}

.hero-scroll svg {
  width: 20px;
  height: 20px;
  color: var(--gold-light);
  filter: drop-shadow(0 1px 4px rgba(20, 32, 26, 0.6));
  animation: scroll-bob 2.4s ease-in-out infinite;
}

.hero-scroll:hover { color: var(--cream); }

@keyframes scroll-bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(6px); }
}

/* ---------- Section shells ---------- */

section { padding: 96px 0; }

.section-cream { background: var(--cream); }

/* ---------- Split layouts ---------- */

.split {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: center;
}

.split-reverse { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); }
.split-reverse .split-media { order: 2; }
.split-reverse .split-body { order: 1; }

.split-media { margin: 0; position: relative; }

.split-media img {
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  width: 100%;
  object-fit: cover;
}

.split-media::after {
  content: "";
  position: absolute;
  inset: 18px -18px -18px 18px;
  border: 1.5px solid var(--sand-dark);
  border-radius: var(--radius);
  z-index: -1;
}

.split-media figcaption {
  margin-top: 1.6rem;
  font-size: 0.9rem;
  color: var(--ink-soft);
  text-align: center;
  font-style: italic;
}

/* ---------- About ---------- */

.credentials {
  margin-top: 1.5rem;
  background: var(--white);
  border: 1px solid var(--sand-dark);
  border-left: 4px solid var(--gold);
  border-radius: 12px;
  padding: 1.4rem 1.6rem;
  box-shadow: var(--shadow-sm);
}

.credentials h3 {
  font-size: 0.85rem;
  font-family: var(--font-body);
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--green-500);
  margin-bottom: 0.75rem;
}

.credentials ul { margin: 0; padding-left: 1.2rem; }
.credentials li { margin-bottom: 0.45rem; font-size: 0.98rem; }

.approach { margin-top: 88px; }

.approach-inner {
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
  padding: clamp(2rem, 5vw, 3.5rem);
  background: var(--sage-100);
  border-radius: calc(var(--radius) * 1.5);
}

.approach-inner p:last-child { margin-bottom: 0; }

/* ---------- Kintsugi ---------- */

.kintsugi {
  position: relative;
  background: var(--green-950);
  color: rgba(250, 247, 240, 0.92);
  overflow: hidden;
}

.kintsugi h2 { color: var(--cream); }

.kintsugi-crack {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  color: var(--gold);
  opacity: 0.25;
  pointer-events: none;
}

.kintsugi-inner {
  position: relative;
  max-width: 720px;
  text-align: center;
}

.kintsugi-inner p { font-size: 1.08rem; }

.kintsugi-signoff {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.25rem !important;
  color: var(--gold-light);
  margin-top: 2rem;
}

/* ---------- Specialties ---------- */

.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.card {
  background: var(--white);
  border: 1px solid var(--sand);
  border-radius: var(--radius);
  padding: 1.75rem 1.6rem;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--sage);
}

.card-icon {
  width: 46px;
  height: 46px;
  margin-bottom: 1rem;
  color: var(--green-700);
  background: var(--sage-100);
  border-radius: 12px;
  display: grid;
  place-items: center;
}
.card-icon svg { width: 26px; height: 26px; }

.card h3 { margin-bottom: 0.5rem; }
.card p { margin: 0; font-size: 0.98rem; color: var(--ink-soft); }

.chips-block { margin-top: 3rem; }

.chips-block h3 {
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--green-500);
  margin-bottom: 1.1rem;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  list-style: none;
  margin: 0;
  padding: 0;
  max-width: 840px;
}

.chips li {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--green-700);
  background: var(--sage-100);
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 7px 16px;
  transition: border-color 0.2s ease;
}
.chips li:hover { border-color: var(--sage); }

/* ---------- Types of therapy ---------- */

.modality-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: modality;
}

.modality {
  position: relative;
  background: var(--white);
  border: 1px solid var(--sand);
  border-radius: var(--radius);
  padding: 1.75rem 1.6rem 1.6rem;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.modality:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }

.modality-num {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.05rem;
  color: var(--gold);
  display: block;
  margin-bottom: 0.6rem;
}

.modality h3 { font-size: 1.15rem; margin-bottom: 0.5rem; }
.modality p { margin: 0; font-size: 0.95rem; color: var(--ink-soft); }

/* ---------- Getting started ---------- */

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  list-style: none;
  margin: 0 0 3.5rem;
  padding: 0;
}

.step { text-align: center; padding: 0 12px; }

.step-num {
  display: inline-grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--green-900);
  color: var(--gold-light);
  font-family: var(--font-display);
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.step h3 { margin-bottom: 0.5rem; }
.step p { color: var(--ink-soft); font-size: 0.98rem; }

.service-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.service-card {
  background: var(--sage-100);
  border-radius: var(--radius);
  padding: 1.6rem;
  text-align: center;
}

.service-card h3 { font-size: 1.05rem; margin-bottom: 0.4rem; }
.service-card p { margin: 0; font-size: 0.95rem; color: var(--ink-soft); }

/* ---------- FAQ ---------- */

.faq-container { max-width: 800px; }

.faq-item {
  background: var(--white);
  border: 1px solid var(--sand);
  border-radius: 12px;
  margin-bottom: 12px;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.faq-item summary {
  cursor: pointer;
  list-style: none;
  padding: 1.15rem 3rem 1.15rem 1.4rem;
  font-weight: 700;
  color: var(--green-900);
  position: relative;
  transition: background-color 0.2s ease;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary:hover { background: var(--cream); }

.faq-item summary::after {
  content: "+";
  position: absolute;
  right: 1.3rem;
  top: 50%;
  transform: translateY(-50%);
  font-family: var(--font-display);
  font-size: 1.4rem;
  color: var(--gold);
  transition: transform 0.2s ease;
}
.faq-item[open] summary::after { transform: translateY(-50%) rotate(45deg); }

.faq-item p {
  padding: 0 1.4rem 1.3rem;
  margin: 0;
  color: var(--ink-soft);
}

/* ---------- Contact ---------- */

.contact {
  position: relative;
  color: var(--cream);
  text-align: center;
  padding: 120px 0;
  overflow: hidden;
}

.contact-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(24, 37, 30, 0.82), rgba(24, 37, 30, 0.88)),
    url("../assets/images/pond.jpg");
  background-size: cover;
  background-position: center;
}

.contact-inner { position: relative; max-width: 640px; }

.contact h2 { color: var(--cream); }

.contact-lede { font-size: 1.15rem; opacity: 0.94; }

.contact-actions { margin: 2rem 0 1.75rem; }

.contact-details {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 1rem;
  opacity: 0.92;
}
.contact-details li { margin-bottom: 0.35rem; }
.contact-details a { color: var(--gold-light); text-decoration: none; }
.contact-details a:hover { text-decoration: underline; }

/* ---------- Footer ---------- */

.site-footer {
  background: var(--green-950);
  color: rgba(250, 247, 240, 0.85);
  padding: 64px 0 32px;
  font-size: 0.95rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1.4fr;
  gap: 40px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(250, 247, 240, 0.15);
}

.footer-brand .brand-name {
  font-family: var(--font-display);
  font-size: 1.2rem;
  color: var(--cream);
  margin-bottom: 0.6rem;
  display: block;
}

.footer-brand a { color: var(--gold-light); text-decoration: none; }
.footer-brand a:hover { text-decoration: underline; }

.footer-nav ul { list-style: none; margin: 0; padding: 0; }
.footer-nav li { margin-bottom: 0.5rem; }
.footer-nav a { color: inherit; text-decoration: none; }
.footer-nav a:hover { color: var(--gold-light); }

.footer-crisis h3 {
  color: var(--gold-light);
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 0.6rem;
}
.footer-crisis a { color: var(--gold-light); }

.footer-crisis-note {
  margin-top: 0.9rem;
  font-size: 0.8rem;
  opacity: 0.65;
}

.footer-bottom {
  padding-top: 24px;
  font-size: 0.85rem;
  opacity: 0.7;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px;
}
.footer-bottom p { margin: 0; }

/* ---------- Reveal animations ---------- */

/* Hidden state applies only when JS is running (html.js is set in main.js),
   so content is never lost if scripts fail to load. */
html.js .reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

html.js .reveal.visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  html.js .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .card, .modality { transition: none; }
  .hero-scroll svg { animation: none; }
}

/* ---------- Responsive ---------- */

@media (max-width: 960px) {
  .card-grid, .modality-grid, .steps, .service-cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-grid { grid-template-columns: 1fr 1fr; }

  .split, .split-reverse { grid-template-columns: 1fr; }
  .split-reverse .split-media { order: 0; }
  .split-media { max-width: 520px; margin: 0 auto; }
  .split-media::after { display: none; }
}

/* Collapse to the drawer well before nav labels start wrapping */
@media (max-width: 1020px) {
  /* Top-align the hero: vertical centering in 92vh reads as a hole at these sizes */
  .hero { min-height: 0; }
  .hero-content { padding-top: 136px; padding-bottom: 104px; }

  .nav-toggle { display: flex; position: relative; z-index: 120; }
  .nav-toggle[aria-expanded="true"] { color: var(--cream); }

  .site-nav {
    position: fixed;
    top: 0;
    right: 0;
    height: 100dvh;
    width: min(320px, 85vw);
    background: var(--green-950);
    color: var(--cream);
    padding: 96px 32px 32px;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    box-shadow: var(--shadow-md);
  }

  .site-nav.open { transform: translateX(0); }

  .site-nav ul {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
  }

  .site-nav a:not(.btn) { font-size: 1.15rem; }

  .nav-cta { margin-top: 8px; }

  /* Inside the dark drawer, the CTA needs the gold treatment for contrast */
  .site-nav .btn-primary {
    background: var(--gold-light);
    color: var(--green-950);
  }
}

@media (max-width: 760px) {
  section { padding: 72px 0; }

  .card-grid, .modality-grid, .steps, .service-cards {
    grid-template-columns: 1fr;
  }

  /* Long centered paragraphs are hard to scan on narrow screens */
  .kintsugi-inner p:not(.kintsugi-signoff),
  .approach-inner p { text-align: left; }

  /* Match the hero: no text over photos on small screens */
  .contact { background: var(--green-950); padding: 88px 0; }
  .contact-bg { display: none; }

  /* Keep tall portrait photos from filling a whole viewport before the copy */
  .split-media img { aspect-ratio: 4 / 3; object-fit: cover; }
  .split-media.portrait img { aspect-ratio: 4 / 5; }

  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .footer-bottom { flex-direction: column; }
}

/* True phone widths only — desktop windows resized narrow keep the photo hero.
   Every pixel has text over it at these widths, so the scrim is near-solid
   behind the copy and dissolves toward the bottom, letting the garden emerge
   under the text block. Pixel-based stops (not %) so the reveal zone never
   creeps up behind the badges on short phones. */
@media (max-width: 600px) {
  .hero {
    min-height: 0;
    align-items: flex-start;
  }

  .hero-bg {
    background-image:
      linear-gradient(to top,
        rgba(20, 32, 26, 0.25) 0,
        rgba(20, 32, 26, 0.55) 110px,
        rgba(20, 32, 26, 0.9) 230px,
        rgba(20, 32, 26, 0.96) 100%),
      url("../assets/images/hero-garden.jpg");
    background-position: center;
  }

  .hero-content {
    padding-top: 108px;
    padding-bottom: 120px;
  }

  .hero-scroll { bottom: 12px; }
}
