/* ===== Demirdaş Arena — Premium Light (Luminous) ===== */
:root,
[data-theme="fb"] {
  --bg-1: #fdfeff;
  --bg-2: #eef2f7;
  --surface: #ffffff;
  --surface-2: #f4f7fa;
  --surface-3: #eef2f7;
  --ink: #0f172a;          /* deep navy */
  --ink-soft: #334155;
  --muted: #7c8aa0;
  --accent: #f4b400;        /* royal gold */
  --accent-deep: #e09600;
  --gold-grad: linear-gradient(135deg, #ffe082, #f4b400);
  --primary: #0f172a;       /* navy (FB) */
  --primary-ink: #ffffff;
  --on-accent: #3a2a00;
  --border: rgba(15, 23, 42, 0.18);
  --ring: rgba(15, 23, 42, 0.05);
  --shadow-card: 0 18px 44px rgba(15, 23, 42, 0.08), 0 2px 6px rgba(15, 23, 42, 0.04);
  --shadow-pop: 0 24px 50px rgba(15, 23, 42, 0.14);
  --glow: rgba(244, 180, 0, 0.35);
  --ok: #16a34a;
  --avatar: #0f172a;
}
/* Galatasaray istisnası — yalnızca Musa'nın ekranı */
[data-theme="gs"] {
  --bg-1: #fffdfb;
  --bg-2: #fbeeee;
  --surface: #ffffff;
  --surface-2: #fdf4f3;
  --surface-3: #faecea;
  --ink: #2a0a0f;
  --ink-soft: #6b2b2b;
  --muted: #b08a86;
  --accent: #fbb200;        /* GS sarı */
  --accent-deep: #e09a00;
  --gold-grad: linear-gradient(135deg, #ffd24a, #f59e0b);
  --primary: #a90432;       /* GS kırmızı */
  --primary-ink: #ffffff;
  --on-accent: #3a1500;
  --border: rgba(169, 4, 50, 0.22);
  --ring: rgba(169, 4, 50, 0.06);
  --shadow-card: 0 18px 44px rgba(169, 4, 50, 0.1), 0 2px 6px rgba(169, 4, 50, 0.05);
  --shadow-pop: 0 24px 50px rgba(169, 4, 50, 0.16);
  --glow: rgba(229, 35, 26, 0.32);
  --avatar: #a90432;
}

* { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }
html, body { height: 100%; }
body {
  font-family: 'Inter', system-ui, sans-serif;
  background:
    radial-gradient(60% 42% at 88% 4%, color-mix(in srgb, var(--accent) 20%, transparent), transparent 70%),
    radial-gradient(52% 36% at 6% 2%, color-mix(in srgb, var(--primary) 14%, transparent), transparent 70%),
    linear-gradient(180deg, var(--bg-1), var(--bg-2)) fixed;
  color: var(--ink);
  min-height: 100dvh;
  transition: background 600ms cubic-bezier(.4,0,.2,1), color 400ms;
}
h1, h2, h3, .ff { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 800; letter-spacing: -.02em; }
.caps { font-size: 11px; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; }
.muted { color: var(--muted); }

/* App frame (mobil-merkezli, responsive) */
.app { max-width: 460px; margin: 0 auto; min-height: 100dvh; padding: 16px 18px 96px; position: relative; }

/* Screens */
.screen { display: none; }
.screen.active { display: block; animation: fade .45s cubic-bezier(.4,0,.2,1); }
@keyframes fade { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* Arena header */
.arena-head { text-align: center; padding: 14px 0 18px; position: relative; }
.arena-head .kicker { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); }
.arena-head .kicker::before, .arena-head .kicker::after { content: ''; width: 26px; height: 1px; background: var(--border); }
.arena-head h1 { font-size: 22px; margin-top: 6px; letter-spacing: .06em; }
.arena-head h1 .dot { color: var(--accent); }
.arena-sub { color: var(--muted); font-size: 13px; margin-top: 2px; }

/* Cards */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: 20px; padding: 20px; box-shadow: var(--shadow-card); }

/* ---------- LOGIN ---------- */
.brand { text-align: center; padding: 30px 0 22px; }
.crest { width: 70px; height: 70px; margin: 0 auto 16px; border-radius: 20px; display: grid; place-items: center;
  font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 36px; color: var(--on-accent);
  background: var(--gold-grad); box-shadow: 0 14px 30px var(--glow); }
.brand h1 { font-size: 26px; letter-spacing: .04em; }
.brand .accent { color: var(--accent-deep); }
.brand .caps { color: var(--muted); margin-top: 10px; }
.login-card { margin-top: 8px; }
.hint { color: var(--muted); margin-bottom: 14px; font-size: 14px; }
.name-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px; }
.name-grid button { display: flex; align-items: center; gap: 10px; padding: 11px 12px; border-radius: 14px;
  border: 1px solid var(--border); background: var(--surface-2); color: var(--ink); font: inherit; font-size: 13px; font-weight: 600;
  cursor: pointer; transition: all .25s cubic-bezier(.4,0,.2,1); }
.name-grid button:hover { border-color: var(--accent); transform: translateY(-2px); box-shadow: var(--shadow-card); }
.name-grid button.sel { border-color: var(--accent); box-shadow: 0 0 0 2px var(--glow); }
.custom-row { display: flex; gap: 8px; }
input[type=text], input[type=password] { width: 100%; padding: 15px; border-radius: 14px; border: 1px solid var(--border);
  background: var(--surface-2); color: var(--ink); font: inherit; font-size: 16px; outline: none; transition: border-color .2s; margin-bottom: 11px; }
input[type=text]:focus, input[type=password]:focus { border-color: var(--accent); }
.error { color: #dc2626; font-size: 13px; margin-top: 6px; min-height: 16px; text-align: center; }

/* Auth adım 2 */
.auth-picked { display: flex; flex-direction: column; align-items: center; gap: 10px; margin-bottom: 18px; }
.auth-picked .auth-name { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 19px; }
#authStep2 .hint { text-align: center; }

/* Otomatik giriş spinner */
.auto-loading { display: flex; flex-direction: column; align-items: center; gap: 14px; padding: 40px 0; color: var(--muted); }
.spinner { width: 40px; height: 40px; border-radius: 50%; border: 3px solid var(--surface-3); border-top-color: var(--accent); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Avatar */
.av { border-radius: 50%; display: grid; place-items: center; font-family: 'Plus Jakarta Sans'; font-weight: 800;
  color: #fff; background: var(--avatar); flex-shrink: 0; position: relative; }
.av.team-gs { background: #a90432; }
.av.team-fb { background: #0f172a; }
.av.sm { width: 34px; height: 34px; font-size: 13px; }
.av.md { width: 46px; height: 46px; font-size: 16px; }
.av.lg { width: 64px; height: 64px; font-size: 22px; }

/* ---------- DASHBOARD / LOBBY ---------- */
.profile-card { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
.profile-card .pc-info { flex: 1; min-width: 0; }
.profile-card .pc-name { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 18px; }
.profile-card .pc-sub { color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.team-chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 11px; border-radius: 999px; font-size: 11px; font-weight: 700;
  letter-spacing: .04em; background: var(--surface-2); border: 1px solid var(--border); }
.team-chip .swatch { width: 9px; height: 9px; border-radius: 50%; }
.team-chip.fb .swatch { background: #f4b400; }
.team-chip.gs .swatch { background: #e2231a; }
.pc-badge { text-align: right; }
.pc-badge .pts { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 17px; display: flex; align-items: center; gap: 5px; color: var(--accent-deep); }
.pc-badge .lbl { font-size: 10px; color: var(--muted); letter-spacing: .1em; text-transform: uppercase; }

.section-title { display: flex; align-items: center; justify-content: space-between; margin: 22px 4px 12px; }
.section-title h2 { font-size: 15px; letter-spacing: .02em; }
.section-title .chip { font-size: 11px; color: var(--muted); padding: 4px 10px; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); }

/* Oyuncu listesi */
.player-strip { display: flex; gap: 12px; overflow-x: auto; padding: 4px 2px 8px; scrollbar-width: none; }
.player-strip::-webkit-scrollbar { display: none; }
.player-cell { display: flex; flex-direction: column; align-items: center; gap: 6px; min-width: 58px; }
.player-cell .nm { font-size: 11px; color: var(--ink-soft); max-width: 64px; text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.player-cell .av { box-shadow: 0 0 0 2px var(--surface), 0 0 0 2px var(--border); }
.player-cell.ready .av { box-shadow: 0 0 0 2px var(--surface), 0 0 0 3px var(--ok); }
.player-cell .rdot { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); }
.player-cell.ready .rdot { background: var(--ok); }

.ready-btn-wrap { margin-top: 14px; }

/* Kategori grid (dashboard) */
.cat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.cat-card { background: var(--surface); border: 1px solid var(--border); border-radius: 18px; padding: 18px 14px; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; box-shadow: var(--shadow-card);
  transition: all .28s cubic-bezier(.4,0,.2,1); position: relative; overflow: hidden; }
.cat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-pop); }
.cat-card .ic { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; background: var(--surface-2); color: var(--accent-deep); }
.cat-card .ic svg { width: 24px; height: 24px; }
.cat-card .ct { font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; line-height: 1.3; }
.cat-card .cc { font-size: 10.5px; color: var(--muted); }
.cat-card.sel { border-color: var(--accent); }
.cat-card.sel::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: var(--gold-grad); }
.cat-card.sel .ic { background: var(--gold-grad); color: var(--on-accent); }

.count-row { display: flex; gap: 10px; margin: 16px 0 4px; }
.count-opt { flex: 1; padding: 12px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface); color: var(--ink);
  cursor: pointer; font: inherit; font-weight: 700; transition: all .2s; }
.count-opt.active { background: var(--primary); color: var(--primary-ink); border-color: var(--primary); }

/* Buttons */
.btn { border: none; border-radius: 999px; padding: 15px 24px; font-size: 15px; font-weight: 700; cursor: pointer; font-family: inherit;
  transition: all .25s cubic-bezier(.4,0,.2,1); display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.btn.full { width: 100%; }
.btn-primary { background: var(--primary); color: var(--primary-ink); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: var(--shadow-pop); }
.btn-gold { background: var(--gold-grad); color: var(--on-accent); }
.btn-gold:hover { transform: translateY(-2px); box-shadow: 0 14px 30px var(--glow); }
.btn-ghost { background: var(--surface); border: 1px solid var(--border); color: var(--ink); }
.btn-ghost:hover { border-color: var(--accent); }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; box-shadow: none; }
.btn.glow { animation: pulse 2.6s infinite; }
@keyframes pulse { 0%{box-shadow:0 0 0 0 var(--glow);} 70%{box-shadow:0 0 0 16px transparent;} 100%{box-shadow:0 0 0 0 transparent;} }

/* ---------- GAME / ARENA ---------- */
.game-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.game-top .gt-meta .ttl { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 16px; letter-spacing: .05em; }
.game-top .gt-meta .sub { color: var(--muted); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; }
.timer-ring { position: relative; width: 58px; height: 58px; flex-shrink: 0; }
.timer-ring svg { transform: rotate(-90deg); width: 100%; height: 100%; }
.ring-bg { fill: none; stroke: var(--surface-3); stroke-width: 6; }
.ring-prog { fill: none; stroke: var(--accent); stroke-width: 6; stroke-linecap: round; stroke-dasharray: 163.4; stroke-dashoffset: 0; transition: stroke-dashoffset 1s linear, stroke .3s; }
.timer-ring span { position: absolute; inset: 0; display: grid; place-items: center; font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 19px; }
.timer-ring.low .ring-prog { stroke: #dc2626; }
.timer-ring.low span { color: #dc2626; }

/* İlerleme çubuğu (segmentli) */
.q-progressbar { display: flex; gap: 5px; margin: 12px 0 4px; }
.q-progressbar .seg { flex: 1; height: 4px; border-radius: 999px; background: var(--surface-3); transition: background .35s, box-shadow .35s; }
.q-progressbar .seg.done { background: var(--accent); }
.q-progressbar .seg.cur { background: var(--accent); box-shadow: 0 0 0 1px var(--glow); animation: segPulse 1.6s ease-in-out infinite; }
@keyframes segPulse { 0%,100%{opacity:1;} 50%{opacity:.55;} }

.q-chips { display: flex; align-items: center; gap: 8px; margin: 12px 0 14px; }
.q-chip { padding: 6px 13px; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); font-size: 11.5px; font-weight: 700; letter-spacing: .04em; }
.q-chip.cat { background: var(--gold-grad); color: var(--on-accent); border: none; }
.q-progress { color: var(--muted); font-size: 12px; font-weight: 700; margin-left: auto; }
/* Zorluk rozeti */
.diff-chip { padding: 6px 11px; border-radius: 999px; font-size: 10.5px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; border: 1px solid transparent; }
.diff-chip.orta { color: #b45309; background: #fef3c7; border-color: #fde68a; }
.diff-chip.zor { color: #c2410c; background: #ffedd5; border-color: #fed7aa; }
.diff-chip.uzman { color: #fff; background: linear-gradient(135deg, #dc2626, #991b1b); }

.question-card { margin-bottom: 14px; position: relative; overflow: hidden; }
.q-watermark { position: absolute; right: -18px; top: -18px; width: 120px; height: 120px; opacity: .05; pointer-events: none; color: var(--ink); }
.q-watermark svg { width: 100%; height: 100%; }
.q-text { font-family: 'Plus Jakarta Sans'; font-weight: 700; font-size: 21px; line-height: 1.42; position: relative; }
/* ortak kategorisi: kulüp logoları */
.q-logos { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: center; gap: 12px 6px; margin-bottom: 18px; position: relative; }
.q-logos.hidden { display: none; }
.logo-cell { display: flex; flex-direction: column; align-items: center; gap: 9px; width: 90px; }
.logo-badge { width: 82px; height: 82px; border-radius: 20px; background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-card); display: flex; align-items: center; justify-content: center; padding: 13px; }
.logo-badge img { max-width: 100%; max-height: 100%; object-fit: contain; display: block; }
.logo-name { font-size: 11.5px; font-weight: 700; color: var(--ink-soft); text-align: center; line-height: 1.2; }
.logo-plus { align-self: flex-start; margin-top: 30px; font-size: 22px; font-weight: 800; color: var(--accent-deep); }
.opt-list { display: grid; gap: 11px; margin-top: 18px; position: relative; }
.opt-list button { animation: optIn .42s cubic-bezier(.4,0,.2,1) both; }
.opt-list button:nth-child(1){animation-delay:.04s} .opt-list button:nth-child(2){animation-delay:.10s}
.opt-list button:nth-child(3){animation-delay:.16s} .opt-list button:nth-child(4){animation-delay:.22s}
.opt-list button:nth-child(5){animation-delay:.28s} .opt-list button:nth-child(6){animation-delay:.34s}
.opt-list button:nth-child(7){animation-delay:.40s} .opt-list button:nth-child(8){animation-delay:.46s}
.opt-list button:nth-child(9){animation-delay:.52s} .opt-list button:nth-child(10){animation-delay:.58s}
.opt-list button:nth-child(11){animation-delay:.64s}
@keyframes optIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.opt-list button:active:not(:disabled) { transform: scale(.985); }
.opt-list button { text-align: left; padding: 16px 18px; border-radius: 16px; border: 1px solid var(--border); background: var(--surface);
  color: var(--ink); font: inherit; font-size: 15px; font-weight: 600; cursor: pointer; display: flex; align-items: center; gap: 13px;
  box-shadow: var(--shadow-card); transition: all .22s cubic-bezier(.4,0,.2,1); position: relative; overflow: hidden; }
.opt-list button .av { width: 36px; height: 36px; font-size: 13px; }
.opt-list button.has-av { padding: 12px 16px; }
.opt-list button:hover:not(:disabled) { transform: translateY(-2px); box-shadow: var(--shadow-pop); border-color: var(--accent); }
.opt-list button.picked { border-color: var(--accent); padding-left: 22px; box-shadow: 0 0 0 2px var(--glow), var(--shadow-card); }
.opt-list button.picked::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--gold-grad); }
.opt-list button:disabled { cursor: default; }
.q-status { text-align: center; margin-top: 16px; color: var(--muted); font-size: 13.5px; min-height: 18px; }

/* Admin live */
.live-card { text-align: center; margin-top: 6px; }
.live-counter { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 46px; line-height: 1; color: var(--ink); }
.live-counter .live-sep { color: var(--muted); margin: 0 6px; font-weight: 400; }
.live-card .caps { color: var(--muted); margin: 8px 0 16px; }

/* Await */
.center-card { text-align: center; margin-top: 12vh; }
.big-emoji { font-size: 54px; margin-bottom: 12px; }
.center-card h2 { font-size: 24px; margin-bottom: 8px; }
.center-card .muted { margin-bottom: 22px; }

/* ---------- LEADERBOARD ---------- */
.podium { display: grid; grid-template-columns: 1fr 1.15fr 1fr; align-items: end; gap: 10px; margin: 8px 0 22px; }
.podium .pod { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.podium .pod .crown { font-size: 20px; height: 22px; }
.podium .pod .av { box-shadow: 0 0 0 3px var(--surface), 0 0 0 4px var(--border); }
.podium .pod.first .av { width: 76px; height: 76px; font-size: 26px; box-shadow: 0 0 0 3px var(--surface), 0 0 0 4px var(--accent); }
.podium .pod .pn { font-size: 12px; font-weight: 700; text-align: center; max-width: 92px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.podium .pod .ps { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 14px; color: var(--accent-deep); }
.podium .pod .stand { width: 100%; border-radius: 12px 12px 0 0; background: var(--surface); border: 1px solid var(--border); border-bottom: none;
  display: grid; place-items: center; font-family: 'Plus Jakarta Sans'; font-weight: 800; color: var(--muted); }
.podium .pod.first .stand { height: 54px; background: var(--gold-grad); color: var(--on-accent); }
.podium .pod.second .stand { height: 40px; }
.podium .pod.third .stand { height: 30px; }

.lb-list { list-style: none; display: grid; gap: 9px; }
.lb-list li { display: flex; align-items: center; gap: 13px; padding: 13px 16px; border-radius: 16px; background: var(--surface);
  border: 1px solid var(--border); box-shadow: var(--shadow-card); animation: slideIn .5s both; }
.lb-list li .rk { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 15px; width: 22px; color: var(--muted); text-align: center; }
.lb-list li .ln { flex: 1; font-weight: 700; font-size: 14px; }
.lb-list li .lp { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 15px; color: var(--accent-deep); }
.lb-list li.you { border-color: var(--accent); box-shadow: 0 0 0 2px var(--glow), var(--shadow-card); }
@keyframes slideIn { from { opacity: 0; transform: translateX(-14px); } to { opacity: 1; transform: none; } }

/* ---------- ODALAR / OYUN OLUŞTUR-KATIL ---------- */
.rooms-list { display: grid; gap: 11px; }
.room-card { display: flex; align-items: center; gap: 13px; padding: 15px 16px; border-radius: 16px; background: var(--surface);
  border: 1px solid var(--border); box-shadow: var(--shadow-card); transition: all .22s cubic-bezier(.4,0,.2,1); }
.room-card .rc-ic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: var(--surface-2); color: var(--accent-deep); flex-shrink: 0; }
.room-card .rc-ic svg { width: 22px; height: 22px; }
.room-card .rc-info { flex: 1; min-width: 0; }
.room-card .rc-cat { font-weight: 700; font-size: 14px; }
.room-card .rc-sub { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.room-card .rc-join { padding: 9px 16px; font-size: 13px; flex-shrink: 0; }
.room-card.playing { opacity: .6; }
.room-card .rc-badge { font-size: 10px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--ok); }

/* Oda bekleme */
.room-meta-card { padding: 16px; }
.room-meta { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; text-align: center; }
.room-meta .rm-label { color: var(--muted); margin-bottom: 6px; }
.room-meta .rm-code { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 26px; color: var(--accent-deep); letter-spacing: .08em; }
.room-meta .rm-val { font-weight: 700; font-size: 14px; padding-top: 6px; }
.room-actions { display: grid; gap: 10px; margin-top: 18px; }

/* Geçmiş */
.history-list { display: grid; gap: 10px; }
.history-item { display: flex; align-items: center; gap: 13px; padding: 14px 16px; border-radius: 16px; background: var(--surface);
  border: 1px solid var(--border); box-shadow: var(--shadow-card); border-left: 4px solid var(--muted); }
.history-item.won { border-left-color: var(--accent); }
.history-item .hi-rank { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 20px; width: 42px; text-align: center; color: var(--muted); }
.history-item.won .hi-rank { color: var(--accent-deep); }
.history-item .hi-info { flex: 1; min-width: 0; }
.history-item .hi-cat { font-weight: 700; font-size: 14px; }
.history-item .hi-sub { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.history-item .hi-score { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 17px; color: var(--accent-deep); }

/* ---------- ARKADAŞLAR & HESAP EKRANLARI ---------- */
.friends-list { display: grid; gap: 10px; }
.friend-row { display: flex; align-items: center; gap: 13px; padding: 12px 14px; border-radius: 16px; background: var(--surface);
  border: 1px solid var(--border); box-shadow: var(--shadow-card); }
.friend-row .fr-info { flex: 1; min-width: 0; }
.friend-row .fr-n { font-weight: 700; font-size: 14px; }
.friend-row .fr-s { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.friend-row .fr-s.on { color: var(--ok); }
.friend-row .fr-btn { padding: 9px 14px; font-size: 12.5px; flex-shrink: 0; }
.empty-state { text-align: center; color: var(--muted); padding: 40px 20px; line-height: 1.6; font-size: 14px; }

.account-card { text-align: center; }
.account-card .acc-name { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 20px; margin-top: 12px; }
.acc-rows { display: grid; gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: 14px; overflow: hidden; margin-bottom: 4px; }
.acc-row { display: flex; justify-content: space-between; padding: 14px 16px; background: var(--surface); font-size: 14px; }
.acc-row span { color: var(--muted); }
.acc-row b { font-weight: 700; }
.acc-row .acc-on { color: var(--ok); }
.acc-note { text-align: center; color: var(--muted); margin-top: 12px; opacity: .8; line-height: 1.5; }

/* ---------- ARKADAŞ & DÜELLO ---------- */
.strip-hint { text-align: center; color: var(--muted); font-size: 10px; margin: 2px 0 4px; opacity: .8; }
.player-cell { cursor: pointer; position: relative; }
.player-cell .friend-star { position: absolute; top: -2px; right: 6px; font-size: 12px; filter: drop-shadow(0 1px 2px rgba(0,0,0,.2)); }
.player-cell.tappable:hover .av { box-shadow: 0 0 0 2px var(--surface), 0 0 0 3px var(--accent); }

/* Modal */
.modal-overlay { position: fixed; inset: 0; z-index: 60; background: color-mix(in srgb, var(--ink) 45%, transparent); backdrop-filter: blur(6px);
  display: grid; place-items: center; padding: 24px; animation: fade .25s; }
.modal-card { width: 100%; max-width: 380px; background: var(--surface); border: 1px solid var(--border); border-radius: 22px; padding: 24px; box-shadow: var(--shadow-pop); animation: popIn .3s cubic-bezier(.34,1.56,.64,1); }
@keyframes popIn { from { opacity: 0; transform: scale(.92) translateY(10px); } to { opacity: 1; transform: none; } }
.modal-card .m-av { margin: 0 auto 14px; }
.modal-card .m-title { text-align: center; font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 19px; }
.modal-card .m-sub { text-align: center; color: var(--muted); font-size: 13.5px; margin: 6px 0 20px; }
.modal-card .m-actions { display: grid; gap: 10px; }
.modal-card .m-row { display: flex; gap: 10px; }
.modal-card .m-row .btn { flex: 1; }
.friend-tag { text-align: center; color: var(--ok); font-weight: 700; font-size: 13px; margin-bottom: 14px; }

/* VS head (düello) */
.vs-head { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 8px; margin: 6px 0 12px; }
.vs-p { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.vs-p .vs-n { font-size: 12px; font-weight: 700; max-width: 100px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-align: center; }
.vs-p .vs-s { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 22px; color: var(--accent-deep); transition: transform .3s; }
.vs-mid { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.vs-badge { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 15px; letter-spacing: .04em; color: var(--primary-ink);
  background: var(--gold-grad); width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; box-shadow: 0 8px 20px var(--glow); }
.timer-ring.sm { width: 46px; height: 46px; }
.timer-ring.sm span { font-size: 16px; }

/* VS sonuç */
.vs-result { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; margin: 14px 0 18px; }
.vs-rp { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 20px 12px; border-radius: 18px; background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-card); }
.vs-rp.win { border-color: var(--accent); box-shadow: 0 0 0 2px var(--glow), var(--shadow-card); }
.vs-rp .vr-n { font-size: 13px; font-weight: 700; text-align: center; }
.vs-rp .vr-s { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 30px; color: var(--accent-deep); }
.vs-rp .vr-crown { font-size: 18px; height: 20px; }
.duel-outcome { text-align: center; font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 20px; margin: 4px 0 20px; }

/* ---------- CEVAP DÖKÜMÜ (review) ---------- */
.review { display: grid; gap: 10px; margin-top: 14px; }
.rev-item { background: var(--surface); border: 1px solid var(--border); border-left: 4px solid var(--muted); border-radius: 14px;
  padding: 14px 16px; box-shadow: var(--shadow-card); animation: slideIn .4s both; }
.rev-item.ok { border-left-color: var(--ok); }
.rev-item.no { border-left-color: #dc2626; }
.rev-item .rev-q { font-weight: 700; font-size: 13.5px; line-height: 1.45; margin-bottom: 9px; }
.rev-item .rev-a { display: grid; gap: 3px; font-size: 12.5px; color: var(--ink-soft); }

/* ===================== VAMPİR KÖYLÜ ===================== */
/* mod seçimi (oluştur modalı) */
.mode-row { display: flex; gap: 8px; margin: 4px 0 14px; }
.mode-opt { flex: 1; padding: 13px 10px; border-radius: 13px; border: 1px solid var(--border); background: var(--surface-2); color: var(--ink); font: inherit; font-size: 13.5px; font-weight: 700; cursor: pointer; transition: .2s; }
.mode-opt.active { background: var(--gold-grad); color: var(--on-accent); border-color: transparent; box-shadow: 0 8px 20px var(--glow); }
.vmp-info-box { background: var(--surface-2); border: 1px solid var(--border); border-radius: 13px; padding: 14px 16px; font-size: 13px; line-height: 1.55; color: var(--ink-soft); }

/* ekran */
#screen-vampir { padding-bottom: 30px; }
.vmp-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.vmp-phase { display: flex; flex-direction: column; gap: 2px; }
#vmpPhase { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 24px; letter-spacing: .01em; }
.vmp-alive { font-size: 12px; color: var(--muted); font-weight: 700; }
.vmp-timer { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; background: var(--surface); border: 2px solid var(--border); font-weight: 800; font-size: 19px; box-shadow: var(--shadow-card); }
.vmp-timer.low { border-color: #dc2626; color: #dc2626; animation: pulse .8s infinite; }
@keyframes pulse { 50% { transform: scale(1.08); } }

.vmp-rolechip { display: flex; align-items: center; gap: 10px; padding: 11px 14px; border-radius: 14px; margin-bottom: 12px; font-size: 13.5px; background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-card); }
.vmp-rolechip .vmp-emoji { font-size: 22px; }
.vmp-rolechip.team-vampir { background: linear-gradient(135deg, #2a0a12, #4a0d1f); color: #ffd9e0; border-color: transparent; }
.vmp-rolechip.team-koy { background: linear-gradient(135deg, #0f172a, #1e293b); color: #ffe082; border-color: transparent; }
.vmp-rolechip.team-deli { background: linear-gradient(135deg, #3b0a52, #6b21a8); color: #f3d9ff; border-color: transparent; }
.vmp-rolechip.dead { filter: grayscale(.6); opacity: .8; }

.vmp-card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 18px; box-shadow: var(--shadow-card); margin-bottom: 12px; }
.vmp-card.vmp-night { background: linear-gradient(135deg, #131a2b, #1d2742); color: #cdd6ea; border-color: transparent; }
.vmp-role-big { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 20px; margin-bottom: 8px; }
.vmp-desc { font-size: 13.5px; line-height: 1.55; opacity: .95; }
.vmp-team { margin-top: 10px; font-size: 13px; background: rgba(255,255,255,.08); padding: 8px 10px; border-radius: 10px; }
.vmp-wait { margin-top: 12px; font-size: 12.5px; color: var(--muted); }
.vmp-night .vmp-wait { color: #9fb0d0; }
.vmp-act-title { font-weight: 800; font-size: 16px; margin-bottom: 12px; }
.vmp-hint { margin-top: 10px; font-size: 12px; color: var(--muted); }
.vmp-night .vmp-hint { color: #9fb0d0; }

.vmp-targets { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.vmp-tgt { padding: 13px 10px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface-2); color: var(--ink); font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; transition: .15s; }
.vmp-night .vmp-tgt { background: rgba(255,255,255,.08); color: #eaf0fb; border-color: rgba(255,255,255,.14); }
.vmp-tgt:active { transform: scale(.96); }
.vmp-tgt.chosen { background: var(--gold-grad); color: var(--on-accent); border-color: transparent; box-shadow: 0 6px 16px var(--glow); }
.vmp-skip { margin-top: 10px; }
.vmp-combine .vmp-combine-row { display: flex; gap: 8px; }
.vmp-combine-row input { flex: 1; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface-2); color: var(--ink); font: inherit; font-size: 16px; }
.vmp-combine-row .btn { width: auto; padding: 12px 20px; }

.vmp-players { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 12px; }
.vmp-pcell { padding: 7px 11px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border); font-size: 12.5px; font-weight: 700; color: var(--ink-soft); }
.vmp-pcell.me { border-color: var(--accent); color: var(--ink); }
.vmp-pcell.dead { opacity: .45; text-decoration: line-through; }

.vmp-log { background: var(--surface-2); border: 1px solid var(--border); border-radius: 14px; padding: 12px 14px; max-height: 200px; overflow-y: auto; display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.vmp-logline { font-size: 12.5px; line-height: 1.5; color: var(--ink-soft); }
.vmp-note { font-size: 12.5px; line-height: 1.5; font-weight: 700; color: var(--accent-deep); background: rgba(244,180,0,.1); padding: 7px 10px; border-radius: 9px; }

.vmp-over { text-align: center; }
.vmp-winner { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 22px; margin-bottom: 16px; }
.vmp-over.team-win-vampir { background: linear-gradient(135deg, #2a0a12, #4a0d1f); color: #ffd9e0; border-color: transparent; }
.vmp-over.team-win-koy { background: linear-gradient(135deg, #0f172a, #1e293b); color: #ffe082; border-color: transparent; }
.vmp-over.team-win-deli { background: linear-gradient(135deg, #3b0a52, #6b21a8); color: #f3d9ff; border-color: transparent; }
.vmp-reveal { display: grid; gap: 7px; text-align: left; }
.vmp-reveal-row { display: flex; justify-content: space-between; align-items: center; padding: 9px 13px; border-radius: 11px; background: rgba(255,255,255,.1); font-size: 13.5px; font-weight: 700; }
.vmp-reveal-row.dead { opacity: .55; }
.vmp-reveal-row .vmp-reveal-role { font-size: 12.5px; opacity: .9; }
.rev-item .rev-a b { font-weight: 700; color: var(--ink); }
.rev-item .rev-tag { display: inline-block; margin-top: 9px; font-size: 10.5px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.rev-item.ok .rev-tag { color: var(--ok); }
.rev-item.no .rev-tag { color: #dc2626; }
.rev-summary { text-align: center; font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 15px; margin: 4px 0 12px; }
.rev-summary .ok-n { color: var(--ok); }

/* ---------- BOTTOM NAV (durum göstergesi) ---------- */
.bottom-nav { position: fixed; bottom: 0; left: 0; right: 0; z-index: 30; }
.bottom-nav .bn-inner { max-width: 460px; margin: 0 auto; background: var(--surface); border-top: 1px solid var(--border);
  display: flex; justify-content: space-around; padding: 9px 8px calc(9px + env(safe-area-inset-bottom)); box-shadow: 0 -8px 24px rgba(15,23,42,.05); }
.bn-item { display: flex; flex-direction: column; align-items: center; gap: 3px; color: var(--muted); font-size: 10px; font-weight: 700; letter-spacing: .04em; }
.bn-item svg { width: 21px; height: 21px; }
.bn-item.active { color: var(--accent-deep); }

.hidden { display: none !important; }

/* ---------- İnce dokunuşlar ---------- */
.crest { position: relative; overflow: hidden; }
.crest::before { content: ''; position: absolute; top: 0; left: -70%; width: 45%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.65), transparent); transform: skewX(-20deg); animation: shine 4s ease-in-out infinite; }
@keyframes shine { 0%, 55% { left: -70%; } 100% { left: 150%; } }
.timer-ring .ring-prog { filter: drop-shadow(0 0 3px var(--glow)); }
.podium .pod.first .av { animation: firstGlow 2.6s ease-in-out infinite; }
@keyframes firstGlow {
  0%, 100% { box-shadow: 0 0 0 3px var(--surface), 0 0 0 4px var(--accent); }
  50% { box-shadow: 0 0 0 3px var(--surface), 0 0 0 4px var(--accent), 0 0 24px var(--glow); }
}
.btn-primary { position: relative; overflow: hidden; }
.btn-primary::after { content: ''; position: absolute; inset: 0; background: linear-gradient(120deg, transparent 40%, rgba(255,255,255,.12) 50%, transparent 60%);
  transform: translateX(-100%); transition: transform .6s; }
.btn-primary:hover::after { transform: translateX(100%); }

/* ===== Aile Şampiyonası (genel liderlik) ===== */
.section-title .chip.link { cursor: pointer; color: var(--accent-deep); font-weight: 700; }
.section-title .chip.link:hover { background: var(--surface-2); }
.section-title.sub { margin: 24px 4px 12px; }
.empty-state.sm { padding: 22px 16px; font-size: 13px; }
.champ-mini { display: flex; flex-direction: column; gap: 8px; }
.champ-row { display: flex; align-items: center; gap: 12px; background: var(--surface); border: 1px solid var(--border);
  border-radius: 16px; padding: 10px 14px; box-shadow: var(--shadow-card); }
.champ-row.me { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), var(--shadow-card); }
.champ-row .cr-rank { font-size: 20px; width: 26px; text-align: center; }
.champ-row .cr-name { flex: 1; font-weight: 700; font-size: 14px; }
.champ-row .cr-wins { font-weight: 800; color: var(--accent-deep); font-size: 14px; }
#globalBoard .lp small { color: var(--muted); font-weight: 600; font-size: 11px; }

/* ===== İstatistik grid ===== */
.stat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.stat-cell { background: var(--surface-2); border: 1px solid var(--border); border-radius: 14px; padding: 14px 8px; text-align: center; }
.stat-cell .sv { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 22px; color: var(--ink); letter-spacing: -.02em; }
.stat-cell .sl { color: var(--muted); margin-top: 4px; }
.stat-cell.wide { grid-column: 1 / -1; background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 14%, var(--surface)), var(--surface)); }
.stat-cell.best-cat .sv { font-size: 17px; }

/* ===== Rozetler ===== */
.badge-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.badge { background: var(--surface-2); border: 1px solid var(--border); border-radius: 16px; padding: 14px; text-align: center; opacity: .62; filter: grayscale(.7); transition: all .3s cubic-bezier(.4,0,.2,1); }
.badge.got { opacity: 1; filter: none; background: linear-gradient(160deg, color-mix(in srgb, var(--accent) 16%, var(--surface)), var(--surface)); border-color: color-mix(in srgb, var(--accent) 40%, var(--border)); box-shadow: 0 6px 18px var(--glow); }
.badge .bg-emoji { font-size: 30px; line-height: 1; }
.badge .bg-name { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 13px; margin-top: 6px; }
.badge .bg-desc { font-size: 11px; color: var(--muted); margin-top: 3px; line-height: 1.35; }
.badge.got .bg-desc { color: var(--ok); font-weight: 700; }
.badge .bg-bar { height: 5px; border-radius: 999px; background: var(--surface-3); margin-top: 8px; overflow: hidden; }
.badge .bg-bar span { display: block; height: 100%; border-radius: 999px; background: var(--gold-grad); }
.badge .bg-prog { font-size: 10px; color: var(--muted); margin-top: 4px; font-weight: 700; }

/* ===== Ses toggle ===== */
.sound-toggle { border: 1px solid var(--border); background: var(--surface-2); color: var(--ink); border-radius: 999px;
  padding: 6px 14px; font-family: inherit; font-weight: 700; font-size: 13px; cursor: pointer; transition: all .25s; }
.sound-toggle.off { color: var(--muted); }
.profile-card .av { box-shadow: 0 0 0 3px var(--surface), 0 0 0 4px var(--border); }

/* Toast */
.toast { position: fixed; left: 50%; bottom: 84px; transform: translateX(-50%) translateY(20px); background: var(--ink); color: #fff;
  padding: 12px 20px; border-radius: 999px; font-size: 14px; font-weight: 600; opacity: 0; pointer-events: none; transition: all .3s; z-index: 50; box-shadow: var(--shadow-pop); }
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ============================================================
   APP SHELL — native uygulama hissi (mobil-öncelikli)
   Geri almak için: ui-backup/style.css dosyasını geri kopyala
   ============================================================ */

/* Uygulama davranışı: sayfa kaydırma esnekliği yok, metin seçilmez (girişler hariç) */
html, body { overscroll-behavior-y: none; }
body {
  -webkit-user-select: none; user-select: none;
  -webkit-touch-callout: none;
  /* "web" gradyanını sakin, tek parça uygulama zeminiyle değiştir */
  background:
    radial-gradient(120% 60% at 50% -10%, color-mix(in srgb, var(--accent) 12%, transparent), transparent 60%),
    linear-gradient(180deg, var(--bg-1), var(--bg-2)) fixed;
}
input, textarea { -webkit-user-select: text; user-select: text; }

/* Telefon kabuğu: üstte çentik güvenli alanı, altta yüzen menü için boşluk */
.app {
  padding: calc(14px + env(safe-area-inset-top)) 18px calc(118px + env(safe-area-inset-bottom));
  min-height: 100dvh;
}

/* Native geçiş: alttan yukarı kayarak gel (fade yerine) */
.screen.active { animation: appScreenIn .34s cubic-bezier(.22,.61,.36,1); }
@keyframes appScreenIn { from { opacity: 0; transform: translateY(16px) scale(.99); } to { opacity: 1; transform: none; } }

/* iOS "large title" hissi — kompakt, sola yaslı başlık, dekoratif çizgiler kalksın */
.arena-head { text-align: left; padding: 6px 2px 16px; }
.arena-head .kicker::before, .arena-head .kicker::after { display: none; }
.arena-head .kicker { color: var(--accent-deep); letter-spacing: .16em; }
.arena-head h1 { font-size: 30px; letter-spacing: -.02em; line-height: 1.05; margin-top: 4px; }
.arena-sub { margin-top: 6px; }

/* DOKUNMA GERİ BİLDİRİMİ — uygulama gibi: basınca küçülsün */
.btn:active:not(:disabled),
.cat-card:active, .room-card:active, .name-grid button:active,
.opt-list button:active:not(:disabled), .friend-row .fr-btn:active,
.count-opt:active, .mode-opt:active, .vmp-tgt:active, .sound-toggle:active,
.champ-row:active, .history-item:active, .badge:active {
  transform: scale(.96) !important;
  transition: transform .08s ease !important;
}

/* Dokunmatik cihazlarda masaüstü "hover-lift"i kapat (tıkta yapışık kalmasın) */
@media (hover: none) {
  .btn:hover, .btn-primary:hover, .btn-gold:hover, .btn-ghost:hover,
  .room-card:hover, .cat-card:hover, .name-grid button:hover,
  .opt-list button:hover:not(:disabled), .friend-row:hover {
    transform: none;
    box-shadow: var(--shadow-card);
    border-color: var(--border);
  }
}

/* ALT MENÜ — yüzen, frosted, kenarlıksız (gereksiz çizgi yok) */
.bottom-nav { bottom: calc(12px + env(safe-area-inset-bottom)); padding: 0 16px; }
.bottom-nav .bn-inner {
  max-width: 420px; border: none; border-radius: 28px;
  background: color-mix(in srgb, var(--surface) 82%, transparent);
  -webkit-backdrop-filter: blur(22px) saturate(1.6); backdrop-filter: blur(22px) saturate(1.6);
  box-shadow: 0 14px 34px rgba(15,23,42,.16), 0 3px 10px rgba(15,23,42,.07);
  padding: 8px; gap: 4px;
}
.bn-item {
  flex: 1; padding: 9px 4px 8px; border-radius: 20px; gap: 5px; font-size: 9.5px;
  transition: background .28s cubic-bezier(.4,0,.2,1), color .28s, transform .12s;
}
.bn-item svg { width: 22px; height: 22px; transition: transform .3s cubic-bezier(.34,1.56,.64,1); }
.bn-item.active {
  color: var(--accent-deep);
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 20%, var(--surface)), color-mix(in srgb, var(--accent) 9%, var(--surface)));
  box-shadow: 0 5px 14px var(--glow), inset 0 1px 0 rgba(255,255,255,.6);
}
.bn-item.active svg { transform: translateY(-1px) scale(1.04); }
.bn-item:active { transform: scale(.9); }

/* Toast yüzen menünün üstünde dursun */
.toast { bottom: calc(96px + env(safe-area-inset-bottom)); }

/* Giriş ekranı = uygulama açılış (splash) hissi */
.brand { padding: 9vh 0 26px; }
.crest { width: 86px; height: 86px; border-radius: 28px; font-size: 42px; }

/* Kartlar biraz daha "yumuşak yüzey" — app bileşeni gibi */
.card { border-radius: 22px; }

/* Masaüstünde: ortada gerçek telefon çerçevesi (içerik içeride kayar, menü dibe sabit) */
@media (min-width: 600px) {
  body { display: grid; place-items: center; min-height: 100dvh;
    background:
      radial-gradient(80% 80% at 50% 0%, color-mix(in srgb, var(--primary) 14%, transparent), transparent 60%),
      linear-gradient(160deg, var(--bg-2), var(--bg-1)) fixed; }
  .app {
    width: 412px; max-width: 412px; margin: 0; height: min(880px, calc(100dvh - 40px));
    padding: 0; overflow: hidden; position: relative;
    display: flex; flex-direction: column;
    border-radius: 46px; border: 11px solid #0b0f1a;
    background: linear-gradient(180deg, var(--bg-1), var(--bg-2));
    box-shadow: 0 50px 120px rgba(15,23,42,.45), 0 0 0 12px rgba(255,255,255,.04);
  }
  /* üst bar çerçeve tepesinde sabit; altındaki aktif ekran kalan alanı doldurur ve kayar */
  .app-bar { flex: none; position: static; margin: 0; padding: 16px 18px 10px; }
  .screen.active {
    flex: 1 1 auto; min-height: 0; height: auto; overflow-y: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none;
    padding: 16px 18px 112px;
  }
  .screen.active::-webkit-scrollbar { display: none; }
  /* yüzen menü çerçevenin dibine mutlak konumda sabit (artık üste kaymaz) */
  .bottom-nav { position: absolute; bottom: 14px; left: 0; right: 0; margin: 0; padding: 0 18px; z-index: 40; }
  .bottom-nav .bn-inner { margin: 0 auto; }
  /* modal & toast çerçeve içinde kalsın, tüm masaüstünü kaplamasın */
  .modal-overlay { position: absolute; border-radius: 36px; }
  .toast { position: absolute; bottom: 92px; }
}

/* ===== Gerçek profil fotoğrafları (avatar) ===== */
.av { overflow: hidden; }
.av img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }

/* ===== Premium sıralama rozetleri + kupa ikonu (emoji yerine) ===== */
.ico-trophy { width: 14px; height: 14px; vertical-align: -2px; color: var(--accent-deep); }
.ttl-ico { width: 17px; height: 17px; vertical-align: -3px; color: var(--accent-deep); margin-right: 2px; }
.section-title h2 { display: inline-flex; align-items: center; gap: 2px; }
.rank-badge { width: 28px; height: 28px; border-radius: 10px; display: grid; place-items: center; flex-shrink: 0;
  font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 13px; color: #5b4a12;
  background: linear-gradient(150deg, #ffe9a8, #f4b400); box-shadow: 0 3px 9px rgba(244,180,0,.4); }
.rank-badge.r2 { color: #3f4651; background: linear-gradient(150deg, #f6f8fb, #c0c9d6); box-shadow: 0 3px 9px rgba(148,163,184,.34); }
.rank-badge.r3 { color: #5a3315; background: linear-gradient(150deg, #f3cfa8, #cd7f32); box-shadow: 0 3px 9px rgba(205,127,50,.34); }
.rank-num { width: 28px; text-align: center; font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 14px; color: var(--muted); flex-shrink: 0; }
.cr-wins { display: inline-flex; align-items: center; gap: 4px; }
#globalBoard .lp { display: inline-flex; align-items: center; gap: 4px; }

/* ============================================================
   PREMIUM OYUN LOBİSİ — ikon temizliği + tipografi öncelikli
   Geri al: ui-backup-v2/ dosyalarını geri kopyala
   ============================================================ */

/* Dekoratif arka plan watermark'ı kaldırıldı (soru/düello ekranı) */
.q-watermark { display: none !important; }

/* Basma geri bildirimi yeni karta da uygulansın */
.game-mode:active { transform: scale(.98) !important; transition: transform .08s ease !important; }

/* ---- Oyun modu kartları: koyu, espor estetiği, ikonsuz ---- */
.mode-cards { display: grid; gap: 10px; margin: 6px 0 18px; }
.game-mode {
  text-align: left; display: flex; flex-direction: column; gap: 4px;
  padding: 17px 19px; border-radius: 18px; cursor: pointer; position: relative; overflow: hidden;
  background: linear-gradient(135deg, #1f2937, #0f172a); color: #e2e8f0;
  border: 1px solid rgba(255,255,255,.07); font-family: inherit; transition: all .3s ease;
}
.game-mode .gm-name { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 16.5px; color: #fff; letter-spacing: -.01em; }
.game-mode .gm-sub { font-size: 11.5px; color: #94a3b8; font-weight: 500; letter-spacing: .01em; }
.game-mode::before { content: ''; position: absolute; inset: 0; opacity: 0; transition: opacity .3s ease;
  background: radial-gradient(130% 100% at 100% 0%, var(--glow), transparent 58%); }
.game-mode:hover { transform: translateY(-2px); border-color: rgba(255,255,255,.16); box-shadow: 0 16px 32px rgba(15,23,42,.3); }
.game-mode.active { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), 0 16px 34px var(--glow); }
.game-mode.active::before { opacity: .9; }

/* Modal sol etiket (tipografi hiyerarşisi) */
.m-label { font-size: 10.5px; font-weight: 700; letter-spacing: .15em; text-transform: uppercase; color: var(--muted); margin: 14px 2px 9px; }

/* ---- Kategori kartları: ikonsuz, tipografik ---- */
.cat-grid { grid-template-columns: 1fr 1fr; gap: 9px; }
.cat-card {
  display: flex; flex-direction: column; align-items: flex-start; gap: 3px; text-align: left;
  padding: 13px 14px; border-radius: 13px; background: var(--surface-2); border: 1px solid var(--border);
  box-shadow: none; cursor: pointer; font-family: inherit; transition: all .3s ease;
}
.cat-card .ct { font-size: 12.5px; font-weight: 700; letter-spacing: 0; text-transform: none; line-height: 1.3; color: var(--ink); }
.cat-card .cc { font-size: 10.5px; color: var(--muted); }
.cat-card:hover { transform: none; border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); box-shadow: none; }
.cat-card.sel { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 10%, var(--surface)); }
.cat-card.sel::before { display: none; }

/* ---- Soru sayısı: cam efektli (glassmorphism) segment ---- */
.count-row {
  display: flex; gap: 5px; padding: 5px; margin: 0 0 4px; border-radius: 14px;
  background: color-mix(in srgb, var(--ink) 5%, transparent); border: 1px solid var(--border);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.count-opt { flex: 1; padding: 11px; border-radius: 10px; border: none; background: transparent; color: var(--muted);
  font-weight: 800; cursor: pointer; transition: all .3s ease; }
.count-opt.active { background: var(--surface); color: var(--ink); border: none; box-shadow: 0 2px 8px rgba(15,23,42,.1); }

.vmp-info-box { background: var(--surface-2); border: 1px solid var(--border); border-radius: 14px; padding: 15px 16px; font-size: 13px; line-height: 1.6; color: var(--ink-soft); }

/* ---- Açık oyunlar: ikonsuz, tipografik lobi kartları ---- */
.room-card { gap: 0; padding: 15px 17px; border-radius: 15px; transition: all .3s ease; }
.room-card .rc-info { flex: 1; min-width: 0; }
.room-card .rc-eyebrow { color: var(--accent-deep); font-size: 9.5px; letter-spacing: .14em; margin-bottom: 3px; }
.room-card .rc-cat { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 14.5px; letter-spacing: -.01em; }
.room-card:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--accent) 40%, var(--border)); box-shadow: var(--shadow-pop); }

/* ---- Arkadaşlar / Meydan Oku: saf tipografi, temiz border ---- */
.friend-row { padding: 12px 16px; border-radius: 15px; transition: all .3s ease; }
.friend-row:hover { border-color: color-mix(in srgb, var(--accent) 35%, var(--border)); }
.friend-row .fr-btn { padding: 10px 18px; font-size: 13px; letter-spacing: .01em; }

/* ---- Rozetler: emoji yok, tipografi + durum işareti ---- */
.badge { text-align: left; padding: 14px 15px; border-radius: 15px; opacity: .68; filter: none; transition: all .3s ease; }
.badge.got { opacity: 1; filter: none;
  background: linear-gradient(160deg, color-mix(in srgb, var(--accent) 14%, var(--surface)), var(--surface));
  border-color: color-mix(in srgb, var(--accent) 38%, var(--border)); box-shadow: 0 5px 16px var(--glow); }
.bg-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.badge .bg-name { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 13.5px; margin: 0; }
.badge .bg-desc { font-size: 11px; color: var(--muted); margin-top: 5px; line-height: 1.4; }
.badge.got .bg-desc { color: var(--accent-deep); font-weight: 700; }
.bg-check { width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; font-weight: 800;
  color: #fff; background: var(--accent-deep); flex-shrink: 0; }
.badge .bg-prog { font-size: 11px; font-weight: 800; color: var(--muted); font-family: 'Plus Jakarta Sans'; }
.badge .bg-bar { height: 5px; border-radius: 999px; background: var(--surface-3); margin-top: 9px; overflow: hidden; }
.badge .bg-bar span { display: block; height: 100%; border-radius: 999px; background: var(--gold-grad); transition: width .4s ease; }

/* Geçmiş: kazanılan oyunda kupa ikonu hizası */
.history-item .hi-rank .ico-trophy { width: 18px; height: 18px; }

/* Uzun modallar taşmasın, içeride kaysın */
.modal-card { max-height: min(86dvh, 760px); overflow-y: auto; scrollbar-width: none; }
.modal-card::-webkit-scrollbar { display: none; }

/* ============================================================
   SABİT ÜST BAR + HERO SELAMLAMA + TAM EKRAN OYUN KUR
   Geri al: ui-backup-v2/ (bir önceki) ya da ui-backup/ (ilk)
   ============================================================ */

/* ---- Sabit, yarı saydam üst bar (tab ekranlarında) ---- */
.app-bar {
  position: sticky; top: calc(env(safe-area-inset-top)); z-index: 35;
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 2px; margin-bottom: 8px;
  -webkit-backdrop-filter: blur(16px) saturate(1.4); backdrop-filter: blur(16px) saturate(1.4);
  background: color-mix(in srgb, var(--bg-1) 70%, transparent);
}
.ab-brand { display: flex; align-items: center; gap: 9px; }
.ab-crest { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center;
  font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 15px; color: var(--on-accent);
  background: var(--gold-grad); box-shadow: 0 4px 12px var(--glow); }
.ab-title { font-family: 'Plus Jakarta Sans'; font-weight: 700; font-size: 12.5px; letter-spacing: .14em; color: var(--ink); }
.ab-title b { font-weight: 800; color: var(--accent-deep); margin-left: 4px; }
#abAvatar { border: none; cursor: pointer; padding: 0; box-shadow: 0 0 0 2px var(--surface), 0 0 0 3px var(--border); transition: transform .15s ease; }
#abAvatar:active { transform: scale(.92); }

/* ---- Hero selamlama (ana sayfa) ---- */
.hero-greet { padding: 6px 2px 16px; }
.hg-hi { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 27px; letter-spacing: -.025em; line-height: 1.12; }
.hg-sub { color: var(--muted); font-size: 14px; margin-top: 5px; }
.hg-wave { display: inline-block; transform-origin: 70% 70%; animation: wave 2.6s ease-in-out infinite; }
@keyframes wave { 0%,62%,100%{transform:rotate(0)} 10%{transform:rotate(14deg)} 22%{transform:rotate(-8deg)} 34%{transform:rotate(14deg)} 46%{transform:rotate(-4deg)} }
.profile-wrap { padding: 14px 16px; }

/* ---- Diğer ekran başlıkları: kicker gizli, tek renk (amatör his gitsin) ---- */
.arena-head { text-align: left; padding: 6px 2px 14px; }
.arena-head .kicker { display: none; }
.arena-head h1 { font-size: 25px; letter-spacing: -.02em; }
.arena-head h1 .dot { color: var(--accent-deep); }
.arena-head .arena-sub { margin-top: 4px; }

/* ---- Sayfa başlığı (geri oku + başlık) ---- */
.page-head { display: flex; align-items: center; gap: 8px; padding: 4px 0 16px; }
.page-head h1 { font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 24px; letter-spacing: -.02em; }
.icon-btn { width: 38px; height: 38px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface); color: var(--ink);
  font-size: 24px; line-height: 1; cursor: pointer; display: grid; place-items: center; flex-shrink: 0; transition: all .3s ease; }
.icon-btn:active { transform: scale(.9); }
.icon-btn:hover { border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); }

/* ---- Tam ekran Oyun Kur: büyük kapak kartları ---- */
.mode-covers { display: grid; gap: 12px; }
.cover {
  position: relative; overflow: hidden; text-align: left; cursor: pointer; font-family: inherit;
  min-height: 122px; padding: 20px 22px; border-radius: 22px; border: 2px solid transparent;
  display: flex; flex-direction: column; justify-content: flex-end; gap: 4px; color: #fff; transition: all .3s ease;
}
.cover.quiz { background: linear-gradient(135deg, #2143b8, #0d1b3e); }
.cover.vampir { background: linear-gradient(135deg, #5a1b30, #190810); }
.cover::before { content: ''; position: absolute; inset: 0; opacity: .55; pointer-events: none;
  background:
    radial-gradient(58% 90% at 86% 6%, rgba(255,255,255,.18), transparent 60%),
    repeating-linear-gradient(135deg, rgba(255,255,255,.05) 0 2px, transparent 2px 17px); }
.cover .cover-tag { position: relative; color: rgba(255,255,255,.55); font-size: 10px; }
.cover .cover-name { position: relative; font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 22px; letter-spacing: -.01em; }
.cover .cover-sub { position: relative; font-size: 12.5px; color: rgba(255,255,255,.72); font-weight: 500; }
.cover .cover-go { position: absolute; top: 50%; right: 18px; transform: translateY(-50%); font-size: 30px; font-weight: 300;
  line-height: 1; color: rgba(255,255,255,.5); transition: all .3s ease; }
.cover:hover { transform: translateY(-2px); box-shadow: 0 16px 36px rgba(15,23,42,.28); }
.cover:hover .cover-go { color: #fff; right: 14px; }
.cover:active { transform: scale(.985); }
.create-lead { color: var(--muted); font-size: 14px; margin: -2px 2px 18px; }
.create-settings { margin-top: 4px; animation: appScreenIn .3s ease; }
.create-settings .m-label:first-child { margin-top: 0; }

/* ---- Kendini Ekle kutucuğu (giriş ekranı isim listesi) ---- */
.name-grid .add-self {
  display: flex; align-items: center; justify-content: center; gap: 9px;
  border: 1px dashed color-mix(in srgb, var(--accent) 55%, var(--border));
  background: color-mix(in srgb, var(--accent) 6%, transparent); color: var(--accent-deep);
}
.name-grid .add-self .as-plus { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center;
  background: var(--gold-grad); color: var(--on-accent); font-family: 'Plus Jakarta Sans'; font-weight: 800; font-size: 15px; line-height: 1; }
.name-grid .add-self:hover { border-style: solid; border-color: var(--accent); }
#addTeamRow { margin-top: 0; }

/* ============================================================
   TEMA RENK AYARI (2026-06-14)
   - Alt menü: seçilmeyen = lacivert/kırmızı (--primary), seçili = altın
   - Başlıklar tek renk (altın iki-tonlu kelime kaldırıldı)
   ============================================================ */
.bn-item { color: var(--primary); }
.bn-item.active { color: var(--accent-deep); }
.arena-head h1, .arena-head h1 .dot, .hg-hi, .page-head h1 { color: var(--primary); }
.ab-title, .ab-title b { color: var(--primary); }

/* "Sen" satırı (Aile Şampiyonası): sarı-lacivert vurgu (Musa'da kırmızı-altın) */
.champ-row.me { background: var(--primary); border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), 0 8px 20px var(--glow); }
.champ-row.me .cr-name { color: #fff; }
.champ-row.me .cr-wins { color: var(--accent); }
.champ-row.me .ico-trophy { color: var(--accent); }

/* Herkesi takımına göre gör: avatar etrafında SABİT takım renkli halka
   (tema bağımsız — Emre'yle girince bile Musa kırmızı halkalı). FB=lacivert, GS=kırmızı. */
.av.team-fb { box-shadow: 0 0 0 1.5px var(--surface), 0 0 0 3.5px #0f172a; }
.av.team-gs { box-shadow: 0 0 0 1.5px var(--surface), 0 0 0 3.5px #a90432; }
/* "sen" satırında zemin lacivert/kırmızı olduğundan halka boşluğu zeminle uyumlansın */
.champ-row.me .av.team-fb, .champ-row.me .av.team-gs { box-shadow: 0 0 0 1.5px var(--primary), 0 0 0 3.5px var(--accent); }

/* Sıralama satırları takım rengine göre tonlanır (Musa kırmızı zemin) */
.lb-list li.team-fb, .champ-row.team-fb:not(.me) { background: color-mix(in srgb, #0f172a 8%, var(--surface)); }
.lb-list li.team-gs, .champ-row.team-gs:not(.me) { background: color-mix(in srgb, #a90432 11%, var(--surface)); }
.lb-list li.team-fb { border-left: 3px solid #0f172a; }
.lb-list li.team-gs { border-left: 3px solid #a90432; }
.champ-row.team-fb:not(.me) { border-left: 3px solid #0f172a; }
.champ-row.team-gs:not(.me) { border-left: 3px solid #a90432; }
