/* PingMeMeds site. The app's own palette and font (Atkinson Hyperlegible, made for low vision), light and dark. */
@font-face { font-family: "Atkinson"; src: url("/pingmemeds/fonts/atkinson_regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Atkinson"; src: url("/pingmemeds/fonts/atkinson_bold.ttf") format("truetype"); font-weight: 700; font-display: swap; }

:root {
  --bg: #F5F5F7; --surface: #FFFFFF; --ink: #17181F; --text2: #4A4D5E; --muted: #6B6E80; --line: #E3E4EC;
  --accent: #3438B0; --accent-2: #5B5FD6; --tint: #ECEDFB; --amber: #F2B33A; --good: #1E8A6E;
  --night: #14164A; --night-card: #23277A; --soft: #C9CBF7;
  --shadow: 0 30px 80px -30px rgba(23, 24, 64, .45);
  --r: 22px; --wrap: 1180px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0F1018; --surface: #181A26; --ink: #ECEDF5; --text2: #B9BBCC; --muted: #8E91A6; --line: #2A2D3D;
    --accent: #8F93FF; --accent-2: #B2B5FF; --tint: #20234A; --good: #5FD0AE;
    --shadow: 0 30px 80px -30px rgba(0, 0, 0, .8);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 18px/1.6 "Atkinson", system-ui, sans-serif; overflow-x: hidden; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); }
h1, h2, h3, h4 { line-height: 1.12; margin: 0; letter-spacing: -.02em; }
p { margin: 0; }
.wrap { width: min(var(--wrap), 100% - 32px); margin-inline: auto; }
.wrap.narrow { width: min(780px, 100% - 32px); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--accent); color: #fff; padding: 10px 14px; border-radius: 10px; z-index: 100; }
.skip:focus { left: 16px; }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 3px; border-radius: 6px; }

/* ---- header ---- */
.bar { position: sticky; top: 0; z-index: 50; display: flex; align-items: center; gap: 24px; padding: 14px max(16px, calc((100% - var(--wrap)) / 2));
  background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid transparent; transition: border-color .3s; }
.bar.is-scrolled { border-bottom-color: var(--line); }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 700; font-size: 20px; letter-spacing: -.01em; }
.brand svg { width: 36px; height: 36px; border-radius: 10px; }
.bar-nav { display: flex; gap: 22px; margin-left: auto; }
.bar-nav a { color: var(--text2); text-decoration: none; font-size: 16px; }
.bar-nav a:hover { color: var(--ink); }
.bar-right { display: flex; align-items: center; gap: 10px; }
.bar-cta { display: inline-flex; align-items: center; min-height: 44px; padding: 0 18px; border-radius: 999px; background: var(--accent); color: #fff; text-decoration: none; font-weight: 700; font-size: 15px; white-space: nowrap; }
.bar-cta[aria-disabled="true"] { background: var(--tint); color: var(--accent); cursor: default; }
.bar-cta .short { display: none; }
.menu-btn { display: none; width: 44px; height: 44px; border: 0; border-radius: 12px; background: var(--surface); position: relative; cursor: pointer; }
.menu-btn i { position: absolute; left: 12px; right: 12px; height: 2px; background: var(--ink); border-radius: 2px; transition: transform .3s, top .3s; }
.menu-btn i:first-child { top: 17px; } .menu-btn i:last-child { top: 25px; }
.menu-btn[aria-expanded="true"] i:first-child { top: 21px; transform: rotate(45deg); }
.menu-btn[aria-expanded="true"] i:last-child { top: 21px; transform: rotate(-45deg); }

/* ---- buttons, labels ---- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 56px; padding: 0 26px; border-radius: 18px; border: 0;
  background: var(--accent); color: #fff; font: 700 18px/1 "Atkinson", sans-serif; text-decoration: none; cursor: pointer; transition: transform .2s, box-shadow .2s; }
.btn:hover { transform: translateY(-2px); box-shadow: 0 14px 30px -14px var(--accent); }
.btn[aria-disabled="true"] { cursor: default; }
.btn[aria-disabled="true"]:hover { transform: none; box-shadow: none; }
.btn.ghost { background: var(--surface); color: var(--accent); border: 2px solid var(--line); }
.btn.ghost svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.btn.light { background: #fff; color: var(--night); }
.eyebrow, .kicker { display: inline-flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.eyebrow .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--amber); box-shadow: 0 0 0 0 rgba(242, 179, 58, .6); animation: beat 2.4s infinite; }
.kicker.light { color: var(--soft); }
.big { font-size: clamp(34px, 5vw, 60px); margin: 10px 0 28px; }
.big.light, .lead.light { color: #fff; }
.lead { font-size: clamp(19px, 1.6vw, 22px); color: var(--text2); max-width: 36em; }
.lead.light { color: var(--soft); }
.hl { background: linear-gradient(120deg, var(--accent), var(--accent-2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hl-light { color: var(--amber); }

/* ---- hero ---- */
/* overflow-x: clip keeps the growing ping rings from widening the page on phones. */
.hero { padding: clamp(28px, 6vw, 72px) 0 40px; overflow-x: clip; }
.story { overflow-x: clip; }
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; align-items: center; gap: 40px; }
.hero h1 { font-size: clamp(48px, 7.6vw, 104px); margin: 16px 0 22px; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin: 30px 0 22px; }
.ticks { display: flex; flex-wrap: wrap; gap: 8px 22px; list-style: none; padding: 0; margin: 0; color: var(--text2); font-size: 16px; }
.ticks li::before { content: ""; display: inline-block; width: 18px; height: 10px; margin-right: 8px; border: solid var(--good); border-width: 0 0 3px 3px; transform: translateY(-4px) rotate(-45deg); }
.hero-phone { position: relative; display: grid; place-items: center; min-height: 560px; }
.phone { position: relative; margin: 0; width: min(300px, 74vw); aspect-ratio: 1 / 2; border-radius: 46px; padding: 10px; background: #0D0E1A; box-shadow: var(--shadow), inset 0 0 0 2px #2B2E45; z-index: 1; }
.phone img { width: 100%; height: 100%; object-fit: cover; border-radius: 36px; }
.rings { position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none; }
.rings i { position: absolute; width: 300px; aspect-ratio: 1; border-radius: 50%; border: 2px solid var(--accent); opacity: 0; animation: ping 3.6s cubic-bezier(.2, .6, .3, 1) infinite; }
.rings i:nth-child(2) { animation-delay: 1.2s; } .rings i:nth-child(3) { animation-delay: 2.4s; }
.rings.burst i { animation: ping 1.2s cubic-bezier(.2, .6, .3, 1) 3; }
.rings.burst i:nth-child(2) { animation-delay: .2s; } .rings.burst i:nth-child(3) { animation-delay: .4s; }
.toast { position: absolute; z-index: 2; top: 54px; left: 50%; width: min(360px, 88vw); display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: 22px;
  background: color-mix(in srgb, var(--surface) 92%, transparent); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); box-shadow: 0 20px 50px -20px rgba(20, 22, 74, .5); border: 1px solid var(--line);
  transform: translate(-50%, -30px) scale(.96); opacity: 0; transition: transform .6s cubic-bezier(.2, .9, .3, 1.2), opacity .4s; }
.toast.is-on { transform: translate(-50%, 0) scale(1); opacity: 1; }
.toast svg { width: 40px; height: 40px; flex: none; border-radius: 11px; }
.toast div { display: flex; flex-direction: column; min-width: 0; }
.toast b { font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.toast span { font-size: 14px; color: var(--text2); }
.toast em { margin-left: auto; font-style: normal; font-size: 13px; color: var(--muted); align-self: flex-start; }

/* ---- story ---- */
.story { padding: 60px 0 20px; }
.story-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; }
.step { min-height: 72vh; display: flex; flex-direction: column; justify-content: center; gap: 14px; opacity: .35; transition: opacity .5s; }
.step.is-on { opacity: 1; }
.step-time { display: inline-flex; align-self: flex-start; padding: 6px 14px; border-radius: 999px; background: var(--tint); color: var(--accent); font-weight: 700; font-size: 15px; }
.step h3 { font-size: clamp(28px, 3vw, 40px); }
.step p { font-size: 19px; color: var(--text2); max-width: 30em; }
.step-shot { display: none; }
.stage { position: relative; }
.stage-inner { position: sticky; top: 10vh; height: 80vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px; }
/* The phone fits the window height, so the clock above it never covers the screen. */
.stage .phone { width: min(320px, 30vw, 34vh); }
.stage .shot { position: absolute; inset: 10px; width: calc(100% - 20px); height: calc(100% - 20px); opacity: 0; transition: opacity .55s ease; }
.stage .shot.is-on { opacity: 1; }
.stage.ringing .phone { animation: buzz .5s ease-in-out 3; }
.rings.small i { width: 330px; animation-duration: 4.8s; opacity: 0; }
.stage:not(.ringing) .rings.small i { animation-play-state: paused; opacity: 0; }
.clock { position: relative; z-index: 2; display: inline-flex; align-items: center; gap: 10px; padding: 8px 16px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); box-shadow: 0 10px 30px -18px rgba(20, 22, 74, .5); font-weight: 700; }
.clock i { width: 12px; height: 12px; border-radius: 50%; background: var(--amber); }
.stage.ringing .clock i { animation: beat 1s infinite; }

/* ---- sections ---- */
.section { padding: clamp(60px, 9vw, 120px) 0; }
.cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 24px; display: flex; flex-direction: column; gap: 10px; transition: transform .3s, box-shadow .3s; }
.card:hover { transform: translateY(-4px); box-shadow: 0 24px 50px -30px rgba(20, 22, 74, .5); }
.card svg { width: 44px; height: 44px; padding: 10px; border-radius: 14px; background: var(--tint); fill: none; stroke: var(--accent); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.card h3 { font-size: 21px; }
.card p { font-size: 16px; color: var(--text2); }

.privacy { background: radial-gradient(ellipse at 85% 10%, rgba(91, 95, 214, .45), transparent 55%), var(--night); color: #fff; padding: clamp(70px, 10vw, 130px) 0; }
.privacy-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: 50px; align-items: center; }
.privacy .lead { margin-bottom: 22px; }
.link-light { color: var(--amber); font-weight: 700; text-decoration: none; }
.zeros { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.zero { background: var(--night-card); border-radius: var(--r); padding: 26px 22px; display: flex; flex-direction: column; }
.zero b { font-size: 64px; line-height: 1; color: #fff; }
.zero span { color: var(--soft); font-size: 17px; margin-top: 6px; }

.plans { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.plan { background: var(--surface); border: 1px solid var(--line); border-radius: 28px; padding: 32px; }
.plan h3 { font-size: 32px; }
.plan-sub { color: var(--text2); margin: 6px 0 18px; }
.plan ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.plan li { padding-left: 32px; position: relative; }
.plan li::before { content: ""; position: absolute; left: 2px; top: 6px; width: 16px; height: 9px; border: solid var(--good); border-width: 0 0 3px 3px; transform: rotate(-45deg); }
.plan.pro { background: linear-gradient(160deg, var(--accent), #262A8F); color: #fff; border-color: transparent; }
.plan.pro .plan-sub, .plan.pro .plan-note { color: var(--soft); }
.plan.pro li::before { border-color: var(--amber); }
.plan-note { margin-top: 22px; font-size: 15px; }

.faq details { border-bottom: 1px solid var(--line); padding: 4px 0; }
.faq summary { cursor: pointer; list-style: none; font-weight: 700; font-size: 20px; padding: 18px 40px 18px 0; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 6px; top: 50%; transform: translateY(-50%); font-size: 28px; color: var(--accent); transition: transform .3s; }
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details p { color: var(--text2); padding-bottom: 18px; }
.faq-more { margin-top: 24px; color: var(--text2); }

.final { background: radial-gradient(ellipse at 50% 120%, rgba(242, 179, 58, .35), transparent 55%), var(--night); padding: clamp(70px, 10vw, 120px) 0; text-align: center; }
.final-inner { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.final-icon { width: 84px; height: 84px; border-radius: 22px; animation: float 4s ease-in-out infinite; }

/* ---- footer ---- */
.foot { padding: 56px 0 40px; border-top: 1px solid var(--line); }
.foot-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 30px; }
.foot-grid h4 { font-size: 15px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin-bottom: 12px; }
.foot-grid a:not(.brand) { display: block; color: var(--text2); text-decoration: none; padding: 4px 0; font-size: 16px; }
.foot-grid a:hover { color: var(--ink); }
.foot-note { color: var(--text2); margin-top: 12px; font-size: 16px; max-width: 24em; }
.foot-legal { margin-top: 36px; color: var(--muted); font-size: 14px; }
.foot-legal a { color: inherit; }

/* ---- document pages ---- */
.doc-hero { padding: 80px 0; }
.doc-hero h1 { font-size: clamp(40px, 6vw, 72px); margin: 14px 0; }
.doc-hero .btn { margin-top: 24px; }
.prose { max-width: 760px; margin: 0 auto; padding: 50px 0 80px; }
.prose h1 { font-size: clamp(34px, 5vw, 52px); margin-bottom: 18px; }
.prose h2 { font-size: 28px; margin: 44px 0 12px; }
.prose h3 { font-size: 21px; margin: 28px 0 8px; }
.prose p, .prose li { color: var(--text2); }
.prose p { margin: 0 0 14px; }
.prose ul { padding-left: 22px; margin: 0 0 14px; }
.prose .lead { margin-bottom: 26px; }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 34px 0; }
.prose strong { color: var(--ink); }
.prose .table { overflow-x: auto; margin: 0 0 18px; }
.prose table { border-collapse: collapse; width: 100%; font-size: 16px; }
.prose th, .prose td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.prose th { color: var(--ink); }

/* ---- motion ---- */
.rise { animation: rise .8s cubic-bezier(.2, .8, .2, 1) both; }
.rise.r1 { animation-delay: .08s; } .rise.r2 { animation-delay: .16s; } .rise.r3 { animation-delay: .24s; } .rise.r4 { animation-delay: .32s; }
[data-reveal] { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s cubic-bezier(.2, .8, .2, 1); }
[data-reveal].is-in { opacity: 1; transform: none; }
.no-js [data-reveal] { opacity: 1; transform: none; }
@keyframes rise { from { opacity: 0; transform: translateY(24px); } }
@keyframes ping { 0% { transform: scale(.7); opacity: .55; } 100% { transform: scale(1.7); opacity: 0; } }
@keyframes beat { 0% { box-shadow: 0 0 0 0 rgba(242, 179, 58, .6); } 70% { box-shadow: 0 0 0 12px rgba(242, 179, 58, 0); } 100% { box-shadow: 0 0 0 0 rgba(242, 179, 58, 0); } }
@keyframes buzz { 0%, 100% { transform: rotate(0); } 25% { transform: rotate(-2deg); } 75% { transform: rotate(2deg); } }
@keyframes float { 0%, 100% { transform: translateY(0) rotate(-4deg); } 50% { transform: translateY(-10px) rotate(4deg); } }

/* ---- smaller screens ---- */
@media (max-width: 1060px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .bar-nav { gap: 16px; }
}
@media (max-width: 900px) {
  .menu-btn { display: block; }
  .bar { gap: 12px; }
  .bar-nav { position: fixed; inset: 72px 0 auto 0; flex-direction: column; gap: 0; padding: 8px 16px 18px; background: var(--bg); border-bottom: 1px solid var(--line);
    transform: translateY(-12px); opacity: 0; pointer-events: none; transition: transform .3s, opacity .3s; margin: 0; }
  .bar-nav.is-open { transform: none; opacity: 1; pointer-events: auto; }
  .bar-nav a { padding: 14px 4px; font-size: 18px; border-bottom: 1px solid var(--line); }
  .bar-right { margin-left: auto; }
  .hero-grid, .story-grid, .privacy-grid, .plans { grid-template-columns: 1fr; }
  .hero-phone { min-height: 0; padding: 40px 0 10px; }
  .stage { display: none; }
  .step { min-height: 0; opacity: 1; padding: 30px 0; }
  .step-shot { display: block; width: min(280px, 72vw); border-radius: 30px; box-shadow: var(--shadow); border: 8px solid #0D0E1A; margin-top: 12px; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  body { font-size: 17px; }
  .bar-cta .long { display: none; } .bar-cta .short { display: inline; }
  .brand span { font-size: 18px; }
  .cards { grid-template-columns: 1fr; }
  .btn { width: 100%; }
  .zero b { font-size: 48px; }
  .toast { top: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  [data-reveal] { opacity: 1; transform: none; }
  .toast { opacity: 1; transform: translate(-50%, 0); }
}

/* ---- early access ---- */
.early { padding-top: 0; }
.early-card { display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px; align-items: center; padding: clamp(28px, 5vw, 56px); border-radius: 32px;
  background: radial-gradient(ellipse at 90% 0%, rgba(242, 179, 58, .28), transparent 50%), radial-gradient(ellipse at 0% 100%, rgba(91, 95, 214, .55), transparent 60%), var(--night); color: #fff; }
.early-card .big { margin-bottom: 14px; }
.early-form { display: flex; flex-direction: column; gap: 10px; }
.early-label { font-weight: 700; color: var(--soft); font-size: 16px; }
.early-row { display: flex; gap: 10px; }
.early-row input { flex: 1; min-width: 0; min-height: 56px; padding: 0 18px; border-radius: 16px; border: 2px solid rgba(201, 203, 247, .4); background: rgba(255, 255, 255, .08);
  color: #fff; font: 400 18px "Atkinson", sans-serif; }
.early-row input::placeholder { color: rgba(201, 203, 247, .6); }
.early-row input:focus { outline: none; border-color: var(--amber); background: rgba(255, 255, 255, .12); }
.early-row input[aria-invalid="true"] { border-color: #FF9C8A; }
.early-trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.early-msg { min-height: 1.6em; font-weight: 700; color: var(--amber); }
.early-msg.bad { color: #FF9C8A; }
.early-fine { font-size: 14px; color: var(--soft); }
.early-fine a { color: #fff; }
.early-form.done .early-row { display: none; }
@media (max-width: 900px) { .early-card { grid-template-columns: 1fr; } }
@media (max-width: 520px) { .early-row { flex-direction: column; } }
