/* =====================================================================
   DTC Skin Clinic & Laser Center — Main Theme Stylesheet
   Palette blended from logo: deep clinical teal-green base,
   logo red for primary CTA, turmeric gold for accents/hover.
   Every color lives here as a CSS custom property — change once,
   updates the whole site.
   ===================================================================== */

:root {
  /* --- Core brand palette (derived from logo) --- */
  --color-primary: #146152;      /* Deep clinical teal-green (from logo swirl) — headers, links, nav */
  --color-primary-dark: #0E4A3F; /* darker shade for hover/active */
  --color-secondary: #D4A657;    /* Turmeric gold — hover states, accents, badges */
  --color-bg: #FAF7F2;           /* Warm off-white — page backgrounds */
  --color-surface: #FFFFFF;      /* Card/panel backgrounds */
  --color-text: #2B2B2B;         /* Charcoal — body text */
  --color-text-muted: #6B6B6B;   /* Secondary text */
  --color-support: #8AA88C;      /* Sage green — category tags/badges */
  --color-cta: #C1272D;          /* Logo red — Book Consultation / primary CTA */
  --color-cta-dark: #9E1F24;     /* CTA hover */
  --color-border: #E7E1D6;       /* Hairline borders/dividers */
  --color-success: #2E7D52;
  --color-white: #FFFFFF;

  /* --- Typography --- */
  --font-heading: 'Poppins', sans-serif;
  --font-body: 'Inter', sans-serif;

  /* --- Radii / shadows --- */
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --shadow-sm: 0 2px 8px rgba(20, 97, 82, 0.08);
  --shadow-md: 0 8px 24px rgba(20, 97, 82, 0.12);
}

/* ---------------------------------------------------------------------
   BASE
   --------------------------------------------------------------------- */
* { box-sizing: border-box; }

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background-color: var(--color-bg);
  line-height: 1.65;
  font-size: 16px;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--color-primary);
  font-weight: 600;
  line-height: 1.3;
}

h1 { font-size: clamp(1.9rem, 3.2vw, 2.75rem); }
h2 { font-size: clamp(1.5rem, 2.4vw, 2.1rem); }
h3 { font-size: clamp(1.15rem, 1.8vw, 1.5rem); }

a { color: var(--color-primary); text-decoration: none; transition: color .2s ease; }
a:hover { color: var(--color-secondary); }

p { margin-bottom: 1rem; color: var(--color-text); }

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

.section { padding: 64px 0; }
.section-sm { padding: 40px 0; }
.bg-surface { background-color: var(--color-surface); }
.bg-primary-soft { background-color: rgba(20, 97, 82, 0.06); }

.section-eyebrow {
  display: inline-block;
  color: var(--color-cta);
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  font-size: .8rem;
  margin-bottom: .5rem;
}

/* ---------------------------------------------------------------------
   BUTTONS / CTA (Section 15 — exactly two consistent CTA patterns)
   --------------------------------------------------------------------- */
.btn-cta-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background-color: var(--color-cta);
  color: var(--color-white);
  border: 2px solid var(--color-cta);
  font-family: var(--font-heading);
  font-weight: 600;
  padding: 12px 26px;
  border-radius: var(--radius-sm);
  transition: background-color .2s ease, transform .15s ease;
}
.btn-cta-primary:hover {
  background-color: var(--color-cta-dark);
  border-color: var(--color-cta-dark);
  color: var(--color-white);
  transform: translateY(-1px);
}

.btn-cta-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background-color: transparent;
  color: var(--color-primary);
  border: 2px solid var(--color-primary);
  font-family: var(--font-heading);
  font-weight: 600;
  padding: 12px 26px;
  border-radius: var(--radius-sm);
  transition: background-color .2s ease, color .2s ease;
}
.btn-cta-secondary:hover {
  background-color: var(--color-primary);
  color: var(--color-white);
}

/* ---------------------------------------------------------------------
   TOP BAR (desktop only) — social icons + phone/WhatsApp
   --------------------------------------------------------------------- */
.site-topbar {
  background-color: var(--color-primary-dark);
  color: #E6F0EC;
  font-size: .82rem;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.site-topbar a {
  color: #E6F0EC !important;
  text-decoration: none;
  font-weight: 500;
}
.site-topbar a:hover { color: var(--color-secondary) !important; }
.site-topbar .social-icons-top {
  display: flex;
  align-items: center;
  gap: 8px;
}
.site-topbar .social-icons-top a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(255,255,255,.14);
  font-size: .66rem;
  font-weight: 700;
  letter-spacing: -.02em;
  transition: background-color .2s ease;
}
.site-topbar .social-icons-top a:hover {
  background: rgba(255,255,255,.26);
  color: #fff !important;
}
.site-topbar .topbar-contact {
  display: flex;
  align-items: center;
  gap: 18px;
}
.site-topbar .topbar-contact a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.site-topbar .topbar-contact a:first-child {
  padding-right: 18px;
  border-right: 1px solid rgba(255,255,255,.18);
}

/* ---------------------------------------------------------------------
   HEADER / NAV
   --------------------------------------------------------------------- */
.site-header {
  background-color: var(--color-surface);
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.site-header .logo-img {
  height: 42px;
  width: auto;
  object-fit: contain; /* preserve natural rectangular aspect ratio */
  border-radius: 0;    /* never round the logo */
  flex-shrink: 0;
}
.site-header .logo-text {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--color-primary);
  font-size: 1rem;
  line-height: 1.1;
  white-space: nowrap;
}
.site-header .navbar-brand {
  flex-shrink: 0;
  margin-right: 12px;
}

.main-nav {
  flex-wrap: wrap;
  column-gap: 2px;
}
.main-nav .nav-link {
  font-family: var(--font-heading);
  font-weight: 500;
  font-size: .88rem;
  color: var(--color-text);
  padding: 10px 10px !important;
  white-space: nowrap;
}
@media (min-width: 992px) and (max-width: 1250px) {
  .main-nav .nav-link { padding: 10px 6px !important; font-size: .82rem; }
}
.main-nav .nav-link:hover,
.main-nav .nav-link:focus {
  color: var(--color-primary);
}

.main-nav .dropdown-menu {
  border: none;
  box-shadow: var(--shadow-md);
  border-radius: var(--radius-sm);
  padding: 10px 0;
  margin-top: 0;
}
.main-nav .dropdown-item {
  font-size: .92rem;
  padding: 8px 20px;
}
.main-nav .dropdown-item:hover {
  background-color: rgba(20, 97, 82, 0.07);
  color: var(--color-primary);
}

/* Desktop: open top-level dropdowns on hover, not just click */
@media (min-width: 992px) {
  .main-nav .dropdown:hover > .dropdown-menu {
    display: block;
  }
}

/* Nested "Treatments" flyout: hovering Dermatology/Trichology/Cosmetology
   reveals the full treatment list beside it. Desktop only — on mobile the
   category link just navigates straight to that category's hub page. */
.main-nav .dropdown-submenu {
  position: relative;
}
.main-nav .dropdown-submenu > .dropdown-item {
  position: relative;
  padding-right: 30px;
}
.main-nav .dropdown-submenu > .dropdown-item::after {
  content: '\203A'; /* › */
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.1rem;
  line-height: 1;
  color: var(--color-text-muted);
}
.main-nav .submenu-menu {
  display: none;
  min-width: 260px;
  max-height: 420px;
  overflow-y: auto;
}
@media (min-width: 992px) {
  .main-nav .submenu-menu {
    position: absolute;
    top: -10px;
    left: 100%;
    margin-left: 2px;
  }
  .main-nav .dropdown-submenu:hover > .submenu-menu {
    display: block;
  }
}
@media (max-width: 991.98px) {
  /* On mobile, hide the nested treatment list entirely — tapping the
     category name (Dermatology/Trichology/Cosmetology) navigates
     straight to that category's full hub page instead. */
  .main-nav .submenu-menu {
    display: none !important;
  }
  .main-nav .dropdown-submenu > .dropdown-item::after {
    display: none;
  }
}

/* Floating WhatsApp button */
.whatsapp-float {
  position: fixed;
  bottom: 22px;
  right: 22px;
  z-index: 1050;
  background-color: #25D366;
  color: var(--color-white);
  width: 58px;
  height: 58px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  font-size: 1.6rem;
}
.whatsapp-float:hover { color: var(--color-white); transform: scale(1.06); }

/* Sticky mobile bottom CTA bar */
.mobile-sticky-cta {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 1040;
  display: none;
  background: var(--color-surface);
  box-shadow: 0 -4px 16px rgba(0,0,0,.1);
  padding: 10px 14px;
  gap: 10px;
}
@media (max-width: 767px) {
  .mobile-sticky-cta { display: flex; }
  body { padding-bottom: 70px; }
}
.mobile-sticky-cta a { flex: 1; text-align: center; justify-content: center; }

/* ---------------------------------------------------------------------
   FOOTER
   --------------------------------------------------------------------- */
.site-footer {
  background-color: var(--color-primary-dark);
  color: #E9F1EE;
  padding: 60px 0 0;
}
.site-footer h5 {
  color: var(--color-secondary);
  font-family: var(--font-heading);
  margin-bottom: 18px;
}
.site-footer a { color: #CFE3DC; }
.site-footer a:hover { color: var(--color-secondary); }
.site-footer .footer-logo { height: 44px; width: auto; margin-bottom: 14px; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.12);
  margin-top: 40px;
  padding: 18px 0;
  font-size: .85rem;
  color: #B9CFC6;
}
.social-icons a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px; height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,.1);
  margin-right: 8px;
}

/* ---------------------------------------------------------------------
   CARDS / BADGES
   --------------------------------------------------------------------- */
.card-clean {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  transition: transform .2s ease, box-shadow .2s ease;
}
.card-clean:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }

.badge-support {
  background-color: var(--color-support);
  color: var(--color-white);
  font-weight: 500;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: .78rem;
}

.badge-gold {
  background-color: rgba(212, 166, 87, 0.15);
  color: #92722E;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: .78rem;
}

/* Botanical-line accent — low opacity, category banners ONLY */
.botanical-accent {
  position: relative;
  overflow: hidden;
}
.botanical-accent::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200' viewBox='0 0 200 200'%3E%3Cpath d='M10 190 Q60 100 10 10 M10 190 Q30 160 60 150 M10 100 Q40 90 55 60' stroke='%23D4A657' stroke-width='2' fill='none' opacity='0.15'/%3E%3C/svg%3E");
  background-repeat: repeat;
  opacity: .5;
  pointer-events: none;
}

/* Visually matches the site's h2 style, but is NOT a heading element —
   used for the treatment-page banner text that sits above the page's
   real H1, so heading order (h1 before h2) stays correct. */
.banner-heading {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.3;
  font-size: clamp(1.5rem, 2.4vw, 2.1rem);
  margin-bottom: .5rem;
}

/* ---------------------------------------------------------------------
   QUICK FACTS BAR (treatment pages)
   --------------------------------------------------------------------- */
.quick-facts-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 18px 22px;
  margin: 24px 0;
}
.quick-facts-bar .fact { min-width: 140px; }
.quick-facts-bar .fact .label {
  display: block;
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--color-text-muted);
}
.quick-facts-bar .fact .value {
  font-family: var(--font-heading);
  font-weight: 600;
  color: var(--color-primary);
}

/* ---------------------------------------------------------------------
   BREADCRUMBS
   --------------------------------------------------------------------- */
.breadcrumb-bar {
  background: var(--color-bg);
  border-bottom: 1px solid var(--color-border);
  padding: 12px 0;
}
.breadcrumb-bar .breadcrumb { margin-bottom: 0; font-size: .88rem; }

/* ---------------------------------------------------------------------
   FORMS
   --------------------------------------------------------------------- */
.form-clinic label {
  font-weight: 500;
  font-size: .88rem;
  color: var(--color-text);
  margin-bottom: 4px;
}
.form-clinic .form-control,
.form-clinic .form-select {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
}
.form-clinic .form-control:focus,
.form-clinic .form-select:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(20, 97, 82, 0.12);
}
.form-honeypot { position: absolute; left: -9999px; opacity: 0; }

.sidebar-widget {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 22px;
  margin-bottom: 24px;
}
.sidebar-widget h4 {
  font-size: 1.05rem;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--color-secondary);
}

/* ---------------------------------------------------------------------
   UTILITIES
   --------------------------------------------------------------------- */
.text-cta { color: var(--color-cta) !important; }
.text-primary-brand { color: var(--color-primary) !important; }
.divider-line {
  height: 1px;
  background: var(--color-border);
  border: none;
  margin: 32px 0;
}
