/* TakTakBeam website. One stylesheet, no build step, nothing loaded from
   another site. Colours and faces are the app's own (Arcade theme). */

@font-face { font-family: "Silkscreen"; src: url("fonts/Silkscreen-Regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Silkscreen"; src: url("fonts/Silkscreen-Bold.ttf") format("truetype"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Pixelify Sans"; src: url("fonts/PixelifySans.ttf") format("truetype"); font-weight: 400 700; font-display: swap; }

:root {
  --ink: #0b1420;
  --night: #0f2130;
  --panel: #16324a;
  --panel-hi: #1e4664;
  --line: #2e6c8e;
  --text: #f6f3e7;
  --muted: #a9c2cd;
  --coral: #ff7a5c;
  --mint: #4fd8c4;
  --yellow: #ffd23f;
  --page: 1120px;
  --display: "Silkscreen", "Courier New", monospace;
  --body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--night);
  color: var(--text);
  font: 400 1.0625rem/1.6 var(--body);
  /* a quiet field of pixel stars behind everything */
  background-image:
    radial-gradient(2px 2px at 12% 18%, #ffffff55 50%, transparent 51%),
    radial-gradient(2px 2px at 78% 9%, #4fd8c466 50%, transparent 51%),
    radial-gradient(2px 2px at 34% 62%, #ff7a5c55 50%, transparent 51%),
    radial-gradient(2px 2px at 91% 48%, #ffffff44 50%, transparent 51%),
    radial-gradient(2px 2px at 58% 84%, #ffd23f55 50%, transparent 51%),
    radial-gradient(2px 2px at 6% 91%, #ffffff44 50%, transparent 51%);
  background-size: 900px 900px;
}
::selection { background: var(--coral); color: var(--ink); }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--mint); text-underline-offset: 0.2em; }
a:hover { color: var(--yellow); }
:focus-visible { outline: 3px solid var(--yellow); outline-offset: 3px; }
code { font-family: ui-monospace, Menlo, Consolas, monospace; background: var(--panel); padding: 0.1em 0.4em; }

h1, h2, h3 { font-family: var(--display); font-weight: 400; line-height: 1.12; margin: 0; text-wrap: balance; }
h1 { font-size: clamp(2.4rem, 6vw, 4.5rem); letter-spacing: -0.02em; }
h1 span { white-space: nowrap; }
h1 span { color: var(--coral); }
h2 { font-size: clamp(1.7rem, 3.6vw, 2.7rem); margin-bottom: 0.45em; }
h3 { font-size: 1.15rem; color: var(--yellow); }
p { margin: 0 0 1em; max-width: 68ch; }

.skip { position: absolute; left: -999px; }
.skip:focus { left: 12px; top: 12px; background: var(--yellow); color: var(--ink); padding: 8px 12px; z-index: 20; }

main > section { max-width: var(--page); margin: 0 auto; padding: clamp(56px, 9vw, 120px) 24px 0; }

/* ------------------------------------------------------------- header */
.top {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 10px 24px;
  background: color-mix(in srgb, var(--ink) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 2px solid var(--panel);
}
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-family: var(--display); font-size: 1.1rem; }
.top nav { display: flex; align-items: center; gap: 22px; }
.top nav a { color: var(--muted); text-decoration: none; font-size: 0.95rem; }
.top nav a:hover { color: var(--text); }
.top nav .cta, .cta-btn {
  color: var(--ink); background: var(--coral); padding: 9px 16px; font-family: var(--display);
  border: 3px solid var(--ink); box-shadow: 4px 4px 0 var(--ink);
  transition: transform 0.12s var(--ease), box-shadow 0.12s var(--ease);
}
.top nav .cta:hover { color: var(--ink); background: var(--yellow); }
.top nav .cta:active { transform: translate(4px, 4px); box-shadow: 0 0 0 var(--ink); }
@media (max-width: 900px) { .top nav a:not(.cta) { display: none; } }

/* --------------------------------------------------------------- hero */
.hero { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(24px, 5vw, 72px); align-items: center; padding-top: clamp(36px, 6vw, 84px) !important; }
.lead { font-size: clamp(1.1rem, 1.6vw, 1.3rem); color: var(--muted); max-width: 34ch; margin-top: 1.1em; }
.lead.strong { color: var(--text); max-width: 36ch; }
.stores { display: flex; flex-wrap: wrap; gap: 14px; margin: 28px 0 18px; }
.store {
  display: inline-flex; flex-direction: column; min-width: 190px; padding: 12px 18px;
  background: var(--panel); border: 3px solid var(--line); color: var(--text); text-decoration: none;
}
.store b { font-family: var(--display); font-weight: 400; font-size: 1.05rem; }
.store i { font-style: normal; font-size: 0.85rem; color: var(--yellow); }
.store.badge { padding: 0; border: 0; background: none; min-width: 0; }
.store.badge img { height: 56px; width: auto; }
.facts { display: flex; flex-wrap: wrap; gap: 8px 10px; list-style: none; padding: 0; margin: 0; }
.facts li { font-family: var(--display); font-size: 0.8rem; color: var(--mint); border: 2px solid var(--panel-hi); padding: 5px 10px; }

.stage { position: relative; display: flex; align-items: center; justify-content: center; gap: 0; min-height: 420px; }
.phone {
  margin: 0; background: #05090e; padding: 9px; border-radius: 34px; border: 2px solid var(--line);
  box-shadow: 0 30px 60px -20px #000c, 0 0 0 1px #0008;
  width: min(100%, 250px);
}
.phone img { border-radius: 26px; }
.stage .send { transform: rotate(-5deg) translateY(-14px); z-index: 1; }
.stage .recv { transform: rotate(4deg) translateY(22px); }
.beam { display: flex; gap: 7px; margin: 0 -14px; z-index: 2; }
.beam i { width: 11px; height: 11px; background: var(--coral); animation: hop 1.5s var(--ease) infinite; }
.beam i:nth-child(n+3) { background: var(--yellow); }
.beam i:nth-child(n+5) { background: var(--mint); }
.beam i:nth-child(2) { animation-delay: 0.1s; } .beam i:nth-child(3) { animation-delay: 0.2s; }
.beam i:nth-child(4) { animation-delay: 0.3s; } .beam i:nth-child(5) { animation-delay: 0.4s; }
.beam i:nth-child(6) { animation-delay: 0.5s; } .beam i:nth-child(7) { animation-delay: 0.6s; }
@keyframes hop { 0%, 60%, 100% { transform: translateY(0); opacity: 0.35; } 25% { transform: translateY(-16px); opacity: 1; } }
@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; }
  .stage { min-height: 0; margin-top: 12px; }
  .phone { width: min(44vw, 230px); }
}

/* -------------------------------------------------------------- pairs */
.sub { color: var(--muted); font-size: 1.1rem; margin-top: 14px; }
.matrix { margin-top: 30px; border: 3px solid var(--line); background: var(--panel); max-width: 720px; }
.mrow { display: grid; grid-template-columns: 1fr 1.2fr 70px; gap: 12px; padding: 13px 18px; border-top: 2px solid var(--panel-hi); align-items: center; }
.mrow:first-child { border-top: 0; }
.mhead { font-family: var(--display); font-size: 0.8rem; color: var(--muted); }
.yes { font-family: var(--display); color: var(--ink); background: var(--mint); text-align: center; padding: 3px 0; }

/* ---------------------------------------------------------------- how */
.steps { list-style: none; padding: 0; margin: 40px 0 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(18px, 3vw, 44px); counter-reset: step; }
.steps li { counter-increment: step; }
.steps img { border-radius: 22px; border: 2px solid var(--line); background: #05090e; }
.steps h3 { margin: 20px 0 6px; font-size: 1.5rem; color: var(--text); }
.steps h3::before { content: counter(step) ". "; color: var(--coral); }
.steps p { color: var(--muted); }
.steps li:nth-child(2) { transform: translateY(28px); }
.note { margin-top: 56px; color: var(--muted); border-left: 0; padding: 16px 18px; background: var(--panel); border: 2px solid var(--panel-hi); }
@media (max-width: 760px) { .steps { grid-template-columns: 1fr; max-width: 340px; } .steps li:nth-child(2) { transform: none; } }

/* --------------------------------------------------------------- uses */
.use { background: var(--panel); border: 3px solid var(--ink); box-shadow: 6px 6px 0 var(--ink); padding: 24px; }
.use p:last-child { margin-bottom: 0; }
.use p { color: var(--muted); }
.use h3 { margin-bottom: 10px; }
.use.big { margin-top: 36px; background: var(--coral); border-color: var(--ink); padding: clamp(24px, 4vw, 44px); }
.use.big h3 { color: var(--ink); font-size: clamp(1.4rem, 3vw, 2.1rem); }
.use.big p { color: #2a120b; font-size: 1.15rem; max-width: 62ch; }
.use.big strong { background: var(--ink); color: var(--yellow); padding: 0 0.3em; }
.use-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 22px; margin-top: 28px; }
.use-grid .use { grid-column: span 4; }
/* not a wall of equal boxes: each row splits differently, and every row is full */
.use-grid .use:nth-child(1) { grid-column: span 5; }
.use-grid .use:nth-child(2) { grid-column: span 7; }
.use-grid .use:nth-child(3), .use-grid .use:nth-child(4) { grid-column: span 6; }
.use-grid .use:nth-child(5) { grid-column: span 7; }
.use-grid .use:nth-child(6) { grid-column: span 5; }
.use-grid .use:nth-child(7) { grid-column: span 5; }
.use-grid .use:nth-child(8) { grid-column: span 7; }
.use-grid .use:nth-child(2) h3 { color: var(--mint); }
.use-grid .use:nth-child(7) { background: var(--ink); border-color: var(--line); box-shadow: none; }
@media (max-width: 820px) { .use-grid .use, .use-grid .use:nth-child(n) { grid-column: span 12; } }

/* -------------------------------------------------------------- cards */
.cards { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 5vw, 64px); align-items: center; }
.cards-copy p { color: var(--muted); }
.cards-copy strong { color: var(--text); }
.ticks { list-style: none; padding: 0; margin: 22px 0 0; }
.ticks li { padding-left: 30px; position: relative; margin-bottom: 10px; }
.ticks li::before { content: ""; position: absolute; left: 0; top: 0.45em; width: 14px; height: 14px; background: var(--mint); box-shadow: 3px 3px 0 var(--ink); }
.cards-shots { display: flex; justify-content: center; }
.cards-shots .phone { width: min(46%, 240px); }
.cards-shots .phone:first-child { transform: rotate(-4deg); z-index: 1; }
.cards-shots .phone.light { transform: rotate(5deg) translate(-18px, 34px); }
@media (max-width: 860px) { .cards { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------- safety */
.safety { display: grid; grid-template-columns: 260px 1fr; gap: clamp(24px, 5vw, 64px); align-items: center; }
.safety p { color: var(--muted); }
.safety .small { font-size: 0.92rem; }
@media (max-width: 760px) { .safety { grid-template-columns: 1fr; } .safety .phone { width: 230px; } }

/* ------------------------------------------------------------- themes */
.wall { margin: 36px auto 0; max-width: min(100%, 760px); border: 3px solid var(--line); }
.langs { list-style: none; padding: 0; margin: 34px 0 0; display: flex; flex-wrap: wrap; gap: 8px; }
.langs li { background: var(--panel); border: 2px solid var(--panel-hi); padding: 6px 12px; }

/* ------------------------------------------------------------ privacy */
.priv-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; margin: 34px 0 26px; border: 3px solid var(--line); }
.priv-grid div { padding: 22px; border-left: 2px solid var(--line); }
.priv-grid div:first-child { border-left: 0; }
.priv-grid p { color: var(--muted); margin: 8px 0 0; font-size: 0.98rem; }
.more { font-family: var(--display); }
@media (max-width: 860px) { .priv-grid { grid-template-columns: 1fr 1fr; } .priv-grid div:nth-child(3) { border-left: 0; } .priv-grid div:nth-child(n+3) { border-top: 2px solid var(--line); } }
@media (max-width: 520px) { .priv-grid { grid-template-columns: 1fr; } .priv-grid div { border-left: 0; border-top: 2px solid var(--line); } .priv-grid div:first-child { border-top: 0; } }

/* ------------------------------------------------------------- honest */
.honest ul { list-style: none; padding: 0; margin: 28px 0 0; max-width: 780px; }
.honest li { padding: 14px 0; border-top: 2px solid var(--panel-hi); color: var(--muted); }
.honest li b { color: var(--text); }

/* ---------------------------------------------------------------- faq */
.faq details { border-top: 2px solid var(--panel-hi); max-width: 820px; }
.faq details:first-of-type { margin-top: 28px; }
.faq summary { cursor: pointer; padding: 18px 34px 18px 0; font-size: 1.15rem; list-style: none; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 4px; top: 12px; font-family: var(--display); font-size: 1.5rem; color: var(--coral); }
.faq details[open] summary::after { content: "–"; }
.faq details p { color: var(--muted); padding-bottom: 14px; }

/* ---------------------------------------------------------------- get */
.get { text-align: center; }
.get img { margin: 0 auto 22px; }
.get h2 { font-size: clamp(2.2rem, 6vw, 4rem); color: var(--coral); }
.get p { margin: 14px auto 0; color: var(--muted); }
.get .stores { justify-content: center; }
.support { text-align: center; padding-bottom: 90px !important; }
.support p { margin: 12px auto 0; color: var(--muted); }

/* ------------------------------------------------------------- footer */
.foot { border-top: 2px solid var(--panel); padding: 34px 24px 46px; text-align: center; color: var(--muted); font-size: 0.92rem; }
.foot nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; margin: 16px 0; }
.foot nav a { color: var(--muted); }
.foot p { margin: 6px auto; max-width: 80ch; }

/* ------------------------------------------------------ plain pages */
.doc { max-width: 760px; margin: 0 auto; padding: 48px 24px 90px; }
.doc h1 { font-size: clamp(2rem, 5vw, 3rem); margin-bottom: 8px; }
.doc h2 { font-size: 1.35rem; margin: 2.2em 0 0.6em; color: var(--yellow); }
.doc h3 { margin: 1.6em 0 0.4em; color: var(--mint); }
.doc p, .doc li { color: #d5e1e6; }
.doc .back { font-family: var(--display); display: inline-block; margin-bottom: 26px; }
.doc .date { color: var(--muted); }

/* things enter once, quietly, as they come into view */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.6s var(--ease), transform 0.6s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .beam i { animation: none; opacity: 1; }
  .reveal { opacity: 1; transform: none; transition: none; }
  * { transition: none !important; }
}
