@font-face { font-family: 'Fredoka'; font-weight: 500; font-display: swap; src: url(vendor/fonts/fredoka-latin-500-normal.woff2) format('woff2');
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Fredoka'; font-weight: 500; font-display: swap; src: url(vendor/fonts/fredoka-latin-ext-500-normal.woff2) format('woff2');
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: 'Fredoka'; font-weight: 600; font-display: swap; src: url(vendor/fonts/fredoka-latin-600-normal.woff2) format('woff2');
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Fredoka'; font-weight: 600; font-display: swap; src: url(vendor/fonts/fredoka-latin-ext-600-normal.woff2) format('woff2');
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: 'Fredoka'; font-weight: 700; font-display: swap; src: url(vendor/fonts/fredoka-latin-700-normal.woff2) format('woff2');
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Fredoka'; font-weight: 700; font-display: swap; src: url(vendor/fonts/fredoka-latin-ext-700-normal.woff2) format('woff2');
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }

:root {
  --ink: #1f2a3d;
  --ink-soft: #5b6679;
  --paper: #eef1f6;
  --card: rgba(255, 255, 255, 0.9);
  --accent: #ff4d5e;
  --accent-dark: #c4303f;
  --go: #2ec4a6;         /* marka rengi (vurgu, halkalar) */
  --go-dark: #1f8f79;
  --go-btn: #178a74;     /* beyaz yazılı düğmeler: okunur kontrast (≥4,3:1) */
  --go-btn-top: #1fa98c;
  --go-btn-dark: #0f6655;
  --bad-btn: #d93344;
  --gold: #ffc93c;
  --shadow: 0 10px 30px rgba(31, 42, 61, 0.18);
  --safe-t: env(safe-area-inset-top, 0px);
  --safe-r: env(safe-area-inset-right, 0px);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-l: env(safe-area-inset-left, 0px);
  --font: 'Fredoka', ui-rounded, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; overflow: hidden; background: #e9edf3; color: var(--ink); font-family: var(--font);
  -webkit-user-select: none; user-select: none; overscroll-behavior: none; touch-action: none; }
#gl, #fx { position: fixed; inset: 0; width: 100vw; height: 100vh; height: 100dvh; display: block; }
canvas { display: block; }
#fx { pointer-events: none; }
#touch { position: fixed; inset: 0; touch-action: none; }
#vignette { position: fixed; inset: 0; pointer-events: none; background: radial-gradient(ellipse at center, rgba(31, 42, 61, 0) 55%, rgba(31, 42, 61, .14) 100%); }
button { font-family: inherit; }

/* Yüzen çubuk (dokunmatik) */
#joy { position: fixed; left: -48px; top: -48px; width: 96px; height: 96px; border-radius: 50%; pointer-events: none;
  border: 3px solid rgba(31, 42, 61, 0.18); background: rgba(255, 255, 255, 0.14); opacity: 0; transition: opacity .15s; }
#joy.on { opacity: 1; }
#joy i { position: absolute; left: 28px; top: 28px; width: 40px; height: 40px; border-radius: 50%; background: rgba(31, 42, 61, 0.28); }

/* Oyun içi göstergeler */
#hud { position: fixed; inset: 0; pointer-events: none; }
#hud .mine { position: absolute; left: calc(14px + var(--safe-l)); top: calc(10px + var(--safe-t)); display: flex; flex-direction: column; }
#pct { font-size: clamp(30px, 6vmin, 46px); font-weight: 700; color: #fff; letter-spacing: .5px;
  text-shadow: 0 3px 0 rgba(31, 42, 61, .35), 0 0 12px rgba(31, 42, 61, .25); line-height: 1; }
#hud .mine.dead { opacity: .45; }
#pct.hurt { animation: hurt .6s; }
@keyframes hurt { 0%, 60% { color: #ff4d5e; transform: scale(1.12); } 100% { color: #fff; transform: none; } }
#pct { transform-origin: left center; }
#sub { margin-top: 4px; font-size: 15px; font-weight: 600; color: #fff; text-shadow: 0 2px 0 rgba(31, 42, 61, .35); }
#lb { position: absolute; right: calc(10px + var(--safe-r)); top: calc(10px + var(--safe-t)); margin: 0; padding: 6px 6px; list-style: none;
  width: min(210px, 46vw); background: rgba(31, 42, 61, .28); border-radius: 12px; backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
#lb:empty { display: none; }
#lb li { display: flex; align-items: center; gap: 6px; padding: 3px 6px; font-size: 13px; font-weight: 600; color: #fff; border-radius: 8px; }
#lb li.me { background: rgba(255, 255, 255, .22); }
#lb i { width: 10px; height: 10px; border-radius: 3px; flex: none; }
#lb b { width: 14px; text-align: right; opacity: .8; font-weight: 600; }
#lb span { flex: 1; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
#lb em { font-style: normal; font-variant-numeric: tabular-nums; opacity: .95; }
#feed { position: absolute; left: 50%; top: calc(12px + var(--safe-t)); transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 4px; }
#feed div { padding: 4px 12px; border-radius: 999px; background: rgba(31, 42, 61, .45); color: #fff; font-size: 14px; font-weight: 600; white-space: nowrap; }
#feed div.mine { background: rgba(255, 77, 94, .85); }
#net { position: absolute; left: calc(12px + var(--safe-l)); bottom: calc(8px + var(--safe-b)); font-size: 12px; color: rgba(31, 42, 61, .55); font-weight: 600; }
@media (max-width: 560px) {
  #feed { top: auto; bottom: calc(118px + var(--safe-b)); max-width: 64vw; } /* mini harita ve alttaki düğmelerin üstünde */
  #feed div { font-size: 12px; padding: 3px 10px; white-space: normal; text-align: center; }
  #lb { width: min(170px, 44vw); padding: 4px; }
  #lb li { font-size: 12px; padding: 2px 5px; }
  #lb li:nth-child(n+4):not(.me) { display: none; }
  #tut { font-size: 15px; padding: 9px 14px; bottom: calc(150px + var(--safe-b)); }
  #hud:has(#tut:not([hidden])) #feed { display: none; } /* öğretici ile ölüm akışı üst üste binmesin */
}

/* Ekranlar */
.screen { position: fixed; inset: 0; display: flex; padding: 16px; overflow-y: auto; touch-action: pan-y; overscroll-behavior: contain;
  padding-top: calc(16px + var(--safe-t)); padding-bottom: calc(16px + var(--safe-b)); padding-left: calc(16px + var(--safe-l)); padding-right: calc(16px + var(--safe-r)); }
.screen > .card { margin: auto; } /* ortalı; sığmazsa üstten kırpılmadan kaydırılır */
.screen[hidden] { display: none; }
#menu { background: radial-gradient(ellipse at center, rgba(233, 237, 243, 0) 30%, rgba(233, 237, 243, .55) 100%); }
#over, #winBox { background: rgba(31, 42, 61, .28); }
.card { width: min(360px, 100%); background: var(--card); border-radius: 26px; padding: 22px 22px 18px; box-shadow: var(--shadow);
  display: flex; flex-direction: column; align-items: stretch; gap: 12px; text-align: center; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  animation: pop .28s cubic-bezier(.2, 1.4, .4, 1); }
@keyframes pop { from { transform: scale(.9); opacity: 0; } }

.logo { margin: 2px 0 6px; display: flex; justify-content: center; gap: 6px; font-size: 58px; font-weight: 700; line-height: 1; }
.logo span { display: inline-grid; place-items: center; width: 62px; height: 62px; border-radius: 16px; color: #fff; }
.logo span:nth-child(1) { background: #ff4d5e; box-shadow: 0 7px 0 #b3303d; transform: rotate(-6deg); }
.logo span:nth-child(2) { background: #ffc93c; box-shadow: 0 7px 0 #b78b18; transform: rotate(4deg) translateY(-3px); }
.logo span:nth-child(3) { background: #2ec4a6; box-shadow: 0 7px 0 #1b8a74; transform: rotate(-3deg) translateY(2px); }
.logo span:nth-child(4) { background: #4c6fff; box-shadow: 0 7px 0 #2e47b8; transform: rotate(6deg); }
@media (max-height: 700px) { #skins { max-height: 128px; } }
/* Yatay telefon: menü iki sütun (solda ad + görünüm, sağda mod + düğmeler) */
@media (max-height: 520px) and (orientation: landscape) {
  #menu .card { width: min(760px, 100%); display: grid; grid-template-columns: 1fr 1fr; column-gap: 16px; row-gap: 8px; align-items: start;
    grid-template-areas: "logo logo" "nick modes" "skh play" "sk stats" "sk online"; }
  #menu .logo { grid-area: logo; } #nick { grid-area: nick; } .skinHead { grid-area: skh; align-self: end; margin-bottom: 0; } #skins { grid-area: sk; max-height: 170px !important; }
  #modes { grid-area: modes; } #play { grid-area: play; } #stats { grid-area: stats; } #online { grid-area: online; }
  #menu .card .btn.big { padding: 11px 16px; font-size: 21px; }
  #over .card, #endBox .card { width: min(520px, 100%); }
  #over .stats { margin: 0; }
}
@media (max-height: 520px) { #skins { max-height: 66px; } .logo { font-size: 40px; } .logo span { width: 44px; height: 44px; border-radius: 12px; } .card { gap: 8px; padding: 14px 18px 12px; } }

#nick { width: 100%; font: inherit; font-size: 20px; font-weight: 600; text-align: center; color: var(--ink); padding: 12px 14px;
  border: 3px solid #dfe4ec; border-radius: 16px; background: #fff; outline: none; -webkit-user-select: text; user-select: text; }
#nick:focus { border-color: #b8c3d6; }
/* Ayarlar */
.card { position: relative; }
.topRow { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: -6px -6px 0; min-height: 44px; }
.gear, .friendsBtn { position: relative; flex: none; width: 44px; height: 44px; border-radius: 14px; border: 0; background: #eef1f6; font-size: 20px; cursor: pointer; color: var(--ink-soft); }
.srow { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-weight: 600; }
.seg { display: flex; gap: 4px; background: #eef1f6; padding: 4px; border-radius: 12px; }
.seg button { border: 0; background: transparent; padding: 7px 10px; min-height: 40px; border-radius: 9px; font: inherit; font-size: 14px; font-weight: 600; color: var(--ink-soft); cursor: pointer; white-space: nowrap; }
.seg button.on { background: #fff; color: var(--ink); box-shadow: 0 2px 6px rgba(31, 42, 61, .12); }
/* Ayarlar: bağlantılar */
.setLinks { display: flex; justify-content: center; gap: 6px; flex-wrap: wrap; }
.link { border: 0; background: none; font: inherit; font-size: 14px; font-weight: 600; color: var(--ink-soft); text-decoration: underline; min-height: 44px; padding: 0 12px; cursor: pointer; }
.link.bad { color: var(--bad-btn); }
.link.bad.arm { background: var(--bad-btn); color: #fff; text-decoration: none; border-radius: 12px; }
.link[hidden] { display: none; }
#settings { background: rgba(31, 42, 61, .45); z-index: 10; }
#settings h2 { margin: 0; font-size: 26px; }

/* Arkadaşlar */
.friendsBtn i { position: absolute; right: -5px; top: -5px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px; background: #ff4d5e; color: #fff;
  font-size: 12px; font-style: normal; font-weight: 700; line-height: 20px; box-shadow: 0 2px 0 rgba(0, 0, 0, .15); }
.friendsBtn i[hidden] { display: none; }
#friends { background: rgba(31, 42, 61, .45); z-index: 10; }
#friends .card, #settings .card { background: #fff; backdrop-filter: none; -webkit-backdrop-filter: none; }
.card.fr { width: min(420px, 100%); max-height: min(720px, calc(100dvh - 32px)); gap: 10px; text-align: left; }
.frHead { display: flex; align-items: center; justify-content: space-between; }
.frHead h2 { margin: 0; font-size: 26px; }
.icon.x { width: 44px; height: 44px; flex: none; border: 0; border-radius: 12px; background: #eef1f6; font-size: 16px; font-weight: 700; color: var(--ink-soft); cursor: pointer; }
#frOn { display: flex; flex-direction: column; gap: 10px; min-height: 0; flex: 1; }
#frOn[hidden], #frOff[hidden] { display: none; }
#frOff { text-align: center; color: var(--ink-soft); font-weight: 600; display: flex; flex-direction: column; gap: 10px; }
.myCode { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: 16px; background: linear-gradient(135deg, #eafaf6, #eef3ff); }
.myCode div { flex: 1; display: flex; flex-direction: column; }
.myCode small { font-size: 12px; color: var(--ink-soft); font-weight: 600; }
.myCode b { font-size: 26px; letter-spacing: 2px; font-weight: 700; white-space: nowrap; }
@media (max-width: 400px) { .myCode { flex-wrap: wrap; } .myCode div { flex-basis: 100%; } .myCode .chip { flex: 1; } }
.addRow { display: flex; gap: 8px; }
.addRow input { flex: 1; min-width: 0; font: inherit; font-size: 18px; font-weight: 600; letter-spacing: 1.5px; text-transform: uppercase; padding: 10px 12px;
  border: 3px solid #dfe4ec; border-radius: 14px; outline: none; -webkit-user-select: text; user-select: text; }
.addRow input:focus { border-color: #b8c3d6; }
.chip { border: 0; border-radius: 12px; padding: 9px 12px; min-height: 42px; min-width: 44px; font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; background: #e3e8f0; color: var(--ink-soft);
  white-space: nowrap; box-shadow: 0 3px 0 #c9d1dd; }
.chip:active { transform: translateY(2px); box-shadow: 0 1px 0 #c9d1dd; }
.chip.go { background: #15806b; color: #fff; box-shadow: 0 3px 0 var(--go-btn-dark); }
.chip.bad { background: var(--bad-btn); color: #fff; box-shadow: 0 3px 0 #9c2330; }
.chip.ghost { background: transparent; box-shadow: none; padding: 9px 8px; }
.chip.gold { background: linear-gradient(180deg, #ffd23f, #ffb300); color: #4a3000; box-shadow: 0 3px 0 #c98a00; }
.chip:disabled { opacity: .5; }
#frList { overflow-y: auto; min-height: 60px; flex: 1; margin: 0 -6px; padding: 0 6px 4px; overscroll-behavior: contain; touch-action: pan-y; }
#frList h3 { margin: 10px 2px 4px; font-size: 13px; text-transform: uppercase; letter-spacing: .6px; color: var(--ink-soft); }
#frList h3 em { font-style: normal; background: #eef1f6; border-radius: 8px; padding: 1px 7px; margin-left: 4px; }
.fr-row { display: flex; align-items: center; gap: 10px; padding: 6px 4px; border-radius: 14px; }
.fr-row:hover { background: #f5f7fa; }
.fr-row .av { width: 38px; height: 38px; flex: none; display: grid; place-items: center; }
.fr-row .who { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.fr-row .who b { font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fr-row .who small { font-size: 12px; color: var(--ink-soft); font-weight: 600; display: flex; align-items: center; gap: 5px; }
.fr-row .act { display: flex; gap: 10px; align-items: center; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: #b8c1ce; display: inline-block; flex: none; }
.dot.on { background: #2ec4a6; box-shadow: 0 0 0 3px rgba(46, 196, 166, .2); }
.dot.mid { background: #ffc93c; }
.empty { color: var(--ink-soft); font-size: 14px; font-weight: 500; margin: 4px 2px 8px; }
.muted { color: var(--ink-soft); font-size: 13px; font-weight: 600; }
#inv { position: fixed; left: 50%; top: calc(12px + var(--safe-t)); transform: translateX(-50%); z-index: 20; display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; border-radius: 18px; background: #fff; box-shadow: var(--shadow); width: min(440px, calc(100vw - 20px)); overflow: hidden;
  animation: invIn .35s cubic-bezier(.2, 1.4, .4, 1); }
#inv[hidden] { display: none; }
@keyframes invIn { from { transform: translate(-50%, -30px); opacity: 0; } }
#inv .av { width: 44px; height: 44px; flex: none; }
#inv p { flex: 1; margin: 0; font-size: 15px; font-weight: 600; line-height: 1.25; }
/* oyun sırasında: küçük davet (göstergeleri kapatmasın), altta */
#inv.mini { top: auto; bottom: calc(66px + var(--safe-b)); width: min(360px, calc(100vw - 120px)); padding: 6px 8px; gap: 8px; border-radius: 16px; }
#inv.mini .av { width: 32px; height: 32px; }
#inv.mini .av canvas { width: 32px !important; height: 32px !important; }
#inv.mini p { font-size: 13px; }
@keyframes invUp { from { transform: translate(-50%, 30px); opacity: 0; } }
#inv.mini { animation-name: invUp; }
#invBar { position: absolute; left: 0; bottom: 0; height: 3px; width: 100%; background: var(--go); transform-origin: left; }

/* Skin seçici */
.skinHead { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin: 2px 4px -4px; font-size: 15px; }
.skinHead b { font-weight: 700; }
.skinHead span { font-size: 12px; color: var(--ink-soft); font-weight: 600; text-align: right; flex: 1; }
.skinHead em { font-style: normal; font-size: 12px; font-weight: 700; color: var(--ink-soft); background: #eef1f6; border-radius: 8px; padding: 1px 7px; }
.skinHead em:empty { display: none; }
#skins { display: grid; grid-template-columns: repeat(auto-fill, minmax(52px, 1fr)); gap: 6px; max-height: 190px; overflow-y: auto; padding: 4px 2px 6px;
  scrollbar-width: thin; overscroll-behavior: contain; touch-action: pan-y; }
/* kaydırılabilir olduğunu göster: altta solan kenar (kilitli görünümler aşağıda) */
#skins.more { -webkit-mask-image: linear-gradient(#000 calc(100% - 26px), transparent); mask-image: linear-gradient(#000 calc(100% - 26px), transparent); }
#skins button { position: relative; height: 56px; border-radius: 14px; border: 0; background: #f1f4f8; cursor: pointer; display: grid; place-items: center;
  transition: transform .12s, background .12s; padding: 0; }
#skins button:hover { background: #e7ecf3; }
#skins button.on { background: #fff; box-shadow: 0 0 0 3px #2ec4a6, 0 4px 10px rgba(46, 196, 166, .3); transform: translateY(-1px); }
#skins button.locked canvas { filter: grayscale(.85) brightness(1.15); opacity: .55; }
#skins button i { position: absolute; right: 3px; bottom: 2px; font-size: 13px; font-style: normal; }
#skins button b.st { position: absolute; left: 3px; top: 2px; font-size: 10px; font-weight: 700; color: #c98a00; }
#skins button.buy i { font-size: 10px; font-weight: 700; color: #7a5a00; background: #ffe7a0; border-radius: 6px; padding: 0 4px; bottom: 3px; }

.btn { font-size: 18px; font-weight: 700; letter-spacing: .6px; border: 0; border-radius: 16px; padding: 13px 16px; cursor: pointer; color: #fff; transition: transform .08s, box-shadow .08s; }
.btn.big { font-size: 24px; padding: 15px 16px; background: linear-gradient(180deg, var(--go-btn-top), var(--go-btn)); box-shadow: 0 6px 0 var(--go-btn-dark);
  text-shadow: 0 2px 0 rgba(0, 0, 0, .18); }
.btn.big:active { transform: translateY(4px); box-shadow: 0 2px 0 var(--go-btn-dark); }
.btn.ghost { background: #e3e8f0; color: var(--ink-soft); box-shadow: 0 4px 0 #c9d1dd; }
.btn.ghost:active { transform: translateY(3px); box-shadow: 0 1px 0 #c9d1dd; }
.btn:disabled { filter: grayscale(.6); opacity: .7; }
.hint { margin: 2px 0 0; font-size: 13px; color: var(--ink-soft); font-weight: 500; }
.hint.small { margin-top: -6px; font-size: 12px; }
.hint:empty { display: none; }

#over h2, #winBox h2 { margin: 4px 0 0; font-size: 34px; font-weight: 700; }
#overWhy, #winSub { margin: 0; font-size: 17px; color: var(--ink-soft); font-weight: 600; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 4px 0; }
.stats div { background: #f1f4f8; border-radius: 14px; padding: 10px 4px; display: flex; flex-direction: column; }
.stats b { font-size: 22px; font-weight: 700; font-variant-numeric: tabular-nums; }
.stats span { font-size: 12px; color: var(--ink-soft); font-weight: 600; text-transform: uppercase; letter-spacing: .5px; }
.card.win h2 { font-size: 38px; background: linear-gradient(90deg, #ff4d5e, #ffc93c, #2ec4a6, #4c6fff); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* Oyun içi: mini harita, açılır yazılar, öğretici, çıkış */
#mini { position: absolute; left: calc(12px + var(--safe-l)); bottom: calc(24px + var(--safe-b)); width: 118px; height: 118px; border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, .8), 0 6px 16px rgba(31, 42, 61, .25); background: rgba(190, 198, 212, .55); }
@media (max-width: 560px), (max-height: 480px) { #mini { width: 84px; height: 84px; } }
#pop { position: absolute; left: 50%; top: 30%; transform: translate(-50%, -50%) scale(.6); font-size: clamp(28px, 7vmin, 54px); font-weight: 700; color: #fff;
  white-space: nowrap; opacity: 0; text-shadow: 0 4px 0 rgba(31, 42, 61, .35), 0 0 18px rgba(31, 42, 61, .25); pointer-events: none; }
#pop.on { animation: popin 1.3s cubic-bezier(.2, 1.4, .4, 1) forwards; }
#pop.hot { color: #ffd23f; }
#pop.gold { color: #ffe066; }
@keyframes popin { 0% { opacity: 0; transform: translate(-50%, -50%) scale(.5); } 15% { opacity: 1; transform: translate(-50%, -50%) scale(1.12); }
  25% { transform: translate(-50%, -50%) scale(1); } 75% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -70%) scale(1); } }
#tut { position: absolute; left: 50%; bottom: calc(110px + var(--safe-b)); transform: translateX(-50%); padding: 12px 20px; border-radius: 18px;
  background: rgba(31, 42, 61, .82); color: #fff; font-size: 18px; font-weight: 600; white-space: nowrap; max-width: 92vw; white-space: normal; text-align: center; }
#tut.bump { animation: bump .45s cubic-bezier(.2, 1.6, .4, 1); }
@keyframes bump { from { transform: translateX(-50%) scale(.8); opacity: 0; } }
#exit { position: absolute; right: calc(10px + var(--safe-r)); bottom: calc(62px + var(--safe-b)); width: 44px; height: 44px; border-radius: 14px; border: 0; white-space: nowrap;
  background: rgba(255, 255, 255, .75); box-shadow: 0 3px 0 rgba(31, 42, 61, .15); font-size: 16px; font-weight: 700; color: var(--ink-soft); cursor: pointer; pointer-events: auto;
  transition: width .2s, background .2s, color .2s; }
#exit.arm { width: 96px; background: var(--bad-btn); color: #fff; }

/* 3 Dakika modu */
.seg.modes { align-self: stretch; }
.seg.modes button { flex: 1; font-size: 15px; padding: 9px 6px; }
#timer { position: absolute; left: 50%; top: calc(10px + var(--safe-t)); transform: translateX(-50%); padding: 4px 16px; border-radius: 14px;
  background: rgba(31, 42, 61, .55); color: #fff; font-size: 24px; font-weight: 700; font-variant-numeric: tabular-nums; }
#timer[hidden] { display: none; }
#timer.low { background: #ff4d5e; animation: bump .5s infinite alternate; }
#timer:not([hidden]) ~ #feed { top: calc(56px + var(--safe-t)); }
/* Dar ekran: sayaç yüzdenin altında, solda (sıralama tablosuyla çakışmasın). Temel kuraldan SONRA gelmeli. */
@media (max-width: 560px) {
  #timer { left: calc(14px + var(--safe-l)); top: calc(76px + var(--safe-t)); transform: none; font-size: 19px; padding: 3px 12px; }
  #timer.low { animation: none; }
  #timer:not([hidden]) ~ #feed { top: auto; }
}
#endBox { background: rgba(31, 42, 61, .28); }
#endBox h2 { margin: 0; font-size: 32px; }
#podium { display: flex; align-items: flex-end; justify-content: center; gap: 8px; margin-top: 6px; }
#podium .pl { display: flex; flex-direction: column; align-items: center; gap: 4px; width: 96px; }
#podium .pl b { font-size: 14px; max-width: 96px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#podium .pl em { font-style: normal; font-size: 13px; color: var(--ink-soft); font-weight: 600; }
#podium .st { width: 100%; border-radius: 12px 12px 4px 4px; display: grid; place-items: center; color: #fff; font-size: 26px; font-weight: 700; }
#podium .p1 .st { height: 84px; background: linear-gradient(180deg, #ffd23f, #f5a300); }
#podium .p2 .st { height: 60px; background: linear-gradient(180deg, #cfd6e2, #9aa6b8); }
#podium .p3 .st { height: 44px; background: linear-gradient(180deg, #e5a36b, #b8733d); }
#podium .pl.me b { color: #1f8f79; }
#endMe { margin: 4px 0 0; font-weight: 700; font-size: 17px; }

/* Sonuç ekranı */
#addKiller { align-self: center; margin-top: -4px; }
#addKiller[hidden] { display: none; }
#record { align-self: center; padding: 4px 14px; border-radius: 999px; background: linear-gradient(90deg, #ffc93c, #ff8a3d); color: #fff; font-weight: 700;
  font-size: 15px; letter-spacing: .5px; animation: bump .5s cubic-bezier(.2, 1.6, .4, 1); }
#record[hidden], #unlock[hidden] { display: none; }
#unlock { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 14px; background: #fff7e0; font-weight: 600; font-size: 14px;
  text-align: left; animation: bump .5s .3s both cubic-bezier(.2, 1.6, .4, 1); }
.btn.gold { position: relative; overflow: hidden; display: flex; flex-direction: column; align-items: center; gap: 1px; font-size: 21px; padding: 11px 16px 13px;
  background: linear-gradient(180deg, #ffd23f, #ffb300); color: #5a3b00; box-shadow: 0 6px 0 #c98a00; }
.btn.gold small { font-size: 12px; font-weight: 600; opacity: .8; letter-spacing: 0; }
.btn.gold i { position: absolute; left: 0; bottom: 0; height: 4px; width: 100%; background: rgba(90, 59, 0, .35); transform-origin: left; transition: transform .1s linear; }
.btn.gold:active { transform: translateY(4px); box-shadow: 0 2px 0 #c98a00; }
.btn.gold[hidden] { display: none; }
.trophy { font-size: 64px; line-height: 1; animation: bump .6s cubic-bezier(.2, 1.6, .4, 1); }

#mute { position: fixed; right: calc(10px + var(--safe-r)); bottom: calc(10px + var(--safe-b)); z-index: 5; width: 44px; height: 44px; border-radius: 14px; border: 0;
  background: rgba(255, 255, 255, .75); box-shadow: 0 3px 0 rgba(31, 42, 61, .15); font-size: 18px; cursor: pointer; }
#toast { position: fixed; left: 50%; bottom: calc(70px + var(--safe-b)); transform: translate(-50%, 20px); padding: 10px 16px; border-radius: 14px;
  background: rgba(31, 42, 61, .88); color: #fff; font-weight: 600; font-size: 15px; opacity: 0; transition: .25s; pointer-events: none; max-width: 90vw; text-align: center; }
#toast.on { opacity: 1; transform: translate(-50%, 0); }
#toast.act { pointer-events: auto; display: flex; align-items: center; gap: 10px; z-index: 25; }
#err[hidden] { display: none; }
#err { position: fixed; inset: 0; display: grid; place-items: center; padding: 24px; background: #e9edf3; font-size: 18px; text-align: center; }

/* ---------------- Meta: seviye, coin, günlük, görevler, haftalık, koleksiyon ---------------- */
.cn { display: inline-block; width: 1em; height: 1em; border-radius: 50%; flex: none; vertical-align: -0.14em; margin-right: .22em;
  background: radial-gradient(circle at 35% 30%, #fff3b0 0 18%, #ffd23f 19% 55%, #f0a800 56%); box-shadow: inset 0 0 0 .09em #c98a00; }
#prof { flex: 1; min-width: 0; display: flex; align-items: center; justify-content: center; gap: 8px; }
#prof[hidden] { display: none; }
#prof button { border: 0; font: inherit; cursor: pointer; min-height: 44px; }
.lv { display: flex; align-items: center; gap: 7px; padding: 4px 10px 4px 4px; border-radius: 14px; background: #eef1f6; min-width: 0; }
.lv b { display: grid; place-items: center; min-width: 34px; height: 34px; padding: 0 5px; border-radius: 11px; background: linear-gradient(180deg, #6d8bff, #4c6fff);
  color: #fff; font-size: 15px; font-weight: 700; box-shadow: 0 2px 0 #2e47b8; }
.xp { display: block; width: 56px; height: 8px; border-radius: 4px; background: #d7deea; overflow: hidden; }
.xp i { display: block; height: 100%; width: 0; border-radius: 4px; background: linear-gradient(90deg, #6d8bff, #35b8ff); transition: width .6s; }
.coin { display: flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: 14px; background: #fff6d8; color: #6b4b00; font-size: 17px; font-weight: 700; }
.coin b { font-variant-numeric: tabular-nums; }
.coin.bump { animation: bump .5s cubic-bezier(.2, 1.6, .4, 1); }
#metaRow { display: grid; grid-template-columns: repeat(5, 1fr); gap: 5px; }
#metaRow[hidden] { display: none; }
#metaRow button { position: relative; border: 0; border-radius: 14px; background: #f1f4f8; min-height: 52px; padding: 5px 2px 4px; cursor: pointer; font: inherit;
  display: flex; flex-direction: column; align-items: center; gap: 1px; color: var(--ink-soft); box-shadow: 0 3px 0 #dde3ec; }
#metaRow button:active { transform: translateY(2px); box-shadow: 0 1px 0 #dde3ec; }
#metaRow span { font-size: 20px; line-height: 1.1; }
#metaRow small { font-size: 11px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.badge { position: absolute; right: 4px; top: 3px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--bad-btn); color: #fff;
  font-size: 11px; font-style: normal; font-weight: 700; line-height: 18px; animation: bump .6s cubic-bezier(.2, 1.6, .4, 1); }
.badge[hidden] { display: none; }
#sheet, #doc { background: rgba(31, 42, 61, .45); z-index: 10; }
#sheet .card, #doc .card { background: #fff; backdrop-filter: none; -webkit-backdrop-filter: none; }
.card.sh { width: min(440px, 100%); max-height: min(760px, calc(100dvh - 32px)); gap: 10px; text-align: left; }
#shBody { overflow-y: auto; min-height: 0; flex: 1; margin: 0 -6px; padding: 0 6px 6px; overscroll-behavior: contain; touch-action: pan-y; display: flex; flex-direction: column; gap: 10px; }
.sh .note { margin: 0; font-size: 13px; color: var(--ink-soft); font-weight: 600; }
.sh .foot { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; font-size: 12px; color: var(--ink-soft); font-weight: 600; }
/* Günlük seri */
.days { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.day { position: relative; border-radius: 16px; background: #f1f4f8; padding: 8px 4px; display: flex; flex-direction: column; align-items: center; gap: 3px; font-weight: 700; }
.day small { font-size: 11px; color: var(--ink-soft); }
.day b { font-size: 15px; display: flex; align-items: center; gap: 4px; }
.day.done { background: #e6f7f2; }
.day.done::after { content: '✓'; position: absolute; right: 7px; top: 4px; color: #15806b; font-size: 14px; }
.day.today { background: #fff6d8; box-shadow: 0 0 0 3px var(--gold); }
.day.big { grid-column: span 2; flex-direction: row; justify-content: center; gap: 10px; background: linear-gradient(135deg, #fff1e6, #ffe3e3); }
.day.big div { display: flex; flex-direction: column; align-items: flex-start; }
.sh .btn.big { font-size: 20px; padding: 12px 16px; }
/* Görevler */
.mis { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 16px; background: #f5f7fa; }
.mis .mt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 5px; }
.mis .mt b { font-size: 15px; }
.bar { height: 10px; border-radius: 5px; background: #dfe5ee; overflow: hidden; }
.bar i { display: block; height: 100%; border-radius: 5px; background: linear-gradient(90deg, #2ec4a6, #35b8ff); }
.mis .mt small { font-size: 12px; color: var(--ink-soft); font-weight: 600; display: flex; justify-content: space-between; }
.mis .ok { color: #15806b; font-weight: 700; font-size: 14px; }
.mis.done { background: #eefaf6; }
.tag { display: inline-flex; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 12px; background: #fff6d8; color: #6b4b00; font-size: 13px; font-weight: 700; }
.tag.off { background: #f1f4f8; color: var(--ink-soft); }
/* Haftalık */
.lead { display: flex; flex-direction: column; gap: 2px; }
.lr { display: flex; align-items: center; gap: 10px; padding: 5px 8px; border-radius: 12px; font-weight: 600; }
.lr.me { background: #e6f7f2; }
.lr > b { width: 30px; text-align: center; font-size: 15px; color: var(--ink-soft); flex: none; }
.lr .av { width: 30px; height: 30px; flex: none; }
.lr span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lr em { font-style: normal; font-variant-numeric: tabular-nums; font-weight: 700; }
/* Koleksiyon */
.skd { display: flex; gap: 14px; align-items: center; padding: 12px; border-radius: 18px; background: linear-gradient(135deg, #f3f6fb, #eef3ff); }
.skd .pv { flex: none; width: 96px; height: 96px; display: grid; place-items: center; }
.skd .inf { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.skd h3 { margin: 0; font-size: 22px; }
.stars { color: #d8dee8; font-size: 18px; letter-spacing: 1px; }
.stars b { color: #f0a800; font-weight: 400; }
.skd .fx { font-size: 12px; color: var(--ink-soft); font-weight: 600; }
.skd .acts { display: flex; flex-wrap: wrap; gap: 8px; }
.skd .acts .chip { display: inline-flex; align-items: center; gap: 6px; }
.skd s { opacity: .6; font-weight: 600; }
.deals { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.deal { position: relative; border: 0; border-radius: 16px; background: #fff6d8; padding: 8px 4px; display: flex; flex-direction: column; align-items: center; gap: 2px; cursor: pointer; font: inherit; }
.deal small { font-size: 12px; font-weight: 700; display: flex; align-items: center; gap: 4px; }
.deal s { font-size: 11px; color: var(--ink-soft); }
.deal::before { content: '-25%'; position: absolute; left: 6px; top: 6px; font-size: 10px; font-weight: 700; color: #fff; background: var(--bad-btn); border-radius: 6px; padding: 1px 5px; }
.deal.own { background: #eefaf6; }
.deal.own::before { content: '✓'; background: #15806b; }
.cgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(58px, 1fr)); gap: 6px; }
.cgrid button { position: relative; height: 62px; border: 0; border-radius: 14px; background: #f1f4f8; cursor: pointer; display: grid; place-items: center; padding: 0; }
.cgrid button.on { background: #fff; box-shadow: 0 0 0 3px #4c6fff; }
.cgrid button.locked canvas { filter: grayscale(.85) brightness(1.15); opacity: .55; }
.cgrid button i { position: absolute; right: 3px; bottom: 2px; font-size: 12px; font-style: normal; }
.cgrid button b { position: absolute; left: 4px; top: 2px; font-size: 10px; color: #c98a00; }
.sh h4 { margin: 4px 2px 0; font-size: 13px; text-transform: uppercase; letter-spacing: .6px; color: var(--ink-soft); }
/* Ödül (ölüm ekranı / podyum) */
.reward { display: flex; justify-content: center; align-items: center; gap: 8px; flex-wrap: wrap; }
.reward[hidden] { display: none; }
.reward > span { display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 12px; font-weight: 700; font-size: 17px; animation: bump .5s cubic-bezier(.2, 1.6, .4, 1) both; }
.reward .rc { background: #fff6d8; color: #6b4b00; }
.reward .rx { background: #eaefff; color: #2e47b8; animation-delay: .12s; }
.reward .rt { background: linear-gradient(90deg, #ff8a3d, #ff4d5e); color: #fff; font-size: 13px; animation-delay: .25s; }
.rwNote[hidden] { display: none; }
/* Oyun içi: izleme etiketi, devam geri sayımı */
#spec { position: absolute; left: 50%; bottom: calc(118px + var(--safe-b)); transform: translateX(-50%); padding: 6px 14px; border-radius: 999px; background: rgba(31, 42, 61, .6);
  color: #fff; font-weight: 600; font-size: 14px; white-space: nowrap; }
#spec[hidden], #resume[hidden] { display: none; }
#resume { position: absolute; inset: 0; display: grid; place-items: center; font-size: 96px; font-weight: 700; color: #fff; background: rgba(31, 42, 61, .25);
  text-shadow: 0 6px 0 rgba(31, 42, 61, .35); }
#resume.tick { animation: bump .5s cubic-bezier(.2, 1.6, .4, 1); }
/* Yasal satır (OYNA altında: şartlar + gizlilik) */
.legalLine { margin: 0; font-size: 12px; line-height: 1.35; }
.legalLine a { color: inherit; text-decoration: underline; cursor: pointer; }
.legalLine[hidden] { display: none; }
/* Ölüm ekranı: arkadaş ekle + şikâyet/engelle */
.killerRow { display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; }
.killerRow:not(:has(button:not([hidden]))) { display: none; }
/* Şikâyet düğmesi (sıralama satırı) */
.rpBtn { margin-left: auto; border: 0; background: transparent; color: var(--ink-soft); font: inherit; font-weight: 700; font-size: 18px; min-width: 40px; min-height: 36px; border-radius: 10px; cursor: pointer; }
.lr .rpBtn + em, .lr em + .rpBtn { margin-left: 4px; }
/* Ödüllü reklam düğmesi */
.chip.ad, .btn.ad { background: linear-gradient(180deg, #6d8bff, #4c6fff); color: #fff; box-shadow: 0 3px 0 #2f4bcc; }
.reward .chip.ad { flex-basis: 100%; margin-top: 4px; }
/* Mağaza (uygulama içi satın alma) */
.skus { display: flex; flex-direction: column; gap: 8px; }
.sku { display: flex; align-items: center; gap: 12px; width: 100%; border: 0; border-radius: 16px; padding: 10px 12px; background: #f1f4f9; color: var(--ink); font: inherit; text-align: left; cursor: pointer; box-shadow: 0 3px 0 #d5dce7; }
.sku:active { transform: translateY(2px); box-shadow: 0 1px 0 #d5dce7; }
.sku .si { font-size: 26px; min-width: 40px; display: grid; place-items: center; }
.sku .st { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.sku .st b { font-size: 16px; } .sku .st small { color: var(--ink-soft); font-size: 13px; }
.sku em { font-style: normal; font-weight: 700; background: #15806b; color: #fff; border-radius: 12px; padding: 8px 12px; white-space: nowrap; }
.sku.hot { background: linear-gradient(180deg, #fff6d6, #ffe9a3); box-shadow: 0 3px 0 #e2bf54; }
.sku.best { outline: 3px solid #ffb300; }
.sku:disabled { opacity: .6; }
/* Menüde ses düğmesi yok (ayarlarda var): kartın altını kapatmasın */
body.inMenu #mute { display: none; }
@media (max-height: 740px) { .logo { font-size: 44px; } .logo span { width: 48px; height: 48px; border-radius: 13px; } .card { gap: 10px; } }
@media (max-height: 520px) and (orientation: landscape) {
  #menu .card { grid-template-areas: "top top" "tabs nick" "skh modes" "sk play" "sk meta" "sk stats" "sk online"; }
  #menu .topRow { grid-area: top; } #metaRow { grid-area: meta; }
  #menu .logo { display: none; }
}
/* Kısa ekranlar (telefon dikey 640–760 px): menü kartı kaydırmadan sığsın. Temel kurallardan SONRA gelmeli. */
@media (max-height: 760px) {
  #skins { max-height: 128px; }
  .card { gap: 9px; }
  .logo { font-size: 40px; margin: 0 0 4px; } .logo span { width: 44px; height: 44px; border-radius: 12px; }
}
@media (max-height: 680px) {
  .card { padding: 16px 16px 14px; gap: 8px; }
  #menu #stats { display: none; }
  #nick { padding: 9px 12px; font-size: 18px; }
  .btn { padding: 11px 16px; } .btn.big { padding: 11px 16px; font-size: 22px; }
  #metaRow button { min-height: 46px; justify-content: center; } #metaRow small { display: none; } #metaRow span { font-size: 22px; }
  #skins { max-height: 124px; }
}
/* Yatay telefon: ayarlar iki sütun */
@media (max-height: 520px) {
  #settings .card { width: min(680px, 100%); display: grid; grid-template-columns: 1fr 1fr; column-gap: 18px; row-gap: 8px; align-items: center; }
  #settings h2, #settings .setLinks, #settings #setClose, #settings #ver { grid-column: 1 / -1; }
  #skins { max-height: 170px; }
}
.topRow .gear { margin-left: auto; } /* arkadaş düğmesi / şerit gizliyken de sağda */
/* Davet */
.refHero { display: flex; flex-direction: column; gap: 8px; padding: 14px; border-radius: 18px; background: linear-gradient(135deg, #e6faf5, #eef1ff); text-align: center; }
.refHero > b { font-size: 20px; }
.refHero p { margin: 0; font-size: 14px; color: var(--ink-soft); font-weight: 600; }
.refHero .btn.big { font-size: 19px; padding: 12px 14px; }
.rstep { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 14px; background: #f5f7fa; font-size: 14px; font-weight: 600; }
.rstep i { flex: none; display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: #4c6fff; color: #fff; font-style: normal; font-weight: 700; }
.rstep span { flex: 1; }
.rstep em { font-style: normal; font-weight: 700; color: #6b4b00; white-space: nowrap; font-size: 13px; }
.tiers { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.tier { display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 8px 4px; border-radius: 14px; background: #f1f4f8; font-size: 13px; }
.tier small { color: var(--ink-soft); font-weight: 700; }
.tier.got { background: #fff6d8; box-shadow: 0 0 0 2px var(--gold); }
.lr em.bad { color: var(--bad-btn); font-size: 12px; }
.lr em { font-size: 12px; text-align: right; }
/* Mod sekmeleri: LAND · FETİH (aynı hesap, aynı coin) */
.modeTabs { display: flex; gap: 4px; padding: 4px; border-radius: 14px; background: #eef1f6; }
.modeTabs a, .modeTabs span { flex: 1; min-height: 38px; display: grid; place-items: center; border-radius: 10px; font-weight: 700; font-size: 15px; color: var(--ink-soft); text-decoration: none; }
.modeTabs .on { background: #fff; color: var(--ink); box-shadow: 0 2px 6px rgba(31, 42, 61, .12); }
@media (max-height: 520px) and (orientation: landscape) { #menu .modeTabs { grid-area: tabs; align-self: center; } } /* yatay: sekmeler logonun yanında (üst satırla çakışmasın) */
.langSel { font: inherit; font-size: 15px; font-weight: 600; color: var(--ink); background: #eef1f6; border: 0; border-radius: 12px; padding: 10px 12px; min-height: 44px; max-width: 60%; cursor: pointer; }
html.rtl .card, html.rtl .sheet, html.rtl #toast { direction: rtl; }
/* sağdan sola dillerde: logo ve sayısal/yön bildiren öğeler soldan sağa kalır */
html[dir="rtl"] .logo, html[dir="rtl"] .bar, html[dir="rtl"] #hud canvas { direction: ltr; }

/* Sezon Kartı: alt düğme satırında 6. düğme (panel Fetih sayfasında) */
#metaRow.six { grid-template-columns: repeat(6, 1fr); }
#metaRow a { position: relative; border-radius: 14px; min-height: 52px; padding: 5px 2px 4px; display: flex; flex-direction: column; align-items: center; gap: 1px; text-decoration: none;
  color: #fff; background: linear-gradient(135deg, #ff8a3d, #e8394b 60%, #b3268f); box-shadow: 0 3px 0 #8a1f5a; }
#metaRow a[hidden] { display: none; }
#metaRow a:active { transform: translateY(2px); box-shadow: 0 1px 0 #8a1f5a; }
