/* =========================================================
   İsmail Bilgehan Kazancı — portföy stil dosyası
   Yön: ana sayfanın ilk ekranı teknik resim paftası (çerçeve, antet,
   ölçü çizgisi); kalan her yer editoryal serif tipografi.
   Renkler yalnızca :root token'larında; koyu tema aynı adları
   [data-theme="dark"] altında yeniden tanımlar.
   ========================================================= */

/* ---------- yazı tipleri (kendinden barındırılan) ---------- */
@font-face { font-family: 'Source Serif 4'; font-style: normal; font-weight: 200 900; font-display: swap;
  src: url('/assets/fonts/source-serif-4-latin-wght-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Source Serif 4'; font-style: normal; font-weight: 200 900; font-display: swap;
  src: url('/assets/fonts/source-serif-4-latin-ext-wght-normal.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Source Serif 4'; font-style: italic; font-weight: 200 900; font-display: swap;
  src: url('/assets/fonts/source-serif-4-latin-wght-italic.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Source Serif 4'; font-style: italic; font-weight: 200 900; font-display: swap;
  src: url('/assets/fonts/source-serif-4-latin-ext-wght-italic.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 400; font-display: swap;
  src: url('/assets/fonts/ibm-plex-mono-latin-400-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 400; font-display: swap;
  src: url('/assets/fonts/ibm-plex-mono-latin-ext-400-normal.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 500; font-display: swap;
  src: url('/assets/fonts/ibm-plex-mono-latin-500-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 500; font-display: swap;
  src: url('/assets/fonts/ibm-plex-mono-latin-ext-500-normal.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Barlow Condensed'; font-style: normal; font-weight: 500; font-display: swap;
  src: url('/assets/fonts/barlow-condensed-latin-500-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Barlow Condensed'; font-style: normal; font-weight: 500; font-display: swap;
  src: url('/assets/fonts/barlow-condensed-latin-ext-500-normal.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

@font-face { font-family: 'Barlow'; font-style: normal; font-weight: 400; font-display: swap;
  src: url('/assets/fonts/barlow-latin-400-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Barlow'; font-style: normal; font-weight: 400; font-display: swap;
  src: url('/assets/fonts/barlow-latin-ext-400-normal.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

/* ---------- token'lar ---------- */
:root {
  color-scheme: light;
  --bg: #FCFCFA;
  --bg-2: #F5F4F0;
  --bg-3: #EAE9E4;
  --ink: #1C1C1C;
  --ink-2: #3A3A3A;
  --mute: #6B6B68;
  --line: rgba(28, 28, 28, .14);
  --line-strong: rgba(28, 28, 28, .75);
  --accent: #C8102E;          /* uyarı kırmızısı: 404 ve Cpk "yetersiz" */
  --draft: #2E7556;           /* pafta çizim rengi: ilk ekrandaki ölçü çizgisi, eksenler, CAD imleci */
  --accent-ink: #FFFFFF;
  --accent-soft: rgba(200, 16, 46, .07);
  --link: #2F5D50;            /* editoryal vurgu: bağlantılar ve italik */
  --code-bg: #1C1C1C;
  --code-ink: #EDEBE6;
  --code-mute: #9A9A96;
  --focus: #2F5D50;
  --shadow: rgba(28, 28, 28, .16);
  --nav-bg: rgba(252, 252, 250, .95);

  --serif: 'Source Serif 4', Georgia, 'Times New Roman', serif;
  --sans: var(--serif);
  --mono: 'IBM Plex Mono', ui-monospace, 'Cascadia Mono', Consolas, monospace;
  --cond: 'Barlow Condensed', 'Arial Narrow', sans-serif;
  --barlow: 'Barlow', 'Segoe UI', sans-serif;

  --sheet: 28px;
  --maxw: 1180px;
  --gutter: 48px;
  --nav-h: 68px;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #141414;
  --bg-2: #1B1B1B;
  --bg-3: #242424;
  --ink: #ECEAE4;
  --ink-2: #CFCCC5;
  --mute: #9C9993;
  --line: rgba(236, 234, 228, .14);
  --line-strong: rgba(236, 234, 228, .7);
  --accent: #F0707A;
  --draft: #86C9AC;
  --accent-ink: #141414;
  --accent-soft: rgba(240, 112, 122, .1);
  --link: #8FC4B3;
  --code-bg: #0D0D0D;
  --code-ink: #ECEAE4;
  --code-mute: #8E8C87;
  --focus: #8FC4B3;
  --shadow: rgba(0, 0, 0, .5);
  --nav-bg: rgba(20, 20, 20, .95);
}

/* ---------- dil geçişi ---------- */
html[lang="tr"] [data-lang="en"],
html[lang="en"] [data-lang="tr"] { display: none !important; }
html:not(.js) .toggles { display: none; }

/* ---------- temel (editoryal) ---------- */
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 24px); }
body {
  background: var(--bg); color: var(--ink);
  font-family: var(--serif); font-size: 19px; line-height: 1.6;
  font-feature-settings: 'kern', 'liga';
  -webkit-font-smoothing: antialiased; overflow-x: clip;
}
img { max-width: 100%; display: block; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }
::selection { background: var(--link); color: var(--bg); }
strong { color: var(--ink); font-weight: 600; }
em { font-style: italic; }
code { font-family: var(--mono); font-size: .8em; }
.mono { font-family: var(--mono); font-size: .85em; font-style: normal; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
.skip { position: absolute; left: 24px; top: -60px; z-index: 200; background: var(--ink); color: var(--bg); padding: 10px 16px; }
.skip:focus { top: 24px; }

.smallcaps, .kicker, .sec-label, .card-top, .case-metrics dt, .case-body th, .gallery-head,
.edu-block h3, .cert-block h3, .cpk-row span, .cpk-fields label, .xp-when b {
  font-variant-caps: all-small-caps; letter-spacing: .07em;
}
.kicker { font-size: 19px; color: var(--mute); }
.h2 { font-size: clamp(30px, 3.6vw, 44px); line-height: 1.12; font-weight: 400; letter-spacing: -.5px; }
.h2 em { color: var(--link); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 46px;
  font-family: var(--serif); font-size: 17px; padding: 10px 20px; border: 1px solid var(--ink); color: var(--ink);
  transition: background .2s ease, color .2s ease;
}
.btn svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.btn-accent { background: var(--ink); color: var(--bg); }
.btn-accent:hover, .btn-line:hover { background: var(--link); border-color: var(--link); color: var(--bg); }

.sec { padding: 104px 0; position: relative; }
.sec-alt { background: var(--bg-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.sec-head { display: flex; align-items: center; gap: 14px; margin-bottom: 32px; }
.sec-no { display: none; }
.sec-label { font-size: 20px; color: var(--mute); }
.sec-head::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.sec-title { margin-bottom: 36px; }
.related-title { font-size: 28px; font-weight: 400; margin-bottom: 8px; }
.sec-intro { display: grid; grid-template-columns: 1.2fr 1fr; gap: 56px; align-items: end; margin-bottom: 52px; }
.sec-intro p { color: var(--mute); font-size: 18px; max-width: 460px; font-style: italic; }

.link-arrow { color: var(--link); }
.link-arrow:hover { text-decoration: underline; text-underline-offset: 4px; }
.link-arrow.is-muted { color: var(--ink); }
.metric { font-size: 16.5px; color: var(--mute); white-space: nowrap; font-variant-numeric: lining-nums tabular-nums; }
.metric b { color: var(--ink); font-weight: 600; margin-right: 4px; }
.card-metrics, .case-tags { column-gap: 22px; }
.chip { font-size: 15.5px; color: var(--mute); font-style: italic; white-space: nowrap; }
.chip + .chip::before { content: ', '; font-style: normal; }

/* ---------- menü ---------- */
.nav {
  position: sticky; top: 0; z-index: 60; background: var(--nav-bg);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent; transition: border-color .25s ease, background .25s ease;
}
.nav.is-scrolled { border-bottom-color: var(--line); }
.nav-inner { height: var(--nav-h); display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand { display: flex; align-items: baseline; min-width: 0; }
.brand-name { font-weight: 600; font-size: 18px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nav-right { display: flex; align-items: center; gap: 28px; }
.nav-links { display: flex; align-items: center; gap: 26px; font-size: 17px; }
.nav-links a { padding: 4px 0; color: var(--ink-2); }
.nav-links a:hover, .nav-links a.is-current { color: var(--ink); text-decoration: underline; text-decoration-color: var(--link); text-underline-offset: 6px; text-decoration-thickness: 1px; }
.toggles { display: flex; align-items: center; gap: 2px; }
.lang { display: inline-flex; align-items: center; font-size: 15px; font-variant-caps: all-small-caps; letter-spacing: .07em; }
.lang button { min-width: 44px; height: 44px; padding: 0 6px; color: var(--mute); }

.lang button[aria-pressed="true"] { color: var(--ink); text-decoration: underline; text-decoration-color: var(--link); text-underline-offset: 5px; }
.theme { width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center; color: var(--ink-2); }
.theme:hover { color: var(--link); }
.theme svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
:root[data-theme="dark"] .theme .i-moon { display: none; }
:root:not([data-theme="dark"]) .theme .i-sun { display: none; }
.nav-toggle { display: none; width: 44px; height: 44px; position: relative; }
.nav-toggle span { position: absolute; left: 11px; right: 11px; height: 1.5px; background: var(--ink); transition: transform .25s ease, top .25s ease; }
.nav-toggle span:first-child { top: 18px; }
.nav-toggle span:last-child { top: 25px; }
.nav-toggle[aria-expanded="true"] span:first-child { top: 21.5px; transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:last-child { top: 21.5px; transform: rotate(-45deg); }

/* =========================================================
   ANA SAYFA İLK EKRAN: TEKNİK RESİM PAFTASI (yalnız burada)
   ========================================================= */
.sheet-hero {
  position: relative;
  min-height: max(660px, calc(100svh - var(--nav-h))); padding: 64px 0 calc(var(--sheet) + 150px);
  font-family: var(--barlow); color: var(--ink);
}
.sheet-frame { position: absolute; inset: 0 var(--sheet) var(--sheet); border: 1.5px solid var(--ink); pointer-events: none; }
.sheet-frame::before { content: ''; position: absolute; inset: 14px; border: .75px solid var(--ink); }
.sheet-top, .sheet-left { position: absolute; display: flex; font: 500 11px/1 var(--mono); color: var(--mute); }
.sheet-top { top: 0; left: 14px; right: 14px; height: 14px; }
.sheet-top i { flex: 1; font-style: normal; display: flex; align-items: center; justify-content: center; border-left: .75px solid var(--ink); }
.sheet-top i:first-child { border-left: 0; }
.sheet-left { left: 0; top: 14px; bottom: 14px; width: 14px; flex-direction: column; }
.sheet-left i { flex: 1; font-style: normal; display: flex; align-items: center; justify-content: center; border-top: .75px solid var(--ink); }
.sheet-left i:first-child { border-top: 0; }
.sheet-grid { position: relative; display: grid; grid-template-columns: 1.35fr .65fr; gap: 64px; align-items: start; }
.sheet-label { font: 500 13px var(--mono); letter-spacing: 1.5px; color: var(--mute); }
.sheet-name { margin-top: 16px; font: 500 clamp(64px, 8.4vw, 116px)/.95 var(--cond); letter-spacing: -1px; }
.sheet-lead { margin-top: 28px; font-size: 21px; line-height: 1.5; max-width: 580px; color: var(--ink-2); }
.sheet-cta { margin-top: 34px; display: flex; flex-wrap: wrap; gap: 12px; }
.sheet-cta .btn { font: 500 14px var(--mono); letter-spacing: .5px; min-height: 48px; }
.sheet-cta .btn-accent:hover, .sheet-cta .btn-line:hover { background: var(--ink); border-color: var(--ink); color: var(--bg); }
/* ölçü çizgisi */
.dimline {
  position: relative; height: 34px; margin-bottom: 18px; max-width: 700px;
  border-left: .75px solid var(--draft); border-right: .75px solid var(--draft);
  color: var(--draft); font: 500 13px/1 var(--mono); letter-spacing: .5px;
  display: flex; justify-content: center;
}
.dimline::before { content: ''; position: absolute; left: 0; right: 0; top: 22px; height: .75px; background: var(--draft); }
.dimline::after {
  content: ''; position: absolute; left: 0; right: 0; top: 18px; height: 9px;
  background:
    linear-gradient(to top right, transparent 48%, var(--draft) 50%, var(--draft) 60%, transparent 62%) left top / 12px 4.5px no-repeat,
    linear-gradient(to bottom right, transparent 48%, var(--draft) 50%, var(--draft) 60%, transparent 62%) left bottom / 12px 4.5px no-repeat,
    linear-gradient(to top left, transparent 48%, var(--draft) 50%, var(--draft) 60%, transparent 62%) right top / 12px 4.5px no-repeat,
    linear-gradient(to bottom left, transparent 48%, var(--draft) 50%, var(--draft) 60%, transparent 62%) right bottom / 12px 4.5px no-repeat;
}
.dimline span { position: relative; z-index: 1; background: var(--bg); padding: 0 8px; margin-top: 2px; white-space: nowrap; }
/* görünüş (portre) */
.view { margin-top: 40px; }
.view-frame { position: relative; aspect-ratio: 4 / 5; border: .75px solid var(--ink); background: var(--bg); overflow: hidden; }
.view-frame img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.view-ph { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.view-ph::before, .view-ph::after { content: ''; position: absolute; background: var(--draft); }
.view-ph::before { left: 50%; top: 10%; bottom: 10%; width: 1px; background: repeating-linear-gradient(to bottom, var(--draft) 0 14px, transparent 14px 18px, var(--draft) 18px 20px, transparent 20px 24px); }
.view-ph::after { top: 50%; left: 10%; right: 10%; height: 1px; background: repeating-linear-gradient(to right, var(--draft) 0 14px, transparent 14px 18px, var(--draft) 18px 20px, transparent 20px 24px); }
.view-ph span { position: relative; z-index: 1; font: 500 40px/1 var(--cond); letter-spacing: 2px; background: var(--bg); padding: 4px 12px; }
.view:has(img) .view-ph { display: none; }
.view-cap { margin-top: 10px; text-align: center; font: 500 12px var(--mono); letter-spacing: 1px; }
.view-cap b { font-weight: 500; text-decoration: underline; text-underline-offset: 3px; }
/* CAD imleci: artı çizgileri, imleç çevresinde milimetrik ızgara, konum okuması, bölge vurgusu */
.sheet-hero.has-cad { cursor: crosshair; }
.sheet-hero.has-cad a, .sheet-hero.has-cad button { cursor: pointer; }
.cad { position: absolute; inset: 14px; overflow: hidden; opacity: 0; transition: opacity .25s ease; }
.sheet-hero.is-cad .cad { opacity: 1; }
.cad-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(color-mix(in srgb, var(--draft) 45%, transparent) 1px, transparent 1px),
    linear-gradient(90deg, color-mix(in srgb, var(--draft) 45%, transparent) 1px, transparent 1px),
    linear-gradient(color-mix(in srgb, var(--draft) 18%, transparent) 1px, transparent 1px),
    linear-gradient(90deg, color-mix(in srgb, var(--draft) 18%, transparent) 1px, transparent 1px);
  background-size: 100px 100px, 100px 100px, 20px 20px, 20px 20px;
  -webkit-mask-image: radial-gradient(circle 200px at var(--mx, -999px) var(--my, -999px), var(--ink), transparent 100%);
  mask-image: radial-gradient(circle 200px at var(--mx, -999px) var(--my, -999px), var(--ink), transparent 100%);
}
.cad-x, .cad-y { position: absolute; background: var(--draft); opacity: .6; }
.cad-x { left: 0; right: 0; height: 1px; top: var(--my, -10px); }
.cad-y { top: 0; bottom: 0; width: 1px; left: var(--mx, -10px); }
/* okuma kutusu içerikten sonra gelir: yazının ve antetin üstünde kalır */
.cad-read {
  position: absolute; z-index: 5; left: var(--hx, -999px); top: var(--hy, -999px); transform: translate(12px, 10px);
  opacity: 0; transition: opacity .2s ease; pointer-events: none;
  font: 500 11px/1 var(--mono); letter-spacing: .5px; color: var(--draft); background: var(--bg);
  border: 1px solid var(--draft); padding: 4px 6px; white-space: nowrap;
}
.sheet-hero.is-cad .cad-read { opacity: 1; }
.cad-read.is-flip { transform: translate(calc(-100% - 12px), 10px); }
.sheet-top i, .sheet-left i { transition: color .15s ease, background .15s ease; }
.sheet-top i.is-on, .sheet-left i.is-on { color: var(--draft); background: color-mix(in srgb, var(--draft) 12%, transparent); }

/* antet */
.titleblock {
  position: absolute; right: calc(var(--sheet) + 14px); bottom: calc(var(--sheet) + 14px); width: 580px;
  display: grid; grid-template-columns: 1fr 1fr 1fr; border: 1.5px solid var(--ink); background: var(--bg);
  font: 400 11.5px/1.35 var(--mono);
}
.titleblock > div { border: .5px solid var(--ink); padding: 5px 8px; min-width: 0; overflow-wrap: anywhere; }
.titleblock small { display: block; font-size: 9px; letter-spacing: 1px; color: var(--mute); }
.titleblock .wide { grid-column: span 2; }
.titleblock .tb-name { font: 500 18px/1.1 var(--cond); letter-spacing: .5px; }
.titleblock a { text-decoration: underline; text-underline-offset: 2px; }
.titleblock a:hover { color: var(--draft); }

/* ---------- hakkımda ---------- */
.about-grid { display: grid; grid-template-columns: 1fr 1.15fr; gap: 72px; align-items: start; }
.about-text p { color: var(--ink-2); font-size: 19px; }
.about-text p + p { margin-top: 18px; }

/* ---------- projeler ---------- */
.projects { border-top: 1px solid var(--ink); }
.card { position: relative; display: grid; gap: 44px; padding: 44px 0; border-bottom: 1px solid var(--line); }
.card-featured { grid-template-columns: 1fr 1fr; }
.card-media { position: relative; }
.card-media img, .card-noimg { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: top left; border: 1px solid var(--line); background: var(--bg-2); }
.card-noimg { position: relative; display: flex; align-items: flex-end; padding: 18px; font-size: 15px; font-style: italic; color: var(--mute); }
.card-noimg b { position: absolute; left: 18px; top: 12px; font-size: 34px; font-weight: 400; font-style: normal; color: var(--ink-2); }
.card-body { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.card-top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; font-size: 17px; color: var(--mute); }
.card-top b { font-weight: 600; color: var(--ink); }
.card-status { font-style: italic; font-variant-caps: normal; letter-spacing: 0; color: var(--link); font-size: 16px; }
.card h3 { font-size: clamp(26px, 2.5vw, 34px); font-weight: 400; letter-spacing: -.4px; line-height: 1.15; }
.card h3 a { background: linear-gradient(var(--link), var(--link)) left bottom / 0 1px no-repeat; transition: background-size .3s ease; }
.card h3 a:hover { background-size: 100% 1px; }
.card p { color: var(--ink-2); font-size: 18px; }
.card-metrics, .card-tags { display: flex; flex-wrap: wrap; row-gap: 2px; }
.card-links { display: flex; flex-wrap: wrap; gap: 6px 22px; font-size: 17px; margin-top: 4px; }
.card-links a, .tool-links a, .xp-links a { color: var(--link); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; text-decoration-color: color-mix(in srgb, var(--link) 45%, transparent); }
.card-links a:hover { text-decoration: underline; text-underline-offset: 4px; }
.card-links a.is-muted { color: var(--ink); font-weight: 600; }
.projects-grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); column-gap: 48px; }
.card-medium { grid-template-rows: auto 1fr; gap: 22px; }
.card-medium .card-media img, .card-medium .card-noimg { aspect-ratio: 16 / 9; }
.card-medium h3 { font-size: clamp(23px, 2vw, 28px); }

/* ---------- araçlar ---------- */
.tools { border-top: 1px solid var(--ink); }
.tool { display: grid; grid-template-columns: 1fr auto; gap: 20px; align-items: baseline; padding: 24px 0; border-bottom: 1px solid var(--line); }
.tool-no { font-style: italic; color: var(--mute); }
.tool h3 { font-size: 23px; font-weight: 500; letter-spacing: -.2px; }
.tool p { margin-top: 4px; color: var(--ink-2); font-size: 17.5px; max-width: 720px; }
.tool-tech { margin-top: 6px; display: flex; flex-wrap: wrap; }
.tool-links { display: flex; gap: 18px; white-space: nowrap; }

/* ---------- beceriler ---------- */
.skills { display: grid; grid-template-columns: repeat(3, 1fr); gap: 48px; }
.skill-group { border-top: 1px solid var(--ink); padding-top: 20px; }
.skill-group h3 { font-size: 25px; font-weight: 500; letter-spacing: -.2px; }
.skill-blurb { margin-top: 6px; color: var(--mute); font-size: 17px; font-style: italic; min-height: 3.2em; }
.skill-list { list-style: none; margin-top: 14px; }
.skill-item { display: grid; gap: 2px; padding: 12px 0; border-top: 1px solid var(--line); }
.skill-name { font-weight: 600; font-size: 17.5px; }
.skill-note { font-size: 15.5px; line-height: 1.5; color: var(--mute); }
.skill-note a { color: var(--link); font-style: italic; }

/* ---------- Cpk hesaplayıcı ---------- */
.cpk { margin-top: 64px; display: grid; grid-template-columns: 1.1fr 1fr; border-top: 1px solid var(--ink); border-bottom: 1px solid var(--ink); }
.cpk-in { padding: 28px 32px 28px 0; border-right: 1px solid var(--line); }
.cpk-in h3 { font-size: 26px; font-weight: 500; }
.cpk-in > p { margin-top: 6px; color: var(--mute); font-size: 17px; font-style: italic; }
.cpk-fields { margin-top: 20px; display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.cpk-fields label { display: grid; gap: 4px; font-size: 17px; color: var(--mute); }
.cpk-fields input { font: 400 17px var(--mono); padding: 9px 11px; width: 100%; border: 1px solid var(--line-strong); background: var(--bg); color: var(--ink); border-radius: 0; }
.cpk-src { margin-top: 16px; font-size: 15px; color: var(--mute); }
.cpk-out { padding: 28px 0 28px 32px; display: flex; flex-direction: column; gap: 12px; }
.cpk-row { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.cpk-row span { font-size: 20px; color: var(--mute); }
.cpk-row b { font-size: 44px; font-weight: 400; line-height: 1; font-variant-numeric: lining-nums tabular-nums; }
.cpk-verdict { font-style: italic; font-size: 20px; color: var(--link); }
.cpk-verdict[data-state="low"] { color: var(--accent); }
.cpk-formula { font: 400 12.5px/1.6 var(--mono); color: var(--mute); }
.cpk-note { font-size: 15.5px; color: var(--mute); line-height: 1.5; margin-top: auto; font-style: italic; }

/* ---------- deneyim ---------- */
.timeline { border-top: 1px solid var(--ink); }
.xp { display: grid; grid-template-columns: 220px 1fr; gap: 32px; padding: 32px 0; border-bottom: 1px solid var(--line); }
.xp-when { font-size: 16px; line-height: 1.6; color: var(--mute); font-style: italic; }
.xp-when b { display: block; color: var(--ink); font-weight: 600; font-style: normal; font-size: 18px; }
.xp h3 { font-size: 25px; font-weight: 500; letter-spacing: -.2px; line-height: 1.2; }
.xp-org { margin-top: 4px; font-size: 17.5px; color: var(--ink-2); font-style: italic; }
.xp ul { list-style: none; margin-top: 12px; display: grid; gap: 6px; color: var(--ink-2); font-size: 18px; }
.xp li { padding-left: 20px; position: relative; }
.xp li::before { content: '—'; position: absolute; left: 0; color: var(--mute); }
.xp-links { margin-top: 12px; display: flex; gap: 16px; }

/* ---------- eğitim & sertifikalar ---------- */
.edu-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 64px; align-items: start; }
.edu-block h3, .cert-block h3 { font-size: 20px; font-weight: 400; color: var(--mute); margin-bottom: 12px; }
.edu { border-top: 1px solid var(--ink); padding-top: 18px; }
.edu-school { font-size: 25px; font-weight: 500; letter-spacing: -.2px; line-height: 1.2; }
.edu-degree { margin-top: 6px; font-size: 18.5px; color: var(--ink-2); font-style: italic; }
.edu-note { margin-top: 8px; color: var(--mute); font-size: 17px; }
.langs { margin-top: 36px; }
.langs ul { list-style: none; border-top: 1px solid var(--ink); }
.langs li { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 18px; }
.langs li span:last-child { font-style: italic; color: var(--mute); text-align: right; }
.certs { list-style: none; border-top: 1px solid var(--ink); }
.cert { display: grid; grid-template-columns: 1fr auto; gap: 16px; align-items: baseline; padding: 13px 0; border-bottom: 1px solid var(--line); }
.cert-title { font-weight: 600; font-size: 18px; }
.cert-issuer { font-size: 16px; color: var(--mute); font-style: italic; }
.cert-date { font-size: 16px; color: var(--mute); white-space: nowrap; }
.cert a { color: var(--link); }

/* ---------- iletişim ---------- */
.contact { padding: 104px 0; }
.contact-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: 64px; align-items: end; }
.contact-title { font-size: clamp(36px, 4.6vw, 60px); line-height: 1.06; font-weight: 400; letter-spacing: -1px; }
.contact-side p { font-size: 19px; color: var(--ink-2); }
.contact-mail { margin-top: 14px; font-size: clamp(20px, 2.2vw, 26px); overflow-wrap: anywhere; }
.contact-mail a { color: var(--link); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 5px; }
.contact-mail a:hover { color: var(--ink); }
.contact-actions { margin-top: 24px; display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- alt bilgi (editoryal) ---------- */
.footer { padding: 28px 0 40px; border-top: 1px solid var(--line); font-size: 16px; color: var(--mute); }
.footer-inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 32px; }
.footer-inner em { color: var(--mute); }
.footer a { color: var(--ink); }
.footer a:hover { color: var(--link); text-decoration: underline; text-underline-offset: 4px; }
.footer-links { display: flex; gap: 22px; }

/* ---------- görünme animasyonu (yalnız opaklık) ---------- */
.js .reveal { opacity: 0; transition: opacity .6s ease; }
.js .reveal.is-in { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
  .js .reveal { opacity: 1; }
}

/* ---------- vaka sayfası (editoryal) ---------- */
.case { padding: 48px 0 96px; }
.crumb { font-size: 17px; font-style: italic; }
.crumb a { color: var(--mute); }
.crumb a:hover { color: var(--link); }
.case-head { margin-top: 28px; max-width: 920px; }
.case-title { margin-top: 12px; font-size: clamp(38px, 5.2vw, 68px); line-height: 1.04; font-weight: 400; letter-spacing: -1.4px; }
.case-lead { margin-top: 22px; font-size: 22px; line-height: 1.55; color: var(--ink-2); max-width: 760px; }
.case-lead::first-letter { float: left; font-size: 3.2em; line-height: .82; margin: 8px 10px 0 0; font-weight: 600; }
.case-tags { margin-top: 18px; display: flex; flex-wrap: wrap; }
.case-metrics { margin-top: 32px; display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); border-top: 1px solid var(--ink); }
.case-metrics div { padding: 12px 20px 0 0; }
.case-metrics dt { font-size: 17px; color: var(--mute); }
.case-metrics dd { margin-top: 2px; font-size: 26px; line-height: 1.2; font-variant-numeric: lining-nums tabular-nums; }
.case-actions { margin-top: 30px; display: flex; flex-wrap: wrap; gap: 12px; }
.case-hero { margin: 56px 0 0; }
.case-hero img { width: 100%; max-height: 720px; object-fit: cover; object-position: top; border: 1px solid var(--line); background: var(--bg-2); }
.case-hero.is-contain img { object-fit: contain; }
.case-hero figcaption { margin-top: 12px; font-size: 16.5px; font-style: italic; color: var(--mute); max-width: 820px; }
.case-hero figcaption::before { font-style: normal; font-weight: 600; color: var(--ink); }
.case-body { margin-top: 64px; max-width: 760px; }
.case-body section + section { margin-top: 56px; }
.case-body h2 { font-size: 32px; font-weight: 400; letter-spacing: -.4px; line-height: 1.15; }
.case-body p, .case-body li { font-size: 19.5px; line-height: 1.65; color: var(--ink-2); }
.case-body p + p, .case-body ul + p, .case-body p + ul { margin-top: 18px; }
.case-body ul { list-style: none; margin-top: 18px; display: grid; gap: 14px; }
.case-body li { padding-left: 22px; position: relative; }
.case-body li::before { content: '—'; position: absolute; left: 0; color: var(--mute); }
.case-body h2 + div > :first-child, .case-body h2 + p, .case-body h2 + ul { margin-top: 20px; }
.case-body a { color: var(--link); }
.case-body a:hover { text-decoration: underline; text-underline-offset: 4px; }
.case-body table { margin-top: 22px; width: 100%; border-collapse: collapse; font-size: 17px; border-top: 1px solid var(--ink); border-bottom: 1px solid var(--ink); }
.case-body th, .case-body td { text-align: left; padding: 10px 14px 10px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.case-body th { font-size: 17px; font-weight: 400; color: var(--mute); }
.case-body td { font-variant-numeric: lining-nums tabular-nums; color: var(--ink-2); }
.case-body td:not(:first-child), .case-body th:not(:first-child) { text-align: right; padding-right: 0; padding-left: 14px; white-space: nowrap; }
.case-body td.num { font-size: 16.5px; }
.case-body td b { color: var(--link); font-weight: 600; }
.case-body pre { margin-top: 22px; padding: 18px 20px; background: var(--bg-2); border-left: 2px solid var(--ink); color: var(--ink); font: 400 13.5px/1.6 var(--mono); overflow-x: auto; }
.gallery { margin-top: 64px; }
.gallery-head { font-size: 20px; color: var(--mute); margin-bottom: 16px; }
.gallery-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.thumb { display: block; }
.thumb img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: top; border: 1px solid var(--line); background: var(--bg); transition: border-color .2s ease; }
.thumb:hover img { border-color: var(--ink); }
.thumb span { display: block; margin-top: 8px; font-size: 16px; font-style: italic; color: var(--mute); }
.lightbox { border: 0; padding: 0; background: transparent; max-width: none; max-height: none; margin: auto; }
.lightbox::backdrop { background: color-mix(in srgb, var(--code-bg) 90%, transparent); }
.lightbox img { display: block; max-width: 94vw; max-height: 88vh; width: auto; height: auto; background: var(--bg); }
.lightbox-close { position: fixed; top: 24px; right: 24px; width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; background: var(--bg); color: var(--ink); font-size: 24px; }
.lightbox-cap { margin-top: 10px; text-align: center; font-size: 16px; font-style: italic; color: var(--code-ink); }
.related { margin-top: 96px; }

/* ---------- duyarlı düzen ---------- */
@media (max-width: 1100px) {
  :root { --gutter: 40px; }
  .nav-links { gap: 18px; font-size: 16px; }
  .skills { grid-template-columns: 1fr; gap: 32px; }
  .skill-blurb { min-height: 0; }
  .card-featured { grid-template-columns: 1fr; gap: 24px; }
  .sheet-grid { grid-template-columns: 1.4fr .6fr; gap: 40px; }
}

@media (max-width: 920px) {
  :root { --nav-h: 60px; --gutter: 28px; --sheet: 14px; }
  .nav-toggle { display: block; }
  .nav-right { gap: 8px; }
  .nav-links {
    position: absolute; top: var(--nav-h); left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--ink);
    padding: 4px var(--gutter) 16px; font-size: 20px;
    transform: translateY(-6px); opacity: 0; visibility: hidden;
    transition: opacity .2s ease, transform .2s ease, visibility .2s;
  }
  .nav-links.is-open { opacity: 1; transform: none; visibility: visible; }
  .nav-links a { padding: 12px 0; border-bottom: 1px solid var(--line); }
  .sheet-hero { min-height: 0; padding: 40px 0 calc(var(--sheet) + 28px); }
  .sheet-grid { grid-template-columns: 1fr; gap: 28px; }
  .view { max-width: 280px; margin-top: 0; }
  .titleblock { position: relative; right: auto; bottom: auto; width: auto; margin: 28px var(--gutter) 0; }
  .sec { padding: 76px 0; }
  .about-grid, .contact-grid, .sec-intro, .edu-grid, .projects-grid-2 { grid-template-columns: 1fr; }
  .about-grid { gap: 24px; }
  .sec-intro { gap: 14px; margin-bottom: 36px; }
  .xp { grid-template-columns: 1fr; gap: 8px; }
  .tool { grid-template-columns: 1fr; }
  .tool-links { margin-top: 6px; }
  .cpk { grid-template-columns: 1fr; }
  .cpk-in { padding-right: 0; border-right: 0; border-bottom: 1px solid var(--line); }
  .cpk-out { padding-left: 0; }
  .contact { padding: 76px 0; }
  .contact-grid { gap: 24px; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
  :root { --gutter: 22px; --sheet: 8px; }
  body { font-size: 18px; }
  .sheet-top, .sheet-left { display: none; }
  .sheet-frame::before { inset: 5px; }
  .brand-name { font-size: 16.5px; }
  .sheet-name { font-size: 60px; }
  .sheet-lead { font-size: 19px; }
  .dimline { height: auto; padding-bottom: 16px; font-size: 11.5px; line-height: 1.5; }
  .dimline span { white-space: normal; text-align: center; margin-top: 0; }
  .dimline::before { top: auto; bottom: 7px; }
  .dimline::after { top: auto; bottom: 2.5px; }
  .sheet-cta .btn { flex: 1 1 auto; }
  .titleblock { grid-template-columns: 1fr 1fr; margin: 24px 14px 0; }
  .titleblock .wide, .titleblock > div:last-child { grid-column: span 2; }
  .card { padding: 30px 0; }
  .cert { grid-template-columns: 1fr; gap: 2px; }
  .gallery-grid { grid-template-columns: 1fr; }
  .case-body table { display: block; overflow-x: auto; }
  .case-body p, .case-body li { font-size: 18px; }
  .case-lead { font-size: 20px; }
}

@media print {
  .nav, .skip, .sheet-frame { display: none !important; }
  body { background: #fff; color: #000; font-size: 11.5pt; }
  .sec { padding: 20pt 0; }
  a[href^="http"]::after { content: ' (' attr(href) ')'; font-size: 8.5pt; }
}
