/* ---- Private room series ---- */
.mp-panel { touch-action: pan-y; overscroll-behavior: contain; }
.mp-series { background: var(--surface-2); border-radius: 18px; padding: 12px; margin: 0 0 12px; text-align: left; display: flex; flex-direction: column; gap: 10px; }
.mp-series-head { display: flex; justify-content: space-between; align-items: center; }
.mp-series-head b { font-size: 15px; font-weight: 900; }
.mp-series-head span { font-size: 12px; font-weight: 700; opacity: 0.7; }
.mp-seg { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; }
.mp-seg.mp-seg-time { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.mp-seg button {
  height: 44px; border-radius: 999px; border: none; background: var(--surface); color: var(--fg);
  font-family: var(--font-display); font-size: 21px; font-weight: 800; line-height: 1; padding-top: 3px;
}
.mp-seg button.on { background: var(--primary); color: var(--on-primary); }
.mp-series-sum { font-size: 13px; font-weight: 700; line-height: 1.4; opacity: 0.85; }
.mp-series-bar { display: grid; gap: 5px; width: min(200px, 70%); margin: 4px auto 6px; }
.mp-series-bar span { height: 6px; border-radius: 3px; background: rgba(var(--fg-rgb),0.14); }
.mp-series-bar span.on { background: var(--primary); }
.mp-table-head, .mp-series-rank li { display: flex; align-items: center; gap: 8px; }
.mp-table-head { padding: 0 10px; margin-bottom: 4px; font-size: 11px; font-weight: 900; letter-spacing: 0.3px; opacity: 0.7; text-align: left; }
.mp-table-head .pos, .mp-series-rank .pos { width: 30px; flex: none; }
.mp-table-head .who, .mp-series-rank .who { flex: 1; min-width: 0; text-align: left; }
.mp-table-head .num, .mp-series-rank .num { width: 58px; text-align: right; flex: none; }
.mp-table-head .pts, .mp-series-rank .pts { width: 58px; text-align: right; flex: none; }
.mp-series-rank .num { font-size: 14px; font-weight: 800; opacity: 0.75; }
.mp-series-rank .pts { font-family: var(--font-display); font-size: 20px; }
.mp-series-rank .mv { font-size: 11px; font-weight: 900; margin-left: 4px; }
.mp-series-rank .mv.up { color: var(--good); }
.mp-series-rank .mv.down { color: var(--bad); }

.mp-podium { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; align-items: end; margin: 14px 0 12px; }
.mp-pod { display: flex; flex-direction: column; align-items: center; gap: 5px; min-width: 0; }
.mp-pod .crown svg { width: 30px; height: 22px; fill: var(--star); }
.mp-pod .av {
  width: 48px; height: 48px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-size: 22px; font-weight: 800; color: #fff; background: #8d9aa6;
}
.mp-pod.p1 .av { width: 60px; height: 60px; background: #c28a12; }
.mp-pod.p3 .av { background: #c08355; }
.mp-pod .nm { font-size: 14px; font-weight: 900; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mp-pod .tt { font-family: var(--font-display); font-size: 19px; font-weight: 800; line-height: 1; }
.mp-pod .tt small { font-family: var(--font-ui); font-size: 11px; opacity: 0.6; }
.mp-pod .block {
  width: 100%; height: 66px; border-radius: 16px 16px 6px 6px; background: #d7dbe2; color: #4a5564;
  font-family: var(--font-display); font-size: 28px; font-weight: 800; padding-top: 6px;
}
.mp-pod.p1 .block { height: 96px; background: #f0b72f; color: #5e4300; }
.mp-pod.p3 .block { height: 48px; background: #ecc1a0; color: #7a3a10; }

.mp-standings { background: var(--surface); border-radius: 18px; padding: 8px; margin-bottom: 14px; display: flex; flex-direction: column; gap: 4px; }
.mp-st-head, .mp-st-row { display: flex; align-items: center; gap: 4px; padding: 0 6px; }
.mp-st-head { height: 40px; font-size: 12px; font-weight: 900; opacity: 0.85; }
.mp-st-head .pos, .mp-st-row .pos { width: 24px; flex: none; text-align: left; }
.mp-st-head .who, .mp-st-row .who { flex: 1; min-width: 0; text-align: left; }
.mp-st-head .c, .mp-st-row .c { width: 48px; flex: none; text-align: right; }
.mp-st-head button.c {
  height: 36px; border: none; border-radius: 10px; background: transparent; padding: 0 2px 0 0;
  display: flex; align-items: center; justify-content: flex-end; cursor: pointer;
}
.mp-st-head button.c svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.3; stroke-linecap: round; stroke-linejoin: round; }
.mp-st-head .total, .mp-st-row .total { color: var(--primary); }
.mp-st-head .avg, .mp-st-row .avg { color: var(--c-teal); }
.mp-st-head .words, .mp-st-row .words { color: var(--c-orange); }
.mp-st-row {
  height: 52px; border: none; border-radius: 14px; background: var(--surface-2); color: var(--fg); cursor: pointer; font: inherit;
}
.mp-st-row.me { background: color-mix(in srgb, var(--good) 18%, var(--surface)); box-shadow: inset 0 0 0 2px var(--good); }
.mp-st-row .pos { font-family: var(--font-display); font-size: 18px; font-weight: 800; }
.mp-st-row:nth-of-type(1) .pos { color: var(--gold, #c28a12); }
.mp-st-row .who { display: flex; flex-direction: column; line-height: 1.15; }
.mp-st-row .who b { font-size: 15px; font-weight: 900; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mp-st-row .who small { font-size: 11px; font-weight: 800; opacity: 0.65; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mp-st-row .c { font-size: 15px; font-weight: 800; }
.mp-st-row .c.total { font-family: var(--font-display); font-size: 20px; color: var(--fg); }
.mp-st-hint { font-size: 11px; font-weight: 700; opacity: 0.6; padding: 4px 6px 2px; text-align: left; }

.mp-signin-note { display: block; font-size: 12px; font-weight: 700; opacity: 0.75; margin-top: -2px; }
.mp-hint-earned { border-radius: 16px; padding: 10px 12px; margin-bottom: 12px; font-size: 14px; font-weight: 700; text-align: left;
  background: color-mix(in srgb, var(--star) 24%, var(--surface)); }
.mp-hint-earned button { display: block; margin-top: 8px; border: none; border-radius: 999px; padding: 8px 14px; font: inherit; font-weight: 900;
  background: var(--primary); color: #fff; cursor: pointer; }
.mp-st-row .who small .hint { font-weight: 900; color: color-mix(in srgb, var(--star) 60%, var(--fg)); }
.mp-awards-title { font-family: var(--font-display); font-size: 21px; font-weight: 800; text-align: left; margin-bottom: 8px; }
.mp-awards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-bottom: 14px; }
.mp-award { background: var(--surface); border-radius: 16px; padding: 11px; display: flex; flex-direction: column; gap: 4px; text-align: left; min-width: 0; }
.mp-award .ic { width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center; margin-bottom: 2px; }
.mp-award .ic svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.mp-award.longest .ic { background: color-mix(in srgb, var(--primary) 16%, var(--surface)); color: var(--primary); }
.mp-award.best .ic { background: color-mix(in srgb, var(--star) 28%, var(--surface)); color: #a8740e; }
.mp-award.words .ic { background: color-mix(in srgb, var(--c-orange) 16%, var(--surface)); color: var(--c-orange); }
.mp-award.accuracy .ic { background: color-mix(in srgb, var(--c-green) 16%, var(--surface)); color: var(--c-green); }
.mp-award .t { font-size: 12px; font-weight: 900; opacity: 0.7; }
.mp-award b { font-family: var(--font-display); font-size: 18px; font-weight: 800; line-height: 1.05; overflow-wrap: anywhere; }
.mp-award .w { font-size: 13px; font-weight: 800; }
.mp-final-actions { display: flex; flex-direction: column; gap: 10px; }
.mp-final-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.mp-final-row .modal-close-btn { margin: 0; }

.mp-sheet-overlay { position: fixed; inset: 0; z-index: 2500; background: var(--overlay, rgba(0,0,0,0.5)); display: none; align-items: flex-end; justify-content: center; }
.mp-sheet-overlay.show { display: flex; }
.mp-sheet {
  width: min(100%, 480px); max-height: 92%; overflow-y: auto; touch-action: pan-y;
  background: var(--panel-a, var(--surface)); color: var(--fg); border-radius: 26px 26px 0 0;
  padding: 10px 18px calc(22px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 12px;
  animation: sheet-up 0.25s ease-out;
}
@keyframes sheet-up { from { transform: translateY(40px); opacity: 0; } to { transform: none; opacity: 1; } }
.mp-sheet .grab { align-self: center; width: 40px; height: 5px; border-radius: 3px; background: rgba(var(--fg-rgb),0.18); }
.mp-sheet-head { display: flex; align-items: center; gap: 12px; }
.mp-sheet-head .av { width: 50px; height: 50px; border-radius: 50%; background: var(--primary); color: #fff; display: flex; align-items: center; justify-content: center; font-family: var(--font-display); font-size: 22px; font-weight: 800; }
.mp-sheet-head div { flex: 1; display: flex; flex-direction: column; line-height: 1.1; }
.mp-sheet-head b { font-family: var(--font-display); font-size: 23px; font-weight: 800; }
.mp-sheet-head small { font-size: 13px; font-weight: 800; opacity: 0.65; }
.mp-sheet-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.mp-sheet-stats div { border-radius: 14px; padding: 9px 10px; display: flex; flex-direction: column; gap: 2px; }
.mp-sheet-stats small { font-size: 11px; font-weight: 900; }
.mp-sheet-stats b { font-family: var(--font-display); font-size: 23px; font-weight: 800; line-height: 1; }
.mp-sheet-stats .total { background: color-mix(in srgb, var(--primary) 15%, var(--surface)); }
.mp-sheet-stats .total small { color: var(--primary); }
.mp-sheet-stats .avg { background: color-mix(in srgb, var(--c-teal) 15%, var(--surface)); }
.mp-sheet-stats .avg small { color: var(--c-teal); }
.mp-sheet-stats .words { background: color-mix(in srgb, var(--c-orange) 15%, var(--surface)); }
.mp-sheet-stats .words small { color: var(--c-orange); }
.mp-sheet-sub { font-size: 13px; font-weight: 900; opacity: 0.7; }
.mp-bar-row { display: flex; align-items: center; gap: 10px; }
.mp-bar-row .l { width: 56px; font-size: 13px; font-weight: 800; opacity: 0.8; }
.mp-bar-row .track { flex: 1; height: 14px; border-radius: 7px; background: var(--surface-2); overflow: hidden; }
.mp-bar-row .track i { display: block; height: 100%; border-radius: 7px; background: var(--c-teal); }
.mp-bar-row .track i.top { background: #c28a12; }
.mp-bar-row .v { width: 34px; text-align: right; font-family: var(--font-display); font-size: 17px; font-weight: 800; }
.mp-sheet-facts { background: var(--surface-2); border-radius: 14px; padding: 10px 14px; display: flex; flex-direction: column; gap: 6px; }
.mp-sheet-facts div { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; font-weight: 800; }
.mp-sheet-facts span { opacity: 0.7; }

/* ---- Account window ---- */
.account-card {
  display: flex; align-items: center; gap: 12px; margin: 4px 0 14px; padding: 12px;
  border-radius: 18px; background: var(--surface-2); text-align: left;
}
.account-card[hidden] { display: none; }
.account-av {
  width: 52px; height: 52px; border-radius: 50%; flex: none; background: var(--primary) center / cover no-repeat;
  color: var(--on-primary); display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-size: 24px; font-weight: 800;
}
.account-id { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.account-id b { font-family: var(--font-display); font-size: 21px; font-weight: 800; line-height: 1.1; overflow-wrap: anywhere; }
.account-id span { font-size: 14px; font-weight: 700; opacity: 0.75; overflow-wrap: anywhere; }
#modal-signin .modal-box p { margin-bottom: 12px; }
#modal-signin .modal-close-btn { margin-top: 8px; }
/* The Google button is the main action: as wide and as tall as "Kapat" (Nov 2026, a tester felt the smaller button
   pointed players to closing the window instead). */
#modal-signin #google-btn-wrap { margin: 6px 0 2px; }
#modal-signin #native-google-btn { width: 100%; height: 50px; font-size: 16px; }
#modal-signin #native-google-btn .g-mark { width: 40px; height: 40px; }
/* "Kapat" is the quiet way out: a plain text button, so Google's button (max ~44px tall on the web) is the bigger one */
#modal-signin .modal-close-btn[data-close] { width: auto; display: block; margin: 6px auto 0; padding: 8px 18px;
  background: none; box-shadow: none; border: 0; font-size: 14px; font-weight: 700; opacity: 0.7; }
#signin-action-btn { color: var(--bad); box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--bad) 35%, transparent); }
/* Android app: our own button for the native Google sign-in (looks like Google's "filled_blue" pill) */
#native-google-btn {
  display: inline-flex; align-items: center; gap: 10px; width: 260px; max-width: 100%; height: 44px;
  padding: 0 16px 0 4px; border: 0; border-radius: 999px; background: #1a73e8; color: #fff;
  font-family: var(--font-ui); font-size: 15px; font-weight: 700; cursor: pointer;
}
#native-google-btn:disabled { opacity: 0.6; }
#native-google-btn .g-mark {
  width: 36px; height: 36px; border-radius: 50%; background: #fff; color: #1a73e8; flex: none;
  display: flex; align-items: center; justify-content: center; font-size: 20px; font-weight: 800;
}
#native-google-btn span:last-child { flex: 1; text-align: center; }

/* ---- Çok Oyuncu screen: making or joining a room ---- */
.mp-choose .mp-name-row { margin: 0 0 12px; }
.mp-opt { border-radius: 18px; padding: 12px; margin-bottom: 10px; display: flex; flex-direction: column; gap: 10px; text-align: left; }
.mp-opt.friends { background: color-mix(in srgb, var(--primary) 9%, var(--surface)); box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--primary) 28%, transparent); }
.mp-opt-head { display: flex; align-items: center; gap: 10px; }
.mp-opt-head div { display: flex; flex-direction: column; line-height: 1.15; }
.mp-opt-head b { font-family: var(--font-display); font-size: 19px; font-weight: 800; }
.mp-opt-head small { font-size: 12px; font-weight: 700; opacity: 0.7; margin: 0; text-align: left; }
.mp-opt-ic { width: 38px; height: 38px; border-radius: 50%; flex: none; display: flex; align-items: center; justify-content: center; color: #fff; }
.mp-opt.friends .mp-opt-ic { background: var(--primary); }
.mp-opt-ic svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.mp-choose .mp-opt .menu-btn { width: 100%; height: 50px; margin: 0; font-size: 17px; }
.mp-opt.friends .menu-btn { background: var(--primary); }
.mp-opt .mp-join-row .menu-btn { width: auto; height: 46px; padding: 0 18px; }
.mp-opt .mp-join-row .mp-input { height: 46px; box-sizing: border-box; background: var(--surface); }
.mp-opt-sep { display: flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 800; opacity: 0.6; }
.mp-opt-sep::before, .mp-opt-sep::after { content: ''; flex: 1; height: 1px; background: currentColor; opacity: 0.4; }

/* ---- Private room lifetime (pick when making one, time left, missed games, a room that is over) ---- */
.mp-hours { display: flex; flex-direction: column; gap: 6px; }
.mp-hours > span { font-size: 12px; font-weight: 800; opacity: 0.7; }
.mp-hours-seg { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.mp-hours-seg button { height: 38px; font-size: 15px; background: var(--surface); }
.mp-hours-seg.mp-seg-time { grid-template-columns: repeat(4, minmax(0, 1fr)); }
/* New room settings: a summary line of the last settings used, the pickers open under it */
.mp-cfg { display: flex; flex-direction: column; gap: 6px; }
.mp-cfg-label { font-size: 12px; font-weight: 800; opacity: 0.7; }
.mp-cfg-sum {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 44px; padding: 0 14px;
  border: 0; border-radius: 12px; background: var(--surface); color: inherit; font: inherit; font-weight: 800;
  font-size: 15px; text-align: left; cursor: pointer;
}
.mp-cfg-sum b { font-size: 13px; color: var(--primary); white-space: nowrap; }
.mp-cfg-panel { display: flex; flex-direction: column; gap: 12px; padding: 12px; border-radius: 12px; background: var(--surface-2); }
.mp-cfg-panel[hidden] { display: none; }
.mp-expiry { font-size: 13px; font-weight: 700; opacity: 0.8; margin: -2px 0 10px; }
.mp-expiry b { font-weight: 900; }
.mp-times { font-size: 12px; font-weight: 700; opacity: 0.6; margin: -8px 0 10px; }
.mp-locked { font-size: 14px; font-weight: 800; line-height: 1.45; padding: 14px; border-radius: 14px; background: var(--surface-2); margin: 0 0 12px; }
.mp-open-note { font-size: 13px; font-weight: 700; line-height: 1.4; opacity: 0.8; margin: 0 0 12px; }
.mp-missed {
  display: flex; flex-direction: column; gap: 6px; text-align: left; border-radius: 18px; padding: 12px; margin: 0 0 12px;
  background: color-mix(in srgb, var(--c-orange) 12%, var(--surface));
  box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--c-orange) 35%, transparent);
}
.mp-missed b { font-size: 15px; font-weight: 900; }
.mp-missed span { font-size: 13px; font-weight: 700; line-height: 1.4; opacity: 0.85; }
.mp-missed .menu-btn, #mp-solo-btn { width: 100%; height: 46px; margin: 4px 0 0; background: var(--c-orange); color: #fff; font-size: 16px; }

/* ---- Odalarım (my rooms) and the badge on the menu's "Çok Oyuncu" ---- */
#btn-multi { position: relative; overflow: visible; }
.menu-badge {
  position: absolute; top: -7px; right: -5px; min-width: 26px; height: 26px; padding: 0 7px; box-sizing: border-box;
  border-radius: 999px; background: #e5484d; color: #fff; box-shadow: 0 0 0 3px var(--bg1, #fff);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-size: 15px; font-weight: 800; line-height: 1; padding-top: 2px;
}
.menu-badge[hidden] { display: none; }
.menu-badge.pop { animation: mp-badge-pop 0.5s ease-out 2; }
@keyframes mp-badge-pop { 40% { transform: scale(1.35); } }
.mp-mine { text-align: left; margin-bottom: 10px; display: flex; flex-direction: column; gap: 8px; }
.mp-mine[hidden] { display: none; }
.mp-mine-head { display: flex; align-items: baseline; justify-content: space-between; padding: 0 4px; }
.mp-mine-head b { font-family: var(--font-display); font-size: 19px; font-weight: 800; }
.mp-mine-head small { font-size: 12px; font-weight: 700; opacity: 0.7; margin: 0; }
.mp-mine-list { display: flex; flex-direction: column; gap: 6px; max-height: 236px; overflow-y: auto; touch-action: pan-y; overscroll-behavior: contain; }
.mp-mine-row {
  display: flex; flex-direction: column; gap: 3px; width: 100%; padding: 10px 12px; border: none; border-radius: 14px;
  background: var(--surface-2); color: var(--fg); font: inherit; text-align: left; cursor: pointer; flex: none;
}
.mp-mine-row.has-new { box-shadow: inset 0 0 0 2px #e5484d; }
.mp-mine-row.closed { opacity: 0.85; }
.mp-mine-row .top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.mp-mine-row .top b { font-family: var(--font-display); font-size: 17px; font-weight: 800; letter-spacing: 1.5px; }
.mp-mine-row .state { font-size: 12px; font-weight: 800; padding: 3px 9px; border-radius: 999px;
  background: color-mix(in srgb, var(--c-green) 18%, transparent); color: color-mix(in srgb, var(--c-green) 75%, var(--fg)); }
.mp-mine-row.closed .state { background: rgba(var(--fg-rgb),0.1); color: var(--fg); opacity: 0.8; }
.mp-mine-row .mid { font-size: 13px; font-weight: 700; opacity: 0.85; }
.mp-mine-row .times { font-size: 12px; font-weight: 700; opacity: 0.6; }
.mp-mine-row .bot { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; }
.mp-mine-row .leader { opacity: 0.75; margin-right: auto; }
.mp-mine-row .tag { padding: 2px 8px; border-radius: 999px; font-weight: 900; color: #fff; }
.mp-mine-row .tag.new { background: #e5484d; }
.mp-mine-row .tag.missed { background: var(--c-orange); }

.mp-mine-toggle {
  display: flex; align-items: center; gap: 8px; width: 100%; flex: none; padding: 8px 12px; border: none; border-radius: 12px;
  background: transparent; color: var(--fg); font: inherit; font-size: 13px; font-weight: 800; cursor: pointer;
  box-shadow: inset 0 0 0 1.5px rgba(var(--fg-rgb),0.15);
}
.mp-mine-toggle > span:first-child { flex: 1; text-align: left; opacity: 0.8; }
.mp-mine-toggle .tag { padding: 2px 8px; border-radius: 999px; font-size: 12px; font-weight: 900; color: #fff; background: #e5484d; }
.mp-mine-toggle svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; transition: transform 0.2s; opacity: 0.7; }
.mp-mine-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }
.mp-close-room {
  display: block; margin: 12px auto 0; padding: 8px 16px; border: none; border-radius: 999px; background: transparent;
  color: var(--bad, #c95b4c); font: inherit; font-size: 13px; font-weight: 800; cursor: pointer;
  box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--bad, #c95b4c) 45%, transparent);
}

/* ---- Çok Oyuncu as a screen (was a window): one scrolling column under the top bar ---- */
#screen-mp, #screen-invite { align-items: stretch; }
.mp-screen-body {
  flex: 1; min-height: 0; width: min(100%, 560px); margin: 0 auto; box-sizing: border-box; padding: 4px 16px 24px;
  display: flex; flex-direction: column; gap: 14px; overflow-y: auto; touch-action: pan-y; overscroll-behavior: contain; color: var(--fg);
}
.mp-screen-body > * { flex: none; }
.mp-screen-body .mp-name-row, .mp-screen-body .mp-opt { margin: 0; }
.mp-screen-body .mp-name-row { background: var(--surface); border-radius: 16px; padding: 8px 8px 8px 14px; box-shadow: inset 0 0 0 2px var(--line-soft); }
.mp-screen-body .mp-name-row label { font-size: 13px; font-weight: 800; opacity: 0.7; }
.mp-screen-body .mp-name-row .mp-input { flex: 1; min-width: 0; height: 40px; }
.mp-screen-body .mp-mine { margin: 0; }
.mp-screen-body .mp-mine-list { max-height: none; overflow: visible; } /* the screen scrolls instead */

/* ---- Invite screen (an invite link): join this room or not ---- */
.inv-body {
  flex: 1; min-height: 0; width: min(100%, 480px); margin: 0 auto; box-sizing: border-box; padding: 8px 20px 24px;
  display: flex; flex-direction: column; gap: 18px; overflow-y: auto; touch-action: pan-y; overscroll-behavior: contain;
  color: var(--fg); animation: mp-ended-in 0.35s ease-out;
}
.inv-body[hidden] { display: none; }
.inv-body > * { flex: none; }
.inv-head { display: flex; flex-direction: column; align-items: center; gap: 12px; padding-top: 14px; text-align: center; }
.inv-head h2 { margin: 0; font-family: var(--font-display); font-size: 27px; font-weight: 800; line-height: 1.1; }
.inv-head p { margin: 0; max-width: 320px; font-size: 15px; font-weight: 700; line-height: 1.4; opacity: 0.8; }
.inv-ic { width: 76px; height: 76px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--c-orange); color: #fff; }
.inv-ic.ended { background: var(--surface-2); color: var(--fg); }
.inv-ic svg { width: 40px; height: 40px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
/* The room code in the game's own letter tiles */
.inv-code { display: flex; justify-content: center; gap: 6px; }
.inv-code span {
  width: 44px; height: 50px; border-radius: 10px; display: flex; align-items: center; justify-content: center;
  background: var(--tile-a, var(--surface)); color: var(--tile-text, var(--fg)); box-shadow: var(--tile-shadow, 0 3px 0 rgba(0,0,0,0.2));
  font-family: var(--font-display); font-size: 26px; font-weight: 800;
}
.inv-facts { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 8px; }
.inv-facts:empty { min-height: 58px; } /* keeps the layout still while the room is asked for */
.inv-facts div { background: var(--surface); border-radius: 14px; padding: 10px 6px; text-align: center; display: flex; flex-direction: column; gap: 2px; }
.inv-facts b { font-family: var(--font-display); font-size: 18px; font-weight: 800; line-height: 1.1; }
.inv-facts small { font-size: 12px; font-weight: 700; opacity: 0.75; }
.inv-spacer { flex: 1 1 0 !important; min-height: 0; }
.inv-name { display: flex; flex-direction: column; gap: 6px; }
.inv-name label { font-size: 13px; font-weight: 800; opacity: 0.75; padding-left: 6px; }
#inv-name { flex: none; height: 50px; font-family: inherit; font-weight: 800; box-sizing: border-box; border-radius: 999px; padding: 0 18px; font-size: 17px; background: var(--surface); box-shadow: inset 0 0 0 2px var(--line-soft); }
#inv-join-btn { width: 100%; margin: 0; background: var(--c-orange); color: #fff; }
#inv-join-btn:disabled { opacity: 0.55; }
.inv-later { height: 46px; border: none; border-radius: 999px; background: transparent; color: var(--fg); font: inherit; font-size: 16px; font-weight: 800; opacity: 0.75; cursor: pointer; }
.inv-note { margin-top: -10px; font-size: 12px; font-weight: 700; line-height: 1.4; opacity: 0.65; text-align: center; }
.inv-top { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.inv-top li { display: flex; align-items: center; gap: 12px; background: var(--surface); border-radius: 14px; padding: 12px 14px; }
.inv-top li.first { box-shadow: inset 0 0 0 2px var(--star); }
.inv-top li span { width: 26px; flex: none; text-align: center; font-size: 20px; }
.inv-top li b { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 16px; }
.inv-top li em { font-style: normal; font-weight: 900; font-size: 15px; }
/* A closed room's final standings (the room's own final panel, without its title and buttons) */
.inv-final { text-align: center; }
.inv-final:empty { display: none; }
.inv-final .mp-podium { margin-top: 0; }
.inv-ended-note { margin: 0; padding: 0 8px; font-size: 14px; font-weight: 700; line-height: 1.45; opacity: 0.8; text-align: center; }
#inv-home-btn { width: 100%; height: 56px; margin: 0; font-size: 20px; }
@keyframes mp-ended-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
/* Editors' "Nesneli deneme" on the Çok Oyuncu screen */
.mp-opt.trial { background: color-mix(in srgb, var(--c-teal) 9%, var(--surface)); box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--c-teal) 28%, transparent); }
.mp-opt.trial .mp-opt-ic, .mp-opt.trial .menu-btn { background: var(--c-teal); }
.mp-opt[hidden] { display: none; }
.mp-trial-modes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.mp-choose .mp-opt.trial .mp-trial-modes .menu-btn { height: auto; min-height: 58px; padding: 8px 10px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; line-height: 1.1; }
.mp-trial-modes .menu-btn b { font-size: 16px; }
.mp-trial-modes .menu-btn small { font-size: 11px; font-weight: 700; opacity: 0.85; }

/* An unpublished level on the map: only editors get it (dashed frame, a "TASLAK" tag in its top-right corner) */
.level-card.draft, .level-extra.draft { outline: 2px dashed #e8a33d; outline-offset: -2px; }
.level-card.draft { position: relative; }
.level-draft-tag { position: absolute; top: 4px; right: 4px; padding: 1px 5px; border-radius: 6px; background: #e8a33d; color: #1f2b3a;
  font-size: 9px; font-weight: 900; letter-spacing: 0.05em; line-height: 1.3; }

/* Android app update (js/app-store-update.js): the soft and the hard window share one look; the hard one sits over
   every other window. The strip at the top of the menu stays until the player updates (its ✕ hides it for now). */
#modal-store-force { z-index: 3000; background: rgba(20,28,40,0.8); }
.store-modal .modal-box { display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; }
.store-modal h3 { margin: 6px 0 0; }
.store-modal p { margin: 0; }
.ss-icon { position: relative; width: 76px; height: 76px; flex: none; }
.ss-icon > svg { width: 100%; height: 100%; display: block; }
.ss-icon i { position: absolute; right: -8px; bottom: -8px; width: 32px; height: 32px; border-radius: 50%;
  background: var(--c-green, #3f8f57); box-shadow: 0 0 0 3px var(--surface, #fffdf8); display: flex; align-items: center; justify-content: center; }
.ss-icon.force i { background: var(--c-orange, #c45f28); }
.ss-icon i svg, .ss-arrow svg { width: 18px; height: 18px; fill: none; stroke: #fff; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.ss-notes { list-style: none; margin: 2px 0 0; padding: 12px 14px; width: 100%; box-sizing: border-box; border-radius: 16px;
  background: var(--surface-2); display: flex; flex-direction: column; gap: 8px; text-align: left; font-size: 14px; font-weight: 700; }
.ss-notes li { display: flex; gap: 10px; align-items: flex-start; }
.ss-tick { flex: none; width: 22px; height: 22px; border-radius: 50%; background: rgba(43,116,112,0.14); color: var(--c-teal, #2b7470);
  display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 900; }
.ss-safe { width: 100%; box-sizing: border-box; padding: 12px 14px; border-radius: 16px; background: rgba(43,116,112,0.12);
  display: flex; gap: 10px; align-items: center; text-align: left; font-size: 14px; font-weight: 800; }
.ss-safe svg { flex: none; width: 26px; height: 26px; fill: none; stroke: var(--c-teal, #2b7470); stroke-width: 2.3; stroke-linecap: round; stroke-linejoin: round; }
body .store-modal .ss-go, body.themed .store-modal .ss-go { width: 100%; margin-top: 4px; display: flex; align-items: center; justify-content: center; gap: 10px;
  background: var(--c-teal, #2b7470); color: #fff; }
.store-modal .ss-go svg.ss-play { width: 20px; height: 20px; fill: currentColor; stroke: none; }
.ss-later { border: none; background: none; color: inherit; opacity: 0.7; font: inherit; font-size: 15px; font-weight: 800; padding: 8px 22px; cursor: pointer; }
.ss-versions { font-size: 12px; font-weight: 700; opacity: 0.55; }
#store-strip { display: flex; align-items: center; gap: 10px; width: 100%; max-width: 420px; box-sizing: border-box; margin: 0 auto 6px;
  padding: 8px 6px 8px 12px; border-radius: 16px; background: var(--c-teal, #2b7470); color: #fff; text-align: left; }
#store-strip[hidden] { display: none; }
.ss-arrow { flex: none; width: 30px; height: 30px; border-radius: 50%; background: rgba(255,255,255,0.18); display: flex; align-items: center; justify-content: center; }
.ss-text { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.2; }
.ss-text b { font-size: 14px; font-weight: 900; }
.ss-text small { font-size: 12px; font-weight: 700; opacity: 0.85; }
#store-strip-go { flex: none; border: none; padding: 7px 14px; border-radius: 999px; background: #fff; color: var(--c-teal, #2b7470);
  font: inherit; font-weight: 900; font-size: 14px; cursor: pointer; }
#store-strip-close { flex: none; width: 30px; height: 30px; border: none; background: none; color: #fff; opacity: 0.8; font-size: 16px; font-weight: 900; cursor: pointer; }

/* ---- Friends (js/friends.js): the list and the invite link's screen ---- */
#screen-friends, #screen-friend-invite { align-items: stretch; }
#signin-chip { position: relative; }
.menu-badge.chip-badge { top: -8px; right: -8px; min-width: 20px; height: 20px; padding: 2px 5px 0; font-size: 12px; box-shadow: 0 0 0 2px var(--bg1, #fff); }
.menu-badge.inline-badge { position: static; display: inline-flex; vertical-align: middle; min-width: 22px; height: 22px; margin-left: 6px; font-size: 13px; box-shadow: none; }
.menu-badge.inline-badge[hidden] { display: none; }
#friends-open-btn { width: 100%; margin: 4px 0 2px; }
.fr-invite, .fr-guest { background: var(--surface); border-radius: 18px; padding: 16px; box-shadow: inset 0 0 0 2px var(--line-soft); display: flex; flex-direction: column; gap: 10px; text-align: left; }
.fr-invite[hidden], .fr-guest[hidden], .fr-list-wrap[hidden] { display: none; }
.fr-invite b { font-family: var(--font-display); font-size: 19px; font-weight: 800; }
.fr-invite p, .fr-guest p { margin: 0; font-size: 14px; font-weight: 700; line-height: 1.4; opacity: 0.8; }
#friends-invite-btn { width: 100%; margin: 0; background: var(--c-orange); color: #fff; }
#friends-invite-btn:disabled { opacity: 0.55; }
.fr-list-wrap { display: flex; flex-direction: column; gap: 8px; text-align: left; }
.fr-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.fr-row { display: flex; align-items: center; gap: 12px; padding: 8px 8px 8px 10px; border-radius: 14px; background: var(--surface-2); }
.fr-row.is-new { box-shadow: inset 0 0 0 2px #e5484d; }
.account-av.fr-av { width: 40px; height: 40px; font-size: 18px; }
.fr-name { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; }
.fr-name b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 16px; }
.fr-new { flex: none; padding: 2px 8px; border-radius: 999px; background: #e5484d; color: #fff; font-size: 11px; font-weight: 800; }
.fr-remove { flex: none; width: 36px; height: 36px; border: none; border-radius: 50%; background: transparent; color: var(--fg); opacity: 0.55; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.fr-remove svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; }
.fr-empty { margin: 0; padding: 12px 4px; font-size: 14px; font-weight: 700; opacity: 0.7; }
.fr-empty[hidden] { display: none; }
.account-av.fr-big-av { width: 88px; height: 88px; font-size: 40px; }
.account-av.fr-big-av[hidden] { display: none; }
#finv-accept-btn, #finv-list-btn { width: 100%; margin: 0; }
#finv-accept-btn { background: var(--c-orange); color: #fff; }
#finv-accept-btn[hidden], #finv-list-btn[hidden] { display: none; }
#finv-accept-btn:disabled { opacity: 0.55; }
#finv-sub small { font-size: 13px; opacity: 0.8; }

/* Friend progress (Nov 2026): level badge on the avatar, a stats line, the profile window */
.fr-row { cursor: pointer; }
.fr-av-wrap { position: relative; flex: none; display: inline-flex; }
.fr-lvl {
  position: absolute; right: -5px; bottom: -4px; min-width: 20px; height: 20px; padding: 2px 5px 0; box-sizing: border-box;
  border-radius: 999px; background: var(--c-teal); color: #fff; box-shadow: 0 0 0 2px var(--surface-2);
  display: flex; align-items: center; justify-content: center; font-family: var(--font-display); font-size: 12px; font-weight: 800; line-height: 1;
}
.fr-lvl[hidden] { display: none; }
.fr-name { flex-direction: column; align-items: stretch; gap: 1px; }
.fr-name-top { display: flex; align-items: center; gap: 8px; min-width: 0; }
.fr-stats { font-size: 12px; font-weight: 700; opacity: 0.7; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fr-profile { text-align: left; }
.fr-prof-head { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.fr-prof-head h3 { margin: 0; text-align: left; }
.fr-prof-head small { font-size: 12px; font-weight: 700; opacity: 0.7; }
.account-av.fr-prof-av { width: 60px; height: 60px; font-size: 26px; }
.fr-prof-head .fr-lvl { min-width: 26px; height: 26px; font-size: 14px; box-shadow: 0 0 0 3px var(--surface); }
.fr-prof-rows { list-style: none; margin: 0 0 14px; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.fr-prof-rows li { display: flex; align-items: center; gap: 12px; background: var(--surface-2); border-radius: 14px; padding: 12px 14px; font-size: 15px; font-weight: 700; line-height: 1.3; }
.fr-prof-rows li > span:first-child { font-size: 20px; flex: none; width: 26px; text-align: center; }
.fr-prof-rows b { font-weight: 900; }

/* The account window's editor link (editors only): a full-width tile set apart from the account buttons, so it is
   easy to hit (it used to be a small text link between them) */
#modal-signin .editor-btn {
  display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; box-sizing: border-box;
  height: 46px; margin: 10px 0 6px; border-radius: 14px; background: var(--surface-2); color: var(--fg);
  box-shadow: inset 0 0 0 1.5px var(--line-soft); font-weight: 800; font-size: 15px; text-decoration: none;
}
#modal-signin .editor-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
#modal-signin .editor-btn:active { transform: scale(0.98); }

/* New levels (Nov 2026): "+N" on "Resimli Bölümler", "YENİ" on the new map cards. */
#btn-single { position: relative; }
.menu-badge.new-badge { font-size: 13px; font-weight: 900; }
.level-card { position: relative; }
.level-new-tag { position: absolute; top: -7px; left: 50%; transform: translateX(-50%); padding: 2px 8px; border-radius: 999px;
  background: #e5484d; color: #fff; font-size: 10px; font-weight: 900; letter-spacing: 0.5px; box-shadow: 0 0 0 2px var(--bg1, #fff); }

/* Settings group titles with a thin line running to the right edge (Nov 2026). */
.settings-group-title { display: flex; align-items: center; gap: 10px; }
.settings-group-title::after { content: ''; flex: 1; height: 1px; background: currentColor; opacity: 0.45; }
.about-version { flex: none; font-family: var(--font-display); font-size: 16px; font-weight: 800; color: rgba(var(--fg-rgb),0.75); white-space: nowrap; }

/* Friends' room invites (js/mp-invites.js): "Davetler" rows and the friend picker */
.mp-invites { margin-bottom: 12px; }
.mp-inv-row { cursor: default; box-shadow: inset 0 0 0 2px var(--c-teal); }
.mp-inv-row .who { font-size: 14px; font-weight: 700; }
.mp-inv-row .who .nm { font-family: inherit; font-size: 14px; letter-spacing: 0; }
.mp-inv-actions { display: flex; gap: 8px; margin-top: 4px; }
.mp-inv-actions .menu-btn { width: auto; flex: 1; padding: 8px 12px; font-size: 14px; }
.mp-share { flex-wrap: wrap; }
.rf-sub { font-size: 13px; line-height: 1.4; opacity: 0.8; }
.rf-list { list-style: none; margin: 8px 0 4px; padding: 0; display: flex; flex-direction: column; gap: 6px; max-height: 46dvh; overflow-y: auto; }
.rf-row label { display: flex; align-items: center; gap: 10px; padding: 6px 10px; border-radius: 12px; background: var(--surface-2); cursor: pointer; }
.rf-row:not(.free) label { cursor: default; opacity: 0.6; }
.rf-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 15px; }
.rf-tag { font-size: 12px; font-weight: 800; opacity: 0.8; }
.rf-row input { width: 22px; height: 22px; accent-color: var(--primary); }
.rf-empty { text-align: center; }

/* Settings: the music volume slider fills the row (js/music.js) */
#music-vol-row { gap: 14px; }
#music-vol { flex: 1; min-width: 120px; accent-color: var(--primary); height: 32px; }
