:root {
  --bg: #f4f4f0;
  --ink: #2a2a28;
  --muted: #7a7a73;
  --accent: #b5502f;
  --card-bg: #fffdf9;
  --border: #e4e2da;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  background: var(--bg);
  background-image: radial-gradient(circle at 15% 8%, rgba(181, 80, 47, 0.05), transparent 40%),
                     radial-gradient(circle at 85% 92%, rgba(181, 80, 47, 0.04), transparent 40%);
  background-attachment: fixed;
  color: var(--ink);
  line-height: 1.6;
  padding-bottom: 64px; /* alt menü için yer bırak */
}

a { color: inherit; }

/* ---------- Üst bar ---------- */

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  border-bottom: 1px solid var(--border);
  background: var(--card-bg);
  position: sticky;
  top: 0;
  z-index: 10;
}

.brand {
  font-size: 1.3rem;
  font-weight: bold;
  text-decoration: none;
  letter-spacing: 0.02em;
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 0.9rem;
}

.top-nav a { color: var(--muted); text-decoration: none; }
.top-nav a:hover { color: var(--accent); }
.who { color: var(--ink); font-weight: bold; }
.new-post-link {
  background: var(--accent); color: #fff !important; padding: 5px 12px;
  border-radius: 16px; font-size: 0.85rem;
}
.new-post-link:hover { opacity: 0.9; }

main {
  max-width: 680px;
  margin: 0 auto;
  padding: 32px 16px 40px;
}

/* ---------- Alt menü (bottom nav) — koyu lacivert, çizgi ikonlu ---------- */

.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-around;
  align-items: center;
  background: #001932;
  height: 56px;
  z-index: 999;
  box-shadow: 0 -1px 6px rgba(0, 0, 0, 0.25);
}

.bottom-nav a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  position: relative;
  border-radius: 10px;
  transition: background 0.15s;
}

.bottom-nav a svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: #ffffff;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: 0.75;
  transition: opacity 0.15s;
}

.bottom-nav a.active svg { opacity: 1; }
.bottom-nav a.active { background: rgba(255, 255, 255, 0.12); }
.bottom-nav a:hover svg { opacity: 1; }

.bottom-nav .badge {
  position: absolute;
  top: 2px;
  right: 2px;
}

.icon--with-badge { position: relative; display: inline-block; }
.badge {
  position: absolute; top: -6px; right: -10px;
  background: var(--accent); color: #fff; font-size: 0.6rem;
  min-width: 16px; height: 16px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  padding: 0 3px; line-height: 1;
}

/* ---------- Genel ---------- */

.hero { text-align: center; margin-bottom: 32px; }
.hero--small { margin-bottom: 24px; }
.hero h1 {
  font-size: 2.2rem; margin-bottom: 6px;
  position: relative; display: inline-block;
}
.hero h1::after {
  content: "";
  display: block;
  width: 40px; height: 3px;
  background: var(--accent);
  margin: 10px auto 0;
  border-radius: 2px;
}
.hero p { color: var(--muted); font-style: italic; }

.flash {
  background: #fbeee6;
  border: 1px solid #e9c8b3;
  border-radius: 6px;
  padding: 10px 16px;
  margin-bottom: 20px;
  font-size: 0.95rem;
}
.flash p { margin: 4px 0; }

.empty {
  color: var(--muted); text-align: center; font-style: italic; margin-top: 32px;
  padding: 24px; background: var(--card-bg); border: 1px dashed var(--border); border-radius: 12px;
}

.tabs {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 24px;
}

.tabs a {
  text-decoration: none;
  color: var(--muted);
  padding: 6px 16px;
  border-radius: 20px;
  border: 1px solid var(--border);
  font-size: 0.9rem;
}

.tabs a.tab-active { background: var(--accent); color: #fff; border-color: var(--accent); }

/* ---------- Yazı kartı ---------- */

.post-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 22px 24px;
  margin-bottom: 18px;
  scroll-margin-top: 70px;
  box-shadow: 0 2px 10px rgba(42, 42, 40, 0.04);
  transition: box-shadow 0.2s;
}
.post-card:hover { box-shadow: 0 4px 16px rgba(42, 42, 40, 0.08); }

.post-card h2 { margin: 0 0 6px; font-size: 1.25rem; }
.post-card h2 a { text-decoration: none; }
.post-card h2 a:hover { color: var(--accent); }

.meta { color: var(--muted); font-size: 0.82rem; margin: 0 0 10px; }
.post-card-jump { margin: 0 0 4px; }
.post-card-jump a { color: var(--muted); text-decoration: none; font-size: 0.9rem; }
.post-card-jump a:hover { color: var(--accent); }
.content { margin: 0 0 12px; white-space: pre-wrap; }

.reblog-tag, .answer-tag {
  font-size: 0.8rem;
  color: var(--accent);
  margin: 0 0 6px;
  font-style: italic;
}

.question-quote {
  background: var(--bg);
  border-left: 3px solid var(--accent);
  padding: 8px 12px;
  margin: 0 0 10px;
  font-style: italic;
  border-radius: 4px;
}

.embed {
  margin: 12px 0;
}
.embed iframe {
  width: 100%;
  border-radius: 8px;
}

.post-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
}

.inline-form { display: inline; }

.action-btn {
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--muted);
  border-radius: 20px;
  padding: 5px 12px;
  font-size: 0.82rem;
  cursor: pointer;
  text-decoration: none;
  font-family: inherit;
}
.action-btn:hover { border-color: var(--accent); color: var(--accent); }
.action-btn--active { background: var(--accent); color: #fff; border-color: var(--accent); }
.action-btn--static { padding: 5px 12px; font-size: 0.82rem; color: var(--muted); }
.action-btn--danger:hover { border-color: #b5302f; color: #b5302f; }
.action-btn--wide { display: block; width: 100%; text-align: center; margin: 16px 0; padding: 10px; }
.action-btn--primary { background: var(--accent); color: #fff; border-color: var(--accent); font-weight: bold; }
.action-btn--primary:hover { opacity: 0.9; color: #fff; }

.comments-block { margin-top: 10px; }

.comment-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 10px; }
.comment-item {
  display: flex; justify-content: space-between; align-items: flex-start; gap: 8px;
  background: var(--bg); border-radius: 8px; padding: 8px 12px;
}
.comment-text { margin: 0; font-size: 0.9rem; flex: 1; }
.comment-author { color: var(--accent); text-decoration: none; font-weight: bold; margin-right: 4px; }
.reply-btn {
  background: none; border: none; color: var(--muted); font-size: 0.75rem;
  cursor: pointer; font-family: inherit; white-space: nowrap; padding: 2px 4px;
}
.reply-btn:hover { color: var(--accent); }

.comments-block--preview { margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--border); }
.comment-text--preview { font-size: 0.85rem; color: var(--muted); margin: 4px 0; }
.comment-more { font-size: 0.78rem; color: var(--muted); font-style: italic; margin: 4px 0 0; }

.comment-form { display: flex; gap: 8px; }
.comment-form input {
  flex: 1;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 20px;
  font-family: inherit;
  background: var(--bg);
  transition: box-shadow 0.3s, border-color 0.3s;
}
.comment-input--highlight {
  border-color: var(--accent) !important;
  box-shadow: 0 0 0 3px rgba(181, 80, 47, 0.25);
}
.comment-form button {
  border: none;
  background: var(--accent);
  color: #fff;
  border-radius: 20px;
  padding: 8px 16px;
  font-family: inherit;
  cursor: pointer;
}

/* ---------- Blog sayfası ---------- */

.blog-page {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--border);
  padding-bottom: 28px;
  margin-bottom: 20px;
  box-shadow: 0 4px 20px rgba(42, 42, 40, 0.06);
}

.cover-banner {
  height: 150px;
  background-size: cover;
  background-position: center;
  background-color: #ddd8cc;
}
.cover-banner--empty { background: linear-gradient(135deg, #ddd8cc, #cfc9ba); }

.blog-header { text-align: center; margin-top: -42px; padding: 0 20px; margin-bottom: 28px; }
.blog-header h1 { margin-bottom: 2px; }

/* Kullanıcı koyu bir arkaplan rengi seçtiyse, blog-header içindeki tüm metin/buton
   renkleri (h1, bio, takip sayacı, butonlar) otomatik olarak açık tonlara döner —
   CSS değişkenlerini bu kapsamda yeniden tanımlayarak tek yerden yönetiyoruz. */
.blog-page--dark-bg .blog-header {
  --ink: #f5f3ee;
  --muted: #c9c6bd;
  --border: rgba(255, 255, 255, 0.25);
  --card-bg: rgba(255, 255, 255, 0.08);
  color: var(--ink);
}
.blog-page--dark-bg .blog-header .action-btn:hover { background: rgba(255, 255, 255, 0.12); }

.avatar {
  width: 84px; height: 84px; border-radius: 50%;
  object-fit: cover; border: 4px solid var(--card-bg);
  display: block; margin: 0 auto 10px; background: var(--card-bg);
}
.avatar--placeholder {
  display: flex; align-items: center; justify-content: center;
  font-size: 2rem; font-weight: bold; color: var(--muted);
}
.avatar--small { width: 48px; height: 48px; font-size: 1.2rem; margin: 0 auto 6px; }
.avatar--tiny { width: 32px; height: 32px; font-size: 0.9rem; margin: 0; }

.follow-counts { color: var(--muted); font-size: 0.85rem; margin: 0 0 8px; }
.follow-counts a { color: var(--muted); text-decoration: none; font-weight: bold; }
.follow-counts a:hover { color: var(--accent); text-decoration: underline; }

.follow-list { display: flex; flex-direction: column; gap: 8px; }
.follow-list-item {
  display: flex; gap: 12px; align-items: center; text-decoration: none; color: var(--ink);
  padding: 12px; border-radius: 10px; border: 1px solid var(--border); background: var(--card-bg);
}
.follow-list-item:hover { border-color: var(--accent); }
.bio { color: var(--muted); }
.empty-bio { font-style: italic; }

.edit-link {
  display: inline-block; margin-top: 8px; font-size: 0.85rem;
  color: var(--accent); text-decoration: none; border: 1px solid var(--border);
  padding: 4px 12px; border-radius: 20px;
}
.edit-link:hover { background: var(--bg); }

.blog-actions { display: flex; justify-content: center; gap: 8px; margin-top: 10px; flex-wrap: wrap; }

.action-btn--disabled {
  background: var(--bg); border: 1px solid var(--border); color: var(--muted);
  border-radius: 20px; padding: 5px 12px; font-size: 0.82rem; cursor: not-allowed;
}

/* ---------- Blog dişli çark menüsü ---------- */

.blog-settings-menu { position: absolute; top: 12px; right: 12px; z-index: 5; }
.gear-btn {
  width: 36px; height: 36px; border-radius: 50%; border: none;
  background: rgba(255,255,255,0.85); display: flex; align-items: center; justify-content: center;
  cursor: pointer; box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.gear-btn svg { width: 20px; height: 20px; fill: none; stroke: var(--ink); stroke-width: 1.8; }
.gear-btn:hover svg { stroke: var(--accent); }

.gear-dropdown {
  display: none; position: absolute; top: 42px; right: 0; min-width: 180px;
  background: var(--card-bg); border: 1px solid var(--border); border-radius: 10px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.15); overflow: hidden; flex-direction: column;
}
.gear-dropdown--open { display: flex; }
.gear-dropdown a {
  padding: 10px 14px; text-decoration: none; color: var(--ink); font-size: 0.9rem;
}
.gear-dropdown a:hover { background: var(--bg); }

/* ---------- Yüzen "yeni yazı" butonu (FAB) ---------- */

.fab {
  position: fixed; bottom: 76px; right: 20px; width: 52px; height: 52px;
  border-radius: 50%; background: var(--accent); display: flex; align-items: center;
  justify-content: center; box-shadow: 0 4px 14px rgba(181, 80, 47, 0.4); z-index: 30;
}
.fab svg { width: 24px; height: 24px; fill: none; stroke: #fff; stroke-width: 2.2; stroke-linecap: round; }
.fab:hover { opacity: 0.92; }

/* ---------- Etkileşim/İletiler sekmeleri ---------- */

.activity-tabs { margin-bottom: 20px; }
.tab-count { font-weight: bold; opacity: 0.85; }
.tabs a.tab-active .tab-count { color: #fff; }

.ask-form {
  margin-top: 16px; display: flex; flex-direction: column; gap: 8px;
  max-width: 420px; margin-left: auto; margin-right: auto;
}
.ask-form-label { margin: 0; font-weight: bold; color: var(--ink); text-align: center; }
.ask-form textarea {
  font-family: inherit; padding: 10px; border: 1px solid var(--border);
  border-radius: 8px; background: var(--card-bg); resize: vertical;
}
.ask-form button {
  align-self: center; border: none; background: var(--accent); color: #fff;
  border-radius: 20px; padding: 8px 20px; cursor: pointer; font-family: inherit;
}

/* ---------- Formlar (kayıt/giriş/profil) ---------- */

.form-page {
  background: var(--card-bg); border: 1px solid var(--border); border-radius: 10px;
  padding: 32px; max-width: 420px; margin: 0 auto;
  box-shadow: 0 4px 20px rgba(42, 42, 40, 0.06);
}
.form-page--wide { max-width: 560px; }
.form-page h1 { margin-top: 0; font-size: 1.5rem; }
.form-page form { display: flex; flex-direction: column; gap: 16px; }
.form-page label { display: flex; flex-direction: column; gap: 6px; font-size: 0.9rem; color: var(--muted); }
.optional-tag { font-weight: normal; opacity: 0.55; font-size: 0.8rem; }
.form-page input, .form-page textarea {
  font-family: inherit; font-size: 1rem; padding: 10px 12px;
  border: 1px solid var(--border); border-radius: 6px; background: var(--bg); color: var(--ink);
}
.form-page button {
  background: var(--accent); color: #fff; border: none; border-radius: 6px;
  padding: 12px; font-size: 1rem; cursor: pointer; font-family: inherit;
}
.form-page button:hover { opacity: 0.9; }
.hint { text-align: center; color: var(--muted); font-size: 0.9rem; margin-top: 16px; }
.hint a { color: var(--accent); }

.import-intro { color: var(--muted); font-size: 0.9rem; margin: -8px 0 4px; }
.import-notes {
  margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--border);
  font-size: 0.85rem; color: var(--muted);
}
.import-notes h3 { font-size: 0.9rem; color: var(--ink); margin-bottom: 8px; }
.import-notes ul { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; }
.form-page select {
  font-family: inherit; font-size: 1rem; padding: 10px 12px;
  border: 1px solid var(--border); border-radius: 6px; background: var(--bg); color: var(--ink);
}

.preview-avatar { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; margin-bottom: 6px; }
.preview-cover { width: 100%; height: 90px; object-fit: cover; border-radius: 6px; margin-bottom: 6px; }

.color-picker-block { display: flex; flex-direction: column; gap: 10px; border-top: 1px solid var(--border); padding-top: 18px; }

.settings-block {
  display: flex; flex-direction: column; gap: 14px;
  border-top: 1px solid var(--border); padding-top: 18px;
}
.settings-block select {
  font-family: inherit; font-size: 1rem; padding: 10px 12px;
  border: 1px solid var(--border); border-radius: 6px; background: var(--bg); color: var(--ink);
}
.checkbox-label {
  flex-direction: row !important; align-items: center; gap: 8px !important;
}
.checkbox-label input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--accent); }
.label-text { font-size: 0.9rem; color: var(--muted); }
.palette { display: flex; flex-wrap: wrap; gap: 8px; }
.swatch { width: 32px; height: 32px; border-radius: 50%; border: 2px solid var(--border); cursor: pointer; padding: 0; }
.swatch:hover { border-color: var(--accent); }
.hex-input input { font-family: monospace; }
.color-preview { height: 36px; border-radius: 6px; border: 1px solid var(--border); }

/* ---------- Keşfet ---------- */

.search-form { display: flex; gap: 8px; max-width: 420px; margin: 16px auto 0; }
.search-form input {
  flex: 1; padding: 10px 12px; border: 1px solid var(--border); border-radius: 20px;
  font-family: inherit; background: var(--card-bg);
}
.search-form button {
  border: none; background: var(--accent); color: #fff; border-radius: 20px;
  padding: 10px 18px; cursor: pointer; font-family: inherit;
}

.discover-block { margin-bottom: 32px; }
.discover-block h2 { font-size: 1.1rem; color: var(--muted); margin-bottom: 12px; }

.tag-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-chip {
  text-decoration: none; background: var(--card-bg); border: 1px solid var(--border);
  color: var(--accent); border-radius: 20px; padding: 6px 14px; font-size: 0.85rem;
}
.tag-chip:hover { background: var(--accent); color: #fff; }

.blog-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(90px, 1fr)); gap: 14px; }
.blog-tile {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  text-decoration: none; color: var(--ink); font-size: 0.82rem; text-align: center;
}
.blog-tile img { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; }

/* ---------- Oyunlar ---------- */

.game-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 14px; }
.game-card {
  background: var(--card-bg); border: 1px solid var(--border); border-radius: 12px;
  padding: 20px 14px; text-align: center; text-decoration: none; color: var(--ink);
}
.game-card:hover { border-color: var(--accent); }
.game-card--soon { opacity: 0.55; }
.game-icon { font-size: 2rem; display: block; margin-bottom: 8px; }
.game-card h3 { margin: 0 0 4px; font-size: 1rem; }
.game-card p { margin: 0; font-size: 0.78rem; color: var(--muted); }
.game-live-count { min-height: 1.1em; }

.tictactoe-board {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px;
  max-width: 300px; margin: 0 auto 16px;
}
.ttt-cell {
  aspect-ratio: 1; font-size: 2rem; background: var(--card-bg);
  border: 1px solid var(--border); border-radius: 8px; cursor: pointer;
  font-family: inherit;
}
.ttt-cell:hover { background: var(--bg); }
.result-message { text-align: center; font-weight: bold; min-height: 1.5em; }

/* ---------- Chat / DM ---------- */

.chat-box {
  background: var(--card-bg); border: 1px solid var(--border); border-radius: 10px;
  padding: 16px; height: 55vh; overflow-y: auto; display: flex; flex-direction: column; gap: 12px;
  margin-bottom: 12px;
  box-shadow: 0 4px 20px rgba(42, 42, 40, 0.06);
}

.chat-msg { display: flex; gap: 8px; align-items: flex-start; }
.chat-msg--mine { flex-direction: row-reverse; }
.chat-msg--mine .chat-bubble { background: var(--accent); color: #fff; }
.chat-msg--mine .chat-time { color: rgba(255,255,255,0.75); }

.chat-avatar { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }

.chat-bubble {
  background: var(--bg); border-radius: 12px; padding: 8px 12px; max-width: 75%;
}
.chat-sender { margin: 0 0 2px; font-size: 0.78rem; color: var(--muted); }
.chat-text { margin: 0; white-space: pre-wrap; }
.chat-text--deleted { font-style: italic; opacity: 0.6; }
.chat-time { font-size: 0.7rem; color: var(--muted); display: block; margin-top: 4px; }
.chat-edited-tag { font-style: italic; opacity: 0.8; }
.chat-read-status { margin-left: 4px; }
.chat-media-img { max-width: 220px; border-radius: 8px; display: block; margin-top: 6px; }
.chat-bubble audio { margin-top: 6px; max-width: 220px; }

.chat-msg-actions { display: flex; gap: 8px; margin-top: 4px; }
.chat-msg-actions button {
  background: none; border: none; font-size: 0.7rem; cursor: pointer;
  color: rgba(255,255,255,0.75); padding: 0; text-decoration: underline;
}
.chat-msg:not(.chat-msg--mine) .chat-msg-actions button { color: var(--muted); }

.thread-time { font-size: 0.78rem; opacity: 0.8; }
.follow-counts--static { cursor: default; }

.chat-form { display: flex; gap: 6px; align-items: center; }
.chat-form input[type="text"] {
  flex: 1; padding: 10px 14px; border: 1px solid var(--border); border-radius: 20px;
  font-family: inherit; background: var(--card-bg);
}
.chat-upload-btn {
  cursor: pointer; background: var(--card-bg); border: 1px solid var(--border);
  border-radius: 50%; width: 38px; height: 38px; display: flex; align-items: center;
  justify-content: center; font-size: 1.1rem;
}
.chat-send-btn {
  border: none; background: var(--accent); color: #fff; border-radius: 20px;
  padding: 10px 16px; cursor: pointer; font-family: inherit;
}
.chat-record-status { text-align: center; font-size: 0.8rem; color: var(--muted); min-height: 1.2em; }

.chat-blocked-notice { display: flex; gap: 6px; align-items: center; }
.chat-blocked-input {
  flex: 1; padding: 10px 14px; border: 1px solid var(--border); border-radius: 20px;
  font-family: inherit; background: var(--bg); color: var(--muted); cursor: not-allowed;
  font-size: 0.85rem;
}
.chat-blocked-notice .chat-send-btn { opacity: 0.5; cursor: not-allowed; }

/* ---------- İletiler listesi ---------- */

.thread-list { display: flex; flex-direction: column; gap: 4px; }
.thread-item {
  display: flex; gap: 8px; align-items: center;
  padding: 8px; border-radius: 10px; border: 1px solid var(--border); background: var(--card-bg);
}
.thread-item:hover { border-color: var(--accent); }
.thread-item-link {
  display: flex; gap: 12px; align-items: center; text-decoration: none; color: var(--ink);
  flex: 1; padding: 4px; min-width: 0;
}
.thread-delete-btn { padding: 6px 10px; flex-shrink: 0; }
.thread-name { margin: 0; font-weight: bold; }
.thread-preview { margin: 2px 0 0; font-size: 0.85rem; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- Etkileşimler ---------- */

.question-card {
  background: var(--card-bg); border: 1px solid var(--border); border-radius: 10px;
  padding: 16px; margin-bottom: 12px;
}
.answer-form { display: flex; flex-direction: column; gap: 8px; }
.answer-form textarea {
  font-family: inherit; padding: 10px; border: 1px solid var(--border); border-radius: 8px; resize: vertical;
}
.answer-form button {
  align-self: flex-start; border: none; background: var(--accent); color: #fff;
  border-radius: 20px; padding: 8px 16px; cursor: pointer; font-family: inherit;
}
.question-card-actions { display: flex; }
.question-card form.inline-form { margin-top: 8px; display: block; }

.event-list { display: flex; flex-direction: column; gap: 10px; }
.event-item {
  background: var(--card-bg); border: 1px solid var(--border); border-radius: 8px; padding: 10px 14px;
}
.event-item p { margin: 0; }
.event-item .meta { margin-top: 4px; }
.event-item--follow { display: flex; justify-content: space-between; align-items: center; gap: 10px; }

/* ---------- Admin paneli ---------- */

.admin-stats-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 12px; margin-bottom: 24px;
}
.admin-stat-card {
  background: var(--card-bg); border: 1px solid var(--border); border-radius: 10px;
  padding: 18px; text-align: center;
}
.admin-stat-card--alert { border-color: var(--accent); background: #fbeee6; }
.admin-stat-number { display: block; font-size: 1.8rem; font-weight: bold; color: var(--ink); }
.admin-stat-label { font-size: 0.8rem; color: var(--muted); }

.admin-nav-links { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; }

.admin-table-wrap { overflow-x: auto; }
.admin-table { width: 100%; border-collapse: collapse; background: var(--card-bg); border-radius: 10px; overflow: hidden; }
.admin-table th, .admin-table td {
  padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--border); font-size: 0.85rem;
}
.admin-table th { background: var(--bg); color: var(--muted); font-weight: bold; }
.admin-row--banned { opacity: 0.6; }
.admin-actions-cell { display: flex; gap: 6px; flex-wrap: wrap; }
.admin-ua-cell { color: var(--muted); font-size: 0.75rem; }

.admin-badge {
  background: var(--accent); color: #fff; font-size: 0.65rem; padding: 2px 6px;
  border-radius: 10px; margin-left: 6px;
}
.admin-status { font-size: 0.78rem; padding: 2px 8px; border-radius: 10px; }
.admin-status--active { background: #e8f0e6; color: #3a6b34; }
.admin-status--banned { background: #fbe3e3; color: #a13a3a; }

.admin-post-list { display: flex; flex-direction: column; gap: 12px; }
.admin-post-item, .admin-report-item {
  background: var(--card-bg); border: 1px solid var(--border); border-radius: 10px; padding: 16px;
  display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; flex-wrap: wrap;
}
.admin-post-title { margin: 0 0 4px; }
.admin-post-excerpt { margin: 0; color: var(--muted); font-size: 0.85rem; }

.admin-report-item { flex-direction: column; align-items: stretch; }
.admin-reported-post {
  background: var(--bg); border-radius: 8px; padding: 10px 14px; margin: 8px 0;
}
.admin-report-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.geo-result { font-size: 0.8rem; color: var(--muted); }

/* ---------- Gömülü oyun/chat widget'ları ---------- */
.external-game-embed {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
  overflow-x: auto;
  box-shadow: 0 4px 20px rgba(42, 42, 40, 0.06);
}
.external-chat-embed { padding: 12px; }

/* ---------- Mobil uyum ---------- */
@media (max-width: 600px) {
  main { padding: 20px 12px 32px; }

  .topbar { padding: 12px 16px; }
  .brand { font-size: 1.15rem; }
  .top-nav { gap: 10px; font-size: 0.82rem; }
  .new-post-link { padding: 4px 10px; font-size: 0.78rem; }

  .hero h1 { font-size: 1.7rem; }

  .bottom-nav a svg { width: 22px; height: 22px; }

  .post-card { padding: 16px 16px; }
  .form-page { padding: 20px; }
  .form-page--wide { max-width: 100%; }

  .admin-stats-grid { grid-template-columns: repeat(2, 1fr); }
  .admin-table th, .admin-table td { padding: 8px; font-size: 0.78rem; }
  .admin-actions-cell { flex-direction: column; align-items: flex-start; }

  .game-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .game-card { padding: 14px 8px; }
  .game-icon { font-size: 1.6rem; }
  .game-card h3 { font-size: 0.85rem; }
  .game-card p { font-size: 0.7rem; }

  .chat-box { height: 62vh; padding: 10px; }
  .chat-bubble { max-width: 85%; }

  .blog-grid { grid-template-columns: repeat(3, 1fr); }

  .external-game-embed { padding: 10px; }

  .tabs a { padding: 5px 12px; font-size: 0.82rem; }

  .comment-item { flex-direction: column; align-items: flex-start; gap: 4px; }
  .post-actions { gap: 6px; }
  .action-btn { padding: 5px 10px; font-size: 0.78rem; }
}

@media (max-width: 380px) {
  .admin-stats-grid { grid-template-columns: 1fr 1fr; }
  .game-grid { grid-template-columns: repeat(2, 1fr); }
  .hero h1 { font-size: 1.5rem; }
}

/* Dokunmatik hedefleri büyüt (parmakla tıklama kolaylığı) */
@media (hover: none) and (pointer: coarse) {
  .action-btn, .bottom-nav a, .chat-upload-btn, .swatch { min-height: 36px; }
  .reply-btn { padding: 6px 8px; }
}

/* ---------- Gömülü Supabase chat ----------
   Bu widget'ın kendi CSS'i inline (style="...") olduğu için, ezmek için
   !important kullanmak gerekiyor — normal özgüllük kuralları yetmiyor. */

/* Her mesaj kutusunu dikey bir sütun haline getiriyoruz: bu şekilde metin,
   varsa görsel/ses, ve reaksiyon satırı HER ZAMAN üst üste, sırayla dizilir —
   metnin uzunluğu/satır sayısı ne olursa olsun reaksiyonlar asla yana kaymaz. */
.external-chat-embed .chat-msg {
  display: flex !important;
  flex-direction: column !important;
  align-items: stretch !important;
}
.external-chat-embed .msg-reactions-row {
  border-top: 1px solid rgba(0, 0, 0, 0.05);
  padding-top: 4px;
  width: 100%;
}
.external-chat-embed .msg-reactions-row span {
  padding: 2px 3px;
}

@media (max-width: 600px) {
  .external-chat-embed #chat-room,
  .external-chat-embed #chat-login {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box;
  }
  .external-chat-embed #chat-messages {
    padding: 12px 10px !important;
    font-size: 0.95rem;
  }
  .external-chat-embed .chat-msg {
    margin-bottom: 14px !important;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  }
  .external-chat-embed .chat-msg p {
    line-height: 1.55 !important;
    word-break: break-word;
  }
}
