/* SMPRO herkese açık sayfalar: tanıtım, Pro başvurusu, giriş, hukuki metinler.
   Tek tasarım dili: sade nötr yüzeyler, tek mor vurgu, ince çizgiler, hızlı ve yumuşak hareket. */
@import url("../fonts/local/inter/font.css");

:root {
    --p-ink: #18181b;
    --p-ink-2: #3f3f46;
    --p-muted: #6b6b76;
    --p-page: #fafafa;
    --p-surface: #fff;
    --p-subtle: #f4f4f5;
    --p-line: rgb(24 24 27 / 8%);
    --p-line-strong: rgb(24 24 27 / 14%);
    /* Form alanlarının kenarlığı: zemine göre en az 3:1 (WCAG 1.4.11). */
    --p-line-field: #85858f;
    /* En küçük dokunma hedefi: fareli ekranda 0, dokunmatik ekranda 44 px (dosyanın sonu). */
    --p-hit: 0px;
    /* Ana düğme: açık temada koyu zemin, koyu temada açık zemin (build-dark-theme.py sabit değerleri). */
    --p-surface-primary: #18181b;
    --p-ink-on-primary: #fff;
    /* Koyu bant (çağrı kutusu): iki temada da koyu kalır. */
    --p-surface-band: #18181b;
    --p-accent: #6546db;
    --p-accent-hover: #5536c9;
    --p-accent-soft: #f1edff;
    --p-accent-ink: #4c2fbf;
    --p-sun: #ffc72c;
    --p-ok: #15803d;
    --p-danger: #b42318;

    /* Sayfalarda geçen diğer yazı renkleri */
    --p-ink-green-20: #14532d;
    --p-ink-green-36: #3f7a52;
    --p-ink-orange-24: #7a4b00;
    --p-ink-white: #fff;

    /* Sayfalarda geçen diğer zemin renkleri */
    --p-surface-amber-96: #fffaeb;
    --p-surface-black: #000;
    --p-surface-n10: #18181b;
    --p-surface-n10-2: #1f1a14;
    --p-surface-n10-a4: rgb(24 24 27 / 4%);
    --p-surface-n10-a40: rgb(24 24 27 / 40%);
    --p-surface-n16: #27272a;
    --p-surface-n90: #e4e4e7;
    --p-surface-n95: #ecf8ef;
    --p-surface-n96: #ecfdf3;
    --p-surface-n97: #f3fbf5;
    --p-surface-n98: #fff6f5;
    --p-surface-n98-2: #fbfbfb;
    --p-surface-n98-a80: rgb(250 250 250 / 80%);
    --p-surface-n98-a85: rgb(250 250 250 / 85%);
    --p-surface-n99: #fbfaff;
    --p-surface-n99-2: #fcfcfc;
    --p-surface-violet-57-a12: rgb(101 70 219 / 12%);
    --p-surface-violet-57-a14: rgb(101 70 219 / 14%);
    --p-surface-violet-57-a55: rgb(101 70 219 / 55%);
    --p-surface-violet-57-a8: rgb(101 70 219 / 8%);
    --p-surface-white-a92: rgb(255 255 255 / 92%);
    --p-surface-white-a96: rgb(255 255 255 / 96%);

    /* Sayfalarda geçen diğer kenarlık renkleri */
    --p-line-green-29-a22: rgb(21 128 61 / 22%);
    --p-line-green-29-a40: rgb(21 128 61 / 40%);
    --p-line-n10-a22: rgb(24 24 27 / 22%);
    --p-line-orange-35-a20: rgb(180 99 0 / 20%);
    --p-line-red-40-a20: rgb(180 35 24 / 20%);
    --p-line-violet-57-a20: rgb(101 70 219 / 20%);
    --p-line-violet-57-a22: rgb(101 70 219 / 22%);
    --p-line-violet-57-a35: rgb(101 70 219 / 35%);
    --p-line-white-a85: rgb(255 255 255 / 85%);

    /* Sayfalarda geçen diğer gölge renkleri */
    --p-shadow-amber-59-a25: rgb(255 199 44 / 25%);
    --p-shadow-black-a25: rgb(0 0 0 / 25%);
    --p-shadow-black-a30: rgb(0 0 0 / 30%);
    --p-shadow-black-a35: rgb(0 0 0 / 35%);
    --p-shadow-n10-a14: rgb(24 24 27 / 14%);
    --p-shadow-n10-a20: rgb(24 24 27 / 20%);
    --p-shadow-n10-a28: rgb(24 24 27 / 28%);
    --p-shadow-n10-a4: rgb(24 24 27 / 4%);
    --p-shadow-n10-a5: rgb(24 24 27 / 5%);
    --p-shadow-violet-47-a30: rgb(76 47 191 / 30%);
    --p-shadow-violet-57-a14: rgb(101 70 219 / 14%);
    --p-shadow-violet-57-a5: rgb(101 70 219 / 5%);
    --p-shadow-violet-57-a8: rgb(101 70 219 / 8%);
    --p-shadow-white-a12: rgb(255 255 255 / 12%);
    --p-shadow-white-a16: rgb(255 255 255 / 16%);
    --p-shadow-white-a8: rgb(255 255 255 / 8%);

    --p-radius-sm: 8px;
    --p-radius: 12px;
    --p-radius-lg: 20px;
    --p-shadow-sm: 0 1px 2px var(--p-shadow-n10-a5);
    --p-shadow: 0 1px 2px var(--p-shadow-n10-a4), 0 8px 24px -10px var(--p-shadow-n10-a14);
    --p-shadow-lg: 0 2px 4px var(--p-shadow-n10-a4), 0 32px 72px -20px var(--p-shadow-n10-a28);

    --ease-out: cubic-bezier(.23, 1, .32, 1);
    --ease-in-out: cubic-bezier(.77, 0, .175, 1);
    --ease-drawer: cubic-bezier(.32, .72, 0, 1);

    --p-font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 88px; }
body {
    margin: 0;
    background: var(--p-page);
    color: var(--p-ink);
    font: 400 16px/1.6 var(--p-font);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3 { margin: 0; color: var(--p-ink); font-weight: 650; letter-spacing: -.025em; text-wrap: balance; }
p { margin: 0; text-wrap: pretty; }
a { color: inherit; }
/* Güneş / ay düğmesi: açık temada ay, koyu temada güneş (assets/js/theme.js çizer). */
.theme-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: none;
    width: 40px;
    height: 40px;
    padding: 0;
    border: 1px solid var(--p-line-strong);
    border-radius: 999px;
    background: transparent;
    color: var(--p-ink-2);
    cursor: pointer;
    transition: background-color 160ms ease, color 160ms ease, transform 160ms var(--ease-out);
}
.theme-toggle:hover { background: var(--p-subtle); color: var(--p-ink); }
.theme-toggle:active { transform: scale(.96); }
.theme-toggle:focus-visible { outline: 2px solid var(--p-accent); outline-offset: 2px; }
.theme-toggle svg { width: 18px; height: 18px; }
.public-login .theme-toggle { position: fixed; top: 16px; right: 16px; }

::selection { background: var(--p-accent-soft); color: var(--p-accent-ink); }

/* Etiket: küçük, sakin, büyük harf değil. */
.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 16px;
    color: var(--p-accent-ink);
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0;
}
.eyebrow::before {
    content: "";
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--p-sun);
    box-shadow: 0 0 0 3px var(--p-shadow-amber-59-a25);
}

/* Düğmeler: basınca hafifçe küçülür; renk değişimi kısa. */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 40px;
    padding: 0 16px;
    border: 1px solid var(--p-line-strong);
    border-radius: 10px;
    background: var(--p-surface);
    color: var(--p-ink);
    font: 550 14px/1 var(--p-font);
    text-decoration: none;
    white-space: nowrap;
    cursor: pointer;
    box-shadow: var(--p-shadow-sm);
    transition: transform 160ms var(--ease-out), background-color 160ms ease, border-color 160ms ease, box-shadow 160ms ease, color 160ms ease;
    -webkit-tap-highlight-color: transparent;
}
.btn:active { transform: scale(.97); }
.btn.primary {
    border-color: transparent;
    background: var(--p-surface-primary);
    color: var(--p-ink-on-primary);
    box-shadow: 0 1px 2px var(--p-shadow-n10-a20), inset 0 1px 0 var(--p-shadow-white-a12);
}
.btn.accent {
    border-color: transparent;
    background: var(--p-accent);
    color: var(--p-ink-white);
    box-shadow: 0 1px 2px var(--p-shadow-violet-47-a30), inset 0 1px 0 var(--p-shadow-white-a16);
}
.btn.ghost { border-color: transparent; background: transparent; box-shadow: none; color: var(--p-ink-2); }
.btn.lg { min-height: 48px; padding: 0 22px; font-size: 15px; border-radius: 12px; }
@media (hover: hover) and (pointer: fine) {
    .btn:hover { border-color: var(--p-line-n10-a22); background: var(--p-surface-n99-2); }
    .btn.primary:hover { background: var(--p-surface-n16); }
    .btn.accent:hover { background: var(--p-accent-hover); }
    .btn.ghost:hover { background: var(--p-subtle); color: var(--p-ink); }
}

:is(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
    outline: 2px solid var(--p-accent);
    outline-offset: 2px;
    border-radius: 6px;
}

/* Form alanları */
.p-field { display: grid; align-content: start; gap: 6px; color: var(--p-ink-2); font-size: 14px; font-weight: 550; }
.p-input,
.p-field :is(input:not([type=checkbox]):not([type=radio]), select, textarea) {
    width: 100%;
    min-height: 44px;
    padding: 10px 12px;
    border: 1px solid var(--p-line-field);
    border-radius: 10px;
    background: var(--p-surface);
    color: var(--p-ink);
    font: 400 15px/1.4 var(--p-font);
    box-shadow: var(--p-shadow-sm);
    transition: border-color 160ms ease, box-shadow 160ms ease;
}
.p-field textarea { min-height: 112px; resize: vertical; }
.p-input::placeholder, .p-field ::placeholder { color: var(--p-muted); }
.p-input:focus, .p-field :is(input, select, textarea):focus {
    outline: none;
    border-color: var(--p-accent);
    box-shadow: 0 0 0 4px var(--p-shadow-violet-57-a14);
}

/* Hukuki bağlantılar: tüm herkese açık sayfaların alt satırı. */
.smpro-legal-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 4px 20px;
    padding: 24px 16px 32px;
    font-size: 13px;
}
.smpro-legal-links a { color: var(--p-muted); text-decoration: none; transition: color 160ms ease; }
.smpro-legal-links a:hover { color: var(--p-ink); }

/* Pencere: açılırken hafif büyüyerek belirir; ortada durduğu için merkezden. */
.p-dialog {
    width: min(560px, calc(100vw - 32px));
    max-height: calc(100dvh - 32px);
    padding: 0;
    border: 1px solid var(--p-line);
    border-radius: var(--p-radius-lg);
    background: var(--p-surface);
    color: var(--p-ink);
    box-shadow: var(--p-shadow-lg);
    overflow: auto;
}
.p-dialog::backdrop { background: var(--p-surface-n10-a40); backdrop-filter: blur(4px); }
@media (prefers-reduced-motion: no-preference) {
    .p-dialog[open] {
        transition: opacity 220ms var(--ease-out), transform 220ms var(--ease-out);
        @starting-style { opacity: 0; transform: scale(.96) translateY(6px); }
    }
    .p-dialog[open]::backdrop {
        transition: opacity 220ms var(--ease-out);
        @starting-style { opacity: 0; }
    }
}

.p-close {
    display: grid;
    place-items: center;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: var(--p-muted);
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    transition: background-color 160ms ease, color 160ms ease, transform 160ms var(--ease-out);
}
.p-close:hover { background: var(--p-subtle); color: var(--p-ink); }
.p-close:active { transform: scale(.94); }

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition-duration: 0ms !important; animation-duration: 0ms !important; scroll-behavior: auto !important; }
}

/* Klavyeyle ilk Tab'da görünen "İçeriğe geç" bağlantısı; üst menüyü atlayıp ana içeriğe götürür (WCAG 2.4.1). */
.skip-link { position: fixed; top: 8px; left: 8px; z-index: 1000; padding: 10px 16px; border-radius: 10px; background: var(--p-surface-primary); color: var(--p-ink-on-primary); font-weight: 600; text-decoration: none; transform: translateY(-160%); }
.skip-link:focus-visible { transform: none; outline: 2px solid var(--p-accent); outline-offset: 2px; }

/* Dokunmatik ekranlarda (telefon, tablet, dokunmatik dizüstü) basılan her bağlantı ve düğme en az 44×44 px
   (WCAG 2.5.5). Fareli ekranda görünüm değişmez. Paragraf içindeki satır içi bağlantılar bunun dışındadır.
   Kendi en küçük boyutunu koyan sayfa kuralları max(..., var(--p-hit)) kullanır. */
@media (any-pointer: coarse) {
    :root { --p-hit: 44px; }
    :is(.btn, .theme-toggle, .brand, .app-brand, .legal-brand, .auth-brand, .admin-entry, .nav a, .app-topbar nav a,
        .legal-topbar nav a, .legal-side a, .smpro-legal-links a, .auth-marketing-link, .application-jump, .contact-email) {
        min-height: var(--p-hit);
    }
    :is(.theme-toggle, .brand, .app-brand, .legal-brand, .auth-brand) { min-width: var(--p-hit); }
}
