/* Static "how to play" pages (public/games/, public/ar/games/), built by scripts/build-game-pages.mjs.
   No script, one stylesheet, the app's palette: wine velvet, brass, ivory. Readable at 360px. */
:root {
  --velvet: #4B1426; --velvet-deep: #2A0B15; --velvet-hi: #6A1E36; --brass: #C9A24D; --brass-hi: #E8CB7E;
  --ivory: #F8F1E3; --text: #F6E9DC; --muted: #C9ABA9; --line: rgba(201, 162, 77, .28); --card: rgba(0, 0, 0, .2);
  --display: 'Gloock', Georgia, serif; --ui: 'Figtree', 'Cairo', system-ui, -apple-system, 'Segoe UI', sans-serif;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--velvet-deep); }
body {
  margin: 0; min-height: 100dvh; font: 400 1.0625rem/1.65 var(--ui); color: var(--text);
  background: radial-gradient(120% 70% at 50% 0%, var(--velvet-hi), var(--velvet-deep) 70%) fixed, var(--velvet-deep);
}
[dir="rtl"] body, body[dir="rtl"], html[dir="rtl"] body { font-family: 'Cairo', var(--ui); line-height: 1.85; }
.page { max-width: 760px; margin: 0 auto; padding: 1rem 16px 2.5rem; }
a { color: var(--brass-hi); }
a:focus-visible { outline: 2px solid var(--brass-hi); outline-offset: 2px; border-radius: 6px; }
p, li, dd { overflow-wrap: anywhere; }

/* top bar */
header.top { display: flex; align-items: center; justify-content: space-between; gap: .75rem; flex-wrap: wrap; }
.brand { display: inline-flex; align-items: center; gap: .6rem; min-height: 44px; color: var(--brass-hi); text-decoration: none; font-family: var(--display); font-size: 1.1rem; }
.brand img { border-radius: 22%; box-shadow: 0 0 0 1px var(--line); }
.brand bdi { font-family: 'Cairo', var(--ui); font-weight: 700; font-size: .95em; }
.lang-link { display: inline-flex; align-items: center; min-height: 44px; padding: 0 1rem; border: 1px solid var(--line); border-radius: 999px; color: var(--text); text-decoration: none; font-weight: 600; }
.lang-link[lang="ar"] { font-family: 'Cairo', var(--ui); }

/* breadcrumb */
.crumbs ol { display: flex; flex-wrap: wrap; gap: .2rem; margin: 1.2rem 0 .4rem; padding: 0; list-style: none; font-size: .88rem; color: var(--muted); }
.crumbs li + li::before { content: '›'; margin-inline-end: .35rem; color: var(--brass); }
[dir="rtl"] .crumbs li + li::before { content: '‹'; }
.crumbs a { color: var(--muted); }

/* headings + intro */
h1 { margin: .2rem 0 .6rem; font: 400 clamp(1.9rem, 7vw, 2.6rem)/1.15 var(--display); color: var(--brass-hi); }
[dir="rtl"] h1 { font-family: 'Cairo', var(--ui); font-weight: 700; line-height: 1.35; }
.lead { margin: 0 0 1.6rem; font-size: 1.12rem; color: var(--ivory); }
h2 { margin: 0 0 .7rem; font: 400 1.45rem/1.25 var(--display); color: var(--brass-hi); }
[dir="rtl"] h2 { font-family: 'Cairo', var(--ui); font-weight: 700; }
h3 { margin: 1.3rem 0 .3rem; font-size: 1.05rem; font-weight: 700; color: var(--ivory); }
main section { margin: 0 0 1.4rem; padding: 1.1rem 1.1rem 1rem; border: 1px solid var(--line); border-radius: 16px; background: var(--card); }
main section > :last-child { margin-bottom: 0; }
.rules h3:first-of-type { margin-top: .2rem; }
p { margin: 0 0 .8rem; }
ul { margin: 0 0 .8rem; padding-inline-start: 1.25rem; }
li { margin-bottom: .4rem; }
li::marker { color: var(--brass); }
b { color: var(--brass-hi); font-weight: 700; }
.note { color: var(--muted); font-size: .95rem; }

/* players and the deal */
.glance { display: grid; gap: .55rem; margin: 0; }
.glance div { display: grid; grid-template-columns: minmax(0, 9.5rem) minmax(0, 1fr); gap: .75rem; padding-bottom: .55rem; border-bottom: 1px solid var(--line); }
.glance div:last-child { border-bottom: 0; padding-bottom: 0; }
.glance dt { font-weight: 700; color: var(--brass-hi); }
.glance dd { margin: 0; }
@media (max-width: 480px) { .glance div { grid-template-columns: minmax(0, 1fr); gap: .1rem; } }

/* play now */
.cta { text-align: center; background: linear-gradient(180deg, rgba(201, 162, 77, .14), rgba(0, 0, 0, .22)); border-color: rgba(201, 162, 77, .5); }
.btn { display: inline-flex; align-items: center; justify-content: center; max-width: 100%; min-height: 50px; padding: .5rem 1.6rem; border-radius: 999px; font-weight: 700; font-size: 1.08rem; text-decoration: none; text-align: center; }
.btn.primary { background: var(--brass); color: var(--velvet-deep); box-shadow: 0 10px 24px -12px rgba(0, 0, 0, .7); }
.btn.primary:hover { background: var(--brass-hi); }
.cta p { margin: .8rem 0 .9rem; color: var(--muted); }
.stores { display: flex; flex-wrap: wrap; justify-content: center; gap: .6rem; }
.store { display: inline-flex; align-items: center; gap: .55rem; min-height: 48px; padding: .4rem 1rem; border: 1px solid var(--line); border-radius: 12px; background: rgba(0, 0, 0, .35); color: var(--ivory); text-decoration: none; font-weight: 600; font-size: .95rem; }
.store svg { width: 22px; height: 22px; flex: none; fill: currentColor; }

/* the other games */
.more { background: none; border: 0; padding: 0; }
.games { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); gap: .7rem; margin: 0; padding: 0; list-style: none; }
.games li { margin: 0; }
.games a { display: flex; flex-direction: column; gap: .2rem; height: 100%; padding: .85rem 1rem; border: 1px solid var(--line); border-radius: 14px; background: var(--card); color: var(--text); text-decoration: none; }
.games a:hover { border-color: var(--brass); }
.games b { font-family: var(--display); font-weight: 400; font-size: 1.2rem; }
[dir="rtl"] .games b { font-family: 'Cairo', var(--ui); font-weight: 700; }
.games span { color: var(--muted); font-size: .93rem; line-height: 1.5; }

/* footer */
footer { margin-top: 2rem; padding-top: 1rem; border-top: 1px solid var(--line); text-align: center; color: var(--muted); font-size: .9rem; }
footer nav { display: flex; flex-wrap: wrap; justify-content: center; gap: .2rem 1rem; }
footer nav a { display: inline-flex; align-items: center; min-height: 44px; }
footer p { margin: .4rem 0 0; }
