/* ===========================================
   Count The Beans — Shared Base Styles
   Loaded by all pages. Page-specific styles
   remain in each file's own <style> block.
   =========================================== */

/* ── CSS Variables ── */
:root {
  /* Primary palette */
  --plum:        #644173;
  --plum-deep:   #3d1e4a;
  --plum-dark:   #2d1b36;
  --plum-light:  #e8d0f0;
  --blush:       #fdf5f9;
  --cream:       #fdf0f6;
  --rose:        #e8a0c8;
  --gold:        #f9d44a;
  --white:       #ffffff;
  --text-dark:   #2d1b36;
  --text-mid:    #7a5a6a;
  --text-light:  #c0a0b8;
  /* Aliases used in legal pages */
  --dark:        #2d1b36;
  --light:       #f0e6f5;
  --mid:         #7a5a6a;
  --border:      #e8d0f0;
}

/* ── Reset ── */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

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

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--plum-dark); }
::-webkit-scrollbar-thumb { background: var(--plum); border-radius: 3px; }

/* ── Logo Images ──
   Heights keep logos proportional without
   increasing nav or footer height.          */

.nav-logo-img {
  height: 60px;
  width: auto;
  object-fit: contain;
  display: block;
}

.footer-logo-img {
  height: 60px;
  width: auto;
  object-fit: contain;
  display: block;
}

.tpb-logo {
  height: 95px;
  width: auto;
  object-fit: contain;
  display: block;
}

/* Base footer (pages without their own inline footer style) */
footer {
  background: var(--plum-dark);
  padding: 24px 48px 18px;
  border-top: 1px solid rgba(232,160,200,0.1);
}

.footer-top {
  display: flex;
  align-items: center;
  justify-content: space-between;

  max-width: 1200px;
  margin: 0 auto;

  width: 100%;
  gap: 24px;
}

/* NAV LINKS */
.footer-links {
  display: flex;
  gap: 24px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-links a {
  font-size: 12px;
  color: rgba(255,255,255,0.4);
  text-decoration: none;
}

.footer-links a:hover {
  color: #e8a0c8;
}

/* COPYRIGHT WRAPPER */
.footer-bottom {
  width: 100%;
  margin-top: -8px;
  padding-top: 0px;
  padding-bottom: 4px;
  border-top: 1px solid rgba(232,160,200,0.1);

  display: flex;
  justify-content: center;
}

/* COPYRIGHT TEXT */
.footer-copy-wrap {
  font-size: 11px;
  color: rgba(255,255,255,0.25);
  letter-spacing: 0.3px;
  line-height: 1;
  transform: translateX(-22px);
}

/* FOOTER TEXT — legal pages (privacy, T&C) */
.footer-text {
  flex: 1;
  text-align: center;
}
.footer-text p {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.3);
  line-height: 1.7;
}
.footer-text a {
  color: var(--rose);
  text-decoration: none;
}

/* ── MOBILE OPTIMIZATION: Small phones (≤480px) ── */
@media (max-width: 480px) {
  nav {
    padding: 12px 16px;
  }

  #hero, #pain, #why, #transform, #packages, #cta,
  #contact, #privacy, #about {
    padding-left: 16px;
    padding-right: 16px;
  }

  .contact-right iframe {
    height: 400px !important;
  }

  .pkg-grid-bottom {
    width: 100%;
    margin-left: 0;
    margin-right: 0;
  }


  /* Footer — reduce padding and stack layout */
  footer {
    padding: 16px 16px;
  }

  .footer-top {
    flex-direction: column;
    gap: 12px;
    justify-content: center;
    text-align: center;
  }

  .footer-links {
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
  }

  .footer-copy-wrap {
    transform: translateX(0);
  }
}

/* ── BLOG MOBILE OPTIMIZATION: Small phones (≤480px) ── */
@media (max-width: 480px) {
  .blog-hero {
    padding: 110px 16px 60px;
  }

  .blog-wrap {
    padding: 36px 16px;
    gap: 32px;
  }

  #back-to-top {
    right: 12px;
  }
}

/* ── STATS BOXES CENTERING ── */
.about-stats {
  width: 100% !important;
  max-width: 100% !important;
  justify-items: stretch;
  justify-content: start !important;
  margin-left: 0 !important;
  margin-right: auto !important;
}

/* ── BACK TO TOP BUTTON ── */
#back-to-top {
  position: fixed;
  right: 16px;
  bottom: 20px;
  z-index: 200;
  background: var(--plum);
  color: var(--white);
  border: none;
  border-radius: 50%;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(45,27,54,0.35);
  opacity: 1;
  pointer-events: all;
  transition: opacity 0.3s ease, background 0.2s ease, transform 0.2s ease;
  font-size: 20px;
  line-height: 1;
  font-weight: bold;
}

#back-to-top:hover {
  background: var(--rose);
  color: var(--plum-dark);
  transform: translateY(-2px);
}

@media (max-width: 480px) {
  #back-to-top {
    opacity: 1;
    pointer-events: all;
  }
}

/* ── CONTACT FORM RESPONSIVE ── */
.contact-right iframe {
  max-width: 100%;
  overflow-x: hidden;
}

@media (max-width: 480px) {
  .contact-right {
    padding: 24px 16px !important;
  }

  .contact-right iframe {
    width: 100% !important;
    min-width: 100% !important;
    height: 950px !important;
  }

  /* Footer copyright centered on mobile */
  .footer-bottom {
    justify-content: center !important;
  }

  .footer-copy-wrap {
    transform: translateX(0) !important;
    text-align: center;
  }
}