/* ForumPHP v2.0 — Flarum 2 özellikleri için ek stiller (mevcut tasarıma uyumlu) */

/* ── Site uyarı bandı ── */
.SiteNotice { background: #fff8e6; border-bottom: 1px solid #f3dfa8; color: #7a5a06; font-size: 13px; padding: 9px 16px; display: flex; align-items: center; justify-content: center; gap: 8px; flex-wrap: wrap; text-align: center; }
.SiteNotice--danger { background: #fdeeee; border-color: #f3c7c7; color: #9b2c2c; }
.SiteNotice-btn { background: rgba(0,0,0,.06); border-radius: 4px; padding: 3px 10px; font-size: 12px; font-weight: 600; color: inherit; }
.SiteNotice-btn:hover { background: rgba(0,0,0,.1); }

/* ── Durum rozetleri ── */
.StateBadge { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 600; padding: 1px 7px; border-radius: 3px; background: rgba(0,0,0,.06); color: #667; vertical-align: middle; line-height: 18px; white-space: nowrap; }
.StateBadge--warn { background: #fff3d6; color: #8a6100; }
.StateBadge--danger { background: #fde8e8; color: #b42318; }
a.StateBadge--danger:hover { color: #8f1c13; }
.DiscHero-badges { display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; margin-top: 8px; }
.DiscHero-badges:empty { display: none; }
.DiscHero .StateBadge { background: rgba(255,255,255,.18); color: inherit; }
.GroupBadge { margin-right: 2px; }
.GroupBadge i { font-size: 10px; }

/* ── Konu listesi: okunmamış ── */
.DiscItem--unread .DiscItem-title { font-weight: 700; color: #111; }
.DiscItem:not(.DiscItem--unread) .DiscItem-title { font-weight: 500; }
.DiscItem--hidden { opacity: .6; }
.DiscItem-unreadCount { display: inline-block; margin-left: 4px; min-width: 18px; padding: 0 5px; border-radius: 9px; background: var(--primary); color: #fff; font-size: 10.5px; font-weight: 700; line-height: 18px; text-align: center; }
.DiscItem-title + .StateBadge { margin-left: 6px; }
.FilterChip { display: inline-flex; align-items: center; gap: 6px; margin-left: 8px; padding: 3px 6px 3px 10px; border-radius: 14px; background: rgba(0,0,0,.05); font-size: 12px; font-weight: 600; color: #555; }
.FilterChip a { color: #999; width: 18px; height: 18px; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; }
.FilterChip a:hover { background: rgba(0,0,0,.08); color: #333; }
.IndexNav-link--child { padding-left: 30px !important; font-size: 13px; }
.IndexNav-lock { font-size: 10px; color: #bbb; margin-left: 2px; }
.NavItem--child { padding-left: 34px !important; font-size: 13px; }

/* ── Alt forumlar (kategori sayfası) ── */
.SubforumBar { border-bottom: 1px solid rgba(0,0,0,.06); background: #fafbfc; }
.SubforumBar-inner { max-width: 1100px; margin: 0 auto; padding: 14px 15px; }
.SubforumBar-back { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: #667; margin-bottom: 8px; }
.SubforumBar-back:hover { color: var(--primary); }
.SubforumBar-back:only-child { margin-bottom: 0; }
.SubforumGrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; }
.SubforumCard { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 6px; background: #fff; border: 1px solid rgba(0,0,0,.07); color: #333; transition: border-color .15s, box-shadow .15s; min-width: 0; }
.SubforumCard:hover { border-color: var(--tag-color); box-shadow: 0 2px 8px rgba(0,0,0,.05); color: #333; text-decoration: none; }
.SubforumCard-icon { width: 36px; height: 36px; flex: 0 0 36px; border-radius: 6px; background: var(--tag-color); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 15px; }
.SubforumCard-body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.SubforumCard-name { font-weight: 700; font-size: 14px; }
.SubforumCard-desc { font-size: 12px; color: #888; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.SubforumCard-count { font-size: 12px; color: #aaa; font-weight: 600; }

/* ── Tüm kategoriler sayfası ── */
.TagsPage { max-width: 1100px; margin: 0 auto; padding: 24px 15px 40px; }
.TagsPage-title { font-size: 20px; font-weight: 700; color: #333; margin-bottom: 4px; }
.TagsPage-sub { color: #888; font-size: 13px; margin-bottom: 18px; }
.TagsGrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; }
.TagTile { border-radius: 8px; overflow: hidden; background: #fff; border: 1px solid rgba(0,0,0,.07); display: flex; flex-direction: column; }
.TagTile-head { display: flex; gap: 12px; align-items: flex-start; padding: 16px; background: var(--tag-color); color: #fff; }
.TagTile-head:hover { color: #fff; text-decoration: none; filter: brightness(1.04); }
.TagTile-icon { width: 40px; height: 40px; flex: 0 0 40px; border-radius: 8px; background: rgba(255,255,255,.2); display: flex; align-items: center; justify-content: center; font-size: 17px; }
.TagTile-name { font-size: 16px; font-weight: 700; display: flex; align-items: center; gap: 6px; }
.TagTile-desc { font-size: 12.5px; opacity: .85; margin-top: 2px; line-height: 1.45; }
.TagTile-children { display: flex; flex-direction: column; border-bottom: 1px solid rgba(0,0,0,.05); }
.TagTile-child { display: flex; gap: 8px; align-items: center; padding: 8px 16px; font-size: 13px; color: #444; border-top: 1px solid rgba(0,0,0,.04); }
.TagTile-child:hover { background: #fafbfc; color: var(--tag-color); text-decoration: none; }
.TagTile-child small { color: #aaa; margin-left: auto; }
.TagTile-child span.desc { color: #999; font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.TagTile-last { padding: 10px 16px; font-size: 12.5px; color: #888; display: flex; gap: 8px; align-items: center; margin-top: auto; min-width: 0; }
.TagTile-last a { color: #444; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; flex: 1; }
.TagTile-stats { margin-left: auto; white-space: nowrap; }

/* ── Gönderi durumları ── */
.Post--pending { background: #fffbef; border-radius: 6px; }
.Post--hidden { padding: 6px 0; }
.Post-hiddenBar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; width: 100%; font-size: 13px; color: #888; padding: 10px 14px; background: #f6f7f8; border-radius: 6px; }
.Post-hiddenBar > span { flex: 1; min-width: 180px; }
.Post-hiddenBar form { display: inline; }
.Post-hiddenContent { display: none; margin: 8px 0 0 0; padding: 10px 14px; border-left: 3px solid #ddd; opacity: .75; }
.Post--hidden.is-revealed .Post-hiddenContent { display: block; }
.PostAction--approve { color: #1e8449 !important; font-weight: 600; }
.Button--danger { color: #c0392b !important; }
.NewPostsBar { cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px; margin: 10px 0; padding: 10px; border-radius: 6px; background: var(--primary); color: #fff; font-weight: 600; font-size: 13px; }
.NewPostsBar:hover { filter: brightness(1.06); }

/* ── Biçimlendirme ── */
.Spoiler { background: #333; color: transparent; border-radius: 3px; padding: 0 3px; cursor: pointer; transition: color .15s, background .15s; user-select: none; }
.Spoiler.is-open, .Spoiler:focus { background: rgba(0,0,0,.06); color: inherit; user-select: auto; }
.Post-content del { opacity: .7; }

/* ── Emoji seçici ── */
.EmojiPicker { position: absolute; z-index: 1300; width: 288px; max-height: 220px; overflow-y: auto; display: grid; grid-template-columns: repeat(8, 1fr); gap: 2px; padding: 8px; background: #fff; border: 1px solid #e3e6ea; border-radius: 8px; box-shadow: 0 8px 24px rgba(0,0,0,.12); }
.EmojiPicker-item { font-size: 20px; line-height: 32px; height: 32px; border-radius: 6px; text-align: center; }
.EmojiPicker-item:hover { background: #f1f3f5; }

/* ── Şikayet modalı ── */
.FlagOpt { display: flex; gap: 10px; align-items: flex-start; padding: 9px 10px; border-radius: 6px; cursor: pointer; }
.FlagOpt:hover { background: #f6f7f8; }
.FlagOpt input { margin-top: 4px; }
.FlagOpt span { display: flex; flex-direction: column; font-size: 13.5px; }
.FlagOpt small { color: #888; font-size: 12px; }

/* ── Giriş / sıfırlama sayfaları ── */
.AuthPage { min-height: 55vh; display: flex; align-items: center; justify-content: center; padding: 40px 15px; }
.AuthCard { width: 100%; max-width: 420px; background: #fff; border-radius: 8px; box-shadow: 0 2px 14px rgba(0,0,0,.08); overflow: hidden; }
.AuthCard-head { padding: 16px 20px; border-bottom: 1px solid #eee; font-weight: 700; font-size: 15px; color: #333; display: flex; gap: 8px; align-items: center; }
.AuthCard-head i { color: var(--primary); }
.AuthCard-body { padding: 20px; display: flex; flex-direction: column; gap: 12px; }
.AuthCard-text { color: #666; font-size: 13.5px; }
.AuthForm { display: flex; flex-direction: column; gap: 12px; }
.Modal-forgot { text-align: center; margin-top: 12px; font-size: 13px; }
.Modal-text { color: #666; font-size: 13px; margin-bottom: 12px; }

/* ── Mesajlar (konuşmalar) ── */
.DMPage { max-width: 1100px; margin: 0 auto; padding: 20px 15px 30px; display: grid; grid-template-columns: 320px 1fr; gap: 16px; height: calc(100vh - 90px); min-height: 480px; }
.DMList, .DMThread { background: #fff; border: 1px solid rgba(0,0,0,.07); border-radius: 8px; display: flex; flex-direction: column; min-height: 0; overflow: hidden; }
.DMList-head, .DMThread-head { padding: 12px 14px; border-bottom: 1px solid #eee; display: flex; align-items: center; gap: 10px; font-weight: 700; color: #333; min-height: 56px; }
.DMList-head .Button { margin-left: auto; }
.DMList-items { overflow-y: auto; flex: 1; }
.DMItem { display: flex; gap: 10px; align-items: center; padding: 10px 14px; border-bottom: 1px solid rgba(0,0,0,.04); color: #333; }
.DMItem:hover { background: #fafbfc; color: #333; text-decoration: none; }
.DMItem.active { background: rgba(77,105,142,.08); }
.DMItem-body { flex: 1; min-width: 0; }
.DMItem-name { font-weight: 600; font-size: 13.5px; display: flex; gap: 6px; align-items: baseline; }
.DMItem-name small { margin-left: auto; color: #aaa; font-weight: 400; font-size: 11px; white-space: nowrap; }
.DMItem-last { font-size: 12.5px; color: #888; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.DMItem.is-unread .DMItem-last { color: #333; font-weight: 600; }
.DMItem-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--primary); flex: 0 0 8px; }
.DMEmpty { padding: 40px 20px; text-align: center; color: #aaa; font-size: 13px; margin: auto; }
.DMEmpty i { font-size: 30px; display: block; margin-bottom: 10px; color: #ddd; }
.DMThread-head a { color: #333; }
.DMThread-head .DMThread-actions { margin-left: auto; display: flex; gap: 6px; }
.DMThread-body { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 6px; background: #fbfbfc; }
.DMMsg { max-width: 72%; padding: 8px 12px; border-radius: 14px; background: #fff; border: 1px solid #eceef1; font-size: 14px; line-height: 1.5; align-self: flex-start; word-wrap: break-word; }
.DMMsg p, .DMMsg blockquote { margin: 0; }
.DMMsg--mine { align-self: flex-end; background: var(--primary); color: #fff; border-color: transparent; }
.DMMsg--mine a { color: #fff; text-decoration: underline; }
.DMMsg-time { display: block; font-size: 10.5px; opacity: .6; margin-top: 2px; text-align: right; }
.DMDay { align-self: center; font-size: 11px; color: #aaa; margin: 8px 0; }
.DMThread-form { border-top: 1px solid #eee; padding: 10px; display: flex; gap: 8px; align-items: flex-end; }
.DMThread-form textarea { flex: 1; resize: none; min-height: 40px; max-height: 160px; border: 1px solid #e3e6ea; border-radius: 8px; padding: 9px 12px; font-size: 14px; }
.DMThread-form textarea:focus { border-color: var(--primary); }
.DMThread-note { padding: 12px; text-align: center; font-size: 13px; color: #888; border-top: 1px solid #eee; }
@media (max-width: 760px) {
  .DMPage { grid-template-columns: 1fr; height: auto; padding: 10px; }
  .DMPage.has-dialog .DMList { display: none; }
  .DMPage:not(.has-dialog) .DMThread { display: none; }
  .DMThread { height: calc(100vh - 90px); }
  .DMMsg { max-width: 86%; }
}

/* ── Ayarlar: veri ve gizlilik ── */
.DangerZone { border: 1px solid #f3c7c7; border-radius: 6px; padding: 14px; background: #fffafa; }
.DangerZone h4 { color: #b42318; font-size: 14px; margin-bottom: 6px; }
.DangerZone p { font-size: 13px; color: #666; margin-bottom: 10px; }

/* ── Arama ── */
.SearchHelp { font-size: 12px; color: #888; margin-top: 8px; line-height: 1.8; }
.SearchHelp code { background: #f1f3f5; padding: 1px 5px; border-radius: 3px; font-size: 11.5px; color: #555; cursor: pointer; }
.SearchHit-post { font-size: 12.5px; color: #777; margin-top: 4px; padding-left: 10px; border-left: 2px solid #e6e8eb; }
.SearchHit-post mark, .SearchHit mark { background: #fff2a8; color: inherit; padding: 0 1px; border-radius: 2px; }

/* ── Admin ek ── */
.PermGrid { width: 100%; border-collapse: collapse; font-size: 13px; }
.PermGrid th, .PermGrid td { padding: 8px 10px; border-bottom: 1px solid #f0f1f3; text-align: center; }
.PermGrid th:first-child, .PermGrid td:first-child { text-align: left; }
.PermGrid thead th { font-size: 12px; color: #667; background: #fafbfc; position: sticky; top: 0; }
.PermGrid tr.sect td { background: #f6f7f9; font-weight: 700; font-size: 11.5px; text-transform: uppercase; letter-spacing: .04em; color: #888; text-align: left; }
.PermGrid td small { display: block; color: #aaa; font-size: 11.5px; }
.PermGrid input[type=checkbox] { width: 16px; height: 16px; cursor: pointer; }
.FlagCard { border: 1px solid #eee; border-radius: 8px; padding: 14px; margin-bottom: 12px; background: #fff; }
.FlagCard-head { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-size: 13px; color: #666; margin-bottom: 8px; }
.FlagCard-head a { font-weight: 600; }
.FlagCard-reasons { display: flex; flex-direction: column; gap: 4px; margin: 8px 0; font-size: 12.5px; }
.FlagCard-reasons div { background: #fdf3f3; border-radius: 4px; padding: 5px 9px; color: #7d2d2d; }
.FlagCard-content { font-size: 13.5px; color: #333; background: #fafbfc; border-radius: 6px; padding: 10px 12px; max-height: 180px; overflow: auto; }
.FlagCard-actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 10px; }
.FlagCard-actions form { display: inline; }
.AdminTabs { display: flex; gap: 4px; border-bottom: 1px solid #eee; margin-bottom: 16px; }
.AdminTabs a { padding: 8px 14px; font-size: 13px; font-weight: 600; color: #888; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.AdminTabs a.active { color: var(--primary); border-color: var(--primary); }
.AdminTabs a .count { background: #e74c3c; color: #fff; border-radius: 8px; font-size: 10px; padding: 0 6px; margin-left: 4px; }

/* ── Grup sohbetleri ── */
.DMGroupIcon { border-radius: 50%; background: linear-gradient(135deg, var(--primary), #8e9bb3); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 15px; }
.DMItem-count { font-style: normal; font-size: 10.5px; font-weight: 600; color: #999; background: #f1f3f5; border-radius: 8px; padding: 0 6px; }
.DMThread-sub { font-size: 11.5px; color: #aaa; font-weight: 400; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.DMThread-sub a { color: #888; }
.DMSystem { align-self: center; font-size: 11.5px; color: #8a8f98; background: #f0f1f3; border-radius: 10px; padding: 3px 10px; margin: 4px 0; text-align: center; max-width: 90%; }
.DMMsg-author { display: block; font-size: 11.5px; font-weight: 700; color: var(--primary); margin-bottom: 2px; }
.DMMembers { display: flex; flex-direction: column; max-height: 280px; overflow-y: auto; border: 1px solid #eee; border-radius: 6px; }
.DMMember { display: flex; align-items: center; gap: 10px; padding: 8px 12px; color: #333; border-bottom: 1px solid #f3f3f3; }
.DMMember:last-child { border-bottom: 0; }
.DMMember:hover { background: #fafbfc; color: #333; text-decoration: none; }
.DMMember span { flex: 1; font-size: 13.5px; }
.DMMember small { color: #aaa; }
.DMSuggest { position: absolute; left: 0; right: 0; top: 100%; background: #fff; border: 1px solid #e3e6ea; border-radius: 6px; box-shadow: 0 6px 18px rgba(0,0,0,.08); z-index: 5; display: none; }
.DMSuggest a { display: block; padding: 8px 12px; font-size: 13px; color: #333; cursor: pointer; }
.DMSuggest a:hover { background: #f5f6f8; }
.DMSuggest small { color: #aaa; margin-left: 6px; }
@media (max-width: 760px) { #dmBack { display: inline-flex !important; } }

/* ── Anlık güncelleme çubuğu (ana sayfa) ── */
.LiveBar { position: sticky; top: 60px; z-index: 50; cursor: pointer; display: none; align-items: center; justify-content: center; gap: 8px; margin: 0 0 10px; padding: 9px; border-radius: 6px; background: var(--primary); color: #fff; font-weight: 600; font-size: 13px; }

/* ── Eklentiler ── */
.ExtGrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 12px; }
.ExtCard { background: #fff; border: 1px solid #eceef1; border-radius: 8px; padding: 14px; display: flex; gap: 12px; align-items: flex-start; }
.ExtCard-icon { width: 40px; height: 40px; flex: 0 0 40px; border-radius: 8px; background: #f1f4f8; color: var(--primary); display: flex; align-items: center; justify-content: center; font-size: 17px; }
.ExtCard.is-on .ExtCard-icon { background: var(--primary); color: #fff; }
.ExtCard-body { flex: 1; min-width: 0; }
.ExtCard-title { font-weight: 700; font-size: 14px; color: #333; display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.ExtCard-title small { font-weight: 400; color: #aaa; font-size: 11.5px; }
.ExtCard-desc { font-size: 12.5px; color: #777; margin: 3px 0 8px; line-height: 1.45; }
.ExtCard-actions { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.ExtCard-actions form { display: inline; }
.ExtSwitch { position: relative; width: 38px; height: 22px; border-radius: 11px; background: #d5d9de; border: 0; cursor: pointer; transition: background .15s; flex: 0 0 38px; }
.ExtSwitch::after { content: ''; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: left .15s; box-shadow: 0 1px 2px rgba(0,0,0,.2); }
.ExtSwitch.on { background: #2ecc71; }
.ExtSwitch.on::after { left: 19px; }
.ExtNote { font-size: 11.5px; color: #b7791f; background: #fff8e6; border-radius: 4px; padding: 3px 8px; }

.ExtStatus { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 14px; border-radius: 8px; margin-bottom: 16px; font-size: 13.5px; }
.ExtStatus.is-on { background: #eafaf1; color: #1e8449; border: 1px solid #c8eed8; }
.ExtStatus.is-off { background: #fff8e6; color: #8a6100; border: 1px solid #f3dfa8; }
.ExtStatus span { flex: 1; min-width: 220px; }
.ExtStatus form { display: inline; }
