/* ==========================================================================
   Tema değişkenleri
   ========================================================================== */
:root {
  --bg: #f7f7f5;
  --bg-elev: #ffffff;
  --bg-soft: #efefec;
  --text: #16181d;
  --text-soft: #4b5160;
  --text-mute: #7a8090;
  --border: #e2e2dd;
  --accent: #2f6df6;
  --accent-soft: rgba(47, 109, 246, .1);
  --accent-2: #0fa37f;
  --warn: #c27a00;
  --shadow: 0 1px 2px rgba(0,0,0,.04), 0 8px 24px rgba(0,0,0,.06);
  --radius: 14px;
  --radius-sm: 8px;
  --maxw: 1120px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "Cascadia Code", Consolas, monospace;
  color-scheme: light;
}

:root[data-theme="dark"] {
  --bg: #0d1016;
  --bg-elev: #141821;
  --bg-soft: #1a1f2a;
  --text: #e8eaf0;
  --text-soft: #b3b9c7;
  --text-mute: #808898;
  --border: #252b38;
  --accent: #6b9bff;
  --accent-soft: rgba(107, 155, 255, .12);
  --accent-2: #34d3a6;
  --warn: #f0b33c;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 10px 30px rgba(0,0,0,.35);
  color-scheme: dark;
}

/* ==========================================================================
   Temel
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.65;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  transition: background .2s, color .2s;
}
img { max-width: 100%; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
h1, h2, h3, h4 { line-height: 1.2; letter-spacing: -.02em; margin: 0 0 .5em; }
h1 { font-size: clamp(2rem, 5vw, 3.2rem); font-weight: 800; }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 700; }
h3 { font-size: 1.15rem; font-weight: 650; }
p { margin: 0 0 1em; }
code, pre, .mono { font-family: var(--mono); }
::selection { background: var(--accent); color: #fff; }

.container { max-width: var(--maxw); margin: 0 auto; padding-inline: 20px; }
.section { padding-block: 72px; }
.section + .section { border-top: 1px solid var(--border); }
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 16px; flex-wrap: wrap; margin-bottom: 32px; }
.section-head h2 { margin: 0; }
.eyebrow {
  font-family: var(--mono); font-size: .8rem; color: var(--accent);
  text-transform: uppercase; letter-spacing: .12em; margin-bottom: 8px; display: block;
}
.lead { font-size: 1.15rem; color: var(--text-soft); max-width: 680px; }
.muted { color: var(--text-mute); }

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; color: var(--text); }
.brand:hover { text-decoration: none; }
.brand-mark {
  width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff; font-family: var(--mono); font-size: .85rem; font-weight: 700;
}
.nav-links { display: flex; align-items: center; gap: 4px; list-style: none; margin: 0; padding: 0; }
.nav-links a {
  display: block; padding: 8px 14px; border-radius: 8px;
  color: var(--text-soft); font-weight: 500; font-size: .95rem;
}
.nav-links a:hover { color: var(--text); background: var(--bg-soft); text-decoration: none; }
.nav-links a.active { color: var(--text); background: var(--bg-soft); }
.nav-actions { display: flex; align-items: center; gap: 6px; }
.icon-btn {
  width: 38px; height: 38px; border-radius: 9px; border: 1px solid var(--border);
  background: var(--bg-elev); color: var(--text); cursor: pointer;
  display: grid; place-items: center;
}
.icon-btn:hover { border-color: var(--text-mute); }
.icon-btn svg { width: 18px; height: 18px; }
.menu-btn { display: none; }

@media (max-width: 760px) {
  .menu-btn { display: grid; }
  .nav-links {
    position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--bg-elev); border-bottom: 1px solid var(--border);
    padding: 8px 20px 16px; display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px 8px; }
}

/* ==========================================================================
   Butonlar, rozetler
   ========================================================================== */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 11px 20px; border-radius: 10px; font-weight: 600; font-size: .95rem;
  border: 1px solid transparent; cursor: pointer; transition: transform .1s, background .15s;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn svg { width: 17px; height: 17px; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: color-mix(in srgb, var(--accent) 88%, #000); }
.btn-ghost { background: var(--bg-elev); color: var(--text); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--text-mute); }
.btn-row { display: flex; gap: 12px; flex-wrap: wrap; }
.btn-share { margin-top: 20px; padding: 8px 14px; font-size: .88rem; }
.btn-share svg { width: 15px; height: 15px; color: #0a66c2; }

.tag {
  display: inline-block; font-family: var(--mono); font-size: .75rem;
  padding: 3px 9px; border-radius: 6px; background: var(--bg-soft);
  color: var(--text-soft); border: 1px solid var(--border);
}
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.status {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: .78rem; font-weight: 600; padding: 3px 10px; border-radius: 999px;
}
.status::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.status-dev { color: var(--warn); background: color-mix(in srgb, var(--warn) 12%, transparent); }
.status-live { color: var(--accent-2); background: color-mix(in srgb, var(--accent-2) 12%, transparent); }
.status-passive { color: var(--text-mute); background: color-mix(in srgb, var(--text-mute) 14%, transparent); }

/* ==========================================================================
   Hero
   ========================================================================== */
.hero { padding-block: 96px 80px; position: relative; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 48px; align-items: center; }
.hero h1 .grad {
  background: linear-gradient(120deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero .lead { margin-bottom: 28px; }
.badge-line {
  display: inline-flex; align-items: center; gap: 8px; font-size: .85rem;
  padding: 6px 12px; border: 1px solid var(--border); border-radius: 999px;
  background: var(--bg-elev); color: var(--text-soft); margin-bottom: 20px;
}
.badge-line .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent-2); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent-2) 25%, transparent); }

.terminal {
  background: #0b0e14; color: #d6dbe6; border-radius: var(--radius);
  border: 1px solid #222838; box-shadow: var(--shadow);
  font-family: var(--mono); font-size: .85rem; overflow: hidden;
}
.terminal-bar { display: flex; gap: 7px; padding: 12px 14px; border-bottom: 1px solid #1d2230; }
.terminal-bar span { width: 11px; height: 11px; border-radius: 50%; background: #3a4152; }
.terminal-bar span:nth-child(1) { background: #ff5f57; }
.terminal-bar span:nth-child(2) { background: #febc2e; }
.terminal-bar span:nth-child(3) { background: #28c840; }
.terminal pre { margin: 0; padding: 18px 20px; line-height: 1.75; white-space: pre-wrap; }
.t-key { color: #7aa2ff; } .t-str { color: #7ee0b5; } .t-com { color: #6b7385; } .t-num { color: #f5b971; }

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero { padding-block: 64px 56px; }
}

/* ==========================================================================
   Metrikler / yetkinlikler
   ========================================================================== */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 48px; }
.stat { padding: 18px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-elev); }
.stat b { display: block; font-size: 1.8rem; letter-spacing: -.03em; }
.stat span { color: var(--text-mute); font-size: .88rem; }
@media (max-width: 700px) { .stats { grid-template-columns: repeat(2, 1fr); } }

.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) { .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .grid-2, .grid-3 { grid-template-columns: 1fr; } }

.card {
  background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 24px; transition: border-color .15s, transform .15s, box-shadow .15s;
}
.card-link { color: inherit; display: flex; flex-direction: column; height: 100%; }
.card-link:hover { text-decoration: none; }
.card:has(.card-link):hover, a.card:hover { border-color: var(--accent); transform: translateY(-2px); box-shadow: var(--shadow); text-decoration: none; }
.card p { color: var(--text-soft); font-size: .95rem; }
.card .icon {
  width: 44px; height: 44px; border-radius: 11px; display: grid; place-items: center;
  background: var(--accent-soft); color: var(--accent); margin-bottom: 16px;
}
.card .icon svg { width: 22px; height: 22px; }

/* Proje kartı */
.project-card { display: flex; flex-direction: column; gap: 12px; padding: 0; overflow: hidden; }
.project-card .cover {
  aspect-ratio: 16 / 7; display: grid; place-items: center; position: relative;
  background: linear-gradient(135deg, var(--c1, var(--accent)), var(--c2, var(--accent-2)));
  color: #fff;
}
.project-card .cover svg { width: 56px; height: 56px; opacity: .95; }
/* Pasif proje: kapak soluk ve gri */
.project-card.is-passive .cover { filter: grayscale(.85); opacity: .7; }
.project-card .cover .status { position: absolute; top: 14px; left: 14px; background: rgba(0,0,0,.35); color: #fff; backdrop-filter: blur(4px); }
.project-card .body { padding: 4px 24px 24px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.project-card h3 { margin: 0; font-size: 1.3rem; }
.project-card p { margin: 0; }
.project-card .links { display: flex; gap: 16px; margin-top: auto; padding-top: 8px; font-weight: 600; font-size: .92rem; }

/* Blog kartı / liste */
.post-card { display: flex; flex-direction: column; gap: 10px; }
.post-card h3 { margin: 0; }
.post-card a.title { color: var(--text); }
.post-meta { display: flex; gap: 12px; flex-wrap: wrap; font-size: .85rem; color: var(--text-mute); font-family: var(--mono); }

.post-list { list-style: none; margin: 0; padding: 0; }
.post-row {
  display: grid; grid-template-columns: 120px 1fr; gap: 24px;
  padding: 22px 0; border-bottom: 1px solid var(--border);
}
.post-row time { font-family: var(--mono); font-size: .85rem; color: var(--text-mute); padding-top: 4px; }
.post-row h3 { margin-bottom: 6px; }
.post-row h3 a { color: var(--text); }
.post-row p { color: var(--text-soft); margin-bottom: 10px; }
@media (max-width: 600px) { .post-row { grid-template-columns: 1fr; gap: 4px; } }

.month-group h2 {
  font-size: 1rem; font-family: var(--mono); color: var(--accent);
  text-transform: uppercase; letter-spacing: .1em; margin: 40px 0 0;
  padding-bottom: 10px; border-bottom: 1px solid var(--border);
}
.month-group:first-child h2 { margin-top: 0; }

.blog-layout { display: grid; grid-template-columns: 1fr 260px; gap: 56px; align-items: start; }
.blog-aside { position: sticky; top: 88px; display: flex; flex-direction: column; gap: 28px; }
.blog-aside h4 { font-size: .8rem; text-transform: uppercase; letter-spacing: .1em; color: var(--text-mute); margin-bottom: 12px; }
.filter-list { display: flex; flex-wrap: wrap; gap: 6px; }
.filter-list button {
  font: inherit; font-family: var(--mono); font-size: .78rem; cursor: pointer;
  padding: 4px 10px; border-radius: 6px; border: 1px solid var(--border);
  background: var(--bg-elev); color: var(--text-soft);
}
.filter-list button.active, .filter-list button:hover { border-color: var(--accent); color: var(--accent); }
.archive-list { list-style: none; padding: 0; margin: 0; font-size: .92rem; }
.archive-list li { display: flex; justify-content: space-between; padding: 6px 0; border-bottom: 1px dashed var(--border); }
.archive-list a { color: var(--text-soft); }
.search {
  width: 100%; padding: 10px 14px; border-radius: 10px; border: 1px solid var(--border);
  background: var(--bg-elev); color: var(--text); font: inherit; font-size: .92rem;
}
.search:focus { outline: 2px solid var(--accent-soft); border-color: var(--accent); }
@media (max-width: 900px) {
  .blog-layout { grid-template-columns: 1fr; }
  .blog-aside { position: static; order: -1; }
}

/* ==========================================================================
   Sayfa başlığı
   ========================================================================== */
.page-head { padding-block: 64px 40px; border-bottom: 1px solid var(--border); }
.page-head h1 { font-size: clamp(2rem, 4vw, 2.7rem); }
.breadcrumb { font-family: var(--mono); font-size: .82rem; color: var(--text-mute); margin-bottom: 16px; }
.breadcrumb a { color: var(--text-mute); }

/* ==========================================================================
   Makale (blog yazısı, proje detayı)
   ========================================================================== */
.prose { max-width: 720px; font-size: 1.05rem; }
.prose h2 { margin-top: 2em; font-size: 1.55rem; }
.prose h3 { margin-top: 1.6em; }
.prose p, .prose li { color: var(--text-soft); }
.prose strong { color: var(--text); }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.2em; }
.prose li { margin-bottom: .4em; }
.prose blockquote {
  margin: 1.5em 0; padding: 4px 20px; border-left: 3px solid var(--accent);
  color: var(--text-soft); font-style: italic;
}
.prose :not(pre) > code {
  font-size: .88em; padding: 2px 6px; border-radius: 5px;
  background: var(--bg-soft); border: 1px solid var(--border); color: var(--text);
}
.prose pre {
  background: #0b0e14; color: #d6dbe6; padding: 18px 20px; border-radius: var(--radius-sm);
  overflow-x: auto; font-size: .87rem; line-height: 1.65; border: 1px solid #222838; margin: 1.4em 0;
}
.prose table { width: 100%; border-collapse: collapse; font-size: .95rem; margin: 1.4em 0; }
.table-wrap { overflow-x: auto; }
.prose th, .prose td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--border); }
.prose th { color: var(--text); font-weight: 600; background: var(--bg-soft); }
.callout {
  padding: 16px 20px; border-radius: var(--radius-sm); background: var(--accent-soft);
  border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent); margin: 1.5em 0;
}
.callout p:last-child { margin: 0; }

.article-layout { display: grid; grid-template-columns: 1fr 280px; gap: 56px; padding-block: 48px 80px; align-items: start; }
.article-aside { position: sticky; top: 88px; }
.info-box { border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-elev); padding: 20px; }
.info-box dl { margin: 0; display: grid; gap: 14px; }
.info-box dt { font-size: .75rem; text-transform: uppercase; letter-spacing: .1em; color: var(--text-mute); }
.info-box dd { margin: 2px 0 0; font-weight: 500; }
@media (max-width: 900px) {
  .article-layout { grid-template-columns: 1fr; }
  .article-aside { position: static; }
}

.post-nav { display: flex; justify-content: space-between; gap: 16px; margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--border); }

/* Mimari diyagram kutuları */
.arch { display: grid; gap: 10px; margin: 1.5em 0; font-family: var(--mono); font-size: .82rem; }
.arch-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; }
.arch-box {
  padding: 12px; border-radius: var(--radius-sm); text-align: center;
  border: 1px solid var(--border); background: var(--bg-elev); color: var(--text);
}
.arch-box.primary { border-color: var(--accent); background: var(--accent-soft); }
.arch-label { text-align: center; color: var(--text-mute); font-size: .75rem; }

/* ==========================================================================
   CTA / iletişim
   ========================================================================== */
.cta {
  border-radius: 20px; padding: 48px; text-align: center;
  background:
    radial-gradient(ellipse at top left, var(--accent-soft), transparent 60%),
    var(--bg-elev);
  border: 1px solid var(--border);
}
.cta .btn-row { justify-content: center; margin-top: 24px; }
@media (max-width: 600px) { .cta { padding: 32px 20px; } }

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer { border-top: 1px solid var(--border); padding-block: 36px; margin-top: 40px; }
.footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.footer-inner p { margin: 0; color: var(--text-mute); font-size: .9rem; }
.socials { display: flex; gap: 8px; }
.socials a { color: var(--text-soft); }

.empty { padding: 40px; text-align: center; color: var(--text-mute); border: 1px dashed var(--border); border-radius: var(--radius); }

/* ==========================================================================
   Yazdırma (CV sayfası için)
   ========================================================================== */
@media print {
  .site-header, .site-footer, .no-print { display: none !important; }
  body { background: #fff; color: #000; font-size: 12px; }
  .cv-simple { padding: 0; max-width: none; }
  .tag { border-color: #ccc; background: none; color: #000; }
}

/* ==========================================================================
   Tema butonu ikonları
   ========================================================================== */
#theme-btn .i-dark { display: none; }
:root[data-theme="dark"] #theme-btn .i-dark { display: grid; }
:root[data-theme="dark"] #theme-btn .i-light { display: none; }
#theme-btn span { display: grid; place-items: center; }
a.tag:hover { border-color: var(--accent); color: var(--accent); text-decoration: none; }
.contact-list svg { width: 17px; height: 17px; }
[hidden] { display: none !important; }

/* CV (sade, tek kolon) */
.cv-simple { max-width: 760px; padding-block: 56px 80px; }
.cv-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; flex-wrap: wrap; padding-bottom: 24px; border-bottom: 1px solid var(--border); margin-bottom: 32px; }
.cv-top h1 { font-size: clamp(1.8rem, 4vw, 2.4rem); margin-bottom: 4px; }
.cv-title { color: var(--text-soft); font-size: 1.05rem; margin: 0 0 10px; }
.cv-contact { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 0; font-size: .92rem; color: var(--text-mute); }
.cv-body { max-width: none; font-size: 1rem; }
.cv-body h2, .cv-skills h2 { font-size: .8rem; text-transform: uppercase; letter-spacing: .12em; color: var(--text-mute); font-weight: 600; margin: 36px 0 14px; }
.cv-body h2:first-child { margin-top: 0; }
.cv-body h3 { font-size: 1rem; margin: 18px 0 0; }
.cv-body h3 + p { font-family: var(--mono); font-size: .8rem; color: var(--text-mute); margin: 2px 0 4px; }
.cv-body p { margin-bottom: .6em; }
.cv-skills .tags { gap: 6px; }

/* ==========================================================================
   Admin paneli
   ========================================================================== */
.admin-main { padding-block: 32px 80px; }
.admin-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 24px; }
.admin-head h1 { font-size: 1.8rem; margin: 0; }
.admin-card { background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; margin-bottom: 24px; }
.admin-card h2 { font-size: 1.1rem; margin-bottom: 16px; }
.admin-table { width: 100%; border-collapse: collapse; font-size: .94rem; }
.admin-table th, .admin-table td { text-align: left; padding: 12px 10px; border-bottom: 1px solid var(--border); vertical-align: top; }
.admin-table th { font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; color: var(--text-mute); font-weight: 600; }
.admin-table .actions { text-align: right; white-space: nowrap; }
.admin-table .actions a { margin-left: 14px; }
.small { font-size: .8rem; }
.btn-sm { padding: 6px 12px; font-size: .82rem; }
.btn-danger { background: transparent; color: #d64545; border-color: color-mix(in srgb, #d64545 40%, transparent); }
.btn-danger:hover { background: color-mix(in srgb, #d64545 10%, transparent); }

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.span-2 { grid-column: span 2; }
@media (max-width: 700px) { .form-grid { grid-template-columns: 1fr; } .span-2 { grid-column: auto; } }
.field { display: flex; flex-direction: column; gap: 6px; }
.field > span { font-size: .85rem; font-weight: 600; color: var(--text-soft); }
.field em { font-style: normal; font-weight: 400; color: var(--text-mute); }
.field input:not([type=checkbox]):not([type=color]):not([type=file]), .field textarea, .field select, .editor textarea {
  width: 100%; padding: 10px 12px; border-radius: 9px; border: 1px solid var(--border);
  background: var(--bg); color: var(--text); font: inherit; font-size: .95rem;
}
.field input:focus, .field textarea:focus, .field select:focus, .editor textarea:focus { outline: 2px solid var(--accent-soft); border-color: var(--accent); }
.field input[type=color] { width: 48px; height: 38px; border: 1px solid var(--border); border-radius: 8px; background: none; padding: 2px; }
.check { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--accent); }

.editor { margin-top: 20px; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: var(--bg-elev); }
.editor-tabs { display: flex; justify-content: space-between; padding: 10px 14px; border-bottom: 1px solid var(--border); font-size: .85rem; font-weight: 600; color: var(--text-soft); }
.editor-panes { display: grid; grid-template-columns: 1fr 1fr; min-height: 480px; }
.editor textarea { border: 0 !important; border-radius: 0 !important; resize: vertical; font-family: var(--mono) !important; font-size: .87rem !important; line-height: 1.6; border-right: 1px solid var(--border) !important; }
.editor-preview { padding: 16px 20px; overflow: auto; max-height: 720px; font-size: .95rem; }
@media (max-width: 900px) { .editor-panes { grid-template-columns: 1fr; } .editor textarea { border-right: 0 !important; border-bottom: 1px solid var(--border) !important; } }

.form-actions { display: flex; justify-content: flex-end; align-items: center; gap: 20px; margin-top: 20px; position: sticky; bottom: 0; padding: 14px 0; background: var(--bg); border-top: 1px solid var(--border); }
.danger-zone { margin-top: 40px; padding-top: 20px; border-top: 1px dashed var(--border); }

.alert { padding: 12px 16px; border-radius: 10px; margin-bottom: 20px; font-size: .92rem; background: var(--bg-soft); border: 1px solid var(--border); }
.alert-ok { background: color-mix(in srgb, var(--accent-2) 10%, transparent); border-color: color-mix(in srgb, var(--accent-2) 35%, transparent); }
.alert-err { background: color-mix(in srgb, #d64545 10%, transparent); border-color: color-mix(in srgb, #d64545 35%, transparent); color: #d64545; }

.login-wrap { min-height: 100vh; display: grid; place-items: center; padding: 20px; }
.login-card { width: 100%; max-width: 380px; display: flex; flex-direction: column; gap: 14px; }
.login-card h2 { margin: 0 0 4px; }

.media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.media-item { border: 1px solid var(--border); border-radius: 10px; overflow: hidden; background: var(--bg); }
.media-thumb { aspect-ratio: 16 / 10; display: grid; place-items: center; background: var(--bg-soft); color: var(--text-mute); }
.media-thumb img { width: 100%; height: 100%; object-fit: cover; }
.media-info { padding: 10px 12px; display: grid; gap: 4px; }
.media-info .mono { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.media-actions { display: flex; gap: 6px; margin-top: 6px; }
.nav-actions form { margin: 0; }

/* Grid kolonlarının uzun içerikle (kod, tablo) taşmasını engelle */
.blog-layout > *, .article-layout > *, .hero-grid > *, .editor-panes > * { min-width: 0; }
.prose img { border-radius: var(--radius-sm); margin: 1.4em 0; }

/* CV teknoloji grupları */
.skill-rows { margin: 0; display: grid; gap: 12px; }
.skill-row { display: grid; grid-template-columns: 170px 1fr; gap: 12px; align-items: baseline; padding-bottom: 12px; border-bottom: 1px dashed var(--border); }
.skill-row:last-child { border-bottom: 0; }
.skill-row dt { font-size: .88rem; font-weight: 600; color: var(--text-soft); }
.skill-row dd { margin: 0; }
@media (max-width: 600px) { .skill-row { grid-template-columns: 1fr; gap: 6px; } }

/* Header sosyal simgeleri: dar ekranda gizlenir (footer'da zaten var) */
.nav-social:hover { text-decoration: none; color: var(--accent); border-color: var(--accent); }
@media (max-width: 1100px) { .nav-social { display: none; } }

/* Menüde CV vurgusu (yıldız) */
.nav-links a.nav-cv { display: inline-flex; align-items: center; gap: 6px; }
.nav-star { display: inline-grid; color: #f5b301; }
.nav-star svg { width: 14px; height: 14px; }

/* Sosyal simgelerin marka renkleri (üzerine gelince) */
.social-instagram:hover { color: #e1306c; border-color: #e1306c; }
.social-kick:hover { color: #53fc18; border-color: #53fc18; }
:root:not([data-theme="dark"]) .social-kick:hover { color: #1f9e00; border-color: #1f9e00; }

/* Stream sayfası */

/* Tema butonu sosyal simgelerden ayrı dursun: boşluk + ince ayraç */
.nav-actions #theme-btn { position: relative; margin-left: 18px; }
.nav-actions #theme-btn::before {
  content: ""; position: absolute; left: -12px; top: 8px; bottom: 8px;
  width: 1px; background: var(--border);
}
@media (max-width: 1100px) { .nav-actions #theme-btn { margin-left: 0; } .nav-actions #theme-btn::before { display: none; } }

/* Stream: yalnızca oyun listesi */
.stream-section { padding-block: 48px 72px; }

/* Footer her zaman en altta (kısa sayfalarda da) */
body { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
body > main { flex: 1 0 auto; }
.site-footer { margin-top: 0; }

/* Stream: oyun grid'i */
.stream-title { font-size: clamp(1.8rem, 4vw, 2.4rem); margin: 0; }
.game-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; }
.game-tile {
  display: flex; flex-direction: column; overflow: hidden; color: inherit;
  border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-elev);
  transition: border-color .15s, transform .15s, box-shadow .15s;
}
.game-tile:hover { text-decoration: none; border-color: var(--accent); transform: translateY(-3px); box-shadow: var(--shadow); }
.game-tile-cover {
  aspect-ratio: 16 / 9; display: grid; place-items: center; color: #fff;
  background: linear-gradient(135deg, var(--c1), var(--c2));
}
.game-tile-cover svg { width: 64px; height: 64px; transition: transform .2s; }
.game-tile:hover .game-tile-cover svg { transform: scale(1.08); }
.game-tile-body { display: flex; flex-direction: column; gap: 8px; padding: 18px 20px 20px; flex: 1; }
.game-title { font-size: 1.2rem; font-weight: 700; letter-spacing: -.01em; }
.game-summary { color: var(--text-soft); font-size: .95rem; }
.game-play { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; color: var(--accent); margin-top: auto; padding-top: 6px; }
.game-play svg { width: 14px; height: 14px; }

/* Footer'daki sosyal simgeler yalnızca header'dakiler gizliyken görünür (çift gösterim olmasın) */
@media (min-width: 1101px) { .footer-social { display: none; } }

/* Kareli arka plan — tüm sayfa boyunca: üstte görünür, ortada kaybolur, alta doğru yeniden belirir */
body { position: relative; isolation: isolate; }
body:not(.admin)::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image:
    radial-gradient(ellipse 70% 560px at 50% 180px, #000 30%, transparent 75%),
    radial-gradient(ellipse 80% 520px at 50% 100%, #000 25%, transparent 75%);
  mask-image:
    radial-gradient(ellipse 70% 560px at 50% 180px, #000 30%, transparent 75%),
    radial-gradient(ellipse 80% 520px at 50% 100%, #000 25%, transparent 75%);
  opacity: .6;
}

/* Oyun kartı: kartın tamamı ana bağlantı (stretched link), "Demo" ayrı tıklanır */
.game-tile { position: relative; }
.game-tile:hover { cursor: pointer; }
.game-main-link { color: inherit; }
.game-main-link:hover { text-decoration: none; }
.game-main-link::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.game-main-link:focus-visible { outline: none; }
.game-tile:has(.game-main-link:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
.game-actions { display: flex; align-items: center; gap: 18px; margin-top: auto; padding-top: 6px; }
.game-actions .game-play { margin-top: 0; padding-top: 0; }
.game-demo {
  position: relative; z-index: 2; font-weight: 600; font-size: .92rem;
  padding: 4px 10px; border-radius: 7px; border: 1px solid var(--border); color: var(--text-soft);
}
.game-demo:hover { text-decoration: none; color: var(--accent); border-color: var(--accent); }
