/* ACS brand palette for the page chrome (memory/context/brand-and-formatting.md).
   The phone preview uses the prospect's own colors via --p / --a. */
:root {
  --navy-900: #0b1f35; --navy-800: #12304f; --navy-700: #1a4270;
  --gold: #b8892b; --gold-light: #d9a94a; --gold-text: #906000; --warm: #fff7e8;
  --slate-700: #3d4a58; --slate-500: #61707f; --slate-300: #c3ccd5; --slate-100: #eef1f4; --slate-50: #f7f9fb;
  --bg: var(--slate-50); --surface: #fff; --text: var(--slate-700); --muted: var(--slate-500);
  --heading: var(--navy-900); --line: var(--slate-300); --fill: var(--slate-100); --accent: var(--navy-700); --accent-soft: #e8eef6;
  --green: #2e7d4f; --red: #b4473a; --radius: 4px; --shadow: 0 1px 2px rgba(11,31,53,.06);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --bg: #08172a; --surface: #0f2340; --text: #d5dde6; --muted: #9aa8b7; --heading: #f2f5f8; --line: #284468; --fill: #15304f; --accent: #6fa3dc; --accent-soft: #15304f; --warm: #2a2312; --gold-text: #d9a94a; --green: #5fbf86; --red: #e07b6e; }
}
:root[data-theme="dark"] { --bg: #08172a; --surface: #0f2340; --text: #d5dde6; --muted: #9aa8b7; --heading: #f2f5f8; --line: #284468; --fill: #15304f; --accent: #6fa3dc; --accent-soft: #15304f; --warm: #2a2312; --gold-text: #d9a94a; --green: #5fbf86; --red: #e07b6e; }

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 17px/1.6 "Segoe UI", "Helvetica Neue", Arial, sans-serif; min-height: 100vh; display: flex; flex-direction: column; }
h1, h2, h3, h4 { color: var(--heading); font-weight: 700; letter-spacing: -0.015em; line-height: 1.2; margin: 0 0 12px; }
h1 { font-size: clamp(1.5rem, 3.6vw, 2.1rem); }
h2 { font-size: 1.15rem; }
h2:focus { outline: none; }
p { margin: 0 0 12px; }
a { color: var(--accent); }
.muted { color: var(--muted); } .small, .mini { font-size: .85rem; } .mini { color: var(--muted); margin: 4px 0 0; } .center { text-align: center; }
.eyebrow { text-transform: uppercase; letter-spacing: .08em; font-size: .78rem; font-weight: 700; color: var(--gold-text); margin-bottom: 8px; }
.lead { font-size: 1.08rem; max-width: 48em; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; font: inherit; font-weight: 600; font-size: 1rem; line-height: 1.2; text-decoration: none; cursor: pointer; padding: 11px 18px; min-height: 44px; border-radius: var(--radius); border: 1px solid transparent; }
.btn-lg { padding: 14px 24px; min-height: 52px; font-size: 1.05rem; }
.btn-sm { padding: 7px 12px; min-height: 36px; font-size: .9rem; }
.btn-primary { background: var(--navy-700); color: #fff; }
.btn-gold { background: var(--gold); color: #fff; } .btn-gold:hover { filter: brightness(1.08); }
.btn-ghost { background: var(--surface); color: var(--accent); border-color: var(--line); } .btn-ghost:hover { border-color: var(--accent); }
.btn-outline-light { background: transparent; color: #fff; border-color: rgba(255,255,255,.5); }
button:focus-visible, .btn:focus-visible, a:focus-visible { outline: 3px solid var(--gold-light); outline-offset: 2px; }
.btn:disabled { opacity: .7; cursor: wait; }
.link-btn { font: inherit; background: none; border: 0; color: var(--accent); text-decoration: underline; cursor: pointer; padding: 0; font-size: .9rem; }
.row-btns { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 16px 0; }

.top { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 20px; padding-top: max(10px, env(safe-area-inset-top)); background: var(--navy-900); border-bottom: 3px solid var(--gold); }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; min-width: 0; }
.brand img { border-radius: var(--radius); flex: none; }
.brand-text { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.brand-text b { font-size: 1rem; } .brand-text small { font-size: .74rem; color: var(--slate-300); }
.demo-tag { font-style: normal; font-size: .68rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; background: var(--gold); color: #fff; padding: 2px 6px; border-radius: 3px; vertical-align: 2px; margin-left: 4px; }
.btn-install { background: var(--gold); color: #fff; min-height: 38px; padding: 8px 14px; font-size: .9rem; flex: none; }
.tabs { position: sticky; top: 0; z-index: 10; display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; background: var(--surface); border-bottom: 1px solid var(--line); padding: 0 12px; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { font: inherit; font-size: .92rem; font-weight: 600; white-space: nowrap; cursor: pointer; background: none; border: 0; border-bottom: 3px solid transparent; color: var(--muted); padding: 12px 12px 10px; }
.tabs button[aria-selected="true"] { color: var(--heading); border-bottom-color: var(--gold); }
.tabs .tab-full { color: var(--gold-text); }

main { flex: 1; width: 100%; max-width: 1080px; margin: 0 auto; padding: 24px 20px 40px; }
.panel { animation: rise .25s ease; }
@keyframes rise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .panel { animation: none; } }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; margin-bottom: 16px; box-shadow: var(--shadow); }

/* Start */
.hero { background: var(--navy-900); color: #dbe3ec; border-radius: var(--radius); border-left: 6px solid var(--gold); padding: clamp(26px, 5vw, 50px); margin-bottom: 26px; }
.hero h1 { color: #fff; font-size: clamp(1.8rem, 4.4vw, 2.6rem); max-width: 19em; }
.hero .eyebrow { color: var(--gold-light); }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin: 22px 0 26px; }
.facts { list-style: none; padding: 20px 0 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; border-top: 1px solid rgba(255,255,255,.15); }
.facts b { display: block; color: #fff; } .facts span { color: #b9c6d4; font-size: .9rem; }
.show-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.show { background: var(--surface); border: 1px solid var(--line); border-top: 3px solid var(--gold); border-radius: var(--radius); padding: 14px; }
.show b { display: block; color: var(--heading); margin-bottom: 4px; } .show p { font-size: .88rem; color: var(--muted); margin: 0; }

/* Demo layout */
.pane-switch { display: none; gap: 4px; background: var(--fill); padding: 4px; border-radius: var(--radius); margin-bottom: 14px; }
.pane-switch button { flex: 1; font: inherit; font-weight: 600; font-size: .92rem; border: 0; background: transparent; color: var(--text); padding: 9px; border-radius: 3px; cursor: pointer; }
.pane-switch button[aria-pressed="true"] { background: var(--navy-700); color: #fff; }
.demo-grid { display: grid; grid-template-columns: minmax(300px, 400px) 1fr; gap: 28px; align-items: start; }
.customize { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); }
.cz { border: 0; border-top: 1px solid var(--line); padding: 12px 0 4px; margin: 12px 0 0; min-width: 0; }
.cz legend { font-weight: 700; color: var(--heading); padding: 0 6px 0 0; font-size: .95rem; }
.field { display: block; min-width: 0; margin-bottom: 10px; }
.field > span { display: block; font-size: .85rem; font-weight: 600; color: var(--heading); margin-bottom: 4px; }
.field i, .check i { color: var(--red); font-style: normal; }
input[type=text], input:not([type]), input[type=email], input[type=tel], input[type=password], input[type=date], select, textarea {
  width: 100%; min-width: 0; max-width: 100%; font: inherit; font-size: 1rem; color: var(--text); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 9px 11px; min-height: 42px;
}
textarea { resize: vertical; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent); border-color: var(--accent); }
input[type=color] { width: 100%; height: 44px; padding: 2px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); cursor: pointer; }
.colors { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.presets { display: flex; flex-wrap: wrap; gap: 8px; }
.preset { display: inline-flex; border: 1px solid var(--line); border-radius: 18px; overflow: hidden; padding: 0; cursor: pointer; background: none; }
.preset span { width: 22px; height: 30px; display: block; }
.logo-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.logo-prev { width: 64px; height: 48px; border: 1px dashed var(--line); border-radius: var(--radius); display: flex; align-items: center; justify-content: center; background: var(--fill); overflow: hidden; }
.logo-prev img { max-width: 100%; max-height: 100%; }
.logo-prev span { font-size: .7rem; color: var(--muted); }
.file-btn { cursor: pointer; }
.seg2 { display: flex; gap: 4px; background: var(--fill); padding: 3px; border-radius: var(--radius); }
.seg2 button { flex: 1; font: inherit; font-size: .9rem; font-weight: 600; border: 0; background: transparent; color: var(--text); padding: 7px; border-radius: 3px; cursor: pointer; }
.seg2 button[aria-pressed="true"] { background: var(--navy-700); color: #fff; }
.habit-ed { display: flex; gap: 8px; margin-bottom: 10px; }
.habit-ed .hn { flex: none; width: 24px; height: 24px; border-radius: 50%; background: var(--navy-700); color: #fff; font-size: .78rem; font-weight: 700; display: flex; align-items: center; justify-content: center; margin-top: 9px; }
.habit-ed > div { flex: 1; display: grid; gap: 4px; min-width: 0; }
.habit-ed input { font-weight: 600; min-height: 38px; padding: 7px 10px; }
.habit-ed textarea { font-size: .9rem; min-height: 0; padding: 7px 10px; }
.cz-cta { margin-top: 8px; background: var(--warm); border-left: 4px solid var(--gold); padding: 10px 12px; border-radius: var(--radius); font-size: .92rem; }

/* Phone frame */
.preview { position: sticky; top: 64px; }
.phone { width: 100%; max-width: 390px; margin: 0 auto 10px; border: 10px solid #111; border-radius: 34px; background: #111; box-shadow: 0 10px 30px rgba(11,31,53,.25); overflow: hidden; }
.phone-app { height: min(720px, calc(100vh - 150px)); overflow-y: auto; background: #f0f2f5; color: #1a2e4a; border-radius: 24px; font-size: 15px; line-height: 1.45; --p: #1a2e4a; --p2: #2a4a7a; --a: #c8a040; --pOn: #fff; --aOn: #1a2e4a; }

/* PocketPal app (inside the phone; uses the prospect's colors) */
.pp-head { position: sticky; top: 0; z-index: 3; display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; padding: 14px 14px 10px; background: linear-gradient(135deg, var(--p), var(--p2)); color: var(--pOn); }
.pp-brand { display: flex; gap: 10px; align-items: center; min-width: 0; }
.pp-logo { width: 40px; height: 40px; object-fit: contain; background: #fff; border-radius: 8px; padding: 3px; flex: none; }
.pp-mono { width: 40px; height: 40px; border-radius: 8px; background: var(--a); color: var(--aOn); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 1.2rem; flex: none; }
.pp-co { margin: 0; font-size: .62rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--a); filter: brightness(1.15); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pp-title { margin: 1px 0 0; font-size: 1.05rem; color: var(--pOn); }
.pp-sub { margin: 0; font-size: .7rem; opacity: .8; }
.pp-lang { display: flex; gap: 3px; flex: none; }
.pp-lang button { font: inherit; font-size: .7rem; font-weight: 700; padding: 3px 7px; border-radius: 4px; border: 1px solid currentColor; background: transparent; color: var(--pOn); opacity: .8; cursor: pointer; }
.pp-lang button.on { background: var(--a); color: var(--aOn); border-color: var(--a); opacity: 1; }
.pp-banner { display: flex; align-items: center; gap: 10px; padding: 10px 14px; background: var(--a); color: var(--aOn); }
.pp-banner > div { flex: 1; min-width: 0; }
.pp-bl { margin: 0; font-size: .6rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; opacity: .85; }
.pp-banner b { display: block; font-size: .95rem; }
.pp-bd { margin: 0; font-size: .74rem; opacity: .9; }
.pp-banner button { font: inherit; font-size: .74rem; font-weight: 700; border: 0; border-radius: 4px; padding: 5px 9px; background: rgba(0,0,0,.12); color: var(--aOn); cursor: pointer; flex: none; }
.pp-id { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 12px 14px; background: #fff; border-bottom: 1px solid #e0e4ea; }
.pp-f { display: block; min-width: 0; margin-bottom: 8px; }
.pp-id .pp-f { margin: 0; }
.pp-f span { display: block; font-size: .6rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--p); margin-bottom: 3px; }
.phone-app input, .phone-app textarea { width: 100%; font: inherit; font-size: .9rem; color: #1a2e4a; background: #f8f9fb; border: 1.5px solid #c8d0dc; border-radius: 6px; padding: 7px 9px; min-height: 36px; }
.phone-app input:focus, .phone-app textarea:focus { outline: none; border-color: var(--p); background: #fff; }
.pp-tabs { position: sticky; top: 72px; z-index: 2; display: flex; background: #fff; border-bottom: 2px solid #e0e4ea; overflow-x: auto; scrollbar-width: none; }
.pp-tab { flex: 1; font: inherit; font-size: .72rem; font-weight: 600; white-space: nowrap; padding: 10px 6px; border: 0; border-bottom: 3px solid transparent; background: none; color: #666; cursor: pointer; }
.pp-tab.on { color: var(--p); border-bottom-color: var(--a); }
.pp-panel { padding: 12px 14px; }
.pp-help { font-size: .8rem; color: #555; margin: 0 0 10px; }
.pp-h { font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--p); border-bottom: 2px solid var(--a); padding-bottom: 4px; margin: 12px 0 8px; }
.pp-card .pp-h:first-child { margin-top: 0; }
.pp-card { background: #fff; border-radius: 10px; padding: 12px; box-shadow: 0 1px 4px rgba(0,0,0,.08); margin-bottom: 10px; }
.pp-days { display: flex; gap: 5px; overflow-x: auto; margin-bottom: 10px; padding-bottom: 2px; }
.pp-day { flex: none; font: inherit; font-size: .76rem; font-weight: 600; padding: 6px 10px; border: 1.5px solid #c8d0dc; border-radius: 6px; background: #fff; color: #666; cursor: pointer; }
.pp-day.has { border-color: var(--a); color: var(--p); }
.pp-day.on { background: var(--p); border-color: var(--p); color: var(--pOn); }
.pp-ov { display: flex; gap: 10px; padding: 6px 0; border-bottom: 1px solid #f0f2f5; font-size: .82rem; }
.pp-ov:last-child { border-bottom: 0; }
.pp-ov b { min-width: 34px; color: var(--p); }
.pp-ov i, .pp-empty { color: #aaa; font-style: italic; font-size: .8rem; margin: 0; }
.pp-btn { display: block; width: 100%; font: inherit; font-weight: 700; font-size: .9rem; margin-top: 8px; padding: 11px; border: 0; border-radius: 8px; background: linear-gradient(135deg, var(--p), var(--p2)); color: var(--pOn); cursor: pointer; }
.pp-btn-a { background: var(--a); color: var(--aOn); }
.pp-inline { width: auto; margin: 0; padding: 8px 14px; align-self: flex-end; flex: none; }
.pp-habit { display: flex; gap: 10px; background: #fff; border-radius: 10px; padding: 11px; box-shadow: 0 1px 4px rgba(0,0,0,.08); margin-bottom: 8px; }
.pp-hn { flex: none; width: 26px; height: 26px; border-radius: 50%; background: var(--p); color: var(--a); font-weight: 700; font-size: .75rem; display: flex; align-items: center; justify-content: center; }
.pp-habit b { color: var(--p); font-size: .9rem; } .pp-habit p { margin: 2px 0 0; font-size: .78rem; color: #555; }
.pp-pinrow { display: flex; gap: 8px; align-items: flex-end; }
.pp-pinrow .pp-f { flex: 1; margin: 0; }
.pp-msg { min-height: 1.2em; font-size: .8rem; color: #b4473a; margin: 6px 0 0; }
.pp-row { display: flex; justify-content: space-between; align-items: baseline; }
.pp-link { font: inherit; font-size: .78rem; background: none; border: 0; color: var(--p); text-decoration: underline; cursor: pointer; padding: 0; }
.pp-stars { display: flex; gap: 4px; }
.pp-star { font-size: 1.7rem; line-height: 1; background: none; border: 0; color: #c8d0dc; cursor: pointer; padding: 2px; }
.pp-star.on { color: var(--a); }
.pp-rl { font-size: .8rem; color: #666; min-height: 1.2em; margin: 4px 0 0; }
.pp-foot { text-align: center; font-size: .6rem; letter-spacing: .08em; text-transform: uppercase; color: #888; padding: 14px; margin: 0; }

/* Simulated sheet */
.log-view { margin-top: 20px; }
.log-head { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.sheet { margin: 12px 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.sheet-tab { margin: 0; padding: 8px 12px; background: #e7f2ea; color: #1d5c34; font-weight: 700; font-size: .88rem; border-bottom: 1px solid var(--line); }
.tbl-scroll { overflow-x: auto; }
.x-tbl { border-collapse: collapse; font-size: .82rem; min-width: 100%; }
.x-tbl th { font-weight: 700; padding: 7px 9px; border: 1px solid rgba(0,0,0,.15); white-space: nowrap; text-align: left; }
.x-tbl td { padding: 6px 9px; border: 1px solid #e1e7e2; white-space: nowrap; max-width: 260px; overflow: hidden; text-overflow: ellipsis; color: var(--text); }

/* Get yours */
.price-card { display: grid; grid-template-columns: 1fr 1.4fr; gap: 24px; background: var(--navy-900); color: #dbe3ec; border-radius: var(--radius); border-left: 6px solid var(--gold); padding: clamp(22px, 4vw, 34px); margin-bottom: 20px; }
.price-card .eyebrow { color: var(--gold-light); }
.price { font-size: 2.6rem; font-weight: 800; color: #fff; margin: 0 0 6px; line-height: 1; }
.price small { font-size: 1rem; font-weight: 600; color: #b9c6d4; }
.checks { list-style: none; padding: 0; margin: 0; }
.checks li { padding: 6px 0 6px 26px; position: relative; border-bottom: 1px solid rgba(255,255,255,.1); }
.checks li::before { content: '✓'; position: absolute; left: 0; color: var(--gold-light); font-weight: 700; }
.feature-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 22px; }
.feature { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.feature .ok { color: var(--green); font-weight: 700; }
.feature b { display: block; color: var(--heading); margin: 6px 0 4px; } .feature p { font-size: .88rem; color: var(--muted); margin: 0; }
.feature.locked { border-style: dashed; background: var(--fill); }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 14px; }
.lead-card { border-top: 4px solid var(--gold); }
.lead-err { color: var(--red); font-weight: 600; margin: 12px 0 0; }
.lead-done { border-top-color: var(--green); }
.check { display: flex; gap: 10px; align-items: flex-start; margin: 10px 0 0; cursor: pointer; font-size: .95rem; }
.check input { width: 20px; height: 20px; margin-top: 2px; flex: none; accent-color: var(--navy-700); }
.bot-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.install-dialog { max-width: 460px; width: calc(100% - 32px); border: 1px solid var(--line); border-top: 4px solid var(--gold); border-radius: var(--radius); padding: 24px; background: var(--surface); color: var(--text); box-shadow: 0 12px 40px rgba(11,31,53,.25); }
.install-dialog::backdrop { background: rgba(11,31,53,.55); }
.install-step { background: var(--fill); border-radius: var(--radius); padding: 12px 14px; margin: 12px 0; }
.install-step b:first-child { color: var(--heading); } .install-step p { margin: 4px 0 0; font-size: .95rem; }
.install-dialog form { margin: 16px 0 0; text-align: right; }

.foot { text-align: center; font-size: .82rem; color: var(--muted); padding: 22px 20px 30px; border-top: 1px solid var(--line); }
.foot p { margin: 0 0 4px; }

@media (max-width: 860px) {
  .demo-grid { grid-template-columns: 1fr; }
  .pane-switch { display: flex; position: sticky; top: 50px; z-index: 5; }
  body[data-pane="customize"] .preview, body[data-pane="preview"] .customize { display: none; }
  .preview { position: static; }
  .feature-grid, .show-grid { grid-template-columns: 1fr 1fr; }
  .price-card { grid-template-columns: 1fr; }
  .facts { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  body { font-size: 16px; }
  main { padding: 16px 12px 32px; }
  .top { padding: 8px 14px; }
  .brand-text small { display: none; }
  .brand-text b { white-space: nowrap; }
  .demo-tag { font-size: .58rem; padding: 2px 5px; white-space: nowrap; }
  .grid2, .feature-grid, .show-grid { grid-template-columns: 1fr; }
  .hero-cta .btn, .row-btns .btn { width: 100%; }
  /* on a phone, show the app full width instead of inside a phone frame */
  .phone { border: 0; border-radius: var(--radius); box-shadow: var(--shadow); max-width: none; background: transparent; }
  .phone-app { height: auto; overflow: visible; border-radius: var(--radius); }
  .pp-head, .pp-tabs { position: static; }
}

/* Print: the PocketPal card only */
@media print {
  body { background: #fff; display: block; }
  .top, .tabs, .foot, .pane-switch, .customize, .preview > p, .log-view, .install-dialog, #tab-start, #tab-full, .pp-lang, .pp-banner button, .pp-tabs, .pp-btn, .pp-link { display: none !important; }
  #tab-demo, .preview { display: block !important; }
  main { padding: 0; max-width: none; }
  .phone { border: 0; box-shadow: none; max-width: none; }
  .phone-app { height: auto; overflow: visible; background: #fff; }
  .pp-head { position: static; }
  .pp-card, .pp-habit { break-inside: avoid; box-shadow: none; border: 1px solid #ddd; }
  * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
