/* ============================================================================
   GIZABET — style.css
   Koyu, premium, editoryal, minimalist tek CSS dosyasi.
   Fontlar: Manrope (baslik), Inter (govde), Fira Code (teknik) — self-hosted.
   ========================================================================== */

:root {
    --bg: #0B0F17;
    --bg-secondary: #111827;
    --card: #151E2E;
    --elevated: #1C2940;
    --primary: #2563EB;
    --accent: #06B6D4;
    --success: #16A34A;
    --warning: #F59E0B;
    --danger: #DC2626;
    --text: #F1F5F9;
    --text-secondary: #A7B3C5;
    --border: #273449;

    --font-head: 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --font-mono: 'Fira Code', 'SFMono-Regular', Consolas, 'Liberation Mono', monospace;

    --max-width: 1080px;
    --radius: 10px;
    --radius-sm: 6px;
    --shadow: 0 8px 30px rgba(0, 0, 0, 0.35);
    --focus-ring: 0 0 0 3px rgba(37, 99, 235, 0.55);
}

@font-face {
    font-family: 'Manrope';
    font-style: normal;
    font-weight: 500 800;
    font-display: swap;
    src: url('../fonts/manrope-var.woff2') format('woff2');
}
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400 700;
    font-display: swap;
    src: url('../fonts/inter-var.woff2') format('woff2');
}
@font-face {
    font-family: 'Fira Code';
    font-style: normal;
    font-weight: 400 700;
    font-display: swap;
    src: url('../fonts/fira-code-var.woff2') format('woff2');
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 1.0625rem;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
    font-family: var(--font-head);
    line-height: 1.25;
    color: var(--text);
    font-weight: 700;
    letter-spacing: -0.01em;
}
h1 { font-size: clamp(1.75rem, 4vw, 2.4rem); margin: 0 0 1rem; }
h2 { font-size: clamp(1.4rem, 3vw, 1.8rem); margin: 2.5rem 0 1rem; padding-top: 0.25rem; }
h3 { font-size: clamp(1.15rem, 2vw, 1.35rem); margin: 2rem 0 0.75rem; }

p { margin: 0 0 1.1rem; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
a:focus-visible { outline: var(--focus-ring); outline-offset: 2px; border-radius: 2px; }

ul, ol { padding-left: 1.4rem; margin: 0 0 1.1rem; }
li { margin-bottom: 0.4rem; }

code, .mono {
    font-family: var(--font-mono);
    font-size: 0.9em;
    background: var(--bg-secondary);
    padding: 0.1em 0.4em;
    border-radius: var(--radius-sm);
    color: var(--accent);
}

img { max-width: 100%; height: auto; }

.container { width: 100%; max-width: var(--max-width); margin: 0 auto; padding: 0 1.25rem; }

.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    background: var(--primary);
    color: #fff;
    padding: 0.75rem 1.25rem;
    border-radius: 0 0 var(--radius-sm) var(--radius-sm);
    z-index: 1001;
}
.skip-link:focus { left: 0; }


/* ------- Sticky header ------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(11, 15, 23, 0.92);
    backdrop-filter: saturate(120%) blur(10px);
    border-bottom: 1px solid var(--border);
}
.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 64px;
    gap: 1rem;
}
.brand { display: flex; flex-direction: column; line-height: 1.1; color: var(--text); text-decoration: none; }
.brand:hover { text-decoration: none; }
.brand-logo { font-family: var(--font-head); font-weight: 800; font-size: 1.35rem; letter-spacing: -0.02em; color: #fff; }
.brand-tagline { font-size: 0.72rem; color: var(--text-secondary); letter-spacing: 0.02em; }

.site-nav { display: flex; align-items: center; }
.nav-list { list-style: none; display: flex; gap: 0.25rem; margin: 0; padding: 0; }
.nav-list a {
    display: inline-flex;
    align-items: center;
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
    padding: 0.5rem 0.65rem;
    border-radius: var(--radius-sm);
    min-height: 44px;
}
.nav-list a:hover { color: var(--text); text-decoration: none; background: var(--card); }
.nav-list a[aria-current="page"] { color: #fff; background: var(--elevated); box-shadow: inset 0 -2px 0 var(--primary); }

.nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
}
.nav-toggle-bar { width: 20px; height: 2px; background: var(--text); margin: 0 auto; transition: transform 0.2s ease, opacity 0.2s ease; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

main { min-height: 60vh; }

.page-head {
    padding: 2.5rem 0 1.5rem;
    border-bottom: 1px solid var(--border);
    background: linear-gradient(180deg, var(--bg-secondary), var(--bg));
    margin-bottom: 2rem;
}
.page-head .breadcrumb { margin-bottom: 0.75rem; }

.breadcrumb { font-size: 0.82rem; color: var(--text-secondary); }
.breadcrumb ol { list-style: none; display: flex; flex-wrap: wrap; gap: 0.35rem; margin: 0; padding: 0; }
.breadcrumb li { margin: 0; }
.breadcrumb li + li::before { content: "/"; margin-right: 0.35rem; color: var(--border); }
.breadcrumb a { color: var(--text-secondary); }

.summary-box {
    background: var(--card);
    border: 1px solid var(--border);
    border-left: 4px solid var(--primary);
    border-radius: var(--radius);
    padding: 1.25rem 1.4rem;
    margin: 0 0 2rem;
}
.summary-box p:last-child { margin-bottom: 0; }

.meta-box {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem 2rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 0.9rem 1.2rem;
    margin: 0 0 2rem;
}
.meta-box strong { color: var(--text); font-weight: 600; }

.toc {

/* ------- Kutu ceseitleri ------- */
.note, .warning, .info, .check { border-radius: var(--radius); padding: 1rem 1.25rem; margin: 1.25rem 0; border: 1px solid var(--border); }
.note { background: var(--card); border-left: 4px solid var(--primary); }
.warning { background: rgba(220, 38, 38, 0.08); border-left: 4px solid var(--danger); }
.warning strong:first-child { color: var(--danger); }
.info { background: rgba(6, 182, 212, 0.08); border-left: 4px solid var(--accent); }
.check { background: rgba(22, 163, 74, 0.08); border-left: 4px solid var(--success); }

.table-wrap { overflow-x: auto; margin: 1.25rem 0; }
table { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
th, td { text-align: left; padding: 0.7rem 0.9rem; border-bottom: 1px solid var(--border); vertical-align: top; }
th { background: var(--elevated); color: var(--text); font-weight: 600; }
tr:nth-child(even) td { background: var(--bg-secondary); }

/* ------- Accordion (SSS) — details tabanli ------- */
.accordion { border: 1px solid var(--border); border-radius: var(--radius); margin: 1.25rem 0; background: var(--card); overflow: hidden; }
.accordion + .accordion { margin-top: 0.75rem; }
.accordion summary {
    cursor: pointer;
    padding: 1rem 1.25rem;
    font-weight: 600;
    font-family: var(--font-head);
    color: var(--text);
    list-style: none;
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-height: 44px;
}
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary::after { content: "+"; margin-left: auto; font-family: var(--font-mono); font-size: 1.3rem; color: var(--accent); transition: transform 0.2s ease; }
.accordion[open] summary::after { transform: rotate(45deg); }
.accordion summary:focus-visible { outline: var(--focus-ring); outline-offset: -2px; }
.accordion .accordion-body { padding: 0 1.25rem 1.1rem; }

/* ------- Rehber kartlari ------- */
.cards-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.25rem; margin: 1.5rem 0; }
.card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.4rem; display: flex; flex-direction: column; gap: 0.6rem; transition: transform 0.15s ease, border-color 0.15s ease; }
.card:hover { border-color: var(--primary); transform: translateY(-2px); }
.card h3 { margin: 0; font-size: 1.15rem; }
.card p { font-size: 0.94rem; color: var(--text-secondary); margin: 0; }
.card .card-link { margin-top: auto; font-weight: 600; color: var(--accent); }

.steps { list-style: none; counter-reset: step; padding-left: 0; }
.steps li { counter-increment: step; position: relative; padding-left: 3rem; margin-bottom: 1.1rem; }
.steps li::before {
    content: counter(step);
    position: absolute;
    left: 0; top: 0;
    width: 2rem; height: 2rem;
    background: var(--elevated);
    color: var(--accent);
    font-family: var(--font-mono);
    font-weight: 700;
    display: flex; align-items: center; justify-content: center;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
}

.sources { margin-top: 2rem; }
.sources li { font-size: 0.9rem; color: var(--text-secondary); }
.sources .src-title { color: var(--text); font-weight: 600; }
.sources .src-meta { font-size: 0.8rem; }
.unverified {
    color: var(--warning);
    font-size: 0.8rem;
    font-family: var(--font-mono);
    border: 1px dashed var(--warning);
    border-radius: var(--radius-sm);
    padding: 0.05em 0.4em;
}


/* ------- Footer ------- */
.site-footer { margin-top: 4rem; background: var(--bg-secondary); border-top: 1px solid var(--border); padding: 3rem 0 2rem; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 2rem; margin-bottom: 2rem; }
.footer-brand { font-family: var(--font-head); font-weight: 800; font-size: 1.3rem; margin: 0 0 0.25rem; color: #fff; }
.footer-tagline { font-size: 0.85rem; color: var(--accent); margin: 0 0 0.75rem; }
.footer-desc { font-size: 0.88rem; color: var(--text-secondary); }
.footer-heading { font-family: var(--font-head); font-weight: 700; font-size: 0.9rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-secondary); margin: 0 0 0.75rem; }
.footer-list { list-style: none; padding: 0; margin: 0; }
.footer-list li { margin-bottom: 0.5rem; }
.footer-list a { color: var(--text-secondary); font-size: 0.9rem; display: inline-block; min-height: 32px; line-height: 1.3; }
.footer-list a:hover { color: var(--accent); }

.footer-legal { border-top: 1px solid var(--border); padding-top: 1.5rem; font-size: 0.85rem; color: var(--text-secondary); }
.age-warning { background: rgba(220, 38, 38, 0.1); border: 1px solid var(--danger); border-radius: var(--radius); padding: 0.8rem 1rem; color: var(--text); }
.age-warning strong { color: var(--danger); font-size: 1.05rem; }
.responsible-note { margin-top: 0.75rem; }
.responsible-note a { color: var(--warning); font-weight: 600; }
.disclaimer { margin-top: 0.75rem; }
.copyright { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--border); }

/* ------- Yukari cik butonu ------- */
.back-to-top {
    position: fixed;
    right: 1.25rem; bottom: 1.25rem;
    width: 48px; height: 48px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    border: none;
    cursor: pointer;
    font-size: 1.4rem;
    box-shadow: var(--shadow);
    z-index: 900;
    display: flex; align-items: center; justify-content: center;
}
.back-to-top[hidden] { display: none; }

/* ------- 404 ------- */
.error-page { text-align: center; padding: 5rem 0; }
.error-code { font-family: var(--font-mono); font-size: 5rem; font-weight: 700; color: var(--accent); line-height: 1; }

/* ------- Mobil ------- */
@media (max-width: 900px) {
    .nav-toggle { display: flex; }
    .nav-list {
        position: absolute;
        top: 64px; left: 0; right: 0;
        flex-direction: column;
        background: var(--bg);
        border-bottom: 1px solid var(--border);
        padding: 0.5rem 1rem 1rem;
        display: none;
        z-index: 1000;
    }
    .nav-list.is-open { display: flex; }
    .nav-list li { margin: 0; }
    .nav-list a { width: 100%; padding: 0.75rem 0.5rem; border-radius: var(--radius-sm); }
}

/* ------- Reduced motion ------- */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    * { transition: none !important; animation: none !important; }
}

.scope-box { border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-secondary); padding: 1.1rem 1.3rem; margin: 2rem 0; font-size: 0.92rem; }
.scope-box h2 { margin: 0 0 0.5rem; font-size: 1.1rem; }

.byline { display: flex; gap: 1rem; align-items: flex-start; border: 1px solid var(--border); border-radius: var(--radius); background: var(--card); padding: 1.1rem 1.3rem; margin: 1.5rem 0; }
.byline-avatar { flex: 0 0 48px; width: 48px; height: 48px; border-radius: 50%; background: var(--elevated); color: var(--accent); display: flex; align-items: center; justify-content: center; font-family: var(--font-head); font-weight: 800; font-size: 1.1rem; }
.byline p { margin: 0; font-size: 0.9rem; color: var(--text-secondary); }
.byline .byline-name { color: var(--text); font-weight: 700; }

    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem 1.4rem;
    margin: 0 0 2rem;
}
.toc-title { font-family: var(--font-head); font-weight: 700; font-size: 0.95rem; margin: 0 0 0.75rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-secondary); }
.toc ol { list-style: none; counter-reset: toc; margin: 0; padding: 0; }
.toc li { counter-increment: toc; margin: 0.3rem 0; }
.toc a { color: var(--text); text-decoration: none; padding: 0.35rem 0; display: flex; gap: 0.6rem; min-height: 40px; align-items: center; }
.toc a::before { content: counter(toc, decimal-leading-zero); font-family: var(--font-mono); font-size: 0.78rem; color: var(--accent); }
.toc a:hover { color: var(--accent); text-decoration: none; }
.toc a.is-active { color: var(--accent); font-weight: 600; }
