/* =========================================================================
   Boopsy — marketing site styles
   Display: Cal Sans · Body: Figtree · Light, clean, modern.
   ========================================================================= */

@font-face {
  font-family: "Cal Sans";
  src: url("fonts/CalSans-SemiBold.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Figtree";
  src: url("fonts/Figtree.woff2") format("woff2");
  font-weight: 300 900; /* variable */
  font-style: normal;
  font-display: swap;
}

:root {
  /* palette — light & warm */
  --bg: #ffffff;
  --bg-soft: #f6f7f4;       /* warm off-white section */
  --bg-tint: #eef4ff;       /* faint blue wash */
  --ink: #1f2430;
  --ink-soft: #545b66;
  --ink-faint: #8a909b;
  --primary: #2563eb;
  --primary-700: #1d4ed8;
  --primary-50: #eaf1fe;
  --accent: #f6a723;        /* warm amber */
  --accent-soft: #fff3dd;
  --border: #e9eaed;
  --card: #ffffff;

  --r: 14px;
  --r-lg: 22px;
  --r-xl: 30px;
  --shadow-sm: 0 1px 2px rgba(20, 24, 34, 0.05), 0 1px 3px rgba(20, 24, 34, 0.06);
  --shadow-md: 0 10px 30px -12px rgba(20, 24, 34, 0.18);
  --shadow-lg: 0 30px 60px -20px rgba(20, 24, 34, 0.28);
  --maxw: 1120px;
  --header-h: 72px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Figtree", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  font-size: 18px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
h1, h2, h3, .display {
  font-family: "Cal Sans", "Figtree", sans-serif;
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin: 0 0 0.4em;
  text-wrap: balance; /* avoid one-word widows on the last line of headings */
}
h1 { font-size: clamp(2.6rem, 6vw, 4.4rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }
h3 { font-size: clamp(1.3rem, 2.4vw, 1.6rem); }
p { margin: 0 0 1rem; color: var(--ink-soft); }
/* balance lead + descriptive copy so a line never ends on a single-word widow */
.lead, .section-head p, .cta p, .pain p, .pcard p, .feature .f-text p { text-wrap: balance; }
a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--primary-700); }
img { max-width: 100%; display: block; }

.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: 24px; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-weight: 700; font-size: 0.8rem; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--primary); background: var(--primary-50);
  padding: 7px 14px; border-radius: 999px;
}
.lead { font-size: 1.2rem; color: var(--ink-soft); max-width: 60ch; }
.muted { color: var(--ink-faint); }
.center { text-align: center; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-weight: 700; font-size: 1rem; cursor: pointer;
  padding: 10px 24px; border-radius: 13px; border: 1.5px solid transparent;
  transition: transform 0.12s ease, box-shadow 0.2s ease, background 0.2s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--primary); color: #fff; box-shadow: var(--shadow-md); }
.btn-primary:hover { background: var(--primary-700); color: #fff; }
.btn-ghost { background: transparent; border-color: var(--border); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink-faint); color: var(--ink); }

/* ---------- store badges (official artwork) ---------- */
.stores { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; }
.store-link { display: inline-block; transition: transform 0.12s ease, opacity 0.2s ease; }
.store-link:hover { transform: translateY(-2px); opacity: 0.9; }
/* Both badges are trimmed to tight bounds, so equal height = equal visual size.
   (Google ends up a little wider, which is expected and fine.) */
.badge-img { width: auto; display: block; height: 48px; }

/* ---------- header / nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--border);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); }
.brand { display: inline-flex; align-items: center; gap: 11px; }
.brand .logomark {
  width: 38px; height: 38px; border-radius: 11px;
  background: linear-gradient(150deg, var(--primary), #5b8df0);
  display: grid; place-items: center; box-shadow: var(--shadow-sm);
}
.brand .logomark svg { width: 23px; height: 23px; }
.brand .wordmark { font-family: "Cal Sans"; font-size: 1.5rem; color: var(--ink); letter-spacing: -0.01em; }
.brand-logo { height: 30px; width: auto; display: block; }
.nav-links { display: flex; align-items: center; gap: 30px; }
.nav-links a:not(.btn) { color: var(--ink-soft); font-weight: 600; font-size: 0.98rem; }
.nav-links a:not(.btn):hover { color: var(--ink); }
.nav-toggle {
  display: none; background: none; border: 1.5px solid var(--border); border-radius: 11px;
  width: 44px; height: 44px; cursor: pointer; align-items: center; justify-content: center;
}
.nav-toggle svg { width: 24px; height: 24px; color: var(--ink); }

/* ---------- sections ---------- */
section { padding: clamp(64px, 9vw, 120px) 0; }
.section-soft { background: var(--bg-soft); }
.section-head { max-width: 720px; margin: 0 auto 56px; text-align: center; }
.section-head p { font-size: 1.15rem; }

/* ---------- hero ---------- */
.hero { position: relative; padding-top: clamp(48px, 7vw, 88px); padding-bottom: clamp(48px, 7vw, 88px); overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 56px; align-items: center; }
.hero h1 { margin-top: 18px; }
.hero .lead { margin-top: 8px; margin-bottom: 28px; font-size: 1.28rem; }
.hero-cta { display: flex; flex-direction: column; gap: 16px; }
.hero-note { font-size: 0.92rem; color: var(--ink-faint); }
.hero-visual { position: relative; display: grid; place-items: center; }
.hero-visual::before {
  content: ""; position: absolute; inset: -8% -12%;
  background: radial-gradient(60% 60% at 60% 35%, var(--bg-tint), transparent 70%);
  z-index: 0;
}
.hero-visual .phone { position: relative; z-index: 1; }

/* scattered dog-face pattern behind the hero (built + animated in script.js) */
.hero > .container { position: relative; z-index: 1; }
.hero-pattern { position: absolute; top: -25%; left: 0; right: 0; height: 150%; z-index: 0; overflow: hidden; pointer-events: none; will-change: transform; }
.hero-pattern img { position: absolute; opacity: 0; transition: opacity 0.9s ease; animation: dogFloat var(--fd, 6s) ease-in-out infinite; animation-delay: var(--fdelay, 0s); }
@keyframes dogFloat {
  0%, 100% { transform: translateY(0) rotate(var(--r, 0deg)); }
  50% { transform: translateY(-9px) rotate(var(--r, 0deg)); }
}
@media (prefers-reduced-motion: reduce) { .hero-pattern img { animation: none; } }

/* ---------- phone mockups (placeholders) ---------- */
.phone {
  width: 280px; aspect-ratio: 9 / 19.3;
  background: #1b1f27; border-radius: 40px; padding: 11px;
  box-shadow: var(--shadow-lg); border: 1px solid #2b313c;
}
.phone .screen {
  position: relative; width: 100%; height: 100%; border-radius: 30px; overflow: hidden;
  background: linear-gradient(170deg, #eaf1fe, #f6f7f4 60%, #fff);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 22px; gap: 10px;
}
.phone .screen::after {                       /* notch */
  content: ""; position: absolute; top: 12px; left: 50%; transform: translateX(-50%);
  width: 38%; height: 22px; background: #1b1f27; border-radius: 999px;
}
.phone .ph-icon {
  width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center;
  background: #fff; color: var(--primary); box-shadow: var(--shadow-sm); margin-bottom: 4px;
}
.phone .ph-icon svg { width: 30px; height: 30px; }
.phone .ph-label { font-family: "Cal Sans"; font-size: 1.15rem; color: var(--ink); }
.phone .ph-sub { font-size: 0.85rem; color: var(--ink-faint); max-width: 80%; }
.phone .ph-tag {
  position: absolute; bottom: 16px; font-size: 0.66rem; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--ink-faint); background: rgba(255,255,255,0.7); padding: 4px 10px; border-radius: 999px;
}
.phone.tilt { transform: rotate(-3deg); }
/* Vary each feature phone's tilt — five identical angles reads as copy-paste.
   General-sibling chains pick out the 2nd, 3rd… .feature regardless of the
   section heading divs around them. */
.feature ~ .feature .phone.tilt { transform: rotate(2.2deg); }
.feature ~ .feature ~ .feature .phone.tilt { transform: rotate(-1.6deg); }
.feature ~ .feature ~ .feature ~ .feature .phone.tilt { transform: rotate(2.7deg); }
.feature ~ .feature ~ .feature ~ .feature ~ .feature .phone.tilt { transform: rotate(-2.2deg); }

/* "Live" phones: an intro placeholder that dissolves into the real app screenshot.
   Reusable — add the .live class to any .phone (hero or feature mockup). */
/* Dynamic Island sits above the screenshot, tucked into its status-bar gap */
.phone.live .screen::after { width: 30%; height: 19px; top: 11px; z-index: 3; }
.phone.live .ph-placeholder {
  position: absolute; inset: 0; z-index: 1;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 22px; gap: 10px;
  transition: opacity 0.65s ease, transform 0.7s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.phone.live .ph-shot {
  position: absolute; inset: 0; z-index: 2;
  width: 100%; height: 100%; object-fit: cover; object-position: top center;
  opacity: 0; transform: scale(1.045);
  transition: opacity 0.85s ease, transform 1s cubic-bezier(0.2, 0.7, 0.2, 1);
  pointer-events: none;
}
.phone.live.revealed .ph-placeholder { opacity: 0; transform: scale(0.94); }
.phone.live.revealed .ph-shot { opacity: 1; transform: scale(1); }
/* a soft "live/searching" pulse on the pin while the placeholder is showing */
.phone.live:not(.revealed) .ph-icon { animation: phPulse 1.8s ease-in-out infinite; }
@keyframes phPulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.06); } }
@media (prefers-reduced-motion: reduce) {
  .phone.live .ph-placeholder, .phone.live .ph-shot { transition: none; }
  .phone.live:not(.revealed) .ph-icon { animation: none; }
}

/* ---------- problem ---------- */
.problem-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 8px; }
.pain {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--r-lg);
  padding: 26px; box-shadow: var(--shadow-sm);
  display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center;
}
.pain .p-icon { width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center; background: var(--primary-50); color: var(--primary); }
.pain .p-icon svg { width: 24px; height: 24px; }
.pain h3 { font-size: 1.15rem; margin: 12px 0 6px; }
.pain p { font-size: 0.98rem; margin: 0; }

/* ---------- features ---------- */
.feature { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.feature + .feature { margin-top: clamp(64px, 8vw, 110px); }
.feature.reverse .f-text { order: 2; }
.feature .f-num {
  font-family: "Cal Sans"; font-size: 1rem; color: var(--accent);
  background: var(--accent-soft); width: 40px; height: 40px; border-radius: 12px;
  display: grid; place-items: center; margin-bottom: 18px;
}
.feature h2 { font-size: clamp(1.7rem, 3vw, 2.3rem); }
.feature .f-text p { font-size: 1.1rem; }
.feature ul { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 10px; }
.feature ul li { display: flex; gap: 10px; align-items: flex-start; color: var(--ink-soft); font-size: 1rem; }
.feature ul li svg { width: 20px; height: 20px; color: var(--primary); flex: none; margin-top: 3px; }
.f-visual { display: grid; place-items: center; }

/* ---------- privacy band ---------- */
.privacy-band { background: linear-gradient(180deg, var(--bg-soft), #fff); }
.privacy-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-top: 44px; }
.pcard { text-align: left; }
.pcard .pc-icon {
  width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center;
  background: var(--primary-50); color: var(--primary); margin-bottom: 14px;
}
.pcard .pc-icon svg { width: 24px; height: 24px; }
.pcard h3 { font-size: 1.1rem; margin-bottom: 6px; }
.pcard p { font-size: 0.95rem; margin: 0; }

/* ---------- pricing / compare ---------- */
.price-tag { display: inline-flex; align-items: baseline; gap: 6px; margin-top: 4px; }
.price-tag .amt { font-family: "Cal Sans"; font-size: 2.3rem; color: var(--ink); line-height: 1; }
.price-tag .per { color: var(--ink-soft); font-weight: 600; }
.compare {
  max-width: 740px; margin: 44px auto 0; background: var(--card);
  border: 1px solid var(--border); border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow-md);
}
.compare table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.compare th, .compare td { padding: 14px 18px; text-align: left; border-bottom: 1px solid var(--border); }
.compare tr:last-child td { border-bottom: none; }
.compare thead th { font-weight: 800; font-size: 0.96rem; color: var(--ink); background: var(--bg-soft); }
.compare thead th.col { text-align: center; width: 160px; }
.compare thead th.premium { color: var(--primary); }
.compare td.feat { color: var(--ink-soft); font-weight: 600; font-size: 0.98rem; }
.compare td.cell { text-align: center; }
.compare td.cell.premium { background: var(--primary-50); }
.compare .val { font-weight: 700; color: var(--ink); font-size: 0.9rem; white-space: nowrap; }
.compare .val.up { color: var(--primary); }
.compare .yes { color: #16a34a; }   /* included */
.compare .no { color: var(--ink-faint); } /* not included */
.compare svg { width: 19px; height: 19px; vertical-align: middle; }
.pricing-note { text-align: center; color: var(--ink-faint); font-size: 0.9rem; margin-top: 18px; }

/* ---------- final CTA ---------- */
.cta {
  background: linear-gradient(150deg, #1f3a8a, var(--primary) 55%, #4f86f2);
  border-radius: var(--r-xl); color: #fff; text-align: center;
  padding: clamp(48px, 7vw, 84px) 28px; box-shadow: var(--shadow-lg);
}
.cta h2 { color: #fff; }
.cta p { color: rgba(255, 255, 255, 0.9); font-size: 1.2rem; max-width: 52ch; margin-inline: auto; }
.cta .stores { justify-content: center; margin-top: 28px; }

/* ---------- footer ---------- */
.site-footer { background: #1b1f27; color: #c7cdd6; padding: 64px 0 36px; }
.site-footer a { color: #c7cdd6; }
.site-footer a:hover { color: #fff; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; }
.footer-brand .wordmark { font-family: "Cal Sans"; font-size: 1.5rem; color: #fff; }
.footer-logo { height: 30px; width: auto; display: block; filter: brightness(0) invert(1); }
.footer-brand p { color: #97a0ad; max-width: 34ch; margin-top: 10px; }
.footer-col h4 { font-size: 0.78rem; letter-spacing: 0.1em; text-transform: uppercase; color: #7b8593; margin: 0 0 14px; }
.footer-col a { display: block; padding: 5px 0; font-weight: 500; }
.footer-bottom {
  display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between;
  border-top: 1px solid #2b313c; margin-top: 44px; padding-top: 22px; font-size: 0.88rem; color: #7b8593;
}

/* ---------- legal pages ---------- */
.legal { padding: clamp(48px, 7vw, 90px) 0 80px; }
.legal-wrap { max-width: 820px; margin: 0 auto; }
.legal h1 { font-size: clamp(2.2rem, 5vw, 3.2rem); }
.legal .updated { color: var(--ink-faint); font-size: 0.95rem; margin-bottom: 8px; }
.legal .toc {
  background: var(--bg-soft); border: 1px solid var(--border); border-radius: var(--r-lg);
  padding: 22px 26px; margin: 28px 0 40px;
}
.legal .toc h2 { font-size: 1.1rem; margin-bottom: 12px; }
.legal .toc ol { margin: 0; padding-left: 1.2em; columns: 2; column-gap: 32px; }
.legal .toc li { margin-bottom: 6px; font-size: 0.95rem; }
.legal h2 { font-size: 1.55rem; margin-top: 48px; scroll-margin-top: 90px; }
.legal h3 { font-size: 1.2rem; margin-top: 28px; }
.legal p, .legal li { color: #3b424d; font-size: 1.02rem; }
.legal ul, .legal ol.body { padding-left: 1.3em; }
.legal li { margin-bottom: 8px; }
.legal .callout {
  background: var(--accent-soft); border: 1px solid #f3dca6; border-radius: var(--r);
  padding: 16px 20px; margin: 22px 0; font-size: 0.98rem; color: #6b521d;
}
.legal address { font-style: normal; color: #3b424d; line-height: 1.7; }
.legal table { width: 100%; border-collapse: collapse; margin: 18px 0; font-size: 0.95rem; }
.legal th, .legal td { text-align: left; padding: 11px 12px; border: 1px solid var(--border); vertical-align: top; }
.legal th { background: var(--bg-soft); font-weight: 700; color: var(--ink); }
.legal .back { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; margin-bottom: 18px; }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .nav-links {
    position: absolute; top: var(--header-h); left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 6px;
    background: #fff; border-bottom: 1px solid var(--border); padding: 16px 24px 22px;
    box-shadow: var(--shadow-md); display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links a:not(.btn) { padding: 12px 4px; font-size: 1.05rem; }
  .nav-links .btn { margin-top: 8px; }
  .nav-toggle { display: inline-flex; }

  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero-visual { order: -1; }
  .hero-cta { align-items: stretch; }
  .stores { justify-content: flex-start; }

  .problem-grid { grid-template-columns: 1fr; }
  .feature, .feature.reverse { grid-template-columns: 1fr; gap: 32px; }
  .feature .f-text, .feature.reverse .f-text { order: 0; }
  .f-visual { order: -1; }
  .privacy-cards { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 30px; }
  .legal .toc ol { columns: 1; }
}
@media (max-width: 520px) {
  body { font-size: 17px; }
  .privacy-cards { grid-template-columns: 1fr; }
  /* Shrink the bezel padding in proportion to the smaller frame so the screen
     keeps the same aspect (and same minimal screenshot crop) as desktop. */
  .phone { width: 240px; padding: 9px; }
  .badge-img { height: 44px; }
  .compare th, .compare td { padding: 12px 8px; }
  .compare thead th.col { width: 88px; }
  .compare td.feat { font-size: 0.88rem; }
  .compare .val { font-size: 0.76rem; }
}
