/* Meme Games — shared page styles for template-built games (landing + privacy). */
/* MINO Grid — site styles. Colors match the game's Classic theme (tile_themes.gd / ui_kit.gd). */
:root {
  /* Defaults; each game overrides these in its page <head> (from game.json "theme"). */
  --bg: #f6f5f1; --card: #ffffff; --ink: #2b2b28; --ink-2: #5f5e58; --muted: #8d8d86;
  --line: #e7e4ea; --row: #f3eef5; --accent: #d6a2e8; --accent-on: #3a2147; --accent-ink: #6d3f84;
  --c1: #d6a2e8; --c2: #f3a0d3; --c3: #a9cef4; --c4: #f7e5a9; --c5: #a8e3c5;
  --radius: 22px; --shadow: 0 18px 40px -18px rgba(107, 84, 120, .35); --max: 1080px;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 17px/1.6 "Noto Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
html[lang="ar"] body { font-family: "Noto Sans Arabic", "Noto Sans", system-ui, sans-serif; line-height: 1.8; }
img { max-width: 100%; display: block; }
a { color: var(--accent-ink); text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--accent-ink); outline-offset: 3px; border-radius: 8px; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 20px; }

/* ---------- header ---------- */
.site-header { padding: 18px 0; }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; font-weight: 700; font-size: 19px; }
.brand img { width: 40px; height: 40px; border-radius: 10px; box-shadow: 0 4px 12px -4px rgba(107,84,120,.4); }
.nav { display: flex; gap: 6px; align-items: center; }
.nav a { color: var(--ink-2); text-decoration: none; font-size: 15px; font-weight: 600; padding: 8px 14px; border-radius: 999px; }
.nav a:hover { background: var(--row); color: var(--ink); }
.nav .lang { border: 1.5px solid var(--c1); color: var(--ink); }

/* ---------- motif (the 2x2 logo) ---------- */
.motif { display: grid; grid-template-columns: 1fr 1fr; gap: 8%; width: 72px; aspect-ratio: 1; }
.motif span { border-radius: 22%; }
.motif span:nth-child(1) { background: var(--c1); }
.motif span:nth-child(2) { background: var(--c2); }
.motif span:nth-child(3) { background: var(--c3); }
.motif span:nth-child(4) { background: var(--c4); }

/* ---------- hero ---------- */
.hero { padding: 40px 0 72px; }
.hero .wrap { display: grid; grid-template-columns: 1.1fr .9fr; gap: 56px; align-items: center; }
.eyebrow { display: inline-block; font-size: 14px; font-weight: 700; letter-spacing: .04em; color: var(--accent-ink); background: color-mix(in srgb, var(--accent) 22%, white); padding: 6px 12px; border-radius: 999px; }
html[lang="ar"] .eyebrow { letter-spacing: 0; }
h1 { font-size: clamp(42px, 7vw, 72px); line-height: 1.04; margin: 18px 0 18px; letter-spacing: -.02em; font-weight: 700; }
html[lang="ar"] h1 { letter-spacing: 0; line-height: 1.25; }
.lede { font-size: clamp(18px, 2.2vw, 21px); color: var(--ink-2); max-width: 32em; margin: 0 0 30px; }
.stores { display: flex; flex-wrap: wrap; gap: 12px; }
.store {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--ink); color: #fff; text-decoration: none;
  padding: 12px 22px 12px 18px; border-radius: 14px; min-width: 190px;
  transition: transform .15s ease, box-shadow .15s ease;
}
.store:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.store svg { width: 26px; height: 26px; flex: none; fill: currentColor; }
.store small { display: block; font-size: 11px; opacity: .8; line-height: 1.2; }
.store strong { display: block; font-size: 18px; line-height: 1.2; }
.store[aria-disabled="true"] { opacity: .55; pointer-events: none; }
.hero-note { margin-top: 16px; font-size: 14px; color: var(--muted); }

/* ---------- sections ---------- */
section { padding: 72px 0; }
.section-title { font-size: clamp(28px, 4vw, 40px); line-height: 1.15; margin: 0 0 12px; letter-spacing: -.01em; }
html[lang="ar"] .section-title { letter-spacing: 0; line-height: 1.4; }
.section-sub { color: var(--ink-2); margin: 0 0 40px; max-width: 36em; }

.shots { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.shot figure { margin: 0; }
.shot img {
  width: 100%; height: auto;
  border-radius: 26px; outline: 6px solid #fff; outline-offset: -1px; box-shadow: var(--shadow); background: #fff;
  margin: 6px 0 0;
}
.shot figcaption { margin-top: 14px; font-size: 15px; font-weight: 600; text-align: center; }
.shot figcaption span { display: block; font-weight: 400; color: var(--muted); font-size: 14px; }

.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.feature { background: var(--card); border-radius: var(--radius); padding: 26px; }
.feature .chip { width: 40px; height: 40px; border-radius: 12px; margin-bottom: 16px; display: grid; place-items: center; font-weight: 800; color: rgba(0,0,0,.55); font-size: 15px; }
.feature h3 { margin: 0 0 6px; font-size: 19px; }
.feature p { margin: 0; color: var(--ink-2); font-size: 16px; }

.cta { text-align: center; background: var(--card); border-radius: 32px; padding: 56px 24px; }
.cta .motif { margin: 0 auto 20px; width: 64px; }
.cta .stores { justify-content: center; }

/* ---------- legal pages ---------- */
.legal { padding: 24px 0 64px; }
.legal .wrap { max-width: 760px; }
.legal h1 { font-size: clamp(34px, 5vw, 48px); margin-bottom: 8px; }
.legal .meta { color: var(--muted); margin: 0 0 28px; font-size: 15px; }
.summary { background: var(--card); border-radius: var(--radius); padding: 22px 26px; margin: 0 0 40px; }
.summary h2 { margin: 0 0 10px; font-size: 18px; }
.summary ul { margin: 0; padding-inline-start: 20px; }
.summary li { margin: 4px 0; }
.legal h2 { font-size: 23px; margin: 44px 0 10px; line-height: 1.3; }
.legal h3 { font-size: 18px; margin: 26px 0 6px; }
.legal p, .legal li { color: #3d3c38; }
.legal ul { padding-inline-start: 22px; }
.legal li { margin: 6px 0; }
.legal table { width: 100%; border-collapse: collapse; font-size: 15px; margin: 14px 0; background: var(--card); border-radius: 16px; overflow: hidden; }
.legal th, .legal td { text-align: start; padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.legal th { background: var(--row); font-weight: 700; }
.legal tr:last-child td { border-bottom: 0; }
.table-scroll { overflow-x: auto; }
.legal code { background: var(--row); padding: 1px 6px; border-radius: 6px; font-size: .92em; }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .hero .wrap { grid-template-columns: 1fr; gap: 40px; }
  .toy { max-width: 420px; width: 100%; margin: 0 auto; }
  .shots { grid-template-columns: repeat(2, 1fr); }
  .features { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .nav a:not(.lang) { display: none; }
  .hero { padding-top: 16px; }
  .store { flex: 1 1 100%; }
  .features { grid-template-columns: 1fr; }
  .shots { gap: 14px; }
  .shot img { outline-width: 4px; border-radius: 20px; }
  section { padding: 52px 0; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
