/* Crinkle — Paper Joy, for the web. Tokens mirror Crinkle/Design/Theme.swift. */
:root {
  --cream: #FFFCF7; --paper: #FFFFFF; --edge: #E2D1BA; --line: #F1E8DA; --wash: #FFF1CF;
  --ink: #2D100B; --cocoa: #3B2219; --muted: #6E6A6B;
  --coral: #FF735F; --coral-tint: #FFD9D1; --butter: #FFD170; --butter-tint: #FFEDBE;
  --green: #315D3B; --green-tint: #D9E8D6; --action: #713E30; --selected: #B23D2A;
  --radius: 16px; --gutter: 20px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--cream); color: var(--ink);
  font-family: "Nunito", -apple-system, "Helvetica Neue", Arial, sans-serif;
  font-size: 17px; line-height: 1.5; font-weight: 500;
}
a { color: var(--action); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; display: block; }
.wrap { max-width: 1040px; margin: 0 auto; padding: 0 var(--gutter); }

/* Header */
.top { display: flex; align-items: center; justify-content: space-between; padding: 18px 0; }
.top .lockup img { height: 40px; width: auto; }
.top nav a { margin-left: 22px; font-weight: 700; color: var(--ink); }
.top nav a:hover { color: var(--coral); text-decoration: none; }

/* Hero */
.hero { position: relative; padding: 36px 0 20px; display: grid; grid-template-columns: 1.1fr 1fr; gap: 24px; align-items: center; }
.hero h1 { font-size: clamp(38px, 6vw, 62px); line-height: 1.02; font-weight: 1000; letter-spacing: -0.02em; margin: 0 0 16px; }
.hero p.lead { font-size: 20px; color: var(--muted); margin: 0 0 26px; max-width: 34ch; }
/* The hero: one plan, many people. A big gift with the family's gifts around it, each tagged. */
.plan-scene { position: relative; height: 500px; }
.plan-scene .wash { position: absolute; left: 4%; right: 4%; bottom: 0; height: 210px; background: var(--wash); border-radius: 50% 50% 0 0 / 100% 100% 0 0; }
.plan-scene .g { position: absolute; margin: 0; width: 20%; }
.plan-scene .g img { width: 100%; filter: drop-shadow(0 10px 14px rgba(45,16,11,0.10)); }
.plan-scene .g.main { width: 42%; left: 29%; top: 12%; z-index: 2; }
.plan-scene .g figcaption { position: absolute; left: 50%; transform: translateX(-50%); bottom: -34px; white-space: nowrap; background: var(--paper); border-radius: 10px; padding: 5px 9px; font-size: 12px; line-height: 1.25; font-weight: 800; color: var(--ink); text-align: center; box-shadow: 0 4px 10px rgba(45,16,11,0.10); }
.plan-scene .g figcaption span { color: var(--muted); font-weight: 700; }
.plan-scene .g figcaption span.done { color: var(--green); }
.plan-scene .g1 { left: 4%; top: 0; }
.plan-scene .g2 { right: 4%; top: 0; }
.plan-scene .g3 { left: 0; top: 37%; width: 19%; }
.plan-scene .g4 { right: 0; top: 35%; width: 21%; }
.plan-scene .g5 { left: 21%; bottom: 26%; width: 16%; z-index: 3; }
.plan-scene .g6 { right: 21%; bottom: 25%; width: 17%; z-index: 3; }
.plan-scene .total { position: absolute; left: 50%; transform: translateX(-50%); bottom: 0; background: var(--paper); border-radius: 14px; padding: 10px 16px; box-shadow: 0 8px 18px rgba(45,16,11,0.10); text-align: center; z-index: 4; }
.plan-scene .total strong { display: block; font-size: 22px; font-weight: 1000; line-height: 1.1; }
.plan-scene .total span { font-size: 13px; color: var(--muted); font-weight: 700; }

/* Motion: things pop in on load, bob while they sit there, and sections rise as you scroll. */
@keyframes pop { from { opacity: 0; transform: translateY(22px) scale(.92); } to { opacity: 1; transform: none; } }
@keyframes rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
@keyframes bob { from { translate: 0 -4px; } to { translate: 0 5px; } }
.pop { animation: pop .7s cubic-bezier(.2,.8,.2,1) both; animation-delay: var(--d, 0s); }
.rise { animation: rise .6s ease-out both; animation-delay: var(--d, 0s); }
.bob img { animation: bob var(--t, 4s) ease-in-out 1.2s infinite alternate; }
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease-out, transform .7s cubic-bezier(.2,.8,.2,1); }
.reveal.in { opacity: 1; transform: none; }
.reveal .art img { opacity: 0; transform: translateY(16px); transition: opacity .6s ease-out, transform .6s cubic-bezier(.2,.8,.2,1); }
.reveal.in .art img { opacity: 1; transform: translateY(0); }
.reveal.in .art .left { transform: rotate(-8deg); transition-delay: .15s; }
.reveal.in .art .right { transform: rotate(7deg); transition-delay: .25s; }
.reveal.in .art .main { transition-delay: .05s; }
@media (prefers-reduced-motion: reduce) {
  .pop, .rise, .bob img { animation: none; }
  .reveal, .reveal .art img { opacity: 1; transform: none; transition: none; }
}

/* Buttons */
.btn { display: inline-flex; align-items: center; gap: 10px; padding: 14px 22px; border-radius: 14px; font-weight: 800; font-size: 17px; line-height: 1; }
.btn.primary { background: var(--coral); color: #fff; box-shadow: 0 8px 20px rgba(255,115,95,0.28); }
.btn.primary:hover { background: #ff846f; text-decoration: none; }
.btn.secondary { background: var(--paper); color: var(--ink); border: 1px solid var(--edge); }
.btn .note { display: block; font-size: 12px; font-weight: 600; opacity: 0.85; }
.cta-row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.small { font-size: 14px; color: var(--muted); }

/* Feature rows */
.features { padding: 40px 0 10px; }
.feature { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; align-items: center; padding: 36px 0; border-top: 1px solid var(--line); }
.feature:first-child { border-top: 0; }
.feature:nth-child(even) .art { order: 2; }
.feature h2 { font-size: clamp(26px, 3.4vw, 34px); font-weight: 1000; line-height: 1.08; margin: 0 0 10px; letter-spacing: -0.015em; }
.feature p { color: var(--muted); margin: 0 0 14px; max-width: 46ch; font-size: 18px; }
.art { position: relative; height: 260px; }
.art img { position: absolute; }
.art .main { width: 54%; left: 23%; top: 2%; }
.art .left { width: 28%; left: 4%; bottom: 6%; }
.art .right { width: 30%; right: 3%; bottom: 4%; }

/* Card chips, like the tour */
.card { background: var(--paper); border-radius: var(--radius); padding: 14px 16px; box-shadow: 0 6px 14px rgba(45,16,11,0.07), 0 1px 2px rgba(45,16,11,0.03); display: inline-block; min-width: 260px; }
.card .row { display: flex; justify-content: space-between; gap: 14px; font-weight: 700; }
.card .cap { color: var(--muted); font-size: 14px; font-weight: 600; margin-top: 4px; }
.bar { height: 8px; background: var(--line); border-radius: 999px; overflow: hidden; margin: 8px 0 6px; display: flex; }
.bar .spent { background: var(--coral); width: 25%; }
.bar .planned { background: #EBC77E; width: 40%; }
.stages { display: flex; gap: 10px; align-items: center; margin-top: 8px; font-size: 14px; font-weight: 700; }
.stages span { padding: 6px 10px; border-radius: 999px; background: var(--coral-tint); color: var(--selected); }
.stages span.done { background: var(--green-tint); color: var(--green); }
.lock { color: var(--muted); font-size: 14px; font-weight: 700; }

/* Private strip */
.private { margin: 40px 0; padding: 28px; background: var(--paper); border-radius: 22px; border: 1px solid var(--line); display: grid; grid-template-columns: auto 1fr; gap: 22px; align-items: center; }
.private img { width: 72px; }
.private h3 { margin: 0 0 6px; font-size: 22px; font-weight: 1000; }
.private p { margin: 0; color: var(--muted); }

/* Footer */
footer { padding: 30px 0 48px; color: var(--muted); font-size: 14px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; border-top: 1px solid var(--line); margin-top: 20px; }
footer a { color: var(--muted); margin-right: 18px; }

/* Text pages */
.doc { max-width: 720px; margin: 0 auto; padding: 20px var(--gutter) 60px; }
.doc h1 { font-size: 40px; font-weight: 1000; line-height: 1.05; margin: 14px 0 6px; letter-spacing: -0.02em; }
.doc .meta { color: var(--muted); margin-bottom: 26px; }
.doc h2 { font-size: 24px; font-weight: 900; margin: 32px 0 8px; }
.doc h3 { font-size: 19px; font-weight: 800; margin: 22px 0 6px; }
.doc p, .doc li { color: #3d3435; }
.doc li { margin: 6px 0; }
.doc strong { color: var(--ink); }
.doc .box { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; margin: 16px 0; }

@media (max-width: 720px) {
  .hero { grid-template-columns: 1fr; padding-top: 10px; }
  .hero .plan-scene { order: -1; height: 380px; }
  .plan-scene .g figcaption { font-size: 11px; bottom: -30px; }
  .plan-scene .g5, .plan-scene .g6 { display: none; }
  .plan-scene .g3, .plan-scene .g4 { top: 40%; }
  .plan-scene .g.main { width: 50%; left: 25%; top: 8%; }
  .btn.primary { flex-direction: column; gap: 3px; padding: 14px 18px; }
  .feature { grid-template-columns: 1fr; gap: 10px; padding: 28px 0; }
  .feature:nth-child(even) .art { order: 0; }
  .art { height: 220px; }
  .private { grid-template-columns: 1fr; text-align: center; justify-items: center; }
  .top nav a { margin-left: 14px; font-size: 15px; }
  .top nav a.only-wide { display: none; }
  .btn.primary { width: 100%; justify-content: center; }
}
