/* ════════════════════════════════════════════════════════════════
   ForumPHP — Mobil görünüm (Flarum mobil düzeni) · v2.3.2
   Yalnızca ≤ 767px genişlikte etkilidir. Masaüstüne dokunmaz.
   ════════════════════════════════════════════════════════════════ */

.Mobile-actions, .Mobile-search, .Mobile-back, .DrawerToggle-dot { display: none; }

@media (max-width: 767px) {

  /* ── Genel ── */
  html { scrollbar-gutter: auto; }
  body { -webkit-tap-highlight-color: transparent; }
  .App { padding-top: 52px !important; }

  /* ── Üst çubuk: ☰ / ←  ·  ortada site adı  ·  ara + birincil işlem ── */
  .App-header { height: 52px !important; padding: 0 !important; box-shadow: 0 1px 0 rgba(0,0,0,.06), 0 2px 8px rgba(0,0,0,.05); }
  .App-header .container { position: relative; height: 52px; display: flex; align-items: center; justify-content: space-between; padding: 0 6px !important; max-width: none !important; }
  .App-header .Header-nav,
  .App-header .Header-secondary,
  .App-header .Ara,
  .App-header .Search,
  .DrawerToggle--back,
  .Navigation-pin { display: none !important; }

  .DrawerToggle--mobile, .Mobile-back, .Mobile-btn {
    display: inline-flex !important; align-items: center; justify-content: center;
    position: relative; width: 40px; height: 40px; flex: none; padding: 0; margin: 0;
    border: 0; border-radius: 10px; background: transparent !important;
    color: var(--header-text) !important; font-size: 18px; cursor: pointer; text-decoration: none !important;
  }
  .DrawerToggle--mobile:active, .Mobile-back:active, .Mobile-btn:active { background: var(--header-ctrl-bg) !important; }
  .DrawerToggle-dot { display: block; position: absolute; top: 9px; right: 8px; width: 9px; height: 9px; border-radius: 50%; background: #e74c3c; box-shadow: 0 0 0 2px var(--header-bg); }

  .App-header .Header-logo {
    position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
    max-width: calc(100% - 190px); margin: 0 !important; display: flex; align-items: center; justify-content: center; gap: 8px;
  }
  .App-header .Header-logo img { max-height: 28px; width: auto; }
  .App-header .Header-logo-text { font-size: 17px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

  .Mobile-actions { display: flex; align-items: center; gap: 0; margin-left: auto; }
  .Mobile-btn { font-size: 17px; }
  .Mobile-btn--primary { color: var(--header-text) !important; }

  /* Arama: üst çubuğun tamamını kaplar */
  .Mobile-search {
    display: flex; align-items: center; gap: 8px; position: absolute; inset: 0; z-index: 3;
    padding: 0 6px 0 14px; background: var(--header-bg);
    opacity: 0; pointer-events: none; transform: translateY(-6px); transition: opacity .15s, transform .15s;
  }
  .Mobile-search > i { color: var(--header-ctrl); font-size: 15px; }
  .Mobile-search input {
    flex: 1; min-width: 0; height: 38px; border: 0; border-radius: 10px; padding: 0 12px;
    background: var(--header-ctrl-bg); color: var(--header-text); font-size: 16px; outline: none;
  }
  .Mobile-search input::placeholder { color: var(--header-ctrl); }
  .App-header.is-searching .Mobile-search { opacity: 1; pointer-events: auto; transform: none; }

  /* ── Yan menü (drawer) ── */
  .App-drawer { width: 86% !important; max-width: 340px; border-radius: 0 !important; box-shadow: 4px 0 30px rgba(0,0,0,.2); }
  .App-drawer-header { height: 52px; padding: 0 8px 0 16px; background: var(--header-bg); border-bottom: 0; }
  .App-drawer-header .Header-logo-text { color: var(--header-text); font-size: 16px; font-weight: 700; }
  .App-drawer-close { color: var(--header-text) !important; width: 40px; height: 40px; font-size: 17px; }
  .App-drawer-search { padding: 12px 14px; border-bottom: 1px solid #f0f0f2; }
  .App-drawer-search input { height: 40px !important; border-radius: 10px !important; font-size: 15px !important; }
  .App-drawer-user { padding: 16px; gap: 12px; }
  .App-drawer-user .name { font-size: 15px; font-weight: 700; }
  .App-drawer .NavItem { min-height: 44px; padding: 0 18px; gap: 14px; font-size: 15px; display: flex; align-items: center; }
  .App-drawer .NavItem .icon { width: 18px; text-align: center; color: #9aa0a6; font-size: 15px; }
  .App-drawer .NavItem.active { font-weight: 600; }
  .App-drawer .NavItem .tag-dot { width: 10px; height: 10px; margin: 0 4px; }
  .App-drawer .Nav-section { padding: 16px 18px 6px; font-size: 11.5px; }
  .App-drawer .Drawer-newBtn { margin: 4px 14px 10px; border-radius: 10px; justify-content: center; background: var(--primary) !important; color: #fff !important; font-weight: 600; }
  .App-drawer .Drawer-newBtn .icon { color: #fff !important; }

  /* ── Duyuru bandı ── */
  .DuyuruBandi, .AnnouncementBar { font-size: 13px; }

  /* ── Karşılama alanı: sade ── */
  .Hero--wide .Hero-inner { padding: 22px 16px 20px !important; }
  .Hero--wide .Hero-title { font-size: 20px !important; margin-bottom: 6px; }
  .Hero--wide .Hero-subtitle { font-size: 13.5px !important; line-height: 1.5; }
  .Hero-eyebrow { margin-bottom: 10px; padding: 3px 10px; font-size: 12px; }
  .Hero-stats, .Hero-note { display: none !important; }
  .Hero-actions { margin-top: 14px !important; gap: 8px; }
  .Hero-btn { height: 36px !important; padding: 0 15px !important; font-size: 13px !important; }
  .Hero--wide::before { width: 200px; height: 200px; right: -70px; top: -100px; }
  .Hero--wide::after { display: none; }
  .Hero-close { top: 8px; right: 8px; }

  /* ── Konu listesi ── */
  .IndexPage { padding: 0 !important; margin: 0 !important; }
  .IndexPage-nav { display: none !important; }
  .IndexPage-main { padding: 0 !important; }
  .DiscList-toolbar { display: flex; align-items: center; gap: 8px; padding: 10px 12px !important; margin: 0 !important; border-bottom: 1px solid #f0f0f2; background: #fff; }
  .DiscList-sortBtn { height: 34px; padding: 0 14px; border-radius: 999px; font-size: 13px; font-weight: 600; }
  .DiscList-markRead { margin-left: auto; width: 34px; height: 34px; border-radius: 50%; }

  .DiscItem { padding: 13px 14px !important; gap: 12px; align-items: flex-start; border-bottom: 1px solid #f2f2f4; }
  .DiscItem:active { background: #f7f7f9; }
  .DiscItem-avatar { width: auto !important; flex: none; padding-top: 1px; }
  .DiscItem-avatar .Avatar, .DiscItem-avatar img { width: 38px !important; height: 38px !important; font-size: 15px !important; }
  .DiscItem-main { min-width: 0; gap: 3px; }
  .DiscItem-title { font-size: 15px !important; font-weight: 600; line-height: 1.35; color: #1f2328; }
  .DiscItem-excerpt { display: none !important; }
  .DiscItem-meta { font-size: 12.5px; line-height: 1.5; flex-wrap: wrap; row-gap: 3px; color: #8a8f98; }
  .DiscItem-pulse { font-size: 11px; padding: 0 7px; margin-left: 4px; }
  .DiscItem-tags { max-width: none !important; }

  .DiscItem-right { align-self: flex-start; padding-top: 2px; gap: 6px; }
  .DiscItem-replyCount { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; color: #8a8f98; }
  .DiscItem-replyCount.is-zero .DiscItem-replyIcon, .DiscItem-replyCount.is-zero .DiscItem-replyNum { display: none; }

  /* ── Kategori başlığı ── */
  .TagHero-inner { padding: 22px 16px !important; }

  /* ── Konu sayfası ── */
  .DiscHero, .DiscussionHero { padding: 22px 16px 20px !important; }
  .DiscHero-title, .DiscussionHero-title { font-size: 19px !important; line-height: 1.3; }
  .DiscussionPage { padding: 0 0 76px !important; margin: 0 !important; }
  .DiscussionPage-stream { border-radius: 0 !important; }

  /* Gönderi: avatar isim satırında, metin tam genişlik */
  .Post, .PostStream-item { position: relative; display: block !important; padding: 16px 16px 6px !important; border-bottom: 1px solid #f2f2f4; }
  .Post-side { position: absolute; left: 16px; top: 16px; width: auto !important; padding: 0 !important; }
  .Post-side .Avatar, .Post-side img, .Post-side span { width: 34px !important; height: 34px !important; min-width: 34px; font-size: 13px !important; line-height: 34px; }
  .Post-main { margin: 0 !important; padding: 0 !important; }
  .Post .Post-meta { min-height: 34px; padding-left: 46px !important; display: flex; flex-wrap: wrap; align-items: center; column-gap: 7px; row-gap: 0; margin-bottom: 8px; }
  .Post-author { font-size: 14.5px !important; font-weight: 700; }
  .Post-time { font-size: 12.5px; }
  .Post-content { font-size: 15px !important; line-height: 1.65 !important; }
  .Post-content img { max-width: 100%; height: auto; }
  .Post-content pre { max-width: 100%; overflow-x: auto; }
  .Post-footer, .Post-actions { margin-top: 4px; }

  /* Konu sayfası alt çubuğu: konum + yanıtla (başparmak hizasında) */
  .Scrubber { display: none !important; }
  .MobileScrubBar {
    display: flex !important; position: fixed !important; top: auto !important; bottom: 0; left: 0; right: 0; z-index: 190;
    height: auto !important; padding: 8px 10px calc(8px + env(safe-area-inset-bottom)) 16px !important;
    background: rgba(255,255,255,.97); border-top: 1px solid #e8e8ec; border-bottom: 0 !important;
    box-shadow: 0 -2px 14px rgba(0,0,0,.06) !important; align-items: center; gap: 10px;
    -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  }
  .MobileScrubBar-info { flex: 1; text-align: left !important; font-size: 13px; font-weight: 600; color: #6b7280; }
  .MobileScrubBar-btn {
    height: 40px; padding: 0 18px !important; border-radius: 999px; gap: 7px;
    display: inline-flex; align-items: center; background: var(--primary) !important; color: #fff !important; font-size: 14px !important; font-weight: 700;
  }
  .MobileScrubBar-btn::after { content: "Yanıtla"; }
  .ComposerPlaceholder { margin: 14px 12px 0 !important; }

  /* ── Yanıt kutusu: Flarum mobildeki gibi tam ekran ── */
  .Composer2 { left: 0 !important; width: 100% !important; max-width: 100% !important; z-index: 600; }
  .Composer2.open { top: 0; bottom: 0; }
  .Composer2.open .Composer2-box { height: 100%; height: 100dvh; display: flex; flex-direction: column; border-radius: 0; border: 0; box-shadow: none; }
  .Composer2.open .Composer2-box > form, .Composer2.open #replyForm { flex: 1; display: flex; flex-direction: column; min-height: 0; }
  .Composer2.open .Composer2-header { padding: 6px 8px 6px 14px; min-height: 52px; background: var(--header-bg); border-bottom: 0; }
  .Composer2.open .Composer2-replying { color: var(--header-text); font-weight: 600; font-size: 14.5px; }
  .Composer2.open .Composer2-replying i { color: var(--header-ctrl); }
  .Composer2.open .Composer2-header .Avatar { display: none; }
  .Composer2-ctrl#composerFsBtn, .Composer2-ctrl[onclick*="minimize"] { display: none !important; }
  .Composer2.open .Composer2-ctrl { color: var(--header-text) !important; width: 40px; height: 40px; font-size: 17px; }
  .Composer2.open .Composer2-textarea { flex: 1 !important; max-height: none !important; min-height: 0 !important; font-size: 16px !important; padding: 14px 16px !important; resize: none; }
  .Composer2.open .Composer2-footer { padding: 8px 12px calc(8px + env(safe-area-inset-bottom)); border-top: 1px solid #eee; }
  .Composer2-submit { height: 40px; border-radius: 999px; padding: 0 20px; }
  body:has(.Composer2.open) { overflow: hidden; }
  body:has(.Composer2.open) .MobileScrubBar { display: none !important; }

  /* ── Yeni konu sayfası ── */
  .NewDiscussionPage, .NewDisc { padding: 0 !important; margin: 0 !important; }
  input, select, textarea { font-size: 16px; } /* iOS yakınlaştırma yapmasın */

  /* ── Pencereler: alttan açılan sayfa ── */
  .Modal-backdrop { align-items: flex-end !important; padding: 0 !important; }
  .Modal-backdrop .Modal, .Modal-backdrop .Modal-dialog { width: 100% !important; max-width: 100% !important; margin: 0 !important; border-radius: 16px 16px 0 0 !important; max-height: 92dvh; overflow-y: auto; }
}
