:root {
  --zemin: #17110c;
  --pano: rgba(24, 18, 13, 0.95);
  --kenar: #6b5233;
  --kenarAcik: #a8834c;
  --yazi: #ecdcc0;
  --soluk: #a89878;
  --altin: #e8b85a;
  --can: #c8362f;
  --ofke: #d9822b;
  --xp: #8f6ad8;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; background: var(--zemin); color: var(--yazi);
  font: 14px/1.4 "Segoe UI", system-ui, sans-serif; user-select: none; }
#tuval { position: fixed; inset: 0; width: 100%; height: 100%; display: block; }
[hidden] { display: none !important; }
button { font: inherit; color: var(--yazi); background: linear-gradient(#4a3823, #33261a); border: 1px solid var(--kenarAcik);
  border-radius: 4px; padding: 6px 12px; cursor: pointer; }
button:hover { background: linear-gradient(#5d472c, #3f2f20); }
button:disabled { opacity: 0.45; cursor: not-allowed; }
kbd { font: 11px ui-monospace, monospace; background: #0008; border: 1px solid #fff3; border-radius: 3px; padding: 0 4px; margin: 0 2px; }

.pano { background: var(--pano); border: 1px solid var(--kenar); border-radius: 8px;
  box-shadow: 0 10px 40px #000a, inset 0 0 0 1px #fff1, inset 0 0 30px #0006; }

/* giriş */
#giris { position: fixed; inset: 0; display: grid; place-items: center; background: radial-gradient(ellipse at center, #2a1d12cc, #0b0806f2); z-index: 50; }
#girisForm { width: min(360px, 90vw); padding: 28px; display: grid; gap: 10px; text-align: center; }
#girisForm h1 { margin: 0; font-size: 54px; letter-spacing: 12px; color: var(--altin); text-shadow: 0 0 24px #ff7a1e88; }
#girisForm label { text-align: left; color: var(--soluk); font-size: 12px; margin-top: 8px; }
#girisForm input { font: inherit; padding: 10px; border-radius: 4px; border: 1px solid var(--kenar); background: #0c0906; color: var(--yazi); user-select: text; }
#girisForm button { padding: 10px; font-weight: 600; }
.alt { color: var(--soluk); margin: 0; font-size: 12px; min-height: 1em; }

/* çerçeveler */
.cerceve { position: fixed; display: flex; gap: 8px; align-items: center; padding: 7px 10px 7px 7px; background: var(--pano);
  border: 1px solid var(--kenar); border-radius: 30px 8px 8px 30px; box-shadow: 0 4px 16px #0008; }
.cerceve .govde { width: 220px; }
#oyuncuCerceve { left: 12px; top: 12px; }
#hedefCerceve { left: 50%; top: 12px; transform: translateX(-50%); border-color: #8a3a30; border-radius: 8px; padding: 7px 10px; }
.portre { width: 46px; height: 46px; border-radius: 50%; border: 2px solid var(--altin); background: radial-gradient(#5a4126, #1c140c);
  display: grid; place-items: center; font-weight: 800; font-size: 17px; color: var(--altin); text-shadow: 0 1px 2px #000; flex: none; }
.baslik { display: flex; justify-content: space-between; font-weight: 600; margin-bottom: 3px; font-size: 13px; }
.sv { color: var(--altin); font-weight: 500; }
.cubuk { position: relative; height: 16px; background: #0009; border: 1px solid #000c; border-radius: 3px; overflow: hidden; margin-top: 3px; box-shadow: inset 0 1px 3px #000; }
.cubuk i { position: absolute; inset: 0 auto 0 0; width: 0; transition: width 0.15s linear; }
.cubuk i::after { content: ""; position: absolute; inset: 0 0 55% 0; background: #fff2; }
.cubuk b { position: absolute; inset: 0; text-align: center; font-size: 11px; line-height: 14px; font-weight: 600; text-shadow: 0 1px 2px #000; }
.cubuk.can i { background: linear-gradient(#e2534a, #9c241f); }
.cubuk.ofke { height: 11px; } .cubuk.ofke b { line-height: 9px; font-size: 9px; }
.cubuk.ofke i { background: linear-gradient(#f0a04a, #b5611a); }
.cubuk.xp { height: 9px; margin-top: 6px; } .cubuk.xp b { line-height: 7px; font-size: 9px; }
.cubuk.xp i { background: linear-gradient(#a98be6, #6f4dbb); }
#etkiler { display: flex; gap: 4px; margin-top: 4px; }
#etkiler span { font-size: 11px; padding: 1px 6px; border-radius: 3px; background: #3b2c1a; border: 1px solid var(--kenarAcik); }

/* mini harita */
#haritaKutu { position: fixed; right: 12px; top: 12px; text-align: center; }
#miniHarita { display: block; width: 176px; height: 176px; border-radius: 50%; border: 2px solid var(--kenarAcik); box-shadow: 0 4px 16px #000a, inset 0 0 20px #000; background: #1c1610; }
#koordinat { display: inline-block; margin-top: 6px; padding: 2px 10px; font-size: 12px; letter-spacing: 0.5px; font-variant-numeric: tabular-nums;
  color: var(--yazi); background: #000a; border: 1px solid var(--kenar); border-radius: 10px; }
/* büyük harita (M) */
#buyukHarita { left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 6; }
#buyukHarita header span { font-size: 12px; opacity: 0.85; font-variant-numeric: tabular-nums; }
#haritaTuval { display: block; width: min(74vh, 86vw, 820px); height: min(74vh, 86vw, 820px); border: 1px solid var(--kenarAcik); border-radius: 4px; background: #1c1610; cursor: crosshair; }
#buyukHarita footer { display: flex; flex-wrap: wrap; gap: 4px 16px; justify-content: center; padding-top: 9px; font-size: 12px; }
#buyukHarita .nk { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 5px; border: 1px solid #000; vertical-align: -1px; }
.nk.ben { background: #fff; } .nk.oyuncu { background: #7fc4ff; } .nk.saldirgan { background: #ff5a48; } .nk.sakin { background: #f0d8a8; }
.nk.seckin { background: #ffcf5a; } .nk.kamp { background: #9fe58a55; border-color: #9fe58a !important; }
#bolge { margin-top: 5px; text-shadow: 0 1px 3px #000, 0 0 5px #000; }
#bolge b { display: block; font-size: 14px; color: var(--altin); }
#bolge span { font-size: 12px; }

/* günlük */
#gunluk { position: fixed; left: 12px; bottom: 14px; width: min(400px, 34vw); max-height: 170px; overflow: hidden; display: flex; flex-direction: column;
  justify-content: flex-end; font-size: 12.5px; text-shadow: 0 1px 2px #000, 0 0 4px #000; pointer-events: none; }
#gunluk div { padding: 1px 0; }
#gunluk .hata { color: #ff8f80; } #gunluk .iyi { color: #9fe58a; } #gunluk .ganimet { color: #e9d49a; } #gunluk .bilgi { color: #d8cdb8; }

/* alt çubuk */
#altCubuk { position: fixed; left: 50%; bottom: 12px; transform: translateX(-50%); width: 380px; padding: 8px 10px; background: var(--pano);
  border: 1px solid var(--kenar); border-radius: 10px; box-shadow: 0 4px 18px #0009; }
#beceriler { display: flex; gap: 8px; justify-content: center; }
.beceri { position: relative; width: 56px; height: 56px; border: 2px solid var(--kenarAcik); border-radius: 8px; background: radial-gradient(#4b3520, #1a120b);
  padding: 7px; cursor: pointer; overflow: hidden; box-shadow: inset 0 0 10px #000; }
.beceri:hover { border-color: var(--altin); }
.beceri.iksir { margin-left: 14px; border-color: #a04848; }
.beceri .tus { position: absolute; left: 3px; top: 1px; font: 700 10px ui-monospace, monospace; color: #fff; text-shadow: 0 1px 2px #000; z-index: 2; }
.beceri .adet { position: absolute; right: 3px; bottom: 1px; font-size: 11px; font-weight: 700; text-shadow: 0 1px 2px #000; z-index: 2; }
.beceri .perde { position: absolute; inset: 0; background: conic-gradient(#000c var(--kalan, 0deg), transparent 0); pointer-events: none; }
.beceri .sure { position: absolute; inset: 0; display: grid; place-items: center; font-size: 17px; font-weight: 800; color: #fff; text-shadow: 0 1px 3px #000; pointer-events: none; }
.beceri.kilitli { filter: grayscale(1) brightness(0.5); }
.beceri.kilitli::after { content: attr(data-sv); position: absolute; inset: auto 0 2px 0; text-align: center; font-size: 10px; font-weight: 700; color: #fff; }
.beceri.yetersiz { border-color: #555; filter: saturate(0.4); }
.beceri.parla { animation: parla 0.35s ease-out; }
@keyframes parla { from { box-shadow: 0 0 0 0 #ffe08acc, inset 0 0 18px #ffe08a; } to { box-shadow: 0 0 0 14px #ffe08a00, inset 0 0 10px #000; } }

#dSes.kapali { opacity: 0.6; }
#dugmeler { position: fixed; right: 12px; bottom: 14px; display: flex; gap: 8px; }
#dKarakter.puan { border-color: var(--altin); box-shadow: 0 0 10px #e8b85a88; }

/* pencereler */
.pencere { position: fixed; padding: 0 12px 12px; z-index: 5; }
.pencere header { display: flex; align-items: center; gap: 12px; padding: 10px 0 8px; border-bottom: 1px solid var(--kenar); margin-bottom: 10px; }
.pencere h2 { margin: 0; font-size: 15px; color: var(--altin); flex: 1; letter-spacing: 1px; }
.kapat { padding: 0 8px; font-size: 16px; line-height: 22px; }
#canta { right: 12px; bottom: 66px; }
#sikke { color: var(--altin); font-weight: 600; }
.envanterIc { display: flex; gap: 14px; }
#kusamAlan { display: grid; grid-template-columns: repeat(3, 48px); grid-auto-rows: 48px; gap: 6px; padding: 8px; align-content: start;
  background: radial-gradient(ellipse at 50% 35%, #3a2a18, #120d08); border: 1px solid #4a3a26; border-radius: 6px; }
#cantaIzgara { display: grid; grid-template-columns: repeat(8, 46px); grid-auto-rows: 46px; gap: 4px; align-content: start; }
.yuva { position: relative; border: 1px solid #4a3a26; border-radius: 5px; background: linear-gradient(#17110b, #0c0906); padding: 5px;
  box-shadow: inset 0 0 8px #000; cursor: pointer; --nadir: #4a3a26; }
.yuva.dolu { border-color: var(--nadir); box-shadow: inset 0 0 8px #000, inset 0 0 12px color-mix(in srgb, var(--nadir) 35%, transparent); }
.yuva.dolu:hover { filter: brightness(1.35); }
.yuva.secili { outline: 2px solid var(--altin); outline-offset: 1px; }
.yuva.hedef { outline: 2px dashed #9fe58a; outline-offset: 1px; }
.yuva.bos svg { opacity: 0.16; filter: grayscale(1); }
.yuva .adet { position: absolute; right: 2px; bottom: 0; font-size: 11px; font-weight: 700; color: #fff; text-shadow: 0 1px 2px #000, 0 0 3px #000; }
/* sınıfa özel kuşam: simgenin altında sınıf adı */
.snEtiket { position: absolute; left: 0; right: 0; bottom: 0; padding: 1px 0; font-size: 9px; font-weight: 700; line-height: 1.1; text-align: center; color: #f3e6c8; background: #000a; text-shadow: 0 1px 1px #000; pointer-events: none; letter-spacing: .2px; }
.snEtiket.sn-savasci { color: #ffb38a; } .snEtiket.sn-avci { color: #b9e08a; } .snEtiket.sn-buyucu { color: #a9c8ff; } .snEtiket.sn-saman { color: #8fe6d6; }
.yuva .arti { position: absolute; left: 2px; top: -1px; font-size: 11px; font-weight: 800; color: var(--altin); text-shadow: 0 1px 2px #000, 0 0 3px #000; }
.yuva svg { pointer-events: none; display: block; }
#ayrinti { margin-top: 10px; min-height: 74px; padding: 8px 10px; background: #0f0b07; border: 1px solid #4a3a26; border-radius: 5px; font-size: 12.5px; max-width: 590px; }
#ayrinti h3 { margin: 0 0 2px; font-size: 14px; }
.satir { color: var(--soluk); }
#ayrinti .islem { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
#ayrinti button { padding: 4px 10px; font-size: 12px; }
.bedel { margin-top: 5px; color: #e9d49a; }
#surukle { position: fixed; left: 0; top: 0; width: 44px; height: 44px; padding: 4px; pointer-events: none; z-index: 70; opacity: 0.9; filter: drop-shadow(0 4px 6px #000); }

#karakter { left: 12px; top: 96px; width: 290px; max-height: calc(100vh - 300px); overflow-y: auto; }
#karakterIc table, #yardim table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
#karakterIc td, #yardim td { padding: 3px 0; }
#karakterIc td:last-child { text-align: right; font-variant-numeric: tabular-nums; }
#karakterIc h3 { margin: 10px 0 4px; font-size: 11px; color: var(--soluk); text-transform: uppercase; letter-spacing: 1px; }
#karakterIc .arti { padding: 0 7px; line-height: 18px; margin-left: 6px; }
.puan { color: var(--altin); font-weight: 600; }
#yardim { left: 50%; top: 50%; transform: translate(-50%, -50%); width: 400px; }
#yardim td:first-child { color: var(--altin); white-space: nowrap; padding-right: 14px; }

/* dünya etiketleri */
#etiketler, #sayilar { position: fixed; inset: 0; pointer-events: none; overflow: hidden; }
.etiket { position: absolute; left: 0; top: 0; text-align: center; white-space: nowrap; font-size: 12px; font-weight: 600;
  text-shadow: 0 1px 2px #000, 0 0 3px #000; will-change: transform; }
.etiket small { font-weight: 500; opacity: 0.85; }
.etiket.mob { color: #f0d8a8; } .etiket.saldirgan { color: #ffb0a0; } .etiket.seckin { color: #ffcf5a; font-size: 13px; } .etiket.oyuncu { color: #bfe3ff; } .etiket.ben { color: #fff; }
.etiket .mini { width: 58px; height: 6px; margin: 2px auto 0; background: #000a; border: 1px solid #000; border-radius: 2px; overflow: hidden; }
.etiket .mini i { display: block; height: 100%; background: linear-gradient(#e2534a, #9c241f); }
.sayi { position: absolute; left: 0; top: 0; font-weight: 800; font-size: 18px; color: #fff; text-shadow: 0 1px 0 #000, 0 0 4px #000; will-change: transform, opacity; }
.sayi.krit { font-size: 27px; color: #ffd84a; } .sayi.alinan { color: #ff6a5a; } .sayi.iyi { color: #7fe38a; } .sayi.sv { color: #ffe08a; font-size: 26px; }

#ipucu { position: fixed; z-index: 60; max-width: 260px; padding: 8px 11px; background: #0d0906f7; border: 1px solid var(--kenarAcik); border-radius: 6px;
  font-size: 12.5px; pointer-events: none; box-shadow: 0 6px 20px #000c; }
#ipucu b { display: block; color: var(--altin); font-size: 13.5px; }
#ipucu .iyi { color: #9fe58a; } #ipucu .kotu { color: #ff8f80; } #ipucu .not { color: var(--soluk); font-size: 11.5px; margin-top: 4px; display: block; }
#olum { position: fixed; inset: 0; display: grid; place-content: center; text-align: center; background: #3a0a0a66; pointer-events: none; }
#olum div { font-size: 54px; font-weight: 800; color: #ffb0a0; text-shadow: 0 2px 16px #000; }

/* efsun satırları (ayrıntı paneli; ortak/efsun.js) */
#ayrinti .efsunlar { margin-top: 6px; padding: 6px 8px; border: 1px solid rgba(155, 231, 255, 0.25); border-radius: 6px; background: rgba(20, 30, 40, 0.45); display: flex; flex-direction: column; gap: 2px; }
#ayrinti .efsunlar b { color: #9be7ff; font-weight: 600; }
#ayrinti .efsunlar i { opacity: 0.75; font-style: normal; font-size: 0.85em; margin-left: 4px; }
#ayrinti .efsunlar .bos { color: #9a9488; }

/* ---------- fare imleçleri (Köz için çizildi; istemci/arayuz/imlec, araclar/arayuz_kes.py) ----------
   ok: her yerde · el: tıklanabilen arayüz öğeleri · kılıç ve konuşma balonu: oyun alanında düşmanın / NPC'nin üstünde (ana.js imlecAyarla) */
html, body, #tuval { cursor: url("/arayuz/imlec/ok.png") 2 2, default; }
button:not(:disabled), a, select, summary, label, [role="button"], [role="option"], [role="radio"], [role="tab"], .yuva.dolu, .byuva.dolu, .kzKart, .gYuva, .gSinif, input[type="checkbox"], input[type="range"] { cursor: url("/arayuz/imlec/el.png") 6 2, pointer; }
#tuval.imlec-saldiri { cursor: url("/arayuz/imlec/kilic.png") 2 2, crosshair; }
#tuval.imlec-konus { cursor: url("/arayuz/imlec/konus.png") 2 2, help; }
