/* Blog (/blog, /blog/<slug>): liste kartları, yazı düzeni, tepkiler, paylaş, yorumlar. Sitenin değişkenlerini (style.css) kullanır. */

/* ---------- Liste ---------- */
.b-hero { padding-bottom: 40px; }
.b-search { position: relative; max-width: 460px; margin: 30px auto 0; }
.b-search svg { position: absolute; left: 18px; top: 50%; width: 18px; height: 18px; translate: 0 -50%; color: var(--muted); pointer-events: none; }
.b-search input {
  width: 100%; padding: 14px 18px 14px 48px; border-radius: 999px; font: inherit; color: var(--text);
  background: var(--field-bg); border: 1px solid var(--border); outline: none; transition: border-color 0.3s, box-shadow 0.3s;
}
.b-search input:focus { border-color: var(--cyan); box-shadow: 0 0 0 4px rgba(56, 200, 255, 0.12); }
.b-wrap { padding-bottom: 90px; }
.b-cats { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-bottom: 36px; }
.b-cats a { padding: 8px 16px; border-radius: 999px; font-size: 0.88rem; font-weight: 600; color: var(--muted); background: var(--surface); border: 1px solid var(--border); transition: color 0.2s, border-color 0.2s, background 0.2s; }
.b-cats a span { opacity: 0.6; font-weight: 500; margin-left: 2px; }
.b-cats a:hover { color: var(--text); border-color: var(--border-hover); }
.b-cats a.on { color: #fff; background: var(--grad); border-color: transparent; }

.b-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 26px; }
.b-card { display: flex; flex-direction: column; border-radius: var(--radius); overflow: hidden; background: var(--surface); border: 1px solid var(--border); transition: border-color 0.3s, transform 0.4s var(--ease), box-shadow 0.4s; }
.b-card:hover { border-color: var(--border-hover); transform: translateY(-4px); box-shadow: var(--shadow); }
.b-card-img { display: block; aspect-ratio: 16 / 9; overflow: hidden; background: var(--surface-2); }
.b-card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.7s var(--ease); }
.b-card:hover .b-card-img img { transform: scale(1.04); }
.b-card-ph { display: grid; place-items: center; width: 100%; height: 100%; background: radial-gradient(circle at 30% 20%, rgba(47, 107, 255, 0.25), transparent 60%), radial-gradient(circle at 80% 90%, rgba(255, 61, 127, 0.2), transparent 55%); }
.b-card-ph img { width: 64px; height: 64px; opacity: 0.85; transform: none !important; }
.b-card-body { display: flex; flex-direction: column; gap: 10px; padding: 22px 24px 24px; flex: 1; }
.b-card h2, .b-card h3 { font-size: 1.22rem; line-height: 1.3; }
.b-card h2 a:hover, .b-card h3 a:hover { color: var(--cyan); }
.b-card p { color: var(--muted); font-family: var(--font-soft); font-weight: 500; font-size: 0.95rem; flex: 1; }
.b-cat { align-self: flex-start; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--cyan); }
.b-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; font-size: 0.82rem; color: var(--muted); }
.b-meta > * + *::before { content: "·"; margin-right: 14px; opacity: 0.6; }
.b-meta a:hover { color: var(--text); }
.b-card-big { display: grid; grid-template-columns: 1.25fr 1fr; margin-bottom: 30px; }
.b-card-big .b-card-img { aspect-ratio: auto; min-height: 320px; }
.b-card-big .b-card-body { padding: 38px 40px; justify-content: center; }
.b-card-big h2 { font-size: clamp(1.5rem, 2.6vw, 2.1rem); }
.b-card-big p { flex: none; font-size: 1.02rem; }
.b-empty { text-align: center; padding: 60px 20px; border-radius: var(--radius); background: var(--surface); border: 1px dashed var(--border); }
.b-empty img { margin: 0 auto 16px; opacity: 0.8; }
.b-empty h2 { font-size: 1.4rem; margin-bottom: 8px; }
.b-empty p { color: var(--muted); margin-bottom: 20px; }
.b-pager { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 44px; }
.b-pager a { min-width: 42px; padding: 9px 14px; text-align: center; border-radius: 12px; border: 1px solid var(--border); background: var(--surface); font-weight: 600; font-size: 0.9rem; }
.b-pager a:hover { border-color: var(--border-hover); }
.b-pager a.on { background: var(--grad); color: #fff; border-color: transparent; }

/* ---------- Yazı ---------- */
.b-post { padding-top: 150px; }
.b-post-head { max-width: 860px; text-align: center; }
.b-post-head h1 { font-size: clamp(2rem, 4.6vw, 3.3rem); margin-bottom: 18px; }
.b-post-meta { justify-content: center; margin-bottom: 36px; font-size: 0.9rem; }
.b-notice { margin-bottom: 22px; padding: 12px 16px; border-radius: 14px; font-size: 0.9rem; background: rgba(255, 197, 61, 0.12); border: 1px solid rgba(255, 197, 61, 0.4); color: var(--text); }
.b-notice a { color: var(--cyan); text-decoration: underline; }
.b-cover { max-width: 1040px; margin-bottom: 50px; }
.b-cover img { width: 100%; max-height: 560px; object-fit: cover; border-radius: 26px; border: 1px solid var(--border); box-shadow: var(--shadow); }
.b-layout { max-width: 1040px; padding-bottom: 40px; }   /* kapak görseliyle aynı genişlik */
.b-toc { margin-bottom: 36px; padding: 18px 22px; border-radius: 18px; background: var(--surface); border: 1px solid var(--border); }
.b-toc summary { cursor: pointer; font-family: "Sora", sans-serif; font-size: 0.85rem; letter-spacing: 0.04em; text-transform: uppercase; color: var(--muted); list-style-position: inside; }
.b-toc summary:hover { color: var(--text); }
.b-toc ol { list-style: none; display: grid; gap: 2px; margin-top: 12px; border-left: 2px solid var(--border); }
.b-toc a { display: block; padding: 5px 0 5px 14px; margin-left: -2px; border-left: 2px solid transparent; font-size: 0.95rem; color: var(--muted); line-height: 1.4; transition: color 0.2s, border-color 0.2s; }
.b-toc .lvl-3 a { padding-left: 28px; font-size: 0.9rem; }
.b-toc a:hover { color: var(--text); border-left-color: var(--cyan); }

.b-prose { font-family: var(--font-soft); font-weight: 500; font-size: 1.1rem; line-height: 1.85; color: var(--body-text); overflow-wrap: break-word; }
.b-prose > * + * { margin-top: 1.15em; }
.b-prose h2, .b-prose h3, .b-prose h4 { color: var(--text); scroll-margin-top: 110px; }
.b-prose h2 { font-size: 1.75rem; margin-top: 1.9em; }
.b-prose h3 { font-size: 1.35rem; margin-top: 1.6em; }
.b-prose h4 { font-size: 1.12rem; margin-top: 1.4em; }
.b-prose a { color: var(--cyan); text-decoration: underline; text-underline-offset: 3px; }
.b-prose strong { color: var(--text); font-weight: 700; }
.b-prose ul, .b-prose ol { padding-left: 1.4em; display: grid; gap: 0.4em; }
.b-prose ul li { list-style: disc; }
.b-prose ol li { list-style: decimal; }
.b-prose li::marker { color: var(--cyan); }
.b-prose blockquote { padding: 18px 24px; border-left: 4px solid; border-image: var(--grad) 1; background: var(--surface); border-radius: 0 16px 16px 0; color: var(--text); font-style: italic; }
.b-prose code { font-family: ui-monospace, "Cascadia Code", Consolas, monospace; font-size: 0.88em; padding: 2px 7px; border-radius: 7px; background: var(--surface-2); color: var(--text); }
.b-prose pre { padding: 20px 22px; border-radius: 16px; background: #0b1028; border: 1px solid var(--border); overflow-x: auto; font-size: 0.92rem; line-height: 1.6; }
.b-prose pre code { padding: 0; background: none; color: #e3e8ff; font-size: inherit; }
.b-prose figure img, .b-prose p img { border-radius: 18px; border: 1px solid var(--border); margin: 0 auto; }
.b-prose hr { border: 0; height: 1px; background: var(--border); margin: 2.2em 0; }
.b-prose del { opacity: 0.7; }

/* ---------- Tepkiler ---------- */
.b-react { margin-top: 56px; padding: 30px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--border); text-align: center; }
.b-react h2 { font-size: 1.3rem; margin-bottom: 6px; }
.b-react-sub { color: var(--muted); font-size: 0.86rem; margin-bottom: 22px; }
.b-react-list { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 10px; }
.b-react-btn {
  position: relative; overflow: hidden; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 14px 4px 16px;
  border-radius: 16px; border: 1px solid var(--border); background: var(--surface-2); color: var(--text); font: inherit; cursor: pointer;
  transition: transform 0.25s var(--ease), border-color 0.25s, background 0.25s;
}
.b-react-btn:hover { transform: translateY(-3px); border-color: var(--border-hover); }
.b-react-btn:focus-visible { outline: 2px solid var(--cyan); outline-offset: 3px; }
.b-react-btn .emo { font-size: 2rem; line-height: 1.2; transition: transform 0.3s var(--ease); font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif; }
.b-react-btn:hover .emo { transform: scale(1.15) rotate(-6deg); }
.b-react-btn .cnt { font-weight: 800; font-size: 1.05rem; font-family: "Sora", sans-serif; }
.b-react-btn .lbl { font-size: 0.72rem; color: var(--muted); font-weight: 600; line-height: 1.25; }
.b-react-btn .bar { position: absolute; left: 0; bottom: 0; height: 4px; width: var(--p, 0%); background: var(--grad); opacity: 0.55; transition: width 0.5s var(--ease); }
.b-react-btn.on { border-color: transparent; background: linear-gradient(var(--bg-2), var(--bg-2)) padding-box, var(--grad) border-box; border: 2px solid transparent; padding: 13px 3px 15px; }
.b-react-btn.on .lbl { color: var(--text); }
.b-react-btn.on .bar { opacity: 1; }
.b-react-btn.pop .emo { animation: bPop 0.5s var(--ease); }
.b-react-btn[disabled] { cursor: progress; }
@keyframes bPop { 30% { transform: scale(1.5) rotate(-10deg); } 60% { transform: scale(0.9); } }

/* ---------- Paylaş ---------- */
.b-share { display: flex; flex-wrap: wrap; gap: 8px; }
.b-sh { display: inline-grid; place-items: center; grid-auto-flow: column; gap: 6px; height: 40px; min-width: 40px; padding: 0 10px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface); color: var(--text); font: 600 0.85rem "Inter", sans-serif; cursor: pointer; transition: transform 0.2s, background 0.2s, border-color 0.2s, color 0.2s; }
.b-sh svg { width: 18px; height: 18px; }
.b-sh:hover { transform: translateY(-2px); color: #fff; border-color: transparent; }
.b-sh-native:hover, .b-sh-copy:hover { background: var(--blue); }
.b-sh-whatsapp:hover { background: #25d366; }
.b-sh-x:hover { background: #111; }
.b-sh-facebook:hover { background: #1877f2; }
.b-sh-linkedin:hover { background: #0a66c2; }
.b-sh-telegram:hover { background: #229ed9; }
.b-sh-email:hover { background: #ea4335; }
.b-sh-copy.done { background: #16a34a; color: #fff; border-color: transparent; }
.b-share-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; margin-top: 28px; padding: 18px 22px; border-radius: 18px; border: 1px solid var(--border); background: var(--surface); }
.b-share-row > span { font-weight: 600; font-size: 0.95rem; }

.b-prevnext { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 28px; }
.b-prevnext a { display: grid; gap: 4px; padding: 18px 20px; border-radius: 18px; border: 1px solid var(--border); background: var(--surface); transition: border-color 0.2s; }
.b-prevnext a:hover { border-color: var(--border-hover); }
.b-prevnext a.nx { text-align: right; }
.b-prevnext small { color: var(--muted); font-size: 0.78rem; }
.b-prevnext b { font-family: "Sora", sans-serif; font-size: 0.98rem; line-height: 1.35; }

/* ---------- Yorumlar ---------- */
.b-comments { margin-top: 64px; }
.b-comments > h2 { font-size: 1.6rem; margin-bottom: 24px; display: flex; align-items: center; gap: 12px; }
.b-comments > h2 span { font-size: 0.9rem; padding: 3px 12px; border-radius: 999px; background: var(--surface-2); color: var(--muted); }
.b-cmt-list { display: grid; gap: 18px; margin-bottom: 36px; }
.b-thread { display: grid; gap: 12px; }
.b-cmt { display: flex; gap: 14px; padding: 18px 20px; border-radius: 18px; background: var(--surface); border: 1px solid var(--border); scroll-margin-top: 110px; }
.b-cmt:target { border-color: var(--cyan); }
.b-cmt-av { flex: none; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; color: #fff; background: var(--grad); }
.b-cmt.is-team { border-color: rgba(56, 200, 255, 0.35); background: linear-gradient(135deg, rgba(47, 107, 255, 0.08), rgba(255, 61, 127, 0.05)); }
.b-cmt.is-team .b-cmt-av { background: #fff; }
.b-cmt-main { min-width: 0; flex: 1; }
.b-cmt-main header { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 6px; }
.b-cmt-main header b { font-family: "Sora", sans-serif; font-size: 0.98rem; }
.b-cmt-main time { font-size: 0.78rem; color: var(--muted); }
.b-team { font-size: 0.68rem; font-weight: 700; padding: 2px 8px; border-radius: 999px; color: #fff; background: var(--blue); }
.b-cmt-body { color: var(--body-text); font-size: 0.97rem; line-height: 1.65; overflow-wrap: anywhere; }
.b-cmt-body a { color: var(--cyan); text-decoration: underline; }
.b-reply-btn { margin-top: 10px; border: 0; background: none; color: var(--cyan); font: 600 0.84rem "Inter", sans-serif; cursor: pointer; padding: 0; }
.b-reply-btn:hover { text-decoration: underline; }
.b-replies { display: grid; gap: 12px; margin-left: 56px; padding-left: 18px; border-left: 2px solid var(--border); }
.b-replies .b-cmt-av { width: 36px; height: 36px; font-size: 0.9rem; }
.b-cmt-none { color: var(--muted); margin-bottom: 26px; }
.b-cmt-form { padding: 32px; }
.b-cmt-form h3 { font-size: 1.3rem; margin-bottom: 6px; }
.b-cmt-note { color: var(--muted); font-size: 0.88rem; margin-bottom: 22px; }
.b-cmt-form textarea { min-height: 130px; }
.b-replying { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; padding: 10px 14px; border-radius: 12px; background: var(--surface-2); font-size: 0.9rem; }
.b-replying[hidden] { display: none; }
.b-replying button { border: 0; background: none; color: var(--pink); font: 600 0.85rem "Inter", sans-serif; cursor: pointer; }
.b-cmt-form .form-status.ok { color: #22c55e; }
.b-cmt-form button[disabled] { opacity: 0.7; cursor: progress; }

/* ---------- İlgili yazılar ---------- */
.b-related { padding: 30px 0 100px; }
.b-related h2 { font-size: 1.6rem; margin-bottom: 24px; text-align: center; }
.b-mini { display: flex; gap: 14px; align-items: center; padding: 12px; border-radius: 18px; border: 1px solid var(--border); background: var(--surface); transition: border-color 0.2s, transform 0.3s var(--ease); }
.b-mini:hover { border-color: var(--border-hover); transform: translateY(-3px); }
.b-mini-img { flex: none; width: 96px; aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: var(--surface-2); display: grid; place-items: center; }
.b-mini-img img { width: 100%; height: 100%; object-fit: cover; }
.b-mini-img img.ph { width: 44px; height: 44px; object-fit: contain; }
.b-mini-body { display: grid; gap: 3px; min-width: 0; }
.b-mini-body small { font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--cyan); }
.b-mini-body b { font-family: "Sora", sans-serif; font-size: 0.95rem; line-height: 1.3; }
.b-mini-body time { font-size: 0.78rem; color: var(--muted); }

/* ---------- Bildirim ---------- */
.b-toast { position: fixed; left: 50%; bottom: 28px; z-index: 80; translate: -50% 0; padding: 12px 18px; border-radius: 14px; font-size: 0.92rem; font-weight: 600; color: #fff; background: #16a34a; box-shadow: var(--shadow); animation: bToast 0.4s var(--ease); max-width: calc(100% - 32px); }
.b-toast.err { background: #dc2626; }
@keyframes bToast { from { opacity: 0; translate: -50% 20px; } }

:root[data-theme="light"] .b-prose pre { background: #0f1636; }
:root[data-theme="light"] .b-cmt.is-team .b-cmt-av { background: #fff; box-shadow: 0 0 0 1px var(--border); }

@media (max-width: 1000px) {
  .b-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .b-card-big { grid-template-columns: 1fr; }
  .b-card-big .b-card-img { min-height: 0; aspect-ratio: 16 / 9; }
  .b-react-list { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .b-post { padding-top: 120px; }
  .b-grid { grid-template-columns: 1fr; gap: 18px; }
  .b-card-big .b-card-body { padding: 22px 24px 24px; }
  .b-prose { font-size: 1.02rem; }
  .b-cover img { border-radius: 18px; }
  .b-react { padding: 22px 16px; }
  .b-react-list { gap: 8px; }
  .b-react-btn .emo { font-size: 1.7rem; }
  .b-prevnext { grid-template-columns: 1fr; }
  .b-prevnext a.nx { text-align: left; }
  .b-replies { margin-left: 18px; padding-left: 12px; }
  .b-cmt { padding: 14px; gap: 10px; }
  .b-cmt-form { padding: 22px 18px; }
  .b-share-row { justify-content: center; text-align: center; }
}
@media (prefers-reduced-motion: reduce) {
  .b-card, .b-card-img img, .b-react-btn, .b-react-btn .emo, .b-sh, .b-mini { transition: none; }
  .b-react-btn.pop .emo { animation: none; }
}

/* ---------- Ana sayfa: son yazılar (index.php) ---------- */
.home-blog .section-head { margin-bottom: 50px; }
.home-blog-more { display: flex; justify-content: center; margin-top: 40px; }
.home-blog .b-grid { grid-template-columns: repeat(auto-fit, minmax(280px, 380px)); justify-content: center; }
@media (max-width: 760px) { .home-blog .b-grid { grid-template-columns: 1fr; } }

/* ---------- Onay bekleyen yorum (yalnızca yazana görünür; bkz. blog.js "Onay bekleyen kendi yorumlarım") ---------- */
.b-cmt.is-pending { opacity: 0.55; border-style: dashed; transition: opacity 0.2s; }
.b-cmt.is-pending:hover, .b-cmt.is-pending:focus-within { opacity: 0.8; }
.b-pending { font-size: 0.68rem; font-weight: 700; padding: 2px 8px; border-radius: 999px; color: #f59e0b; background: rgba(245, 158, 11, 0.14); border: 1px solid rgba(245, 158, 11, 0.35); }
.b-pending-note { margin-top: 8px; font-size: 0.8rem; color: var(--muted); font-style: italic; }
