/* ==============================================================
   FROLOS — brand styles built from your real logo, colors, font
   and mascot artwork.
   ============================================================== */
@font-face {
  font-family: 'Croissant';
  src: url('../assets/fonts/croissant.woff2') format('woff2'),
       url('../assets/fonts/croissant.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Core Frolos brand colors */
  --color-navy:      #25327B; /* brand dark blue */
  --color-yellow:    #FEC124; /* brand yellow */
  --color-white:     #FFFFFF; /* brand white */

  /* Working aliases used throughout this file */
  --color-primary:   var(--color-navy);
  --color-secondary: var(--color-yellow);
  --color-cream:     #FFFDF7; /* near-white page background, easier on the eyes than pure white */
  --color-ink:       var(--color-navy);

  /* Decorative accent colors, sampled from the Frolos logo artwork
     (used for blobs/gallery tiles, not tied to specific flavors). */
  --flavor-orange: #F8A920;
  --flavor-green:  #7CCA29;
  --flavor-purple: #6E1E71;
  --flavor-cream:  #F3EFC9;
  --flavor-pink:   #D9115A;
  --flavor-teal:   #3AA89F;

  /* Real product flavor colors */
  --flavor-chocolate:   #6B3F2A;
  --flavor-strawberry:  #D9115A;
  --flavor-mango:       #FDBB2D;
  --flavor-cremesoda:   #7CCA29;
  --flavor-raspberry:   #A61257;
  --flavor-tuttifruity: #8E3FA8;
  --flavor-cola:        #2B1B12;
  --flavor-pineapple:   #FFD447;
  --flavor-bubblegum:   #6EC6E0;

  --font-display: 'Croissant', system-ui, sans-serif;
  --font-body: 'Poppins', system-ui, sans-serif;

  --radius-lg: 28px;
  --radius-md: 18px;
  --shadow-soft: 0 20px 40px -14px rgba(31,34,51,0.25);
  --ease-bounce: cubic-bezier(.34,1.56,.64,1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--color-ink);
  background: var(--color-cream);
  overflow-x: hidden;
}
h1,h2,h3 { font-family: var(--font-display); margin: 0; line-height: 1.05; }
p { line-height: 1.6; }
a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }

.eyebrow {
  font-family: var(--font-display);
  letter-spacing: .12em;
  font-size: .8rem;
  color: var(--color-primary);
  font-weight: 600;
  margin: 0 0 .6rem;
}
.highlight { color: var(--color-primary); }

/* ---------- Reveal-on-scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .7s ease, transform .7s var(--ease-bounce);
}
.reveal.in-view { opacity: 1; transform: translateY(0); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
  padding: .95rem 1.8rem;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  transition: transform .25s var(--ease-bounce), box-shadow .25s ease;
}
.btn-primary {
  background: var(--color-secondary);
  color: var(--color-navy);
  box-shadow: 0 12px 24px -8px rgba(254,193,36,.7);
}
.btn-primary:hover { transform: translateY(-4px) scale(1.03); box-shadow: 0 18px 30px -10px rgba(254,193,36,.75); }
.btn-ghost {
  background: transparent;
  border: 2px solid var(--color-ink);
  padding: .85rem 1.7rem;
}
.btn-ghost:hover { background: var(--color-ink); color: #fff; transform: translateY(-4px); }

/* ================= NAV ================= */
.site-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 1.1rem 0;
  transition: background .3s ease, padding .3s ease, box-shadow .3s ease;
}
.site-nav.scrolled {
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(10px);
  padding: .5rem 0;
  box-shadow: 0 6px 20px -10px rgba(37,50,123,.18);
}
.nav-inner {
  max-width: 1180px; margin: 0 auto; padding: 0 1.6rem;
  display: flex; align-items: center; justify-content: space-between;
}
.nav-logo { display: flex; align-items: center; }
.nav-logo-img { height: 56px; width: auto; transition: height .3s ease; }
.site-nav.scrolled .nav-logo-img { height: 42px; }
.logo-text {
  font-family: var(--font-display); font-weight: 700; font-size: 1.5rem;
  color: var(--color-ink);
}
.drip { color: var(--color-secondary); }
.nav-links { display: flex; gap: 2rem; }
.nav-links a {
  font-weight: 500; font-size: .95rem; position: relative; padding: .2rem 0;
}
.nav-links a::after {
  content: ""; position: absolute; left: 0; bottom: -4px; height: 3px; width: 0;
  background: var(--color-primary); border-radius: 2px; transition: width .25s ease;
}
.nav-links a:hover::after { width: 100%; }
.nav-toggle {
  display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 6px;
}
.nav-toggle span { width: 24px; height: 3px; background: var(--color-ink); border-radius: 2px; transition: transform .3s ease, opacity .3s ease; }

/* ================= HERO ================= */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  text-align: center;
  padding: 7rem 1.5rem 4rem;
  overflow: hidden;
  background: linear-gradient(180deg, #FFF3D6 0%, var(--color-cream) 70%);
}
.hero-bg { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.blob { position: absolute; border-radius: 50%; filter: blur(4px); opacity: .5; animation: float-blob 10s ease-in-out infinite; }
.blob-1 { width: 320px; height: 320px; background: var(--flavor-teal); top: -60px; left: -80px; animation-duration: 12s; }
.blob-2 { width: 260px; height: 260px; background: var(--color-secondary); bottom: -60px; right: -40px; animation-duration: 9s; }
.blob-3 { width: 180px; height: 180px; background: var(--flavor-pink); bottom: 20%; left: 8%; animation-duration: 14s; }
@keyframes float-blob {
  0%,100% { transform: translate(0,0) scale(1); }
  50% { transform: translate(20px,-30px) scale(1.08); }
}
.sun { position: absolute; top: 8%; right: 10%; width: 110px; animation: spin-slow 22s linear infinite; }
.sun-svg { width: 100%; height: 100%; }
@keyframes spin-slow { to { transform: rotate(360deg); } }

.floaty {
  position: absolute; font-size: 2.4rem; filter: drop-shadow(0 8px 12px rgba(0,0,0,.12));
  will-change: transform;
}
.floaty-1 { top: 20%; left: 10%; }
.floaty-2 { top: 65%; left: 16%; font-size: 2.8rem; }
.floaty-4 { top: 72%; right: 20%; font-size: 2rem; }
.floaty-5 { top: 12%; left: 45%; font-size: 2.1rem; }

.hero-mascot {
  bottom: -1%; right: 3%; width: min(260px, 26vw);
}
.hero-mascot-inner {
  display: block; width: 100%;
  filter: drop-shadow(0 18px 24px rgba(37,50,123,.25));
  animation: mascot-bob 4.5s ease-in-out infinite;
}
@keyframes mascot-bob {
  0%,100% { transform: translateY(0); }
  50% { transform: translateY(-14px); }
}
@media (max-width: 720px) {
  .hero-mascot { width: 130px; right: 2%; bottom: 2%; }
}

.hero-content { position: relative; z-index: 2; max-width: 720px; }
.hero-logo { width: min(360px, 70vw); margin: 0 auto 1.4rem; animation: logo-pop .8s var(--ease-bounce) both .1s; }
@keyframes logo-pop { from { opacity: 0; transform: scale(.85) translateY(14px); } to { opacity: 1; transform: scale(1) translateY(0); } }
.hero-title {
  font-size: clamp(2.6rem, 7vw, 5rem);
  font-weight: 700;
  color: var(--color-ink);
}
.hero-title-accent { color: var(--color-secondary); -webkit-text-stroke: 1.5px var(--color-navy); }
.hero-sub { font-size: 1.15rem; max-width: 540px; margin: 1.3rem auto 2rem; color: #4b4e63; }
.hero-cta-row { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

.scroll-cue {
  position: absolute; bottom: 2rem; left: 50%; transform: translateX(-50%);
  width: 26px; height: 42px; border: 2px solid var(--color-ink); border-radius: 20px;
  display: flex; justify-content: center; padding-top: 8px; z-index: 2;
}
.scroll-cue span { width: 5px; height: 8px; background: var(--color-secondary); border-radius: 3px; animation: scroll-dot 1.6s ease infinite; }
@keyframes scroll-dot { 0% { opacity:1; transform: translateY(0);} 70% {opacity:0; transform: translateY(12px);} 100%{opacity:0;} }

/* ================= MARQUEE ================= */
.marquee {
  background: var(--color-ink); color: var(--color-cream);
  overflow: hidden; white-space: nowrap; padding: .9rem 0;
}
.marquee-track { display: inline-flex; animation: marquee-scroll 18s linear infinite; }
.marquee-track span {
  font-family: var(--font-display); font-weight: 600; font-size: 1.1rem; letter-spacing: .04em;
  padding-right: 1rem;
}
@keyframes marquee-scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ================= SECTIONS shared ================= */
.section-title { font-size: clamp(1.9rem, 4vw, 2.8rem); text-align: center; margin-top: 5rem; }
.section-sub { text-align: center; color: #6a6d82; max-width: 480px; margin: .8rem auto 3rem; }

/* ================= FLAVORS / PRODUCTS ================= */
.flavors { padding: 2rem 1.5rem 4rem; max-width: 1180px; margin: 0 auto; }

.product-tabs {
  display: flex; justify-content: center; gap: .9rem; flex-wrap: wrap;
  margin: 0 auto 3rem;
}
.tab-btn {
  font-family: var(--font-display); font-size: 1.05rem; letter-spacing: .02em;
  padding: .8rem 1.7rem; border-radius: 999px; border: 2px solid var(--color-navy);
  background: #fff; color: var(--color-navy); cursor: pointer;
  transition: transform .25s var(--ease-bounce), background .25s ease, color .25s ease, box-shadow .25s ease;
}
.tab-btn:hover { transform: translateY(-3px); }
.tab-btn.active {
  background: var(--color-navy); color: #fff;
  box-shadow: 0 14px 26px -10px rgba(37,50,123,.5);
}

.product-panel { display: none; }
.product-panel.active { display: block; animation: panel-in .5s var(--ease-bounce); }
@keyframes panel-in {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

.flavor-group { margin-bottom: 2.8rem; }
.flavor-group:last-child { margin-bottom: 0; }
.flavor-group-title {
  font-family: var(--font-display); font-size: 1.3rem; color: var(--color-navy);
  text-align: center; margin-bottom: 1.3rem;
}
.flavor-group-title .tag {
  font-family: var(--font-body); font-weight: 600; font-size: .68rem; letter-spacing: .06em;
  background: var(--color-yellow); color: var(--color-navy);
  padding: .25rem .65rem; border-radius: 999px; margin-left: .5rem; vertical-align: middle;
}
.flavor-grid.single { grid-template-columns: minmax(220px, 280px); justify-content: center; }

.flavor-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.6rem;
}
.flavor-card {
  background: #fff; border-radius: var(--radius-lg); padding: 2rem 1.6rem;
  text-align: center; box-shadow: var(--shadow-soft);
  border-bottom: 6px solid var(--card-color);
  transition: transform .12s ease, box-shadow .3s ease;
  will-change: transform;
}
.flavor-card:hover { box-shadow: 0 26px 46px -16px rgba(0,0,0,.28); }
.flavor-emoji { font-size: 3rem; margin-bottom: .8rem; }
.flavor-card h3 { font-size: 1.2rem; margin-bottom: .4rem; }
.flavor-card p { color: #6a6d82; font-size: .92rem; margin: 0; }

/* ================= ABOUT ================= */
.about { background: #fff; padding: 5rem 1.5rem; }
.about-inner {
  max-width: 1080px; margin: 0 auto; display: grid; grid-template-columns: 1fr 1.2fr; gap: 3.5rem; align-items: center;
}
.about-visual { position: relative; aspect-ratio: 1; display: flex; align-items: center; justify-content: center; }
.about-blob {
  position: absolute; inset: 0; border-radius: 42% 58% 65% 35% / 45% 40% 60% 55%;
  background: linear-gradient(135deg, var(--flavor-teal), var(--color-navy));
  opacity: .16; animation: morph 8s ease-in-out infinite;
}
@keyframes morph {
  0%,100% { border-radius: 42% 58% 65% 35% / 45% 40% 60% 55%; }
  50% { border-radius: 60% 40% 35% 65% / 55% 60% 40% 45%; }
}
.about-emoji { font-size: 7rem; position: relative; z-index: 1; }
.about-mascot { width: 62%; position: relative; z-index: 1; filter: drop-shadow(0 16px 20px rgba(37,50,123,.2)); }
.about-copy h2 { font-size: clamp(1.8rem,3.4vw,2.4rem); margin-bottom: 1rem; }
.about-copy p { color: #4b4e63; }
.stat-row { display: flex; gap: 2.2rem; margin-top: 2rem; flex-wrap: wrap; }
.stat strong { display: block; font-family: var(--font-display); font-size: 1.8rem; color: var(--color-primary); }
.stat strong .pct { font-family: var(--font-body); } /* Croissant's % glyph is blank — use the body font for it */
.stat span { font-size: .85rem; color: #6a6d82; }

/* ================= GALLERY ================= */
.gallery { padding: 2rem 1.5rem 5rem; max-width: 1180px; margin: 0 auto; }
.gallery-grid { display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: 160px; gap: 1rem; }
.gallery-tile {
  background: var(--tile-color); border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center; font-size: 2.4rem;
  opacity: .85; transition: transform .3s var(--ease-bounce), opacity .3s ease;
}
.gallery-tile:hover { transform: scale(1.04) rotate(-1deg); opacity: 1; }
.gallery-tile.tall { grid-row: span 2; }

/* ================= CONTACT ================= */
.contact { position: relative; background: var(--color-ink); color: #fff; padding-top: 1px; overflow: hidden; }
.contact-mascot {
  position: absolute; left: 2%; bottom: 0; width: min(190px, 20vw);
  z-index: 1; filter: drop-shadow(0 -6px 18px rgba(0,0,0,.25));
}
.contact-mascot img { width: 100%; display: block; }
@media (max-width: 640px) { .contact-mascot { width: 110px; opacity: .85; } }
.wave-divider { line-height: 0; margin-top: -1px; }
.wave-divider svg { width: 100%; height: 90px; }
.wave-divider path { fill: var(--color-ink); }
.contact-inner { max-width: 620px; margin: 0 auto; text-align: center; padding: 3rem 1.5rem 2rem; }
.contact-inner h2 { font-size: clamp(1.9rem,4vw,2.6rem); margin: .4rem 0 1rem; }
.contact-sub { color: #c8c9db; margin-bottom: 1.8rem; }
.social-row { display: flex; gap: 1rem; justify-content: center; margin-top: 1.6rem; }
.social-btn {
  width: 46px; height: 46px; border-radius: 50%; background: rgba(255,255,255,.1);
  display: flex; align-items: center; justify-content: center; font-size: .8rem; font-weight: 700;
  transition: background .25s ease, transform .25s var(--ease-bounce);
}
.social-btn:hover { background: var(--color-secondary); color: var(--color-navy); transform: translateY(-4px); }
.site-footer { text-align: center; padding: 1.6rem 1rem 2rem; font-size: .82rem; color: #9698ab; }

/* ================= CONFETTI CANVAS ================= */
#confettiCanvas {
  position: fixed; inset: 0; pointer-events: none; z-index: 9999;
}

/* ================= RESPONSIVE ================= */
@media (max-width: 860px) {
  .about-inner { grid-template-columns: 1fr; text-align: center; }
  .stat-row { justify-content: center; }
  .about-visual { max-width: 260px; margin: 0 auto; }
}
@media (max-width: 720px) {
  .nav-links { position: fixed; top: 0; right: 0; height: 100vh; width: min(78vw, 300px);
    background: var(--color-cream); flex-direction: column; justify-content: center; align-items: center; gap: 2.2rem;
    transform: translateX(100%); transition: transform .35s var(--ease-bounce); box-shadow: -10px 0 30px rgba(0,0,0,.12);
  }
  .nav-links.open { transform: translateX(0); }
  .nav-toggle { display: flex; z-index: 200; }
  .nav-toggle.open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
  .nav-toggle.open span:nth-child(2) { opacity: 0; }
  .nav-toggle.open span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .floaty { font-size: 1.7rem; }
  .nav-logo-img { height: 44px; }
  .site-nav.scrolled .nav-logo-img { height: 36px; }
  /* Keep floaties clear of the taller mobile text column */
  .floaty-2, .floaty-4 { display: none; }
  .floaty-1 { top: 6%; left: 4%; }
  .floaty-3 { top: 6%; right: 4%; }
  .floaty-5 { top: 2%; left: 42%; }
}
@media (max-width: 480px) {
  .gallery-grid { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 130px; }
  .hero-cta-row { flex-direction: column; align-items: stretch; }
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  html { scroll-behavior: auto; }
}
