/* pixeye.app. Colours follow the app icon (tool/make_icon.py) and the app's
   seed colour (lib/app/theme.dart). System fonts only: no third-party
   requests. */

:root {
  --bg: #F5F9FA;
  --surface: #FFFFFF;
  --ink: #0F2A35;
  --muted: #4D6571;
  --line: #DAE5E9;
  --teal: #1E6F8C;
  --teal-deep: #12465A;
  --teal-soft: #E3F0F4;
  --free: #2E7D4F;
  --plus: #6B4BC4;
  --gutter: 16px;
  --max: 1040px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0C1A20;
    --surface: #12252D;
    --ink: #E4EFF2;
    --muted: #9AB2BC;
    --line: #22404B;
    --teal: #6CC0DC;
    --teal-deep: #0A2A36;
    --teal-soft: #163844;
    --free: #6FCB95;
    --plus: #B6A2F2;
  }
}

* { box-sizing: border-box; }
html { color-scheme: light dark; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  overflow-x: hidden;
}
a { color: var(--teal); }
a:focus-visible { outline: 2px solid var(--teal); outline-offset: 3px; border-radius: 4px; }
img { max-width: 100%; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.narrow { max-width: 740px; }

/* Header */
.top { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 0; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 700; font-size: 19px; text-decoration: none; }
.brand img { width: 32px; height: 32px; border-radius: 8px; }
.nav { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px 18px; font-size: 15px; }
.nav a { color: var(--muted); text-decoration: none; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--ink); }
.nav .lang { border: 1px solid var(--line); border-radius: 999px; padding: 0 10px; }

/* The pixel strip: the hue circle of the icon, as a divider */
.pixels { display: flex; gap: 5px; margin: 0 0 18px; }
.pixels i { width: 12px; height: 12px; border-radius: 3px; }
.pixels i:nth-child(1) { background: #E04242; }
.pixels i:nth-child(2) { background: #E0A142; }
.pixels i:nth-child(3) { background: #C1E042; }
.pixels i:nth-child(4) { background: #62E042; }
.pixels i:nth-child(5) { background: #42E082; }
.pixels i:nth-child(6) { background: #42E0E0; }
.pixels i:nth-child(7) { background: #4282E0; }
.pixels i:nth-child(8) { background: #6242E0; }
.pixels i:nth-child(9) { background: #C142E0; }
.pixels i:nth-child(10) { background: #E042A1; }

/* Hero */
.hero { display: grid; grid-template-columns: 1fr; gap: 32px; align-items: center; padding: 28px 0 48px; }
@media (min-width: 820px) { .hero { grid-template-columns: 1.25fr 1fr; padding: 56px 0 72px; } }
h1 { font-size: clamp(32px, 6vw, 50px); line-height: 1.1; margin: 0 0 18px; letter-spacing: -0.01em; }
h1 span { color: var(--teal); }
.lede { font-size: 19px; color: var(--muted); max-width: 44ch; margin: 0 0 26px; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; }
.store {
  display: inline-flex; flex-direction: column; justify-content: center;
  min-width: 190px; padding: 10px 18px; border-radius: 14px;
  background: var(--ink); color: var(--bg); text-decoration: none; line-height: 1.25;
}
.store small { font-size: 12px; opacity: .75; }
.store b { font-size: 17px; }
.store.soon { background: transparent; color: var(--muted); border: 1px dashed var(--line); }
.hero-art { display: flex; justify-content: center; }
.hero-art img { width: min(56vw, 320px); border-radius: 22%; box-shadow: 0 24px 60px rgba(18, 70, 90, .28); }

/* Sections */
section { padding: 8px 0 56px; }
h2 { font-size: clamp(24px, 4vw, 32px); line-height: 1.2; margin: 0 0 10px; }
.sub { color: var(--muted); margin: 0 0 26px; max-width: 60ch; }

.tests { display: grid; grid-template-columns: 1fr; gap: 12px; }
@media (min-width: 640px) { .tests { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 940px) { .tests { grid-template-columns: repeat(3, 1fr); } }
.test { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 18px 18px 16px; }
.test h3 { font-size: 17px; margin: 0 0 4px; display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.test p { margin: 0; color: var(--muted); font-size: 15px; }
.tag { flex: none; font-size: 12px; font-weight: 600; border-radius: 999px; padding: 1px 9px; border: 1px solid currentColor; }
.tag.free { color: var(--free); }
.tag.plus { color: var(--plus); }

.points { display: grid; grid-template-columns: 1fr; gap: 12px; }
@media (min-width: 820px) { .points { grid-template-columns: repeat(3, 1fr); } }
.point { background: var(--teal-soft); border-radius: 16px; padding: 20px; }
.point h3 { font-size: 17px; margin: 0 0 6px; }
.point p { margin: 0; color: var(--muted); font-size: 15px; }

.note { border-left: 4px solid var(--teal); background: var(--surface); border-radius: 12px; padding: 16px 18px; margin: 0 0 56px; }
.note p { margin: 0; }

/* Prose pages */
.page { padding: 12px 0 64px; }
.page h1 { font-size: clamp(28px, 5vw, 38px); margin-bottom: 6px; }
.page .meta { color: var(--muted); font-size: 14px; margin: 0 0 30px; }
.page h2 { font-size: 21px; margin: 38px 0 10px; padding-top: 18px; border-top: 1px solid var(--line); }
.page h3 { font-size: 17px; margin: 22px 0 6px; }
.page ul { padding-left: 22px; }
.page li { margin: 6px 0; }
.table { overflow-x: auto; margin: 12px 0; }
.page table { border-collapse: collapse; width: 100%; min-width: 520px; font-size: 15px; }
.page th, .page td { text-align: left; vertical-align: top; padding: 10px 12px 10px 0; border-bottom: 1px solid var(--line); }
.page th { font-size: 13px; color: var(--muted); font-weight: 600; }
.callout { border: 1px solid var(--line); border-left: 4px solid var(--free); border-radius: 12px; background: var(--surface); padding: 16px 18px; margin: 18px 0; }
.callout p { margin: 0; }
details { border: 1px solid var(--line); border-radius: 12px; background: var(--surface); padding: 0 18px; margin: 10px 0; }
details summary { cursor: pointer; padding: 14px 0; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
details summary::-webkit-details-marker { display: none; }
details summary::after { content: "+"; color: var(--muted); font-weight: 400; }
details[open] summary::after { content: "−"; }
details p { margin: 0 0 16px; }

/* Footer */
.foot { border-top: 1px solid var(--line); padding: 24px 0 40px; display: flex; flex-wrap: wrap; gap: 12px 24px; align-items: center; justify-content: space-between; font-size: 14px; color: var(--muted); }
.foot a { color: var(--muted); }
.foot nav { display: flex; flex-wrap: wrap; gap: 8px 18px; }
