/* AslanForum — Sarı-Kırmızı tema */
:root {
  --red: #a90432;
  --red-dark: #7d0224;
  --yellow: #fdb912;
  --yellow-soft: #fff4d4;
  --bg: #f3efe9;
  --card: #ffffff;
  --text: #1f1a1c;
  --muted: #7a6f73;
  --border: #e4dbd3;
  --row-alt: #fbf8f5;
  --radius: 8px;
  --link: #a90432;
  --ok-bg: #e3f6e8; --ok-text: #17682f; --err-bg: #fde4e8; --err-text: #a90432;
  color-scheme: light;
}
/* Gece modu: sistem ayarı ya da üstteki 🌙 düğmesi */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #161214; --card: #221c1f; --text: #f1ebe6; --muted: #a99ca1;
    --border: #3a3034; --row-alt: #1d181a; --yellow-soft: #3a2f12; --link: #ff6b8a;
    --ok-bg: #143322; --ok-text: #7fe0a0; --err-bg: #3d1420; --err-text: #ff8fa6;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #161214; --card: #221c1f; --text: #f1ebe6; --muted: #a99ca1;
  --border: #3a3034; --row-alt: #1d181a; --yellow-soft: #3a2f12; --link: #ff6b8a;
  --ok-bg: #143322; --ok-text: #7fe0a0; --err-bg: #3d1420; --err-text: #ff8fa6;
  color-scheme: dark;
}
* { box-sizing: border-box; }
body { margin: 0; font-family: "Segoe UI", system-ui, -apple-system, Roboto, sans-serif; font-size: 15px;
  background: var(--bg); color: var(--text); line-height: 1.5; }
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 16px; }
.muted { color: var(--muted); font-size: 13px; }
.center { text-align: center; }
h1 { margin: 0 0 4px; font-size: 24px; }

/* Header */
.site-header { background: linear-gradient(135deg, var(--red) 0%, var(--red-dark) 60%, #4a0115 100%); color: #fff;
  border-bottom: 4px solid var(--yellow); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 18px; padding-bottom: 18px; flex-wrap: wrap; }
.logo { display: flex; align-items: center; gap: 12px; color: #fff; font-size: 28px; }
.logo:hover { text-decoration: none; }
.logo strong { color: var(--yellow); }
.logo small { display: block; font-size: 12px; opacity: .85; letter-spacing: .3px; }
.logo-icon { font-size: 40px; filter: drop-shadow(0 2px 4px rgba(0,0,0,.4)); }
.search input { padding: 9px 14px; border-radius: 20px; border: 0; width: 260px; max-width: 100%; }
.navbar { background: rgba(0,0,0,.25); }
.nav-inner { display: flex; justify-content: space-between; flex-wrap: wrap; }
.navbar a { color: #fff; display: inline-block; padding: 10px 14px; font-weight: 600; font-size: 14px; }
.navbar a:hover { background: rgba(255,255,255,.12); text-decoration: none; }
.nav-cta { background: var(--yellow); color: var(--red-dark) !important; }
.nav-admin { color: var(--yellow) !important; }

main.wrap { padding-top: 20px; padding-bottom: 30px; }
.announcement { background: var(--yellow-soft); border-left: 5px solid var(--yellow); padding: 10px 14px; border-radius: var(--radius); margin-bottom: 16px; }
.flash { padding: 10px 14px; border-radius: var(--radius); margin-bottom: 14px; font-weight: 600; }
.flash.success { background: var(--ok-bg); color: var(--ok-text); }
.flash.error { background: var(--err-bg); color: var(--err-text); }

/* Layout */
.layout { display: grid; grid-template-columns: 1fr 300px; gap: 20px; align-items: start; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
@media (max-width: 900px) { .layout, .grid-2 { grid-template-columns: 1fr; } }

.box { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 20px; overflow: hidden; }
.box.narrow { max-width: 440px; margin-left: auto; margin-right: auto; }
.box-head { background: linear-gradient(90deg, var(--red), var(--red-dark)); color: #fff; padding: 10px 16px; font-weight: 700;
  border-bottom: 3px solid var(--yellow); }
.box-body { padding: 16px; }
.box.box-body { padding: 16px; }

.breadcrumb { margin-bottom: 12px; font-size: 14px; color: var(--muted); }
.page-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }

/* Tables */
.forum-table { width: 100%; border-collapse: collapse; }
.forum-table th { text-align: left; font-size: 12px; text-transform: uppercase; color: var(--muted); padding: 8px 12px;
  border-bottom: 1px solid var(--border); background: var(--row-alt); }
.forum-table td { padding: 12px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.forum-table tbody tr:hover { background: var(--row-alt); }
.forum-table tr:last-child td { border-bottom: 0; }
.forum-table .icon { width: 50px; font-size: 26px; text-align: center; }
.forum-table .num { width: 90px; text-align: center; }
.forum-table .last { width: 220px; font-size: 14px; }
.forum-name { font-size: 16px; font-weight: 700; }
.topic-title { font-weight: 600; }
tr.pinned { background: var(--yellow-soft); }
.empty { text-align: center; padding: 30px !important; color: var(--muted); }
@media (max-width: 700px) {
  .forum-table .num, .forum-table th.num, .forum-table .last, .forum-table th.last { display: none; }
}

.tag { font-size: 11px; padding: 2px 6px; border-radius: 4px; font-weight: 700; margin-right: 4px; }
.tag-pin { background: var(--yellow); color: var(--red-dark); }
.tag-lock { background: #555; color: #fff; }

/* Sidebar */
.list { list-style: none; margin: 0; padding: 0; }
.list li { padding: 10px 16px; border-bottom: 1px solid var(--border); }
.list li:last-child { border-bottom: 0; }
.stats { display: flex; justify-content: space-around; text-align: center; }
.stats b { display: block; font-size: 22px; color: var(--red); }
.stats span { font-size: 12px; color: var(--muted); }

/* Badges */
.badge { font-size: 11px; padding: 2px 8px; border-radius: 10px; font-weight: 700; background: #ddd; color: #333; }
.badge.role-admin { background: var(--red); color: var(--yellow); }
.badge.role-moderator { background: var(--yellow); color: var(--red-dark); }
.badge.role-banned { background: #222; color: #fff; }
.role-admin-text { color: var(--red) !important; font-weight: 700; }
.role-moderator-text { color: #c98a00 !important; font-weight: 700; }
.rank { font-size: 12px; color: var(--muted); font-style: italic; }

.avatar { display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; font-weight: 800; flex-shrink: 0;
  background: linear-gradient(135deg, var(--yellow) 50%, var(--red) 50%); color: #fff; text-shadow: 0 1px 3px rgba(0,0,0,.6); }

/* Posts */
.post { display: grid; grid-template-columns: 180px 1fr; background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); margin-bottom: 14px; overflow: hidden; }
.post-user { background: var(--row-alt); border-right: 1px solid var(--border); padding: 16px; text-align: center;
  display: flex; flex-direction: column; align-items: center; gap: 6px; }
.post-username { font-weight: 700; font-size: 16px; }
.post-user dl { display: grid; grid-template-columns: auto auto; gap: 2px 6px; margin: 6px 0 0; text-align: left; }
.post-user dt { font-weight: 600; } .post-user dd { margin: 0; }
.post-main { padding: 12px 18px; display: flex; flex-direction: column; min-width: 0; }
.post-meta { display: flex; justify-content: space-between; font-size: 13px; color: var(--muted); border-bottom: 1px solid var(--border); padding-bottom: 8px; }
.post-body { padding: 14px 0; flex: 1; overflow-wrap: anywhere; }
.post-body img { max-width: 100%; border-radius: 6px; }
blockquote { margin: 8px 0; padding: 10px 14px; background: var(--row-alt); border-left: 4px solid var(--yellow); border-radius: 4px; }
blockquote cite { display: block; font-weight: 700; font-style: normal; font-size: 13px; color: var(--red); margin-bottom: 4px; }
.signature { border-top: 1px dashed var(--border); padding-top: 8px; font-size: 13px; color: var(--muted); }
.edited { font-size: 12px; font-style: italic; }
.post-actions { display: flex; gap: 6px; justify-content: flex-end; flex-wrap: wrap; }
.post-actions form, .mod-tools form { display: inline; }
.mod-tools { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
@media (max-width: 700px) {
  .post { grid-template-columns: 1fr; }
  .post-user { flex-direction: row; flex-wrap: wrap; border-right: 0; border-bottom: 1px solid var(--border); text-align: left; padding: 10px; }
  .post-user .avatar { width: 40px !important; height: 40px !important; font-size: 20px !important; }
  .post-user dl { display: none; }
}

.profile-head { display: flex; gap: 20px; align-items: center; }

/* Forms & buttons */
.form label { display: block; margin-bottom: 12px; font-weight: 600; font-size: 14px; }
.form label.check { font-weight: 400; }
input, textarea, select { font: inherit; color: var(--text); background: var(--card); border: 1px solid var(--border); border-radius: 6px; padding: 8px 10px; }
.form input:not([type=checkbox]), .form textarea, .form select { display: block; width: 100%; margin-top: 4px; }
input:focus, textarea:focus, select:focus { outline: 2px solid var(--yellow); border-color: var(--yellow); }
.btn { display: inline-block; background: var(--red); color: #fff !important; border: 0; padding: 9px 18px; border-radius: 6px;
  font-weight: 700; cursor: pointer; font-size: 14px; text-decoration: none !important; }
.btn:hover { background: var(--red-dark); }
.btn.block { display: block; width: 100%; text-align: center; margin-bottom: 8px; }
.btn-ghost { background: transparent; color: var(--red) !important; border: 1px solid var(--border); }
.btn-ghost:hover { background: var(--yellow-soft); }
.btn-danger { background: #2b2b2b; }
.btn-danger:hover { background: #000; }
.btn-sm { padding: 4px 10px; font-size: 12px; }

.editor { margin-bottom: 12px; }
.editor-bar { display: flex; flex-wrap: wrap; gap: 4px; padding: 6px; background: var(--row-alt); border: 1px solid var(--border); border-bottom: 0; border-radius: 6px 6px 0 0; }
.editor-bar button { background: var(--card); border: 1px solid var(--border); border-radius: 4px; padding: 4px 8px; cursor: pointer; color: var(--text); }
.editor-bar button:hover { background: var(--yellow-soft); }
.editor textarea { border-radius: 0 0 6px 6px; margin-top: 0 !important; width: 100%; display: block; resize: vertical; }

.pagination { display: flex; gap: 4px; margin: 10px 0 16px; flex-wrap: wrap; }
.pagination a, .pagination span { padding: 5px 11px; border: 1px solid var(--border); border-radius: 4px; background: var(--card); font-size: 14px; }
.pagination .current { background: var(--red); color: #fff; border-color: var(--red); }

.site-footer { background: #1a1416; color: #ddd; text-align: center; padding: 20px 0; border-top: 4px solid var(--yellow); font-size: 14px; }
.site-footer p { margin: 4px 0; }

/* ---------- Admin ---------- */
.admin-wrap { display: grid; grid-template-columns: 240px 1fr; min-height: 100vh; }
.admin-side { background: linear-gradient(180deg, var(--red-dark), #3d0111); padding: 20px 0; border-right: 4px solid var(--yellow); }
.admin-side .logo { padding: 0 20px 20px; font-size: 22px; }
.admin-side .logo-icon { font-size: 30px; }
.admin-side nav a { display: block; color: #fff; padding: 11px 20px; font-weight: 600; font-size: 14px; }
.admin-side nav a:hover, .admin-side nav a.active { background: rgba(255,255,255,.12); text-decoration: none; border-left: 4px solid var(--yellow); padding-left: 16px; }
.admin-main { padding: 24px; min-width: 0; }
.admin-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.stat-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; margin-bottom: 20px; }
.stat-card { background: var(--card); border: 1px solid var(--border); border-top: 4px solid var(--red); border-radius: var(--radius); padding: 16px; }
.stat-card b { display: block; font-size: 28px; color: var(--red); }
.stat-card span { color: var(--muted); font-size: 13px; }
.chart { display: flex; align-items: flex-end; gap: 12px; height: 200px; }
.bar-col { flex: 1; display: flex; flex-direction: column; align-items: center; height: 100%; justify-content: flex-end; }
.bar { width: 100%; max-width: 50px; background: linear-gradient(180deg, var(--yellow), var(--red)); border-radius: 4px 4px 0 0; min-height: 3px; position: relative; }
.bar span { position: absolute; top: -20px; left: 0; right: 0; text-align: center; font-size: 12px; font-weight: 700; }
.bar-col small { margin-top: 6px; color: var(--muted); }
.admin-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.admin-row input { color: var(--text); }
.inline-form { display: flex; gap: 6px; align-items: center; }
.admin-table td { padding: 8px; }
.admin-table td form { display: inline; }
.admin-table input:not([type=checkbox]) { width: 100%; }
.w-xs { width: 70px !important; } .w-lg { min-width: 240px; }
.nowrap { white-space: nowrap; }
.toolbar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
.banned-row { opacity: .6; }
@media (max-width: 800px) {
  .admin-wrap { grid-template-columns: 1fr; }
  .admin-side { border-right: 0; border-bottom: 4px solid var(--yellow); padding: 12px 0; }
  .admin-side nav { display: flex; flex-wrap: wrap; }
  .admin-side nav a { padding: 8px 12px; }
  .admin-main { padding: 16px; }
  .box { overflow-x: auto; }
}

/* ---------- v2: bildirim, beğeni, mesaj, maç, anket, şikayet ---------- */
.count { display: inline-block; min-width: 18px; padding: 0 5px; margin-left: 3px; border-radius: 9px; background: var(--yellow);
  color: var(--red-dark); font-size: 11px; font-weight: 800; line-height: 18px; text-align: center; vertical-align: top; }
.nav-user { display: inline-flex !important; align-items: center; gap: 6px; }
img.avatar { object-fit: cover; background: var(--row-alt); border: 2px solid var(--yellow); }

.like-btn { background: var(--card); color: var(--muted) !important; border: 1px solid var(--border); }
.like-btn:hover:not([disabled]) { background: var(--err-bg); }
.like-btn.liked { background: var(--err-bg); color: var(--err-text) !important; border-color: var(--red); }
.like-btn[disabled] { opacity: .6; cursor: default; }
.post-actions form { display: inline; }

.tabs { display: flex; gap: 4px; margin-bottom: 12px; border-bottom: 2px solid var(--border); }
.tabs a { padding: 8px 16px; font-weight: 600; color: var(--muted); border-bottom: 3px solid transparent; margin-bottom: -2px; }
.tabs a.active { color: var(--red); border-bottom-color: var(--red); }
.tabs a:hover { text-decoration: none; color: var(--red); }
tr.unread td { background: var(--yellow-soft); }

.notif-list li.unread { background: var(--yellow-soft); }
.notif { display: flex; align-items: center; gap: 10px; color: var(--text); }
.notif:hover { text-decoration: none; }
.notif-icon { font-size: 18px; width: 22px; text-align: center; }

.match-box .next-match { padding: 14px 16px; text-align: center; background: linear-gradient(180deg, var(--yellow-soft), transparent); }
.match-box .teams { display: flex; justify-content: center; align-items: center; gap: 10px; font-weight: 700; font-size: 16px; margin: 6px 0; }
.match-box .teams .gs { color: var(--red); }
.match-box .teams b { color: var(--muted); font-size: 12px; }
.match-box .when { font-size: 13px; color: var(--muted); }
.countdown { display: flex; justify-content: center; gap: 6px; margin-top: 10px; font-weight: 700; }
.countdown span { background: var(--red); color: #fff; border-radius: 6px; padding: 4px 8px; font-size: 11px; display: flex; flex-direction: column; min-width: 44px; }
.countdown b { font-size: 18px; color: var(--yellow); }
.small-list { border-top: 1px solid var(--border); font-size: 14px; display: flex; flex-direction: column; gap: 4px; }
.result { display: flex; align-items: center; gap: 6px; }
.result .score { margin-left: auto; }
.res { width: 20px; height: 20px; border-radius: 4px; color: #fff; font-size: 11px; font-weight: 800; display: inline-flex; align-items: center; justify-content: center; }
.res-w { background: #1e9e4a; } .res-d { background: #888; } .res-l { background: var(--red); }
.match-form { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; }
.match-form label { display: flex; flex-direction: column; font-size: 13px; font-weight: 600; gap: 4px; }

.poll-row { margin-bottom: 10px; }
.poll-label { display: flex; justify-content: space-between; font-size: 14px; margin-bottom: 3px; }
.poll-bar { height: 12px; background: var(--row-alt); border-radius: 6px; overflow: hidden; border: 1px solid var(--border); }
.poll-bar div { height: 100%; background: linear-gradient(90deg, var(--yellow), var(--red)); }
.poll-row.mine .poll-label { font-weight: 700; color: var(--red); }
.poll-form label { display: block; padding: 6px 0; cursor: pointer; }
.poll-add { margin: 0 0 14px; padding: 10px 14px; border: 1px dashed var(--border); border-radius: 6px; }
.poll-add summary { cursor: pointer; font-weight: 700; margin-bottom: 8px; }

.report-head { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.report .toolbar form { display: inline; }

/* ---------- v3: rütbe, sohbet kutusu, mobil menü, gece modu ---------- */
.rank-badge { display: inline-block; font-size: 11px; font-weight: 700; font-style: normal; padding: 1px 8px; border: 1px solid; border-radius: 10px; white-space: nowrap; }

.header-tools { display: flex; gap: 6px; align-items: center; }
.icon-btn { background: rgba(255,255,255,.15); border: 0; color: #fff; font-size: 18px; width: 38px; height: 38px; border-radius: 50%; cursor: pointer; position: relative; }
.icon-btn:hover { background: rgba(255,255,255,.25); }
.menu-btn { display: none; }
.menu-btn .dot { position: absolute; top: 6px; right: 6px; width: 9px; height: 9px; border-radius: 50%; background: var(--yellow); }

@media (max-width: 760px) {
  .header-inner { padding-top: 10px; padding-bottom: 10px; gap: 10px; }
  .logo { font-size: 22px; }
  .logo-icon { font-size: 30px; }
  .logo small { display: none; }
  .search { order: 3; width: 100%; }
  .search input { width: 100%; }
  .menu-btn { display: inline-block; }
  .navbar { display: none; }
  .navbar.open { display: block; }
  .nav-inner, .nav-inner > div { flex-direction: column; display: flex; width: 100%; }
  .navbar a { padding: 12px 16px; border-bottom: 1px solid rgba(255,255,255,.1); }
  .nav-inner > div + div { border-top: 2px solid var(--yellow); }
  main.wrap { padding-top: 12px; }
  h1 { font-size: 20px; }
  .page-head .btn { width: 100%; text-align: center; }
  .forum-table td { padding: 10px 8px; }
  .forum-table .icon { width: 36px; font-size: 20px; }
  .editor-bar .emojis { width: 100%; }
}

.shoutbox .box-head { display: flex; justify-content: space-between; align-items: center; }
.live-dot { color: #7fe0a0 !important; font-size: 11px; }
.shout-list { height: 260px; overflow-y: auto; padding: 8px 12px; display: flex; flex-direction: column; gap: 8px; }
.shout { display: flex; gap: 8px; align-items: flex-start; font-size: 14px; }
.shout .avatar { flex-shrink: 0; }
.shout-user { font-weight: 700; }
.shout-body { overflow-wrap: anywhere; }
.shout-body img { max-width: 160px; max-height: 120px; border-radius: 4px; }
.shout-del { background: none; border: 0; color: var(--muted); cursor: pointer; font-size: 11px; opacity: 0; }
.shout:hover .shout-del { opacity: 1; }
.shout-form { display: flex; gap: 8px; padding: 10px 12px; border-top: 1px solid var(--border); }
.shout-form input { flex: 1; min-width: 0; }
@media (hover: none) { .shout-del { opacity: 1; } }

#uploadStatus { min-height: 18px; margin-top: 4px; }
.post-body a img { cursor: zoom-in; }
