/* =========================================================
   SS Coconuts — Complete Stylesheet
   Font  : Poppins (Google Fonts)
   Brand : #B8292F
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700;800;900&display=swap');

/* ── 1. Design Tokens ─────────────────────────────────────── */
:root {
  --primary:        #B8292F;
  --primary-dark:   #9b2227;
  --primary-light:  #fae8e8;
  --cream:          #fdf6f0;
  --text-dark:      #1a1a1a;
  --text-mid:       #444444;
  --text-light:     #777777;
  --white:          #ffffff;
  --border:         #e8e0da;
  --shadow-sm:      0 2px 8px  rgba(0,0,0,.08);
  --shadow-md:      0 6px 24px rgba(0,0,0,.12);
  --shadow-lg:      0 16px 48px rgba(0,0,0,.16);
  --radius-sm:      6px;
  --radius-md:      12px;
  --radius-lg:      20px;
  --transition:     .3s ease;
}

/* ── 2. Reset ─────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html  { scroll-behavior: smooth; overflow-x: hidden; }
body  {
  font-family: 'Poppins', sans-serif;
  color: var(--text-dark);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
.page-content {
  overflow-x: hidden;
  width: 100%;
}
/* Force Poppins on ALL elements — override Tailwind font-serif */
.font-serif, .font-sans, [class*="font-"] {
  font-family: 'Poppins', sans-serif !important;
}
img { display: block; max-width: 100%; }
a   { text-decoration: none; color: inherit; }
ul  { list-style: none; }

/* ── 3. Scrollbar ─────────────────────────────────────────── */
::-webkit-scrollbar       { width: 6px; }
::-webkit-scrollbar-track  { background: #f1f1f1; }
::-webkit-scrollbar-thumb  { background: var(--primary); border-radius: 4px; }

/* ── 4. Custom Tailwind Color Overrides ───────────────────── */
/* These extend / override Tailwind's default palette          */
.bg-primary            { background-color: var(--primary) !important; }
.bg-primary-dark       { background-color: var(--primary-dark) !important; }
.bg-primary-light      { background-color: var(--primary-light) !important; }
.bg-cream              { background-color: var(--cream) !important; }
.text-primary          { color: var(--primary) !important; }
.border-primary        { border-color: var(--primary) !important; }
.ring-primary          { --tw-ring-color: var(--primary); }

/* Hover variants */
.hover\:bg-primary:hover          { background-color: var(--primary) !important; }
.hover\:bg-primary-dark:hover     { background-color: var(--primary-dark) !important; }
.hover\:bg-primary-light:hover    { background-color: var(--primary-light) !important; }
.hover\:text-primary:hover        { color: var(--primary) !important; }
.hover\:border-primary:hover      { border-color: var(--primary) !important; }
.hover\:text-white:hover          { color: #fff !important; }

/* Focus ring */
.focus\:ring-primary:focus { --tw-ring-color: var(--primary); }

/* ── 5. Layout Helpers ────────────────────────────────────── */
.section    { padding: 80px 0; }
.section-sm { padding: 48px 0; }
@media (max-width: 767px) {
  .section    { padding: 48px 0; }
  .section-sm { padding: 32px 0; }
}

/* ── 6. Typography Helpers ────────────────────────────────── */
.section-label {
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 10px;
  display: block;
}
.section-title {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-dark);
  line-height: 1.25;
  margin-bottom: 14px;
}
.section-desc {
  font-size: .95rem;
  color: var(--text-light);
  max-width: 560px;
  line-height: 1.7;
}

/* ── 7. Buttons ───────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: var(--radius-sm);
  font-family: 'Poppins', sans-serif;
  font-size: .88rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  border: 2px solid transparent;
  text-decoration: none;
}
.btn-primary {
  background: var(--primary);
  color: #fff;
}
.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(184,41,47,.35);
}
.btn-outline {
  background: transparent;
  border-color: var(--primary);
  color: var(--primary);
}
.btn-outline:hover {
  background: var(--primary);
  color: #fff;
  transform: translateY(-2px);
}
.btn-white {
  background: #fff;
  color: var(--primary);
}
.btn-white:hover {
  background: var(--primary-light);
  transform: translateY(-2px);
}

/* ── 8. Navbar ────────────────────────────────────────────── */
#navbar { transition: background .3s, box-shadow .3s; }
#navbar.scrolled {
  background: rgba(255,255,255,.97) !important;
  box-shadow: 0 2px 20px rgba(0,0,0,.1);
}
.nav-link {
  position: relative;
  font-size: .88rem;
  font-weight: 500;
  color: #333;
  transition: color .25s;
}
.nav-link::after {
  content: '';
  position: absolute;
  bottom: -3px; left: 0;
  width: 0; height: 2px;
  background: var(--primary);
  transition: width .3s;
}
.nav-link:hover,
.nav-link.active { color: var(--primary); }
.nav-link:hover::after,
.nav-link.active::after { width: 100%; }

/* ── 9. Hero Section ──────────────────────────────────────── */
.hero-section {
  background-image: url('../images/homepage/hero_bg.png');
  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;
  min-height: 100vh;
  position: relative;
  display: flex;
  align-items: center;
}
.hero-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    110deg,
    rgba(255,255,255,0.95) 40%,
    rgba(255,255,255,0.60) 65%,
    rgba(255,255,255,0.10) 100%
  );
}
@media (max-width: 767px) {
  .hero-section {
    min-height: auto;
    padding-bottom: 0;
  }
  .hero-section::before {
    background: rgba(255,255,255,0.88);
  }
}

/* ── 10. Hero Circular Frame ──────────────────────────────── */
.hero-img-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: clamp(220px, 70vw, 360px);
  height: clamp(220px, 70vw, 360px);
}
@media (min-width: 1024px) {
  .hero-img-wrapper { width: 440px; height: 440px; }
}

/* Spinning dashed outer ring */
.hero-ring-outer {
  position: absolute;
  inset: -40px;
  border-radius: 50%;
  border: 2px dashed rgba(184,41,47,.25);
  animation: spin-slow 18s linear infinite;
  pointer-events: none;
}
@media (max-width: 767px) {
  .hero-ring-outer { inset: -16px; }
}
/* Static middle ring */
.hero-ring-inner {
  position: absolute;
  inset: -14px;
  border-radius: 50%;
  border: 3px solid rgba(184,41,47,.12);
  pointer-events: none;
}
@media (max-width: 767px) {
  .hero-ring-inner { inset: -6px; }
}
/* Glow blob */
.hero-glow {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: rgba(184,41,47,.12);
  filter: blur(40px);
  pointer-events: none;
}
/* Circular clipped photo */
.hero-circle-img {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0,0,0,.28);
  border: 4px solid #fff;
  z-index: 1;
}
.hero-circle-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
/* Floating badges */
.hero-badge-bl {
  position: absolute;
  bottom: 10px;
  left: -30px;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 6px 24px rgba(0,0,0,.12);
  padding: 10px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  z-index: 2;
  white-space: nowrap;
}
.hero-badge-tr {
  position: absolute;
  top: 10px;
  right: -20px;
  background: var(--primary);
  color: #fff;
  border-radius: 14px;
  box-shadow: 0 6px 24px rgba(184,41,47,.35);
  padding: 10px 16px;
  text-align: center;
  z-index: 2;
}
.hero-badge-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(184,41,47,.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  flex-shrink: 0;
}

/* ── 11. Highlight Stripe ─────────────────────────────────── */
.highlight-stripe {
  background: linear-gradient(90deg, var(--primary) 0%, #d93d44 100%);
}

/* Trusted Section Marquee */
.trusted-marquee {
  background: var(--white) !important;
  color: var(--primary) !important;
  overflow: hidden;
  white-space: nowrap;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.marquee-content {
  display: inline-flex;
  gap: 6rem;
  animation: scroll-marquee 30s linear infinite;
  padding: 1rem 0;
}

@keyframes scroll-marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.marquee-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.85rem;
  white-space: nowrap;
}
.marquee-item i {
  font-size: 1rem;
}
@media (min-width: 768px) {
  .marquee-item { font-size: 1rem; gap: 1rem; }
  .marquee-item i { font-size: 1.3rem; }
}
@media (min-width: 1024px) {
  .marquee-item { font-size: 1.1rem; gap: 1.5rem; }
  .marquee-item i { font-size: 1.6rem; }
}

/* ── 12. Product Carousel ─────────────────────────────────── */
.carousel-track {
  display: flex;
  transition: transform .5s ease;
}
.product-card {
  flex: 0 0 25%;
  padding: 0 12px;
  display: flex;
}
.product-card > div {
  width: 100%;
  display: flex;
  flex-direction: column;
}
.product-card > div > .p-5 {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}
.product-card > div > .p-5 > a {
  margin-top: auto;
}
@media (max-width: 1023px) { .product-card { flex: 0 0 50%; } }
@media (max-width: 767px)  { .product-card { flex: 0 0 100%; } }
.card-hover { transition: transform .3s, box-shadow .3s; }
.card-hover:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 50px rgba(0,0,0,.13);
}

/* ── 13. Stat Cards ───────────────────────────────────────── */
.stat-card { transition: transform .3s, box-shadow .3s; }
.stat-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 40px rgba(184,41,47,.18);
}

/* ── 14. Gallery ──────────────────────────────────────────── */
.gallery-item { overflow: hidden; cursor: pointer; }
.gallery-item img { transition: transform .5s ease; }
.gallery-item:hover img { transform: scale(1.07); }
/* Responsive gallery card widths — overrides inline style via JS */
@media (max-width: 639px) {
  #galleryTrack .gallery-item {
    width: calc(100vw - 48px) !important;
  }
  #galleryTrack .gallery-item img {
    height: 200px !important;
  }
}
@media (min-width: 640px) and (max-width: 1023px) {
  #galleryTrack .gallery-item {
    width: 280px !important;
  }
}

/* ── 15. Process Step connector line ─────────────────────── */
.process-step { position: relative; }
.process-step:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 36px; right: -50%;
  width: 100%; height: 2px;
  background: repeating-linear-gradient(
    90deg,
    var(--primary) 0, var(--primary) 8px,
    transparent 8px, transparent 16px
  );
  z-index: 0;
}
@media (max-width: 767px) { .process-step::after { display: none; } }

/* ── 15b. Process Icon hover animation ───────────────────── */
.process-step img {
  transition: transform .35s cubic-bezier(.34,1.56,.64,1),
              filter .35s ease;
  will-change: transform;
}
.process-step:hover img {
  transform: scale(1.22);
  filter: drop-shadow(0 8px 18px rgba(184,41,47,.30));
}

/* ── 16. Scroll Reveal ────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity .65s ease, transform .65s ease;
}
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-left  {
  opacity: 0;
  transform: translateX(-40px);
  transition: opacity .65s ease, transform .65s ease;
}
.reveal-right {
  opacity: 0;
  transform: translateX(40px);
  transition: opacity .65s ease, transform .65s ease;
}
.reveal-left.visible,
.reveal-right.visible { opacity: 1; transform: translate(0); }

@media (max-width: 767px) {
  .reveal-left, .reveal-right {
    transform: translateY(32px);
  }
  .reveal-left.visible, .reveal-right.visible {
    transform: translateY(0);
  }
}

/* ── 17. Floating decorative icons ───────────────────────── */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-14px); }
}
.floating       { animation: float 4s ease-in-out infinite; }
.floating-delay { animation: float 4s 1.5s ease-in-out infinite; }

/* ── 18. Spinning ring ────────────────────────────────────── */
@keyframes spin-slow {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

/* ── 19. Map pin pulse ────────────────────────────────────── */
@keyframes ping {
  0%   { transform: scale(1);   opacity: 1; }
  100% { transform: scale(2.5); opacity: 0; }
}
.map-pin-pulse { animation: ping 1.6s ease-out infinite; }

/* ── 20. Lightbox ─────────────────────────────────────────── */
#lightbox {
  z-index: 9999;
  background: rgba(0,0,0,.85);
}

/* ── 21. Shadow utilities (Tailwind v2 supplement) ────────── */
.shadow-card { box-shadow: 0 4px 24px rgba(0,0,0,.08); }
.shadow-hero { box-shadow: 0 20px 60px rgba(0,0,0,.25); }
.shadow-brand{ box-shadow: 0 8px 20px rgba(184,41,47,.35); }

/* ── 22. Mobile drawer ────────────────────────────────────── */
#mobileMenu {
  transform: translateX(100%);
  transition: transform .3s ease;
}
#mobileMenu.open { transform: translateX(0); }

/* ── 23. CTA Section background blob ─────────────────────── */
.cta-blob-tr {
  position: absolute;
  top: -40px; right: -40px;
  width: 192px; height: 192px;
  background: rgba(255,255,255,.1);
  border-radius: 50%;
  filter: blur(24px);
  pointer-events: none;
}
.cta-blob-bl {
  position: absolute;
  bottom: -40px; left: -40px;
  width: 256px; height: 256px;
  background: rgba(255,255,255,.05);
  border-radius: 50%;
  filter: blur(40px);
  pointer-events: none;
}

/* ── 24. About image ──────────────────────────────────────────────────────────────────── */
.about-img {
  height: 600px;
}
@media (max-width: 767px) {
  .about-img {
    height: auto;
    min-height: 280px;
  }
}

/* ── 24b. About Banner ────────────────────────────────────────────────────────────────── */
.about-banner {
  position: relative;
  width: 100%;
  min-height: 220px;
  background: url('../images/homepage/hero_bg.png') center/cover no-repeat;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.about-banner-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    100deg,
    rgba(20, 6, 6, 0.82) 0%,
    rgba(184, 41, 47, 0.72) 55%,
    rgba(20, 6, 6, 0.45) 100%
  );
}
.about-banner-content {
  position: relative;
  z-index: 2;
  width: 100%;
  padding-top: 56px;
  padding-bottom: 56px;
}
.about-banner-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .13em;
  text-transform: uppercase;
  color: rgba(255,255,255,.75);
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.2);
  border-radius: 50px;
  padding: 5px 14px;
  margin-bottom: 18px;
}
.about-banner-title {
  font-size: clamp(1.75rem, 4.5vw, 2.75rem);
  font-weight: 800;
  color: #ffffff;
  line-height: 1.22;
  max-width: 600px;
  margin-bottom: 16px;
  text-shadow: 0 2px 16px rgba(0,0,0,.35);
}
.about-banner-title span {
  color: #ffc0c2;
}
.about-banner-desc {
  font-size: 0.875rem;
  color: rgba(255,255,255,.82);
  max-width: 520px;
  line-height: 1.75;
  margin-bottom: 24px;
}
.about-banner-dots {
  display: flex;
  gap: 8px;
}
.about-banner-dots span {
  display: block;
  height: 4px;
  border-radius: 2px;
  background: rgba(255,255,255,.5);
  transition: all .3s;
}
.about-banner-dots span:nth-child(1) { width: 28px; background: #fff; }
.about-banner-dots span:nth-child(2) { width: 16px; }
.about-banner-dots span:nth-child(3) { width: 10px; }
@media (max-width: 767px) {
  .about-banner { min-height: 160px; }
  .about-banner-content { padding-top: 36px; padding-bottom: 36px; }
  .about-banner-title   { font-size: 1.4rem; }
}

/* ── 24. Footer links ─────────────────────────────────────────────────────────────────── */
.footer-link {
  font-size: .7rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: #5a3a3a;
  transition: color .25s;
  display: inline-block;
}
.footer-link:hover { color: var(--primary); }

/* ── 25. Mobile-specific overrides ───────────────────────── */
@media (max-width: 767px) {

  /* ── Hero ──────────────────────────────────────────────────
     py-20 on the inner grid = 80px top+bottom — way too much.
     Override to compact values so no whitespace bleeds out.    */
  .hero-section .max-w-7xl {
    padding-top: 1.5rem !important;
    padding-bottom: 2rem !important;
    gap: 2rem !important;
  }

  /* Reduce badge + h1 bottom margins */
  .hero-section span.rounded-full { margin-bottom: 0.75rem !important; }
  .hero-section h1               { margin-bottom: 0.5rem !important; }

  /* Reduce description paragraph bottom margin */
  .hero-section p.mb-8           { margin-bottom: 1rem !important; }

  /* Stack hero buttons & reduce their container bottom margin */
  .hero-section .flex.flex-wrap {
    flex-direction: column;
    align-items: flex-start;
    margin-bottom: 0 !important;
  }
  .hero-section .flex.flex-wrap .btn {
    width: 100%;
    justify-content: center;
  }

  /* Shrink hero image on mobile */
  .hero-img-wrapper {
    width: clamp(180px, 60vw, 240px) !important;
    height: clamp(180px, 60vw, 240px) !important;
  }

  /* ── Navbar ─────────────────────────────────────────────── */
  #navCta { display: none !important; }

  /* ── Section defaults ───────────────────────────────────── */
  .section    { padding: 40px 0; }
  .section-sm { padding: 24px 0; }

  /* Section titles — scale down */
  .section-title { font-size: 1.4rem; }

  /* ── Products ───────────────────────────────────────────── */
  #products .flex.flex-col.sm\:flex-row { gap: 0.75rem; }

  /* ── About ──────────────────────────────────────────────── */
  /* Reduce grid gap and fix image height */
  #about .max-w-7xl { gap: 1.5rem !important; }
  .about-img {
    height: 240px !important;
    min-height: unset;
  }
  #about img[style*="height"] {
    height: auto !important;
    min-height: 240px !important;
  }

  /* ── Why Choose Us ──────────────────────────────────────── */
  /* Reduce section padding so bg image sits tight */
  #why-us {
    padding-top: 2.5rem !important;
    padding-bottom: 2.5rem !important;
  }
  /* Background image — only needs to cover the heading block */
  #why-us > div:first-child { height: 240px !important; }

  /* Text block — reduce pt and pb so cards follow closely */
  #why-us .text-center {
    padding-top: 0.5rem !important;
    padding-bottom: 50px !important;
  }
  #why-us .text-center h2 { font-size: clamp(1.4rem, 5vw, 2rem) !important; }

  /* Cards — reduce padding */
  #why-us .grid > div { padding: 1.5rem !important; }

  /* ── Supply Map ─────────────────────────────────────────── */
  #supply {
    padding-top: 2rem !important;
    padding-bottom: 1rem !important;
  }
  #supply .text-center { margin-bottom: 1rem; }
  #supply h2 { font-size: 1.3rem !important; }

  /* ── Gallery ────────────────────────────────────────────── */
  #gallery .flex.items-end.justify-between {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }

  /* ── Process ────────────────────────────────────────────── */
  #process .grid {
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
  }

  /* ── Contact CTA ────────────────────────────────────────── */
  /* py-24 = 6rem each side — reduce to 3rem on mobile */
  #contact-cta {
    padding-top: 3rem !important;
    padding-bottom: 3rem !important;
  }
  #contact-cta h2 { font-size: 1.15rem !important; }

  /* ── Marquee ────────────────────────────────────────────── */
  .marquee-content { gap: 2.5rem; }

  /* ── Footer ─────────────────────────────────────────────── */
  footer .grid { gap: 1.5rem !important; }
}

/* ── XS (≤479px) ──────────────────────────────────────────── */
@media (max-width: 479px) {

  /* Hero heading */
  .hero-section h1 { font-size: 1.65rem !important; }

  /* Hero image even smaller */
  .hero-img-wrapper {
    width: clamp(160px, 55vw, 200px) !important;
    height: clamp(160px, 55vw, 200px) !important;
  }

  /* Process — single column */
  #process .grid { grid-template-columns: 1fr; }

  /* Why choose us bg + cards */
  #why-us > div:first-child { height: 210px !important; }
  #why-us .grid > div       { padding: 1.25rem !important; }
}

/* ── 26. Go To Top Button ─────────────────────────────────── */
#goTopBtn {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--primary);
  color: white;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  box-shadow: var(--shadow-md);
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all var(--transition);
  z-index: 99;
}

#goTopBtn.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

#goTopBtn:hover {
  background: var(--primary-dark);
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

@media (max-width: 767px) {
  #goTopBtn {
    bottom: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    font-size: 1rem;
  }
}

/* ── 27. Quote Modal ──────────────────────────────────────── */
@keyframes quoteSlideIn {
  from {
    opacity: 0;
    transform: translateY(24px) scale(.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Submit button hover — targets the inline-styled submit button */
#quoteForm button[type="submit"]:hover {
  background: var(--primary-dark) !important;
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(184,41,47,.35);
}

/* Close button hover */
#quoteCloseBtn:hover {
  background: rgba(255,255,255,.32) !important;
}

/* Escape key support */
#quoteModal:focus-visible { outline: none; }
