/* ==========================================================================
   Olwethu Jwili — Clinical Psychologist
   Warm, comforting redesign · Custom CSS on top of Bootstrap 5
   Palette: #d5b874 (gold) · #1f3646 (deep teal-navy) · #ffffff · #282828
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Design tokens
   -------------------------------------------------------------------------- */
:root {
  --gold:        #d5b874;
  --gold-soft:   rgba(213, 184, 116, 0.14);   /* warm tint for section washes  */
  --gold-softer: rgba(213, 184, 116, 0.07);
  --navy:        #1f3646;
  --navy-deep:   #16283475;                   /* overlay tone for imagery      */
  --ink:         #282828;
  --white:       #ffffff;
  --cream:       #fdfbf6;                     /* white warmed with a whisper of gold */

  --font-display: "Fraunces", Georgia, serif;
  --font-body:    "Karla", "Segoe UI", sans-serif;

  --radius-lg:   2rem;
  --radius-xl:   3rem;
  --shadow-soft: 0 18px 45px -18px rgba(31, 54, 70, 0.25);
  --shadow-lift: 0 26px 60px -20px rgba(31, 54, 70, 0.35);

  --ease-gentle: cubic-bezier(0.22, 1, 0.36, 1);
}

/* --------------------------------------------------------------------------
   2. Base
   -------------------------------------------------------------------------- */
html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.75;
  color: var(--ink);
  background-color: var(--cream);
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, .display-font {
  font-family: var(--font-display);
  font-weight: 500;
  color: var(--navy);
  line-height: 1.25;
}

::selection { background: var(--gold); color: var(--navy); }

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

a { color: var(--navy); text-decoration-color: var(--gold); text-underline-offset: 4px; }
a:hover { color: var(--gold); }

/* Small gold eyebrow label above headings */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #b3945a; /* gold darkened for legibility on light backgrounds */
}
.eyebrow::before {
  content: "";
  display: inline-block;
  width: 2.2rem; height: 2px;
  border-radius: 2px;
  background: var(--gold);
}

/* --------------------------------------------------------------------------
   3. Gradient atmosphere
   Dark sections share a deep navy-to-teal gradient warmed by soft gold
   glows; the hero adds a slow-drifting shimmer for gentle life.
   -------------------------------------------------------------------------- */

/* Soft wave divider below dark heroes. The SVG draws the navy wave on a
   transparent background and the negative top margin tucks it under the
   hero, so sub-pixel rounding can never open a hairline seam. */
.divider {
  display: block;
  width: 100%;
  height: 70px;
  margin-top: -2px;
}

/* --------------------------------------------------------------------------
   4. Buttons — pill-shaped, finger-friendly
   -------------------------------------------------------------------------- */
.btn-warm,
.btn-outline-warm,
.btn-ghost-light {
  display: inline-block;
  padding: 0.85rem 2.1rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.02em;
  text-decoration: none;
  border: 2px solid transparent;
  transition: transform 0.3s var(--ease-gentle), box-shadow 0.3s var(--ease-gentle),
              background-color 0.3s, color 0.3s, border-color 0.3s;
}

.btn-warm {
  background: var(--gold);
  color: var(--navy);
  box-shadow: 0 10px 24px -10px rgba(213, 184, 116, 0.8);
}
.btn-warm:hover {
  background: var(--navy);
  color: var(--white);
  transform: translateY(-3px);
  box-shadow: var(--shadow-soft);
}

.btn-outline-warm {
  border-color: var(--navy);
  color: var(--navy);
  background: transparent;
}
.btn-outline-warm:hover {
  background: var(--navy);
  color: var(--white);
  transform: translateY(-3px);
}

/* Light outline for use on navy backgrounds */
.btn-ghost-light {
  border-color: rgba(255, 255, 255, 0.55);
  color: var(--white);
  background: transparent;
}
.btn-ghost-light:hover {
  background: var(--white);
  border-color: var(--white);
  color: var(--navy);
  transform: translateY(-3px);
}

/* --------------------------------------------------------------------------
   5. Header / navigation
   Transparent over the hero; JS adds .is-scrolled once the page moves.
   -------------------------------------------------------------------------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1030;
  padding: 1.1rem 0;
  transition: padding 0.4s var(--ease-gentle), background-color 0.4s,
              box-shadow 0.4s, backdrop-filter 0.4s;
}

.site-header .navbar-brand img {
  height: 54px;
  transition: height 0.4s var(--ease-gentle);
  /* the logo artwork is dark — lift it on the navy hero */
  filter: brightness(0) invert(1);
}

.site-header .nav-link {
  color: rgba(255, 255, 255, 0.9);
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.6rem 1rem !important;
  border-radius: 999px;
  transition: color 0.25s, background-color 0.25s;
}
.site-header .nav-link:hover,
.site-header .nav-link.active { color: var(--gold); }

.site-header .btn-warm { padding: 0.6rem 1.5rem; font-size: 0.92rem; }

/* Scrolled state: warm solid bar, slimmer, soft shadow */
.site-header.is-scrolled {
  padding: 0.45rem 0;
  background: rgba(253, 251, 246, 0.92);
  backdrop-filter: blur(10px);
  box-shadow: 0 8px 30px -12px rgba(31, 54, 70, 0.25);
}
.site-header.is-scrolled .navbar-brand img { height: 44px; filter: none; }
.site-header.is-scrolled .nav-link { color: var(--navy); }
.site-header.is-scrolled .nav-link:hover,
.site-header.is-scrolled .nav-link.active { color: #b3945a; background: var(--gold-softer); }

/* Hamburger — custom two-line icon that stays visible on both header states */
.site-header .navbar-toggler {
  border: none;
  padding: 0.6rem;
  width: 48px; height: 48px; /* comfortable touch target */
}
.site-header .navbar-toggler:focus { box-shadow: none; outline: 2px solid var(--gold); border-radius: 12px; }
.site-header .navbar-toggler span,
.site-header .navbar-toggler span::before {
  display: block;
  width: 26px; height: 2.5px;
  border-radius: 3px;
  background: var(--white);
  transition: background 0.3s;
}
.site-header .navbar-toggler span::before { content: ""; transform: translateY(8px); }
.site-header.is-scrolled .navbar-toggler span,
.site-header.is-scrolled .navbar-toggler span::before { background: var(--navy); }

/* Services dropdown — soft rounded card */
.site-header .dropdown-menu {
  border: none;
  border-radius: 1.4rem;
  padding: 0.7rem;
  margin-top: 0.75rem;
  background: var(--cream);
  box-shadow: var(--shadow-soft);
}
.site-header .dropdown-item {
  border-radius: 999px;
  padding: 0.6rem 1.1rem;
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--navy);
}
.site-header .dropdown-item:hover,
.site-header .dropdown-item:focus {
  background: var(--gold-soft);
  color: #b3945a;
}

/* Mobile header: keep a constant compact size so the scroll animation can
   never shift the logo, and respect the notch/status-bar safe area. */
@media (max-width: 991.98px) {
  .site-header,
  .site-header.is-scrolled {
    padding: 0.6rem 0;
    padding-top: calc(0.6rem + env(safe-area-inset-top, 0px));
  }
  .site-header .navbar-brand img,
  .site-header.is-scrolled .navbar-brand img {
    height: 44px;
  }
}

/* Collapsed mobile menu — soft rounded card */
@media (max-width: 991.98px) {
  .site-header .navbar-collapse {
    margin-top: 0.9rem;
    background: var(--cream);
    border-radius: var(--radius-lg);
    padding: 1.25rem 1.4rem;
    box-shadow: var(--shadow-soft);
  }
  .site-header .navbar-collapse .nav-link { color: var(--navy); padding: 0.8rem 1rem !important; }
  .site-header .navbar-collapse .btn-warm { display: block; text-align: center; margin-top: 0.75rem; }
}

/* --------------------------------------------------------------------------
   6. Hero
   -------------------------------------------------------------------------- */
.hero {
  position: relative;
  /* layered glows over a navy-to-teal base; the bottom fades to flat navy
     so the wave divider below blends seamlessly */
  background:
    radial-gradient(1100px 650px at 88% -18%, rgba(213, 184, 116, 0.32), transparent 60%),
    radial-gradient(850px 550px at -12% 30%, rgba(52, 110, 98, 0.55), transparent 62%),
    radial-gradient(650px 420px at 68% 42%, rgba(213, 184, 116, 0.10), transparent 60%),
    linear-gradient(180deg, #142b39 0%, #1d3a4a 55%, var(--navy) 88%, var(--navy) 100%);
  color: var(--white);
  padding: 11rem 0 8.5rem;
  overflow: hidden;
}

/* Slow-drifting gold shimmer that gives the gradient life without noise */
.hero::before {
  content: "";
  position: absolute;
  top: -30%; left: -10%;
  width: 70%; height: 120%;
  background: radial-gradient(closest-side, rgba(213, 184, 116, 0.16), transparent 70%);
  filter: blur(10px);
  pointer-events: none;
  animation: shimmer-drift 22s ease-in-out infinite alternate;
}
@keyframes shimmer-drift {
  from { transform: translate(0, 0) scale(1); }
  to   { transform: translate(45%, 18%) scale(1.25); }
}
.hero--short { padding: 9.5rem 0 5.5rem; } /* inner pages */

.hero h1 {
  color: var(--white);
  font-size: clamp(1.85rem, 4.2vw, 3.2rem);
  font-weight: 400;
  font-style: italic;      /* the hero carries a quotation */
}
.hero h1 .quote-mark {
  font-size: 1.6em;
  color: var(--gold);
  font-style: normal;
  line-height: 0;
  vertical-align: -0.28em;
}
.hero .hero-attribution {
  color: var(--gold);
  font-family: var(--font-display);
  font-size: 1.15rem;
  letter-spacing: 0.06em;
}
.hero .lead { color: rgba(255, 255, 255, 0.82); }

/* --------------------------------------------------------------------------
   7. Sections & cards
   -------------------------------------------------------------------------- */
.section { padding: 5.5rem 0; }
.section--wash { background: linear-gradient(180deg, var(--gold-softer), var(--gold-soft)); }
.section--navy {
  background:
    radial-gradient(900px 550px at 108% -20%, rgba(213, 184, 116, 0.20), transparent 60%),
    radial-gradient(750px 500px at -10% 110%, rgba(52, 110, 98, 0.45), transparent 62%),
    linear-gradient(165deg, #1a3241 0%, var(--navy) 55%, #1d3f4a 100%);
  color: rgba(255, 255, 255, 0.85);
}
.section--navy h2, .section--navy h3, .section--navy h4 { color: var(--white); }

/* Service cards — rounded, breathing, lift gently on hover */
.card-soft {
  background: var(--white);
  border: none;
  border-radius: var(--radius-lg);
  padding: 2.5rem 2rem;
  height: 100%;
  box-shadow: 0 14px 40px -22px rgba(31, 54, 70, 0.28);
  transition: transform 0.4s var(--ease-gentle), box-shadow 0.4s var(--ease-gentle);
}
.card-soft:hover { transform: translateY(-8px); box-shadow: var(--shadow-lift); }

.card-soft .card-icon {
  width: 108px; height: 108px;
  margin: 0 auto 1.5rem;
  display: grid;
  place-items: center;
  background: var(--gold-soft);
  /* organic blob instead of a circle */
  border-radius: 46% 54% 55% 45% / 52% 44% 56% 48%;
}
.card-soft .card-icon img { width: 68px; }

.card-soft h3 { font-size: 1.45rem; margin-bottom: 0.75rem; }

.link-more {
  font-weight: 700;
  color: #b3945a;
  text-decoration: none;
  letter-spacing: 0.04em;
}
.link-more::after { content: " \2192"; transition: margin-left 0.25s; }
.link-more:hover { color: var(--navy); }
.link-more:hover::after { margin-left: 4px; }

/* --------------------------------------------------------------------------
   8. Imagery — organic masks, warm overlays, soft shadows
   -------------------------------------------------------------------------- */
.img-organic {
  position: relative;
  display: inline-block;
}
.img-organic img {
  border-radius: 58% 42% 45% 55% / 48% 52% 48% 52%;
  box-shadow: var(--shadow-lift);
  width: 100%;
  object-fit: cover;
}
/* warm gold veil over photos so they sit inside the palette */
.img-organic::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 58% 42% 45% 55% / 48% 52% 48% 52%;
  background: linear-gradient(160deg, rgba(213, 184, 116, 0.18), rgba(31, 54, 70, 0.12));
  pointer-events: none;
}
/* offset gold outline echoing the blob */
.img-organic::before {
  content: "";
  position: absolute;
  inset: -14px -14px 14px 14px;
  border: 2px solid var(--gold);
  border-radius: 58% 42% 45% 55% / 48% 52% 48% 52%;
  opacity: 0.55;
  pointer-events: none;
}

/* Simple rounded photo with warm overlay (for photo pairs) */
.img-warm {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}
.img-warm img { width: 100%; height: 100%; object-fit: cover; display: block; }
.img-warm::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(31, 54, 70, 0.35));
  pointer-events: none;
}

/* --------------------------------------------------------------------------
   9. Specialties list (services page)
   -------------------------------------------------------------------------- */
.specialty {
  display: flex;
  gap: 1.1rem;
  background: var(--white);
  border-radius: 1.5rem;
  padding: 1.4rem 1.5rem;
  height: 100%;
  box-shadow: 0 10px 30px -20px rgba(31, 54, 70, 0.25);
}
.specialty .dot-bullet { flex: 0 0 auto; margin-top: 0.35rem; color: var(--gold); }
.specialty h4 { font-size: 1.12rem; margin-bottom: 0.25rem; }
.specialty p { margin: 0; font-size: 0.97rem; color: #555; }

/* Steps (Getting started is easy) */
.step-card { text-align: center; padding: 1rem; }
.step-card .step-number {
  font-family: var(--font-display);
  font-size: 2.6rem;
  color: var(--gold);
  line-height: 1;
}
.step-card h4 { margin: 0.6rem 0 0.4rem; font-size: 1.25rem; }

/* --------------------------------------------------------------------------
   10. Quote band
   -------------------------------------------------------------------------- */
.quote-band blockquote {
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(1.4rem, 2.8vw, 2rem);
  color: var(--white);
  margin: 0;
}
.quote-band cite { color: var(--gold); font-style: normal; font-family: var(--font-body); letter-spacing: 0.1em; }

/* --------------------------------------------------------------------------
   11. FAQ accordion (Bootstrap accordion re-skinned)
   -------------------------------------------------------------------------- */
.accordion-warm .accordion-item {
  border: none;
  border-radius: 1.5rem !important;
  margin-bottom: 1rem;
  overflow: hidden;
  background: var(--white);
  box-shadow: 0 10px 30px -22px rgba(31, 54, 70, 0.3);
}
.accordion-warm .accordion-button {
  font-family: var(--font-display);
  font-size: 1.15rem;
  color: var(--navy);
  background: var(--white);
  padding: 1.3rem 1.6rem;
  box-shadow: none;
}
.accordion-warm .accordion-button:not(.collapsed) {
  background: var(--gold-soft);
  color: var(--navy);
}
.accordion-warm .accordion-button:focus { box-shadow: 0 0 0 3px var(--gold-soft); }
.accordion-warm .accordion-button::after {
  /* gold chevron */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23b3945a'%3E%3Cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E");
}
.accordion-warm .accordion-body { padding: 0.4rem 1.6rem 1.6rem; color: #444; }
.accordion-warm .accordion-body ul { padding-left: 1.2rem; }
.accordion-warm .accordion-body li { margin-bottom: 0.35rem; }

/* --------------------------------------------------------------------------
   12. Contact section & forms
   -------------------------------------------------------------------------- */
.contact-chip {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: var(--white);
  border-radius: 1.5rem;
  padding: 1.2rem 1.5rem;
  box-shadow: 0 10px 30px -20px rgba(31, 54, 70, 0.25);
  height: 100%;
}
.contact-chip .chip-icon {
  flex: 0 0 auto;
  width: 52px; height: 52px;
  display: grid; place-items: center;
  background: var(--gold-soft);
  border-radius: 46% 54% 55% 45% / 52% 44% 56% 48%;
  color: #b3945a;
}
.contact-chip h4 { font-size: 1.05rem; margin: 0; word-break: break-word; }
.contact-chip a { text-decoration: none; }
.contact-chip a:hover h4 { color: #b3945a; }

/* Warm form controls */
.form-warm .form-control,
.form-warm .form-select {
  border: 1.5px solid rgba(31, 54, 70, 0.15);
  border-radius: 1.1rem;
  padding: 0.85rem 1.2rem;
  font-size: 1rem;
  background: var(--white);
  color: var(--ink);
  transition: border-color 0.25s, box-shadow 0.25s;
}
.form-warm .form-control:focus,
.form-warm .form-select:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 4px var(--gold-soft);
}
.form-warm textarea.form-control { min-height: 140px; border-radius: 1.4rem; }
.form-warm .form-label { font-weight: 700; color: var(--navy); font-size: 0.92rem; }

/* Card wrapping the form */
.form-card {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: 2.75rem 2.5rem;
  box-shadow: var(--shadow-soft);
}
@media (max-width: 575.98px) { .form-card { padding: 2rem 1.4rem; } }

/* Post-submit thank-you message (revealed by JS) */
.form-success {
  display: none;
  background: var(--gold-soft);
  border-radius: 1.4rem;
  padding: 1.2rem 1.5rem;
  color: var(--navy);
  font-weight: 700;
}
.form-success.is-visible { display: block; }

/* Error notice — same shape as the success panel, warmer red */
.form-error {
  display: none;
  background: rgba(168, 61, 47, 0.10);
  border-radius: 1.4rem;
  padding: 1.2rem 1.5rem;
  color: #8f3325;
  font-weight: 700;
}
.form-error.is-visible { display: block; }

/* Honeypot — off-screen rather than display:none, which some bots detect */
.hp-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Submit button while the request is in flight */
.form-warm button[type="submit"][disabled] {
  opacity: 0.6;
  cursor: progress;
}

/* --------------------------------------------------------------------------
   13. Footer
   -------------------------------------------------------------------------- */
.site-footer {
  background:
    radial-gradient(850px 500px at 100% 0%, rgba(213, 184, 116, 0.14), transparent 60%),
    radial-gradient(700px 450px at -8% 100%, rgba(52, 110, 98, 0.40), transparent 60%),
    linear-gradient(170deg, #1a3241 0%, var(--navy) 60%, #16303c 100%);
  color: rgba(255, 255, 255, 0.75);
  padding: 4.5rem 0 2rem;
}
.site-footer h3 {
  color: var(--gold);
  font-size: 1.15rem;
  letter-spacing: 0.06em;
  margin-bottom: 1.1rem;
}
.site-footer a {
  color: rgba(255, 255, 255, 0.75);
  text-decoration: none;
  transition: color 0.25s;
}
.site-footer a:hover { color: var(--gold); }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 0.55rem; }
.site-footer .footer-logo { height: 64px; filter: brightness(0) invert(1); opacity: 0.9; }
.site-footer .social-links a {
  display: inline-grid;
  place-items: center;
  width: 46px; height: 46px;
  margin-right: 0.5rem;
  border: 1.5px solid rgba(255, 255, 255, 0.3);
  border-radius: 46% 54% 55% 45% / 52% 44% 56% 48%;
  transition: border-color 0.25s, background 0.25s, color 0.25s;
}
.site-footer .social-links a:hover {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--navy);
}
.site-footer .footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  margin-top: 3rem;
  padding-top: 1.5rem;
  font-size: 0.9rem;
}

/* Floating WhatsApp enquiry button */
.whatsapp-float {
  position: fixed;
  right: 1.4rem;
  bottom: 1.4rem;
  z-index: 1040;
  width: 60px; height: 60px;
  display: grid;
  place-items: center;
  background: var(--gold);
  color: var(--navy);
  border-radius: 46% 54% 55% 45% / 52% 44% 56% 48%;
  box-shadow: var(--shadow-lift);
  transition: transform 0.3s var(--ease-gentle), background 0.3s, color 0.3s;
}
.whatsapp-float:hover { transform: translateY(-4px) scale(1.05); background: var(--navy); color: var(--gold); }

/* --------------------------------------------------------------------------
   14. Scroll-reveal animations
   Elements with [data-reveal] start hidden and ease in when they enter
   the viewport (JS adds .is-revealed). Honors reduced-motion preference.
   -------------------------------------------------------------------------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(34px);
  transition: opacity 0.8s var(--ease-gentle), transform 0.8s var(--ease-gentle);
  transition-delay: var(--reveal-delay, 0s);
}
[data-reveal="scale"] { transform: translateY(0) scale(0.94); }
[data-reveal].is-revealed { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  [data-reveal] { opacity: 1; transform: none; transition: none; }
  .hero::before { animation: none; }
}

/* --------------------------------------------------------------------------
   15. Small-screen refinements
   -------------------------------------------------------------------------- */
@media (max-width: 767.98px) {
  .section { padding: 3.75rem 0; }
  .hero { padding: 8.5rem 0 6rem; }
  .hero--short { padding: 7.5rem 0 4rem; }
  .img-organic::before { inset: -8px -8px 8px 8px; }
  body { font-size: 1rem; }
}
