/* ─────────────────────────────────────────────────────────────
   uzeyir.net — site stylesheet
   minimal, akışkan, sticky sidebar, light/dark
   ───────────────────────────────────────────────────────────── */

/* ─── Tokens (light) ─── */
:root {
  --bg:           #fafaf7;
  --bg-elev:      #ffffff;
  --ink:          #15171a;
  --ink-strong:   #0b0d10;
  --muted:        #5b6168;
  --rule:         #e7e5dd;
  --accent:       #3a5a40;
  --accent-soft:  #d6e1d8;
  --shadow:       0 1px 2px rgba(15,17,20,.04), 0 8px 24px rgba(15,17,20,.06);
  --radius:       14px;
  --radius-sm:    8px;
  --maxw:         1180px;
  --gap:          clamp(1rem, 2vw, 1.75rem);
  --font-sans:    'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --font-serif:   'Fraunces', ui-serif, Georgia, 'Times New Roman', serif;
}

/* ─── Tokens (dark) ─── */
@media (prefers-color-scheme: dark) {
  :root[data-theme="auto"] {
    --bg:          #0e1114;
    --bg-elev:     #14181d;
    --ink:         #ecedef;
    --ink-strong:  #ffffff;
    --muted:       #8b9199;
    --rule:        #1f242b;
    --accent:      #9bbfa3;
    --accent-soft: #1c2a22;
    --shadow:      0 1px 2px rgba(0,0,0,.5), 0 8px 24px rgba(0,0,0,.45);
  }
}
:root[data-theme="dark"] {
  --bg:          #0e1114;
  --bg-elev:     #14181d;
  --ink:         #ecedef;
  --ink-strong:  #ffffff;
  --muted:       #8b9199;
  --rule:        #1f242b;
  --accent:      #9bbfa3;
  --accent-soft: #1c2a22;
  --shadow:      0 1px 2px rgba(0,0,0,.5), 0 8px 24px rgba(0,0,0,.45);
}

/* ─── Reset & base ─── */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, video { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
a:hover, a:focus-visible { color: var(--accent); }
button { font: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

h1, h2, h3, h4 {
  font-family: var(--font-serif);
  color: var(--ink-strong);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 0 0 .6em;
}
h1 { font-size: clamp(2rem, 3.6vw, 2.85rem); }
h2 { font-size: clamp(1.5rem, 2.4vw, 2rem); }
h3 { font-size: 1.25rem; }
p  { margin: 0 0 1em; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 clamp(1rem, 3vw, 2rem);
}

.bare-list { list-style: none; padding: 0; margin: 0; }

/* ─── Header ─── */
.site-header {
  border-bottom: 1px solid var(--rule);
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: saturate(140%) blur(12px);
  position: sticky; top: 0; z-index: 50;
}
.site-header__inner {
  display: flex; align-items: center; gap: 1.25rem;
  height: 64px;
}
.brand {
  display: inline-flex; align-items: baseline; gap: .55rem;
  font-family: var(--font-serif);
  font-size: 1.15rem; color: var(--ink-strong);
}
.brand__mark {
  display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 28px;
  background: var(--ink-strong); color: var(--bg);
  border-radius: 8px;
  font-size: .85rem; font-weight: 600; font-family: var(--font-sans);
}
.brand__name { font-weight: 500; }
.brand__tagline { color: var(--muted); font-size: .9rem; }

.site-nav {
  margin-left: auto;
  display: inline-flex; align-items: center; gap: 1.25rem;
  font-size: .94rem;
}
.site-nav__links { display: inline-flex; align-items: center; gap: 1.25rem; }
.site-nav a { color: var(--muted); transition: color .15s ease; }
.site-nav a:hover { color: var(--ink); }
.site-nav__falanqes { color: var(--accent) !important; font-weight: 500; }

.site-header__actions { display: inline-flex; align-items: center; gap: .6rem; }

/* Home ikonu (masaüstünde metin gizli, mobil panelde görünür) */
.site-nav__home {
  display: inline-flex; align-items: center; gap: .4rem;
  color: var(--muted);
}
.site-nav__home:hover { color: var(--ink); }
.site-nav__home svg { display: block; }
.site-nav__home-label { display: none; }

/* Dil menüsü (yalnızca globe ikonu → açılır menü) */
.lang-menu { position: relative; }
.lang-menu__btn {
  width: 36px; height: 36px;
  display: inline-flex; align-items: center; justify-content: center;
  background: transparent;
  border: 1px solid var(--rule);
  border-radius: 999px;
  color: var(--ink);
  cursor: pointer;
  transition: background .15s ease, border-color .15s ease;
}
.lang-menu__btn:hover { background: var(--bg-elev); border-color: var(--ink); }
.lang-menu__btn svg { display: block; }
.lang-menu__list[hidden] { display: none; }
.lang-menu__list {
  position: absolute; top: calc(100% + .5rem); right: 0;
  min-width: 148px;
  display: flex; flex-direction: column;
  background: var(--bg-elev);
  border: 1px solid var(--rule);
  border-radius: 12px;
  box-shadow: var(--shadow);
  padding: .35rem;
  z-index: 60;
}
.lang-menu__list a {
  padding: .55rem .7rem;
  border-radius: 8px;
  font-size: .9rem;
  color: var(--ink);
  transition: background .12s ease;
}
.lang-menu__list a:hover { background: var(--bg); }
.lang-menu__list a[aria-current="true"] { color: var(--accent); font-weight: 600; }

/* Hamburger — masaüstünde gizli, mobilde kategorileri açar */
.nav-toggle {
  display: none;
  width: 36px; height: 36px;
  flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  background: transparent;
  border: 1px solid var(--rule);
  border-radius: 999px;
  color: var(--ink);
  cursor: pointer;
  transition: background .15s ease, border-color .15s ease;
}
.nav-toggle:hover { background: var(--bg-elev); border-color: var(--ink); }
.nav-toggle__bar {
  display: block; width: 16px; height: 2px;
  background: currentColor; border-radius: 2px;
  transition: transform .2s ease, opacity .2s ease;
}
.site-header.is-nav-open .nav-toggle__bar:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.site-header.is-nav-open .nav-toggle__bar:nth-child(2) { opacity: 0; }
.site-header.is-nav-open .nav-toggle__bar:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

.theme-toggle {
  width: 36px; height: 36px;
  background: transparent;
  border: 1px solid var(--rule);
  border-radius: 999px;
  color: var(--ink);
  display: inline-flex; align-items: center; justify-content: center;
  transition: background .15s ease, border-color .15s ease;
}
.theme-toggle:hover { background: var(--bg-elev); border-color: var(--ink); }
.theme-toggle__sun, .theme-toggle__moon { display: none; }
:root[data-theme="dark"] .theme-toggle__sun,
:root[data-theme="auto"] .theme-toggle__sun { display: inline; }
:root[data-theme="light"] .theme-toggle__moon { display: inline; }
@media (prefers-color-scheme: dark) {
  :root[data-theme="auto"] .theme-toggle__sun { display: none; }
  :root[data-theme="auto"] .theme-toggle__moon { display: inline; }
}

/* ─── Mobil header: kategoriler hamburger panelinde, falanqes görünür ─── */
@media (max-width: 640px) {
  .site-header__inner { gap: .5rem; }
  .nav-toggle { display: inline-flex; }
  .site-nav { gap: .75rem; }

  .site-nav__links {
    position: absolute;
    top: 64px; left: 0; right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: .25rem clamp(1rem, 3vw, 2rem) .5rem;
    background: var(--bg);
    border-bottom: 1px solid var(--rule);
    box-shadow: var(--shadow);
    /* kapalı durum */
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    pointer-events: none;
    transition: opacity .18s ease, transform .18s ease, visibility .18s;
  }
  .site-header.is-nav-open .site-nav__links {
    opacity: 1; visibility: visible; transform: none; pointer-events: auto;
  }
  .site-nav__links a {
    padding: .8rem .2rem;
    font-size: 1rem;
    color: var(--ink);
    border-bottom: 1px solid var(--rule);
  }
  .site-nav__links a:last-child { border-bottom: 0; }
  /* Mobil açılır menüde home ikonu yanında etiket görünsün */
  .site-nav__home-label { display: inline; }
}

/* ─── Layout (content + sticky sidebar) ─── */
.site-main { padding: clamp(1.5rem, 4vw, 3rem) 0 4rem; }
.layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: clamp(1.5rem, 3vw, 3rem);
  align-items: start;
}
.layout-content { min-width: 0; }
.layout-sidebar { position: sticky; top: 88px; }

@media (max-width: 980px) {
  .layout { grid-template-columns: 1fr; }
  .layout-sidebar { position: static; }
}

/* ─── Featured (öne çıkan) ─── */
.featured {
  display: grid;
  gap: var(--gap);
  margin-bottom: clamp(1.5rem, 3vw, 2.5rem);
}
.featured__media {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--bg-elev);
  box-shadow: var(--shadow);
}
.featured__media img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .8s cubic-bezier(.2,.7,.2,1);
}
.featured__media:hover img { transform: scale(1.03); }
.featured__placeholder {
  width: 100%; height: 100%;
  background:
    linear-gradient(135deg, var(--accent-soft), transparent 60%),
    repeating-linear-gradient(45deg, var(--rule) 0 12px, transparent 12px 24px);
}
.featured__badge {
  position: absolute; top: 12px; left: 12px;
  background: var(--bg); color: var(--ink-strong);
  font-size: .75rem; font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
  letter-spacing: .04em; text-transform: lowercase;
  border: 1px solid var(--rule);
}
.featured__title {
  font-size: clamp(1.75rem, 3.5vw, 2.65rem);
  margin: .2em 0 .35em;
}
.featured__title a:hover { color: var(--ink-strong); text-decoration: underline; text-underline-offset: 4px; }
.featured__excerpt {
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 60ch;
}
.featured__foot {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 1rem;
  padding-top: .25rem;
}

/* ─── Kicker (kategori chip) ─── */
.kicker {
  display: inline-block;
  font-size: .75rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: .35rem;
}

/* ─── Section divider ─── */
.section-divider {
  display: flex; align-items: center; gap: 1rem;
  margin: 2rem 0 1.25rem;
  color: var(--muted);
  font-family: var(--font-serif);
  font-size: 1.1rem;
}
.section-divider::before, .section-divider::after {
  content: ''; height: 1px; flex: 1;
  background: var(--rule);
}
.section-divider span { padding: 0 .5rem; }

/* ─── Post grid ─── */
.post-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--gap);
}
@media (max-width: 620px) {
  .post-grid { grid-template-columns: 1fr; }
  .brand__tagline { display: none; }
}

.post-card {
  display: flex; flex-direction: column;
  background: var(--bg-elev);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.post-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  border-color: color-mix(in srgb, var(--ink) 18%, var(--rule));
}
.post-card__media {
  display: block; aspect-ratio: 16 / 10;
  overflow: hidden; background: var(--bg);
}
.post-card__media img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .6s ease;
}
.post-card:hover .post-card__media img { transform: scale(1.04); }
.post-card__placeholder {
  width: 100%; height: 100%;
  background: linear-gradient(135deg, var(--accent-soft), transparent),
              repeating-linear-gradient(45deg, var(--rule) 0 8px, transparent 8px 16px);
}
.post-card__body { padding: 1rem 1.15rem 1.15rem; display: flex; flex-direction: column; gap: .4rem; flex: 1; }
.post-card__cat {
  font-size: .72rem; letter-spacing: .12em; text-transform: uppercase;
  color: var(--accent); font-weight: 600;
}
.post-card__title {
  font-size: 1.2rem; margin: .15rem 0 .25rem;
}
.post-card__title a:hover { text-decoration: underline; text-underline-offset: 3px; color: var(--ink-strong); }
.post-card__excerpt {
  color: var(--muted); font-size: .95rem;
  display: -webkit-box; -webkit-line-clamp: 3; line-clamp: 3;
  -webkit-box-orient: vertical; overflow: hidden;
  margin: 0 0 .75rem;
}
.post-card__foot {
  margin-top: auto;
  display: flex; align-items: center; justify-content: space-between;
  padding-top: .35rem;
}
.post-card__date { color: var(--muted); font-size: .85rem; }

/* ─── Buttons ─── */
.btn {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .6rem 1rem;
  background: var(--ink-strong);
  color: var(--bg);
  border: 1px solid var(--ink-strong);
  border-radius: 999px;
  font-size: .9rem; font-weight: 500;
  text-decoration: none;
  transition: transform .15s ease, background .15s ease;
}
.btn:hover { transform: translateY(-1px); color: var(--bg); }
.btn--ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--rule);
  padding: .35rem .75rem;
  font-size: .82rem;
}
.btn--ghost:hover {
  border-color: var(--ink);
  background: var(--bg-elev);
  color: var(--ink-strong);
}

/* ─── Sidebar cards ─── */
.sidebar { display: flex; flex-direction: column; gap: 1rem; }
.card {
  background: var(--bg-elev);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  padding: 1rem 1.15rem;
}
.card__title {
  font-size: .78rem; letter-spacing: .14em; text-transform: uppercase;
  color: var(--muted); font-weight: 600; font-family: var(--font-sans);
  margin: 0 0 .85rem;
}
.cat-list, .recent-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; }
.cat-list li + li, .recent-list li + li { border-top: 1px solid var(--rule); }
.cat-list a, .recent-list a {
  display: flex; align-items: center; justify-content: space-between;
  padding: .65rem 0; gap: 1rem;
  color: var(--ink);
}
.cat-list a:hover, .recent-list a:hover { color: var(--accent); }
.cat-list__count {
  font-size: .8rem;
  color: var(--muted);
  background: var(--bg);
  padding: 0 .55rem;
  border-radius: 999px;
  border: 1px solid var(--rule);
  min-width: 28px; text-align: center;
}
.recent-list__title {
  font-size: .95rem;
  display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2;
  -webkit-box-orient: vertical; overflow: hidden;
}
.recent-list__date { font-size: .78rem; color: var(--muted); white-space: nowrap; }

.tag-cloud { display: flex; flex-wrap: wrap; gap: .4rem; }
.chip {
  display: inline-block;
  padding: .25rem .65rem;
  font-size: .8rem;
  border: 1px solid var(--rule);
  border-radius: 999px;
  color: var(--muted);
  background: var(--bg);
}
.chip:hover { color: var(--ink); border-color: var(--ink); }

.contact-list li {
  display: flex; align-items: center; gap: .55rem;
  padding: .35rem 0;
  font-size: .92rem;
}
.contact-list a:hover { color: var(--accent); }

.card--falanqes { padding: 0; overflow: hidden; }
.falanqes-promo {
  display: block; padding: 1.1rem 1.15rem;
  background:
    radial-gradient(120% 80% at 100% 0, rgba(168,50,50,.18), transparent 60%),
    linear-gradient(180deg, #f3eee5, #ede4d3);
  color: #1c1a17;
  position: relative;
}
:root[data-theme="dark"] .falanqes-promo,
:root[data-theme="auto"] .falanqes-promo {
  background:
    radial-gradient(120% 80% at 100% 0, rgba(168,50,50,.2), transparent 60%),
    linear-gradient(180deg, #1d1916, #15110d);
  color: #ece6d8;
}
.falanqes-promo__label {
  font-size: .7rem; letter-spacing: .14em; text-transform: uppercase; opacity: .7;
}
.falanqes-promo__title {
  display: block;
  font-family: var(--font-serif);
  font-size: 1.6rem;
  letter-spacing: .04em;
  font-weight: 700;
  margin-top: .25rem;
}
.falanqes-promo__sub {
  display: block;
  margin-top: .35rem;
  font-size: .85rem;
  opacity: .85;
}

/* ─── Page heads (kategori) ─── */
.page-head { margin: 0 0 1.5rem; }
.page-head__title { margin: 0 0 .35rem; }
.page-head__sub { color: var(--muted); }

/* ─── Yazı detay ─── */
.post__head { margin-bottom: 1.5rem; }
.post__title { font-size: clamp(2rem, 4vw, 3rem); margin: .25rem 0 .65rem; }
.post__meta  { color: var(--muted); font-size: .92rem; }
.post__hero  {
  margin: 0 0 2rem;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: var(--bg-elev);
}
.post__hero img { width: 100%; height: 100%; object-fit: cover; }

.content { font-size: 1.05rem; }
.content p { margin: 0 0 1.1em; }
.content h2, .content h3, .content h4 { margin-top: 2em; }
.content blockquote {
  margin: 1.5em 0;
  padding: .25rem 0 .25rem 1.25rem;
  border-left: 3px solid var(--accent);
  color: var(--ink);
  font-family: var(--font-serif);
  font-size: 1.2rem;
}
.content blockquote cite {
  display: block;
  margin-top: .5em;
  font-style: normal;
  font-size: .85rem;
  color: var(--muted);
  font-family: var(--font-sans);
}
.content ul, .content ol { padding-left: 1.25rem; margin: 0 0 1em; }
.content li { margin: .25em 0; }
.content pre {
  background: var(--bg-elev);
  border: 1px solid var(--rule);
  padding: 1rem;
  border-radius: var(--radius-sm);
  overflow: auto;
  font-size: .9rem;
}
.content code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .92em; }
.content :not(pre) > code {
  padding: .1em .35em;
  border-radius: 4px;
  background: var(--accent-soft);
  color: var(--ink-strong);
}
.content-image {
  margin: 1.5em auto;
  display: block;
  max-width: 100%;
}
.content-image img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius-sm);
}
.content-image.align-left   { margin-left: 0;     margin-right: auto; }
.content-image.align-right  { margin-left: auto;  margin-right: 0; }
.content-image.align-center { margin-left: auto;  margin-right: auto; }
.content-image.stretched    { width: 100% !important; }
.content-image figcaption {
  font-size: .85rem; color: var(--muted);
  text-align: center; margin-top: .35em;
}
.content-delimiter {
  border: 0; height: 1px; background: var(--rule); margin: 2em auto; max-width: 240px;
}

/* İçerik içi buton (Editor.js "Buton" bloğu) */
.content-btn-wrap { margin: 1.6em 0; }
.content-btn-wrap.align-center { text-align: center; }
.content-btn-wrap.align-right  { text-align: right; }
.content-btn-wrap .content-btn {
  display: inline-flex; align-items: center; gap: .45rem;
  padding: .72rem 1.5rem;
  border-radius: 999px;
  font-size: .95rem; font-weight: 500;
  text-decoration: none;
  transition: transform .18s ease, background .18s ease, color .18s ease, border-color .18s ease;
}
.content-btn-wrap .content-btn--solid {
  background: var(--ink-strong); color: var(--bg); border: 1px solid var(--ink-strong);
}
.content-btn-wrap .content-btn--solid:hover {
  transform: translateY(-1px); background: var(--accent); border-color: var(--accent); color: #fff;
}
.content-btn-wrap .content-btn--outline {
  background: transparent; color: var(--ink-strong); border: 1px solid var(--rule);
}
.content-btn-wrap .content-btn--outline:hover {
  transform: translateY(-1px); border-color: var(--ink-strong); color: var(--ink-strong);
}

/* İçerik videosu / embed — responsive 16:9 çerçeve */
.content-video { margin: 1.8em 0; }
.content-video__frame,
.content-embed {
  position: relative; width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius); overflow: hidden;
  background: #000; box-shadow: var(--shadow);
}
.content-video__frame iframe,
.content-embed iframe {
  position: absolute; inset: 0; width: 100%; height: 100%; border: 0;
}
.content-video figcaption {
  margin-top: .6rem; text-align: center;
  color: var(--muted); font-size: .9rem;
}

.post__tags { margin-top: 2rem; display: flex; flex-wrap: wrap; gap: .4rem; }

/* ─── Yorumlar ─── */
.comments { margin-top: 3rem; padding-top: 2rem; border-top: 1px solid var(--rule); }
.comments__title { font-size: 1.5rem; margin-bottom: 1rem; }
.comments__list { list-style: none; padding: 0; margin: 0 0 2rem; display: flex; flex-direction: column; gap: 1rem; }
.comment {
  background: var(--bg-elev);
  border: 1px solid var(--rule);
  border-radius: var(--radius-sm);
  padding: .9rem 1rem;
}
.comment__head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: .35rem; gap: .5rem; }
.comment__author { font-family: var(--font-serif); }
.comment__body { margin: 0; font-size: .96rem; color: var(--ink); }

.comment-form { background: var(--bg-elev); border: 1px solid var(--rule); border-radius: var(--radius); padding: 1.25rem; }
.comment-form h3 { margin-top: 0; }
.form-row { display: flex; flex-direction: column; gap: 1rem; margin-bottom: 1rem; }
.form-row--2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 540px) { .form-row--2 { grid-template-columns: 1fr; } }
.comment-form label { display: flex; flex-direction: column; font-size: .85rem; color: var(--muted); gap: .35rem; }
.comment-form input, .comment-form textarea {
  font: inherit; color: var(--ink);
  background: var(--bg);
  border: 1px solid var(--rule);
  border-radius: var(--radius-sm);
  padding: .65rem .8rem;
  width: 100%;
  transition: border-color .15s ease;
}
.comment-form input:focus, .comment-form textarea:focus {
  outline: none; border-color: var(--accent);
}
.comment-form textarea { resize: vertical; min-height: 110px; }

.alert { padding: .75rem 1rem; border-radius: var(--radius-sm); margin-bottom: 1rem; font-size: .92rem; }
.alert--ok  { background: var(--accent-soft); color: var(--ink-strong); border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent); }
.alert--err { background: #fbe9e7; color: #5a1f17; border: 1px solid #f1c4be; }
:root[data-theme="dark"] .alert--err,
:root[data-theme="auto"] .alert--err { background: #2b1715; color: #f4c5be; border-color: #4a221b; }

/* ─── 404 ─── */
.page-404 { padding: 3rem 0; text-align: center; }
.page-404 h1 { margin-bottom: .5rem; }

/* ─── Footer ─── */
.site-footer { border-top: 1px solid var(--rule); padding: 2.5rem 0; margin-top: 4rem; background: var(--bg-elev); }
.site-footer__inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 2rem;
}
@media (max-width: 720px) { .site-footer__inner { grid-template-columns: 1fr; } }
.site-footer h4 { font-size: .82rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-family: var(--font-sans); font-weight: 600; margin: 0 0 .65rem; }
.site-footer__brand { font-family: var(--font-serif); font-size: 1.15rem; margin: 0 0 .25rem; }
.site-footer ul li { padding: .2rem 0; font-size: .92rem; }
.site-footer a:hover { color: var(--accent); }

/* ─── Sayfa geçişleri: JS destekli yumuşak crossfade (tüm tarayıcılarda) ───
   Giren içerik hafifçe yükselerek belirir; iç linke tıklayınca sayfa solarak
   çıkar (site.js `is-leaving` sınıfını ekler), sonra navigasyon olur.
   Sert kesme / beyaz flash yerine kibar bir geçiş. */
@keyframes uz-page-in {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: no-preference) {
  .site-main { animation: uz-page-in .5s cubic-bezier(.16,1,.3,1) both; }
  body { transition: opacity .32s ease; }
  body.is-leaving { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

/* ─── Reading focus mode (yalnızca yazı detay) ───────────────
   has-reading: yazı detay açıldığında body'e eklenir
   is-focused : okuma odağı aktif (scroll / F / pill) */

/* İlerleme çubuğu — daima görünür, soluk; odakta belirginleşir */
.reading-progress {
  position: fixed; inset: 0 0 auto 0;
  height: 2px;
  background: var(--accent, #2f5a3a);
  transform-origin: left center;
  transform: scaleX(0);
  z-index: 60;
  opacity: .35;
  transition: opacity .25s ease;
  pointer-events: none;
  will-change: transform;
}
.has-reading.is-focused .reading-progress { opacity: 1; }

/* Odak butonu — temel (her iki varyant) */
.focus-pill {
  display: inline-flex; align-items: center; justify-content: center;
  background: color-mix(in srgb, var(--bg) 90%, transparent);
  color: var(--ink);
  border: 1px solid var(--rule);
  border-radius: 999px;
  cursor: pointer;
  transition: opacity .2s ease, transform .2s ease, background .2s ease, border-color .2s ease;
}
.focus-pill:hover { transform: translateY(-1px); border-color: var(--ink, #15171a); }
.focus-pill:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.focus-pill__icon--exit  { display: none; }
.focus-pill[aria-pressed="true"] .focus-pill__icon--enter { display: none; }
.focus-pill[aria-pressed="true"] .focus-pill__icon--exit  { display: inline; }

/* Sağ alt sabit pill */
.focus-pill--float {
  position: fixed; right: 1.25rem; bottom: 1.25rem;
  width: 42px; height: 42px;
  backdrop-filter: saturate(140%) blur(8px);
  box-shadow: 0 1px 2px rgba(0,0,0,.06), 0 8px 24px rgba(0,0,0,.08);
  z-index: 60;
  opacity: .55;
  will-change: transform, opacity;
}
.focus-pill--float:hover { opacity: 1; }
.focus-pill--float:focus-visible { opacity: 1; }
.has-reading.is-focused .focus-pill--float {
  opacity: .9; background: var(--ink); color: var(--bg); border-color: var(--ink);
}

/* Meta satırına gömülü pill — yazı başında "okumaya başla" tetikleyicisi */
.focus-pill--inline {
  width: 26px; height: 26px;
  margin-right: .55rem;
  vertical-align: -7px;
  background: transparent;
  border-color: var(--rule);
  color: var(--muted);
  opacity: .85;
}
.focus-pill--inline:hover { color: var(--ink); opacity: 1; background: var(--bg-elev); }
.focus-pill--inline .focus-pill__icon--enter,
.focus-pill--inline .focus-pill__icon--exit { width: 13px; height: 13px; }
.has-reading.is-focused .focus-pill--inline {
  background: var(--ink); color: var(--bg); border-color: var(--ink); opacity: 1;
}

/* Geçişler — kibar, koordineli (yalnızca yazı detayda transition aç).
   Ortak yumuşak easing: cubic-bezier(.22,1,.36,1) ("easeOutQuint" hissi). */
.has-reading .site-header {
  transition: transform .6s cubic-bezier(.16,1,.3,1), opacity .45s ease;
  will-change: transform, opacity;
}
.has-reading .layout-sidebar {
  /* sticky'i bozmaz — overflow yalnızca element üzerinde, ata sticky context'inde değil.
     Odakta yerinde erir: solma + hafif sağa kayma + blur (hepsi GPU-composited). */
  overflow: hidden;
  transform-origin: right top;
  transition: opacity .5s ease, transform .7s cubic-bezier(.16,1,.3,1), filter .5s ease;
  will-change: opacity, transform, filter;
}
.has-reading .layout-content {
  /* Grid kolonunu ANİMASYONLAMIYORUZ (asıl "sertlik" ve reflow jank'i oradaydı).
     Makale genişliği sabit kalır; odakta yalnızca transform ile yumuşakça ortaya
     süzülür → satırlar yeniden kırılmaz, metin zıplamaz. */
  transition: transform .7s cubic-bezier(.16,1,.3,1);
  will-change: transform;
}

/* Snap modu: alt sentinel tetiklemesi gibi ani geçişlerde transitions kapat,
   layout titremeden anında yerine otursun. JS bir frame sonra sınıfı kaldırır,
   böylece sonraki manuel/scroll geçişler yeniden yumuşak olur. */
.has-reading.is-snapping .site-header,
.has-reading.is-snapping .layout,
.has-reading.is-snapping .layout-sidebar,
.has-reading.is-snapping .layout-content,
.has-reading.is-snapping .reading-progress {
  transition: none !important;
}

/* ── Odak modu aktif: chrome geri çekilir, içerik tüm genişliği alır ── */
.has-reading.is-focused .site-header {
  transform: translateY(-100%);
  opacity: 0;
  pointer-events: none;
}
.has-reading.is-focused .layout-sidebar {
  opacity: 0;
  transform: translateX(26px) scale(.985);
  filter: blur(4px);
  pointer-events: none;
}
/* Makale genişliği DEĞİŞMEDEN (reflow yok) container ortasına süzülür.
   Sağa kayma = (sidebar kolonu 320px + gap) / 2. */
.has-reading.is-focused .layout-content {
  transform: translateX(calc((320px + clamp(1.5rem, 3vw, 3rem)) / 2));
}

/* Mobil: zaten tek kolon, sidebar yok — makale kaydırılmaz, sadece header gizlenir */
@media (max-width: 980px) {
  .has-reading.is-focused .layout-content { transform: none; }
  .focus-pill--float { right: 1rem; bottom: 1rem; width: 40px; height: 40px; }
}

/* ─── Cookie banner (alttan slide) ───────────────────────── */
.cookie-banner {
  position: fixed; left: 0; right: 0; bottom: 0;
  z-index: 70;
  padding: .85rem clamp(1rem, 3vw, 1.5rem);
  background: var(--bg-elev, #fff);
  border-top: 1px solid var(--rule);
  box-shadow: 0 -4px 24px rgba(0,0,0,.06);
  transform: translateY(100%);
  transition: transform .35s cubic-bezier(.4,.0,.2,1);
}
.cookie-banner.is-shown { transform: translateY(0); }
.cookie-banner.is-dismissed { transform: translateY(100%); }
.cookie-banner__inner {
  max-width: var(--maxw, 1180px);
  margin: 0 auto;
  display: flex; align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}
.cookie-banner__msg {
  margin: 0;
  flex: 1 1 320px;
  font-size: .88rem;
  color: var(--ink-soft);
  line-height: 1.5;
}
.cookie-banner__msg a { color: var(--accent); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.cookie-banner__actions { display: inline-flex; gap: .5rem; flex-wrap: wrap; }
.cookie-banner__btn {
  padding: .5rem 1rem;
  border-radius: 8px;
  font: inherit; font-size: .85rem; font-weight: 500;
  cursor: pointer;
  border: 1px solid var(--ink-strong, #15171a);
  background: var(--ink-strong, #15171a);
  color: var(--bg, #fafaf7);
  transition: filter .15s ease, transform .15s ease;
}
.cookie-banner__btn:hover { filter: brightness(1.1); transform: translateY(-1px); }
.cookie-banner__btn--ghost {
  background: transparent;
  color: var(--ink, #15171a);
}
.cookie-banner__btn--ghost:hover { background: var(--bg, #fafaf7); }

/* ─── Footer legal ───────────────────────────────────────── */
.site-footer__legal { margin-top: .5rem; }
.site-footer__legal a { color: var(--muted); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.site-footer__legal a:hover { color: var(--ink); }
.site-footer__legal span { margin: 0 .35rem; opacity: .5; }

/* ─── Legal article (gizlilik, çerez) ────────────────────── */
.legal {
  max-width: 70ch;
  margin: 0 auto;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--ink-soft);
}
.legal h1 { font-family: var(--font-serif); font-size: clamp(1.8rem, 3vw, 2.4rem); color: var(--ink); margin: 0 0 .25rem; }
.legal h2 { font-family: var(--font-serif); font-size: 1.2rem; color: var(--ink); margin: 2rem 0 .5rem; font-weight: 500; }
.legal p, .legal ul, .legal ol { margin: 0 0 1em; }
.legal ul, .legal ol { padding-left: 1.25rem; }
.legal li { margin: .35em 0; }
.legal code { background: var(--accent-soft); padding: .1em .35em; border-radius: 4px; font-size: .9em; }
.legal a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.legal-table {
  width: 100%; border-collapse: collapse;
  margin: 1rem 0;
  font-size: .9rem;
}
.legal-table th, .legal-table td {
  border: 1px solid var(--rule);
  padding: .55rem .75rem;
  text-align: left; vertical-align: top;
}
.legal-table th { background: var(--bg-elev, #fff); font-weight: 600; color: var(--ink); }
