/* ============================================
   Liddy Store – Design System
   ============================================ */

@font-face {
  font-family: 'Rounded Elegance';
  src: url('Rounded_Elegance.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #ffffff;
  --ink: #0f172a;
  --muted: #64748b;
  --brand: #687690;
  --brand-dark: #58647a;
  --accent: #10b981;
  --line: #e5e7eb;
  --panel: #f8fafc;
  --warm: #fef9f3;
  --radius: 16px;
  --max-w: 1100px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'Rounded Elegance', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ---- Layout ---- */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }
section { padding: 80px 0; }

/* ---- Navigation ---- */
.nav {
  position: sticky;
  top: 0;
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  z-index: 100;
  padding: 12px 0;
}
.nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-logo img { height: 52px; }
.nav-links { display: flex; gap: 24px; align-items: center; }
.nav-links a { color: var(--ink); font-weight: 500; font-size: 15px; }
.nav-links a:hover { color: var(--brand); text-decoration: none; }
.nav-cta {
  background: var(--ink);
  color: #fff !important;
  padding: 8px 20px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 14px;
  transition: background 0.2s;
}
.nav-cta:hover { background: var(--brand); text-decoration: none !important; }

/* ---- Hero ---- */
.hero {
  padding: 100px 0 80px;
  text-align: center;
  background: linear-gradient(180deg, var(--warm) 0%, var(--bg) 100%);
}
.hero h1 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.1;
  margin: 0 0 16px;
  letter-spacing: -0.02em;
}
.hero .tagline {
  font-size: clamp(1.1rem, 2.5vw, 1.4rem);
  color: var(--muted);
  margin: 0 0 32px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}
.hero-cta {
  display: inline-block;
  background: var(--ink);
  color: #fff;
  padding: 16px 40px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 18px;
  transition: transform 0.2s, background 0.2s;
}
.hero-cta:hover { background: var(--brand); transform: translateY(-2px); text-decoration: none; }
.hero-sub {
  margin-top: 12px;
  font-size: 14px;
  color: var(--muted);
}
.hero-media {
  margin-top: 48px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}
.hero-media video {
  width: 100%;
  border-radius: var(--radius);
}

/* ---- Trust Bar ---- */
.trust-bar {
  padding: 24px 0;
  background: var(--panel);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.trust-items {
  display: flex;
  justify-content: center;
  gap: 40px;
  flex-wrap: wrap;
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
}
.trust-items span { display: flex; align-items: center; gap: 6px; }

/* ---- Problem / Before-After ---- */
.problem { background: var(--warm); }
.problem h2 { text-align: center; }
.problem .subtitle { text-align: center; color: var(--muted); margin-bottom: 48px; }
.before-after-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  max-width: 800px;
  margin: 0 auto;
}
.ba-card {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
}
.ba-card img {
  width: 100%;
  aspect-ratio: 16/10;
  object-fit: cover;
}
.ba-card .ba-label {
  padding: 12px 16px;
  font-weight: 700;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.ba-card.before .ba-label { background: #fef2f2; color: #dc2626; }
.ba-card.after .ba-label { background: #ecfdf5; color: var(--accent); }

/* Placeholder card for adding more before/after images */
.ba-add {
  border: 2px dashed var(--line);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 200px;
  color: var(--muted);
  font-size: 14px;
  /* DEVELOPER NOTE: Duplicate a .ba-card block above to add more before/after images */
}

/* ---- Product / What's in the Box ---- */
.product { background: var(--bg); }

/* ---- Stats / Why Liddy ---- */
.stats { background: var(--bg); }
.stats h2 { text-align: center; }
.stats .subtitle { text-align: center; color: var(--muted); margin-bottom: 48px; }
.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.stat-card {
  text-align: center;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px 24px;
}
.stat-number {
  font-size: clamp(2.5rem, 5vw, 3.5rem);
  font-weight: 800;
  color: var(--brand);
  line-height: 1;
  margin-bottom: 8px;
}
.stat-label {
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 12px;
}
.stat-desc {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.6;
  margin: 0;
}

@media (max-width: 768px) {
  .stats-grid { grid-template-columns: 1fr; }
}

/* ---- Product cards ---- */
.product h2 { text-align: center; margin-bottom: 8px; }
.product .subtitle { text-align: center; color: var(--muted); margin-bottom: 48px; }
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}
.product-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.2s, box-shadow 0.2s;
}
.product-card:hover { transform: translateY(-4px); box-shadow: 0 12px 40px rgba(0,0,0,0.1); }
.product-card img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
}
.product-card-body { padding: 20px; }
.product-card h3 { margin: 0 0 8px; font-size: 20px; }
.product-card p { margin: 0 0 16px; color: var(--muted); font-size: 15px; }
.product-card .price { font-size: 24px; font-weight: 800; color: var(--ink); }

/* Stripe button container */
.stripe-btn { margin-top: 16px; }

/* ---- Gallery ---- */
.gallery { background: var(--panel); }
.gallery h2 { text-align: center; margin-bottom: 40px; }
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}
.gallery-grid img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  border-radius: 12px;
  cursor: pointer;
  transition: transform 0.2s;
}
.gallery-grid img:hover { transform: scale(1.02); }

/* ---- Reviews ---- */
.reviews { background: var(--bg); }
.reviews h2 { text-align: center; margin-bottom: 40px; }
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
}
.review-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}
.review-stars { color: #f59e0b; font-size: 18px; margin-bottom: 12px; }
.review-text { font-size: 15px; line-height: 1.7; margin-bottom: 16px; }
.review-author {
  display: flex;
  align-items: center;
  gap: 12px;
}
.review-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--line);
}
/* Placeholder avatar when no photo is uploaded yet */
.review-avatar-placeholder {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  flex-shrink: 0;
}
.review-name { font-weight: 600; font-size: 14px; }
.review-badge { font-size: 12px; color: var(--accent); font-weight: 600; }

/* ---- FAQ ---- */
.faq { background: var(--panel); }
.faq h2 { text-align: center; margin-bottom: 40px; }
.faq-list { max-width: 700px; margin: 0 auto; }
.faq-item {
  border-bottom: 1px solid var(--line);
  padding: 20px 0;
}
.faq-q {
  font-weight: 700;
  font-size: 17px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.faq-q::after {
  content: '+';
  font-size: 24px;
  font-weight: 300;
  color: var(--muted);
  transition: transform 0.2s;
}
.faq-item.open .faq-q::after { content: '−'; }
.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
}
.faq-item.open .faq-a { max-height: 300px; padding-top: 12px; }

/* ---- CTA Banner ---- */
.cta-banner {
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  color: #fff;
  text-align: center;
  padding: 60px 24px;
}
.cta-banner h2 { font-size: clamp(1.5rem, 4vw, 2.5rem); margin: 0 0 12px; }
.cta-banner p { margin: 0 0 24px; opacity: 0.9; font-size: 18px; }
.cta-banner-btn {
  display: inline-block;
  background: #fff;
  color: var(--ink);
  padding: 14px 36px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 16px;
  transition: transform 0.2s;
}
.cta-banner-btn:hover { transform: translateY(-2px); text-decoration: none; }

/* ---- Footer ---- */
.footer {
  background: var(--ink);
  color: #94a3b8;
  padding: 48px 0 32px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 32px;
}
.footer-brand img { height: 36px; margin-bottom: 12px; filter: brightness(10); }
.footer-brand p { font-size: 14px; line-height: 1.7; }
.footer h4 { color: #fff; font-size: 14px; text-transform: uppercase; letter-spacing: 0.08em; margin: 0 0 16px; }
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: 8px; }
.footer-links a { color: #94a3b8; font-size: 14px; }
.footer-links a:hover { color: #fff; }
.footer-social { display: flex; gap: 16px; margin-top: 12px; }
.footer-social a {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 16px;
  transition: background 0.2s;
}
.footer-social a:hover { background: var(--brand); text-decoration: none; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 24px;
  text-align: center;
  font-size: 13px;
}

/* ---- Lightbox ---- */
.lightbox {
  display: none;
  position: fixed;
  z-index: 1000;
  inset: 0;
  background: rgba(0,0,0,0.92);
  animation: fadeIn 0.3s ease;
}
.lightbox-content {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  max-width: 90%;
  max-height: 90%;
  border-radius: 8px;
  object-fit: contain;
}
.lightbox-close {
  position: absolute;
  top: 20px; right: 28px;
  color: #fff;
  font-size: 36px;
  cursor: pointer;
  z-index: 1001;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* ---- Section Headings ---- */
h2 {
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  font-weight: 800;
  margin: 0 0 8px;
}
.subtitle {
  font-size: 16px;
  color: var(--muted);
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* ---- Mobile Nav Toggle ---- */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--ink);
  padding: 4px;
}

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 768px) {
  section { padding: 56px 0; }

  .nav-toggle { display: block; }
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    background: #fff;
    flex-direction: column;
    padding: 16px 24px;
    border-bottom: 1px solid var(--line);
    gap: 16px;
  }
  .nav-links.open { display: flex; }

  .hero { padding: 60px 0 48px; }
  .hero-media { margin-top: 32px; }

  .trust-items { gap: 20px; font-size: 13px; }

  .footer-grid { grid-template-columns: 1fr; gap: 32px; }

  .product-grid { grid-template-columns: 1fr; }
  .reviews-grid { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 480px) {
  .container { padding: 0 16px; }
  .gallery-grid { grid-template-columns: 1fr; }
}
