/* =================================================================
   İK PORTALI GLOBAL PREMIUM STANDARTLARI (CORE & FORMS)
================================================================= */

/* --- YEREL FONTLAR (DIŞA BAĞIMLILIK OLMADAN HIZLI VE GÜVENLİ YÜKLEME) --- */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 300;
    font-display: swap;
    src: url('../fonts/inter-v20-latin_latin-ext-300.woff2') format('woff2');
}

@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/inter-v20-latin_latin-ext-regular.woff2') format('woff2');
}

@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url('../fonts/inter-v20-latin_latin-ext-500.woff2') format('woff2');
}

@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url('../fonts/inter-v20-latin_latin-ext-600.woff2') format('woff2');
}

@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url('../fonts/inter-v20-latin_latin-ext-700.woff2') format('woff2');
}

:root {
    /* Marka Renkleri */
    --brand-red: #9e0b0f;
    --brand-red-hover: #7d090c;
    --brand-red-light: #f9e7e7;
    --brand-red-shadow: rgba(158, 11, 15, 0.15);
    /* Başarı (Success) Renkleri */
    --brand-success: #16a34a;
    --brand-success-hover: #15803d;
    --brand-success-bg: #e6f4ea;
    --brand-success-shadow: rgba(22, 163, 74, 0.2);
    /* Arka Plan ve Yüzey Renkleri */
    --bg-white: #ffffff;
    --bg-light-gray: #f8fafc;
    --bg-light: #f8fafc;
    --bg-readonly: #f1f5f9;
    --sidebar-bg: #ffffff;
    /* Metin (Tipografi) Renkleri */
    --text-dark: #0f172a;
    --text-main: #334155;
    --text-label: #475569;
    --text-muted: #64748b;
    /* Çizgi ve Kenarlık (Border) Renkleri */
    --border-soft: #e2e8f0;
    --border-color: #e2e8f0;
    --border-input: #cbd5e1;
    --border-hover: #94a3b8;
    --focus-border: #475569;
    /* Gölgeler (Shadows) */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.05), 0 4px 6px -2px rgba(0, 0, 0, 0.025);
    --shadow-premium: 0 1px 2px rgba(15, 23, 42, 0.05), 0 3px 6px rgba(15, 23, 42, 0.04), 0 10px 15px rgba(15, 23, 42, 0.03), 0 20px 30px rgba(15, 23, 42, 0.02);
}

/* =================================================================
   TİPOGRAFİ, SIFIRLAMA VE GLOBAL AYARLAR
================================================================= */
body,
html {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background-color: var(--bg-light-gray);
    color: var(--text-main);
    transition: background-color 0.5s ease-in-out, color 0.5s ease-in-out;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    scroll-behavior: smooth;
    margin: 0;
    padding: 0;
    height: 100%;
}

h1,
h2,
h3,
h4,
.header-title-wrapper h4 {
    letter-spacing: -0.02em;
    text-wrap: balance;
    line-height: 1.2;
}

.premium-label,
.text-muted {
    letter-spacing: 0.03em;
}

::selection {
    background-color: var(--brand-red-light);
    color: var(--brand-red);
}

a:focus-visible,
button:focus-visible,
.user-profile-toggle:focus-visible {
    outline: 2px solid var(--brand-red);
    outline-offset: 3px;
    box-shadow: 0 0 0 5px var(--brand-red-shadow);
    border-radius: inherit;
}

/* =================================================================
   GLOBAL SCROLLBAR & ANİMASYONLAR
================================================================= */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background-color: rgba(100, 116, 139, 0.25);
    border-radius: 10px;
    border: 2px solid var(--bg-light-gray);
}

    ::-webkit-scrollbar-thumb:hover {
        background-color: rgba(100, 116, 139, 0.5);
    }

@keyframes smoothEntrance {
    0% {
        opacity: 0;
        transform: translateY(15px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes shimmer-shine {
    0% {
        left: -100%;
    }

    100% {
        left: 200%;
    }
}

input[type="checkbox"].checkbox-premium {
    appearance: none;
    -webkit-appearance: none;
    width: 22px;
    height: 22px;
    border: 2px solid var(--border-input);
    border-radius: 6px;
    background-color: var(--bg-white);
    cursor: pointer;
    position: relative;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: middle;
    margin: 0;
}

    input[type="checkbox"].checkbox-premium:hover {
        border-color: var(--brand-red);
        background-color: var(--brand-red-light);
    }

    input[type="checkbox"].checkbox-premium:checked {
        background-color: var(--brand-red);
        border-color: var(--brand-red);
        animation: checkbox-pop 0.3s ease;
    }

    input[type="checkbox"].checkbox-premium:focus-visible {
        box-shadow: 0 0 0 3px var(--brand-red-shadow);
        outline: 2px solid var(--brand-red);
        outline-offset: 2px;
    }

    input[type="checkbox"].checkbox-premium::after {
        content: '';
        width: 6px;
        height: 12px;
        border: solid white;
        border-width: 0 2.5px 2.5px 0;
        transform: rotate(45deg) scale(0);
        position: absolute;
        top: 2px;
        transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    }

    input[type="checkbox"].checkbox-premium:checked::after {
        transform: rotate(45deg) scale(1);
    }

@keyframes checkbox-pop {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(0.9);
    }

    100% {
        transform: scale(1);
    }
}
/* =================================================================
   SWEETALERT2 PREMIUM MODAL (DOĞRULAMA POP-UP) TASARIMI
================================================================= */
.swal-premium-popup {
    border-radius: 24px !important;
    border: 1px solid rgba(226, 232, 240, 0.6) !important;
    box-shadow: var(--shadow-premium) !important;
    padding: 3rem 2rem 2.5rem !important;
    position: relative !important;
    overflow: hidden !important; /* Üstteki kırmızı çizginin köşelerden taşmasını kesinlikle engeller */
    box-sizing: border-box !important;
}

    /* Form-Card'daki o meşhur üst kırmızı ışık şeridi */
    .swal-premium-popup::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%; /* right:0 yerine width:100% taşmayı engeller */
        height: 6px;
        background: linear-gradient(90deg, var(--brand-red), #cf151a, var(--brand-red));
        z-index: 10;
    }

/* Butonları Taşırmadan Eşit Genişlikte Yan Yana Zorlama */
.swal-premium-actions {
    display: flex !important;
    flex-wrap: nowrap !important;
    gap: 16px !important;
    width: 100% !important;
    margin: 2rem 0 0 0 !important; /* SweetAlert'in sağa iten margin'ini sıfırlar! */
    padding: 0 !important;
    box-sizing: border-box !important;
}

    .swal-premium-actions .btn {
        flex: 1 !important;
        margin: 0 !important;
        height: 48px !important;
        font-size: 1rem !important;
    }

/* Doğrulama Input Alanının Lüks Tasarımı (Global Standartlara Geri Döndürüldü) */
.swal-premium-input {
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 1.5rem 0 0 0 !important;
    height: 64px !important;
    border-radius: 8px !important; /* Diğer inputlarınla aynı ovallik */
    border: 1px solid var(--border-input) !important; /* Diğer inputlar gibi 1px sınır */
    background-color: var(--bg-white) !important;
    font-size: 1.75rem !important;
    font-weight: 800 !important;
    letter-spacing: 12px !important; /* O güzel boşluklu hissiyat korundu */
    text-align: center !important;
    color: var(--text-dark) !important; /* Kırmızı silindi, standart koyu metin geldi */
    transition: all 0.15s ease-in-out !important;
    padding: 0 1rem !important;
}

    /* Üzerine gelindiğinde (Hover) diğer inputlarınla aynı davranır */
    .swal-premium-input:hover {
        border-color: var(--border-hover) !important;
    }

    /* Tıklandığında (Focus) Kırmızı yerine senin belirlediğin Antrasit/Lacivert yanar */
    .swal-premium-input:focus {
        background-color: var(--bg-white) !important;
        border-color: var(--focus-border) !important;
        box-shadow: 0 0 0 1px var(--focus-border) !important; /* O sinsi kırmızı gölge silindi */
        outline: none !important;
    }

    /* Placeholder ayarı korundu */
    .swal-premium-input::placeholder {
        letter-spacing: 4px !important;
        font-weight: 500 !important;
        font-size: 1.15rem !important;
        color: var(--text-muted) !important;
    }
/* =================================================================
   İKON ANİMASYONLARI (NEFES ALMA VE GÜVENLİK KALKANI EFEKTİ)
================================================================= */
.swal-premium-popup .header-icon-box {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    cursor: default; /* Kullanıcı üzerine gelindiğini hissetsin diye */
}

    /* Pop-up İçindeki İkonun Üzerine Gelince */
    .swal-premium-popup .header-icon-box:hover {
        animation: float-breathe 2.5s ease-in-out infinite !important;
        background-color: var(--brand-red) !important;
        color: var(--bg-white) !important;
        box-shadow: 0 10px 20px -5px var(--brand-red-shadow) !important;
    }

/* Formların sol üst köşesindeki ikonların üzerine gelince (Senin eklemek istediğin özellik) */
.header-icon-box:hover {
    animation: float-breathe 2.5s ease-in-out infinite !important;
}
/* =================================================================
   FORM BİLEŞENLERİ (KARTLAR, İNPUTLAR)
================================================================= */
#page-content-wrapper > .container-fluid {
    animation: smoothEntrance 0.7s cubic-bezier(0.4, 0, 0.2, 1) backwards;
}

.form-card {
    background: var(--bg-white);
    border-radius: 24px;
    border: 1px solid rgba(226, 232, 240, 0.6);
    padding: 40px;
    margin-bottom: 30px;
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-premium);
    animation: smoothEntrance 0.7s cubic-bezier(0.4, 0, 0.2, 1) backwards;
}

    .form-card:nth-child(1) {
        animation-delay: 0.1s;
    }

    .form-card:nth-child(2) {
        animation-delay: 0.2s;
    }

    .form-card:nth-child(3) {
        animation-delay: 0.3s;
    }

    .form-card::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 5px;
        background: linear-gradient(90deg, var(--brand-red), #cf151a, var(--brand-red));
        opacity: 0.95;
    }

.form-card-header {
    margin-bottom: 32px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border-soft);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.header-title-wrapper {
    display: flex;
    align-items: center;
    gap: 16px;
}

.header-icon-box {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 48px;
    width: 48px;
    height: 48px;
    background-color: var(--brand-red-shadow);
    color: var(--brand-red);
    border-radius: 12px;
    font-size: 1.35rem;
}

.header-title-wrapper h4 {
    margin: 0;
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--text-dark);
    letter-spacing: -0.015em;
}

.header-title-wrapper p {
    margin: 4px 0 0 0;
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 500;
}

.btn-back {
    background-color: var(--bg-white);
    border: 1px solid var(--border-input);
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.85rem;
    border-radius: 10px;
    padding: 0 16px;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    height: 42px;
    white-space: nowrap;
    flex-shrink: 0;
}

    .btn-back:hover {
        background-color: var(--bg-readonly);
        color: var(--text-dark);
        border-color: var(--border-hover);
        text-decoration: none;
        transform: translateY(-1px);
    }

.premium-label {
    font-weight: 600;
    font-size: 0.8rem;
    color: var(--text-label);
    margin-bottom: 8px;
    display: block;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.input-icon-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
}

    .input-icon-wrapper .fa-left {
        position: absolute;
        left: 14px;
        color: var(--text-muted);
        font-size: 1rem;
        transition: all 0.2s ease;
        pointer-events: none;
    }

    .input-icon-wrapper .form-control.has-left-icon {
        padding-left: 40px !important;
    }

.password-toggle {
    position: absolute;
    right: 14px;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 1rem;
    padding: 5px;
    transition: color 0.2s;
    z-index: 5;
}

    .password-toggle:hover {
        color: var(--text-dark);
    }

.form-control {
    background-color: var(--bg-white);
    border-radius: 8px !important;
    padding: 10px 14px;
    border: 1px solid var(--border-input);
    font-size: 0.9rem;
    color: var(--text-main);
    font-weight: 500;
    transition: all 0.15s ease-in-out;
    height: 42px;
    width: 100%;
}

    .form-control:hover:not([readonly]):not([disabled]) {
        border-color: var(--border-hover);
    }

    .form-control:focus {
        border-color: var(--focus-border) !important;
        box-shadow: 0 0 0 1px var(--focus-border) !important;
        outline: none !important;
        background-color: var(--bg-white) !important;
    }

        .input-icon-wrapper .form-control:focus + .fa-left,
        .form-control:focus ~ .fa-left {
            color: var(--focus-border);
        }

    .form-control[readonly],
    .form-control[disabled] {
        background-color: var(--bg-readonly) !important;
        color: var(--text-muted) !important;
        border-color: var(--border-soft);
        cursor: not-allowed !important;
        opacity: 1;
    }

@keyframes checkbox-pop {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(0.9);
    }

    100% {
        transform: scale(1);
    }
}

/* =================================================================
   BUTONLAR & AKSİYONLAR (TOP %1 UX KURALLARI UYGULANDI)
================================================================= */
.action-footer {
    display: flex;
    justify-content: flex-end;
    margin-top: 16px;
    gap: 12px;
}

/* YEŞİL BUTONLAR (KAYDET, ONAYLA, GÖNDER) - UX Evrensel Kuralı */
.btn-submit,
.btn-primary,
.btn-success-custom {
    background-color: var(--brand-success);
    border: none !important;
    color: var(--bg-white) !important;
    height: 44px;
    border-radius: 8px !important;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 4px 6px -1px var(--brand-success-shadow);
    padding: 0 24px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

/* KIRMIZI BUTONLAR (SİL, İPTAL, VAZGEÇ) - Kurumsal Marka Rengi */
.btn-danger,
.btn-cancel,
.btn-delete {
    background-color: var(--brand-red);
    border: none !important;
    color: var(--bg-white) !important;
    height: 44px;
    border-radius: 8px !important;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 4px 6px -1px var(--brand-red-shadow);
    padding: 0 24px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

/* Sorgulama ve Arama Butonları İçin */
.btn-search {
    background-color: var(--text-dark);
    /* Koyu Antrasit/Lacivert */
    border: none !important;
    color: var(--bg-white) !important;
    height: 44px;
    border-radius: 8px !important;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.2s ease !important;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 4px 6px -1px rgba(15, 23, 42, 0.2);
    padding: 0 24px;
    cursor: pointer;
}

    .btn-search:hover {
        background-color: var(--text-label);
        transform: translateY(-1px);
    }

    .btn-search:active {
        transform: scale(0.96);
    }

/* Ortak Shimmer Efekti (Işık Yansıması) - Sadece Hover Durumunda */
.btn-submit::after,
.btn-primary::after,
.btn-success-custom::after,
.btn-danger::after,
.btn-cancel::after,
.btn-delete::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.2) 50%, rgba(255, 255, 255, 0) 100%);
    transform: skewX(-25deg);
}

.btn-submit:hover:not([disabled])::after,
.btn-primary:hover:not([disabled])::after,
.btn-success-custom:hover:not([disabled])::after,
.btn-danger:hover:not([disabled])::after,
.btn-cancel:hover:not([disabled])::after,
.btn-delete:hover:not([disabled])::after {
    animation: shimmer-shine 0.8s ease-in-out;
}

/* Hover Renk ve Gölge Geçişleri */
.btn-submit:hover:not([disabled]),
.btn-primary:hover:not([disabled]),
.btn-success-custom:hover:not([disabled]) {
    background-color: var(--brand-success-hover);
    transform: translateY(-1px);
    box-shadow: 0 6px 12px -2px rgba(22, 163, 74, 0.3);
}

.btn-danger:hover:not([disabled]),
.btn-cancel:hover:not([disabled]),
.btn-delete:hover:not([disabled]) {
    background-color: var(--brand-red-hover);
    transform: translateY(-1px);
    box-shadow: 0 6px 12px -2px rgba(158, 11, 15, 0.3);
}

/* Disabled (Tıklanamaz) Durumlar */
.btn-submit[disabled],
.btn-primary[disabled],
.btn-success-custom[disabled],
.btn-danger[disabled],
.btn-cancel[disabled],
.btn-delete[disabled] {
    background-color: var(--border-soft) !important;
    color: var(--text-muted) !important;
    box-shadow: none !important;
    cursor: not-allowed !important;
}

/* Tıklama (Press) Yaylanma Animasyonları */
.btn-submit:active:not([disabled]),
.btn-primary:active:not([disabled]),
.btn-success-custom:active:not([disabled]),
.btn-danger:active:not([disabled]),
.btn-cancel:active:not([disabled]),
.btn-delete:active:not([disabled]),
.btn-back:active {
    transform: scale(0.96) translateY(0) !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
    transition: transform 0.1s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

/* Tıklama (Press) Yaylanma Animasyonları VE Arka Plan Sabitleme */
.btn-submit:active:not([disabled]),
.btn-primary:active:not([disabled]),
.btn-success-custom:active:not([disabled]) {
    background-color: var(--brand-success-hover) !important;
    /* Bootstrap Mavisini Ezer */
    border-color: var(--brand-success-hover) !important;
    transform: scale(0.96) translateY(0) !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
    transition: transform 0.1s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.btn-danger:active:not([disabled]),
.btn-cancel:active:not([disabled]),
.btn-delete:active:not([disabled]) {
    background-color: var(--brand-red-hover) !important;
    /* Bootstrap Mavisini Ezer */
    border-color: var(--brand-red-hover) !important;
    transform: scale(0.96) translateY(0) !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
    transition: transform 0.1s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.btn-search:active:not([disabled]) {
    background-color: var(--text-label) !important;
    transform: scale(0.96) translateY(0) !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
}

.btn-back:active {
    background-color: var(--border-soft) !important;
    transform: scale(0.96) translateY(0) !important;
}

/* =================================================================
   BOOTSTRAP MAVİ TIKLAMA (FOCUS) ÇAKIŞMASINI TAMAMEN ÇÖZME
================================================================= */
.btn:focus,
.btn:active:focus,
.btn.focus,
.btn:active.focus {
    outline: none !important;
    box-shadow: none !important;
    /* İŞTE O SİNSİ MAVİ ÇERÇEVEYİ YOK EDEN KOD BURASI */
}

/* Butonlara tıklandığında Mavi yerine Kendi Marka Renginde Şık Bir Hale (Gölge) Veriyoruz */
.btn-submit:focus:not(:active),
.btn-primary:focus:not(:active),
.btn-success-custom:focus:not(:active) {
    box-shadow: 0 0 0 3px var(--brand-success-shadow) !important;
}

.btn-danger:focus:not(:active),
.btn-cancel:focus:not(:active),
.btn-delete:focus:not(:active) {
    box-shadow: 0 0 0 3px var(--brand-red-shadow) !important;
}

.btn-search:focus:not(:active) {
    box-shadow: 0 0 0 3px rgba(15, 23, 42, 0.15) !important;
}

.btn-back:focus:not(:active) {
    box-shadow: none !important;
}

/* Avans ve Utility Sınıfları */
.premium-info-section {
    background-color: var(--bg-light-gray);
    border: 1px solid var(--border-soft);
    border-radius: 14px;
    padding: 24px;
    margin-top: 40px;
}

.premium-section-icon {
    background: var(--brand-success-bg);
    padding: 12px;
    border-radius: 10px;
    color: var(--brand-success);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
}

.balance-input {
    background-color: #f0fdf4 !important;
    border: 1px solid #22c55e !important;
    color: #166534 !important;
    font-size: 1.1rem !important;
    font-weight: 700;
}

.error-class {
    color: var(--brand-red);
    font-size: 0.8rem;
    font-weight: 600;
    margin-top: 6px;
    display: block;
}

.alert-success-premium {
    background-color: #f0fdf4 !important;
    color: var(--brand-success);
    border: 0;
    border-radius: 8px;
    padding: 1rem;
    font-weight: 600;
}

.badge-premium-success {
    background-color: var(--brand-success) !important;
    color: var(--bg-white) !important;
    font-weight: 500;
}

.badge-premium-danger {
    background-color: var(--brand-red) !important;
    color: var(--bg-white) !important;
    font-weight: 500;
}

.required-marker {
    color: var(--brand-red);
    font-size: 20px;
    margin: 0 5px;
}

.file-requirements {
    color: var(--brand-red);
    font-size: 0.8rem;
    margin-top: 10px;
}

.hr-dashed {
    border-top: 1px dashed var(--border-input);
    margin-bottom: 24px;
    margin-top: 24px;
}

.letter-space-2 {
    letter-spacing: 2px;
}

.btn-outline-input {
    border-color: var(--border-input) !important;
    color: var(--text-label) !important;
}

.bg-consent {
    background-color: var(--bg-readonly) !important;
}

.border-dashed-card {
    border: 2px dashed var(--border-hover);
    background-color: var(--bg-readonly);
}

.btn-dashed {
    border: 1px dashed var(--border-hover) !important;
}

.rounded-right-8 {
    border-top-right-radius: 8px !important;
    border-bottom-right-radius: 8px !important;
}

.rounded-left-0 {
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
}

.img-preview-md {
    max-width: 250px;
    max-height: 250px;
    object-fit: cover;
}

.addon-premium {
    background-color: var(--bg-readonly) !important;
    border-color: var(--border-input) !important;
    color: var(--text-muted) !important;
    border-top-left-radius: 8px !important;
    border-bottom-left-radius: 8px !important;
}

.max-w-250 {
    max-width: 250px !important;
}

.min-h-20 {
    min-height: 20px !important;
}

.text-success-premium {
    color: var(--brand-success) !important;
}

/* Mobil Sınırlamaları */
@media (max-width: 768px) {
    .form-card {
        padding: 24px 16px;
        border-radius: 16px;
    }

    .form-card-header {
        flex-direction: column;
        align-items: flex-start !important;
        gap: 16px;
        margin-bottom: 24px;
    }

    .header-icon-box {
        min-width: 42px;
        width: 44px;
        height: 42px;
        font-size: 1.15rem;
    }

    .header-title-wrapper h4 {
        font-size: 1.15rem;
    }

    .btn-back {
        width: 100%;
        height: 48px;
    }

    .form-control {
        height: 48px;
        font-size: 0.95rem;
    }

    .action-footer {
        justify-content: center;
        width: 100%;
    }

    .btn-submit,
    .btn-primary,
    .btn-success-custom,
    .btn-danger,
    .btn-cancel,
    .btn-delete {
        width: 100%;
        height: 48px;
        font-size: 0.95rem !important;
    }

    .premium-info-section {
        padding: 20px 14px;
        margin-top: 32px;
    }
}

/* =================================================================
   DARK MODE (TÜM SİTE, GİRİŞ VE FORMLAR İÇİN)
================================================================= */
[data-theme="dark"] {
    color-scheme: dark;
    --bg-light-gray: #09090b;
    --bg-light: #09090b;
    --bg-white: #18181b;
    --bg-readonly: #27272a;
    --sidebar-bg: #050505;
    --text-dark: #ffffff;
    --text-main: #e4e4e7;
    --text-label: #a1a1aa;
    --text-muted: #71717a;
    --border-soft: #27272a;
    --border-color: #27272a;
    --border-input: #3f3f46;
    --border-hover: #52525b;
    --focus-border: #a1a1aa;
    --brand-red-light: rgba(158, 11, 15, 0.15);
}

    [data-theme="dark"] body {
        background-color: var(--bg-light-gray) !important;
        color: var(--text-main) !important;
    }

    [data-theme="dark"] ::selection {
        background-color: rgba(158, 11, 15, 0.4);
        color: #ffffff;
    }

    [data-theme="dark"] ::-webkit-scrollbar-track {
        background: var(--bg-light-gray);
    }

    [data-theme="dark"] ::-webkit-scrollbar-thumb {
        background: var(--border-hover);
        border-radius: 5px;
    }

        [data-theme="dark"] ::-webkit-scrollbar-thumb:hover {
            background: var(--text-muted);
        }

    [data-theme="dark"] .bg-white {
        background-color: var(--bg-white) !important;
    }

    [data-theme="dark"] .text-dark {
        color: var(--text-dark) !important;
    }

    [data-theme="dark"] .text-muted {
        color: var(--text-muted) !important;
    }

    [data-theme="dark"] footer {
        background-color: var(--bg-white) !important;
        border-top: 1px solid var(--border-soft) !important;
    }

    [data-theme="dark"] .modal-content {
        background-color: var(--bg-white) !important;
        border-color: var(--border-soft) !important;
    }

    /* Inputlar Dark Mode */
    [data-theme="dark"] .form-control {
        background-color: var(--bg-white) !important;
        color: var(--text-dark) !important;
        border-color: var(--border-input) !important;
    }

        [data-theme="dark"] .form-control:focus {
            background-color: var(--bg-white) !important;
            color: var(--text-dark) !important;
            border-color: var(--focus-border) !important;
            box-shadow: 0 0 0 1px var(--focus-border) !important;
        }

        [data-theme="dark"] .form-control::placeholder {
            color: #94a3b8 !important;
            opacity: 1 !important;
        }

    [data-theme="dark"] input:-webkit-autofill,
    [data-theme="dark"] input:-webkit-autofill:hover,
    [data-theme="dark"] input:-webkit-autofill:focus,
    [data-theme="dark"] input:-webkit-autofill:active {
        -webkit-box-shadow: 0 0 0 30px var(--bg-white) inset !important;
        -webkit-text-fill-color: var(--text-dark) !important;
        transition: background-color 5000s ease-in-out 0s;
    }

    /* =================================================================
   BUTON VE BİLEŞEN DARK MODE UYUMLARI
================================================================= */
    /* Yeşil Butonlar İçin Dark Mod (Zümrüt Yeşili Neon Işıma) */
    [data-theme="dark"] .btn-submit,
    [data-theme="dark"] .btn-primary,
    [data-theme="dark"] .btn-success-custom {
        color: #ffffff !important;
        box-shadow: 0 4px 15px -3px rgba(22, 163, 74, 0.4) !important;
    }

    /* Kırmızı Butonlar İçin Dark Mod (Kurumsal Kırmızı Neon Işıma) */
    [data-theme="dark"] .btn-danger,
    [data-theme="dark"] .btn-cancel,
    [data-theme="dark"] .btn-delete {
        color: #ffffff !important;
        box-shadow: 0 4px 15px -3px rgba(158, 11, 15, 0.4) !important;
    }

    [data-theme="dark"] .btn-back {
        color: var(--text-main) !important;
    }

    [data-theme="dark"] input[type="checkbox"].checkbox-premium {
        background-color: #18181b;
        border-color: #3f3f46;
    }

        [data-theme="dark"] input[type="checkbox"].checkbox-premium:hover {
            border-color: #f87171;
        }

        [data-theme="dark"] input[type="checkbox"].checkbox-premium:checked {
            background-color: var(--brand-red);
            border-color: var(--brand-red);
        }

    [data-theme="dark"] .form-control[readonly],
    [data-theme="dark"] .form-control[disabled] {
        background-color: #0f172a !important;
        color: #64748b !important;
        border-color: #334155 !important;
        cursor: not-allowed !important;
        opacity: 0.75 !important;
        box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2) !important;
    }

        [data-theme="dark"] .form-control[readonly] + .fa-left,
        [data-theme="dark"] .form-control[disabled] + .fa-left,
        [data-theme="dark"] .form-control[readonly] ~ .fa-left,
        [data-theme="dark"] .form-control[disabled] ~ .fa-left {
            color: #64748b !important;
            opacity: 0.75 !important;
        }

    [data-theme="dark"] select.form-control option {
        background-color: var(--bg-white);
        color: var(--text-dark);
    }

    /* Tüm Pasif Butonlar İçin Dark Mod */
    [data-theme="dark"] .btn-submit[disabled],
    [data-theme="dark"] .btn-primary[disabled],
    [data-theme="dark"] .btn-success-custom[disabled],
    [data-theme="dark"] .btn-danger[disabled],
    [data-theme="dark"] .btn-cancel[disabled],
    [data-theme="dark"] .btn-delete[disabled] {
        background-color: #27272a !important;
        color: #71717a !important;
        box-shadow: none !important;
        border: 1px solid #3f3f46 !important;
        cursor: not-allowed !important;
        transform: none !important;
    }

    [data-theme="dark"] .balance-input {
        background-color: rgba(22, 163, 74, 0.1) !important;
        border-color: #15803d !important;
        color: #4ade80 !important;
        box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3) !important;
    }

        [data-theme="dark"] .balance-input ~ .fa-try,
        [data-theme="dark"] .input-icon-wrapper .fa-try.text-success-premium {
            color: #4ade80 !important;
        }

/* Global Modals (Tüm Sistemde Geçerli) */
.modal-backdrop,
.swal2-container.swal2-backdrop-show {
    background: rgba(15, 23, 42, 0.3) !important;
    backdrop-filter: blur(8px) !important;
    -webkit-backdrop-filter: blur(8px) !important;
}

[data-theme="dark"] .swal2-popup {
    background-color: #18181b !important;
    border: 1px solid var(--border-color) !important;
    color: var(--text-dark) !important;
    border-radius: 16px !important;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.9) !important;
}

[data-theme="dark"] .swal2-title {
    color: var(--text-dark) !important;
}

[data-theme="dark"] .swal2-html-container,
[data-theme="dark"] .swal2-content {
    color: var(--text-muted) !important;
}

[data-theme="dark"] .swal2-icon.swal2-success {
    border-color: var(--brand-success) !important;
}

    [data-theme="dark"] .swal2-icon.swal2-success [class^=swal2-success-line] {
        background-color: var(--brand-success) !important;
    }

    [data-theme="dark"] .swal2-icon.swal2-success .swal2-success-ring {
        border-color: rgba(22, 163, 74, 0.3) !important;
    }

[data-theme="dark"] .swal2-icon.swal2-error {
    border-color: var(--brand-red) !important;
}

    [data-theme="dark"] .swal2-icon.swal2-error [class^=swal2-x-mark-line] {
        background-color: var(--brand-red) !important;
    }

[data-theme="dark"] .swal2-icon.swal2-warning {
    border-color: #fbbf24 !important;
    color: #fbbf24 !important;
}

[data-theme="dark"] .swal2-icon.swal2-info {
    border-color: #3b82f6 !important;
    color: #3b82f6 !important;
}

[data-theme="dark"] .modal-backdrop,
[data-theme="dark"] .swal2-container.swal2-backdrop-show {
    background: rgba(0, 0, 0, 0.5) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
}

[data-theme="dark"] .form-card {
    /* Mevcut dark mode gölgesini ezip yerine, arkadan sızan geniş bir kırmızı neon aura ekleriz */
    box-shadow: 0 0 50px -15px rgba(158, 11, 15, 0.15) !important;
}

    [data-theme="dark"] .form-card:hover {
        /* Fare karta gelince ışık çok hafif canlanır */
        box-shadow: 0 0 60px -10px rgba(158, 11, 15, 0.25) !important;
        transition: box-shadow 0.4s ease;
    }



/* =================================================================
   VALIDATION ERROR STATE (GLOBAL)
================================================================= */
.input-validation-error {
    border: 2px solid var(--brand-red, #dc2626) !important;
}

.input-icon-wrapper:has(.input-validation-error) i {
    color: var(--brand-red, #dc2626) !important;
}

/* =================================================================
   IMAGE UPLOAD COMPONENT & PREVIEWS
================================================================= */
.image-upload-dropzone {
    border: 2px dashed var(--border-color, #cbd5e1);
    border-radius: 12px;
    padding: 24px 16px;
    background: var(--bg-light-gray, #f8fafc);
    text-align: center;
    cursor: pointer;
    transition: all 0.25s ease-in-out;
    position: relative;
    display: block;
    margin-bottom: 0;
    user-select: none;
}

.image-upload-dropzone:hover,
.image-upload-dropzone.drag-over {
    border-color: var(--brand-red, #9e0b0f);
    background: rgba(158, 11, 15, 0.04);
}

.image-upload-dropzone.drag-over {
    transform: scale(1.01);
}

.upload-dropzone-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    pointer-events: none;
}

.upload-dropzone-content * {
    pointer-events: none;
}

.upload-icon-circle {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: rgba(158, 11, 15, 0.1);
    color: var(--brand-red, #9e0b0f);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    transition: transform 0.25s ease;
}

.image-upload-dropzone:hover .upload-icon-circle {
    transform: translateY(-2px);
}

.upload-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.upload-main-text {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-dark, #1e293b);
}

.upload-browse-link {
    color: var(--brand-red, #9e0b0f);
    text-decoration: underline;
    cursor: pointer;
}

.upload-sub-text {
    font-size: 0.8rem;
    color: var(--text-muted, #64748b);
}

/* Önizleme Izgarası */
.image-preview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 12px;
}

.image-preview-card {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    background: var(--bg-white, #ffffff);
    border: 1px solid var(--border-color, #e2e8f0);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    display: flex;
    flex-direction: column;
    transition: transform 0.2s, box-shadow 0.2s;
}

.image-preview-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.image-preview-thumb-wrap {
    width: 100%;
    height: 100px;
    position: relative;
    background: #000;
    overflow: hidden;
}

.image-preview-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.image-preview-info {
    padding: 6px 8px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    background: var(--bg-white, #ffffff);
}

.image-preview-name {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-dark, #1e293b);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.image-preview-size {
    font-size: 0.7rem;
    color: var(--text-muted, #64748b);
}

.btn-remove-image {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: rgba(220, 38, 38, 0.9);
    color: #fff;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
    transition: all 0.2s ease;
    z-index: 2;
}

.btn-remove-image:hover {
    background: #b91c1c;
    transform: scale(1.15);
}

/* =================================================================
   DATATABLE IMAGE THUMBNAIL & GALLERY
================================================================= */
.table-img-container {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    cursor: pointer;
}

.table-img-thumb {
    width: 38px;
    height: 38px;
    border-radius: 8px;
    object-fit: cover;
    border: 1px solid var(--border-color, #e2e8f0);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
    transition: transform 0.2s, box-shadow 0.2s;
}

.table-img-container:hover .table-img-thumb {
    transform: scale(1.1);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.table-img-badge {
    background: var(--brand-red, #9e0b0f);
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.table-no-img {
    color: var(--text-muted, #94a3b8);
    font-size: 1rem;
    font-weight: 600;
}

/* Dark Mode Uyumları */
[data-theme="dark"] .image-upload-dropzone {
    background: rgba(255, 255, 255, 0.02);
    border-color: rgba(255, 255, 255, 0.12);
}

[data-theme="dark"] .image-upload-dropzone:hover,
[data-theme="dark"] .image-upload-dropzone.drag-over {
    border-color: #ef4444;
    background: rgba(239, 68, 68, 0.08);
}

[data-theme="dark"] .upload-icon-circle {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
}

[data-theme="dark"] .upload-main-text {
    color: var(--text-dark, #f1f5f9);
}

[data-theme="dark"] .upload-browse-link {
    color: #f87171;
}

[data-theme="dark"] .image-preview-card {
    background: var(--bg-white, #18181b);
    border-color: rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .image-preview-info {
    background: var(--bg-white, #18181b);
}

[data-theme="dark"] .image-preview-name {
    color: var(--text-dark, #f1f5f9);
}

[data-theme="dark"] .table-img-thumb {
    border-color: rgba(255, 255, 255, 0.15);
}

