/*
 * UdesQuake site tasarım sistemi (ana sayfayla aynı dil).
 * Renk: uygulamanın paleti (lacivert zemin, güvenlik turuncusu); site ve uygulama tek marka.
 * Yazı: başlıklar Space Grotesk (uygulamanın fontu), metin sistem fontu.
 * İmza: ince sismogram çizgisi (.trace) bölüm ayracı olarak.
 * Vurgu: turuncu yalnızca birincil eylem, bağlantı ve canlı göstergelerde.
 * Kontrast: tüm metin renkleri zemin üstünde 4.5:1 üzeri (turuncu düğmede koyu yazı 6.7:1).
 */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
    --bg: #070b14;
    --bg-raised: #0d1422;
    --bg-sunk: #050810;
    --line: #1c2638;
    --line-strong: #2a3850;
    --text: #e6ebf3;
    --text-soft: #a9b4c6;
    --text-faint: #8391a8;
    --orange: #ff6a00;
    --orange-soft: #f97316;
    --green: #22c55e;
    --red: #ef4444;
    --display: 'Space Grotesk', system-ui, sans-serif;
    --mono: ui-monospace, 'SFMono-Regular', Menlo, monospace;
    --radius: 14px;
    /* Eski sayfa betiklerinin okuduğu adlar, yeni markaya bağlı. */
    --primary: #f97316;
    --secondary: #f97316;
    --accent: #ef4444;
    --dark-bg: #070b14;
    --dark-card: #0d1422;
    --dark-border: #1c2638;
    --text-dim: #8391a8;
}

html { scroll-behavior: smooth; }
body {
    background: var(--bg);
    color: var(--text);
    font: 16px/1.65 system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    overflow-x: hidden;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}
body > main { flex: 1; }
a { color: var(--orange-soft); }
img { max-width: 100%; }
/* Leaflet karoları ve işaretleri kendi boyutunu kullanır; aksi hâlde harita parça parça görünür. */
.leaflet-container img { max-width: none !important; max-height: none !important; }
:focus-visible { outline: 2px solid var(--orange-soft); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3, h4, .display { font-family: var(--display); letter-spacing: -0.01em; color: var(--text); line-height: 1.15; }
.container { max-width: 1160px; margin: 0 auto; padding: 0 24px; }
.narrow { max-width: 780px; }

/* ── Üst çubuk ── */
.site-header {
    position: sticky; top: 0; z-index: 100;
    background: rgba(7, 11, 20, 0.86);
    backdrop-filter: blur(12px); /* tek cam öğe: içerik altından geçerken okunabilirlik */
    border-bottom: 1px solid var(--line);
}
.site-header nav { display: flex; align-items: center; justify-content: space-between; gap: 20px; height: 68px; }
.logo { font-family: var(--display); font-weight: 700; font-size: 20px; min-height: 44px; display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); }
.logo img { width: 30px; height: 30px; border-radius: 8px; }
.nav-links { display: flex; gap: 26px; list-style: none; }
.nav-links a { color: var(--text-soft); text-decoration: none; font-size: 15px; padding: 6px 0; transition: color .2s; }
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--text); }
.nav-links a[aria-current="page"] { box-shadow: inset 0 -2px 0 var(--orange-soft); }
.nav-live-link i { color: var(--orange-soft); }
.nav-actions { display: flex; align-items: center; gap: 14px; }
.nav-actions .login { color: var(--text-soft); text-decoration: none; font-size: 15px; min-height: 44px; display: inline-flex; align-items: center; }
.cta-button {
    background: var(--orange); color: #0b0f19; font: 600 15px var(--display);
    padding: 10px 18px; min-height: 44px; display: inline-flex; align-items: center; border-radius: 10px; text-decoration: none; white-space: nowrap; transition: background .2s;
}
.cta-button:hover { background: #ff7d22; }
.nav-toggle {
    display: none; background: none; border: 1px solid var(--line-strong); color: var(--text);
    border-radius: 10px; width: 44px; height: 44px; align-items: center; justify-content: center; cursor: pointer;
}

/* ── Sayfa başı (alt sayfalar) ── */
.page-head { padding: 64px 0 28px; }
.page-kicker { color: var(--orange-soft); font: 600 14px var(--display); display: block; margin-bottom: 10px; }
.page-head h1 { font-size: clamp(34px, 4.6vw, 52px); margin-bottom: 14px; }
.page-head p { color: var(--text-soft); font-size: 18px; max-width: 40em; }
.trace { display: block; width: 100%; height: 28px; margin: 18px 0 28px; color: var(--line-strong); }

/* ── Düğmeler ── */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px;
    padding: 12px 20px; border-radius: 12px; font: 600 15px/1.2 var(--display); cursor: pointer;
    text-decoration: none; border: 1px solid var(--line-strong); background: var(--bg-raised); color: var(--text);
    transition: border-color .2s, background .2s, transform .2s;
}
.btn:hover { border-color: var(--text-faint); transform: translateY(-1px); }
.btn-primary { background: var(--orange); border-color: var(--orange); color: #0b0f19; }
.btn-primary:hover { background: #ff7d22; border-color: #ff7d22; }
.btn[disabled], .btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }

/* ── Kart ve uzun metin ── */
.card { background: var(--bg-raised); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.prose { color: var(--text-soft); font-size: 16.5px; }
.prose h2 { font-size: 26px; margin: 40px 0 12px; }
.prose h3 { font-size: 20px; margin: 28px 0 10px; }
.prose p, .prose ul, .prose ol { margin: 0 0 16px; }
.prose ul, .prose ol { padding-left: 22px; }
.prose li { margin: 6px 0; }
.prose strong { color: var(--text); }
.prose code { font: 14px var(--mono); background: var(--bg-sunk); border: 1px solid var(--line); border-radius: 6px; padding: 1px 6px; color: var(--text); }
.prose pre { background: var(--bg-sunk); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; overflow-x: auto; margin: 0 0 18px; }
.prose pre code { border: 0; padding: 0; background: none; font-size: 14px; line-height: 1.7; }
.muted { color: var(--text-faint); }

/* ── Form ── */
label { display: block; font: 500 14px var(--display); color: var(--text-soft); margin-bottom: 6px; }
input, select, textarea {
    width: 100%; min-height: 48px; padding: 12px 14px; border-radius: 10px; border: 1px solid var(--line-strong);
    background: var(--bg-sunk); color: var(--text); font: 16px system-ui, sans-serif;
}
textarea { min-height: 130px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--orange-soft); outline: none; box-shadow: 0 0 0 3px rgba(249,115,22,.25); }
input[type="checkbox"], input[type="radio"] { width: 18px; min-height: 18px; accent-color: var(--orange-soft); }
.field { margin-bottom: 16px; }

/* ── Tablo ── */
table { width: 100%; border-collapse: collapse; font-size: 15px; }
th, td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font: 600 14px var(--display); color: var(--text-soft); }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }

/* ── Durum etiketleri ── */
.status-ok { color: var(--green); }
.status-bad { color: var(--red); }
.notice { border: 1px solid var(--line-strong); border-radius: 12px; padding: 14px 16px; color: var(--text-soft); background: var(--bg-sunk); }
.notice.ok { border-color: rgba(34,197,94,.45); }
.notice.err { border-color: rgba(239,68,68,.5); }

/* ── Alt bilgi ── */
.site-footer { border-top: 1px solid var(--line); padding: 34px 0 40px; color: var(--text-faint); font-size: 14px; margin-top: 72px; }
.footer-row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 18px; align-items: center; }
.footer-links, .footer-social { display: flex; flex-wrap: wrap; gap: 4px 22px; }
.site-footer a { color: var(--text-soft); text-decoration: none; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; }
.site-footer a:hover { color: var(--text); }

/* Kaydırınca bir kez belirme: okuma sırasını yönlendirir. */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
    .reveal { opacity: 1; transform: none; transition: none; }
    html { scroll-behavior: auto; }
}

@media (max-width: 860px) {
    .nav-links { display: none; }
    .nav-links.open {
        display: flex; flex-direction: column; gap: 4px; position: absolute; top: 68px; left: 0; right: 0;
        padding: 12px 24px 18px; background: var(--bg); border-bottom: 1px solid var(--line);
    }
    .nav-links.open a { display: block; padding: 10px 0; font-size: 17px; }
    .nav-toggle { display: inline-flex; }
    .nav-actions .login { display: none !important; }
}
@media (max-width: 560px) {
    .container { padding: 0 16px; }
    .site-header nav { gap: 10px; }
    .cta-button { padding: 10px 14px; font-size: 14px; }
    .page-head { padding-top: 40px; }
    .page-head p { font-size: 16px; }
    .card { padding: 20px; }
    th, td { padding: 10px; }
}
