/* ===== Custom Properties ===== */
:root {
  --bg: #FDF8F3;
  --surface: #FFFFFF;
  --text: #2D2019;
  --text-secondary: #7A6E64;
  --text-tertiary: #A89E96;
  --accent: #D4875C;
  --border: #E8E0D8;
  --feeding: #E8B86D;
  --diaper: #E8967D;
  --sleep: #C4A6B8;
  --radius: 20px;
  --radius-pill: 999px;
  --font-display: 'Gabarito', sans-serif;
  --font-body: 'Atkinson Hyperlegible', sans-serif;
  --max-width: 1120px;
}

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

html { scroll-behavior: smooth; }

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

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

a { color: inherit; text-decoration: none; }

/* ===== Utilities ===== */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

.section-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 2rem;
  text-align: center;
  margin-bottom: 48px;
}

/* ===== Fade-in Animation ===== */
.fade-in-up {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Nav ===== */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(253, 248, 243, 0.85);
  transition: background 0.3s, backdrop-filter 0.3s;
}

.nav.scrolled {
  background: rgba(253, 248, 243, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 var(--border);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.nav-logo img { height: 40px; width: auto; }

/* ===== Buttons & Badges ===== */
.btn {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.875rem;
  padding: 10px 24px;
  border-radius: var(--radius-pill);
  background: var(--accent);
  color: #fff;
  transition: transform 0.15s, box-shadow 0.15s;
}

.btn:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(212, 135, 92, 0.25); }

.btn-sm { padding: 8px 20px; font-size: 0.8125rem; }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 20px;
  border-radius: var(--radius-pill);
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 700;
  line-height: 1.2;
  transition: transform 0.15s;
}

.badge span { display: flex; flex-direction: column; text-align: left; }
.badge small { font-size: 0.6875rem; font-weight: 400; opacity: 0.7; }

.badge-muted {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
}

.badge-solid {
  background: var(--accent);
  color: #fff;
}

.badge:hover { transform: translateY(-1px); }

.store-badges { display: flex; gap: 12px; flex-wrap: wrap; }

/* ===== Hero ===== */
.hero {
  padding: 80px 0 64px;
  overflow: hidden;
}

.hero-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 48px;
}

.hero-text { max-width: 520px; text-align: center; }

.hero-headline {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 2.5rem;
  line-height: 1.15;
  margin-bottom: 20px;
}

.hero-sub {
  font-size: 1.125rem;
  color: var(--text-secondary);
  margin-bottom: 32px;
  line-height: 1.6;
}

.hero-text .store-badges { justify-content: center; }

.hero-phone { flex-shrink: 0; }

/* ===== iPhone Frame ===== */
.iphone-frame {
  position: relative;
  width: 270px;
  aspect-ratio: 433 / 882;
  flex-shrink: 0;
  filter: drop-shadow(0 8px 32px rgba(45, 32, 25, 0.12));
}

.iphone-frame-shell {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  pointer-events: none;
}

.iphone-frame img.iphone-screen {
  position: absolute;
  /* Match the screen rect in the SVG: x=21.25 y=19.25 w=389.5 h=843.5 out of 433x882 */
  left: 4.91%;
  top: 2.18%;
  width: 89.95%;
  height: 95.64%;
  object-fit: cover;
  object-position: top;
  border-radius: 14.31% / 6.61%;
  z-index: 1;
}

.iphone-frame-sm { width: 220px; }

/* ===== Problems ===== */
.problems {
  padding: 80px 0;
}

.problem-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

.problem-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px;
  text-align: center;
}

.problem-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #FDF3E0;
  color: var(--accent);
  margin-bottom: 16px;
}

.problem-card h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  margin-bottom: 8px;
}

.problem-card p {
  color: var(--text-secondary);
  font-size: 0.9375rem;
  line-height: 1.6;
}

/* ===== Features ===== */
.features {
  padding: 80px 0;
  background: var(--surface);
}

.feature-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
}

.feature-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 24px;
}

.feature-card h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  margin-bottom: 4px;
}

.feature-card p {
  color: var(--text-secondary);
  font-size: 0.9375rem;
  line-height: 1.6;
  max-width: 300px;
}

/* ===== Values ===== */
.values {
  padding: 80px 0;
}

.values-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.value-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
}

.value-item h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.125rem;
  margin-bottom: 6px;
}

.value-item p {
  color: var(--text-secondary);
  font-size: 0.875rem;
  line-height: 1.5;
}

/* ===== CTA ===== */
.cta {
  padding: 80px 0;
  background: var(--surface);
  text-align: center;
}

.cta-inner { display: flex; flex-direction: column; align-items: center; gap: 24px; }

.cta-icon img { width: 80px; height: 80px; }

.cta-headline {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 2rem;
  max-width: 480px;
}

.store-badges-lg { justify-content: center; }
.store-badges-lg .badge { padding: 14px 28px; font-size: 1rem; }

/* ===== Footer ===== */
.footer {
  background: #2D2019;
  color: #F5EDE6;
  padding: 40px 0;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  text-align: center;
}

.footer-logo-img {
  height: 32px;
  width: auto;
  filter: brightness(0) invert(1) sepia(0.15) saturate(0.5) hue-rotate(10deg);
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-links a {
  font-size: 0.875rem;
  color: var(--text-tertiary);
  transition: color 0.15s;
}

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

.footer-copy {
  font-size: 0.8125rem;
  color: var(--text-tertiary);
}

/* ===== Responsive: 768px+ ===== */
@media (min-width: 768px) {
  .hero-inner {
    flex-direction: row;
    text-align: left;
    gap: 48px;
  }

  .hero-text { text-align: left; }
  .hero-text .store-badges { justify-content: flex-start; }

  .hero-headline { font-size: 3rem; }

  .problem-grid { grid-template-columns: repeat(3, 1fr); }

  .feature-grid { grid-template-columns: repeat(2, 1fr); gap: 40px; }

  .values-grid { grid-template-columns: repeat(3, 1fr); }

  .section-title { font-size: 2.25rem; }

  .footer-inner { flex-direction: row; justify-content: space-between; }
  .footer-copy { order: -1; }
}

/* ===== Responsive: 1024px+ ===== */
@media (min-width: 1024px) {
  .hero { padding: 100px 0 80px; }

  .hero-inner { gap: 64px; }

  .hero-text { flex: 0 0 55%; }
  .hero-phone { flex: 0 0 auto; }

  .hero-headline { font-size: 3.25rem; }

  .feature-grid { grid-template-columns: repeat(3, 1fr); }

  .iphone-frame-sm { width: 240px; }
}
