@import url('/assets/fonts/inter/font.css');

:root {
  --ink: #202820;
  --paper: #fffaf0;
  --muted: #505c51;
  --line: #d6ddcf;
  --green: #406749;
  --button: #e3efda;
  --navy: #0a172d;
  --blue: #168cf6;
  --sky: #c9efff;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.65;
  scroll-padding-top: 104px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); }
button, input, select { font: inherit; }
button { cursor: pointer; }
a { color: #245e44; text-underline-offset: 3px; }
:focus-visible { outline: 3px solid #9d751d; outline-offset: 4px; }
.shell { width: min(1040px, calc(100% - 40px)); margin-inline: auto; }
.mobile-app { display: none; }
.desktop-only { display: block; }
.site-header-inner { display: flex !important; }

/* Desktop page: intentionally shares PebblePaste's editorial system. */
.desktop-landing { padding-bottom: 48px; }
.desktop-landing h1,
.desktop-landing h2,
.desktop-landing h3,
.desktop-landing p { margin: 0; }
.desktop-landing p + p { margin-top: 12px; }
.desktop-landing p { color: var(--muted); }
.hero-illustrated {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  align-items: center;
  gap: 44px;
  padding: 65px 0 52px;
}
.eyebrow { margin: 0; color: var(--green); font-size: 12px; font-weight: 650; letter-spacing: .07em; text-transform: none; }
.hero h1 { margin: 16px 0 24px; font-size: clamp(44px, 7vw, 76px); line-height: 1.02; letter-spacing: -.055em; }
.lead { margin-bottom: 18px !important; font-size: 21px; line-height: 1.5; }
.actions { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; margin-top: 24px; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 10px 18px;
  border: 1px solid #243d2e;
  border-radius: 6px;
  background: var(--button);
  color: #243d2e;
  text-decoration: none;
  font-weight: 650;
}
.hero-artwork { margin: 0; min-width: 0; }
.hero-artwork img { display: block; width: 100%; height: auto; border-radius: 12px; }
.desktop-landing > section:not(.hero) { padding: 34px 0; border-top: 1px solid var(--line); }
.desktop-landing h2 { margin-bottom: 20px; font-size: 28px; line-height: 1.2; letter-spacing: -.03em; }
.desktop-landing h3 { margin-bottom: 10px; font-size: 18px; line-height: 1.35; }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; }
.split aside { padding-left: 32px; border-left: 1px solid var(--line); }
.phone-qr { display: flex; align-items: center; gap: 22px; }
.phone-qr .qr-code { flex: 0 0 auto; }
.qr-code { display: grid; width: 148px; height: 148px; place-items: center; padding: 8px; background: #fff; }
.qr-code canvas, .qr-code img { display: block; width: 100%; max-width: 100%; height: auto; }
.copy-link.button { font: inherit; }
.copy-status { min-height: 20px; color: var(--green); font-size: 13px; font-weight: 650; }
.steps { display: grid; grid-template-columns: 1fr 1fr; gap: 28px 48px; margin: 0; padding-left: 24px; }
.steps li { padding-left: 6px; }
.steps li::marker { color: var(--green); font-weight: 700; }
.faq details { padding: 14px 0; border-bottom: 1px solid var(--line); }
.faq summary { min-height: 32px; cursor: pointer; font-weight: 650; }
.faq details p { max-width: 760px; margin-top: 10px; }
.wide-artwork,
.closing-artwork { margin: 0; min-width: 0; }
.wide-artwork img,
.closing-artwork img { display: block; width: 100%; height: auto; border-radius: 12px; }
.wide-artwork figcaption {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding-top: 14px;
  color: var(--muted);
  font-size: 13px;
}
.help-illustrated { display: grid; grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr); align-items: center; gap: 48px; }
.help-illustrated .eyebrow { margin-bottom: 10px; }
.bottom-phone { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 48px; }

/* Phone app: camera first, with the same navy/blue visual structure as the reference. */
.mobile-app-bar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 15px;
  background: linear-gradient(135deg, #09162a, #1a2d4a);
  color: #fff;
}
.mobile-app-bar > div { display: flex; align-items: center; gap: 11px; }
.mobile-app-bar strong { display: block; font-size: 19px; line-height: 1.15; }
.mobile-app-bar small { display: block; color: #b7c5d8; font-size: 11px; }
.mobile-mark { display: grid; width: 42px; height: 42px; place-items: center; border-radius: 15px; background: #dfe9f7; color: #0b2d65; }
.icon-button { display: grid; width: 44px; height: 44px; place-items: center; border: 1px solid rgba(255,255,255,.34); border-radius: 50%; background: rgba(255,255,255,.08); color: #fff; font-weight: 900; }
.camera-screen {
  position: relative;
  height: min(54svh, 570px);
  min-height: 360px;
  overflow: hidden;
  background-color: #d9dfe3;
  background-image: linear-gradient(45deg,#c7cdd1 25%,transparent 25%),linear-gradient(-45deg,#c7cdd1 25%,transparent 25%),linear-gradient(45deg,transparent 75%,#c7cdd1 75%),linear-gradient(-45deg,transparent 75%,#c7cdd1 75%);
  background-position: 0 0, 0 12px, 12px -12px, -12px 0;
  background-size: 24px 24px;
}
.camera-screen video,
.camera-screen canvas { display: none; width: 100%; height: 100%; object-fit: contain; }
.camera-screen.is-live video { display: block; object-fit: cover; }
.camera-screen.has-result canvas { display: block; touch-action: none; }
.placement-guide { position: absolute; inset: 9% 8%; display: none; border: 2px solid #fff; border-radius: 32px; box-shadow: 0 0 0 4px #38ce86, 0 0 0 999px rgba(6,22,45,.12); }
.is-live .placement-guide { display: block; }
.placement-guide span { position: absolute; left: 50%; bottom: 18px; width: max-content; max-width: 90%; padding: 7px 11px; border-radius: 999px; background: rgba(10,23,45,.82); color: #fff; font-size: 11px; font-weight: 800; transform: translateX(-50%); }
.empty-camera { position: absolute; inset: 0; display: grid; width: 100%; height: 100%; place-content: center; place-items: center; gap: 10px; border: 0; background: transparent; color: #10213d; }
.empty-camera span { display: grid; width: 76px; height: 76px; place-items: center; border: 2px solid #fff; border-radius: 50%; background: #ffd45c; color: #10213d; box-shadow: 0 0 0 4px #38ce86, 0 8px 18px rgba(17,39,70,.22); font-size: 40px; }
.empty-camera strong { font-size: 27px; letter-spacing: -.04em; }
.empty-camera small { color: #52647a; font-size: 14px; }
.camera-tip { position: absolute; left: 50%; bottom: 14px; width: max-content; max-width: 90%; margin: 0; padding: 9px 13px; border-radius: 999px; background: rgba(10,23,45,.84); color: #fff; font-size: 11px; font-weight: 750; text-align: center; transform: translateX(-50%); }
.camera-screen.has-result .camera-tip,
.camera-screen.has-result .placement-guide,
.camera-screen.has-result .empty-camera,
.camera-screen.is-live .empty-camera { display: none; }
.processing { position: absolute; inset: 0; z-index: 8; display: grid; place-content: center; place-items: center; gap: 8px; background: rgba(238,246,255,.92); text-align: center; }
.processing strong { font-size: 28px; }
.processing small { color: #52647a; }
.spinner { width: 50px; height: 50px; border: 5px solid #cdd9e7; border-top-color: #176bd7; border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.capture-controls { position: relative; z-index: 5; display: grid; grid-template-columns: 1fr 82px 1fr; align-items: center; gap: 12px; margin-top: -22px; padding: 22px 15px calc(22px + env(safe-area-inset-bottom)); border-radius: 26px 26px 0 0; background: linear-gradient(145deg,#178cf6,#54b2ff 58%,#c9efff); }
.secondary-button, .primary-button { min-height: 48px; padding: 10px 14px; border: 1.5px solid #0a356f; border-radius: 13px; font-weight: 850; }
.secondary-button { background: rgba(255,255,255,.92); color: #0f438e; }
.primary-button { background: #0a356f; color: #fff; }
.shutter { display: grid; width: 76px; height: 76px; place-items: center; border: 3px solid #fff; border-radius: 50%; background: rgba(255,255,255,.28); }
.shutter span { width: 58px; height: 58px; border-radius: 50%; background: #fff; box-shadow: inset 0 0 0 5px #178cf6; }
.shutter:disabled { opacity: .45; }
.result-sheet, .done-sheet { position: relative; z-index: 4; margin-top: -26px; padding: 22px 16px calc(24px + env(safe-area-inset-bottom)); border-radius: 30px 30px 0 0; background: linear-gradient(145deg,#178cf6,#54b2ff 58%,#c9efff); color: #0c2c68; box-shadow: 0 -8px 25px rgba(10,36,75,.18); }
.result-count { display: flex; align-items: baseline; justify-content: center; gap: 10px; padding: 18px; border-radius: 20px; background: rgba(255,255,255,.92); }
.result-count strong { font-size: 78px; line-height: .86; letter-spacing: -.07em; }
.result-count span { font-size: 20px; font-weight: 800; }
.result-message { min-height: 38px; margin: 12px 0; padding: 12px 14px; border-radius: 16px; background: rgba(255,255,255,.88); color: #52647a; font-size: 13px; line-height: 1.45; }
.range-row { display: grid; gap: 9px; margin-top: 10px; padding: 14px; border-radius: 16px; background: rgba(255,255,255,.9); }
.range-row span { display: flex; justify-content: space-between; font-size: 14px; font-weight: 800; }
.range-row input { width: 100%; height: 28px; accent-color: #1678e6; }
.adjust-details { border: 0; }
.adjust-details summary { min-height: 48px; padding: 14px 0; color: #fff; font-weight: 850; }
.result-actions { display: grid; grid-template-columns: 1fr 1.4fr; gap: 10px; margin-top: 8px; }
.done-sheet { text-align: center; }
.done-count { display: block; font-size: 100px; line-height: .9; letter-spacing: -.08em; }
.done-label { display: block; font-size: 21px; font-weight: 850; }
.done-sheet p:not(.eyebrow) { color: #234e84; }
.done-sheet button { display: block; width: 100%; margin-top: 10px; }
.recent-counts { padding: 27px 16px 80px; background: #eaf2fb; }
.recent-counts h2 { margin: 5px 0 16px; font-size: 27px; }
.recent-counts ol { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.recent-counts li { display: flex; align-items: center; justify-content: space-between; min-height: 54px; padding: 10px 14px; border: 1px solid #cdd9e7; border-radius: 13px; background: #fff; }
.recent-counts strong { font-size: 21px; }
.recent-counts time { color: #52647a; font-size: 12px; }
.recent-counts .empty-history { justify-content: flex-start; color: #52647a; }
.settings-sheet { position: fixed; inset: auto 0 0; width: 100%; max-width: none; max-height: 88svh; margin: 0; padding: 0; border: 0; border-top: 2px solid #0a172d; border-radius: 24px 24px 0 0; background: #fff; }
.settings-sheet::backdrop { background: rgba(10,23,45,.56); }
.settings-sheet form { display: grid; gap: 15px; padding: 20px 16px calc(22px + env(safe-area-inset-bottom)); overflow: auto; }
.settings-sheet header { display: flex; align-items: start; justify-content: space-between; }
.settings-sheet h2 { margin: 4px 0 0; font-size: 30px; }
.settings-sheet > form > label:not(.toggle-row) { display: grid; gap: 6px; font-weight: 800; }
.settings-sheet select { min-height: 48px; padding: 9px 12px; border: 1.5px solid #0a172d; border-radius: 12px; background: #fff; }
.toggle-row { display: flex; min-height: 58px; align-items: center; justify-content: space-between; gap: 16px; border-top: 1px solid #d5dde7; }
.toggle-row span { display: grid; gap: 3px; }
.toggle-row small { color: #52647a; font-weight: 400; }
.toggle-row input { width: 24px; height: 24px; accent-color: #176bd7; }
.settings-sheet section { padding-top: 13px; border-top: 1px solid #d5dde7; }
.settings-sheet h3 { margin: 0 0 5px; }
.settings-sheet p { margin: 0; color: #52647a; line-height: 1.55; }

@media (max-width: 767px) {
  html, body, .mobile-app { background: #eaf2fb; }
  .desktop-only { display: none !important; }
  .mobile-app { display: block; min-height: 100svh; }
}

@media (min-width: 768px) and (max-width: 900px) {
  .hero-illustrated { grid-template-columns: 1fr; gap: 28px; }
  .hero-artwork { max-width: 600px; }
  .help-illustrated { grid-template-columns: 1fr; gap: 24px; }
}

@media (max-width: 700px) {
  .shell { width: calc(100% - 32px); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .spinner { animation: none; }
}
