/* Market Tales website. System fonts only (no third-party requests, GDPR-friendly). */
:root {
  --bg: #fbf4e8;
  --paper: #fffaf1;
  --ink: #2f2418;
  --muted: #5e4e3c;
  --accent: #b5462b;
  --accent-ink: #ffffff;
  --leaf: #3f6b3a;
  --line: #e6d6bd;
  --shadow: 0 10px 30px rgba(84, 52, 20, 0.12);
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1d1712;
    --paper: #2a221b;
    --ink: #f6ead8;
    --muted: #d3c2aa;
    --accent: #f08a62;
    --accent-ink: #1d1712;
    --leaf: #9cc98f;
    --line: #463a2e;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 18px/1.6 var(--sans);
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-underline-offset: 3px; }
a:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
h1, h2, h3 { font-family: var(--serif); line-height: 1.2; margin: 0 0 0.5em; }

.wrap { max-width: 1040px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 760px; }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; background: var(--paper); padding: 8px 12px; z-index: 10; }

/* Header */
.top { border-bottom: 1px solid var(--line); background: var(--paper); }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-family: var(--serif); font-size: 1.25rem; font-weight: 700; }
.brand img { width: 40px; height: 40px; border-radius: 10px; }
.top nav { display: flex; gap: 16px; flex-wrap: wrap; }
.top nav a { color: var(--ink); font-size: 1rem; padding: 10px 2px; }

/* Landing */
.hero { padding: 48px 0 32px; }
.hero .wrap { display: grid; gap: 32px; align-items: center; }
@media (min-width: 860px) { .hero .wrap { grid-template-columns: 1.05fr 0.95fr; } }
.hero-icon { width: 96px; height: 96px; border-radius: 22px; box-shadow: var(--shadow); margin-bottom: 20px; }
.hero h1 { font-size: clamp(2.4rem, 7vw, 3.6rem); margin-bottom: 0.15em; }
.subtitle { font-family: var(--serif); font-size: 1.5rem; color: var(--accent); margin: 0 0 16px; }
.pitch { font-size: 1.15rem; color: var(--muted); margin: 0 0 24px; }
.soon {
  display: inline-block; background: var(--paper); border: 2px dashed var(--line);
  border-radius: 14px; padding: 12px 18px; font-weight: 600;
}
.hero-art { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.hero-art .phone { width: min(300px, 82%); }
.hero-art figcaption { font-family: var(--serif); font-size: 1.1rem; color: var(--muted); text-align: center; }

/* Gameplay clips in a simple phone frame */
.phone {
  --bezel: #3a2c1f;
  background: var(--bezel); padding: 8px; border-radius: 34px;
  box-shadow: var(--shadow), inset 0 0 0 1px rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line);
}
.phone video {
  display: block; width: 100%; height: auto; aspect-ratio: 720 / 1558;
  border-radius: 27px; background: var(--paper); object-fit: cover;
}
@media (prefers-color-scheme: dark) { .phone { --bezel: #0f0b08; } }

.clips { display: grid; gap: 20px; padding: 0; margin: 8px 0 0; list-style: none; }
.clips li {
  display: grid; grid-template-columns: minmax(0, 42%) minmax(0, 1fr); gap: 16px; align-items: center;
  background: var(--paper); border: 1px solid var(--line); border-radius: 18px; padding: 14px;
}
.clips .phone { padding: 5px; border-radius: 22px; }
.clips .phone video { border-radius: 18px; }
.clips p { margin: 0; color: var(--muted); }
.clips strong { display: block; font-family: var(--serif); font-size: 1.2rem; color: var(--ink); margin-bottom: 4px; }
@media (min-width: 760px) {
  .clips { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
  .clips li { grid-template-columns: 1fr; align-content: start; padding: 20px 20px 22px; }
  .clips .phone { width: min(240px, 100%); margin: 0 auto 4px; padding: 7px; border-radius: 30px; }
  .clips .phone video { border-radius: 24px; }
  .clips p { text-align: center; }
}

.items { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; padding: 8px 0 32px; list-style: none; margin: 0; }
.items li { width: 72px; height: 72px; background: var(--paper); border: 1px solid var(--line); border-radius: 50%; display: grid; place-items: center; }
.items img { width: 56px; height: 56px; }

section { padding: 32px 0; }
section h2 { font-size: clamp(1.6rem, 4.5vw, 2.2rem); }
.lead { color: var(--muted); margin-top: 0; }

.features { display: grid; gap: 16px; grid-template-columns: 1fr; padding: 0; list-style: none; }
@media (min-width: 700px) { .features { grid-template-columns: repeat(2, 1fr); } }
.features li { background: var(--paper); border: 1px solid var(--line); border-radius: 18px; padding: 18px 20px; }
.features strong { display: block; font-family: var(--serif); font-size: 1.2rem; margin-bottom: 4px; }

.places { display: grid; gap: 16px; grid-template-columns: repeat(2, 1fr); padding: 0; list-style: none; }
@media (min-width: 860px) { .places { grid-template-columns: repeat(3, 1fr); } }
.places li { background: var(--paper); border-radius: 18px; overflow: hidden; border: 1px solid var(--line); }
.places img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.places .home-place { grid-column: 1 / -1; }
.places .home-place img { aspect-ratio: 16 / 9; object-position: center 62%; }
@media (min-width: 860px) { .places .home-place img { aspect-ratio: 21 / 8; } }
.places span { display: block; padding: 10px 12px; font-weight: 600; font-size: 1rem; line-height: 1.35; }

/* Legal pages */
.doc { padding: 32px 0 48px; }
.doc h1 { font-size: clamp(2rem, 6vw, 2.6rem); }
.doc h2 { font-size: 1.45rem; margin-top: 1.8em; }
.doc h3 { font-size: 1.15rem; margin-top: 1.4em; font-family: var(--sans); }
.doc p, .doc li { max-width: 70ch; }
.doc ul { padding-left: 1.3em; }
.doc li { margin: 0.3em 0; }
.meta { background: var(--paper); border: 1px solid var(--line); border-left: 6px solid var(--leaf); border-radius: 12px; padding: 12px 16px; margin: 16px 0 24px; }
.meta p { margin: 0.2em 0; }
.table-wrap { overflow-x: auto; margin: 16px 0; }
table { border-collapse: collapse; width: 100%; min-width: 560px; font-size: 1rem; }
th, td { border: 1px solid var(--line); padding: 8px 10px; text-align: left; vertical-align: top; }
th { background: var(--paper); }
.lang { font-size: 1rem; }
@media (max-width: 600px) {
  table { min-width: 0; }
  thead { position: absolute; left: -9999px; }
  table, tbody, tr, td { display: block; width: 100%; }
  tr { border: 1px solid var(--line); border-radius: 12px; margin-bottom: 12px; background: var(--paper); overflow: hidden; }
  td { border: 0; border-top: 1px solid var(--line); }
  td:first-child { border-top: 0; }
  td::before { content: attr(data-label); display: block; font-weight: 700; font-size: 0.9rem; color: var(--muted); }
}

/* Footer */
footer { border-top: 1px solid var(--line); background: var(--paper); padding: 24px 0 32px; margin-top: 24px; }
footer nav { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-bottom: 8px; }
footer nav a { display: inline-block; padding: 8px 0; font-size: 1rem; }
footer p { margin: 0; color: var(--muted); font-size: 1rem; }

@media (prefers-reduced-motion: no-preference) {
  a { transition: color 0.15s; }
}
