/* Don't Forget — dontforget.fartingpixel.com
   Editorial dark: warm ink on near-black indigo, Instrument Serif display,
   paper "receipts" as the recurring visual metaphor for what forgetting costs. */

@font-face {
  font-family: 'Instrument Serif';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/assets/fonts/instrument-serif-regular.woff2') format('woff2');
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('/assets/fonts/instrument-serif-italic.woff2') format('woff2');
}

:root {
  --bg: #0a0812;
  --ink: #f2eee6;
  --muted: #a29cb3;
  --coral: #ff6b47;
  --coral-soft: rgba(255, 107, 71, 0.14);
  --violet: #7a35c9;
  --paper: #f5efe2;
  --paper-ink: #1b1526;
  --paper-muted: #6b6353;
  --line: rgba(242, 238, 230, 0.14);
  --surface: rgba(242, 238, 230, 0.05);
  --serif: 'Instrument Serif', 'Iowan Old Style', Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, monospace;
  --maxw: 72rem;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Film grain — the cheap trick that kills the "flat gradient" look. */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 999;
  pointer-events: none;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

a { color: var(--coral); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

img, svg { max-width: 100%; height: auto; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 1.4rem; }

.display {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.015em;
  line-height: 1.02;
}
.display em {
  font-style: italic;
  color: var(--coral);
}

.skip-link { position: absolute; left: -9999px; }
.skip-link:focus {
  left: 1rem; top: 1rem; z-index: 100;
  background: var(--bg); color: var(--ink);
  padding: 0.5rem 1rem; border-radius: 8px;
}

/* ---------- Header / footer ---------- */

header.site {
  position: sticky; top: 0; z-index: 10;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  background: rgba(10, 8, 18, 0.65);
  border-bottom: 1px solid var(--line);
}
header.site .wrap {
  display: flex; align-items: center; justify-content: space-between;
  padding-top: 0.85rem; padding-bottom: 0.85rem;
}
.brand {
  display: flex; align-items: center; gap: 0.55rem;
  font-family: var(--serif); font-size: 1.25rem; color: var(--ink);
}
.brand:hover { text-decoration: none; }
.brand svg { width: 26px; height: 26px; }
nav.main a { color: var(--muted); margin-left: 1.5rem; font-size: 0.95rem; }
nav.main a:hover { color: var(--ink); text-decoration: none; }

footer.site {
  border-top: 1px solid var(--line);
  padding: 2.5rem 0 3rem;
  color: var(--muted);
  font-size: 0.9rem;
}
footer.site .wrap { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between; }
footer.site a { color: var(--muted); }
footer.site a:hover { color: var(--ink); }

/* ---------- Buttons ---------- */

.btn {
  display: inline-block;
  padding: 0.9rem 1.7rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 1rem;
}
.btn.primary {
  background: var(--coral);
  color: #1c0c06;
  box-shadow: 0 8px 30px rgba(255, 107, 71, 0.25);
}
.btn.primary:hover { text-decoration: none; filter: brightness(1.07); }
.btn.ghost { border: 1px solid var(--line); color: var(--ink); background: var(--surface); }
.btn.ghost:hover { text-decoration: none; background: rgba(242, 238, 230, 0.1); }
.note { color: var(--muted); font-size: 0.85rem; margin-top: 1rem; }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  padding: 7rem 0 6rem;
  min-height: 88vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.glow {
  position: absolute; border-radius: 50%; filter: blur(90px); pointer-events: none;
}
.glow.a {
  width: 44rem; height: 44rem; top: -18rem; right: -12rem;
  background: radial-gradient(circle, rgba(122, 53, 201, 0.45), transparent 65%);
  animation: drift-a 26s ease-in-out infinite alternate;
}
.glow.b {
  width: 36rem; height: 36rem; bottom: -16rem; left: -10rem;
  background: radial-gradient(circle, rgba(255, 107, 71, 0.28), transparent 65%);
  animation: drift-b 32s ease-in-out infinite alternate;
}
@keyframes drift-a { to { transform: translate(-6rem, 5rem) scale(1.15); } }
@keyframes drift-b { to { transform: translate(5rem, -4rem) scale(1.1); } }

.hero .wrap { position: relative; }

.siri-line {
  display: inline-flex; align-items: baseline; gap: 0.5rem;
  font-family: var(--mono); font-size: 0.95rem;
  color: var(--muted);
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 999px;
  padding: 0.55rem 1.1rem;
  margin-bottom: 2.2rem;
  max-width: 100%;
}
.siri-line .say { color: var(--ink); white-space: nowrap; }
.siri-typer { color: var(--coral); }
.caret {
  display: inline-block; width: 1px; height: 1em;
  background: var(--coral); vertical-align: -0.15em;
  animation: blink 1.1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

.hero h1 {
  font-size: clamp(3.2rem, 11vw, 8rem);
  margin-bottom: 1.6rem;
  max-width: 12ch;
}
.hero .forget {
  display: inline-block;
  animation: dissolve 7s ease-in-out infinite;
}
@keyframes dissolve {
  0%, 55%, 100% { opacity: 1; filter: blur(0); }
  70%, 78% { opacity: 0.18; filter: blur(7px); }
  92% { opacity: 1; filter: blur(0); }
}
.hero .sub {
  color: var(--muted);
  font-size: clamp(1.05rem, 2.2vw, 1.3rem);
  max-width: 34rem;
  margin-bottom: 2.4rem;
}
.hero .sub strong { color: var(--ink); font-weight: 600; }
.cta-row { display: flex; gap: 0.9rem; flex-wrap: wrap; }

/* ---------- Shared section rhythm ---------- */

section { padding: 6rem 0; }
.kicker {
  font-family: var(--mono);
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--coral);
  margin-bottom: 1rem;
}
section h2.display {
  font-size: clamp(2.2rem, 5.5vw, 3.8rem);
  max-width: 22ch;
  margin-bottom: 1.2rem;
}
.lead { color: var(--muted); max-width: 40rem; font-size: 1.08rem; }

.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Forgetting curve ---------- */

.curve-grid {
  display: grid; gap: 3rem; align-items: center;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
}
@media (max-width: 860px) { .curve-grid { grid-template-columns: 1fr; } }
.curve-copy p { color: var(--muted); margin-bottom: 1rem; max-width: 36rem; }
.curve-copy p strong { color: var(--ink); }
.curve-figure {
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
  padding: 1.6rem 1.4rem 1rem;
}
.curve-figure figcaption {
  font-family: var(--mono); font-size: 0.75rem;
  color: var(--muted); margin-top: 0.8rem;
}
.curve-figure .axis-label { font-family: var(--mono); font-size: 11px; fill: var(--muted); }
.curve-figure .pin-label { font-family: var(--mono); font-size: 10.5px; fill: #ffb39e; }
.curve-figure .decay { stroke: #5e5870; stroke-dasharray: 5 6; }
.curve-figure .saved {
  stroke: var(--coral);
  stroke-dasharray: 1200;
  stroke-dashoffset: 1200;
}
.curve-figure.in .saved { animation: draw 2.4s ease forwards 0.3s; }
@keyframes draw { to { stroke-dashoffset: 0; } }

/* ---------- Receipts ---------- */

.receipts { overflow: hidden; padding-bottom: 7rem; }
.receipts .wrap { margin-bottom: 2.6rem; }
.marquee {
  display: flex; gap: 1.4rem; width: max-content;
  transform: rotate(-1.2deg);
  animation: marquee 55s linear infinite;
  padding: 1.4rem 0;
}
.marquee:hover { animation-play-state: paused; }
@keyframes marquee { to { transform: rotate(-1.2deg) translateX(-50%); } }

.receipt {
  background: var(--paper);
  color: var(--paper-ink);
  width: 17rem;
  flex-shrink: 0;
  padding: 1.3rem 1.3rem 1.6rem;
  font-family: var(--mono);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.45);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 8px),
    95% 100%, 90% calc(100% - 8px), 85% 100%, 80% calc(100% - 8px), 75% 100%,
    70% calc(100% - 8px), 65% 100%, 60% calc(100% - 8px), 55% 100%,
    50% calc(100% - 8px), 45% 100%, 40% calc(100% - 8px), 35% 100%,
    30% calc(100% - 8px), 25% 100%, 20% calc(100% - 8px), 15% 100%,
    10% calc(100% - 8px), 5% 100%, 0 calc(100% - 8px));
}
.receipt .cost {
  font-family: var(--serif);
  font-size: 2.1rem;
  line-height: 1.1;
  margin-bottom: 0.4rem;
}
.receipt .what { font-size: 0.8rem; line-height: 1.5; color: var(--paper-muted); }
.receipt .rule { border-top: 1px dashed rgba(27, 21, 38, 0.35); margin: 0.7rem 0; }
.receipts .closer {
  font-family: var(--serif); font-style: italic;
  font-size: clamp(1.3rem, 3vw, 1.8rem);
  color: var(--ink); text-align: center; margin-top: 2.8rem;
}

/* ---------- Product ---------- */

.product-grid {
  display: grid; gap: 4rem; align-items: center;
  grid-template-columns: minmax(0, 4fr) minmax(0, 6fr);
}
@media (max-width: 860px) { .product-grid { grid-template-columns: 1fr; } }

.iphone {
  width: min(300px, 78vw);
  margin: 0 auto;
  border-radius: 44px;
  border: 1px solid rgba(242, 238, 230, 0.22);
  background: #060410;
  box-shadow:
    0 0 0 10px #17131f,
    0 0 0 11px rgba(242, 238, 230, 0.12),
    0 30px 80px rgba(0, 0, 0, 0.6),
    0 0 120px rgba(122, 53, 201, 0.18);
  padding: 1rem 0.9rem 1.6rem;
  position: relative;
}
.iphone .island {
  width: 34%; height: 20px; border-radius: 12px;
  background: #000; margin: 0.1rem auto 1.1rem;
  border: 1px solid rgba(242, 238, 230, 0.08);
}
.iphone .greeting {
  font-family: var(--serif);
  font-size: 1.45rem;
  padding: 0 0.4rem 0.8rem;
}
.iphone .row {
  display: flex; gap: 0.6rem; align-items: flex-start;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 14px;
  padding: 0.65rem 0.7rem;
  margin-bottom: 0.55rem;
}
.iphone .row .dot {
  width: 26px; height: 26px; flex-shrink: 0;
  border-radius: 50%; display: grid; place-items: center;
  font-size: 0.75rem;
}
.iphone .dot.bell { background: var(--coral-soft); }
.iphone .dot.alarm { background: rgba(255, 69, 58, 0.18); }
.iphone .dot.spark { background: rgba(122, 53, 201, 0.25); }
.iphone .row .t { font-size: 0.78rem; line-height: 1.35; }
.iphone .row .t small { display: block; color: var(--muted); font-size: 0.68rem; }
.iphone .chip-q {
  border: 1px solid rgba(255, 107, 71, 0.35);
  background: var(--coral-soft);
  border-radius: 14px;
  padding: 0.7rem 0.75rem;
  margin: 0.8rem 0 0.55rem;
  font-size: 0.78rem;
}
.iphone .chip-q .mini-btns { display: flex; gap: 0.4rem; margin-top: 0.5rem; }
.iphone .chip-q .mini-btns span {
  border-radius: 999px; padding: 0.15rem 0.7rem; font-size: 0.7rem;
  background: var(--coral); color: #1c0c06; font-weight: 600;
}
.iphone .chip-q .mini-btns span + span { background: transparent; border: 1px solid var(--line); color: var(--ink); }

.notice-list { list-style: none; margin-top: 2.2rem; }
.notice-list li {
  display: flex; gap: 1.1rem; align-items: baseline;
  padding: 1.1rem 0;
  border-top: 1px solid var(--line);
  color: var(--muted);
}
.notice-list li:last-child { border-bottom: 1px solid var(--line); }
.notice-list .num {
  font-family: var(--serif); font-style: italic;
  color: var(--coral); font-size: 1.3rem;
  min-width: 2rem;
}
.notice-list strong { color: var(--ink); font-weight: 600; }
.verbs {
  margin-top: 2rem;
  font-family: var(--serif); font-style: italic;
  font-size: clamp(1.4rem, 3vw, 1.9rem);
}
.verbs span { color: var(--coral); }

/* ---------- Privacy ---------- */

.privacy-section { text-align: center; }
.privacy-section h2 { margin-inline: auto; }
.privacy-section .lead { margin: 0 auto 3rem; }
.server-receipt {
  width: min(21rem, 90vw);
  margin: 0 auto;
  background: var(--paper);
  color: var(--paper-ink);
  font-family: var(--mono);
  font-size: 0.82rem;
  text-align: left;
  padding: 1.5rem 1.4rem 1.8rem;
  transform: rotate(1.4deg);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.5);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 8px),
    95% 100%, 90% calc(100% - 8px), 85% 100%, 80% calc(100% - 8px), 75% 100%,
    70% calc(100% - 8px), 65% 100%, 60% calc(100% - 8px), 55% 100%,
    50% calc(100% - 8px), 45% 100%, 40% calc(100% - 8px), 35% 100%,
    30% calc(100% - 8px), 25% 100%, 20% calc(100% - 8px), 15% 100%,
    10% calc(100% - 8px), 5% 100%, 0 calc(100% - 8px));
}
.server-receipt h3 {
  text-align: center; font-size: 0.85rem; letter-spacing: 0.1em;
  border-bottom: 1px dashed rgba(27, 21, 38, 0.35);
  padding-bottom: 0.7rem; margin-bottom: 0.7rem;
}
.server-receipt .line { display: flex; justify-content: space-between; padding: 0.2rem 0; }
.server-receipt .total {
  display: flex; justify-content: space-between;
  border-top: 1px dashed rgba(27, 21, 38, 0.35);
  margin-top: 0.7rem; padding-top: 0.7rem;
  font-weight: 700;
}
.server-receipt .thanks {
  text-align: center; margin-top: 1rem; color: var(--paper-muted); font-size: 0.72rem;
}
.privacy-section .after { color: var(--muted); max-width: 34rem; margin: 2.6rem auto 0; }

/* ---------- FAQ ---------- */

.faq { margin-top: 2rem; }
.faq details {
  border-top: 1px solid var(--line);
  padding: 1.1rem 0.2rem;
}
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary {
  cursor: pointer; font-weight: 600; list-style: none;
  display: flex; justify-content: space-between; gap: 1rem; align-items: baseline;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  font-family: var(--serif);
  color: var(--coral);
  font-size: 1.4rem; line-height: 1;
  transition: transform 0.25s ease;
  flex-shrink: 0;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { color: var(--muted); margin-top: 0.7rem; max-width: 44rem; }

/* ---------- Final CTA ---------- */

.final-cta { text-align: center; padding-bottom: 8rem; }
.final-cta h2 { font-size: clamp(2.6rem, 7vw, 5rem); margin: 0 auto 2rem; }

/* ---------- Article / blog (shared with posts, privacy, terms) ---------- */

.breadcrumb { font-size: 0.85rem; color: var(--muted); padding: 1.4rem 0 0; }
.breadcrumb a { color: var(--muted); }

article.post { max-width: 46rem; margin: 0 auto; padding: 2.5rem 1.4rem 5rem; }
article.post h1 {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(2.2rem, 5.5vw, 3.4rem);
  line-height: 1.08; letter-spacing: -0.015em;
  margin: 0.8rem 0;
}
article.post .meta { color: var(--muted); font-size: 0.9rem; margin-bottom: 1.8rem; }
article.post h2 {
  font-family: var(--serif); font-weight: 400;
  font-size: 1.75rem; margin: 2.4rem 0 0.8rem;
}
article.post h3 { font-size: 1.15rem; margin: 1.6rem 0 0.5rem; }
article.post p, article.post li { color: #d6d1c7; }
article.post p { margin-bottom: 1rem; }
article.post ul, article.post ol { margin: 0 0 1rem 1.4rem; }
article.post .breadcrumb { padding-top: 0; }

.answer {
  background: var(--coral-soft);
  border: 1px solid rgba(255, 107, 71, 0.35);
  border-radius: 18px;
  padding: 1.2rem 1.4rem;
  margin: 1.2rem 0 1.8rem;
}
.answer strong { color: var(--coral); }

.takeaways {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 18px;
  padding: 1.2rem 1.4rem 1.2rem 1.2rem;
  margin: 1.4rem 0;
}
.takeaways ul { margin-bottom: 0; }

.table-scroll { overflow-x: auto; margin: 1.4rem 0; }
table { border-collapse: collapse; width: 100%; font-size: 0.95rem; }
th, td { text-align: left; padding: 0.65rem 0.9rem; border-bottom: 1px solid var(--line); }
th {
  color: var(--muted); font-weight: 600; font-size: 0.8rem;
  text-transform: uppercase; letter-spacing: 0.06em;
}

/* ---------- Blog index ---------- */

section h2 { font-family: var(--serif); font-weight: 400; letter-spacing: -0.01em; font-size: clamp(2rem, 4.5vw, 2.8rem); }

.post-list { display: grid; gap: 1.1rem; margin-top: 2.4rem; }
.post-list a.card {
  display: block; color: var(--ink);
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 18px;
  padding: 1.5rem;
}
.post-list a.card:hover { text-decoration: none; border-color: var(--coral); }
.post-list a.card h3 { font-family: var(--serif); font-weight: 400; font-size: 1.5rem; margin: 0.3rem 0; }
.post-list a.card p { color: var(--muted); font-size: 0.95rem; }
.post-list .date { color: var(--muted); font-family: var(--mono); font-size: 0.78rem; }

/* ---------- Sticky CTA (appears once APP_ID is set) ---------- */

.sticky-cta {
  position: fixed; bottom: 1rem; left: 0; right: 0;
  display: flex; justify-content: center; z-index: 20; pointer-events: none;
}
.sticky-cta-btn {
  pointer-events: auto;
  background: var(--coral); color: #1c0c06;
  font-weight: 700; padding: 0.8rem 1.6rem; border-radius: 999px;
}
.sticky-cta-btn:hover { text-decoration: none; filter: brightness(1.08); }
@media (min-width: 900px) { .sticky-cta { display: none; } }

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  .glow.a, .glow.b, .hero .forget, .caret { animation: none; }
  .marquee { animation: none; transform: none; flex-wrap: wrap; width: auto; justify-content: center; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .curve-figure .saved { stroke-dashoffset: 0; animation: none; }
  html { scroll-behavior: auto; }
}
