/* Almanak — mobil öncelikli, açık/koyu temalı stil dosyası. Harici yazı tipi kullanmaz. */

:root {
  --bg: #f6f3ec;
  --surface: #fffdf8;
  --surface-2: #efe9dd;
  --ink: #1c1e21;
  --muted: #5b5f65;
  --line: #e1d9ca;
  --line-strong: #cbbfa9;
  --accent: #9f2f25;
  --accent-soft: #f3e2dc;
  --accent-ink: #ffffff;
  --focus: #1f5fd1;
  --mark: #ffe58a;

  --c-pdf: #b3261e;
  --c-img: #2c7a3f;
  --c-txt: #54595f;
  --c-doc: #1f5fbf;
  --c-tif: #946200;
  --c-other: #6b5ca5;

  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgb(40 30 10 / 5%), 0 6px 20px rgb(40 30 10 / 5%);
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --moon: inline-block;
  --sun: none;
  color-scheme: light;
}

/* Varsayılan tema aydınlıktır; koyu tema yalnızca ziyaretçi düğmeye basınca açılır. */
:root[data-theme="dark"] {
  --bg: #131416;
  --surface: #1b1d20;
  --surface-2: #24272b;
  --ink: #ebe8e2;
  --muted: #a5a9ae;
  --line: #2e3136;
  --line-strong: #43474d;
  --accent: #ff9f90;
  --accent-soft: #3a2320;
  --accent-ink: #1a0d0b;
  --focus: #8ab4ff;
  --mark: #6b5510;
  --c-pdf: #ff8a80;
  --c-img: #7fd08f;
  --c-txt: #b8bcc2;
  --c-doc: #8ab4ff;
  --c-tif: #f1c35c;
  --c-other: #c3b5ff;
  --shadow: 0 1px 2px rgb(0 0 0 / 30%), 0 6px 20px rgb(0 0 0 / 25%);
  --moon: none;
  --sun: inline-block;
  color-scheme: dark;
}

/* ---------- Temel ---------- */

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 5.5rem;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.55 var(--sans);
  -webkit-font-smoothing: antialiased;
}

img, iframe { max-width: 100%; }
h1, h2, h3, h4 { margin: 0; line-height: 1.2; }
p { margin: 0; }
ol, ul { margin: 0; padding: 0; list-style: none; }
button, input { font: inherit; color: inherit; }

a { color: inherit; text-decoration-color: var(--line-strong); text-underline-offset: .18em; }
a:hover { color: var(--accent); text-decoration-color: currentColor; }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 6px; }

mark { background: var(--mark); color: inherit; padding: 0 .12em; border-radius: 3px; }

[hidden] { display: none !important; }

.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

.i {
  width: 1.25em; height: 1.25em; flex: none;
  fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
  vertical-align: middle;
}

.wrap {
  width: 100%;
  max-width: 76rem;
  margin-inline: auto;
  padding-inline: max(1rem, env(safe-area-inset-left), env(safe-area-inset-right));
}

@media (min-width: 48rem) {
  .wrap { padding-inline: 2rem; }
}

.skip-link {
  position: absolute; left: 1rem; top: -4rem; z-index: 100;
  background: var(--ink); color: var(--bg); padding: .6rem 1rem; border-radius: var(--radius-sm);
}
.skip-link:focus { top: 1rem; color: var(--bg); }

.muted { color: var(--muted); }

/* ---------- Butonlar ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .45rem;
  min-height: 2.75rem; padding: .55rem 1.1rem;
  border: 1px solid transparent; border-radius: 999px;
  font-weight: 600; font-size: .95rem; line-height: 1.2; text-decoration: none;
  cursor: pointer; transition: background-color .15s, border-color .15s, color .15s;
}
.btn-sm { min-height: 2.5rem; padding: .4rem .85rem; font-size: .88rem; }
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { color: var(--accent-ink); filter: brightness(1.08); }
.btn-ghost { background: var(--surface); border-color: var(--line); color: var(--ink); }
.btn-ghost:hover { border-color: var(--line-strong); color: var(--ink); background: var(--surface-2); }

.icon-btn {
  display: inline-grid; place-items: center; flex: none;
  width: 2.75rem; height: 2.75rem; padding: 0;
  border: 1px solid var(--line); border-radius: 999px;
  background: var(--surface); color: var(--ink); cursor: pointer;
}
.icon-btn:hover { background: var(--surface-2); }

.theme-icon-moon { display: var(--moon); }
.theme-icon-sun { display: var(--sun); }

/* ---------- Üst bölüm ---------- */

.site-header {
  position: relative; z-index: 20;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex; flex-wrap: wrap; align-items: center; gap: .6rem 1rem;
  padding-block: .6rem;
}

.brand {
  display: flex; align-items: center; gap: .65rem; min-width: 0;
  margin-right: auto; text-decoration: none; color: var(--ink);
}
.brand:hover { color: var(--ink); }
.brand-mark {
  display: grid; place-items: center; width: 2.5rem; height: 2.5rem; flex: none;
  border-radius: 12px; background: var(--accent); color: var(--accent-ink);
}
.brand-mark .i { width: 1.35rem; height: 1.35rem; }
.brand-text { display: flex; flex-direction: column; min-width: 0; }
.brand-name { font-family: var(--serif); font-size: 1.3rem; font-weight: 700; letter-spacing: -.01em; line-height: 1.1; }
.brand-sub { font-size: .78rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.header-search {
  order: 3; flex: 1 1 100%;
  display: flex; align-items: center; gap: .5rem;
  min-height: 2.75rem; padding-inline: .9rem;
  background: var(--surface); border: 1px solid var(--line); border-radius: 999px;
}
.header-search:focus-within { border-color: var(--focus); box-shadow: 0 0 0 3px color-mix(in srgb, var(--focus) 25%, transparent); }
.header-search .i { color: var(--muted); }
.header-search input { flex: 1; min-width: 0; border: 0; background: transparent; padding: .5rem 0; outline: none; }

@media (min-width: 48rem) {
  .site-header { position: sticky; top: 0; }
  .header-inner { flex-wrap: nowrap; padding-block: .75rem; }
  .header-search { order: 0; flex: 0 1 22rem; }
}

/* ---------- İçerik ---------- */

.site-main { flex: 1; padding-block: 1.25rem 3.5rem; outline: none; }

@media (min-width: 48rem) {
  .site-main { padding-block: 2rem 5rem; }
}

.crumbs { margin-bottom: 1.1rem; font-size: .9rem; color: var(--muted); }
.crumbs ol { display: flex; flex-wrap: wrap; align-items: center; gap: .2rem; }
.crumbs li { display: inline-flex; align-items: center; min-width: 0; }
.crumbs li + li::before { content: "›"; margin-inline: .35rem; color: var(--line-strong); }
.crumbs a { color: var(--muted); text-decoration: none; padding-block: .35rem; }
.crumbs a:hover { color: var(--accent); text-decoration: underline; }
.crumbs [aria-current] { color: var(--ink); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 70vw; }

.eyebrow {
  margin-bottom: .45rem;
  font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: var(--accent);
}

.page-head { margin-bottom: 1.75rem; }
.page-title {
  font-family: var(--serif); font-weight: 700; letter-spacing: -.015em;
  font-size: clamp(1.9rem, 1.3rem + 2.6vw, 3rem);
  overflow-wrap: anywhere;
}
.page-title-date {
  display: block; margin-top: .35rem;
  font-family: var(--sans); font-size: clamp(1rem, .9rem + .5vw, 1.25rem); font-weight: 500;
  letter-spacing: 0; color: var(--muted);
}
.page-meta, .page-lead { margin-top: .6rem; color: var(--muted); }
.page-lead { font-size: 1.1rem; max-width: 42rem; }

.section { margin-top: 2.25rem; }
.section:first-child { margin-top: 0; }
.section-title {
  display: flex; align-items: baseline; gap: .5rem;
  margin-bottom: .9rem;
  font-family: var(--serif); font-size: clamp(1.25rem, 1.1rem + .6vw, 1.55rem); font-weight: 700;
}
.count {
  font-family: var(--sans); font-size: .8rem; font-weight: 600; color: var(--muted);
  background: var(--surface-2); padding: .1rem .5rem; border-radius: 999px;
}

.empty-state {
  padding: 2rem 1.25rem; text-align: center; color: var(--muted);
  background: var(--surface); border: 1px dashed var(--line-strong); border-radius: var(--radius);
}

/* ---------- Ana sayfa ---------- */

.hero {
  padding: 1.5rem 0 .5rem;
}
.hero-title {
  font-family: var(--serif); font-weight: 700; letter-spacing: -.02em;
  font-size: clamp(2.6rem, 1.6rem + 5vw, 4.75rem); line-height: 1;
}
.hero-lead { margin-top: .9rem; max-width: 44rem; font-size: clamp(1.02rem, .95rem + .35vw, 1.2rem); color: var(--muted); }

.search-box {
  display: flex; align-items: center; gap: .5rem;
  margin-top: 1.4rem; max-width: 44rem;
  padding: .35rem .35rem .35rem 1rem;
  background: var(--surface); border: 1px solid var(--line-strong); border-radius: 999px;
  box-shadow: var(--shadow);
}
.search-box:focus-within { border-color: var(--focus); box-shadow: 0 0 0 3px color-mix(in srgb, var(--focus) 22%, transparent); }
.search-box .i { color: var(--muted); }
.search-box input { flex: 1; min-width: 0; border: 0; background: transparent; outline: none; padding: .55rem 0; font-size: 1.02rem; }
.search-help { margin-top: 1rem; max-width: 44rem; }

.stats {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem;
  margin: 1.75rem 0 0;
}
.stat { padding: .85rem 1rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.stat dt { font-size: .78rem; color: var(--muted); }
.stat dd { margin: .15rem 0 0; font-family: var(--serif); font-size: clamp(1.35rem, 1.1rem + 1vw, 1.8rem); font-weight: 700; font-variant-numeric: tabular-nums; }

@media (min-width: 48rem) {
  .hero { padding-top: 2.5rem; }
  .stats { grid-template-columns: repeat(4, minmax(0, 1fr)); max-width: 52rem; }
}

.collections { display: grid; gap: 1rem; }
.collection {
  padding: 1.1rem; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow);
}
.collection-head { display: flex; gap: .85rem; align-items: flex-start; }
.collection-icon {
  display: grid; place-items: center; width: 2.6rem; height: 2.6rem; flex: none;
  border-radius: 12px; background: var(--accent-soft); color: var(--accent);
}
.collection-title { font-family: var(--serif); font-size: 1.3rem; }
.collection-title a { text-decoration: none; }
.collection-title a:hover { text-decoration: underline; }
.collection-meta { margin-top: .2rem; font-size: .88rem; color: var(--muted); }

.year-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(6.25rem, 1fr)); gap: .5rem;
  margin-top: 1rem;
}
.year {
  display: flex; flex-direction: column; gap: .1rem;
  padding: .65rem .75rem; min-height: 3.5rem;
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-sm);
  text-decoration: none; transition: border-color .15s, transform .15s;
}
.year:hover { border-color: var(--accent); color: var(--ink); transform: translateY(-1px); }
.year-name { font-family: var(--serif); font-weight: 700; font-size: 1.15rem; font-variant-numeric: tabular-nums; }
.year-count { font-size: .76rem; color: var(--muted); }

@media (min-width: 48rem) {
  .collection { padding: 1.5rem; }
}

/* ---------- Klasörler ---------- */

.folder-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr)); gap: .6rem; }
.folder-card {
  display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; column-gap: .65rem;
  align-items: center; height: 100%;
  padding: .8rem .9rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm);
  text-decoration: none; transition: border-color .15s;
}
.folder-card:hover { border-color: var(--accent); color: var(--ink); }
.folder-card .i { grid-row: span 2; color: var(--accent); width: 1.5rem; height: 1.5rem; }
.folder-name { font-weight: 650; overflow-wrap: anywhere; }
.folder-meta { font-size: .8rem; color: var(--muted); }

/* ---------- Kayıt listesi ---------- */

.records-head { display: grid; gap: .75rem; margin-bottom: .5rem; }
.records-head .section-title { margin-bottom: 0; }

.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.filter {
  display: flex; align-items: center; gap: .5rem; flex: 1 1 100%;
  min-height: 2.75rem; padding-inline: .9rem;
  background: var(--surface); border: 1px solid var(--line); border-radius: 999px;
}
.filter:focus-within { border-color: var(--focus); box-shadow: 0 0 0 3px color-mix(in srgb, var(--focus) 22%, transparent); }
.filter .i { color: var(--muted); }
.filter input { flex: 1; min-width: 0; border: 0; background: transparent; outline: none; padding: .5rem 0; }
.format-filter { display: flex; flex-wrap: wrap; gap: .4rem; }

@media (min-width: 48rem) {
  .records-head { grid-template-columns: auto 1fr; align-items: center; }
  .toolbar { justify-content: flex-end; }
  .filter { flex: 0 1 18rem; }
}

.filter-status { min-height: 1.4rem; margin: .25rem 0 .5rem; font-size: .9rem; color: var(--muted); }

.group + .group { margin-top: 1.5rem; }
.group-title {
  position: sticky; top: 0; z-index: 5;
  display: flex; align-items: baseline; gap: .5rem;
  margin: 0 -.25rem .5rem; padding: .45rem .25rem;
  background: var(--bg);
  font-family: var(--serif); font-size: 1.1rem;
}
@media (min-width: 48rem) {
  .group-title { top: 4.3rem; }
}

.record-list { display: grid; gap: .5rem; }

.record {
  display: grid; grid-template-columns: auto minmax(0, 1fr); gap: .65rem .85rem; align-items: center;
  padding: .75rem .85rem;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm);
  transition: border-color .15s;
}
.record:hover { border-color: var(--line-strong); }

.record-date {
  grid-row: span 2; align-self: start;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  width: 3.25rem; min-height: 3.25rem; padding: .25rem 0;
  border-radius: 10px; background: var(--accent-soft); color: var(--accent);
  line-height: 1; text-align: center;
}
.rd-day { font-family: var(--serif); font-size: 1.35rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.rd-mon { margin-top: .12rem; font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.rd-year { margin-top: .12rem; font-size: .66rem; opacity: .85; font-variant-numeric: tabular-nums; }
.record-date--none { background: var(--surface-2); color: var(--muted); }

.record-title { font-size: 1.02rem; font-weight: 650; overflow-wrap: anywhere; }
.record-title a { text-decoration: none; }
.record-title a::after { content: ""; }
.record-title a:hover { text-decoration: underline; }
.record-meta { display: flex; flex-wrap: wrap; gap: .1rem .5rem; margin-top: .1rem; font-size: .84rem; color: var(--muted); }
.record-meta > * + *::before { content: "·"; margin-right: .5rem; }
.record-snippet { margin-top: .4rem; font-size: .9rem; color: var(--muted); overflow-wrap: anywhere; }

.chips { grid-column: 2; display: flex; flex-wrap: wrap; gap: .4rem; }

@media (min-width: 40rem) {
  .record { grid-template-columns: auto minmax(0, 1fr) auto; }
  .record-date { grid-row: auto; align-self: center; }
  .chips { grid-column: auto; justify-content: flex-end; max-width: 22rem; }
}

.chip {
  --c: var(--c-other);
  display: inline-flex; align-items: center; gap: .4rem;
  min-height: 2.25rem; padding: .3rem .7rem;
  border: 1px solid color-mix(in srgb, var(--c) 40%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, var(--c) 9%, var(--surface));
  color: var(--c);
  font-size: .8rem; font-weight: 700; line-height: 1; white-space: nowrap;
  text-decoration: none; cursor: pointer;
  transition: background-color .15s, border-color .15s;
}
.chip:hover { color: var(--c); border-color: var(--c); background: color-mix(in srgb, var(--c) 16%, var(--surface)); }
.chip-size { font-weight: 500; opacity: .8; font-variant-numeric: tabular-nums; }
.chip--pdf { --c: var(--c-pdf); }
.chip--img { --c: var(--c-img); }
.chip--txt { --c: var(--c-txt); }
.chip--doc { --c: var(--c-doc); }
.chip--tif { --c: var(--c-tif); }
.chip--other { --c: var(--c-other); }
button.chip[aria-pressed="true"] { background: var(--c); border-color: var(--c); color: var(--surface); }
button.chip[aria-pressed="true"] .chip-size { opacity: 1; }

@media (pointer: coarse) {
  .chip { min-height: 2.5rem; padding-inline: .8rem; }
}

/* ---------- Kayıt sayfası ---------- */

.record-layout { display: grid; gap: 2rem; }
.record-content > .section:first-child { margin-top: 0; }
.record-aside .section-title { margin-bottom: .75rem; }

@media (min-width: 64rem) {
  .record-layout { grid-template-columns: minmax(0, 1fr) 20rem; align-items: start; }
  .record-aside { position: sticky; top: 5.5rem; }
}

.file-list { display: grid; gap: .5rem; }
.file-card {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: .75rem; align-items: center;
  padding: .75rem .85rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm);
  text-decoration: none;
}
.file-card:hover { border-color: var(--accent); color: var(--ink); }
.file-badge { min-width: 3.6rem; justify-content: center; }
.file-info { display: flex; flex-direction: column; min-width: 0; }
.file-name { font-weight: 650; }
.file-meta { font-size: .8rem; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-action { color: var(--muted); }
.file-card:hover .file-action { color: var(--accent); }

.pdf-frame {
  display: none;
  height: min(88vh, 70rem);
  background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
}
.pdf-frame iframe { display: block; width: 100%; height: 100%; border: 0; }
.pdf-mobile { width: 100%; }

@media (min-width: 48rem) and (pointer: fine) {
  .pdf-frame { display: block; }
  .pdf-mobile { display: none; }
}

.image-block { margin-inline: 0; }
.image-block img {
  display: block; width: auto; max-height: 85vh; margin-inline: auto;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm);
}
.image-block figcaption { margin-top: .5rem; font-size: .85rem; color: var(--muted); text-align: center; }

.prose {
  max-width: 44rem; padding: 1.25rem;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  font-family: var(--serif); font-size: clamp(1.02rem, .98rem + .25vw, 1.15rem); line-height: 1.75;
  overflow-wrap: anywhere;
}
.prose p + p { margin-top: .9em; }
.note { margin-top: .6rem; font-size: .82rem; color: var(--muted); }

@media (min-width: 48rem) {
  .prose { padding: 2rem 2.25rem; }
}

.pager { display: grid; gap: .6rem; margin-top: 2.5rem; }
.pager-link {
  display: flex; align-items: center; gap: .75rem;
  padding: .9rem 1rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm);
  text-decoration: none;
}
.pager-link:hover { border-color: var(--accent); color: var(--ink); }
.pager-link > span { display: flex; flex-direction: column; min-width: 0; }
.pager-label { font-size: .78rem; color: var(--muted); }
.pager-title { font-weight: 650; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pager-next { justify-content: flex-end; text-align: right; }

@media (min-width: 40rem) {
  .pager { grid-template-columns: 1fr 1fr; }
  .pager-next { grid-column: 2; }
}

/* ---------- Hata ---------- */

.error-page { max-width: 40rem; padding-block: 2rem; }
.error-code { font-family: var(--serif); font-size: clamp(4rem, 3rem + 6vw, 7rem); font-weight: 700; line-height: 1; color: var(--accent); }
.error-page .page-title { margin-top: .5rem; }
.error-actions { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 1.5rem; }

/* ---------- Alt bölüm ---------- */

.site-footer { border-top: 1px solid var(--line); background: var(--surface); font-size: .9rem; color: var(--muted); }
.footer-inner {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem 1.5rem;
  padding-block: 1.25rem calc(1.25rem + env(safe-area-inset-bottom));
}
.site-footer nav { display: flex; flex-wrap: wrap; gap: .25rem 1rem; }
.site-footer a { color: var(--muted); padding-block: .35rem; }
.site-footer a:hover { color: var(--accent); }

.to-top {
  position: fixed; z-index: 30;
  right: max(1rem, env(safe-area-inset-right)); bottom: max(1rem, env(safe-area-inset-bottom));
  display: grid; place-items: center; width: 3rem; height: 3rem;
  border-radius: 999px; background: var(--ink); color: var(--bg); box-shadow: var(--shadow);
}
.to-top:hover { color: var(--bg); filter: brightness(1.15); }

/* ---------- Önizleme penceresi ---------- */

.viewer {
  width: min(100vw - 1rem, 72rem); height: min(100dvh - 1rem, 60rem);
  max-width: none; max-height: none;
  padding: 0; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--surface); color: var(--ink); box-shadow: 0 20px 60px rgb(0 0 0 / 35%);
}
.viewer[open] { display: flex; flex-direction: column; }
.viewer::backdrop { background: rgb(15 12 8 / 60%); }
.viewer-bar {
  display: flex; align-items: center; gap: .75rem;
  padding: .5rem .5rem .5rem 1rem; border-bottom: 1px solid var(--line);
}
.viewer-title { flex: 1; min-width: 0; font-size: .98rem; font-weight: 650; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.viewer-actions { display: flex; align-items: center; gap: .35rem; }
.viewer-body { flex: 1; min-height: 0; display: grid; place-items: center; background: var(--surface-2); overflow: auto; }
.viewer-body iframe { width: 100%; height: 100%; border: 0; }
.viewer-body img { max-height: 100%; width: auto; object-fit: contain; background: #fff; }

@media (max-width: 40rem) {
  .viewer .btn-label { display: none; }
  .viewer .btn-sm { width: 2.5rem; padding: 0; }
}

/* ---------- Erişilebilirlik ve yazdırma ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

@media print {
  .site-header, .site-footer, .toolbar, .to-top, .pager, .pdf-frame, .pdf-mobile, .viewer { display: none !important; }
  body { background: #fff; color: #000; }
  .record, .prose, .file-card { border-color: #bbb; box-shadow: none; }
}
