:root {
  --ink: #15283a;
  --ink-soft: #526476;
  --navy: #102a43;
  --navy-deep: #0a1d30;
  --teal: #147d76;
  --teal-soft: #e7f3f1;
  --gold: #d7ac4f;
  --paper: #fbfcfd;
  --surface: #ffffff;
  --line: #dce4e9;
  --line-strong: #c7d3da;
  --shadow: 0 18px 45px rgba(16, 42, 67, 0.08);
  --header-height: 96px;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: #eef3f6;
  font-synthesis: none;
}

* { box-sizing: border-box; }
html { height: 100%; scroll-behavior: smooth; }
body {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  width: 100%;
  height: 100dvh;
  margin: 0;
  min-width: 320px;
  min-height: 0;
  overflow: hidden;
  background: var(--paper);
}
button, input { font: inherit; }
button { color: inherit; }
svg { width: 1.2rem; height: 1.2rem; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; left: 1rem; top: -4rem; z-index: 99; padding: .75rem 1rem; color: white; background: var(--navy); border-radius: .5rem; }
.skip-link:focus { top: 1rem; }

.site-header {
  height: var(--header-height);
  display: grid;
  grid-template-columns: minmax(180px, 1fr) auto minmax(180px, 1fr);
  align-items: center;
  padding: 0 clamp(1.25rem, 4vw, 4.5rem);
  color: #fff;
  background: linear-gradient(90deg, #081a2a 0%, #0b2236 48%, #0a1d30 100%);
  border-bottom: 1px solid rgba(215,172,79,.24);
  box-shadow: 0 6px 24px rgba(5,22,35,.12);
}
.brand {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-self: stretch;
  align-items: center;
  width: 106px;
  min-height: 0;
  height: var(--header-height);
  padding: 0;
  color: var(--navy);
  text-decoration: none;
  overflow: hidden;
  background: #071725;
  border-radius: 0 0 .9rem .9rem;
  box-shadow: none;
}
.brand-lockup {
  position: relative;
  display: block;
  width: 106px;
  height: var(--header-height);
  overflow: hidden;
  border-radius: 0 0 .9rem .9rem;
  background: transparent;
}
.brand-lockup img {
  position: absolute;
  top: -9px;
  left: 50%;
  width: auto;
  height: 117px;
  max-width: none;
  transform: translateX(-50%);
}
.top-nav { display: flex; align-items: stretch; height: 100%; gap: 1.55rem; }
.nav-item { position: relative; border: 0; padding: 0 .35rem; color: #9fb0bc; background: transparent; cursor: pointer; font-size: .76rem; font-weight: 700; letter-spacing: .035em; }
.nav-item:hover, .nav-item:focus-visible, .nav-item.active { color: #fff; }
.nav-item.active::after { content: ""; position: absolute; left: .35rem; right: .35rem; bottom: 18px; height: 2px; border-radius: 999px; background: #d4b76d; }
.header-actions { justify-self: end; display: flex; gap: .6rem; align-items: center; }
.profile-button, .icon-button { border: 1px solid rgba(255,255,255,.2); color: white; background: rgba(255,255,255,.07); cursor: pointer; }
.profile-button { width: 38px; height: 38px; border-radius: 50%; font-size: .7rem; font-weight: 750; letter-spacing: .04em; box-shadow: inset 0 0 0 1px rgba(255,255,255,.04); }
.icon-button { display: grid; place-items: center; width: 40px; height: 40px; border-radius: .6rem; }
.mobile-menu { display: none; }

.ask-strip {
  display: grid;
  grid-template-columns: minmax(220px, .6fr) minmax(420px, 1.4fr);
  align-items: center;
  gap: 2.5rem;
  min-height: 132px;
  padding: 1.6rem 2rem;
  color: #fff;
  background:
    radial-gradient(circle at 85% -50%, rgba(47, 170, 156, .38), transparent 38%),
    linear-gradient(115deg, #123b52, #0f5d5b);
  box-shadow: inset 0 -1px rgba(255,255,255,.08);
}
.ask-heading { justify-self: end; }
.eyebrow { display: block; margin-bottom: .45rem; color: var(--teal); font-size: .7rem; font-weight: 800; letter-spacing: .15em; }
.ask-heading .eyebrow { color: #86d5cc; }
.ask-heading h1 { margin: 0; font-family: Georgia, "Times New Roman", serif; font-size: clamp(1.3rem, 2vw, 1.85rem); font-weight: 500; }
.ask-form { position: relative; display: flex; align-items: center; max-width: 860px; height: 58px; padding: .38rem .4rem .38rem 1rem; color: var(--ink); background: #fff; border-radius: .75rem; box-shadow: 0 12px 30px rgba(2, 22, 35, .22); }
.ask-form svg { flex: 0 0 auto; color: #718392; }
.ask-form input { min-width: 0; flex: 1; height: 100%; border: 0; outline: 0; padding: 0 .85rem; color: var(--ink); background: transparent; font-size: 1rem; }
.ask-form input::placeholder { color: #81909c; }
.ask-form button { height: 44px; border: 0; border-radius: .55rem; padding: 0 1.25rem; color: #fff; background: var(--navy); cursor: pointer; font-weight: 700; }
.ask-form button:hover { background: #1b4666; }
.ask-response { display: none; grid-column: 2; max-width: 860px; padding: .75rem 1rem; border: 1px solid rgba(255,255,255,.24); border-radius: .6rem; background: rgba(4,35,42,.32); font-size: .9rem; }
.ask-response.visible { display: block; }

.workspace { display: grid; grid-template-columns: 285px minmax(520px, 1fr) 280px; width: 100%; height: 100%; min-height: 0; overflow: hidden; background: var(--paper); }
.library-panel, .source-panel { padding: 1.5rem; background: #f5f8fa; }
.library-panel { border-right: 1px solid var(--line); }
.source-panel { min-height: 0; overflow-y: auto; overscroll-behavior: contain; border-left: 1px solid var(--line); background: #fbfcfc; scrollbar-width: thin; scrollbar-color: #cbd7de transparent; }
.panel-heading { display: flex; justify-content: space-between; align-items: end; margin-bottom: 1rem; }
.panel-heading h2, .source-panel h2 { margin: 0; font-family: Georgia, "Times New Roman", serif; font-size: 1.35rem; }
.count-badge { display: inline-grid; place-items: center; min-width: 28px; height: 28px; border-radius: 999px; color: var(--teal); background: var(--teal-soft); font-size: .8rem; font-weight: 800; }
.library-search { display: flex; align-items: center; height: 42px; margin-bottom: 1.15rem; padding: 0 .75rem; border: 1px solid var(--line); border-radius: .55rem; color: #748795; background: white; }
.library-search input { min-width: 0; width: 100%; border: 0; outline: 0; padding-left: .55rem; color: var(--ink); background: transparent; }
.discipline-row { display: flex; gap: .65rem; align-items: center; padding: .8rem .7rem; border-radius: .55rem; color: var(--navy); background: #e8eef2; }
.discipline-row > div:last-child { display: flex; flex-direction: column; }
.discipline-row small, .book-title small, .chapter small { display: block; margin-top: .15rem; color: #718392; font-size: .76rem; font-weight: 500; }
.discipline-icon { display: grid; place-items: center; width: 34px; height: 34px; border-radius: .45rem; color: white; background: var(--navy); font-family: Georgia, serif; font-size: 1.1rem; }
.book-card { margin-top: .8rem; }
.book-title { width: 100%; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: .65rem; padding: .8rem .35rem; border: 0; text-align: left; background: transparent; cursor: pointer; }
.book-monogram { display: grid; place-items: center; width: 38px; height: 46px; border-radius: .3rem .45rem .45rem .3rem; color: var(--gold); background: var(--navy); font-family: Georgia, serif; font-size: 1.25rem; box-shadow: inset 4px 0 rgba(255,255,255,.08); }
.book-title > span:nth-child(2) { min-width: 0; }
.book-title strong { display: block; font-size: .9rem; }
.chapter-list { display: grid; gap: .35rem; margin-left: 1.15rem; padding-left: 1rem; border-left: 1px solid var(--line-strong); }
.chapter { display: grid; grid-template-columns: 30px 1fr; gap: .55rem; align-items: start; width: 100%; padding: .7rem; border: 1px solid transparent; border-radius: .55rem; text-align: left; background: transparent; cursor: pointer; }
.chapter > span:first-child { color: #8795a0; font-size: .75rem; font-weight: 800; padding-top: .15rem; }
.chapter > span:last-child { font-size: .86rem; font-weight: 700; }
.chapter:hover { background: #edf2f5; }
.chapter.active { border-color: #bedbd7; background: var(--teal-soft); }
.chapter.active > span:first-child { color: var(--teal); }
.library-note { display: flex; gap: .65rem; margin-top: 1.5rem; padding: .9rem; border: 1px solid var(--line); border-radius: .65rem; color: var(--ink-soft); background: #fff; }
.library-note svg { flex: 0 0 auto; color: var(--teal); }
.library-note p { margin: 0; font-size: .78rem; line-height: 1.55; }

.reader { display: grid; grid-template-rows: auto minmax(0, 1fr) auto auto; min-width: 0; min-height: 0; height: 100%; padding: 1.35rem clamp(1.5rem, 3vw, 3.25rem) 1rem; overflow: hidden; background: var(--surface); }
.reader-header { display: flex; align-items: end; justify-content: space-between; gap: 1rem; padding-bottom: 1.3rem; border-bottom: 1px solid var(--line); }
.breadcrumb { display: flex; gap: .5rem; margin-bottom: .6rem; color: #718392; font-size: .78rem; }
.breadcrumb b { color: var(--gold); }
.reader-header h2 { margin: 0; font-family: Georgia, "Times New Roman", serif; color: var(--navy); font-size: clamp(1.6rem, 3vw, 2.3rem); font-weight: 500; }
.reader-header p { margin: .35rem 0 0; color: var(--ink-soft); font-size: .86rem; }
.view-switcher { display: inline-flex; padding: .25rem; border: 1px solid var(--line); border-radius: .55rem; background: #f4f7f8; }
.view-switcher button { border: 0; border-radius: .38rem; padding: .5rem .72rem; color: var(--ink-soft); background: transparent; cursor: pointer; font-size: .78rem; font-weight: 700; }
.view-switcher button.active { color: var(--navy); background: #fff; box-shadow: 0 2px 8px rgba(16,42,67,.09); }
.reading-sheet { width: 100%; max-width: 1050px; min-height: 0; margin: 0 auto; padding: 1.7rem .8rem 2.5rem 0; overflow-y: auto; overscroll-behavior: contain; scrollbar-gutter: stable; scrollbar-width: thin; scrollbar-color: #b8c8d1 transparent; }
.reading-sheet::-webkit-scrollbar, .source-panel::-webkit-scrollbar, .library-tree::-webkit-scrollbar { width: 8px; }
.reading-sheet::-webkit-scrollbar-track, .source-panel::-webkit-scrollbar-track, .library-tree::-webkit-scrollbar-track { background: transparent; }
.reading-sheet::-webkit-scrollbar-thumb, .source-panel::-webkit-scrollbar-thumb, .library-tree::-webkit-scrollbar-thumb { border: 2px solid transparent; border-radius: 999px; background: #b8c8d1; background-clip: padding-box; }
.section-kicker { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 1rem; margin-bottom: 1.6rem; color: var(--gold); font-size: .7rem; letter-spacing: .13em; }
.section-kicker span { height: 1px; background: linear-gradient(90deg, transparent, #dfc986); }
.section-kicker span:last-child { background: linear-gradient(90deg, #dfc986, transparent); }
.text-columns { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1.5rem, 3vw, 3rem); }
.text-columns.filter-empty { grid-template-columns: minmax(0, 760px); justify-content: center; }
.text-columns.filter-empty .arabic-column { display: none; }
.text-columns > section { min-width: 0; }
.text-columns > section + section { padding-left: clamp(1.5rem, 3vw, 3rem); border-left: 1px solid var(--line); }
.text-columns h3 { position: sticky; z-index: 3; top: -.1rem; margin: 0 0 1.1rem; padding: .45rem 0 .65rem; color: #718392; background: rgba(255,255,255,.94); backdrop-filter: blur(8px); font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; }
.arabic-column h3 { text-align: right; }
.prose { font-family: Georgia, "Times New Roman", serif; font-size: 1.05rem; line-height: 1.95; }
.prose p { margin: 0 0 1.1rem; }
.prose h4 { margin: .35rem 0 1.2rem; color: var(--navy); font-size: 1.32rem; font-weight: 500; }
.prose blockquote { margin: 1.35rem 0; padding: .8rem 1rem; border-left: 3px solid var(--gold); color: #233e52; background: #f7f9fa; }
.arabic-prose { font-family: "Noto Naskh Arabic", "Geeza Pro", "Times New Roman", serif; color: #243a4c; font-size: 1.38rem; line-height: 2.2; }
.arabic-prose p { margin: 0 0 1rem; }
.arabic-prose h4 { margin: .35rem 0 1.2rem; color: var(--navy); font-size: 1.65rem; font-weight: 600; }
.print-page-break { display: flex; align-items: center; gap: .65rem; margin: 1.8rem 0 .85rem; color: #9a7931; font-family: Inter, ui-sans-serif, system-ui, sans-serif; font-size: .64rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.print-page-break::before, .print-page-break::after { content: ""; flex: 1; height: 1px; background: #e5d8b4; }
.tafsir-record:first-child .print-page-break { margin-top: 0; }
.verse-block { padding: 1.15rem 1.2rem .2rem; border: 1px solid #e7d9aa; border-radius: .65rem; background: #fdfbf4; }
.tafsir-record { padding-bottom: 1.2rem; }
.tafsir-record + .tafsir-record { margin-top: .8rem; }
.tafsir-record:focus { outline: 2px solid rgba(20,125,118,.2); outline-offset: .45rem; border-radius: .2rem; }
.passage-review-state { display: inline-flex; align-items: center; gap: .3rem; margin: 0 0 .45rem; font-size: .69rem; font-weight: 650; letter-spacing: .02em; }
.passage-review-state i { font-size: .9rem; }
.passage-review-state.checked { color: #147d76; }
.passage-review-state.pending { color: #b27125; }
.isnad { color: #5f7180; font-size: .92em; line-height: 1.75; }
.tafsir-matn { color: #223b4d; font-weight: 500; }
.translation-column[hidden], .arabic-column[hidden] { display: none; }
.reading-sheet.translation .text-columns, .reading-sheet.arabic .text-columns { grid-template-columns: minmax(0, 760px); justify-content: center; }
.reading-sheet.translation .text-columns > section + section, .reading-sheet.arabic .text-columns > section + section { padding-left: 0; border-left: 0; }
.placeholder { display: grid; place-items: center; min-height: 280px; padding: 2rem; border: 1px dashed var(--line-strong); border-radius: .75rem; color: var(--ink-soft); text-align: center; background: #f9fbfc; }
.placeholder strong { display: block; margin-bottom: .4rem; color: var(--navy); font-family: Georgia, serif; font-size: 1.15rem; }
.pagination { display: flex; align-items: center; justify-content: center; gap: .45rem; margin: 0; padding: .75rem 0; border-top: 1px solid var(--line); background: rgba(255,255,255,.96); }
.pagination[hidden] { display: none; }
.page-numbers { display: flex; flex-wrap: wrap; justify-content: center; gap: .35rem; }
.page-number, .page-arrow { display: inline-grid; place-items: center; min-width: 38px; height: 38px; border: 1px solid var(--line-strong); border-radius: .48rem; color: var(--navy); background: #fff; cursor: pointer; font-weight: 750; }
.page-number:hover, .page-arrow:hover:not(:disabled) { border-color: var(--teal); color: var(--teal); }
.page-number.active { border-color: var(--navy); color: #fff; background: var(--navy); }
.page-arrow svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 2; }
.page-arrow:disabled { opacity: .35; cursor: not-allowed; }
.page-status { display: none; min-width: 56px; color: var(--ink-soft); text-align: center; font-size: .85rem; font-weight: 700; }
.reader-footer { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding-top: .75rem; border-top: 1px solid var(--line); background: #fff; }
.reader-footer > span { color: #718392; font-size: .82rem; }
.secondary-button { display: inline-flex; align-items: center; gap: .4rem; min-height: 40px; border: 1px solid var(--line-strong); border-radius: .5rem; padding: 0 .85rem; color: var(--navy); background: #fff; cursor: pointer; font-weight: 700; font-size: .82rem; }
.secondary-button:hover:not(:disabled) { border-color: var(--teal); color: var(--teal); }
.secondary-button:disabled { opacity: .4; cursor: not-allowed; }

.source-panel section { padding-bottom: 1.35rem; }
.source-panel section + section { padding-top: 1.35rem; border-top: 1px solid var(--line); }
.source-panel dl { margin: 1rem 0 0; }
.source-panel dl div { display: grid; grid-template-columns: 72px 1fr; gap: .6rem; padding: .55rem 0; border-bottom: 1px solid var(--line); }
.source-panel dt { color: #718392; font-size: .75rem; }
.source-panel dd { margin: 0; font-size: .78rem; font-weight: 600; line-height: 1.45; }
.citation-box { margin-top: 1.2rem; padding: 1.15rem 0 0; border-top: 1px solid var(--line); }
.citation-label { color: #718392; font-size: .62rem; font-weight: 750; letter-spacing: .08em; }
.citation-box p { margin: .65rem 0 .8rem; color: #334b5e; font-family: Georgia, "Times New Roman", serif; font-size: .78rem; line-height: 1.6; }
.citation-box button { display: inline-flex; align-items: center; gap: .4rem; min-height: 32px; border: 1px solid var(--line-strong); border-radius: .35rem; padding: 0 .65rem; color: #405769; background: transparent; cursor: pointer; font-size: .7rem; font-weight: 650; }
.citation-box button:hover, .citation-box button.copied { border-color: var(--teal); color: var(--teal); background: #f1faf8; }
.citation-box small { display: block; min-height: 1.1rem; padding-top: .35rem; color: var(--teal); font-size: .66rem; }
.status-card { margin: 0; padding: 1rem 0; border-top: 1px solid var(--line); }
.status-title { display: flex; align-items: center; justify-content: space-between; gap: .55rem; color: #526476; cursor: pointer; font-size: .72rem; font-weight: 600; list-style: none; }
.status-title::-webkit-details-marker { display: none; }
.status-title::after { content: "+"; color: #81909c; font-size: .95rem; font-weight: 400; }
.status-card[open] .status-title::after { content: "−"; }
.status-card[data-review-status="pending"] .status-title { color: #a36914; }
.status-card p { margin: .7rem 0 0; color: var(--ink-soft); font-size: .73rem; line-height: 1.55; }

/* Modern külliyat ağacı */
.workspace { grid-template-columns: 338px minmax(520px, 1fr) 310px; }
.library-panel {
  min-height: 0;
  padding: 0;
  overflow: hidden;
  background: #f8fafb;
}
.library-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 58px;
  padding: 0 1.15rem;
  border-bottom: 1px solid var(--line);
  background: rgba(255,255,255,.76);
}
.library-title { display: flex; align-items: center; gap: .6rem; }
.library-title i { color: var(--navy); font-size: 1.3rem; }
.library-title h2 { margin: 0; font-family: Georgia, "Times New Roman", serif; color: var(--navy); font-size: 1.22rem; }
.expand-all { border: 0; padding: .35rem .2rem; color: #6d7f8d; background: transparent; cursor: pointer; font-size: .72rem; font-weight: 700; }
.expand-all:hover { color: var(--teal); }

.library-panel .library-search {
  position: relative;
  height: 40px;
  margin: .85rem 1rem .7rem;
  padding: 0 .65rem;
  border-color: #d9e2e7;
  border-radius: .48rem;
  box-shadow: 0 1px 2px rgba(15,42,61,.03);
}
.library-panel .library-search i { flex: 0 0 auto; font-size: 1rem; }
.library-panel .library-search input { padding-left: .5rem; font-size: .78rem; }
.library-panel .library-search kbd {
  display: inline-flex;
  align-items: center;
  height: 23px;
  padding: 0 .4rem;
  border: 1px solid #dce4e9;
  border-radius: .32rem;
  color: #7c8d99;
  background: #f4f7f8;
  font: 600 .66rem/1 Inter, sans-serif;
  white-space: nowrap;
}

.library-tree { height: calc(100vh - 76px - 132px - 58px - 66px); min-height: 430px; overflow-y: auto; padding: 0 .8rem 1.25rem; scrollbar-width: thin; scrollbar-color: #cbd7de transparent; }
.discipline-group { border-left: 2px solid transparent; }
.discipline-toggle, .tree-heading, .discipline-compact {
  width: 100%;
  border: 0;
  color: var(--navy);
  background: transparent;
  cursor: pointer;
}
.discipline-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 46px;
  padding: 0 .72rem;
  border-radius: .42rem;
  background: #e9eff2;
}
.discipline-name, .discipline-end, .tree-heading > span, .discipline-compact > span { display: inline-flex; align-items: center; }
.discipline-name { gap: .58rem; }
.discipline-name i { display: grid; place-items: center; width: 28px; height: 28px; border-radius: .38rem; color: var(--gold); background: var(--navy); font-size: 1rem; }
.discipline-name strong { font-size: .86rem; }
.discipline-end { gap: .45rem; }
.discipline-end small { color: #718392; font-size: .67rem; }
.discipline-end i { font-size: .75rem; transition: transform .2s ease; }
.discipline-group:not(.expanded) .discipline-end i { transform: rotate(180deg); }
.discipline-group:not(.expanded) .discipline-content { display: none; }

.discipline-content { margin-left: .72rem; padding: .65rem 0 0 .65rem; border-left: 1px solid #d5dee3; }
.selected-book { display: grid; grid-template-columns: 56px 1fr; gap: .7rem; align-items: start; margin: 0 -.35rem; padding: .55rem .8rem .7rem .6rem; border: 1px solid transparent; border-radius: .58rem; cursor: pointer; transition: border-color .18s ease, background .18s ease, box-shadow .18s ease, transform .18s ease; }
.selected-book:hover { border-color: #c9ddd9; background: #f3f9f7; box-shadow: 0 8px 18px rgba(16, 42, 67, .06); transform: translateY(-1px); }
.selected-book:focus-visible { outline: 3px solid rgba(37, 176, 160, .35); outline-offset: 2px; border-color: var(--teal); }
.book-cover { width: 56px; height: 78px; border-radius: 2px 4px 4px 2px; object-fit: cover; box-shadow: 0 4px 10px rgba(10,29,48,.16); }
.book-identity { min-width: 0; padding-top: .12rem; }
.book-identity h3 { margin: 0; color: var(--navy); font-family: Georgia, "Times New Roman", serif; font-size: .98rem; font-weight: 700; line-height: 1.25; }
.book-identity p { margin: .18rem 0 .28rem; color: #586b7a; font-size: .72rem; }
.book-meta { display: flex; gap: .32rem; color: #6e7e8b; font-size: .65rem; white-space: nowrap; }
.book-meta b { color: #aab6bd; }
.book-progress { display: flex; align-items: center; gap: .55rem; margin-top: .55rem; }
.book-progress > span { position: relative; flex: 1; height: 4px; overflow: hidden; border-radius: 999px; background: #dfe7eb; }
.book-progress > span i { position: absolute; inset: 0 auto 0 0; width: 14%; border-radius: inherit; background: var(--teal); }
.book-progress small { color: #718392; font-size: .63rem; white-space: nowrap; }

.book-actions { display: grid; grid-template-columns: .78fr 1.22fr; gap: .45rem; padding: .05rem .38rem .7rem 0; }
.book-actions button { display: inline-flex; align-items: center; justify-content: center; gap: .38rem; height: 34px; border: 1px solid #d5dfe5; border-radius: .42rem; color: #42586a; background: #fff; cursor: pointer; font-size: .7rem; font-weight: 700; }
.book-actions button:hover, .book-actions button[aria-pressed="true"] { border-color: #9fc9c4; color: #0f6964; background: #eff8f6; }
.book-actions i { font-size: .95rem; }

.tafsir-filters { margin: 0 .38rem .72rem 0; overflow: hidden; border: 1px solid #d7e1e5; border-radius: .55rem; background: #fff; box-shadow: 0 4px 12px rgba(16,42,67,.035); }
.tafsir-filter-toggle { display: flex; align-items: center; justify-content: space-between; width: 100%; min-height: 40px; padding: 0 .68rem; border: 0; color: var(--navy); background: #f2f6f7; cursor: pointer; }
.tafsir-filter-toggle > span { display: inline-flex; align-items: center; gap: .42rem; }
.tafsir-filter-toggle > span:first-child i { color: var(--teal); font-size: .95rem; }
.tafsir-filter-toggle strong { font-size: .76rem; }
.tafsir-filter-toggle small { display: inline-grid; place-items: center; min-width: 47px; height: 20px; padding: 0 .42rem; border-radius: 999px; color: #627986; background: #e4ebee; font-size: .58rem; font-weight: 800; }
.tafsir-filter-toggle > span:last-child > i { color: #7c8d98; font-size: .68rem; transition: transform .18s ease; }
.tafsir-filters.collapsed .tafsir-filter-toggle > span:last-child > i { transform: rotate(180deg); }
.tafsir-filters.collapsed .tafsir-filter-body { display: none; }
.tafsir-filter-body { padding: .62rem; }
.passage-search { display: flex; align-items: center; height: 35px; padding: 0 .58rem; border: 1px solid #d8e1e6; border-radius: .4rem; color: #768995; background: #fff; }
.passage-search:focus-within { border-color: #7ebcb5; box-shadow: 0 0 0 3px rgba(20,125,118,.1); }
.passage-search i { flex: 0 0 auto; font-size: .92rem; }
.passage-search input { min-width: 0; width: 100%; border: 0; outline: 0; padding: 0 0 0 .45rem; color: var(--ink); background: transparent; font-size: .69rem; }
.filter-field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .45rem; margin-top: .55rem; }
.filter-field { display: grid; gap: .26rem; min-width: 0; }
.filter-field > span { color: #6d7f8b; font-size: .58rem; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.filter-field select { min-width: 0; width: 100%; height: 32px; border: 1px solid #d8e1e6; border-radius: .38rem; padding: 0 1.4rem 0 .48rem; color: #354e60; background: #fff; font: 650 .65rem/1 Inter, sans-serif; }
.filter-field select:focus-visible { outline: 3px solid rgba(37,176,160,.32); outline-offset: 1px; }
.advanced-filters { margin-top: .5rem; border-top: 1px solid #e5eaed; }
.advanced-filters summary { display: flex; align-items: center; justify-content: space-between; min-height: 33px; color: #536a79; cursor: pointer; list-style: none; font-size: .65rem; font-weight: 750; }
.advanced-filters summary::-webkit-details-marker { display: none; }
.advanced-filters summary i { color: #86949e; font-size: .68rem; transition: transform .18s ease; }
.advanced-filters[open] summary i { transform: rotate(180deg); }
.advanced-filter-content { display: grid; gap: .5rem; padding-bottom: .15rem; }
.filter-field.full-width { width: 100%; }
.facet-list { display: flex; flex-wrap: wrap; gap: .3rem; }
.facet-chip { min-height: 27px; border: 1px solid #d3dde2; border-radius: 999px; padding: 0 .5rem; color: #637986; background: #fff; cursor: pointer; font-size: .59rem; font-weight: 750; }
.facet-chip:hover { border-color: #8fc3bd; color: var(--teal); }
.facet-chip[aria-pressed="true"] { border-color: var(--teal); color: #0f6762; background: #e8f5f3; }
.filter-result-bar { display: flex; align-items: center; justify-content: space-between; min-height: 31px; margin-top: .45rem; padding-top: .45rem; border-top: 1px solid #e5eaed; color: #6d7f8b; font-size: .62rem; }
.filter-result-bar strong { color: var(--navy); font-size: .71rem; }
.filter-result-bar button { border: 0; padding: .25rem 0; color: var(--teal); background: transparent; cursor: pointer; font-size: .62rem; font-weight: 800; }
.filter-result-bar button:disabled { color: #a7b2b8; cursor: default; }
.chapter-match-count { display: inline-block; margin-left: .3rem; color: var(--teal); font-size: .58rem; font-weight: 800; }
.chapter-match-count[hidden] { display: none; }
.filter-empty-state { grid-column: 1 / -1; min-height: 250px; display: grid; place-items: center; padding: 2rem; border: 1px dashed #cfdbe0; border-radius: .7rem; color: #637786; background: #f8fafb; text-align: center; font-family: Inter, sans-serif; }
.filter-empty-state i { display: block; margin-bottom: .65rem; color: #8ca0aa; font-size: 1.65rem; }
.filter-empty-state strong { display: block; margin-bottom: .3rem; color: var(--navy); font-family: Georgia, "Times New Roman", serif; font-size: 1.05rem; }
.filter-empty-state p { margin: 0; font-size: .75rem; line-height: 1.55; }

.chapter-tree { padding-right: .38rem; }
.tree-heading { display: flex; align-items: center; justify-content: space-between; height: 39px; padding: 0 .28rem 0 .1rem; border-top: 1px solid #e0e7eb; }
.tree-heading > span { gap: .48rem; }
.tree-heading i { font-size: .82rem; }
.tree-heading > span i { color: #627785; font-size: 1rem; }
.tree-heading strong { font-size: .81rem; }
.chapter-tree:not(.expanded) .chapter-tree-content { display: none; }
.chapter-tree:not(.expanded) .tree-heading > i { transform: rotate(180deg); }
.chapter-search-wrap { display: flex; align-items: center; height: 36px; padding: 0 .6rem; border: 1px solid #d9e2e7; border-radius: .42rem; color: #7d8e9b; background: #fff; }
.chapter-search-wrap i { font-size: .92rem; }
.chapter-search-wrap input { min-width: 0; width: 100%; border: 0; outline: 0; padding: 0 0 0 .45rem; color: var(--ink); background: transparent; font-size: .72rem; }
.chapter-filters { display: grid; grid-template-columns: .72fr 1.25fr .85fr; gap: .28rem; margin: .55rem 0 .48rem; }
.filter-chip { height: 29px; border: 1px solid #d6e0e5; border-radius: 999px; color: #718392; background: transparent; cursor: pointer; font-size: .64rem; font-weight: 700; }
.filter-chip:hover { border-color: #9fc9c4; color: var(--teal); }
.filter-chip.active { border-color: var(--navy); color: #fff; background: var(--navy); }

.library-panel .chapter-list { position: relative; gap: 0; margin: 0; padding: 0; border: 0; }
.library-panel .chapter-list::before { content: ""; position: absolute; top: 0; bottom: 0; left: 26px; width: 1px; background: #d8e1e6; }
.library-panel .chapter {
  position: relative;
  grid-template-columns: 25px 17px 1fr;
  gap: .45rem;
  min-height: 48px;
  padding: .5rem .5rem .48rem .4rem;
  border: 0;
  border-left: 2px solid transparent;
  border-radius: 0 .44rem .44rem 0;
  z-index: 1;
}
.library-panel .chapter > span:first-child { padding-top: .12rem; color: #7c8e9b; font-size: .64rem; }
.library-panel .chapter > span:last-child { color: #263d50; font-size: .75rem; line-height: 1.2; }
.library-panel .chapter small { margin-top: .18rem; color: #718392; font-size: .64rem; font-weight: 500; }
.library-panel .chapter[data-status="progress"] small { color: #c47b16; }
.chapter-status { position: relative; z-index: 2; margin-top: .05rem; background: #f8fafb; font-size: .88rem; }
.chapter-status.complete { color: var(--teal); }
.chapter-status.progress { color: #d99b22; }
.chapter-status.draft { color: #c47b16; }
.record-review-note { margin-top: .8rem; border: 1px solid #d9e1e6; border-radius: .55rem; background: #f8fafb; color: #4d6272; font-family: Inter, ui-sans-serif, system-ui, sans-serif; font-size: .75rem; }
.record-review-note summary { display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: .55rem; padding: .65rem .75rem; cursor: pointer; list-style: none; }
.record-review-note summary::-webkit-details-marker { display: none; }
.record-review-note summary > span { display: inline-flex; align-items: center; gap: .45rem; }
.record-review-note summary > span i { color: #537084; font-size: .95rem; }
.record-review-note summary small { color: #7a8b97; font-size: .66rem; font-weight: 600; }
.record-review-note .note-caret { color: #8b9aa4; font-size: .72rem; transition: transform .18s ease; }
.record-review-note[open] .note-caret { transform: rotate(180deg); }
.record-review-note > p { margin: 0; padding: .72rem .8rem .8rem; border-top: 1px solid #e1e7eb; color: #465e70; font-family: Georgia, "Times New Roman", serif; font-size: .82rem; line-height: 1.65; }
.record-review-note.note-edition { border-color: #e1d5b4; background: #fffdf7; }
.record-review-note.note-edition summary > span i { color: #9a7931; }
.record-review-note.note-translator { border-color: #cedce7; background: #f7fafc; }
.record-review-note.note-translator summary > span i { color: #3f718e; }
.record-review-note.note-term { border-color: #c8dfda; background: #f4faf8; }
.record-review-note.note-term summary > span i { color: var(--teal); }
.library-panel .chapter:hover { background: #eef3f5; }
.library-panel .chapter.active { border-left-color: var(--teal); background: #e7f3f1; }
.library-panel .chapter.active > span:last-child { color: #102f45; }
.library-panel .chapter.pending { cursor: default; }
.library-panel .chapter.pending:hover { background: transparent; }
.library-panel .chapter[hidden],
.library-panel .discipline-group[hidden],
.library-panel .discipline-compact[hidden] { display: none !important; }

.other-disciplines { margin-top: .55rem; padding-top: .45rem; border-top: 1px solid var(--line); }
.discipline-compact { display: flex; align-items: center; justify-content: space-between; height: 36px; padding: 0 .5rem; border-radius: .38rem; }
.discipline-compact:hover { background: #edf2f5; }
.discipline-compact > span { gap: .55rem; font-size: .75rem; font-weight: 700; }
.discipline-compact > span i { width: 20px; color: #456072; font-size: .95rem; text-align: center; }
.discipline-compact > i { color: #8a99a3; font-size: .7rem; }

.library-panel.no-results::after { content: "Aramanızla eşleşen bir eser veya sûre bulunamadı."; display: block; margin: 1rem; padding: 1rem; color: var(--ink-soft); background: #fff; border: 1px dashed var(--line-strong); border-radius: .55rem; font-size: .75rem; line-height: 1.5; }
.source-panel.attention { animation: sourceAttention 1.2s ease; }
@keyframes sourceAttention { 35% { background: #eef7f5; } }

body.modal-open { overflow: hidden; }

.book-profile-modal {
  width: min(1040px, calc(100vw - 40px));
  max-width: none;
  height: min(820px, calc(100vh - 48px));
  max-height: none;
  margin: auto;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 1rem;
  color: var(--ink);
  background: #fff;
  box-shadow: 0 30px 90px rgba(4, 23, 38, .32);
}
.book-profile-modal::backdrop { background: rgba(6, 25, 39, .72); backdrop-filter: blur(4px); }
.book-profile-shell { display: grid; grid-template-rows: auto minmax(0, 1fr); height: 100%; }
.book-profile-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 116px;
  padding: 1rem 1.15rem 1rem 1.35rem;
  color: #fff;
  background: radial-gradient(circle at 80% -80%, rgba(66, 181, 167, .4), transparent 45%), linear-gradient(120deg, #0b2235, #10484f);
  border-bottom: 1px solid rgba(255,255,255,.12);
}
.book-profile-identity { display: flex; align-items: center; gap: 1rem; min-width: 0; }
.book-profile-identity img { width: 58px; height: 80px; flex: 0 0 auto; border-radius: 2px 5px 5px 2px; object-fit: cover; box-shadow: 0 8px 22px rgba(0,0,0,.28); }
.book-profile-identity .eyebrow { margin-bottom: .25rem; color: #86d5cc; }
.book-profile-identity h2 { margin: 0; font-family: Georgia, "Times New Roman", serif; font-size: 1.6rem; font-weight: 600; }
.book-profile-identity p { max-width: 620px; margin: .32rem 0 0; color: #bdd0d8; font-family: Georgia, "Times New Roman", serif; font-size: .88rem; line-height: 1.5; }
.modal-close { display: grid; place-items: center; width: 40px; height: 40px; flex: 0 0 auto; border: 1px solid rgba(255,255,255,.22); border-radius: .65rem; color: #fff; background: rgba(255,255,255,.08); cursor: pointer; }
.modal-close:hover { background: rgba(255,255,255,.16); }
.modal-close i { font-size: 1.25rem; }

.book-profile-body { display: grid; grid-template-columns: 210px minmax(0, 1fr); min-height: 0; }
.book-profile-nav { padding: 1.25rem .85rem; border-right: 1px solid var(--line); background: #f5f8f9; }
.book-profile-nav::before { content: "DOSYA İÇERİĞİ"; display: block; margin: 0 .65rem .65rem; color: #80909c; font-size: .62rem; font-weight: 800; letter-spacing: .13em; }
.book-profile-nav button { width: 100%; min-height: 42px; margin-bottom: .25rem; padding: .6rem .7rem; border: 0; border-left: 3px solid transparent; border-radius: 0 .42rem .42rem 0; color: #536979; background: transparent; cursor: pointer; text-align: left; font-size: .76rem; font-weight: 700; }
.book-profile-nav button:hover { color: var(--navy); background: #e9eff2; }
.book-profile-nav button.active { border-left-color: var(--teal); color: #0f625e; background: #e2f1ef; }

.book-profile-content { min-height: 0; overflow-y: auto; scroll-behavior: smooth; scrollbar-width: thin; scrollbar-color: #bdcbd3 transparent; }
.profile-section { max-width: 760px; margin: 0 auto; padding: 2.35rem 2.6rem; scroll-margin-top: 1rem; }
.profile-section + .profile-section { border-top: 1px solid var(--line); }
.profile-section-heading { display: flex; align-items: center; gap: .85rem; margin-bottom: 1.35rem; }
.profile-section-heading > span { display: grid; place-items: center; width: 38px; height: 38px; flex: 0 0 auto; border: 1px solid #bdd8d4; border-radius: 50%; color: var(--teal); background: #eff8f6; font: 800 .72rem/1 Inter, sans-serif; }
.profile-section-heading small { display: block; margin-bottom: .15rem; color: #87949d; font-size: .62rem; font-weight: 800; letter-spacing: .13em; }
.profile-section-heading h3 { margin: 0; color: var(--navy); font-family: Georgia, "Times New Roman", serif; font-size: 1.38rem; }
.profile-section > p { margin: 0 0 1rem; color: #384f61; font-family: Georgia, "Times New Roman", serif; font-size: .96rem; line-height: 1.78; }
.profile-section cite { font-style: italic; }
.profile-callout, .profile-warning { display: flex; gap: .8rem; align-items: flex-start; margin-top: 1.35rem; padding: 1rem 1.05rem; border: 1px solid #c8dfda; border-radius: .65rem; color: #284f52; background: #f1f8f7; }
.profile-callout.neutral { border-color: #d6dfe5; color: #3b5365; background: #f6f8fa; }
.profile-callout i, .profile-warning i { flex: 0 0 auto; margin-top: .12rem; color: var(--teal); font-size: 1.15rem; }
.profile-callout p, .profile-warning p { margin: 0; font-size: .82rem; line-height: 1.6; }
.method-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .8rem; }
.method-grid article { padding: 1.05rem; border: 1px solid var(--line); border-radius: .65rem; background: #fcfdfd; }
.method-grid i { display: grid; place-items: center; width: 34px; height: 34px; margin-bottom: .75rem; border-radius: .45rem; color: #a37922; background: #fff7e5; font-size: 1.05rem; }
.method-grid h4 { margin: 0 0 .4rem; color: var(--navy); font-size: .82rem; }
.method-grid p { margin: 0; color: #566b79; font-size: .75rem; line-height: 1.62; }
.reading-steps { display: grid; gap: .9rem; margin: 0; padding: 0; list-style: none; }
.reading-steps li { display: grid; grid-template-columns: 32px 1fr; gap: .8rem; }
.reading-steps li > span { display: grid; place-items: center; width: 30px; height: 30px; border-radius: .42rem; color: #fff; background: var(--navy); font-size: .72rem; font-weight: 800; }
.reading-steps strong { display: block; margin: .1rem 0 .25rem; color: var(--navy); font-size: .84rem; }
.reading-steps p { margin: 0; color: #556a79; font-size: .78rem; line-height: 1.58; }
.profile-warning { border-color: #ead8ae; color: #66501e; background: #fffaf0; }
.profile-warning i { color: #b28325; }
.edition-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .85rem; }
.edition-cards article { padding: 1.1rem; border: 1px solid #d6e0e5; border-radius: .72rem; background: #fbfcfd; }
.edition-cards article > span, .profile-citation > span { display: block; margin-bottom: .35rem; color: #718493; font-size: .6rem; font-weight: 800; letter-spacing: .12em; }
.edition-cards h4 { margin: 0 0 .85rem; color: var(--navy); font-family: Georgia, "Times New Roman", serif; font-size: 1.02rem; }
.edition-cards dl { margin: 0; }
.edition-cards dl div { display: grid; grid-template-columns: 72px 1fr; gap: .55rem; padding: .45rem 0; border-top: 1px solid #e6ebee; font-size: .7rem; line-height: 1.45; }
.edition-cards dt { color: #7b8b96; font-weight: 700; }
.edition-cards dd { margin: 0; color: #3e5566; }
.translated-edition-card { border-color: #c4ddd9 !important; background: #f4faf9 !important; }
.profile-citation { margin-top: 1rem; padding: 1rem; border: 1px solid #d7c797; border-radius: .7rem; background: #fffdf7; }
.profile-citation p { margin: 0 0 .85rem; color: #3a4e5e; font-family: Georgia, "Times New Roman", serif; font-size: .78rem; line-height: 1.6; }
.profile-citation button { display: inline-flex; align-items: center; gap: .42rem; min-height: 34px; padding: 0 .75rem; border: 1px solid #cdbd8e; border-radius: .42rem; color: #685522; background: #fff; cursor: pointer; font-size: .7rem; font-weight: 800; }
.profile-citation button:hover, .profile-citation button.copied { color: #fff; background: #886c28; }
.profile-citation small { margin-left: .55rem; color: var(--teal); font-size: .68rem; font-weight: 700; }
.profile-sources { margin-top: 1rem !important; color: #71818c !important; font-family: Inter, sans-serif !important; font-size: .68rem !important; line-height: 1.5 !important; }
.profile-sources a { color: #0f6f69; font-weight: 700; }

button:focus-visible, input:focus-visible, a:focus-visible { outline: 3px solid rgba(37, 176, 160, .45); outline-offset: 2px; }

@media (max-width: 1180px) {
  .workspace { grid-template-columns: 315px minmax(500px, 1fr); }
  .source-panel { display: none; }
}

@media (max-width: 820px) {
  .site-header { grid-template-columns: 1fr auto; height: 68px; padding: 0 1rem; }
  .top-nav { display: none; }
  .mobile-menu { display: grid; }
  .brand { width: 88px; min-height: 91px; margin-left: -.25rem; padding: 0; border-radius: 0 0 .78rem .78rem; }
  .brand-lockup { width: 88px; height: 91px; }
  .brand-lockup img { top: -6px; height: 102px; }
  .ask-strip { grid-template-columns: 1fr; gap: 1rem; padding: 1.25rem 1rem; }
  .ask-heading { justify-self: start; }
  .ask-response { grid-column: 1; }
  .workspace { display: block; height: 100%; min-height: 0; overflow: hidden; }
  .library-panel { position: fixed; z-index: 20; top: 68px; bottom: 0; left: 0; width: min(92vw, 350px); overflow: hidden; transform: translateX(-105%); transition: transform .25s ease; box-shadow: var(--shadow); }
  .library-tree { height: calc(100vh - 68px - 58px - 66px); }
  .library-panel.open { transform: translateX(0); }
  .reader { height: 100%; min-height: 0; padding: 1rem 1rem .75rem; }
  .reader-header { align-items: flex-start; flex-direction: column; }
  .text-columns { grid-template-columns: 1fr; }
  .text-columns > section + section { padding: 1.5rem 0 0; border-left: 0; border-top: 1px solid var(--line); }
  .book-profile-modal { width: calc(100vw - 20px); height: calc(100vh - 20px); }
  .book-profile-header { min-height: 100px; padding: .8rem; }
  .book-profile-identity img { width: 46px; height: 64px; }
  .book-profile-identity h2 { font-size: 1.28rem; }
  .book-profile-identity p { font-size: .74rem; }
  .book-profile-body { display: block; overflow: hidden; }
  .book-profile-nav { display: flex; gap: .35rem; padding: .65rem .75rem; overflow-x: auto; border-right: 0; border-bottom: 1px solid var(--line); white-space: nowrap; }
  .book-profile-nav::before { display: none; }
  .book-profile-nav button { width: auto; min-height: 34px; flex: 0 0 auto; margin: 0; padding: .45rem .65rem; border-left: 0; border-bottom: 2px solid transparent; border-radius: .38rem; }
  .book-profile-nav button.active { border-left-color: transparent; border-bottom-color: var(--teal); }
  .book-profile-content { height: calc(100% - 58px); }
  .profile-section { padding: 1.7rem 1.25rem; }
}

@media (max-width: 520px) {
  .ask-form { height: auto; min-height: 54px; padding-right: .3rem; }
  .ask-form button { padding: 0 .85rem; }
  .ask-form input { font-size: .9rem; }
  .view-switcher { width: 100%; }
  .view-switcher button { flex: 1; }
  .reader-footer { flex-wrap: wrap; }
  .reader-footer > span { order: -1; width: 100%; text-align: center; }
  .page-numbers { display: none; }
  .page-status { display: inline-block; }
  .book-profile-identity p { display: none; }
  .method-grid, .edition-cards { grid-template-columns: 1fr; }
  .profile-section-heading h3 { font-size: 1.2rem; }
}

/* Külliyat Meydanı — ana sayfa ve yeni bilgi mimarisi */
body { grid-template-rows: var(--header-height) minmax(0, 1fr); }
.site-header { height: var(--header-height); }
.site-header { position: relative; z-index: 50; }
.app-screen[hidden] { display: none !important; }
.home-screen, .catalog-screen, .work-screen { min-height: 0; height: 100%; overflow-y: auto; background: #fff; scrollbar-width: thin; scrollbar-color: #bdcbd3 transparent; }
.home-screen { display: flex; flex-direction: column; }
.site-header .top-nav { align-items: stretch; }
.nav-item { font-size: .84rem; }

.home-hero { position: relative; min-height: 400px; display: flex; align-items: center; padding: 2.4rem max(8vw, 3rem); color: #fff; background-image: linear-gradient(90deg, rgba(4,24,37,.87) 0%, rgba(4,31,43,.58) 54%, rgba(4,31,43,.3) 100%), url("./assets/library-hero.png"); background-size: cover; background-position: center; }
.home-hero-content { width: 100%; }
.verse-heading { width: min(553px, 100%); margin-inline: auto; text-align: center; }
.verse-art-title { margin: 0; font: inherit; line-height: 0; }
.verse-calligraphy { display: block; width: 100%; max-height: 133px; object-fit: contain; }
.verse-turkish { margin: .35rem 0 0; color: #edf2f3; font: italic 1.08rem/1.45 "Iowan Old Style", Baskerville, Georgia, "Times New Roman", serif; }
.verse-heading > span { display: block; margin-top: .38rem; color: #d7bc75; font-size: .59rem; font-weight: 800; letter-spacing: .13em; }
.rasih-search-panel { display: grid; grid-template-columns: 132px minmax(0, 1fr) 76px; gap: .45rem; align-items: center; width: min(920px, 100%); min-height: 72px; margin: 1.55rem auto 0; padding: .48rem; border: 1px solid rgba(255,255,255,.72); border-radius: .92rem; background: rgba(255,255,255,.97); box-shadow: 0 18px 42px rgba(2,17,28,.26); }
.search-assistant-brand { display: flex; align-items: center; justify-content: flex-start; min-width: 0; min-height: 50px; padding: 0 .7rem 0 .3rem; border-right: 1px solid #dce4e9; overflow: hidden; }
.search-assistant-brand img { display: block; width: 108px; max-width: 100%; max-height: 52px; object-fit: contain; }
.ask-submit { height: 46px; border: 1px solid var(--navy); border-radius: .58rem; padding: 0 1rem; color: #fff; background: var(--navy); box-shadow: 0 4px 10px rgba(9,38,57,.14); cursor: pointer; font-size: .77rem; font-weight: 800; transition: background .16s ease, transform .16s ease, box-shadow .16s ease; }
.ask-submit:hover { background: #173f5c; box-shadow: 0 6px 14px rgba(9,38,57,.2); transform: translateY(-1px); }
.ask-submit:focus-visible { outline: 3px solid rgba(20,125,118,.28); outline-offset: 2px; }
.home-search { display: flex; align-items: center; width: 100%; min-height: 50px; padding: .15rem .25rem .15rem .85rem; border: 1px solid #d8e2e6; border-radius: .65rem; color: #687d8a; background: #fbfcfc; box-shadow: inset 0 1px 2px rgba(10,39,52,.035); transition: border-color .16s ease, box-shadow .16s ease, background .16s ease; }
.home-search > i { flex: 0 0 auto; color: #748895; font-size: 1.08rem; }
.home-search input { min-width: 0; flex: 1; height: 42px; border: 0; outline: 0; padding: 0 .72rem; color: var(--ink); background: transparent; font-size: .88rem; }
.home-search input::placeholder { color: #7d8d97; opacity: 1; }
.home-search button { height: 44px; border: 0; border-radius: .48rem; padding: 0 1.35rem; color: #fff; background: var(--navy); cursor: pointer; font-size: .82rem; font-weight: 800; }
.home-search button:hover { background: #173f5c; }
.home-search:focus-within { border-color: rgba(20,125,118,.58); background: #fff; box-shadow: 0 0 0 3px rgba(20,125,118,.11); }
.home-hero .ask-response { width: min(920px, 100%); margin: .7rem auto 0; font-size: .72rem; }

.home-disciplines, .home-new { padding: 1.45rem max(8vw, 3rem) 1.55rem; }
.home-section-heading { display: flex; align-items: end; justify-content: space-between; gap: 2rem; }
.home-section-heading > div { min-width: 0; }
.home-section-heading > div > span, .catalog-kicker, .catalog-result-heading span, .work-section-heading > span { color: var(--teal); font-size: .61rem; font-weight: 850; letter-spacing: .18em; }
.home-section-heading h2 { margin: .12rem 0 .1rem; color: var(--navy); font: 600 1.68rem/1.12 Georgia, "Times New Roman", serif; }
.home-section-heading p { margin: 0; color: #738592; font-size: .72rem; }
.home-new .home-section-heading { justify-content: center; text-align: center; }
.home-section-heading button, .home-section-action button, .catalog-hero nav button, .work-breadcrumb button { border: 0; padding: .35rem; color: var(--navy); background: transparent; cursor: pointer; font-size: .68rem; font-weight: 800; }
.home-section-heading button i, .home-section-action button i { margin-left: .35rem; }
.home-section-action { display: flex; justify-content: flex-end; margin-bottom: .8rem; }
.site-footer { display: grid; grid-template-columns: minmax(120px, 1fr) auto minmax(120px, 1fr); align-items: center; gap: 2rem; margin-top: auto; padding: 1.2rem max(8vw, 3rem); color: #c8d3db; background: var(--navy-deep); border-top: 1px solid rgba(215,172,79,.32); }
.site-footer-brand { display: flex; align-items: baseline; gap: .65rem; min-width: 0; }
.site-footer-brand strong { color: #fff; font: 600 1.02rem/1 "Iowan Old Style", Baskerville, Georgia, "Times New Roman", serif; }
.site-footer-brand span { color: #8fa2b0; font-size: .55rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.site-footer nav { grid-column: 2; display: flex; align-items: center; justify-content: center; gap: 1.5rem; }
.site-footer nav button { border: 0; padding: .3rem 0; color: #d7e0e5; background: transparent; cursor: pointer; font-size: .68rem; font-weight: 650; }
.site-footer nav button:hover, .site-footer nav button:focus-visible { color: #fff; }
.site-footer > small { grid-column: 3; justify-self: end; color: #748997; font-size: .58rem; }
.site-info-modal { width: min(520px, calc(100% - 2rem)); padding: 0; border: 0; border-radius: .8rem; color: var(--ink); background: transparent; box-shadow: 0 28px 70px rgba(3,20,32,.32); }
.site-info-modal::backdrop { background: rgba(5,23,36,.58); backdrop-filter: blur(3px); }
.site-info-shell { position: relative; padding: 2.2rem 2.3rem 2.4rem; background: #fff; border-top: 3px solid var(--gold); }
.site-info-close { position: absolute; top: .8rem; right: .8rem; display: grid; place-items: center; width: 34px; height: 34px; border: 0; border-radius: 50%; color: #5e7280; background: #f1f5f6; cursor: pointer; }
.site-info-kicker { color: var(--teal); font-size: .58rem; font-weight: 850; letter-spacing: .18em; }
.site-info-shell h2 { margin: .45rem 0 .75rem; color: var(--navy); font: 600 1.65rem/1.15 Georgia, "Times New Roman", serif; }
.site-info-shell p { margin: 0; color: #526776; font-size: .86rem; line-height: 1.75; }
.discipline-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); max-width: 1280px; margin: .9rem auto 0; overflow: hidden; border: 1px solid #e0e6e8; border-radius: .7rem; background: #fff; box-shadow: 0 10px 28px rgba(15,42,58,.04); }
.discipline-tile { position: relative; display: grid; grid-template-columns: 42px minmax(0, 1fr); gap: .65rem; align-items: center; min-height: 72px; border: 0; padding: .62rem .72rem; color: var(--navy); background: #fff; box-shadow: inset -1px -1px #e8ecee; cursor: pointer; text-align: left; transition: background .18s ease, color .18s ease; }
.discipline-symbol { display: grid; place-items: center; width: 38px; height: 42px; border: 1px solid #e7dfce; border-radius: 19px 19px 8px 8px; color: #27485d; background: #faf8f2; transition: color .18s ease, background .18s ease, border-color .18s ease, transform .18s ease; }
.discipline-symbol i { font-size: 1.18rem; }
.discipline-copy { min-width: 0; }
.discipline-copy strong { display: block; color: inherit; font: 700 .72rem/1.25 Georgia, "Times New Roman", serif; }
.discipline-copy small { display: block; margin-top: .18rem; color: #7b8b95; font-size: .53rem; line-height: 1.3; }
.discipline-tile::after { content: ""; position: absolute; left: 0; bottom: 0; width: 0; height: 2px; background: var(--gold); transition: width .22s ease; }
.discipline-tile:hover, .discipline-tile.active { color: #0c354d; background: #fbfcfb; }
.discipline-tile:hover .discipline-symbol, .discipline-tile.active .discipline-symbol { color: var(--gold); background: var(--navy); border-color: var(--navy); transform: translateY(-1px); }
.discipline-tile:hover::after, .discipline-tile.active::after { width: 100%; }
.discipline-tile:focus-visible { z-index: 1; outline: 3px solid rgba(20,125,118,.28); outline-offset: -3px; }
.home-toast { min-height: 1em; margin: .35rem 0 0; color: #718493; text-align: center; font-size: .68rem; }

.home-new { flex: 1; border-top: 1px solid #e1e7e7; background: #fbfcfc; }
.recent-works { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); max-width: 1120px; margin: 1.2rem auto 0; border-top: 1px solid #dce4e6; }
.recent-work { display: grid; grid-template-columns: 76px minmax(0, 1fr) 18px; gap: 1rem; align-items: center; min-height: 128px; padding: 1rem .8rem; border-bottom: 1px solid #dce4e6; cursor: pointer; }
.recent-work:not(:nth-child(3n + 1)) { border-left: 1px solid #dce4e6; }
.recent-work:hover { background: #f3f8f7; }
.recent-work:focus-visible, .catalog-work-row:focus-visible { outline: 3px solid rgba(20,125,118,.35); outline-offset: 3px; }
.recent-work > img { width: 66px; height: 92px; justify-self: center; border-radius: 2px 5px 5px 2px; object-fit: cover; box-shadow: 0 5px 12px rgba(8,35,45,.12); }
.recent-work-copy { min-width: 0; }
.recent-work-copy > span { color: #8b713b; font-size: .57rem; font-weight: 750; letter-spacing: .08em; }
.recent-work-copy h3 { margin: .2rem 0; color: var(--navy); font: 700 1.13rem/1.2 Georgia, "Times New Roman", serif; }
.recent-work-copy p { margin: 0; color: #536b79; font-size: .73rem; }
.recent-work-copy small { display: block; margin-top: .65rem; color: #667c88; font-size: .65rem; line-height: 1.45; }
.recent-work > i { align-self: end; margin-bottom: .3rem; color: #7b8d95; font-size: .85rem; }

.catalog-screen, .work-screen { background: #f8faf9; }
.catalog-hero { padding: 2.15rem max(10vw, 3rem) 2rem; color: #fff; background: radial-gradient(circle at 85% -40%, rgba(59,162,151,.28), transparent 42%), linear-gradient(120deg, #0b2235, #104f51); }
.catalog-hero nav, .work-breadcrumb { display: flex; align-items: center; gap: .38rem; margin-bottom: 1.25rem; color: #b9ccd3; font-size: .68rem; }
.catalog-hero nav button { color: #c4d6dc; }
.catalog-hero nav i, .work-breadcrumb i { font-size: .58rem; }
.catalog-hero .catalog-kicker { color: #8fd6ce; }
.catalog-hero h1 { margin: .28rem 0 .42rem; font: 600 2.65rem Georgia, "Times New Roman", serif; }
.catalog-hero > p { max-width: 760px; margin: 0; color: #c7d7dc; font: .94rem/1.6 Georgia, "Times New Roman", serif; }
.catalog-body { max-width: 1180px; margin: 0 auto; padding: 1.4rem 2rem 3rem; }
.catalog-subcategories { display: flex; gap: .35rem; margin: -.2rem 0 1rem; padding: .42rem; overflow-x: auto; border: 1px solid #d6e1e3; border-radius: .65rem; background: #eef3f3; scrollbar-width: thin; }
.catalog-subcategories button { position: relative; flex: 0 0 auto; min-height: 40px; border: 1px solid transparent; border-radius: .42rem; padding: 0 .9rem; color: #415b6b; background: transparent; cursor: pointer; font-size: .72rem; font-weight: 800; white-space: nowrap; transition: color .16s ease, background .16s ease, border-color .16s ease; }
.catalog-subcategories button::after { content: ""; position: absolute; right: .9rem; bottom: 4px; left: .9rem; height: 2px; border-radius: 999px; background: transparent; }
.catalog-subcategories button:hover { border-color: #cbd9dc; color: var(--navy); background: rgba(255,255,255,.62); }
.catalog-subcategories button.active { border-color: #cbd8da; color: var(--navy); background: #fff; box-shadow: 0 2px 8px rgba(10,38,49,.08); }
.catalog-subcategories button.active::after { background: var(--gold); }
.catalog-subcategories button:focus-visible { outline: 2px solid rgba(20,125,118,.35); outline-offset: -2px; }
.catalog-toolbar { display: grid; grid-template-columns: minmax(280px, 1.7fr) repeat(3, minmax(150px, .6fr)) auto; gap: .55rem; padding: .8rem; border: 1px solid #dce5e7; border-radius: .7rem; background: #fff; }
.catalog-toolbar label { display: flex; align-items: center; min-width: 0; height: 40px; padding: 0 .7rem; border: 1px solid #d6e0e4; border-radius: .45rem; color: #758893; }
.catalog-toolbar input { min-width: 0; width: 100%; border: 0; outline: 0; padding-left: .55rem; color: var(--ink); background: transparent; font-size: .75rem; }
.catalog-toolbar select { min-width: 0; border: 1px solid #d6e0e4; border-radius: .45rem; padding: 0 .65rem; color: #4f6574; background: #fff; font-size: .7rem; font-weight: 700; }
.catalog-toolbar > button { border: 0; padding: 0 .5rem; color: var(--teal); background: transparent; cursor: pointer; font-size: .7rem; font-weight: 800; }
.catalog-toolbar > button:disabled { color: #a6b1b7; cursor: default; }
.catalog-result-heading { display: flex; align-items: end; justify-content: space-between; margin: 2rem 0 .8rem; }
.catalog-result-heading h2 { margin: .16rem 0 0; color: var(--navy); font: 600 1.7rem Georgia, "Times New Roman", serif; }
.catalog-result-heading p { margin: 0; color: #758690; font-size: .72rem; }
.catalog-work-row { display: grid; grid-template-columns: 106px minmax(0, 1fr) 150px; gap: 1.4rem; align-items: center; padding: 1.2rem; border-top: 1px solid #d7e1e4; border-bottom: 1px solid #d7e1e4; background: #fff; cursor: pointer; transition: background .18s ease; }
#catalogWorkList .catalog-work-row + .catalog-work-row { border-top: 0; }
.catalog-work-row[hidden], .catalog-empty[hidden] { display: none !important; }
.catalog-work-row:hover { background: #f2f8f7; }
.catalog-work-row > img { width: 88px; height: 122px; justify-self: center; object-fit: cover; box-shadow: 0 6px 16px rgba(10,35,47,.16); }
.work-type { color: #a07928; font-size: .59rem; font-weight: 850; letter-spacing: .13em; }
.catalog-work-row h3 { margin: .2rem 0 .16rem; color: var(--navy); font: 700 1.38rem Georgia, "Times New Roman", serif; }
.catalog-work-row p { margin: 0; color: #455e70; font-size: .78rem; }
.catalog-work-row p small { color: #7a8993; }
.catalog-work-row ul { display: flex; gap: .4rem; margin: .65rem 0 .55rem; padding: 0; list-style: none; }
.catalog-work-row li { padding: .27rem .5rem; border-radius: 999px; color: #3e6966; background: #eaf5f3; font-size: .62rem; font-weight: 750; }
.catalog-work-row div > small { color: #71828e; font-size: .68rem; }
.catalog-work-end { display: flex; min-height: 94px; flex-direction: column; align-items: center; justify-content: center; border-left: 1px solid #e0e6e8; color: var(--navy); }
.catalog-work-end strong { font: 700 1.05rem Georgia, serif; }
.catalog-work-end span { margin: .2rem 0 .7rem; color: #788994; font-size: .64rem; }
.catalog-work-end i { font-size: 1.1rem; }
.catalog-empty { min-height: 260px; display: grid; place-items: center; align-content: center; gap: .4rem; color: #738691; text-align: center; }
.catalog-empty i { font-size: 2rem; }.catalog-empty strong { color: var(--navy); font-family: Georgia, serif; }.catalog-empty p { margin: 0; font-size: .75rem; }

.work-screen { padding-bottom: 3rem; }
.work-breadcrumb { max-width: 1180px; margin: 0 auto; padding: 1.4rem 2rem .8rem; color: #71838e; }
.work-breadcrumb button { color: #536c7d; }
.work-intro { display: grid; grid-template-columns: 180px minmax(0, 1fr) 230px; gap: 2.4rem; max-width: 1120px; margin: 0 auto; padding: 2rem 2.25rem; border: 1px solid #dce5e7; border-radius: .8rem; background: #fff; }
.work-intro > img { width: 148px; height: 204px; justify-self: center; border-radius: 3px 7px 7px 3px; object-fit: cover; box-shadow: 0 12px 28px rgba(11,34,46,.2); }
.work-intro > div > span { color: #a27d31; font-size: .62rem; font-weight: 850; letter-spacing: .14em; }
.work-intro h1 { margin: .3rem 0 .25rem; color: var(--navy); font: 700 2.25rem Georgia, "Times New Roman", serif; }
.work-author { margin: 0 0 .85rem !important; color: #3f5a6d !important; font: 700 .86rem Inter, sans-serif !important; }
.work-author small { color: #7a8992; font-weight: 600; }
.work-intro > div > p { max-width: 620px; margin: 0; color: #566d7c; font: .88rem/1.7 Georgia, "Times New Roman", serif; }
.work-intro-actions { display: flex; gap: .55rem; margin-top: 1.2rem; }
.work-intro-actions button { min-height: 40px; border: 1px solid var(--navy); border-radius: .46rem; padding: 0 .9rem; color: var(--navy); background: #fff; cursor: pointer; font-size: .72rem; font-weight: 800; }
.work-intro-actions button:first-child { color: #fff; background: var(--navy); }
.work-intro dl { margin: 0; padding-left: 1.25rem; border-left: 1px solid #dfe6e8; }
.work-intro dl div { padding: .6rem 0; border-bottom: 1px solid #e5eaec; }
.work-intro dt { color: #7b8b95; font-size: .63rem; }
.work-intro dd { margin: .15rem 0 0; color: var(--navy); font-size: .78rem; font-weight: 750; }
.work-contents { max-width: 1120px; margin: 1.5rem auto 0; padding: 0 .1rem; }
.work-section-heading { margin-bottom: .8rem; }
.work-section-heading h2 { margin: .2rem 0 .15rem; color: var(--navy); font: 600 1.55rem Georgia, serif; }
.work-section-heading p { margin: 0; color: #738590; font-size: .72rem; }
.work-chapter-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid #d7e1e4; }
.work-chapter-list button { display: grid; grid-template-columns: 36px 1fr auto; gap: .7rem; align-items: center; min-height: 68px; border: 0; border-bottom: 1px solid #d7e1e4; padding: .65rem .9rem; color: var(--navy); background: transparent; cursor: pointer; text-align: left; }
.work-chapter-list button:nth-child(odd) { border-right: 1px solid #d7e1e4; }
.work-chapter-list button:hover { background: #edf6f4; }
.work-chapter-list button > span { color: #9b7a32; font-size: .68rem; font-weight: 800; }
.work-chapter-list strong { display: block; font: 700 .84rem Georgia, serif; }.work-chapter-list small { display: block; margin-top: .2rem; color: #7b8b95; font-size: .65rem; }.work-chapter-list i { color: var(--teal); }
.work-chapter-list button[data-status="progress"] small { color: #c47b16; }

/* Okuma ekranı artık yalnızca eserin içindekiler ağacını gösterir. */
#readerView { height: 100%; background: #edf2f3; }
#readerView .library-panel { margin-top: 0; padding-top: 0; border-top: 0; background: #f5f7f7; }
#readerView .library-toolbar { justify-content: flex-end; height: 54px; padding: 0 .2rem; border-bottom: 1px solid #dde5e7; background: rgba(255,255,255,.55); }
#readerView .library-toolbar .expand-all { color: #5e7380; font-size: .65rem; font-weight: 750; letter-spacing: .035em; }
#readerView .library-search, #readerView .discipline-toggle, #readerView .selected-book, #readerView .book-actions, #readerView .tafsir-filters, #readerView .other-disciplines { display: none; }
#readerView .library-tree { height: calc(100dvh - var(--header-height) - 54px); min-height: 0; padding-top: .8rem; }
#readerView .discipline-content { margin: 0; padding: 0 .25rem; border-left: 0; }
#readerView .chapter-tree { padding: 0; }
#readerView .tree-heading { border-top: 0; }
#readerView .chapter-filters { display: none; }
#readerView .library-panel .chapter { min-height: 52px; }
#readerView .reader { padding-top: 1.6rem; background: #fff; box-shadow: 0 0 0 1px rgba(20,45,60,.04); }
#readerView .reader-header { padding-bottom: 1.1rem; }
#readerView .source-panel { padding-top: 1.7rem; background: #f8faf9; }
#readerView .source-panel > section:first-child { position: relative; }
#readerView .source-panel > section:first-child::before { content: ""; position: absolute; top: -.65rem; left: 0; width: 38px; height: 2px; border-radius: 999px; background: #b99a54; }

@media (max-width: 1100px) {
  .recent-works { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .recent-work:not(:nth-child(3n + 1)) { border-left: 0; }
  .recent-work:nth-child(even) { border-left: 1px solid #dce4e6; }
  .discipline-grid { grid-template-columns: repeat(3, 1fr); }
  .catalog-toolbar { grid-template-columns: 1fr 1fr; }
  .catalog-toolbar label { grid-column: 1 / -1; }
  .work-intro { grid-template-columns: 150px 1fr; }
  .work-intro dl { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(4, 1fr); padding: 0; border-left: 0; border-top: 1px solid #dfe6e8; }
}

@media (max-width: 820px) {
  :root { --header-height: 76px; }
  body { grid-template-rows: var(--header-height) minmax(0, 1fr); }
  .site-header { height: var(--header-height); grid-template-columns: 1fr auto; padding: 0 1rem; }
  .brand { width: 82px; height: var(--header-height); min-height: 0; margin-left: 0; border-radius: 0 0 .7rem .7rem; }
  .brand-lockup { width: 82px; height: var(--header-height); border-radius: 0 0 .7rem .7rem; }
  .brand-lockup img { top: -6px; height: 91px; }
  .home-hero { min-height: 470px; padding: 2.2rem 1.25rem; }
  .rasih-search-panel { grid-template-columns: minmax(0, 1fr) 72px; margin-top: 1.35rem; }
  .search-assistant-brand { grid-column: 1 / -1; min-height: 46px; padding: 0 .4rem .35rem; border-right: 0; border-bottom: 1px solid #e0e6e9; }
  .search-assistant-brand img { width: 100px; max-height: 46px; }
  .ask-submit { grid-column: 2; }
  .home-disciplines, .home-new { padding: 1.5rem 1.1rem; }
  .site-footer { grid-template-columns: 1fr; gap: .85rem; padding: 1.3rem 1.25rem; }
  .site-footer-brand { flex-direction: column; gap: .25rem; }
  .site-footer nav { grid-column: 1; flex-wrap: wrap; justify-content: flex-start; gap: .7rem 1.25rem; }
  .site-footer > small { grid-column: 1; justify-self: start; }
  .discipline-grid { grid-template-columns: repeat(2, 1fr); }
  .recent-works { grid-template-columns: 1fr; }
  .recent-work:nth-child(even) { border-left: 0; }
  .catalog-hero { padding: 1.7rem 1.25rem; }
  .catalog-body { padding: 1rem; }
  .catalog-toolbar { grid-template-columns: 1fr; }
  .catalog-toolbar label { grid-column: auto; }
  .catalog-work-row { grid-template-columns: 80px 1fr; padding: .9rem; }
  .catalog-work-row > img { width: 68px; height: 96px; }.catalog-work-end { grid-column: 1 / -1; min-height: auto; flex-direction: row; gap: .55rem; padding-top: .7rem; border-left: 0; border-top: 1px solid #e0e6e8; }
  .work-breadcrumb { padding: 1rem; }.work-intro { grid-template-columns: 100px 1fr; gap: 1.2rem; margin: 0 1rem; padding: 1.2rem; }.work-intro > img { width: 90px; height: 126px; }.work-intro h1 { font-size: 1.65rem; }.work-intro dl { grid-template-columns: repeat(2, 1fr); }.work-contents { margin: 1.2rem 1rem; }.work-chapter-list { grid-template-columns: 1fr; }.work-chapter-list button:nth-child(odd) { border-right: 0; }
  #readerView .library-tree { height: calc(100dvh - var(--header-height) - 54px); }
  .library-panel { top: var(--header-height); }
  .site-header.mobile-nav-open .top-nav { position: absolute; top: calc(var(--header-height) - 8px); right: 1rem; display: grid; width: 180px; height: auto; padding: .45rem; border: 1px solid rgba(255,255,255,.14); border-radius: .6rem; background: #0b2235; box-shadow: 0 16px 36px rgba(0,0,0,.25); }
  .site-header.mobile-nav-open .nav-item { min-height: 40px; border-radius: .4rem; text-align: left; }
  .site-header.mobile-nav-open .nav-item.active::after { inset: auto auto 7px 8px; width: 24px; }
}

@media (max-width: 520px) {
  .verse-calligraphy { max-height: 106px; }
  .verse-turkish { font-size: 1rem; }
  .rasih-search-panel { padding: .5rem; }
  .home-search button { padding: 0 .8rem; }
  .home-section-heading { align-items: start; }
  .home-section-heading > button { display: none; }
  .discipline-grid { grid-template-columns: 1fr; }
  .discipline-tile { min-height: 68px; grid-template-columns: 40px minmax(0, 1fr); padding: .6rem .7rem; }
  .discipline-symbol { width: 36px; height: 40px; border-radius: 18px 18px 8px 8px; }
  .recent-work { grid-template-columns: 62px minmax(0, 1fr) 14px; gap: .75rem; min-height: 108px; padding: .8rem .25rem; }
  .recent-work > img { width: 56px; height: 78px; }
  .recent-work-copy h3 { font-size: 1rem; }
  .recent-work-copy small { margin-top: .45rem; }
  .work-intro { grid-template-columns: 1fr; text-align: center; }.work-intro-actions { justify-content: center; }.work-intro dl { text-align: left; }
}

/* Râsih 2026 — çağdaş neşir sistemi. Logo çentiği özgün biçimiyle korunur. */
:root {
  --header-height: 88px;
  --modern-ink: #142b2a;
  --modern-ink-soft: #536664;
  --modern-paper: #f8f7f2;
  --modern-mist: #edf0eb;
  --modern-sage: #e2e8e2;
  --modern-rust: #b6573f;
  --modern-line: #d4dbd5;
  --masthead-surface: linear-gradient(112deg, rgba(7, 23, 38, .96) 0%, rgba(12, 36, 55, .94) 48%, rgba(8, 27, 45, .97) 100%);
}

body { grid-template-rows: var(--header-height) minmax(0, 1fr); background: var(--modern-paper); }

.site-header {
  isolation: isolate;
  height: var(--header-height);
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr);
  gap: 0;
  padding: 0 clamp(1.25rem, 3.2vw, 3.75rem);
  color: #f1f6f9;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.site-header::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  border: 0;
  border-radius: 0 0 24px 24px;
  background: linear-gradient(112deg, #071725 0%, #0b2638 52%, #071b2d 100%);
  box-shadow: 0 12px 30px rgba(4, 19, 31, .14);
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
}

.brand {
  align-self: start;
  z-index: 2;
  width: 108px;
  height: 114px;
  min-height: 114px;
  overflow: hidden;
  border: 0;
  border-top: 0;
  border-radius: 0 0 20px 20px;
  box-shadow: 0 15px 34px rgba(3, 18, 29, .2);
  transition: transform .22s ease, box-shadow .22s ease;
}

.brand:hover { transform: translateY(2px); box-shadow: 0 12px 26px rgba(3, 18, 29, .18); }

.brand-lockup {
  width: 108px;
  height: 114px;
  border-radius: 0 0 20px 20px;
}

.brand-lockup img { top: -14px; height: 146px; }

.site-header .top-nav {
  justify-self: center;
  align-items: center;
  align-self: center;
  height: 44px;
  margin: 0;
  gap: .2rem;
  padding: 4px;
  border: 1px solid rgba(221, 234, 242, .1);
  border-radius: 999px;
  background: rgba(255, 255, 255, .035);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .04);
}

.nav-item {
  min-height: 34px;
  border-radius: 999px;
  padding: 0 1.05rem;
  color: #b9c9d4;
  background: transparent;
  font-size: .79rem;
  font-weight: 600;
  letter-spacing: .005em;
  transition: color .18s ease, background .18s ease, box-shadow .18s ease;
}

.nav-item:hover, .nav-item:focus-visible { color: #fff; background: rgba(255, 255, 255, .06); }
.nav-item.active {
  color: #fff;
  background: rgba(240, 246, 249, .11);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .055), 0 4px 14px rgba(2, 15, 25, .12);
}
.nav-item.active::after { display: none; }

.site-header .header-actions {
  align-self: center;
  height: 42px;
  gap: .4rem;
  padding: 3px;
  border: 1px solid rgba(221, 234, 242, .1);
  border-radius: 999px;
  background: rgba(255,255,255,.035);
}
.site-header .profile-button, .site-header .icon-button {
  border: 0;
  border-radius: 999px;
  color: #c2d2dc;
  background: transparent;
  box-shadow: none;
}
.site-header .profile-button { width: 34px; height: 34px; font-size: .66rem; font-weight: 650; letter-spacing: .07em; }
.site-header .profile-button:hover, .site-header .icon-button:hover { color: #fff; background: rgba(255,255,255,.07); }
.site-header button:focus-visible, .site-header .brand:focus-visible { outline: 2px solid #c7d9e5; outline-offset: 5px; }

.home-hero { min-height: 390px; padding-left: max(10vw, 9rem); }

.catalog-screen, .work-screen { background: var(--modern-paper); }
.catalog-hero {
  position: relative;
  padding: 4rem max(10vw, 3rem) 3.5rem;
  color: var(--modern-ink);
  background: var(--modern-sage);
  border-bottom: 1px solid #ccd5ce;
}
.catalog-hero::after {
  content: "";
  position: absolute;
  right: max(5vw, 2rem);
  bottom: 0;
  width: min(34vw, 420px);
  height: 6px;
  background: var(--modern-rust);
}
.catalog-hero nav { color: #6c7c79; }
.catalog-hero nav button { color: #405955; }
.catalog-hero .catalog-kicker { color: var(--modern-rust); }
.catalog-hero h1 { margin-top: .5rem; color: var(--modern-ink); font-family: Inter, ui-sans-serif, sans-serif; font-size: clamp(2.5rem, 5vw, 4.6rem); font-weight: 690; letter-spacing: -.055em; }
.catalog-hero > p { max-width: 680px; color: #536864; font-family: Inter, ui-sans-serif, sans-serif; font-size: .95rem; line-height: 1.7; }
.catalog-body { max-width: 1240px; padding-top: 2.2rem; }
.catalog-subcategories { gap: 1.4rem; padding: 0 0 .8rem; border: 0; border-bottom: 1px solid var(--modern-line); border-radius: 0; background: transparent; }
.catalog-subcategories button { min-height: 34px; border: 0; border-radius: 0; padding: 0; color: #6b7977; }
.catalog-subcategories button::after { right: 0; bottom: -.85rem; left: 0; background: transparent; }
.catalog-subcategories button:hover { border: 0; color: var(--modern-ink); background: transparent; }
.catalog-subcategories button.active { border: 0; color: var(--modern-ink); background: transparent; box-shadow: none; }
.catalog-subcategories button.active::after { background: var(--modern-rust); }
.catalog-toolbar { margin-top: 1.6rem; padding: .65rem 0; border: 0; border-bottom: 1px solid var(--modern-line); border-radius: 0; background: transparent; }
.catalog-toolbar label, .catalog-toolbar select { border-color: #cbd4ce; border-radius: .2rem; background: rgba(255,255,255,.55); }
.catalog-result-heading h2 { font-family: Inter, ui-sans-serif, sans-serif; font-weight: 680; letter-spacing: -.035em; }
.catalog-work-row { border-color: var(--modern-line); background: transparent; }
.catalog-work-row:hover { background: #edf2ed; }
.catalog-work-row h3 { font-family: Inter, ui-sans-serif, sans-serif; font-weight: 690; letter-spacing: -.025em; }
.catalog-work-row li { border-radius: .2rem; color: #49605c; background: #e4eae4; }

.work-breadcrumb { padding-top: 3.5rem; }
.work-intro { max-width: 1180px; grid-template-columns: 200px minmax(0,1fr) 250px; padding: 2.4rem 0; border: 0; border-top: 1px solid var(--modern-line); border-bottom: 1px solid var(--modern-line); border-radius: 0; background: transparent; }
.work-intro > img { width: 160px; height: 224px; box-shadow: 0 16px 36px rgba(20,43,42,.14); }
.work-intro h1 { font-family: Inter, ui-sans-serif, sans-serif; font-size: clamp(2.1rem,4vw,3.5rem); font-weight: 690; letter-spacing: -.05em; }
.work-intro > div > span { color: var(--modern-rust); }
.work-intro-actions button { border-radius: .2rem; }
.work-intro-actions button:first-child { border-color: var(--modern-ink); background: var(--modern-ink); }
.work-chapter-list button:hover { background: #e8eee8; }

.workspace { grid-template-columns: 258px minmax(560px, 1fr) 304px; background: #e8ede8; }
.library-panel, .source-panel { border-color: #cfd7d1; }
#readerView .library-panel { padding: 0 1rem 1rem; background: #e4e9e4; }
#readerView .library-toolbar {
  height: 78px;
  align-items: end;
  padding: 0 .35rem 1rem;
  border-bottom-color: #ccd5ce;
  background: transparent;
}
#readerView .library-toolbar .expand-all { color: #4e625e; font-size: .68rem; letter-spacing: .06em; text-transform: uppercase; }
#readerView .library-tree { height: calc(100dvh - var(--header-height) - 78px); padding-top: 1rem; }
#readerView .tree-heading button { color: var(--modern-ink); }
#readerView .library-panel .chapter { min-height: 48px; border-radius: .2rem; }
#readerView .library-panel .chapter:hover { background: rgba(255,255,255,.48); }
#readerView .library-panel .chapter.active { border-left-color: var(--modern-rust); background: rgba(255,255,255,.64); }

#readerView .reader { padding: 2rem clamp(2rem,3vw,3.6rem) 1rem; background: var(--modern-paper); box-shadow: none; }
#readerView .reader-header { align-items: center; padding-bottom: 1.4rem; border-color: var(--modern-line); }
.breadcrumb { color: #75827f; font-size: .7rem; }
.breadcrumb b { color: var(--modern-rust); }
.reader-header h2 { font-family: Inter, ui-sans-serif, sans-serif; font-size: clamp(2rem,3vw,3rem); font-weight: 690; letter-spacing: -.055em; }
.reader-header p { color: #60716e; }
.view-switcher { padding: .2rem; border: 0; border-radius: .25rem; background: #e5e9e5; }
.view-switcher button { border-radius: .18rem; padding: .6rem .8rem; }
.view-switcher button.active { color: #fff; background: var(--modern-ink); box-shadow: none; }
.reading-sheet { max-width: 1120px; padding-top: 2.2rem; }
.section-kicker { color: var(--modern-rust); }
.section-kicker span, .section-kicker span:last-child { background: #d8c3bc; }
.text-columns { gap: clamp(2rem,4vw,4rem); }
.text-columns > section + section { border-left-color: var(--modern-line); }
.text-columns h3 { color: #687875; background: rgba(248,247,242,.95); font-family: Inter, ui-sans-serif, sans-serif; }
.prose { color: #263a38; font-family: "Iowan Old Style", Baskerville, Georgia, serif; font-size: 1.06rem; }
.arabic-prose { color: #1d3533; }
.print-page-break { color: #9a5747; }
.print-page-break::before, .print-page-break::after { background: #ddc8c1; }
.verse-block { border-color: #d8ddd7; border-radius: .2rem; background: #f3f3ed; }
.pagination, .reader-footer { border-color: var(--modern-line); background: var(--modern-paper); }
.page-number, .page-arrow { border-radius: .2rem; }
.page-number.active { border-color: var(--modern-ink); background: var(--modern-ink); }

#readerView .source-panel { padding: 2.25rem 1.5rem; background: #f0eee8; }
#readerView .source-panel > section:first-child::before { width: 32px; background: var(--modern-rust); }
.source-panel h2 { color: var(--modern-ink); font-family: Inter, ui-sans-serif, sans-serif; font-size: 1.15rem; font-weight: 690; letter-spacing: -.025em; }
.source-panel dt { color: #74817e; }
.source-panel dd { color: #334946; }
.citation-box p { color: #384d49; font-family: "Iowan Old Style", Baskerville, Georgia, serif; }
.citation-box button { border-radius: .2rem; }

@media (max-width: 820px) {
  :root { --header-height: 78px; }
  .site-header { height: var(--header-height); grid-template-columns: auto minmax(0,1fr) auto; padding: 0 1.1rem; background: #071725; }
  .site-header::before { inset: 0; border-radius: 0 0 18px 18px; }
  .brand { width: 82px; height: 96px; min-height: 96px; border-radius: 0 0 15px 15px; box-shadow: 0 11px 25px rgba(3,18,29,.18); }
  .brand-lockup { width: 82px; height: 96px; border-radius: 0 0 15px 15px; }
  .brand-lockup img { top: -9px; height: 116px; }
  .site-header .top-nav { margin: 0; }
  .site-header .header-actions { grid-column: 3; width: 42px; height: 42px; padding: 3px; border: 1px solid rgba(221,234,242,.1); }
  .site-header .profile-button { display: none; }
  .site-header.mobile-nav-open .top-nav { height: auto; gap: .25rem; padding: .45rem; border: 1px solid rgba(221,234,242,.13); border-radius: 15px; background: rgba(7,23,38,.97); box-shadow: 0 18px 36px rgba(3,18,29,.22); }
  .site-header.mobile-nav-open .nav-item { min-height: 42px; border-radius: 10px; }
  .home-hero { padding-left: 1.25rem; }
  .catalog-hero { padding-top: 3.5rem; }
  .catalog-hero::after { width: 38vw; }
  .work-breadcrumb { padding-top: 3rem; }
  .work-intro { margin-inline: 1rem; padding: 1.5rem 0; }
  .library-panel { top: var(--header-height); }
  #readerView .library-tree { height: calc(100dvh - var(--header-height) - 78px); }
  #readerView .reader { padding: 2.2rem 1rem 1rem; }
}

/* Final masthead guard: prevent the page background from showing through rounded edges. */
.site-header {
  background: #071725 !important;
  border-radius: 0 !important;
  overflow: visible;
}

.site-header::before {
  inset: 0 !important;
  border-radius: 0 !important;
}

@media (max-width: 820px) {
  .site-header { background: #071725 !important; border-radius: 0 !important; }
  .site-header::before { inset: 0 !important; border-radius: 0 !important; }
}
