/* KulpPasur — eski (Bootstrap) sayfaları yeni tasarıma uyduran köprü katmanı.
   header.php tüm eski CSS'lerden SONRA yükler; yalnızca body.kpy-eski altında çalışır. */

body.kpy-eski {
    --primary: var(--g-600);
    --secondary: var(--gold-3);
    --dark: var(--g-900);
    --light: var(--silk);
    --kp-lg-page: var(--silk);
    --kp-lg-surface: rgba(255, 255, 255, .7);
    --kp-lg-surface-strong: #fff;
    --kp-lg-surface-hover: #fff;
    --kp-lg-border: var(--line);
    --kp-lg-border-soft: var(--line);
    --kp-lg-shadow: var(--shadow);
    --kp-lg-shadow-lg: var(--shadow-lg);
    --kp-lg-shine: 0 0 0 transparent;
    --kp-lg-shine-soft: 0 0 0 transparent;
    --kp-lg-accent: var(--g-500);
    --kp-lg-accent-dark: var(--g-700);
    --kp-lg-text: var(--ink);
    --kp-lg-text-muted: var(--muted);
    --kp-lg-radius: var(--radius);
    --kp-lg-radius-md: var(--radius);
    --kp-lg-radius-sm: 14px;
    --kpy-head-h: 118px;
    margin: 0;
    font-family: 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
    color: var(--ink);
    background: var(--silk) !important;
    -webkit-font-smoothing: antialiased;
}
body.kpy-eski::before { background: var(--silk) !important; }
body.kpy-eski h1, body.kpy-eski h2, body.kpy-eski h3,
body.kpy-eski .h1, body.kpy-eski .h2, body.kpy-eski .h3,
body.kpy-eski .display-1, body.kpy-eski .display-2, body.kpy-eski .display-3,
body.kpy-eski .display-4, body.kpy-eski .display-5, body.kpy-eski .display-6 { font-family: var(--serif); letter-spacing: .2px; }
body.kpy-eski h4, body.kpy-eski h5, body.kpy-eski h6,
body.kpy-eski .h4, body.kpy-eski .h5, body.kpy-eski .h6,
body.kpy-eski .btn { font-family: 'Manrope', system-ui, sans-serif; }

/* Yeni kabuk: eski Bootstrap a{} kuralları ezmesin (özgül kurallar yine kazansın) */
:where(body.kpy-eski .kpy) a, :where(body.kpy-eski .kpy) a:hover { color: inherit; text-decoration: none; }
:where(body.kpy-eski .kpy) ul { padding-left: 0; }
:where(body.kpy-eski .kpy) h5 { line-height: 1.3; }
body.kpy-eski .kpy-footer p { color: inherit; }
body.kp-site .kpy-offcanvas.offcanvas {
    background: linear-gradient(180deg, var(--g-900), var(--g-950)) !important;
    border: 0 !important; box-shadow: -20px 0 60px rgba(0, 0, 0, .35) !important;
    backdrop-filter: none; -webkit-backdrop-filter: none; color: #fff;
}
body.kpy-eski .kpy-header .kpy-container,
body.kpy-eski .kpy-footer .kpy-container,
body.kpy-eski .kpy-pagehead .kpy-container { padding-left: 20px !important; padding-right: 20px !important; }

/* Hero'suz sayfalar: sabit başlık içeriği örtmesin */
body.kpy-duz,
body.kpy-eski:not(:has(.hero-header, .kpy-pagehead, .kpy-hero)) { padding-top: var(--kpy-head-h); }
body.kpy-duz .kpy-header,
body.kpy-eski:not(:has(.hero-header, .kpy-pagehead, .kpy-hero)) .kpy-header { background: rgba(6, 35, 26, .96); box-shadow: 0 10px 30px rgba(0, 0, 0, .18); }

/* ---------- Eski satır içi .hero-header blokları → yeni sayfa başlığı ----------
   Seçici özgüllüğü onemli-yerler.css'teki (0,6,1) !important kuralını geçmeli. */
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell):not(.kpy-a):not(.kpy-b):not(.kpy-c) {
    position: relative !important; isolation: isolate; overflow: hidden;
    height: auto !important; min-height: 0 !important; max-height: none !important;
    padding: calc(var(--kpy-head-h) + 52px) 1rem 112px !important;
    margin: 0 0 2.75rem !important;
    display: flex !important; flex-direction: column; align-items: center; justify-content: center; text-align: center;
    border: 0 !important; box-shadow: none !important; color: #fff;
    background-color: var(--g-950) !important;
    background-size: cover !important; background-position: center 55% !important;
}
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell)::before {
    content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none;
    background:
        linear-gradient(180deg, rgba(4, 21, 14, .9) 0%, rgba(6, 35, 26, .7) 45%, rgba(4, 21, 14, .86) 100%),
        radial-gradient(ellipse 60% 70% at 50% 55%, rgba(201, 165, 90, .18), transparent 70%);
}
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell)::after {
    content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 84px; z-index: 0; pointer-events: none;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 90' preserveAspectRatio='none'%3E%3Cpath fill='%2306231a' fill-opacity='.55' d='M0 90 L0 52 L120 44 L230 54 L330 30 L420 40 L500 16 L560 26 L640 44 L760 34 L860 50 L960 32 L1060 46 L1160 28 L1260 44 L1360 36 L1440 46 L1440 90 Z'/%3E%3Cpath fill='%23f8f4ea' d='M0 90 L0 72 L140 62 L280 70 L420 58 L560 68 L700 56 L840 68 L980 60 L1120 70 L1260 60 L1440 68 L1440 90 Z'/%3E%3C/svg%3E") bottom / 100% 100% no-repeat;
}
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell) > * { position: relative; z-index: 1; width: 100%; }
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell) :is(.container, .row, [class*="col-"], .oy-hero-inner, .kp-ilce-hero-inner) {
    padding-top: 0 !important; padding-bottom: 0 !important; margin-top: 0 !important; margin-bottom: 0 !important; min-height: 0 !important;
}
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell) :is(.py-5, .py-4, .pt-lg-5, .mt-lg-5, .pt-lg-3, .mt-lg-3, .pb-lg-5) {
    padding-top: 0 !important; padding-bottom: 0 !important; margin-top: 0 !important;
}
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell):not(.kpy-a):not(.kpy-b) :is(h1, h2, .h1, .display-3, .display-4, .display-5, .kp-hero-title) {
    font-family: var(--serif) !important; font-size: clamp(2rem, 4.2vw, 3.3rem) !important; font-weight: 700 !important;
    line-height: 1.12 !important; letter-spacing: .5px !important; color: #fff !important; margin: 0 auto !important;
    text-shadow: 0 8px 30px rgba(0, 0, 0, .35) !important; animation: none !important;
}
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell) :is(h1, .kp-hero-title)::after {
    content: ''; display: block; width: 64px; height: 2px; margin: 16px auto 0; background: var(--gold-grad); border-radius: 2px;
}
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell) :is(p, .lead) {
    color: rgba(255, 255, 255, .82) !important; font-size: 1rem !important; max-width: 640px; margin: 14px auto 0 !important;
}
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell) nav.d-none { display: block !important; }
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell):not(.kpy-a) .breadcrumb {
    display: inline-flex !important; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px 10px;
    margin: 18px auto 0 !important; padding: 8px 18px !important; border-radius: 999px !important;
    background: rgba(255, 255, 255, .08) !important; border: 1px solid rgba(233, 211, 154, .22) !important;
    backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
    font-size: .8rem !important; font-weight: 600; text-transform: none !important; max-width: calc(100% - 16px);
}
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell) .breadcrumb-item,
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell) .breadcrumb-item a { color: rgba(255, 255, 255, .86) !important; text-decoration: none !important; }
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell) .breadcrumb-item a:hover { color: var(--gold-2) !important; }
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell) .breadcrumb-item.active { color: var(--gold-2) !important; }
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell) .breadcrumb-item + .breadcrumb-item { padding-left: 0 !important; }
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell) .breadcrumb-item + .breadcrumb-item::before {
    content: '\203A' !important; color: var(--gold) !important; padding-right: 10px !important; float: none !important;
}
html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell) :is(.btn, .badge) { position: relative; }

/* ---------- Renk & bileşen uyumu ---------- */
:where(body.kpy-eski) a:not(:where(.kpy *)) { color: var(--g-600); }
:where(body.kpy-eski) a:not(:where(.kpy *)):hover { color: var(--gold-3); }
body.kpy-eski .text-primary { color: var(--g-600) !important; }
body.kpy-eski .bg-primary:not(.hero-header) { background-color: var(--g-600) !important; }
body.kpy-eski .border-primary { border-color: var(--g-500) !important; }
body.kpy-eski .text-secondary { color: var(--gold-3) !important; }
body.kpy-eski .bg-dark { background-color: var(--g-900) !important; }
body.kpy-eski .text-dark { color: var(--ink) !important; }

body.kpy-eski .btn { border-radius: 999px; font-weight: 700; letter-spacing: .2px; transition: all .25s ease; }
body.kpy-eski .btn.rounded-0 { border-radius: 0; }
body.kpy-eski .btn-primary, body.kpy-eski .btn-success {
    background: linear-gradient(135deg, var(--g-500), var(--g-800)) !important; border-color: transparent !important; color: #fff !important;
    box-shadow: 0 8px 20px rgba(10, 51, 38, .2) !important;
}
body.kpy-eski .btn-primary:hover, body.kpy-eski .btn-success:hover,
body.kpy-eski .btn-primary:focus, body.kpy-eski .btn-success:focus { background: var(--gold-grad) !important; color: var(--g-900) !important; transform: translateY(-1px); }
body.kpy-eski .btn-secondary, body.kpy-eski .btn-warning { background: var(--gold-grad) !important; border-color: transparent !important; color: var(--g-900) !important; }
body.kpy-eski .btn-outline-primary, body.kpy-eski .btn-outline-success { color: var(--g-600) !important; border-color: rgba(27, 122, 87, .45) !important; background: transparent !important; }
body.kpy-eski .btn-outline-primary:hover, body.kpy-eski .btn-outline-success:hover,
body.kpy-eski .btn-outline-primary.active, body.kpy-eski .btn-outline-success.active { background: linear-gradient(135deg, var(--g-500), var(--g-800)) !important; color: #fff !important; border-color: transparent !important; }
body.kpy-eski .btn-light { background: #fff; border-color: var(--line); color: var(--g-700); }
body.kpy-eski .btn-check:checked + .btn-outline-primary,
body.kpy-eski .btn-check:checked + .btn-outline-success { background: linear-gradient(135deg, var(--g-500), var(--g-800)) !important; color: #fff !important; }

body.kpy-eski .card { border-radius: var(--radius) !important; border: 1px solid var(--line) !important; background: #fff !important; box-shadow: var(--shadow) !important; backdrop-filter: none !important; -webkit-backdrop-filter: none !important; }
body.kpy-eski .card:hover { border-color: rgba(201, 165, 90, .45) !important; }
body.kpy-eski .card-header, body.kpy-eski .card-footer { background: var(--silk) !important; border-color: var(--line) !important; }
body.kpy-eski .card-header.bg-primary, body.kpy-eski .card-header.bg-success { background: linear-gradient(135deg, var(--g-600), var(--g-800)) !important; color: #fff; }
body.kpy-eski .bg-white:not(#spinner), body.kpy-eski .bg-light { background: #fff !important; backdrop-filter: none !important; -webkit-backdrop-filter: none !important; }

body.kpy-eski .form-control, body.kpy-eski .form-select {
    background: #fff !important; border: 1px solid var(--line) !important; border-radius: 12px !important; color: var(--ink);
    backdrop-filter: none !important; -webkit-backdrop-filter: none !important;
}
body.kpy-eski .form-control:focus, body.kpy-eski .form-select:focus { border-color: var(--gold) !important; box-shadow: 0 0 0 3px rgba(201, 165, 90, .2) !important; }
body.kpy-eski .form-check-input:checked { background-color: var(--g-600); border-color: var(--g-600); }
body.kpy-eski .form-check-input:focus { box-shadow: 0 0 0 3px rgba(201, 165, 90, .2); border-color: var(--gold); }
body.kpy-eski .input-group-text { background: var(--silk) !important; border-color: var(--line) !important; color: var(--g-700); }
body.kpy-eski .form-label { font-weight: 700; color: var(--g-800); font-size: .9rem; }

body.kpy-eski .badge.bg-primary, body.kpy-eski .badge.bg-success { background: linear-gradient(135deg, var(--g-500), var(--g-700)) !important; }
body.kpy-eski .badge.bg-warning, body.kpy-eski .badge.bg-secondary { background: var(--gold-grad) !important; color: var(--g-900) !important; }
body.kpy-eski .badge.bg-light { color: var(--g-700) !important; border: 1px solid var(--line); }

body.kpy-eski .pagination { gap: 4px; }
body.kpy-eski .pagination .page-link { border-radius: 999px !important; border: 1px solid var(--line) !important; color: var(--g-700); background: #fff; min-width: 40px; text-align: center; font-weight: 700; }
body.kpy-eski .pagination .page-link:hover { background: var(--silk); color: var(--g-800); }
body.kpy-eski .pagination .page-item.active .page-link { background: linear-gradient(135deg, var(--g-500), var(--g-800)) !important; color: #fff !important; border-color: transparent !important; }

body.kpy-eski .nav-pills .nav-link { border-radius: 999px; color: var(--g-700); font-weight: 700; }
body.kpy-eski .nav-pills .nav-link.active, body.kpy-eski .nav-pills .show > .nav-link { background: linear-gradient(135deg, var(--g-600), var(--g-800)); color: var(--gold-2); }
body.kpy-eski .nav-tabs { border-bottom: 1px solid var(--line); }
body.kpy-eski .nav-tabs .nav-link { color: var(--muted); font-weight: 700; border: 0 !important; border-bottom: 2px solid transparent !important; background: transparent !important; border-radius: 0 !important; }
body.kpy-eski .nav-tabs .nav-link.active { color: var(--g-800); border-bottom-color: var(--gold) !important; }
body.kpy-eski .tab-content { background: transparent; border: 0; padding: 1rem 0; backdrop-filter: none; -webkit-backdrop-filter: none; }

body.kpy-eski .list-group-item { border-color: var(--line) !important; background: #fff; }
body.kpy-eski .list-group-item.active { background: linear-gradient(135deg, var(--g-600), var(--g-800)); border-color: transparent !important; }
body.kpy-eski .table-responsive { background: #fff; border-color: var(--line); backdrop-filter: none; -webkit-backdrop-filter: none; }
body.kpy-eski .table > thead { color: var(--g-800); }
body.kpy-eski .progress-bar { background: linear-gradient(90deg, var(--g-500), var(--gold)); }
body.kpy-eski .alert { border-radius: 14px; backdrop-filter: none; -webkit-backdrop-filter: none; }
body.kpy-eski .modal-content { background: #fff !important; border-radius: var(--radius) !important; border: 1px solid var(--line) !important; backdrop-filter: none !important; -webkit-backdrop-filter: none !important; }
body.kpy-eski .modal-header { border-bottom-color: var(--line); }
body.kpy-eski .modal-title { font-family: var(--serif); color: var(--g-800); }
body.kpy-eski .dropdown-menu:not(.kpy-dropdown) { background: #fff !important; border: 1px solid var(--line) !important; border-radius: 14px !important; backdrop-filter: none !important; -webkit-backdrop-filter: none !important; }
body.kpy-eski .dropdown-item.active, body.kpy-eski .dropdown-item:active { background: var(--g-600); }
body.kpy-eski .section-title { color: var(--gold-3) !important; font-family: 'Manrope', sans-serif; letter-spacing: 3px; }
body.kpy-eski .section-title::before, body.kpy-eski .section-title::after { background: var(--gold) !important; }
body.kpy-eski .kp-btn-cta { background: var(--gold-grad) !important; color: var(--g-900) !important; }
body.kpy-eski .back-to-top { display: none !important; }
body.kpy-eski #spinner.bg-white { background: rgba(248, 244, 234, .92) !important; }
body.kpy-eski #spinner .spinner-border { color: var(--g-500) !important; }

/* ---------- Tablet / mobil ---------- */
@media (max-width: 991.98px) {
    html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell):not(.kpy-a):not(.kpy-b):not(.kpy-c) { padding: calc(var(--kpy-head-h) + 36px) 1rem 92px !important; }
}
@media (max-width: 767.98px) {
    body.kpy-eski { --kpy-head-h: 66px; }
    html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell):not(.kpy-a):not(.kpy-b):not(.kpy-c) { padding: calc(var(--kpy-head-h) + 34px) 14px 64px !important; margin-bottom: 1.75rem !important; }
    html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell)::after { height: 44px; }
    html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell):not(.kpy-a):not(.kpy-b) :is(h1, h2, .h1, .display-3, .display-4, .display-5, .kp-hero-title) { font-size: clamp(1.55rem, 7vw, 2.1rem) !important; }
    html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell) :is(p, .lead) { font-size: .9rem !important; }
    html body.kpy-eski.kp-site .hero-header:not(.kp-hero-shell):not(.kpy-a) .breadcrumb { font-size: .72rem !important; padding: 6px 14px !important; }
    body.kpy-eski .kpy-header .kpy-container,
    body.kpy-eski .kpy-footer .kpy-container,
    body.kpy-eski .kpy-pagehead .kpy-container { padding-left: 16px !important; padding-right: 16px !important; }
    body.kpy-eski .btn { white-space: normal; }
}
