/* Flowly landing: "Calm Clay" tokens from the app's design system. */
@font-face { font-family: 'Nunito'; font-style: normal; font-weight: 400; font-display: swap; src: url('/fonts/nunito-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Nunito'; font-style: normal; font-weight: 700; font-display: swap; src: url('/fonts/nunito-latin-700-normal.woff2') format('woff2'); }
@font-face { font-family: 'Nunito'; font-style: normal; font-weight: 800; font-display: swap; src: url('/fonts/nunito-latin-800-normal.woff2') format('woff2'); }

:root {
  --bg: #FAEEE2;
  --surface: #FFFAF4;
  --sand50: #F7EADB;
  --primary: #3F6B82;
  --primary-deep: #2C4F63;
  --primary-soft: #DCE8EA;
  --accent: #E07A5F;
  --accent-deep: #A9492F;
  --ink: #22313D;
  --ink-soft: #47545F;
  --muted: #5F6973;
  --line: #EBDCCB;
  --danger: #C41E3A;
  --danger-bg: #FFF2F2;
  --shadow: 0 8px 22px rgba(80, 52, 30, 0.07);
  --radius-card: 24px;
  --gutter: 20px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg) 40%, #FFFFFF 100%);
  background-color: var(--bg);
  color: var(--ink);
  font-family: 'Nunito', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 16px;
  line-height: 1.55;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--primary); }
a:focus-visible, button:focus-visible, input:focus-visible, label.choice:focus-within {
  outline: 3px solid var(--primary);
  outline-offset: 2px;
}
h1, h2, h3 { line-height: 1.2; margin: 0 0 12px; }
h1 { font-size: 34px; font-weight: 800; letter-spacing: -0.02em; }
h2 { font-size: 24px; font-weight: 800; letter-spacing: -0.01em; }
h3 { font-size: 18px; font-weight: 700; }
p { margin: 0 0 12px; }
ul { margin: 0; padding: 0; list-style: none; }

.top, main, .footer { max-width: 1040px; margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.top { padding-top: 18px; padding-bottom: 6px; }
.wordmark { font-weight: 800; font-size: 22px; color: var(--primary-deep); text-decoration: none; letter-spacing: -0.01em; }

.hero { display: grid; gap: 20px; padding: 20px 0 12px; align-items: center; }
.hero-art img { width: 100%; max-width: 420px; margin: 0 auto; border-radius: 32px; }
.lead { font-size: 18px; color: var(--ink-soft); margin-bottom: 20px; }

.button {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 52px; padding: 0 28px;
  border: 0; border-radius: 999px;
  background: var(--primary); color: #fff;
  font: inherit; font-size: 17px; font-weight: 800;
  cursor: pointer; transition: background-color 0.15s ease;
}
.button:hover { background: var(--primary-deep); }
.button:active { transform: translateY(1px); }
.button[disabled] { opacity: 0.6; cursor: progress; }
.button.wide { width: 100%; }

.fine { font-size: 14px; color: var(--muted); }
.center { text-align: center; }

.section { padding: 36px 0 8px; }

.cards { display: grid; gap: 16px; }
.card { background: var(--surface); border-radius: var(--radius-card); padding: 22px; box-shadow: var(--shadow); }
.card p { color: var(--ink-soft); margin: 0; }
.card h3::before { content: ''; display: block; width: 28px; height: 4px; border-radius: 4px; background: var(--accent); margin-bottom: 14px; }

.preview .phone {
  max-width: 380px; margin: 8px auto 14px;
  background: linear-gradient(160deg, #B9CCD2 0%, #DCE8EA 55%, #F1DDC9 100%);
  border: 8px solid var(--ink); border-radius: 40px;
  padding: 44px 12px 28px;
  box-shadow: var(--shadow);
}
.notes { display: grid; gap: 10px; }
.note { background: rgba(255, 250, 244, 0.92); border-radius: 18px; padding: 12px 14px; }
.note-app { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); margin-bottom: 4px; }
.app-icon { width: 20px; height: 20px; border-radius: 6px; background: var(--primary); color: #fff; font-weight: 800; font-size: 12px; display: grid; place-items: center; }
.note-time { margin-left: auto; }
.note-title { font-weight: 800; margin: 0 0 2px; font-size: 15px; }
.note-body { margin: 0; font-size: 15px; color: var(--ink-soft); line-height: 1.4; }

.everything { display: grid; gap: 4px; background: var(--surface); border-radius: var(--radius-card); padding: 8px 20px; box-shadow: var(--shadow); }
.everything li { display: flex; gap: 14px; align-items: flex-start; padding: 14px 0; border-bottom: 1px solid var(--line); }
.everything li:last-child { border-bottom: 0; }
.everything h3 { font-size: 16px; margin: 0 0 2px; }
.everything p { margin: 0; color: var(--ink-soft); font-size: 15px; }
.icon { flex: none; width: 36px; height: 36px; padding: 7px; border-radius: 12px; background: var(--primary-soft); fill: none; stroke: var(--primary-deep); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.who { text-align: center; padding-bottom: 32px; }
.who p { font-size: 18px; color: var(--ink-soft); max-width: 520px; margin: 0 auto 20px; }

.footer { padding-top: 24px; padding-bottom: 40px; border-top: 1px solid var(--line); margin-top: 16px; }
.emergency { background: var(--danger-bg); color: var(--danger); border-radius: 12px; padding: 12px 16px; font-size: 15px; }

.prose { max-width: 680px; padding-top: 16px; padding-bottom: 24px; }
.prose h2 { font-size: 20px; margin-top: 28px; }
.prose ul { list-style: disc; padding-left: 22px; }
.prose li { margin-bottom: 6px; }

/* Sheet */
.sheet[hidden] { display: none; }
.sheet { position: fixed; inset: 0; z-index: 10; display: flex; align-items: flex-end; justify-content: center; }
.sheet-backdrop { position: absolute; inset: 0; background: rgba(34, 49, 61, 0.45); }
.sheet-panel {
  position: relative; width: 100%; max-width: 520px; max-height: 92vh; overflow-y: auto;
  background: var(--surface); border-radius: 28px 28px 0 0;
  padding: 28px var(--gutter) calc(24px + env(safe-area-inset-bottom));
  animation: rise 0.25s ease-out;
}
@keyframes rise { from { transform: translateY(24px); opacity: 0; } to { transform: none; opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .sheet-panel { animation: none; } }
.sheet-close { position: absolute; top: 10px; right: 10px; width: 44px; height: 44px; border: 0; border-radius: 999px; background: var(--sand50); color: var(--ink); font-size: 26px; line-height: 1; cursor: pointer; }
.sheet h2 { padding-right: 44px; }
label[for="email"] { display: block; font-weight: 700; margin: 8px 0 6px; }
input[type="email"] {
  width: 100%; min-height: 52px; padding: 0 16px; margin-bottom: 12px;
  border: 2px solid var(--line); border-radius: 14px; background: #fff;
  font: inherit; font-size: 17px; color: var(--ink);
}
input[type="email"]:focus { border-color: var(--primary); outline: none; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.error { color: var(--danger); font-weight: 700; }
fieldset { border: 0; padding: 0; margin: 0 0 18px; }
legend { font-weight: 800; margin-bottom: 8px; }
.choice { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 10px 14px; margin-bottom: 8px; border: 2px solid var(--line); border-radius: 14px; background: #fff; cursor: pointer; }
.choice:has(input:checked) { border-color: var(--primary); background: var(--primary-soft); }
.choice input { width: 20px; height: 20px; accent-color: var(--primary); flex: none; }
.check { margin-bottom: 12px; }

@media (min-width: 760px) {
  :root { --gutter: 32px; }
  h1 { font-size: 46px; }
  h2 { font-size: 30px; }
  .hero { grid-template-columns: 1.1fr 1fr; gap: 48px; padding-top: 40px; }
  .cards { grid-template-columns: repeat(3, 1fr); }
  .everything { grid-template-columns: 1fr 1fr; column-gap: 32px; }
  .everything li:nth-last-child(2) { border-bottom: 0; }
  .sheet { align-items: center; }
  .sheet-panel { border-radius: 28px; }
}
