/* Grocery Savings by FreeMe (2026-11-27). FreeMe.com family: v3 greens and mint, Montserrat headings, Open Sans text.
   Hairline cards and nearly square inputs (NerdWallet DESIGN.md, pulled live), tap-friendly lists (UI UX Pro Max:
   Grocery & Shopping List). One file for the marketing page and the app. */
@font-face { font-family: "Montserrat"; font-weight: 100 900; font-display: swap; src: url("../fonts/montserrat-latin-wght-normal.woff2") format("woff2"); }
@font-face { font-family: "Open Sans"; font-weight: 300 800; font-display: swap; src: url("../fonts/open-sans-latin-wght-normal.woff2") format("woff2"); }

:root {
  color-scheme: light;
  --paper: #f4f7f5;
  --card: #ffffff;
  --ink: #10201a;
  --soft: #4d5f57;
  --green: #0b6b48;
  --green-deep: #074a32;
  --fresh: #12a06a;
  --mint: #dff0e8;
  --mint-2: #eef7f2;
  --mark: #ffd84a;
  --amber: #8a5300;
  --amber-bg: #fff4d6;
  --red: #b42318;
  --rule: #d5dfda;
  --font-head: "Montserrat", "Segoe UI", system-ui, sans-serif;
  --font-body: "Open Sans", "Segoe UI", system-ui, sans-serif;
  --r: 14px;
  --r-sm: 6px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--font-body); font-size: 17px; line-height: 1.55; }
h1, h2, h3, h4, p, ul, ol, figure, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
h1, h2, h3, h4 { font-family: var(--font-head); line-height: 1.15; letter-spacing: -0.01em; }
a { color: var(--green); text-underline-offset: 3px; }
img, svg { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; border-radius: 4px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.wrap { width: min(1120px, 100% - 32px); margin-inline: auto; }
.skip { position: absolute; left: -999px; top: 8px; }
.skip:focus { left: 16px; z-index: 50; background: var(--card); padding: 10px 14px; border-radius: var(--r-sm); }
[hidden] { display: none !important; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 12px 22px; border: 1.5px solid var(--green); border-radius: var(--r-sm);
  background: var(--green); color: #fff; font-family: var(--font-head); font-weight: 700; font-size: 16px; line-height: 1.2; text-decoration: none; cursor: pointer; transition: background .15s, border-color .15s; }
.btn:hover { background: var(--green-deep); border-color: var(--green-deep); }
.btn:disabled { opacity: .55; cursor: progress; }
.btn--ghost { background: var(--card); color: var(--green-deep); }
.btn--ghost:hover { background: var(--mint); }
.btn--sm { min-height: 40px; padding: 8px 14px; font-size: 15px; }
.btn--big { min-height: 56px; padding: 14px 28px; font-size: 18px; }
.btn--wide { width: 100%; }
.btn--danger { background: var(--card); color: var(--red); border-color: var(--red); }
.btn--danger:hover { background: #fdecea; }
.link { background: none; border: 0; padding: 0; color: var(--green); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; font-weight: 600; }

/* logo */
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand svg { height: 30px; width: auto; }
.brand b { font-family: var(--font-head); font-weight: 800; font-size: 17px; letter-spacing: -0.01em; padding-left: 10px; border-left: 1.5px solid var(--rule); color: var(--green-deep); white-space: nowrap; }
@media (max-width: 380px) { .brand svg { height: 24px; } .brand b { font-size: 15px; } }

/* forms */
.field { display: grid; gap: 6px; }
.field label, .lbl { font-weight: 700; font-size: 15px; }
.field small, .hint { font-size: 14px; color: var(--soft); }
input[type=text], input[type=email], input[type=number], input[type=date], input[type=search], input[inputmode], select {
  width: 100%; min-height: 48px; padding: 10px 12px; border: 1.5px solid #b8c7bf; border-radius: var(--r-sm); background: #fff; }
input:focus, select:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 3px rgba(11, 107, 72, .18); }
.code-input { font-family: var(--font-head); font-size: 28px; letter-spacing: .3em; text-align: center; font-weight: 700; }
.err { color: var(--red); font-weight: 600; font-size: 15px; min-height: 1.2em; }
.ok-msg { color: var(--green-deep); font-weight: 600; font-size: 15px; }
.trap { position: absolute; left: -5000px; width: 1px; height: 1px; overflow: hidden; }
.row { display: grid; gap: 12px; }
@media (min-width: 560px) { .row--2 { grid-template-columns: 1fr 1fr; } .row--3 { grid-template-columns: 2fr 1fr 1fr; } }
.stack { display: grid; gap: 14px; }
.fine { font-size: 14px; color: var(--soft); }

/* cards */
.card { background: var(--card); border: 1px solid var(--rule); border-radius: var(--r); padding: 20px; }
.card--mint { background: var(--mint-2); border-color: #c7e3d5; }
.card h2, .card h3 { margin-bottom: 4px; }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; background: var(--mint); color: var(--green-deep); font-weight: 700; font-size: 13px; font-family: var(--font-head); white-space: nowrap; }
.pill--plus { background: var(--mark); color: var(--ink); }
.pill--day { background: var(--amber-bg); color: var(--amber); }
.save { color: var(--green); font-weight: 800; font-family: var(--font-head); }

/* ---------------- marketing page ---------------- */
.top { position: sticky; top: 0; z-index: 20; background: rgba(244, 247, 245, .94); backdrop-filter: blur(8px); border-bottom: 1px solid var(--rule); }
.top .wrap { display: flex; align-items: center; gap: 16px; min-height: 64px; }
.nav { display: none; gap: 22px; margin-left: auto; }
.nav a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: 15px; }
.nav a:hover { color: var(--green); }
.top__cta { margin-left: auto; display: flex; gap: 10px; align-items: center; }
.top__cta .signin { font-weight: 700; font-size: 15px; text-decoration: none; }
@media (min-width: 900px) { .nav { display: flex; } .top__cta { margin-left: 18px; } }
@media (max-width: 420px) { .top__cta .btn { padding: 8px 12px; } }

.hero { padding-block: clamp(36px, 7vw, 88px) clamp(40px, 6vw, 72px); }
.hero__grid { display: grid; gap: 36px; align-items: center; }
@media (min-width: 960px) { .hero__grid { grid-template-columns: 1.05fr .95fr; gap: 56px; } }
.eyebrow { font-family: var(--font-head); font-weight: 800; font-size: 14px; letter-spacing: .08em; text-transform: uppercase; color: var(--green); }
.hero h1 { font-size: clamp(38px, 6.4vw, 66px); font-weight: 800; margin: 10px 0 18px; }
.hero h1 em { font-style: normal; background: linear-gradient(transparent 62%, var(--mark) 62%); }
.hero p.lead { font-size: clamp(18px, 2.1vw, 21px); color: var(--soft); max-width: 36em; }
.hero__go { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-top: 26px; }
.hero__go .fine { flex-basis: 100%; }
.checks { display: grid; gap: 8px; margin-top: 22px; }
.checks li { position: relative; padding-left: 30px; font-weight: 600; }
.checks li::before { content: ""; position: absolute; left: 0; top: .2em; width: 20px; height: 20px; border-radius: 50%; background: var(--mint) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 10.5l3.2 3.2L15 7' fill='none' stroke='%230b6b48' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/20px no-repeat; }

/* the example plan in the hero */
.demo { background: var(--card); border: 1px solid var(--rule); border-radius: 18px; padding: 18px; display: grid; gap: 14px; }
.demo__head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.demo__head h2 { font-size: 19px; }
.demo__total { background: var(--mint); border-radius: 12px; padding: 14px 16px; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.demo__total b { font-family: var(--font-head); font-size: 30px; color: var(--green-deep); line-height: 1; }
.demo__store { border: 1px solid var(--rule); border-radius: 12px; overflow: hidden; }
.demo__store h3 { font-size: 16px; padding: 10px 14px; background: var(--mint-2); display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.demo__store li { display: grid; grid-template-columns: 22px 1fr auto; gap: 10px; align-items: center; padding: 9px 14px; border-top: 1px solid var(--rule); font-size: 15px; }
.demo__store li i { width: 20px; height: 20px; border: 2px solid #9fb5aa; border-radius: 5px; }
.demo__store li.done i { background: var(--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 10.5l3.2 3.2L15 7' fill='none' stroke='%23fff' stroke-width='2.6' stroke-linecap='round'/%3E%3C/svg%3E") center/18px no-repeat; border-color: var(--green); }
.demo__store li.done span:first-of-type { text-decoration: line-through; color: var(--soft); }
.demo__store small { color: var(--green); font-weight: 700; display: block; font-size: 13px; }
.demo__note { font-size: 13px; color: var(--soft); text-align: center; }

.section { padding-block: clamp(52px, 8vw, 96px); }
.section--white { background: var(--card); border-block: 1px solid var(--rule); }
.section h2.title { font-size: clamp(28px, 4.2vw, 42px); font-weight: 800; max-width: 22em; }
.section p.sub { color: var(--soft); font-size: 18px; margin-top: 12px; max-width: 40em; }
.steps { display: grid; gap: 16px; margin-top: 34px; counter-reset: step; }
@media (min-width: 820px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.steps li { counter-increment: step; background: var(--card); border: 1px solid var(--rule); border-radius: var(--r); padding: 22px; display: grid; gap: 8px; align-content: start; }
.section--white .steps li { background: var(--paper); }
.steps li::before { content: counter(step); display: grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; background: var(--green); color: #fff; font-family: var(--font-head); font-weight: 800; font-size: 18px; }
.steps h3 { font-size: 20px; }
.steps p { color: var(--soft); }

.story { display: grid; gap: 20px; align-items: center; }
@media (min-width: 860px) { .story { grid-template-columns: 1fr 1fr; gap: 48px; } }
.bill { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.bill div { border-radius: var(--r); padding: 22px 18px; text-align: center; border: 1px solid var(--rule); background: var(--card); }
.bill div:last-child { background: var(--mint); border-color: #c7e3d5; }
.bill b { display: block; font-family: var(--font-head); font-size: clamp(34px, 5vw, 48px); line-height: 1.05; }
.bill span { font-size: 14px; color: var(--soft); font-weight: 600; }
.bill div:first-child b { color: var(--soft); text-decoration: line-through; text-decoration-thickness: 3px; text-decoration-color: rgba(180, 35, 24, .7); }
.bill div:last-child b { color: var(--green-deep); }

.feat { display: grid; gap: 14px; margin-top: 32px; }
@media (min-width: 720px) { .feat { grid-template-columns: 1fr 1fr; } }
.feat li { display: grid; grid-template-columns: 44px 1fr; gap: 14px; padding: 18px; background: var(--card); border: 1px solid var(--rule); border-radius: var(--r); }
.feat li svg { width: 44px; height: 44px; padding: 10px; border-radius: 12px; background: var(--mint); color: var(--green); }
.feat h3 { font-size: 17px; margin-bottom: 4px; }
.feat p { color: var(--soft); font-size: 16px; }

.prices { display: grid; gap: 16px; margin-top: 34px; align-items: start; }
@media (min-width: 820px) { .prices { grid-template-columns: 1fr 1fr; } }
.price { background: var(--card); border: 1px solid var(--rule); border-radius: 18px; padding: 26px; display: grid; gap: 14px; }
.price--plus { border: 2px solid var(--green); }
.price h3 { font-size: 22px; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.price .amt { font-family: var(--font-head); font-weight: 800; font-size: 40px; line-height: 1; }
.price .amt small { font-size: 16px; font-weight: 700; color: var(--soft); }
.price .or { color: var(--soft); font-weight: 600; }
.price ul { display: grid; gap: 8px; }
.price li { position: relative; padding-left: 26px; }
.price li::before { content: ""; position: absolute; left: 0; top: .35em; width: 16px; height: 16px; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M4 10.5l4 4L16 6' fill='none' stroke='%230b6b48' stroke-width='2.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/16px no-repeat; }

.guarantee { display: grid; gap: 22px; align-items: center; background: var(--ink); color: #fff; border-radius: 22px; padding: clamp(24px, 5vw, 48px); }
@media (min-width: 820px) { .guarantee { grid-template-columns: auto 1fr; gap: 40px; } }
.stamp { width: 168px; height: 168px; border-radius: 50%; background: var(--mark); color: var(--ink); display: grid; place-content: center; text-align: center; font-family: var(--font-head); border: 5px double var(--ink); outline: 4px solid var(--mark); }
.stamp small { font-weight: 800; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; }
.stamp b { font-size: 40px; line-height: 1; font-weight: 900; }
.guarantee h2 { font-size: clamp(26px, 3.6vw, 36px); }
.guarantee p { color: rgba(255, 255, 255, .84); margin-top: 10px; }
.guarantee a { color: var(--mark); }

.faq { display: grid; gap: 10px; margin-top: 30px; max-width: 820px; }
.faq details { background: var(--card); border: 1px solid var(--rule); border-radius: var(--r); padding: 0 18px; }
.faq summary { cursor: pointer; font-family: var(--font-head); font-weight: 700; font-size: 17px; padding: 16px 0; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 24px; line-height: 1; color: var(--green); }
.faq details[open] summary::after { content: "\2013"; }
.faq details p { padding-bottom: 16px; color: var(--soft); }

.join { display: grid; gap: 26px; }
@media (min-width: 900px) { .join { grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; } }
.join .card { padding: clamp(20px, 4vw, 30px); }

.foot { padding-block: 36px 48px; border-top: 1px solid var(--rule); font-size: 15px; color: var(--soft); }
.foot .wrap { display: grid; gap: 14px; }
.foot nav { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.foot nav a { color: var(--ink); font-weight: 600; text-decoration: none; }

/* legal pages */
.doc { max-width: 760px; padding-block: 40px 72px; }
.doc h1 { font-size: clamp(30px, 5vw, 42px); margin-bottom: 10px; }
.doc h2 { font-size: 21px; margin: 30px 0 8px; }
.doc p, .doc li { color: #24352d; margin-bottom: 10px; }
.doc ul { list-style: disc; padding-left: 22px; }

/* ---------------- the app ---------------- */
.app-body { padding-bottom: 86px; }
.bar { position: sticky; top: 0; z-index: 20; background: var(--card); border-bottom: 1px solid var(--rule); }
.bar .wrap { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 58px; }
.view { padding-block: 20px 28px; display: grid; gap: 16px; max-width: 760px; }
.view > h1 { font-size: 26px; }
.tabs { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; background: var(--card); border-top: 1px solid var(--rule); padding-bottom: env(safe-area-inset-bottom); }
.tabs ul { display: grid; grid-template-columns: repeat(5, 1fr); max-width: 760px; margin-inline: auto; }
.tabs a { display: grid; justify-items: center; gap: 2px; padding: 8px 2px 9px; text-decoration: none; color: var(--soft); font-size: 12px; font-weight: 700; font-family: var(--font-head); min-height: 58px; }
.tabs a svg { width: 24px; height: 24px; }
.tabs a[aria-current="page"] { color: var(--green); }
.tabs a[aria-current="page"] svg { stroke-width: 2.4; }
@media (min-width: 900px) { .tabs { position: sticky; top: 58px; bottom: auto; border-top: 0; border-bottom: 1px solid var(--rule); } .app-body { padding-bottom: 0; } .tabs a { grid-auto-flow: column; justify-content: center; gap: 8px; font-size: 14px; min-height: 48px; align-items: center; } .tabs a svg { width: 20px; height: 20px; } }

.big-num { font-family: var(--font-head); font-weight: 800; font-size: 40px; line-height: 1; color: var(--green-deep); }
.kpis { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.kpi { background: var(--card); border: 1px solid var(--rule); border-radius: var(--r); padding: 14px 16px; display: grid; gap: 4px; }
.kpi span { font-size: 13px; color: var(--soft); font-weight: 700; }
.kpi b { font-family: var(--font-head); font-size: 24px; line-height: 1.1; }

.trip { background: var(--card); border: 1px solid var(--rule); border-radius: var(--r); overflow: hidden; }
.trip__head { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 16px; background: var(--mint-2); border-bottom: 1px solid var(--rule); }
.trip__head h3 { font-size: 18px; }
.ticks li { border-top: 1px solid var(--rule); }
.ticks li:first-child { border-top: 0; }
.tick { display: grid; grid-template-columns: 26px 1fr auto; gap: 12px; align-items: center; width: 100%; padding: 12px 16px; background: none; border: 0; text-align: left; cursor: pointer; min-height: 52px; }
.tick i { width: 24px; height: 24px; border: 2px solid #9fb5aa; border-radius: 6px; }
.tick[aria-pressed="true"] i { background: var(--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 10.5l3.2 3.2L15 7' fill='none' stroke='%23fff' stroke-width='2.6' stroke-linecap='round'/%3E%3C/svg%3E") center/20px no-repeat; border-color: var(--green); }
.tick[aria-pressed="true"] .tick__name { text-decoration: line-through; color: var(--soft); }
.tick__price { font-weight: 700; font-family: var(--font-head); }

.list { background: var(--card); border: 1px solid var(--rule); border-radius: var(--r); }
.list > li { padding: 14px 16px; border-top: 1px solid var(--rule); display: grid; gap: 6px; }
.list > li:first-child { border-top: 0; }
.list__row { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.list__name { font-weight: 700; }
.list__meta { font-size: 14px; color: var(--soft); }
.empty { text-align: center; padding: 26px 18px; color: var(--soft); }
.actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.mini { min-height: 34px; padding: 4px 10px; font-size: 14px; border-radius: var(--r-sm); border: 1px solid var(--rule); background: #fff; cursor: pointer; font-weight: 600; }
.mini:hover { border-color: var(--green); color: var(--green); }
.mini--x { color: var(--red); }
.mini--x:hover { border-color: var(--red); color: var(--red); }
.switch { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; cursor: pointer; }
.switch input { width: 20px; height: 20px; accent-color: var(--green); }

.review { width: 100%; border-collapse: collapse; font-size: 15px; }
.review th { text-align: left; font-size: 13px; color: var(--soft); padding: 4px 4px 6px; }
.review td { padding: 4px; vertical-align: middle; }
.review input, .review select { min-height: 42px; padding: 6px 8px; }
.review .c-name { width: 46%; } .review .c-qty { width: 15%; } .review .c-unit { width: 17%; } .review .c-price { width: 18%; }
.review .c-x { width: 34px; }
@media (max-width: 560px) {
  .review thead { display: none; }
  .review tr { display: grid; grid-template-columns: 1fr 1fr 1fr 34px; gap: 6px; padding: 10px 0; border-top: 1px solid var(--rule); }
  .review td.c-name { grid-column: 1 / -1; width: auto; }
  .review td { width: auto !important; padding: 0; }
}
.toast { position: fixed; left: 50%; bottom: 96px; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 10px; font-weight: 600; z-index: 60; max-width: calc(100% - 32px); text-align: center; }
@media (min-width: 900px) { .toast { bottom: 28px; } }
.lock { display: flex; gap: 10px; align-items: center; background: var(--amber-bg); border-radius: 10px; padding: 10px 12px; font-size: 15px; color: var(--amber); font-weight: 600; }
.signin { max-width: 460px; margin: 28px auto; }
.spinner { width: 18px; height: 18px; border: 3px solid rgba(255,255,255,.4); border-top-color: #fff; border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.btn--ghost .spinner { border-color: rgba(11,107,72,.25); border-top-color: var(--green); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .spinner { animation-duration: 2.4s; } }
