/* Solo World — tasarım sistemi v1
   60 % kırık beyaz / açık taş · 30 % derin gece mavisi · 10 % sıcak kehribar (yalnızca ana eylem, seçim, gidilebilir delik) */
:root {
  color-scheme: light;
  /* taş (60) */
  --stone-50: #fbf9f4;
  --stone-100: #f4f0e6;
  --stone-200: #e8e1d1;
  --stone-300: #d6ccb6;
  --stone-400: #b9ac90;
  /* gece mavisi (30) */
  --navy-950: #0c1629;
  --navy-900: #10203d;
  --navy-800: #172c52;
  --navy-700: #213b6a;
  --navy-500: #3c5d97;
  --navy-100: #e2e8f3;
  /* kehribar (10) */
  --amber-500: #eaa23a;
  --amber-600: #d18a20;
  --amber-100: #fcefd6;
  --amber-800: #7a4c0c;
  /* metin */
  --ink: #18223a;
  --muted: #555e70; /* stone-100 üzerinde ~6:1 */
  --danger: #a3261e;

  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(16, 32, 61, 0.06), 0 6px 18px rgba(16, 32, 61, 0.06);
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  font-family: var(--font);
  color: var(--ink);
  background: var(--stone-100);
  -webkit-text-size-adjust: 100%;
}
* { box-sizing: border-box; }
body { margin: 0; line-height: 1.5; font-size: 16px; }
a { color: var(--navy-700); text-underline-offset: 3px; }
h1, h2, h3 { color: var(--navy-900); letter-spacing: -0.02em; line-height: 1.15; margin: 0; }
h1 { font-size: clamp(26px, 3.4vw, 34px); font-weight: 800; }
h2 { font-size: 22px; font-weight: 800; }
p { margin: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 10; background: var(--amber-500); color: var(--navy-950); padding: 8px 14px; border-radius: 8px; font-weight: 700; }
.skip:focus { left: 8px; }

/* Odak: lacivert çizgi + kehribar hale — her zeminde görünür, seçimden farklı */
:focus-visible { outline: 3px solid var(--navy-900); outline-offset: 2px; box-shadow: 0 0 0 7px rgba(234, 162, 58, 0.55); border-radius: 8px; }
.top :focus-visible { outline-color: var(--amber-500); box-shadow: none; }

/* ---------- üst bar (lacivert) ---------- */
.top { background: var(--navy-900); color: var(--stone-100); position: sticky; top: 0; z-index: 5; }
.top-inner { max-width: 1120px; margin: 0 auto; padding: 0 20px; height: 64px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font-weight: 800; font-size: 19px; letter-spacing: -0.01em; }
.logo-mark { width: 30px; height: 30px; }
.lm-peg { fill: var(--stone-200); }
.lm-center { fill: none; stroke: var(--amber-500); stroke-width: 1.6; }
.top nav { display: flex; align-items: center; gap: 4px; }
.top nav a, .top nav button.link { display: inline-flex; align-items: center; gap: 6px; color: var(--stone-200); text-decoration: none; font-weight: 600; font-size: 15px; padding: 10px 12px; border-radius: 10px; min-height: 44px; }
@media (hover: hover) { .top nav a:hover, .top nav button.link:hover { background: var(--navy-800); color: #fff; } }
.top nav a[aria-current="page"] { color: #fff; box-shadow: inset 0 -3px 0 var(--amber-500); border-radius: 10px 10px 0 0; }
.account { display: inline-flex; align-items: center; gap: 2px; margin-left: 6px; padding-left: 8px; border-left: 1px solid var(--navy-700); }
.acct-name { color: var(--stone-300); font-weight: 500; }
button.link { background: none; border: 0; cursor: pointer; font: inherit; }
.nav-login { border: 1px solid var(--navy-500); margin-left: 6px; }

main { max-width: 1120px; margin: 0 auto; padding: 28px 20px 64px; }
.page { display: grid; gap: 20px; }
.page.narrow { max-width: 620px; margin: 0 auto; }
.eyebrow { font-size: 13px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.error { color: var(--danger); font-weight: 600; }
.warn { background: var(--amber-100); color: var(--amber-800); border: 1px solid var(--amber-500); padding: 10px 14px; border-radius: var(--radius-sm); font-weight: 700; }
.panel { background: var(--stone-50); border: 1px solid var(--stone-200); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.title-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 4px; }

/* ---------- düğmeler ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 20px; border-radius: 12px;
  border: 1.5px solid var(--stone-300); background: var(--stone-50); color: var(--navy-900); font: inherit; font-weight: 700; text-decoration: none; cursor: pointer;
  transition: background 120ms, border-color 120ms, transform 120ms; }
@media (hover: hover) { .btn:hover { border-color: var(--navy-500); background: #fff; } .btn.primary:hover { background: var(--amber-600); } .link-card:hover { border-color: var(--navy-500); } }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--amber-500); border-color: var(--amber-600); color: var(--navy-950); }
.btn.big { min-height: 60px; padding: 0 34px; font-size: 20px; letter-spacing: 0.04em; border-radius: 14px; }
.btn:disabled { opacity: 0.6; cursor: progress; }
.actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ---------- zorluk ---------- */
.diff { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; color: var(--navy-900); background: var(--navy-100); padding: 6px 12px; border-radius: 999px; font-size: 15px; }
.diff-dots { display: inline-flex; gap: 4px; }
.diff-dots span { width: 9px; height: 9px; border-radius: 50%; border: 2px solid var(--navy-700); }
.diff-dots span.on { background: var(--navy-700); }

/* ---------- ana ekran ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); background: var(--stone-50); border: 1px solid var(--stone-200); border-radius: 22px; overflow: hidden; box-shadow: var(--shadow); }
.hero-main { padding: clamp(24px, 4vw, 44px); display: grid; gap: 18px; align-content: center; }
.hero-title { font-size: clamp(32px, 5vw, 50px); font-weight: 850; line-height: 1.05; }
.hero-meta { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.countdown { display: inline-flex; align-items: center; gap: 8px; color: var(--navy-900); font-weight: 600; background: var(--stone-100); border: 1px solid var(--stone-200); padding: 6px 12px; border-radius: 999px; }
.countdown strong { font-variant-numeric: tabular-nums; font-size: 18px; }
.hero-cta { display: grid; gap: 10px; justify-items: start; margin-top: 4px; }
.cta-note { color: var(--muted); font-size: 15px; max-width: 46ch; }
.today-result { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.tr-detail { font-weight: 700; font-variant-numeric: tabular-nums; }
.hero-art { background: var(--navy-900); display: flex; align-items: center; justify-content: center; padding: 28px; }
.hero-board { width: min(100%, 300px); height: auto; }
.hb-surface { fill: var(--stone-200); }
.hb-hole { fill: var(--stone-300); }
.hb-peg { fill: var(--navy-700); }
.hb-sel { fill: var(--amber-500); }
.side-links { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.link-card { display: flex; gap: 14px; align-items: center; padding: 16px 18px; background: var(--stone-50); border: 1px solid var(--stone-200); border-radius: var(--radius); color: var(--navy-900); text-decoration: none; min-height: 72px; }
.link-card > span { display: grid; }
.link-card strong { font-size: 17px; }
.link-card span span { color: var(--muted); font-size: 15px; }
.how { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.how li { display: flex; gap: 12px; align-items: flex-start; color: var(--ink); font-size: 15px; }
.how-n { flex: none; width: 28px; height: 28px; border-radius: 50%; background: var(--navy-900); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 14px; }

/* ---------- oyun ---------- */
/* Mobil öncelikli düzen: başlık → süre/taş/amaç → tahta → kısa yardım. Masaüstü düzeni yalnızca geniş ekranda. */
.game-grid { display: grid; grid-template-columns: minmax(0, 1fr); grid-template-areas: "result" "hud" "board"; gap: 14px; align-items: start; }
@media (min-width: 881px) {
  .game-grid { grid-template-columns: minmax(0, 1fr) 300px; grid-template-areas: "board result" "board hud"; grid-template-rows: auto 1fr; gap: 20px 28px; }
  }
.board-area { grid-area: board; display: grid; justify-items: center; gap: 14px; background: var(--stone-50); border: 1px solid var(--stone-200); border-radius: 22px; padding: clamp(14px, 3vw, 28px); box-shadow: var(--shadow); }
.hud { grid-area: hud; display: grid; gap: 12px; }
.result-slot { grid-area: result; }
/* Bitmiş oyunda süre/taş sonuç kartında; tekrar eden panel ve bağlantı satırı gizlenir */
.game.finished .hud, .game.finished .conn { display: none; }
.game.finished .board-foot { min-height: 0; }
.game.finished .board-foot .note:empty { display: none; }
.result-stats dd small { font-size: 14px; font-weight: 700; color: var(--muted); }
.result .actions .btn { flex: 1 1 150px; white-space: nowrap; padding: 0 14px; }
.m-only { display: none; }
.stat { background: var(--stone-50); border: 1px solid var(--stone-200); border-radius: var(--radius); padding: 12px 16px; display: grid; gap: 2px; }
.stat-label { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: 0.06em; }
.stat-value { font-size: 26px; font-weight: 800; color: var(--navy-900); font-variant-numeric: tabular-nums; }
.stat-big { background: var(--navy-900); border-color: var(--navy-900); }
.stat-big .stat-label { color: var(--stone-300); }
.stat-big .stat-value { color: #fff; font-size: 34px; letter-spacing: -0.01em; }
.goal { font-size: 18px; }
.board-foot { display: grid; justify-items: center; gap: 4px; text-align: center; min-height: 52px; }
.conn { font-size: 14px; font-weight: 700; display: inline-flex; align-items: center; gap: 6px; }
.conn::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.conn.ok { color: var(--navy-700); }
.conn.bad { color: var(--danger); }
.note { color: var(--muted); font-size: 15px; min-height: 1.5em; }

/* Tahta: haç biçimi hücrelerin kendisinden oluşur */
.board { --cell: clamp(40px, calc((100vw - 64px) / 7), 64px); display: grid; grid-template-columns: repeat(7, var(--cell)); grid-template-rows: repeat(7, var(--cell));
  filter: drop-shadow(0 4px 10px rgba(16, 32, 61, 0.1)); touch-action: manipulation; user-select: none; -webkit-user-select: none; }
.cell { display: flex; align-items: center; justify-content: center; background: var(--stone-200); }
.cell.void { background: transparent; }
/* dış köşeleri yumuşat */
.board > .cell:nth-child(3), .board > .cell:nth-child(15) { border-top-left-radius: 14px; }
.board > .cell:nth-child(5), .board > .cell:nth-child(21) { border-top-right-radius: 14px; }
.board > .cell:nth-child(29), .board > .cell:nth-child(45) { border-bottom-left-radius: 14px; }
.board > .cell:nth-child(35), .board > .cell:nth-child(47) { border-bottom-right-radius: 14px; }
.hole { position: relative; width: 100%; height: 100%; border-radius: 50%; border: 0; padding: 0; cursor: pointer; background: transparent;
  display: flex; align-items: center; justify-content: center; -webkit-tap-highlight-color: transparent; }
.pit { position: relative; width: 70%; height: 70%; border-radius: 50%; display: block;
  background: var(--stone-300); box-shadow: inset 0 2px 3px rgba(16, 32, 61, 0.2), inset 0 -1px 0 rgba(255, 255, 255, 0.55); transition: transform 120ms var(--ease); }
.board.locked .hole { cursor: not-allowed; }
.board.locked { filter: drop-shadow(0 4px 10px rgba(16, 32, 61, 0.1)) saturate(0.8); }
.peg-dot { position: absolute; inset: -9%; border-radius: 50%; pointer-events: none; z-index: 2;
  background: radial-gradient(circle at 38% 32%, #33528a 0%, var(--navy-700) 58%, #1b3260 100%);
  box-shadow: 0 1.5px 2.5px rgba(12, 22, 41, 0.2), inset 0 -1px 2px rgba(0, 0, 0, 0.14);
  transition: transform 130ms var(--ease), box-shadow 130ms var(--ease), background 130ms; }
@media (hover: hover) {
  .board:not(.locked) .hole.movable:hover .peg-dot { transform: translateY(-1px) scale(1.03); }
}
/* seçili taş: kehribar + yükselme + koyu çerçeve */
.hole.selected .peg-dot { background: radial-gradient(circle at 38% 32%, #f0b961 0%, var(--amber-500) 60%, #db971f 100%);
  box-shadow: 0 0 0 2.5px var(--navy-900), 0 4px 7px rgba(12, 22, 41, 0.2); transform: translateY(-2px) scale(1.05); }
/* gidilebilir delik: kehribar halka + orta nokta */
.hole.dest .pit { box-shadow: inset 0 0 0 3px var(--amber-500), inset 0 3px 4px rgba(16, 32, 61, 0.2); background: var(--amber-100); }
.hole.dest .pit::after { content: ""; position: absolute; inset: 34%; border-radius: 50%; background: var(--amber-600); }
@media (hover: hover) { .hole.dest:hover .pit { transform: scale(1.08); } }
/* HARD hedef: lacivert kesik halka (dışarıda) + boşken lacivert merkez işareti — kehribar kullanmaz */
.target-ring { position: absolute; inset: -17%; border-radius: 50%; border: 2.5px dashed var(--navy-700); pointer-events: none; z-index: 3; }
.hole.target:not(.peg):not(.dest) .pit { background: radial-gradient(circle, var(--navy-700) 0 16%, var(--stone-300) 17%); }
/* onay bekleyen taş: yarı saydam + yavaş nabız (sunucu onayını taklit etmez) */
.peg-dot.unconfirmed { opacity: 0.55; animation: pending 0.9s ease-in-out infinite alternate; }
@keyframes pending { to { opacity: 0.85; } }
/* alınan taş: küçülerek kaybolur */
.peg-dot.ghost { animation: capture 200ms var(--ease) forwards; }
@keyframes capture { from { transform: scale(1); opacity: 1; } to { transform: scale(0.35); opacity: 0; } }
.hole:focus-visible { outline: 3px solid var(--navy-900); outline-offset: 0; box-shadow: inset 0 0 0 5px var(--stone-50); border-radius: 50%; }

/* gösterge */
.legend { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 16px; font-size: 14px; color: var(--muted); font-weight: 600; }
.legend li { display: inline-flex; align-items: center; gap: 7px; }
.lg { position: relative; width: 20px; height: 20px; border-radius: 50%; display: inline-block; flex: none; }
.lg-peg { background: var(--navy-700); }
.lg-empty { background: var(--stone-300); box-shadow: inset 0 2px 3px rgba(16, 32, 61, 0.3); }
.lg-sel { background: var(--amber-500); box-shadow: 0 0 0 2px var(--navy-900); }
.lg-dest { background: var(--amber-100); box-shadow: inset 0 0 0 2.5px var(--amber-500); }
.lg-dest::after { content: ""; position: absolute; inset: 33%; border-radius: 50%; background: var(--amber-600); }
.lg-target { background: radial-gradient(circle, var(--navy-700) 0 18%, var(--stone-300) 19%); outline: 2px dashed var(--navy-700); outline-offset: 2px; margin: 0 3px; }

/* ---------- sonuç ---------- */
.result { display: grid; gap: 14px; border-width: 1px; animation: rise 220ms var(--ease); }
@keyframes rise { from { transform: translateY(6px); opacity: 0; } to { transform: none; opacity: 1; } }
.result-head { display: flex; gap: 14px; align-items: center; }
.result-head h2 { font-size: 28px; letter-spacing: 0.01em; }
.result-icon { flex: none; width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center; background: var(--navy-900); color: #fff; animation: pop 320ms var(--ease); }
.result-perfect { border-color: var(--amber-500); box-shadow: 0 0 0 3px var(--amber-100), var(--shadow); }
.result-perfect .result-icon { background: var(--amber-500); color: var(--navy-950); }
@keyframes pop { 0% { transform: scale(0.6); } 70% { transform: scale(1.12); } 100% { transform: scale(1); } }
.result-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 0; }
.result-stats div { background: var(--stone-100); border-radius: var(--radius-sm); padding: 10px 12px; }
.result-stats dt { font-size: 13px; color: var(--muted); font-weight: 700; }
.result-stats dd { margin: 0; font-size: 20px; font-weight: 800; color: var(--navy-900); font-variant-numeric: tabular-nums; }
.finality { font-size: 14px; font-weight: 700; color: var(--navy-700); display: flex; align-items: center; gap: 8px; }
.finality::before { content: ""; width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--navy-700); }
.finality.f-final::before { background: var(--navy-700); }
.game.finished .board-area { opacity: 0.92; }

/* ---------- sonuç rozetleri (simge + metin, renge bağlı değil) ---------- */
.st { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 800; letter-spacing: 0.04em; padding: 4px 8px; border-radius: 7px; white-space: nowrap; }
.st-perfect { background: var(--navy-900); color: #fff; }
.st-solved { background: var(--navy-100); color: var(--navy-900); }
.st-incomplete { background: var(--stone-200); color: var(--navy-900); }
.st-expired { background: transparent; color: var(--navy-900); border: 1.5px dashed var(--navy-500); }
.st-active { background: var(--stone-200); color: var(--navy-900); }

/* ---------- sıralama ---------- */
.lb-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 14px; flex-wrap: wrap; }
.lb-status { display: flex; gap: 8px; flex-wrap: wrap; }
.pill { display: inline-flex; align-items: center; gap: 7px; font-size: 14px; font-weight: 700; padding: 6px 12px; border-radius: 999px; border: 1.5px solid var(--stone-300); color: var(--navy-900); background: var(--stone-50); }
.pill-final { background: var(--navy-900); border-color: var(--navy-900); color: #fff; }
.pill-provisional { border-style: dashed; border-color: var(--navy-500); }
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--navy-700); box-shadow: 0 0 0 3px var(--navy-100); }
.lb-controls { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.seg { display: inline-flex; background: var(--stone-200); padding: 4px; border-radius: 12px; }
.seg button { display: inline-flex; align-items: center; gap: 6px; border: 0; background: transparent; color: var(--navy-900); font: inherit; font-weight: 700; padding: 0 18px; min-height: 42px; border-radius: 9px; cursor: pointer; }
.seg button.on { background: var(--navy-900); color: #fff; }
.me-card { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; background: var(--amber-100); border: 1.5px solid var(--amber-500); border-radius: var(--radius); padding: 12px 16px; }
.me-label { font-weight: 800; color: var(--navy-900); }
.me-ranks { display: flex; gap: 22px; margin-left: auto; }
.me-ranks span { display: grid; text-align: right; }
.me-ranks small { color: var(--amber-800); font-weight: 700; font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; }
.me-ranks strong { font-size: 24px; color: var(--navy-900); font-variant-numeric: tabular-nums; }
.table-wrap { background: var(--stone-50); border: 1px solid var(--stone-200); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
th, td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--stone-200); font-size: 15px; }
th { color: var(--muted); font-weight: 700; font-size: 13px; text-transform: uppercase; letter-spacing: 0.05em; background: var(--stone-100); }
tbody tr:last-child td { border-bottom: 0; }
td.rank { font-weight: 800; color: var(--navy-900); width: 64px; font-size: 17px; }
td.player { font-weight: 600; }
tr.mine td { background: var(--amber-100); }
tr.mine td.rank { box-shadow: inset 4px 0 0 var(--amber-500); }
.you { margin-left: 8px; font-size: 11px; font-weight: 800; background: var(--navy-900); color: #fff; padding: 2px 6px; border-radius: 5px; vertical-align: 1px; }
.cc-inline { display: none; }
.empty-row { text-align: center; padding: 28px; }
.lb-foot { margin-top: -6px; }

/* ---------- pratik, formlar, yardım ---------- */
.practice-bar { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.practice-bar label { display: inline-flex; gap: 8px; align-items: center; font-weight: 700; color: var(--navy-900); }
select, input { font: inherit; padding: 10px 12px; border-radius: 10px; border: 1.5px solid var(--stone-300); background: #fff; color: var(--ink); min-height: 46px; }
.form { display: grid; gap: 16px; }
.form label { display: grid; gap: 6px; font-weight: 700; color: var(--navy-900); min-width: 0; }
/* Uzun seçenek adları (ör. ülkeler) formu ekrandan taşırmasın */
.form select, .form input { width: 100%; min-width: 0; max-width: 100%; text-overflow: ellipsis; }
.hint { font-weight: 400; color: var(--muted); font-size: 14px; }
.badge-dev { justify-self: start; background: var(--stone-200); color: var(--navy-900); padding: 4px 10px; border-radius: 6px; font-size: 12px; font-weight: 800; letter-spacing: 0.04em; }
.help ul { padding-left: 38px; display: grid; gap: 10px; line-height: 1.6; }
.empty p { color: var(--muted); }

/* ---------- dil seçici ve alt bilgi ---------- */
.lang-select { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; color: var(--navy-900); font-size: 15px; }
.lang-select select { min-height: 44px; padding: 6px 10px; }
.lang-select.compact .lang-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.lang-select.compact select { min-height: 38px; background: var(--navy-800); color: #fff; border-color: var(--navy-500); font-size: 14px; font-weight: 600; }
.nav-lang { margin-left: 8px; display: inline-flex; }
.foot { max-width: 1120px; margin: 0 auto; padding: 18px 20px 28px; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; border-top: 1px solid var(--stone-200); }
.foot-note { color: var(--muted); font-size: 13px; }
.this-puzzle { margin-top: 6px; font-weight: 700; color: var(--navy-900); }

/* ---------- mobil ---------- */
@media (max-width: 880px) {
  .hud { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr) minmax(0, 1.1fr); gap: 8px; }
  .stat { padding: 8px 10px; border-radius: 12px; min-width: 0; grid-template-columns: minmax(0, 1fr); }
  /* Dar kutularda etiket simgesiz; sığmazsa alt satıra geçer, kutudan taşmaz */
  .stat-label { font-size: 11px; gap: 4px; letter-spacing: 0.04em; overflow-wrap: anywhere; }
  .stat-label svg { display: none; }
  .stat-value { font-size: 20px; line-height: 1.2; }
  .stat-big .stat-value { font-size: 20px; white-space: nowrap; }
  .goal { font-size: 14px; line-height: 1.2; display: block; }
  .hero { grid-template-columns: 1fr; }
  .hero-art { display: none; }
}
@media (max-width: 900px) { .nav-lang { display: none; } }
@media (max-width: 640px) {
  main { padding: 18px 14px 48px; }
  .foot { padding: 16px 14px 28px; }
  .top-inner { padding: 0 10px; height: 58px; }
  .brand { gap: 7px; font-size: 16px; letter-spacing: -0.02em; white-space: nowrap; }
  .logo-mark { width: 24px; height: 24px; }
  .acct-name, .top nav button.logout { display: none; }
  .top nav { gap: 0; }
  .top nav a { flex-direction: column; gap: 2px; font-size: 11px; padding: 6px 4px; min-width: 52px; min-height: 52px; justify-content: center; }
  .top nav a[aria-current="page"] { box-shadow: inset 0 -3px 0 var(--amber-500); }
  .account { margin-left: 2px; padding-left: 2px; border-left: 0; }
  .nav-login { margin-left: 0; border: 0; }
  .top-inner { height: 60px; }
  .col-result, .col-pegs { display: none; }
  .m-only { display: block; margin-top: 4px; }
  .pegs-inline { font-size: 12px; color: var(--muted); font-weight: 700; }
  td.time { text-align: right; white-space: nowrap; }
  th:last-child { text-align: right; }
  .side-links, .how { grid-template-columns: 1fr; }
  .btn.big { width: 100%; }
  .hero-cta { justify-items: stretch; }
  .board-area { padding: 12px 4px; border-radius: 18px; }
  .board { --cell: clamp(40px, calc((100vw - 44px) / 7), 64px); }
  .col-country { display: none; }
  .cc-inline { display: inline; margin-left: 6px; color: var(--muted); font-size: 12px; font-weight: 700; }
  th, td { padding: 10px 8px; font-size: 14px; }
  td.rank { width: 40px; }
  .me-ranks { margin-left: 0; }
  .result-head h2 { font-size: 24px; }
}

@media (max-width: 369px) {
  .hud { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .hud .stat-big { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
  .stat-label { font-size: 10.5px; }
}

@media (max-width: 359px) {
  .top-inner { padding: 0 6px; gap: 4px; }
  .brand { font-size: 15px; gap: 5px; }
  .logo-mark { width: 20px; height: 20px; }
  .top nav a { min-width: 46px; font-size: 10px; padding: 6px 2px; }
}

/* Kompakt dil kontrolü (≤900 px üst çubuk). Masaüstünde nav içindeki tam seçici kullanılır. */
.top-lang { display: none; }
.lang-menu { position: relative; display: inline-flex; align-items: center; gap: 5px; height: 38px; padding: 0 10px 0 9px; border: 1px solid var(--navy-500); border-radius: 999px; background: var(--navy-800); color: #fff; font-size: 13px; font-weight: 700; letter-spacing: 0.04em; white-space: nowrap; }
.lang-menu .lang-chev { opacity: 0.75; }
.lang-menu select { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; font-size: 16px; border: 0; margin: 0; appearance: none; }
.lang-menu:focus-within { outline: 2px solid var(--amber-500); outline-offset: 2px; }
@media (hover: hover) { .lang-menu:hover { background: var(--navy-700); } }

/* ≤900 px: üst çubuk iki satır — marka + dil kontrolü, altında tam genişlikte menü (menü sıkışmaz). */
@media (max-width: 900px) {
  .top-inner { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "brand lang" "nav nav"; height: auto; column-gap: 8px; row-gap: 0; padding-top: 4px; }
  .brand { grid-area: brand; min-height: 44px; }
  .top-lang { grid-area: lang; display: flex; justify-self: end; }
  .top nav { grid-area: nav; min-width: 0; margin: 0 -8px; }
}
@media (max-width: 640px) {
  .top nav { justify-content: space-between; margin: 0 -4px; }
  .top nav > a, .top nav > .account { flex: 1 1 0; min-width: 0; }
  .top nav .account > a { flex: 1 1 auto; min-width: 0; }
  .top nav a { min-height: 50px; white-space: nowrap; }
}

/* Kısa görünümlerde (ör. %200 yakınlaştırma) sabit üst çubuk içeriği örtmesin */
@media (max-height: 560px) { .top { position: static; } }

/* ---------- hareket azaltma ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .hole.selected .peg-dot { transform: none; }
}

@media (max-width: 880px) { .practice .hud { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.streak-card { display:flex; flex-wrap:wrap; align-items:center; gap:.5rem 1rem; width:100%; padding:1rem; margin-bottom:1rem; border:1px solid var(--border, #ddd5c3); border-radius:14px; }
.streak-card small { flex-basis:100%; font-weight:normal; }
.social-result { width:100%; min-width:0; }
.social-result textarea { display:block; width:100%; min-height:150px; box-sizing:border-box; }

.streak-card p{flex-basis:100%;margin:.25rem 0;overflow-wrap:anywhere;}
.streak-milestone{border-left:4px solid #eda532;padding-left:.75rem;font-weight:700;}
.social-result details{margin-top:1rem;}
.social-result summary{cursor:pointer;}
.share-image{display:block;width:270px;max-width:100%;height:auto;margin-top:1rem;border-radius:16px;}
.social-result .actions{flex-wrap:wrap;}
