:root {
  --bg: #0b110e;
  --panel: #121b16;
  --panel-2: #18241d;
  --line: #22322a;
  --text: #e8efe9;
  --muted: #8fa398;
  --gold: #d4af37;
  --gold-soft: rgba(212, 175, 55, .14);
  --green: #3ccf7a;
  --red: #e5534b;
  --blue: #4c8bf5;
  --radius: 14px;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: radial-gradient(1200px 500px at 50% -200px, #17301f 0%, var(--bg) 60%) fixed, var(--bg);
  color: var(--text);
  font: 15px/1.5 Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  min-height: 100vh;
  display: flex; flex-direction: column;
}
a { color: inherit; text-decoration: none; }
a:hover { color: var(--gold); }

/* üst çubuk */
.top {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
  padding: 12px max(16px, calc((100% - 1120px) / 2));
  background: rgba(11, 17, 14, .86); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: baseline; gap: 6px; font-weight: 800; font-size: 20px; letter-spacing: .5px; }
.brand .logo { font-size: 22px; }
.brand small { color: var(--gold); font-weight: 600; font-size: 12px; letter-spacing: 1.5px; text-transform: uppercase; }
nav { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
nav a { padding: 7px 12px; border-radius: 999px; color: var(--muted); font-weight: 600; white-space: nowrap; }
nav a.on { color: var(--bg); background: var(--gold); }
.search { position: relative; margin-left: auto; min-width: 200px; flex: 0 1 260px; }
.search input {
  width: 100%; padding: 9px 14px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--panel); color: var(--text); font: inherit; outline: none;
}
.search input:focus { border-color: var(--gold); }
.hits {
  position: absolute; top: calc(100% + 6px); left: 0; right: 0; max-height: 320px; overflow-y: auto;
  background: var(--panel-2); border: 1px solid var(--line); border-radius: 12px; padding: 4px; box-shadow: 0 12px 30px rgba(0,0,0,.45);
}
.hits a { display: flex; justify-content: space-between; gap: 8px; padding: 8px 10px; border-radius: 8px; }
.hits a:hover, .hits a.sel { background: var(--gold-soft); color: var(--text); }

main { width: 100%; max-width: 1120px; margin: 0 auto; padding: 22px 16px 40px; flex: 1; }
.foot { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; padding: 16px max(16px, calc((100% - 1120px) / 2)); color: var(--muted); font-size: 13px; border-top: 1px solid var(--line); }
.loading, .empty { color: var(--muted); padding: 30px 0; text-align: center; }

/* başlıklar ve ızgara */
h1 { font-size: 26px; margin: 0 0 4px; letter-spacing: -.3px; }
h2 { font-size: 16px; margin: 0 0 12px; display: flex; align-items: center; gap: 8px; }
h2 .sub { color: var(--muted); font-weight: 500; font-size: 13px; margin-left: auto; }
.lead { color: var(--muted); margin: 0 0 20px; }
.grid { display: grid; gap: 16px; grid-template-columns: repeat(12, 1fr); }
.c12 { grid-column: span 12; } .c8 { grid-column: span 8; } .c6 { grid-column: span 6; } .c4 { grid-column: span 4; }
@media (max-width: 900px) { .c8, .c6, .c4 { grid-column: span 12; } }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; min-width: 0; }

/* odalar */
.rooms { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.room { background: linear-gradient(160deg, var(--panel-2), var(--panel)); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.room .name { font-weight: 700; }
.room .count { font-size: 30px; font-weight: 800; }
.room .count small { font-size: 14px; color: var(--muted); font-weight: 500; }
.dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; background: var(--muted); }
.dot.on { background: var(--green); box-shadow: 0 0 0 4px rgba(60,207,122,.15); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 9px 14px; border-radius: 10px; font-weight: 700; background: var(--gold); color: #1a1405; }
.btn:hover { color: #1a1405; filter: brightness(1.08); }
.btn.off { background: var(--panel-2); color: var(--muted); pointer-events: none; }

/* tablolar */
.tw { overflow-x: auto; margin: 0 -4px; }
table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
th, td { padding: 8px 6px; text-align: left; white-space: nowrap; }
th { color: var(--muted); font-weight: 600; font-size: 12px; text-transform: uppercase; letter-spacing: .6px; border-bottom: 1px solid var(--line); }
td { border-bottom: 1px solid rgba(34,50,42,.6); }
tr:last-child td { border-bottom: 0; }
td.n, th.n { text-align: right; }
td.pos { width: 42px; color: var(--muted); font-weight: 700; }
tr.me td { background: var(--gold-soft); }
.medal { font-size: 16px; }

/* küçük öğeler */
.pill { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 999px; font-size: 12px; font-weight: 700; background: var(--panel-2); color: var(--muted); border: 1px solid var(--line); }
.pill.gold { color: var(--gold); border-color: rgba(212,175,55,.4); background: var(--gold-soft); }
.pill.vip { color: #f6d365; }
.tag { color: var(--gold); font-weight: 700; }
.win { color: var(--green); font-weight: 700; } .loss { color: var(--red); font-weight: 700; }
.muted { color: var(--muted); }
.feed { display: flex; flex-direction: column; }
.match { display: grid; grid-template-columns: 1fr auto 1fr auto; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid rgba(34,50,42,.6); }
.match:last-child { border-bottom: 0; }
.match .l { text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.match .r { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); }
.match .score { font-weight: 800; background: var(--panel-2); border-radius: 8px; padding: 2px 10px; min-width: 58px; text-align: center; }
.match .t { color: var(--muted); font-size: 12px; min-width: 64px; text-align: right; }
.tabs { display: flex; gap: 6px; margin-bottom: 14px; flex-wrap: wrap; }
.tabs button { font: inherit; font-weight: 600; padding: 7px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--panel); color: var(--muted); cursor: pointer; }
.tabs button.on { background: var(--gold); color: #1a1405; border-color: var(--gold); }

/* profil */
.hero { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; margin-bottom: 18px; }
.avatar { width: 64px; height: 64px; border-radius: 18px; display: grid; place-items: center; font-size: 28px; font-weight: 800; background: linear-gradient(135deg, #2a4a36, #13261b); border: 1px solid var(--line); }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; }
.stat { background: var(--panel-2); border-radius: 12px; padding: 12px; }
.stat b { display: block; font-size: 22px; }
.stat span { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .5px; }
.bar { height: 8px; border-radius: 99px; background: var(--panel-2); overflow: hidden; margin-top: 6px; }
.bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--gold), #f6d365); }
.achs { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.ach { display: flex; gap: 10px; align-items: center; background: var(--panel-2); border-radius: 12px; padding: 10px; }
.ach .i { font-size: 22px; }
.ach.lock { opacity: .38; filter: grayscale(1); }
.ach small { display: block; color: var(--muted); font-size: 11px; }
.big-record { display: flex; align-items: center; gap: 14px; }
.big-record .v { font-size: 30px; font-weight: 800; color: var(--gold); }

/* klan sohbeti */
.chat { display: flex; flex-direction: column; height: min(70vh, 640px); }
.chat .log { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; padding: 4px 2px 10px; }
.chat .msg { background: var(--panel-2); border-radius: 12px; padding: 8px 12px; max-width: 85%; align-self: flex-start; word-wrap: break-word; }
.chat .msg.mine { align-self: flex-end; background: rgba(212,175,55,.16); }
.chat .msg .h { font-size: 12px; color: var(--muted); display: flex; gap: 8px; align-items: center; }
.chat .msg .h b { color: var(--text); }
.chat .msg .x { margin-left: auto; cursor: pointer; color: var(--red); background: none; border: 0; font: inherit; }
.chat form { display: flex; gap: 8px; border-top: 1px solid var(--line); padding-top: 10px; }
.chat input, .code input, .chat select { flex: 1; padding: 11px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--panel-2); color: var(--text); font: inherit; outline: none; }
.chat input:focus, .code input:focus { border-color: var(--gold); }
.chat button.btn, .code button.btn { border: 0; cursor: pointer; font: inherit; font-weight: 700; }
.code { display: flex; gap: 8px; max-width: 360px; margin-top: 12px; }
.code input { letter-spacing: 4px; font-size: 20px; text-align: center; }
.note { color: var(--muted); font-size: 13px; margin-top: 8px; }
.note.err { color: var(--red); }
.steps { margin: 0; padding-left: 20px; line-height: 1.9; }
.steps b { color: var(--gold); }

/* yenilikler */
.news-row { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; border-bottom: 1px solid rgba(34,50,42,.6); }
.news-row:last-child { border-bottom: 0; }
.news-row .i { font-size: 20px; line-height: 1.3; }
.news-row small { display: block; color: var(--muted); font-size: 13px; }
.timeline .tday + .tday { margin-top: 14px; }
h3 { font-size: 14px; margin: 14px 0 8px; color: var(--gold); letter-spacing: .3px; }
.timeline h3 { margin-top: 0; }

/* profil araçları, karşılaştırma */
.hero-tools { margin-left: auto; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.hero-tools .btn { border: 0; cursor: pointer; font: inherit; font-weight: 700; }
.pick { margin-left: 0; min-width: 220px; flex: 0 1 260px; }
.spark { width: 100%; height: 70px; margin-bottom: 6px; }
.five { white-space: nowrap; letter-spacing: 1px; }
.h2h { display: grid; grid-template-columns: 1fr auto 1fr; gap: 12px; align-items: center; }
.h2h .side { font-size: 20px; font-weight: 800; min-width: 0; overflow-wrap: anywhere; }
.h2h .side.r { text-align: right; }
.h2h .mid { text-align: center; }
.h2h .big { font-size: 40px; font-weight: 800; line-height: 1.1; }
table.cmp td.lbl { text-align: center; color: var(--muted); font-size: 13px; }
table.cmp td.n.l { text-align: left; }
table.cmp td.better { color: var(--green); font-weight: 800; }
@media (max-width: 600px) { .h2h { grid-template-columns: 1fr; text-align: center; } .h2h .side.r { text-align: center; } .hero-tools { margin-left: 0; width: 100%; } .pick { flex: 1 1 auto; } }

/* aktif saatler */
.heat { display: grid; grid-template-columns: 34px repeat(24, minmax(0, 1fr)); gap: 3px; font-size: 11px; color: var(--muted); }
.heat > span { text-align: center; }
.heat .dl { text-align: left; align-self: center; }
.heat i { aspect-ratio: 1; border-radius: 3px; background: rgba(212,175,55,var(--a)); outline: 1px solid rgba(34,50,42,.8); }

/* rehber */
.rules { margin: 0; padding-left: 18px; line-height: 1.6; }
.rules li + li { margin-top: 6px; }
.filter { width: 100%; padding: 10px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--panel-2); color: var(--text); font: inherit; outline: none; margin-bottom: 6px; }
.filter:focus { border-color: var(--gold); }
.cmds { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 6px 16px; }
.cmd { display: flex; gap: 10px; align-items: baseline; padding: 6px 0; border-bottom: 1px solid rgba(34,50,42,.6); min-width: 0; }
.cmd code, .item code { color: var(--gold); font-weight: 700; white-space: nowrap; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; }
.cmd span { color: var(--text); font-size: 14px; overflow-wrap: anywhere; }

/* sezonlar */
a.season:hover { border-color: var(--gold); color: inherit; }

/* market */
.items { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.item { display: flex; gap: 10px; align-items: flex-start; background: var(--panel-2); border-radius: 12px; padding: 10px 12px; min-width: 0; }
.item .i { font-size: 22px; }
.item > div { flex: 1; min-width: 0; }
.item small { display: block; color: var(--muted); font-size: 12px; }
.item .price { font-weight: 800; color: var(--gold); white-space: nowrap; }
.fxwrap { display: grid; grid-template-columns: minmax(0, 480px) 1fr; gap: 16px; align-items: start; }
.fxview { position: sticky; top: 70px; }
.fxview canvas { width: 100%; height: auto; border-radius: 12px; border: 1px solid var(--line); display: block; background: #1f3a28; }
.pack h3 { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 4px; }
.pack + .pack { margin-top: 10px; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chips button { font: inherit; font-size: 13px; font-weight: 600; padding: 5px 10px; border-radius: 999px; border: 1px solid var(--line); background: var(--panel-2); color: var(--text); cursor: pointer; }
.chips button.on, .chips button:hover { border-color: var(--gold); color: var(--gold); }
.badges { display: flex; gap: 8px; flex-wrap: wrap; font-size: 24px; }
.badges span { display: inline-flex; flex-direction: column; align-items: center; background: var(--panel-2); border-radius: 10px; padding: 4px 8px; }
.badges small { font-size: 11px; color: var(--muted); }
@media (max-width: 900px) { .fxwrap { grid-template-columns: 1fr; } .fxview { position: static; } }
table.cmp { table-layout: fixed; }
table.cmp th, table.cmp td { white-space: normal; overflow-wrap: anywhere; }
table.cmp th:nth-child(2), table.cmp td.lbl { width: 34%; }

/* canlı skor (oda kartında) */
.live:empty { display: none; }
.live { display: flex; flex-direction: column; gap: 6px; padding: 10px; border-radius: 10px; background: rgba(0,0,0,.22); border: 1px solid var(--line); }
.live .pill { align-self: flex-start; }
.live-pill { color: var(--green); border-color: rgba(60,207,122,.4); }
.live .ls { display: grid; grid-template-columns: 1fr auto 1fr; gap: 8px; align-items: center; font-weight: 700; }
.live .ls .rd { text-align: right; color: #ff8a80; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.live .ls .bl { color: #82b1ff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.live .ls b { font-size: 20px; background: var(--panel-2); border-radius: 8px; padding: 0 10px; }
.live .lt { color: var(--muted); font-size: 13px; }

/* kurucu (sahip) profili: tek taç, altın isim */
.hero.founder .avatar { border: 2px solid var(--gold); box-shadow: 0 0 0 4px rgba(212,175,55,.18), 0 0 24px rgba(212,175,55,.25); background: linear-gradient(135deg, #4a3b12, #1f1906); color: #ffd700; }
.hero.founder h1 .nm { background: linear-gradient(90deg, #f6d365, #ffd700 45%, #fff3b0 60%, #d4af37); -webkit-background-clip: text; background-clip: text; color: transparent; }
.founder-pill { color: #1a1405; background: linear-gradient(90deg, #f6d365, #d4af37); border-color: #d4af37; }
