/* tez.webstree.com · editoryal tez sunumu
   Palet: kemik kâğıt, grafit mürekkep, ret kırmızısı, yöntem çiviti */

:root {
  color-scheme: light;
  --paper: #e9e7df;
  --paper-2: #f3f1ea;
  --ink: #17191b;
  --ink-2: #3b3e41;
  --muted: #5b5e5a;
  --line: rgba(23, 25, 27, .16);
  --line-soft: rgba(23, 25, 27, .08);
  --ret: #a63a2c;
  --ret-soft: rgba(166, 58, 44, .12);
  --slate: #2e4a5e;
  --slate-soft: rgba(46, 74, 94, .12);
  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --page: 1320px;
  --pad: clamp(18px, 4vw, 56px);
}

[data-theme="dark"] {
  color-scheme: dark;
  --paper: #131416;
  --paper-2: #1b1d20;
  --ink: #e9e7df;
  --ink-2: #c9c7bf;
  --muted: #9a9d97;
  --line: rgba(233, 231, 223, .18);
  --line-soft: rgba(233, 231, 223, .09);
  --ret: #d0604e;
  --ret-soft: rgba(208, 96, 78, .14);
  --slate: #8fb0c6;
  --slate-soft: rgba(143, 176, 198, .12);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 76px;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.68;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

::selection { background: var(--ret); color: var(--paper); }

img { max-width: 100%; height: auto; }

a { color: var(--ink); text-underline-offset: 4px; }

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

.skip {
  position: absolute;
  left: -9999px;
  top: 8px;
  z-index: 100;
  background: var(--ink);
  color: var(--paper);
  padding: 10px 16px;
  font-size: .85rem;
}
.skip:focus { left: 12px; }

/* ---------- zemin katmanı ---------- */

.bg {
  position: fixed;
  inset: 0;
  z-index: -2;
  overflow: hidden;
  background: var(--paper);
  pointer-events: none;
}

.bg-layer {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 1.15s ease;
  filter: saturate(.45) contrast(.92);
}

.bg-layer.is-on { opacity: .15; }

[data-theme="dark"] .bg-layer { filter: grayscale(1) brightness(.5); }
[data-theme="dark"] .bg-layer.is-on { opacity: .22; }

.grain {
  position: absolute;
  inset: 0;
  opacity: .28;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.82' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='.32'/%3E%3C/svg%3E");
}

[data-theme="dark"] .grain { mix-blend-mode: screen; opacity: .12; }

/* ---------- üst bar ---------- */

.top {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 0 var(--pad);
  background: var(--paper);
  background: color-mix(in srgb, var(--paper) 84%, transparent);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.mark {
  display: flex;
  flex-direction: column;
  line-height: 1.18;
  text-decoration: none;
  color: var(--ink);
  white-space: nowrap;
}
.mark-name { font-family: var(--serif); font-size: 1.02rem; }
.mark-sub { font-size: .68rem; color: var(--muted); }

.topnav { display: flex; gap: 24px; }
.topnav a {
  font-size: .78rem;
  color: var(--muted);
  text-decoration: none;
  padding: 4px 0;
  border-bottom: 1px solid transparent;
  transition: color .18s, border-color .18s;
}
.topnav a:hover { color: var(--ink); }
.topnav a.is-active { color: var(--ink); border-bottom-color: var(--ret); }

.tools { display: flex; align-items: center; gap: 16px; }
.tools button {
  appearance: none;
  background: none;
  border: 0;
  border-bottom: 1px solid transparent;
  color: var(--muted);
  font: inherit;
  font-size: .76rem;
  padding: 5px 0;
  cursor: pointer;
  transition: color .18s, border-color .18s;
}
.tools button:hover { color: var(--ink); }
.tools button[aria-pressed="true"] { color: var(--ink); border-bottom-color: var(--ret); }

.progress {
  position: fixed;
  top: 64px;
  left: 0;
  right: 0;
  height: 2px;
  z-index: 51;
  background: transparent;
}
.progress i {
  display: block;
  height: 100%;
  width: 100%;
  background: var(--ret);
  transform: scaleX(0);
  transform-origin: left;
}

/* ---------- sağ dizin ---------- */

.rail {
  position: fixed;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 40;
}
.rail ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.rail a {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  text-decoration: none;
  color: var(--muted);
}
.rail .num { font-size: 9px; opacity: 0; transition: opacity .2s; }
.rail .tick {
  display: block;
  width: 16px;
  height: 1px;
  background: currentColor;
  transition: width .22s, background-color .22s, height .22s;
}
.rail a:hover { color: var(--ink); }
.rail a:hover .num { opacity: 1; }
.rail a.is-active { color: var(--ret); }
.rail a.is-active .num { opacity: 1; }
.rail a.is-active .tick { width: 26px; height: 2px; }

/* ---------- kapak ---------- */

.cover {
  min-height: 100svh;
  display: grid;
  grid-template-columns: 1.04fr .96fr;
  padding-top: 64px;
  border-bottom: 1px solid var(--line);
}

.cover-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: clamp(15px, 2vw, 24px);
  padding: clamp(40px, 6vw, 84px) clamp(24px, 4vw, 64px);
  padding-left: max(var(--pad), calc((100vw - var(--page)) / 2 + var(--pad)));
  width: 100%;
}

.cover-copy > * { width: 100%; max-width: 660px; }

.cover-copy > * {
  animation: rise .85s cubic-bezier(.2, .7, .2, 1) both;
}
.cover-copy > *:nth-child(2) { animation-delay: .06s; }
.cover-copy > *:nth-child(3) { animation-delay: .12s; }
.cover-copy > *:nth-child(4) { animation-delay: .18s; }
.cover-copy > *:nth-child(5) { animation-delay: .24s; }
.cover-copy > *:nth-child(6) { animation-delay: .3s; }

@keyframes rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}

.inst {
  margin: 0;
  font-size: .76rem;
  line-height: 1.5;
  color: var(--muted);
  border-left: 2px solid var(--ret);
  padding-left: 12px;
  max-width: 46ch;
}

.cover h1 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.45rem, 5.1vw, 4.75rem);
  line-height: .98;
  letter-spacing: -.025em;
  text-wrap: balance;
}
.cover h1 em {
  display: block;
  font-style: italic;
  color: var(--ret);
}

.sub {
  margin: 0;
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.1rem, 1.7vw, 1.35rem);
  color: var(--ink-2);
}

.cover-lede {
  margin: 0;
  font-size: .98rem;
  line-height: 1.65;
  color: var(--ink-2);
  max-width: 52ch;
}

.cover-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 34px;
  margin: 4px 0 0;
}
.cover-meta dt { font-size: .68rem; color: var(--muted); margin-bottom: 2px; }
.cover-meta dd { margin: 0; font-size: .86rem; }

.cover-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 6px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid var(--ink);
  background: transparent;
  color: var(--ink);
  text-decoration: none;
  font: inherit;
  font-size: .8rem;
  font-weight: 500;
  letter-spacing: .01em;
  cursor: pointer;
  transition: background-color .18s, color .18s, border-color .18s;
}
.btn:hover { background: var(--ink); color: var(--paper); }
.btn.primary { background: var(--ink); color: var(--paper); }
.btn.primary:hover { background: var(--ret); border-color: var(--ret); color: #fff; }
.btn.ghost { border-color: var(--line); color: var(--muted); }
.btn.ghost:hover { background: transparent; color: var(--ink); border-color: var(--ink); }

.cover-hint {
  margin: 2px 0 0;
  font-size: .7rem;
  color: var(--muted);
}
kbd {
  font: inherit;
  font-size: .68rem;
  border: 1px solid var(--line);
  padding: 1px 5px;
  color: var(--ink-2);
}

.cover-fig {
  position: relative;
  margin: 0;
  min-height: 100%;
  overflow: hidden;
  background: #ddd9cf;
}
.cover-fig img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.cover-fig::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, var(--paper) 0%, rgba(233, 231, 223, .28) 9%, transparent 32%, transparent 100%);
  pointer-events: none;
}
[data-theme="dark"] .cover-fig::after {
  background: linear-gradient(90deg, var(--paper) 0%, rgba(19, 20, 22, .35) 9%, transparent 34%, transparent 100%);
}
.cover-fig figcaption {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 2;
  font-size: .64rem;
  color: #fff;
  background: rgba(20, 22, 24, .42);
  padding: 4px 8px;
  backdrop-filter: blur(4px);
}

/* ---------- bölümler ---------- */

.sec {
  padding: clamp(72px, 10vw, 132px) 0;
  border-bottom: 1px solid var(--line);
}

.sec-inner {
  max-width: var(--page);
  margin: 0 auto;
  padding: 0 var(--pad);
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: clamp(28px, 5vw, 80px);
  align-items: start;
}

.margin { position: sticky; top: 104px; }

.sec-no {
  display: block;
  font-family: var(--serif);
  font-size: clamp(2.1rem, 3.2vw, 3rem);
  line-height: 1;
  opacity: .26;
}

.margin-note {
  margin: 18px 0 0;
  padding-left: 12px;
  border-left: 2px solid var(--ret);
  font-size: .77rem;
  line-height: 1.6;
  color: var(--muted);
  max-width: 30ch;
}

.body { max-width: 860px; min-width: 0; }

h2 {
  margin: 0 0 22px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.9rem, 3.5vw, 3.15rem);
  line-height: 1.04;
  letter-spacing: -.02em;
  text-wrap: balance;
}
h2 em { font-style: italic; color: var(--ret); }

h3 { margin: 0 0 8px; font-size: 1rem; font-weight: 600; }

.lede {
  margin: 0 0 34px;
  font-family: var(--serif);
  font-size: clamp(1.08rem, 1.45vw, 1.28rem);
  line-height: 1.56;
  color: var(--ink-2);
  max-width: 64ch;
}

.body > p { max-width: 68ch; }

.fine {
  margin: 18px 0 0;
  font-size: .74rem;
  line-height: 1.6;
  color: var(--muted);
  max-width: 70ch;
}

/* karşılaştırma */

.compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid var(--line);
  margin: 8px 0 34px;
}
.compare-col { padding: 24px 26px 24px 0; border-bottom: 1px solid var(--line); }
.compare-col + .compare-col { border-left: 1px solid var(--line); padding-left: 26px; padding-right: 0; }
.compare h3 { font-family: var(--serif); font-size: 1.22rem; font-weight: 500; margin-bottom: 12px; }
.compare ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.compare li {
  position: relative;
  padding-left: 17px;
  font-size: .9rem;
  line-height: 1.55;
  color: var(--ink-2);
}
.compare li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .64em;
  width: 7px;
  height: 1px;
  background: var(--muted);
}
.is-key h3 { color: var(--ret); }
.is-key li::before { background: var(--ret); width: 9px; }

.pull {
  margin: 36px 0;
  padding-left: 22px;
  border-left: 2px solid var(--ret);
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.35rem, 2.4vw, 2rem);
  line-height: 1.26;
  letter-spacing: -.015em;
  max-width: 32ch;
}

/* soru */

.question-main {
  margin: 0 0 34px;
  padding: clamp(24px, 3.2vw, 38px);
  background: var(--paper-2);
  border: 1px solid var(--ink);
}
.q-label { display: block; margin-bottom: 12px; font-size: .7rem; color: var(--ret); }
.question-main p {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(1.35rem, 2.5vw, 1.95rem);
  line-height: 1.26;
  letter-spacing: -.01em;
}

.qlist { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.qlist li {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 18px;
  align-items: start;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
}
.q-no { font-family: var(--serif); font-size: 1.35rem; line-height: 1.1; color: var(--ret); }
.qlist p { margin: 0; font-size: .96rem; line-height: 1.6; }
.q-data {
  font-size: .68rem;
  color: var(--muted);
  border: 1px solid var(--line);
  padding: 4px 8px;
  white-space: nowrap;
}

/* çerçeve */

.frame {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid var(--line);
  margin-bottom: 22px;
}
.frame article { padding: 26px 26px 26px 0; border-bottom: 1px solid var(--line); }
.frame article:nth-child(even) { padding-left: 26px; padding-right: 0; border-left: 1px solid var(--line); }
.frame-tag { display: block; margin-bottom: 10px; font-size: .69rem; color: var(--slate); }
.frame h3 { font-family: var(--serif); font-size: 1.24rem; font-weight: 500; line-height: 1.22; margin-bottom: 10px; }
.frame p { margin: 0 0 12px; font-size: .87rem; line-height: 1.6; color: var(--ink-2); max-width: 46ch; }
.frame .cite { font-size: .71rem; color: var(--muted); line-height: 1.55; margin: 0; }

/* yöntem */

.method-grid {
  display: grid;
  grid-template-columns: .85fr 1.35fr;
  gap: clamp(22px, 3.5vw, 44px);
  padding: 28px 0;
  border-top: 1px solid var(--line);
}
.method-grid + .method-grid { border-bottom: 1px solid var(--line); }
.method-intro p { margin: 8px 0 0; font-size: .89rem; line-height: 1.62; color: var(--ink-2); }

.instruments { margin: 0; }
.instruments > div {
  display: grid;
  grid-template-columns: 172px minmax(0, 1fr);
  gap: 16px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line-soft);
}
.instruments > div:first-child { padding-top: 0; }
.instruments dt { font-size: .81rem; font-weight: 600; }
.instruments dd { margin: 0; font-size: .84rem; line-height: 1.55; color: var(--ink-2); }

.rubric {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-content: start;
}
.rubric li { border: 1px solid var(--line); padding: 7px 11px; font-size: .79rem; }

.method-note {
  margin-top: 26px;
  padding: 20px 22px;
  background: var(--paper-2);
  border-left: 2px solid var(--slate);
}
.method-note p { margin: 0 0 8px; font-size: .85rem; line-height: 1.62; color: var(--ink-2); }
.method-note p:last-child { margin-bottom: 0; }

/* vakalar */

.cases {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(18px, 2.3vw, 30px);
  margin: 8px 0 24px;
}
.case { display: flex; flex-direction: column; }
.case figure { margin: 0 0 14px; }
.case img {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  filter: saturate(.82) contrast(1.02);
}
.case figcaption { padding-top: 6px; font-size: .64rem; color: var(--muted); }
.case-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 8px; }
.case-no { font-family: var(--serif); font-size: 1rem; color: var(--ret); }
.case h3 { margin: 0; font-family: var(--serif); font-size: 1.28rem; font-weight: 500; line-height: 1.16; }
.case p { margin: 0 0 14px; font-size: .85rem; line-height: 1.6; color: var(--ink-2); }
.case-data {
  margin: auto 0 0;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  display: grid;
  gap: 6px;
}
.case-data div { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 8px; }
.case-data dt { font-size: .66rem; color: var(--muted); }
.case-data dd { margin: 0; font-size: .71rem; line-height: 1.45; color: var(--ink-2); }

/* üretim ortamı */

.env {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  margin-bottom: 34px;
}
.env-item { padding: 24px 24px 24px 0; border-bottom: 1px solid var(--line); }
.env-item + .env-item { border-left: 1px solid var(--line); padding-left: 24px; padding-right: 0; }
.env-item h3 { font-family: var(--serif); font-size: 1.18rem; font-weight: 500; margin-bottom: 8px; }
.env-item p { margin: 0; font-size: .85rem; line-height: 1.6; color: var(--ink-2); }

.flow-wrap { padding: clamp(20px, 3vw, 30px); background: var(--paper-2); border: 1px solid var(--line); }
.flow-title { margin: 0 0 18px; font-size: .76rem; font-weight: 500; color: var(--muted); }
.flow { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; background: var(--line); }
.flow-col { background: var(--paper-2); padding: 16px 14px; display: grid; gap: 10px; align-content: start; }
.flow-stage { font-family: var(--serif); font-size: 1.12rem; }
.flow-designer, .flow-tool { margin: 0; font-size: .73rem; line-height: 1.5; }
.flow-designer { color: var(--ink); }
.flow-tool { color: var(--slate); }
.flow-designer::before, .flow-tool::before {
  content: "";
  display: block;
  width: 14px;
  height: 2px;
  margin-bottom: 7px;
}
.flow-designer::before { background: var(--ret); }
.flow-tool::before { background: var(--slate); }

/* katkı */

.contrib { display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--line); }
.contrib article { padding: 26px 26px 26px 0; border-bottom: 1px solid var(--line); }
.contrib article:nth-child(even) { padding-left: 26px; padding-right: 0; border-left: 1px solid var(--line); }
.contrib-no { font-family: var(--serif); font-size: 1.1rem; color: var(--ret); }
.contrib h3 { font-family: var(--serif); font-weight: 500; font-size: 1.24rem; margin: 6px 0 8px; }
.contrib p { margin: 0; font-size: .85rem; line-height: 1.6; color: var(--ink-2); max-width: 48ch; }
.scope { margin-top: 26px; padding-top: 18px; border-top: 1px solid var(--line); }
.scope p { margin: 0 0 8px; font-size: .87rem; line-height: 1.6; color: var(--ink-2); }

/* etik */

.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 4vw, 48px); }
.checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.checks li { position: relative; padding-left: 20px; font-size: .86rem; line-height: 1.6; color: var(--ink-2); }
.checks li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .72em;
  width: 10px;
  height: 1px;
  background: var(--ret);
}
.checks.is-limit li::before { background: var(--muted); }

/* takvim */

.timeline { border-top: 1px solid var(--line); margin-bottom: 22px; }
.tl-head, .tl-row {
  display: grid;
  grid-template-columns: 46px 78px minmax(90px, 1fr) 1.25fr;
  gap: 16px;
  align-items: center;
}
.tl-head {
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
  font-size: .65rem;
  color: var(--muted);
}
.tl-row { padding: 12px 0; border-bottom: 1px solid var(--line-soft); }
.tl-name { font-family: var(--serif); font-size: 1rem; }
.tl-weeks { font-size: .71rem; color: var(--muted); }
.tl-track { position: relative; height: 10px; background: var(--line-soft); min-width: 80px; }
.tl-track i { position: absolute; top: 0; height: 100%; background: var(--slate); opacity: .55; }
.tl-row.is-core .tl-track i { background: var(--ret); opacity: .85; }
.tl-out { font-size: .77rem; line-height: 1.45; color: var(--ink-2); }

.contingency {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}
.contingency p { margin: 0; font-size: .81rem; line-height: 1.55; color: var(--ink-2); }

/* kaynakça */

.refs { list-style: none; margin: 0; padding: 0; counter-reset: ref; }
.refs li {
  counter-increment: ref;
  position: relative;
  padding: 12px 0 12px 42px;
  border-bottom: 1px solid var(--line-soft);
  font-size: .85rem;
  line-height: 1.62;
  color: var(--ink-2);
}
.refs li::before {
  content: counter(ref, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 12px;
  font-family: var(--serif);
  color: var(--muted);
}

/* kapanış */

.asks { list-style: none; margin: 0 0 46px; padding: 0; border-top: 1px solid var(--line); }
.asks li {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 16px;
  align-items: baseline;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.asks span { font-family: var(--serif); font-size: 1rem; color: var(--ret); }
.asks p { margin: 0; font-size: .94rem; }

.thanks { padding: 34px 0; border-top: 1px solid var(--ink); }
.thanks-line {
  margin: 0 0 12px;
  font-family: var(--serif);
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1;
  letter-spacing: -.02em;
}
.thanks-sub { margin: 0 0 14px; font-size: .8rem; color: var(--muted); }
.thanks-links { display: flex; flex-wrap: wrap; gap: 18px; margin: 0; }
.thanks-links a { font-size: .81rem; }

/* alt */

.foot {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  padding: 26px var(--pad) 34px;
  max-width: var(--page);
  margin: 0 auto;
  font-size: .72rem;
  color: var(--muted);
}
.foot p { margin: 0; }
.foot a { color: var(--muted); }

/* sunum notları */

.notes {
  display: none;
  margin-top: 36px;
  padding: 18px 20px;
  background: var(--paper-2);
  border-left: 2px solid var(--ret);
}
body.notlar .notes { display: block; }
.notes-label { display: block; margin-bottom: 6px; font-size: .65rem; color: var(--ret); }
.notes p { margin: 0; font-size: .83rem; line-height: 1.62; color: var(--ink-2); }

/* sunum arayüzü */

.hud, .hint { display: none; }

body.sunum .hud {
  position: fixed;
  top: 76px;
  right: var(--pad);
  z-index: 45;
  display: flex;
  gap: 14px;
  padding: 5px 10px;
  border: 1px solid var(--line);
  background: var(--paper);
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  font-size: .68rem;
  color: var(--muted);
}

body.sunum .hint {
  position: fixed;
  bottom: 14px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 45;
  display: block;
  padding: 6px 12px;
  border: 1px solid var(--line);
  background: var(--paper);
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  font-size: .67rem;
  color: var(--muted);
  white-space: nowrap;
  transition: opacity .5s;
}
body.sunum.hint-off .hint { opacity: 0; pointer-events: none; }

body.sunum .rail,
body.sunum .progress { display: none; }
body.sunum .cover-actions,
body.sunum .cover-hint { display: none; }

/* sunum notları: sabit alt çekmece, yalnız etkin bölüm */
body.sunum.notlar .notes { display: none; }
body.sunum.notlar .sec.is-active .notes {
  display: block;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 60;
  margin: 0;
  max-height: 30vh;
  overflow-y: auto;
  padding: 14px clamp(18px, 4vw, 56px) 16px;
  background: var(--paper-2);
  background: color-mix(in srgb, var(--paper-2) 96%, transparent);
  backdrop-filter: blur(12px);
  border-top: 1px solid var(--line);
  border-left: 0;
}
body.sunum.notlar .sec.is-active .notes p { max-width: 84ch; }
body.sunum.notlar .hint { display: none; }

html.sunum { scroll-snap-type: y proximity; }
body.sunum .cover { scroll-snap-align: start; }
body.sunum .sec {
  min-height: 100svh;
  scroll-snap-align: start;
  display: flex;
  align-items: center;
  padding: 64px 0 40px;
}

@media (max-height: 820px) {
  body.sunum .sec { padding: 44px 0 28px; }
  body.sunum h2 { margin-bottom: 16px; }
  body.sunum .lede { margin-bottom: 22px; }
  body.sunum .method-grid { padding: 20px 0; }
  body.sunum .method-note { margin-top: 18px; padding: 14px 18px; }
  body.sunum .cases { margin-bottom: 14px; }
  body.sunum .frame article,
  body.sunum .contrib article,
  body.sunum .env-item { padding-top: 18px; padding-bottom: 18px; }
}
body.sunum .sec-inner { width: 100%; }
body.sunum .margin { position: static; }
body.sunum .foot { display: none; }

/* ---------- duyarlı ---------- */

/* kısa ekranlar: kapak tek ekrana sığsın */
@media (min-width: 901px) and (max-height: 960px) {
  .cover-copy {
    gap: 12px;
    padding-top: 26px;
    padding-bottom: 26px;
  }
  .cover h1 { font-size: clamp(2.2rem, 4.4vw, 3.85rem); }
  .cover-lede { font-size: .92rem; line-height: 1.55; }
  .cover-meta { gap: 8px 26px; }
  .cover-hint { display: none; }
}

@media (max-width: 1100px) {
  .rail { display: none; }
  .sec-inner { grid-template-columns: 180px minmax(0, 1fr); gap: 36px; }
}

@media (max-width: 980px) {
  .topnav { display: none; }
}

@media (max-width: 900px) {
  .cover { grid-template-columns: 1fr; min-height: 0; }
  .cover-copy { padding: 46px var(--pad) 34px; max-width: none; }
  .cover-fig { height: 46vh; min-height: 280px; order: 2; }
  .cover-fig::after {
    background: linear-gradient(180deg, var(--paper) 0%, transparent 22%, transparent 76%, rgba(233, 231, 223, .45) 100%);
  }
  [data-theme="dark"] .cover-fig::after {
    background: linear-gradient(180deg, var(--paper) 0%, transparent 22%, transparent 76%, rgba(19, 20, 22, .5) 100%);
  }

  .sec-inner { grid-template-columns: 1fr; gap: 18px; }
  .margin { position: static; display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap; }
  .margin-note { margin: 0; max-width: 52ch; }
  .body { max-width: none; }

  .compare { grid-template-columns: 1fr; }
  .compare-col + .compare-col { border-left: 0; padding-left: 0; }
  .frame { grid-template-columns: 1fr; }
  .frame article:nth-child(even) { padding-left: 0; border-left: 0; }
  .method-grid { grid-template-columns: 1fr; gap: 18px; }
  .env { grid-template-columns: 1fr; }
  .env-item + .env-item { border-left: 0; padding-left: 0; }
  .contrib { grid-template-columns: 1fr; }
  .contrib article:nth-child(even) { padding-left: 0; border-left: 0; }
  .two-col { grid-template-columns: 1fr; }
  .contingency { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  body { font-size: 16px; }
  .top { height: 58px; }
  .progress { top: 58px; }
  .mark-name { font-size: .92rem; }
  .mark-sub { display: none; }
  .tools { gap: 12px; }
  .tools button { font-size: .72rem; }

  .cover h1 { font-size: clamp(2.1rem, 8.6vw, 3.2rem); }
  .cover-fig { height: 38vh; min-height: 230px; }
  .cover-meta { gap: 10px 24px; }
  .cover-actions .btn { flex: 1 1 auto; }

  h2 { font-size: clamp(1.7rem, 6.4vw, 2.3rem); }
  .lede { font-size: 1.05rem; }
  .qlist li { grid-template-columns: 34px minmax(0, 1fr); }
  .q-data { grid-column: 2; justify-self: start; }
  .question-main p { font-size: 1.28rem; }
  .cases { grid-template-columns: 1fr; }
  .flow { grid-template-columns: 1fr 1fr; }
  .instruments > div { grid-template-columns: 1fr; gap: 3px; }
  .tl-head { display: none; }
  .tl-row {
    grid-template-columns: 40px minmax(0, 1fr);
    gap: 5px 14px;
    padding: 14px 0;
  }
  .tl-name { grid-row: 1 / span 3; align-self: start; }
  .tl-weeks, .tl-track, .tl-out { grid-column: 2; }
  .tl-track { height: 8px; }
  .refs li { padding-left: 34px; }
  .hud { top: 68px; }
  .hint { display: none !important; }
}

@media (max-width: 520px) {
  .flow { grid-template-columns: 1fr; }
  .cover-actions .btn { flex: 1 1 100%; }
  .cover h1 { font-size: 2.05rem; }
  .sub { font-size: 1.05rem; }
}

/* ---------- hareket azaltma ---------- */

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

/* ---------- yazdırma ---------- */

@media print {
  :root, [data-theme="dark"] {
    color-scheme: light;
    --paper: #fff;
    --paper-2: #f4f4f4;
    --ink: #000;
    --ink-2: #222;
    --muted: #444;
    --line: rgba(0, 0, 0, .25);
    --line-soft: rgba(0, 0, 0, .12);
    --ret: #000;
    --slate: #333;
  }
  .bg, .top, .rail, .progress, .hud, .hint, .notes, .skip, .cover-actions, .cover-hint, .foot { display: none !important; }
  html, body { background: #fff !important; color: #000; font-size: 10.5pt; line-height: 1.5; }
  .cover { display: block; min-height: 0; padding-top: 0; border-bottom: 1px solid #bbb; }
  .cover-copy { padding: 0 0 14pt; max-width: none; }
  .cover-fig {
    display: block;
    position: static;
    height: 58mm;
    min-height: 0;
    margin: 0;
    overflow: hidden;
  }
  .cover-fig img { position: static; width: 100%; height: 58mm; object-fit: cover; filter: grayscale(.35); }
  .cover-fig::after, .cover-fig figcaption { display: none; }
  .cover h1 { font-size: 30pt; }
  .cover h1 em { color: #000; }
  .sec { padding: 16pt 0; border-bottom: 1px solid #ccc; break-inside: auto; }
  .sec-inner { display: block; max-width: none; padding: 0; }
  .margin { position: static; display: block; margin-bottom: 8pt; }
  .sec-no { display: none; }
  .margin-note { border-left: 2px solid #000; color: #333; }
  h2 { font-size: 18pt; margin-bottom: 8pt; }
  h2 em { color: #000; }
  .lede, .body > p { font-size: 10.5pt; }
  .question-main, .method-note, .flow-wrap { background: #f4f4f4; border-color: #999; }
  .cases { grid-template-columns: repeat(3, 1fr); gap: 10pt; }
  .case img { filter: grayscale(1); }
  .case-data { border-color: #bbb; }
  .tl-track { background: #e6e6e6; }
  .tl-track i { background: #666 !important; }
  .timeline, .contrib, .compare, .frame, .qlist li, .tl-row, .case, .refs li, .asks li { break-inside: avoid; }
  .sec { break-before: auto; }
  a { color: #000; text-decoration: none; }
  @page { margin: 16mm 14mm; }
}
