/* =====================================================
   Sakarya Elektrikçiler Odası — Yönetim Sistemi
   Modern Kurumsal Tema  ·  v2.0
   ===================================================== */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=JetBrains+Mono:wght@500;600&display=swap');

:root {
    /* Layout */
    --eo-sidebar-width: 268px;
    --eo-sidebar-collapsed-width: 76px;
    --eo-topbar-height: 64px;

    /* Brand palette — kurumsal elektrik */
    --eo-brand-navy:   #0b1220;
    --eo-brand-navy-2: #111c30;
    --eo-primary:      #2563eb;
    --eo-primary-dark: #1d4ed8;
    --eo-primary-soft: #eff4ff;
    --eo-accent:       #f59e0b;   /* kıvılcım vurgusu */

    /* Sidebar */
    --eo-sidebar-bg-top:    #0c1628;
    --eo-sidebar-bg-bottom: #0a1322;
    --eo-sidebar-hover:     rgba(255,255,255,0.06);
    --eo-sidebar-text:      #93a4bf;
    --eo-sidebar-text-active: #ffffff;

    /* Status colors */
    --eo-success: #059669;
    --eo-danger:  #dc2626;
    --eo-warning: #d97706;
    --eo-info:    #0891b2;

    /* Surfaces */
    --eo-bg-main:   #eef1f6;
    --eo-bg-grad-1: #eef2f8;
    --eo-bg-grad-2: #e7ecf4;
    --eo-card-bg:   #ffffff;
    --eo-border:    #e4e9f0;
    --eo-border-soft: #eef1f6;
    --eo-text-main:  #0f1b2d;
    --eo-text-mid:   #475569;
    --eo-text-muted: #7a8aa0;

    /* Elevation */
    --eo-shadow-xs: 0 1px 2px rgba(15,27,45,0.05);
    --eo-shadow:    0 1px 3px rgba(15,27,45,0.07), 0 1px 2px rgba(15,27,45,0.04);
    --eo-shadow-md: 0 6px 16px -6px rgba(15,27,45,0.12), 0 2px 6px rgba(15,27,45,0.05);
    --eo-shadow-lg: 0 18px 40px -12px rgba(15,27,45,0.22), 0 6px 14px -8px rgba(15,27,45,0.12);
    --eo-ring: 0 0 0 4px rgba(37,99,235,0.13);

    --eo-radius:    14px;
    --eo-radius-sm: 9px;
    --eo-radius-lg: 20px;
    --eo-transition: all .22s cubic-bezier(.4,0,.2,1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { -webkit-text-size-adjust: 100%; }

body {
    font-family: 'Plus Jakarta Sans', system-ui, -apple-system, "Segoe UI", sans-serif;
    background:
        radial-gradient(1200px 600px at 100% -10%, rgba(37,99,235,0.06), transparent 60%),
        linear-gradient(180deg, var(--eo-bg-grad-1), var(--eo-bg-grad-2));
    background-attachment: fixed;
    color: var(--eo-text-main);
    font-size: 14px;
    line-height: 1.6;
    letter-spacing: -0.01em;
    -webkit-font-smoothing: antialiased;
}

::selection { background: rgba(37,99,235,0.18); }

/* =========================================================
   WRAPPER & LAYOUT
========================================================= */
.wrapper { display: flex; min-height: 100vh; position: relative; }

/* =========================================================
   SIDEBAR
========================================================= */
.sidebar {
    width: var(--eo-sidebar-width);
    height: 100vh;
    background: linear-gradient(185deg, var(--eo-sidebar-bg-top), var(--eo-sidebar-bg-bottom));
    position: fixed;
    top: 0; left: 0;
    z-index: 1000;
    transition: var(--eo-transition);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-right: 1px solid rgba(255,255,255,0.05);
}
/* hairline glow on the right edge */
.sidebar::after {
    content: '';
    position: absolute;
    top: 0; right: 0; bottom: 0;
    width: 1px;
    background: linear-gradient(180deg, transparent, rgba(37,99,235,0.5), transparent);
    opacity: .5;
}

.sidebar.collapsed { width: var(--eo-sidebar-collapsed-width); }

/* Header */
.sidebar-header {
    padding: 18px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: var(--eo-topbar-height);
    border-bottom: 1px solid rgba(255,255,255,0.06);
    flex-shrink: 0;
}

.sidebar-logo { display: flex; align-items: center; gap: 13px; overflow: hidden; }

.logo-icon {
    width: 42px; height: 42px;
    background: linear-gradient(135deg, var(--eo-primary), #4f7bff);
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-size: 19px;
    flex-shrink: 0;
    box-shadow: 0 6px 16px -4px rgba(37,99,235,0.6), inset 0 1px 0 rgba(255,255,255,0.3);
    position: relative;
}
.logo-icon::after {
    content: '';
    position: absolute; inset: 0;
    border-radius: 12px;
    box-shadow: 0 0 0 1px rgba(255,255,255,0.12);
}

.logo-text { display: flex; flex-direction: column; overflow: hidden; transition: var(--eo-transition); }
.logo-title {
    font-size: 15px; font-weight: 800; color: #fff;
    white-space: nowrap; letter-spacing: -0.02em;
}
.logo-subtitle {
    font-size: 11px; color: var(--eo-sidebar-text);
    white-space: nowrap; letter-spacing: .02em;
}

.sidebar-toggle-btn {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.06);
    color: var(--eo-sidebar-text);
    cursor: pointer;
    padding: 8px 9px;
    border-radius: 9px;
    transition: var(--eo-transition);
    flex-shrink: 0;
}
.sidebar-toggle-btn:hover { background: var(--eo-sidebar-hover); color: #fff; }

/* User chip */
.sidebar-user {
    margin: 14px 14px 6px;
    padding: 12px 14px;
    display: flex; align-items: center; gap: 12px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 13px;
    flex-shrink: 0;
    overflow: hidden;
}
.user-avatar i { font-size: 30px; color: #6ea0ff; }
.user-info { overflow: hidden; transition: var(--eo-transition); }
.user-name {
    display: block; font-size: 13.5px; font-weight: 700; color: #fff;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.user-role {
    font-size: 11px; color: var(--eo-sidebar-text); white-space: nowrap;
    text-transform: uppercase; letter-spacing: .06em; font-weight: 600;
}

/* Menu */
.sidebar-menu {
    list-style: none;
    padding: 8px 12px 18px;
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
}
.sidebar-menu::-webkit-scrollbar { width: 5px; }
.sidebar-menu::-webkit-scrollbar-track { background: transparent; }
.sidebar-menu::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.12); border-radius: 4px; }
.sidebar-menu::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.22); }

.menu-label {
    font-size: 10px; font-weight: 700;
    text-transform: uppercase; letter-spacing: .12em;
    color: rgba(147,164,191,0.55);
    padding: 16px 12px 6px;
    white-space: nowrap; overflow: hidden;
    transition: var(--eo-transition);
}

.sidebar-menu li a {
    display: flex; align-items: center; gap: 13px;
    padding: 10px 12px;
    margin: 2px 0;
    color: var(--eo-sidebar-text);
    text-decoration: none;
    transition: var(--eo-transition);
    border-radius: 10px;
    position: relative;
    white-space: nowrap;
    font-weight: 500;
}
.sidebar-menu li a i {
    width: 22px; text-align: center; font-size: 15px; flex-shrink: 0;
    transition: var(--eo-transition);
}
.sidebar-menu li a span { transition: var(--eo-transition); font-size: 13.5px; }

.sidebar-menu li a:hover {
    background: var(--eo-sidebar-hover);
    color: #fff;
}
.sidebar-menu li a:hover i { color: #6ea0ff; transform: translateX(1px); }

.sidebar-menu li.active a {
    background: linear-gradient(100deg, rgba(37,99,235,0.95), rgba(79,123,255,0.85));
    color: #fff;
    box-shadow: 0 8px 18px -8px rgba(37,99,235,0.8), inset 0 1px 0 rgba(255,255,255,0.18);
}
.sidebar-menu li.active a i { color: #fff; }
.sidebar-menu li.active a::before {
    content: '';
    position: absolute; left: -12px; top: 50%; transform: translateY(-50%);
    width: 4px; height: 22px;
    background: var(--eo-accent);
    border-radius: 0 4px 4px 0;
    box-shadow: 0 0 12px rgba(245,158,11,0.7);
}

/* Collapsed */
.sidebar.collapsed .logo-text,
.sidebar.collapsed .user-info,
.sidebar.collapsed .menu-label,
.sidebar.collapsed .sidebar-menu li a span { opacity: 0; width: 0; overflow: hidden; }
.sidebar.collapsed .sidebar-user { justify-content: center; padding: 12px; }
.sidebar.collapsed .sidebar-menu li a { justify-content: center; padding: 12px; }

/* =========================================================
   CONTENT
========================================================= */
.content-wrapper {
    margin-left: var(--eo-sidebar-width);
    flex: 1;
    transition: var(--eo-transition);
    min-width: 0;
    display: flex;
    flex-direction: column;
}
.content-wrapper.expanded { margin-left: var(--eo-sidebar-collapsed-width); }

/* Top navbar */
.top-navbar {
    height: var(--eo-topbar-height);
    background: rgba(255,255,255,0.78);
    backdrop-filter: saturate(180%) blur(14px);
    -webkit-backdrop-filter: saturate(180%) blur(14px);
    border-bottom: 1px solid var(--eo-border);
    padding: 0 24px;
    position: sticky; top: 0; z-index: 900;
    box-shadow: 0 1px 0 rgba(15,27,45,0.03);
}
.page-title {
    font-size: 16px; font-weight: 700; color: var(--eo-text-main);
    letter-spacing: -0.02em;
}

/* Page content */
.page-content { padding: 26px; min-height: calc(100vh - var(--eo-topbar-height)); }

/* =========================================================
   CARDS
========================================================= */
.card {
    background: var(--eo-card-bg);
    border: 1px solid var(--eo-border);
    border-radius: var(--eo-radius);
    box-shadow: var(--eo-shadow);
    overflow: hidden;
    transition: var(--eo-transition);
}

.card-header {
    background: linear-gradient(180deg, #fff, #fbfcfe);
    border-bottom: 1px solid var(--eo-border-soft);
    padding: 16px 20px;
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.card-header h5, .card-header h6 {
    margin: 0; font-weight: 700; color: var(--eo-text-main);
    letter-spacing: -0.01em; display: flex; align-items: center;
}
.card-body { padding: 20px; }

/* =========================================================
   DASHBOARD — KARŞILAMA PANELİ
========================================================= */
.hero-panel {
    display: flex; align-items: center; justify-content: space-between;
    flex-wrap: wrap; gap: 24px;
    padding: 26px 30px;
    border-radius: var(--eo-radius-lg);
    background:
        radial-gradient(600px 260px at 0% 0%, rgba(37,99,235,0.35), transparent 62%),
        linear-gradient(120deg, #0c1729 0%, #101f38 100%);
    color: #e8eefc;
    position: relative;
    overflow: hidden;
    box-shadow: var(--eo-shadow-md);
}
.hero-panel::after {
    content: '';
    position: absolute; right: -60px; top: -80px;
    width: 280px; height: 280px;
    background: radial-gradient(circle, rgba(245,158,11,0.16), transparent 65%);
    pointer-events: none;
}
.hero-main { min-width: 0; position: relative; z-index: 1; }
.hero-date {
    display: inline-block;
    font-size: 11.5px; font-weight: 600; letter-spacing: .04em;
    text-transform: uppercase; color: #8fa3c4;
    margin-bottom: 8px;
}
.hero-title {
    font-size: 25px; font-weight: 800; color: #fff;
    letter-spacing: -0.035em; margin: 0 0 5px;
}
.hero-sub { font-size: 13.5px; color: #9db0cd; margin: 0; }

.hero-metrics {
    display: flex; gap: 12px; flex-wrap: wrap;
    position: relative; z-index: 1;
}
.hero-metric {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.09);
    border-radius: 13px;
    padding: 12px 18px;
    min-width: 122px;
}
.hm-label {
    display: block; font-size: 10.5px; font-weight: 600;
    text-transform: uppercase; letter-spacing: .07em; color: #8fa3c4;
    margin-bottom: 3px;
}
.hm-value {
    display: block; font-size: 17px; font-weight: 800; color: #fff;
    letter-spacing: -0.02em; font-variant-numeric: tabular-nums;
}
.hm-value.negatif { color: #fca5a5; }

/* =========================================================
   UYARI ŞERİDİ
========================================================= */
.uyari-serit {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 12px;
}
.uyari-kart {
    display: flex; align-items: center; gap: 13px;
    padding: 14px 16px;
    border-radius: var(--eo-radius-sm);
    text-decoration: none;
    border: 1px solid;
    transition: var(--eo-transition);
}
.uyari-kart > i:first-child { font-size: 17px; flex-shrink: 0; }
.uyari-kart div { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.uyari-kart strong { font-size: 13.5px; font-weight: 700; letter-spacing: -0.01em; }
.uyari-kart span { font-size: 11.5px; opacity: .78; font-weight: 500; }
.uyari-ok { font-size: 11px; opacity: .45; transition: var(--eo-transition); }
.uyari-kart:hover { transform: translateX(3px); box-shadow: var(--eo-shadow-md); }
.uyari-kart:hover .uyari-ok { opacity: .9; transform: translateX(2px); }

.uyari-kart.danger  { background: #fdeaea; border-color: #f7cccc; color: #991b1b; }
.uyari-kart.warning { background: #fef6e3; border-color: #f8e3b5; color: #92400e; }

/* Stat cards */
.stat-card {
    background: var(--eo-card-bg);
    border: 1px solid var(--eo-border);
    border-radius: var(--eo-radius);
    padding: 20px;
    display: flex; align-items: center; gap: 16px;
    box-shadow: var(--eo-shadow);
    transition: var(--eo-transition);
    height: 100%;
    position: relative;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
}
/* left accent strip */
.stat-card::before {
    content: '';
    position: absolute; left: 0; top: 0; bottom: 0;
    width: 4px;
    background: var(--eo-primary);
    opacity: .85;
    transition: var(--eo-transition);
}
.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--eo-shadow-lg);
    border-color: #d6deea;
}
.stat-card:hover::before { width: 6px; }

.stat-icon {
    width: 54px; height: 54px;
    border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
    font-size: 22px; flex-shrink: 0;
    box-shadow: inset 0 0 0 1px rgba(15,27,45,0.04);
}
.stat-icon.blue   { background: linear-gradient(135deg,#eaf1ff,#dbe7ff); color: var(--eo-primary); }
.stat-icon.green  { background: linear-gradient(135deg,#e6f8f0,#d6f4e6); color: var(--eo-success); }
.stat-icon.yellow { background: linear-gradient(135deg,#fff4e1,#ffedcc); color: var(--eo-warning); }
.stat-icon.red    { background: linear-gradient(135deg,#fdeaea,#fbdcdc); color: var(--eo-danger); }
.stat-icon.purple { background: linear-gradient(135deg,#f2ecfe,#e9dffd); color: #7c3aed; }
.stat-icon.cyan   { background: linear-gradient(135deg,#e2f7fb,#d0f1f7); color: var(--eo-info); }

/* color the accent strip to match icon */
.stat-card:has(.stat-icon.green)::before  { background: var(--eo-success); }
.stat-card:has(.stat-icon.yellow)::before { background: var(--eo-warning); }
.stat-card:has(.stat-icon.red)::before    { background: var(--eo-danger); }
.stat-card:has(.stat-icon.purple)::before { background: #7c3aed; }
.stat-card:has(.stat-icon.cyan)::before   { background: var(--eo-info); }

.stat-info { flex: 1; min-width: 0; }
.stat-value {
    font-size: 24px; font-weight: 800; color: var(--eo-text-main);
    line-height: 1.15; letter-spacing: -0.03em;
    font-variant-numeric: tabular-nums;
}
.stat-label { font-size: 12px; color: var(--eo-text-muted); margin-top: 3px; font-weight: 500; }

/* alt satır: trend rozeti + açıklama */
.stat-meta {
    display: flex; align-items: center; gap: 7px;
    margin-top: 8px;
    font-size: 11px; color: var(--eo-text-muted); font-weight: 500;
}
.stat-meta .trend {
    display: inline-flex; align-items: center; gap: 3px;
    padding: 2px 7px; border-radius: 50px;
    font-weight: 700; font-size: 10.5px;
    font-variant-numeric: tabular-nums;
}
.stat-meta .trend.yukari { background: #e6f8f0; color: #065f46; }
.stat-meta .trend.asagi  { background: #fdeaea; color: #991b1b; }

/* =========================================================
   GRAFİK & DEMANT HALKASI
========================================================= */
/* Grafik kartı, yanındaki demant kartıyla aynı yüksekliği doldurur */
.card-body-grafik { display: flex; flex-direction: column; }
.grafik-kutu { position: relative; flex: 1; min-height: 260px; }

.halka {
    --yuzde: 0;
    width: 178px; height: 178px;
    margin: 6px auto 0;
    border-radius: 50%;
    display: grid; place-items: center;
    background:
        conic-gradient(var(--eo-primary) calc(var(--yuzde) * 1%), #e9eef6 0);
    position: relative;
    animation: halkaGir .9s cubic-bezier(.2,.9,.3,1) both;
}
@keyframes halkaGir { from { transform: scale(.9); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.halka::after {
    content: '';
    position: absolute; inset: 13px;
    border-radius: 50%;
    background: var(--eo-card-bg);
    box-shadow: inset 0 1px 4px rgba(15,27,45,.07);
}
.halka-ic { position: relative; z-index: 1; text-align: center; }
.halka-deger {
    display: block; font-size: 32px; font-weight: 800;
    color: var(--eo-text-main); letter-spacing: -0.04em;
    font-variant-numeric: tabular-nums; line-height: 1;
}
.halka-etiket {
    display: block; font-size: 11.5px; color: var(--eo-text-muted);
    font-weight: 600; margin-top: 5px;
    text-transform: uppercase; letter-spacing: .06em;
}

/* =========================================================
   HIZLI İŞLEMLER
========================================================= */
.hizli-islemler {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(138px, 1fr));
    gap: 12px;
}
.hizli-islem span { line-height: 1.35; overflow-wrap: anywhere; }
.hizli-islem {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 9px; padding: 18px 12px;
    background: linear-gradient(180deg, #fbfcfe, #f4f7fb);
    border: 1px solid var(--eo-border-soft);
    border-radius: 13px;
    text-decoration: none;
    color: var(--eo-text-mid);
    font-size: 12.5px; font-weight: 600;
    text-align: center;
    transition: var(--eo-transition);
}
.hizli-islem i {
    font-size: 19px; color: var(--eo-primary);
    transition: var(--eo-transition);
}
.hizli-islem:hover {
    border-color: #cfdcff;
    background: var(--eo-primary-soft);
    color: var(--eo-primary);
    transform: translateY(-3px);
    box-shadow: var(--eo-shadow-md);
}
.hizli-islem:hover i { transform: scale(1.12); }

/* =========================================================
   TABLES
========================================================= */
.table-responsive { border-radius: var(--eo-radius-sm); overflow: hidden; }
.table { margin-bottom: 0; font-size: 13.5px; }

.table thead th {
    background: #f6f8fc;
    font-weight: 700;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--eo-text-muted);
    border-bottom: 1px solid var(--eo-border);
    padding: 13px 16px;
    white-space: nowrap;
}
.table tbody td {
    padding: 13px 16px;
    vertical-align: middle;
    border-bottom: 1px solid var(--eo-border-soft);
    color: var(--eo-text-mid);
}
.table tbody tr { transition: background .15s ease; }
.table tbody tr:hover { background: var(--eo-primary-soft); }
.table tbody tr:last-child td { border-bottom: none; }

/* =========================================================
   BADGES
========================================================= */
.badge {
    font-size: 11px; font-weight: 700;
    padding: 5px 11px; border-radius: 50px;
    letter-spacing: .01em;
}

/* =========================================================
   BUTTONS
========================================================= */
.btn {
    font-size: 13px; font-weight: 600;
    border-radius: var(--eo-radius-sm);
    padding: 8px 17px;
    transition: var(--eo-transition);
    letter-spacing: -0.01em;
}
.btn:active { transform: translateY(1px); }

.btn-primary {
    background: linear-gradient(135deg, var(--eo-primary), #3b6cf0);
    border: none;
    box-shadow: 0 6px 16px -6px rgba(37,99,235,0.6);
}
.btn-primary:hover {
    background: linear-gradient(135deg, var(--eo-primary-dark), #2f5fe0);
    box-shadow: 0 8px 20px -6px rgba(37,99,235,0.7);
    transform: translateY(-1px);
}
.btn-sm { padding: 5px 12px; font-size: 12px; }
.btn-lg { padding: 12px 22px; font-size: 15px; }

.btn-outline-primary { border-color: #cfdcff; color: var(--eo-primary); }
.btn-outline-primary:hover { background: var(--eo-primary); border-color: var(--eo-primary); }

.btn-icon {
    width: 34px; height: 34px; padding: 0;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 9px;
}

/* =========================================================
   FORMS
========================================================= */
.form-label { font-size: 13px; font-weight: 600; color: var(--eo-text-mid); margin-bottom: 6px; }
.form-control, .form-select {
    font-size: 14px;
    border: 1px solid var(--eo-border);
    border-radius: var(--eo-radius-sm);
    padding: 9px 13px;
    transition: var(--eo-transition);
    color: var(--eo-text-main);
    background-color: #fff;
}
.form-control::placeholder { color: #aab6c8; }
.form-control:focus, .form-select:focus {
    border-color: var(--eo-primary);
    box-shadow: var(--eo-ring);
}
.form-control-lg { padding: 12px 15px; font-size: 15px; }

/* =========================================================
   PROGRESS
========================================================= */
.progress { height: 9px; border-radius: 50px; background: #e6ebf3; overflow: hidden; }
.progress-bar { border-radius: 50px; background: linear-gradient(90deg, var(--eo-primary), #4f7bff); }

/* =========================================================
   STATUS BADGES
========================================================= */
.status-beklemede    { background: #fef3c7; color: #92400e; }
.status-devam        { background: #dbeafe; color: #1e40af; }
.status-tamamlandi   { background: #d1fae5; color: #065f46; }
.status-iptal        { background: #fee2e2; color: #991b1b; }
.status-tahsil       { background: #d1fae5; color: #065f46; }
.status-iade         { background: #fef3c7; color: #92400e; }
.status-karsilisksiz { background: #fee2e2; color: #991b1b; }

/* =========================================================
   LOGIN PAGE  —  iki panelli kurumsal giriş ekranı
========================================================= */
.login-page {
    min-height: 100vh;
    background:
        radial-gradient(900px 520px at 12% 18%, rgba(37,99,235,0.34), transparent 58%),
        radial-gradient(760px 520px at 88% 84%, rgba(245,158,11,0.16), transparent 58%),
        linear-gradient(150deg, #0b1220 0%, #112038 55%, #0b1a33 100%);
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    padding: 28px 20px;
    position: relative;
    overflow: hidden;
}
/* ince ızgara dokusu */
.login-page::before {
    content: '';
    position: absolute; inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px);
    background-size: 46px 46px;
    mask-image: radial-gradient(circle at 50% 45%, #000 25%, transparent 80%);
    -webkit-mask-image: radial-gradient(circle at 50% 45%, #000 25%, transparent 80%);
}
/* yumuşak ışık kürelerinden biri */
.login-page::after {
    content: '';
    position: absolute;
    width: 540px; height: 540px;
    top: -170px; right: -130px;
    background: radial-gradient(circle, rgba(37,99,235,0.42), transparent 65%);
    filter: blur(42px);
    animation: floatGlow 9s ease-in-out infinite alternate;
    pointer-events: none;
}
@keyframes floatGlow {
    from { transform: translate(0,0) scale(1); }
    to   { transform: translate(-40px,40px) scale(1.12); }
}

/* akım hattı animasyonu */
.login-circuit {
    position: absolute; inset: 0;
    width: 100%; height: 100%;
    pointer-events: none;
    opacity: .5;
}
.login-circuit path {
    fill: none;
    stroke: rgba(110,160,255,0.35);
    stroke-width: 1.5;
    stroke-dasharray: 14 260;
    animation: akim 7s linear infinite;
}
.login-circuit path:nth-child(2) { animation-duration: 9s;  animation-delay: -2s; stroke: rgba(245,158,11,0.3); }
.login-circuit path:nth-child(3) { animation-duration: 11s; animation-delay: -4s; }
@keyframes akim { to { stroke-dashoffset: -1370; } }

/* iki panelli kabuk */
.login-shell {
    position: relative; z-index: 2;
    display: grid;
    grid-template-columns: 1.05fr .95fr;
    align-items: stretch;
    width: 100%; max-width: 940px;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 36px 80px -22px rgba(0,0,0,0.65), 0 0 0 1px rgba(255,255,255,0.07);
    animation: cardIn .6s cubic-bezier(.2,.9,.3,1) both;
}
@keyframes cardIn {
    from { opacity: 0; transform: translateY(20px) scale(.98); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* --- sol tanıtım paneli --- */
.login-brand {
    padding: 48px 44px;
    color: #e8eefc;
    background:
        radial-gradient(520px 300px at 0% 0%, rgba(37,99,235,0.4), transparent 62%),
        linear-gradient(165deg, #0e1b31 0%, #0a1424 100%);
    background-color: #0c1729;
    display: flex; flex-direction: column;
    border-right: 1px solid rgba(255,255,255,0.07);
}
.brand-mark {
    width: 54px; height: 54px;
    border-radius: 16px;
    background: linear-gradient(135deg, var(--eo-primary), #4f7bff);
    display: flex; align-items: center; justify-content: center;
    font-size: 23px; color: #fff;
    box-shadow: 0 10px 26px -8px rgba(37,99,235,0.8), inset 0 1px 0 rgba(255,255,255,0.3);
    margin-bottom: 26px;
}
.login-brand h1 {
    font-size: 30px; font-weight: 800; line-height: 1.2;
    letter-spacing: -0.035em; color: #fff; margin: 0 0 12px;
}
.brand-sub {
    font-size: 14px; color: #93a4bf; line-height: 1.65;
    margin: 0 0 30px; max-width: 34ch;
}
.brand-list { list-style: none; padding: 0; margin: 0 0 auto; display: grid; gap: 14px; }
.brand-list li {
    display: flex; align-items: center; gap: 13px;
    font-size: 13.5px; color: #c3d0e6; font-weight: 500;
}
.brand-list i {
    width: 34px; height: 34px; flex-shrink: 0;
    border-radius: 10px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.08);
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 13px; color: #6ea0ff;
}
.brand-foot {
    margin-top: 34px; padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.08);
    font-size: 11.5px; color: #7a8aa0; letter-spacing: .02em;
}
.brand-foot i { color: var(--eo-accent); margin-right: 6px; }

/* --- sağ form paneli --- */
.login-card {
    position: relative;
    background: #fff;
    padding: 46px 44px;
    display: flex; flex-direction: column; justify-content: center;
}

.login-logo { text-align: center; margin-bottom: 26px; }
.login-logo .logo-circle {
    width: 68px; height: 68px;
    background: linear-gradient(135deg, var(--eo-primary), #4f7bff);
    border-radius: 19px;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 29px; color: #fff;
    margin-bottom: 15px;
    box-shadow: 0 12px 30px -8px rgba(37,99,235,0.7), inset 0 1px 0 rgba(255,255,255,0.35);
    animation: pulseGlow 2.8s ease-in-out infinite;
}
@keyframes pulseGlow {
    0%,100% { box-shadow: 0 12px 30px -8px rgba(37,99,235,0.55), inset 0 1px 0 rgba(255,255,255,0.35); }
    50%     { box-shadow: 0 12px 38px -6px rgba(37,99,235,0.85), inset 0 1px 0 rgba(255,255,255,0.35); }
}
.login-logo h2 {
    font-size: 22px; font-weight: 800; color: var(--eo-text-main);
    margin: 0 0 5px; letter-spacing: -0.03em;
}
.login-logo p { font-size: 13px; color: var(--eo-text-muted); font-weight: 500; margin: 0; }

.login-card .form-control-lg { padding: 13px 15px; }
.login-card .input-group .btn-outline-secondary {
    border-color: var(--eo-border); color: var(--eo-text-muted);
}
.login-card .input-group .btn-outline-secondary:hover { background: var(--eo-primary-soft); color: var(--eo-primary); }

.caps-warn {
    margin-top: 8px; font-size: 12px; font-weight: 600;
    color: #92400e; background: #fef3c7;
    display: inline-flex; align-items: center; gap: 6px;
    padding: 5px 10px; border-radius: 7px;
}

.btn-login {
    margin-top: 18px; padding: 13px; font-weight: 700;
    display: flex; align-items: center; justify-content: center;
}
.btn-login:disabled { opacity: .65; }

.login-help {
    margin: 22px 0 0; text-align: center;
    font-size: 12px; color: var(--eo-text-muted);
}

.login-footer {
    position: relative; z-index: 2;
    margin-top: 26px;
    font-size: 12px; color: rgba(147,164,191,0.7);
    text-align: center;
}

/* --- giriş ekranı duyarlılık --- */
@media (max-width: 860px) {
    .login-shell { grid-template-columns: 1fr; max-width: 460px; }
    .login-brand { display: none; }
    .login-card { padding: 40px 30px; border-radius: 24px; }
    .login-circuit { opacity: .3; }
}
@media (max-width: 400px) {
    .login-page { padding: 16px 12px; }
    .login-card { padding: 32px 22px; }
    .login-logo h2 { font-size: 20px; }
}

/* =========================================================
   ALERTS
========================================================= */
.alert { font-size: 13.5px; border-radius: var(--eo-radius-sm); border: none; font-weight: 500; }
.alert-danger { background: #fdeaea; color: #991b1b; }
.alert-success { background: #e6f8f0; color: #065f46; }

/* =========================================================
   DATATABLES
========================================================= */
.dataTables_wrapper .dataTables_filter input,
.dataTables_wrapper .dataTables_length select {
    border: 1px solid var(--eo-border);
    border-radius: var(--eo-radius-sm);
    padding: 6px 11px;
    font-size: 13px;
}
.dataTables_wrapper .dataTables_filter input:focus,
.dataTables_wrapper .dataTables_length select:focus {
    border-color: var(--eo-primary); box-shadow: var(--eo-ring); outline: none;
}
.dataTables_wrapper .dataTables_paginate .paginate_button.current {
    background: var(--eo-primary) !important;
    border-color: var(--eo-primary) !important;
    color: #fff !important;
    border-radius: 7px;
}

/* =========================================================
   OVERLAY (mobile)
========================================================= */
.sidebar-overlay {
    display: none;
    position: fixed; top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(11,18,32,0.55);
    backdrop-filter: blur(2px);
    z-index: 999;
}

/* =========================================================
   RESPONSIVE
========================================================= */
@media (max-width: 992px) {
    .sidebar { transform: translateX(-100%); z-index: 1001; }
    .sidebar.mobile-open { transform: translateX(0); }
    .content-wrapper { margin-left: 0 !important; }
    .sidebar-overlay.active { display: block; }
    .page-content { padding: 18px; }

    .hero-panel { padding: 22px; }
    .hero-title { font-size: 21px; }
    .hero-metrics { width: 100%; }
    .hero-metric { flex: 1; min-width: 100px; padding: 11px 14px; }
    .hm-value { font-size: 15.5px; }
}

@media (max-width: 576px) {
    .page-content { padding: 14px; }
    .stat-card { padding: 16px; gap: 13px; }
    .stat-icon { width: 46px; height: 46px; font-size: 18px; border-radius: 12px; }
    .stat-value { font-size: 20px; }
    .grafik-kutu { height: 230px; }
    .halka { width: 150px; height: 150px; }
    .halka-deger { font-size: 27px; }
    .hero-metric { min-width: 0; }
    .hm-label { font-size: 9.5px; }
    /* Tablolar dar ekranda yatay kaydırılır, sayfa gövdesi kaymaz */
    .table-responsive { overflow-x: auto; -webkit-overflow-scrolling: touch; }
}

/* =========================================================
   MISC
========================================================= */
.text-money { font-weight: 700; color: var(--eo-success); font-variant-numeric: tabular-nums; }
.text-money-red { font-weight: 700; color: var(--eo-danger); font-variant-numeric: tabular-nums; }

.action-btns { display: flex; gap: 5px; flex-wrap: nowrap; }

.section-header {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 22px; flex-wrap: wrap; gap: 12px;
}

.page-icon {
    width: 42px; height: 42px;
    border-radius: 12px;
    background: linear-gradient(135deg, #eaf1ff, #dbe7ff);
    color: var(--eo-primary);
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 18px; margin-right: 12px;
    box-shadow: inset 0 0 0 1px rgba(37,99,235,0.08);
}

.quick-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 12px;
}
.quick-info-item {
    text-align: center; padding: 14px;
    background: linear-gradient(180deg,#fbfcfe,#f4f7fb);
    border-radius: 11px;
    border: 1px solid var(--eo-border-soft);
}
.quick-info-item .value {
    font-size: 19px; font-weight: 800; color: var(--eo-text-main);
    letter-spacing: -0.02em; font-variant-numeric: tabular-nums;
}
.quick-info-item .label { font-size: 11px; color: var(--eo-text-muted); margin-top: 3px; font-weight: 500; }

.empty-state { text-align: center; padding: 52px 20px; color: var(--eo-text-muted); }
.empty-state i { font-size: 50px; margin-bottom: 16px; opacity: .28; }
.empty-state p { font-size: 14px; font-weight: 500; }

/* Dropdown polish */
.dropdown-menu {
    border: 1px solid var(--eo-border);
    border-radius: 13px;
    box-shadow: var(--eo-shadow-lg);
    padding: 6px;
}
.dropdown-item { border-radius: 8px; padding: 8px 12px; font-weight: 500; }
.dropdown-header { font-weight: 700; color: var(--eo-text-main); }

/* Staggered entrance for dashboard rows */
.page-content > .row { animation: rowIn .5s ease both; }
.page-content > .row:nth-of-type(1) { animation-delay: .02s; }
.page-content > .row:nth-of-type(2) { animation-delay: .08s; }
.page-content > .row:nth-of-type(3) { animation-delay: .14s; }
.page-content > .row:nth-of-type(4) { animation-delay: .20s; }
@keyframes rowIn {
    from { opacity: 0; transform: translateY(12px); }
    to   { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
    *, .page-content > .row, .login-card, .login-logo .logo-circle, .login-page::after {
        animation: none !important;
    }
}
