/* public/assets/css/app.css - Fibyte Modern SaaS Portal Refined Elegant Design */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:wght,FILL@100..700,0..1&display=swap');

:root {
    --primary: #135bec;
    --primary-hover: #0e45b5;
    --primary-subtle: #eff6ff;
    --primary-light: #dbeafe;
    --bg-light: #f8fafc;
    --card-bg: #ffffff;
    --border-color: #e2e8f0;
    --text-main: #0f172a;
    --text-muted: #64748b;
    --sidebar-width: 240px;
    --header-height: 60px;
    --radius-lg: 12px;
    --radius-md: 8px;
    --radius-sm: 6px;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-card: 0 4px 20px -2px rgba(15, 23, 42, 0.05), 0 2px 6px -1px rgba(15, 23, 42, 0.02);
    --shadow-hover: 0 10px 28px -4px rgba(15, 23, 42, 0.09), 0 4px 10px -2px rgba(15, 23, 42, 0.03);
}

:root {
    --primary: #135bec;
    --primary-hover: #0e45b5;
    --primary-subtle: #eff6ff;
    --primary-light: #dbeafe;
    --bg-light: #f8fafc;
    --card-bg: #ffffff;
    --border-color: #e2e8f0;
    --text-main: #0f172a;
    --text-muted: #64748b;
    --sidebar-width: 240px;
    --header-height: 56px;
    --radius-lg: 10px;
    --radius-md: 7px;
    --radius-sm: 5px;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.04);
    --shadow-card: 0 1px 3px 0 rgba(0, 0, 0, 0.02), 0 4px 16px -2px rgba(15, 23, 42, 0.05), 0 0 0 1px rgba(15, 23, 42, 0.04);
    --shadow-hover: 0 8px 24px -4px rgba(15, 23, 42, 0.08), 0 0 0 1px rgba(15, 23, 42, 0.06);
}

[data-bs-theme="dark"] {
    --bg-light: #0b0f19;
    --card-bg: #151c2c;
    --border-color: #242e42;
    --text-main: #f1f5f9;
    --text-muted: #94a3b8;
    --primary-subtle: rgba(19, 91, 236, 0.16);
    --primary-light: rgba(19, 91, 236, 0.28);
    --shadow-card: 0 4px 20px -2px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(255, 255, 255, 0.07);
    --shadow-hover: 0 8px 30px -4px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.1);
}

/* Base Refined Typography (Dengeli, Okunabilir & Modern SaaS) */
html {
    font-size: 15px; /* Dengeli, gözü yormayan modern SaaS ölçeği */
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background-color: var(--bg-light);
    color: var(--text-main);
    overflow-x: hidden;
    min-height: 100vh;
    font-size: 0.933rem; /* ~14px: net ve rahat okunabilir altın standart */
    line-height: 1.55;
    letter-spacing: -0.011em;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Linkler */
a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.15s ease;
}

a:hover {
    color: var(--primary-hover);
}

[data-bs-theme="dark"] a {
    color: #60a5fa;
}

[data-bs-theme="dark"] a:hover {
    color: #93c5fd;
}

/* Koyu Mod Uyumlulukları */
[data-bs-theme="dark"] .text-dark,
[data-bs-theme="dark"] .dark\:text-white {
    color: #f1f5f9 !important;
}

[data-bs-theme="dark"] .text-muted {
    color: #94a3b8 !important;
}

[data-bs-theme="dark"] .bg-light,
[data-bs-theme="dark"] .dark\:bg-dark {
    background-color: rgba(255, 255, 255, 0.035) !important;
    border-color: var(--border-color) !important;
    color: #f1f5f9 !important;
}

[data-bs-theme="dark"] .bg-white,
[data-bs-theme="dark"] .dark\:bg-card-bg {
    background-color: var(--card-bg) !important;
    border-color: var(--border-color) !important;
    color: #f1f5f9 !important;
}

[data-bs-theme="dark"] .border {
    border-color: var(--border-color) !important;
}

[data-bs-theme="dark"] .bg-primary-subtle {
    background-color: rgba(19, 91, 236, 0.12) !important;
    color: #93c5fd !important;
}

/* Dengeli ve Zarif Başlık Standartları */
h1, .h1 { font-size: 1.65rem; font-weight: 700; letter-spacing: -0.025em; color: var(--text-main); }
h2, .h2 { font-size: 1.4rem; font-weight: 600; letter-spacing: -0.02em; color: var(--text-main); }
h3, .h3 { font-size: 1.22rem; font-weight: 600; letter-spacing: -0.015em; color: var(--text-main); }
h4, .h4 { font-size: 1.08rem; font-weight: 600; letter-spacing: -0.01em; color: var(--text-main); }
h5, .h5 { font-size: 0.96rem; font-weight: 600; color: var(--text-main); }
h6, .h6 { font-size: 0.88rem; font-weight: 600; color: var(--text-main); }

/* Dengeli Font Büyüklük Yardımcıları */
.fs-7 { font-size: 0.85rem !important; }
.fs-8 { font-size: 0.78rem !important; }
.fs-9 { font-size: 0.72rem !important; }
.tracking-tight { letter-spacing: -0.02em !important; }
.tracking-widest { letter-spacing: 0.1em !important; }

.material-symbols-outlined {
    font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 20;
    vertical-align: middle;
    line-height: 1;
    font-size: 1.28rem;
}

/* Layout */
.app-wrapper {
    display: flex;
    min-height: 100vh;
}

.app-sidebar {
    width: var(--sidebar-width);
    background-color: var(--card-bg);
    border-right: 1px solid var(--border-color);
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 1030;
    display: flex;
    flex-direction: column;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.app-main {
    margin-left: var(--sidebar-width);
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.app-header {
    height: var(--header-height);
    background-color: rgba(255, 255, 255, 0.92);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1020;
    display: flex;
    align-items: center;
    padding: 0 1.5rem;
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

[data-bs-theme="dark"] .app-header {
    background-color: rgba(21, 28, 44, 0.92);
}

.content-body {
    padding: 1.25rem 1.5rem;
    flex: 1;
}

/* Sidebar Elements (Kibar & Kompakt) */
.sidebar-brand {
    padding: 0.85rem 1.15rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    border-bottom: 1px solid var(--border-color);
    text-decoration: none;
    color: var(--text-main);
}

.sidebar-nav {
    padding: 0.6rem 0.5rem;
    flex: 1;
    overflow-y: auto;
}

.nav-section-title {
    font-size: 0.72rem;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--text-muted);
    padding: 0.65rem 0.65rem 0.25rem 0.65rem;
    letter-spacing: 0.07em;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.5rem 0.75rem;
    color: var(--text-main);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.88rem;
    border-radius: var(--radius-md);
    transition: all 0.15s ease;
    margin-bottom: 3px;
}

.sidebar-link .material-symbols-outlined {
    font-size: 1.22rem;
    color: var(--text-muted);
    transition: color 0.15s ease;
}

.sidebar-link:hover {
    background-color: var(--primary-subtle);
    color: var(--primary);
}

.sidebar-link:hover .material-symbols-outlined {
    color: var(--primary);
}

.sidebar-link.active {
    background-color: var(--primary);
    color: #ffffff;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(19, 91, 236, 0.25);
}

.sidebar-link.active .material-symbols-outlined {
    color: #ffffff;
    font-variation-settings: 'FILL' 1;
}

/* Collapsible Dropdown & Submenu */
.sidebar-dropdown {
    margin-bottom: 2px;
}

.sidebar-dropdown-toggle {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.48rem 0.75rem;
    color: var(--text-main);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.86rem;
    border-radius: var(--radius-md);
    transition: all 0.15s ease;
    cursor: pointer;
    user-select: none;
    background: transparent;
    border: none;
    width: 100%;
    text-align: left;
}

.sidebar-dropdown-toggle .material-symbols-outlined:not(.sidebar-arrow) {
    font-size: 1.22rem;
    color: var(--text-muted);
    transition: color 0.15s ease;
}

.sidebar-dropdown-toggle:hover {
    background-color: var(--primary-subtle);
    color: var(--primary);
}

.sidebar-dropdown-toggle:hover .material-symbols-outlined {
    color: var(--primary);
}

.sidebar-dropdown-toggle .sidebar-arrow {
    font-size: 1.15rem;
    transition: transform 0.22s cubic-bezier(0.4, 0, 0.2, 1);
    color: var(--text-muted);
}

.sidebar-dropdown-toggle[aria-expanded="true"] .sidebar-arrow {
    transform: rotate(180deg);
    color: var(--primary);
}

.sidebar-dropdown-toggle.active-parent {
    color: var(--primary);
    font-weight: 600;
    background-color: rgba(19, 91, 236, 0.05);
}

.sidebar-dropdown-toggle.active-parent .material-symbols-outlined:not(.sidebar-arrow) {
    color: var(--primary);
    font-variation-settings: 'FILL' 1;
}

/* Submenu container with modern tree guide-line */
.sidebar-submenu {
    position: relative;
    margin-left: 1.35rem;
    padding-left: 0.65rem;
    border-left: 2px solid var(--border-color);
    margin-top: 3px;
    margin-bottom: 6px;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.sidebar-sublink {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.38rem 0.65rem;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 500;
    border-radius: var(--radius-sm);
    transition: all 0.15s ease;
    position: relative;
}

.sidebar-sublink:hover {
    color: var(--primary);
    background-color: var(--primary-subtle);
}

.sidebar-sublink.active {
    color: var(--primary);
    background-color: var(--primary-subtle);
    font-weight: 600;
}

.sidebar-sublink.active::before {
    content: '';
    position: absolute;
    left: -0.75rem;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 16px;
    border-radius: 2px;
    background-color: var(--primary);
}

/* Cards & Containers (Gölge, İnce Kenarlık, Havada Duran Kart Hissi) */
.card-custom {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    transition: box-shadow 0.25s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.2s ease, transform 0.2s ease;
}

.card-custom:hover {
    box-shadow: var(--shadow-hover);
}

.stat-card {
    padding: 1.15rem 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.stat-card .stat-icon {
    width: 38px;
    height: 38px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--primary-subtle);
    color: var(--primary);
}

.stat-card .stat-icon .material-symbols-outlined {
    font-size: 1.25rem;
}

.stat-card .stat-val {
    font-size: 1.6rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text-main);
}

/* Tablolar (Estetik, İnce Çizgili, Havada Duran Gölge & Okunabilir) */
.table-responsive {
    border-radius: var(--radius-lg);
    background-color: var(--card-bg);
}

.table-custom {
    width: 100%;
    margin-bottom: 0;
    color: var(--text-main);
    border-collapse: separate;
    border-spacing: 0;
}

.table-custom th {
    background-color: #f8fafc;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
    color: #64748b;
    border-bottom: 1px solid var(--border-color);
    padding: 0.75rem 1rem;
    white-space: nowrap;
}

[data-bs-theme="dark"] .table-custom th {
    background-color: #111724;
    color: #94a3b8;
    border-bottom: 1px solid #1e293b;
}

.table-custom td {
    padding: 0.78rem 1rem;
    vertical-align: middle;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.88rem;
    color: var(--text-main);
}

[data-bs-theme="dark"] .table-custom td {
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.table-custom tbody tr {
    transition: background-color 0.15s ease;
}

.table-custom tbody tr:hover {
    background-color: rgba(19, 91, 236, 0.025);
}

[data-bs-theme="dark"] .table-custom tbody tr:hover {
    background-color: rgba(255, 255, 255, 0.02);
}

.table-custom tbody tr:last-child td {
    border-bottom: none;
}

.table-custom a {
    color: var(--text-main);
    font-weight: 500;
    transition: color 0.15s ease;
}

.table-custom a:hover {
    color: var(--primary);
}

[data-bs-theme="dark"] .table-custom a {
    color: #f1f5f9;
}

[data-bs-theme="dark"] .table-custom a:hover {
    color: #60a5fa;
}

.table-custom .btn {
    padding: 0.28rem 0.6rem;
    font-size: 0.78rem;
    border-radius: var(--radius-sm);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.02);
}

.table-custom .btn-light {
    background-color: var(--bg-light);
    border: 1px solid var(--border-color);
    color: var(--text-main);
}

.table-custom .btn-light:hover {
    background-color: rgba(0, 0, 0, 0.05);
    border-color: #cbd5e1;
}

[data-bs-theme="dark"] .table-custom .btn-light {
    background-color: rgba(255, 255, 255, 0.06);
    border-color: var(--border-color);
    color: #f1f5f9;
}

[data-bs-theme="dark"] .table-custom .btn-light:hover {
    background-color: rgba(255, 255, 255, 0.12);
    color: #fff;
}

/* Butonlar (Zarif & Rahat Okunabilir) */
.btn-primary-custom {
    background-color: var(--primary);
    border: 1px solid var(--primary);
    color: #fff;
    font-weight: 500;
    font-size: 0.875rem;
    padding: 0.46rem 1rem;
    border-radius: var(--radius-md);
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    box-shadow: 0 1px 2px rgba(19, 91, 236, 0.18), 0 2px 4px rgba(19, 91, 236, 0.1);
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-primary-custom:hover {
    background-color: var(--primary-hover);
    border-color: var(--primary-hover);
    color: #fff;
    box-shadow: 0 4px 12px rgba(19, 91, 236, 0.3);
    transform: translateY(-1px);
}

.btn-secondary-custom {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    color: var(--text-main);
    font-weight: 500;
    font-size: 0.875rem;
    padding: 0.46rem 1rem;
    border-radius: var(--radius-md);
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-secondary-custom:hover {
    background-color: rgba(0, 0, 0, 0.03);
    color: var(--primary);
    border-color: #cbd5e1;
    transform: translateY(-1px);
}

.btn-xs {
    padding: 0.25rem 0.6rem;
    font-size: 0.78rem;
    border-radius: var(--radius-sm);
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

.btn-sm {
    padding: 0.36rem 0.8rem;
    font-size: 0.84rem;
    border-radius: var(--radius-sm);
}

/* Modals */
.modal-content {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.15);
}

.modal-header {
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 1.25rem;
}

.modal-footer {
    border-top: 1px solid var(--border-color);
    padding: 0.85rem 1.25rem;
}

/* Form Kontrolleri (Zarif, Net, İnce Çerçeveli & Rahat) */
.form-control, .form-select {
    background-color: var(--card-bg);
    border: 1px solid #cbd5e1;
    color: var(--text-main);
    border-radius: var(--radius-md);
    padding: 0.48rem 0.8rem;
    font-size: 0.88rem;
    transition: border-color 0.15s, box-shadow 0.15s;
}

[data-bs-theme="dark"] .form-control, 
[data-bs-theme="dark"] .form-select {
    background-color: #111724;
    border-color: #242e42;
    color: var(--text-main);
}

.form-control:focus, .form-select:focus {
    background-color: var(--card-bg);
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(19, 91, 236, 0.12);
    color: var(--text-main);
}

[data-bs-theme="dark"] .form-control:focus, 
[data-bs-theme="dark"] .form-select:focus {
    background-color: #111724;
}

.form-label {
    font-size: 0.82rem;
    font-weight: 600;
    margin-bottom: 0.35rem;
    color: var(--text-main);
}

/* Rozetler / Badges (Zarif & Okunaklı) */
.badge {
    font-weight: 500;
    font-size: 0.76rem;
    padding: 0.28rem 0.58rem;
    border-radius: 5px;
    letter-spacing: 0.015em;
}

.badge-pill {
    padding: 0.28rem 0.68rem;
    font-weight: 500;
    font-size: 0.76rem;
    border-radius: 9999px;
}

/* Dropdown Menus */
.dropdown-menu {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.08), 0 8px 10px -6px rgba(0, 0, 0, 0.04);
    font-size: 0.88rem;
    padding: 0.45rem;
}

[data-bs-theme="dark"] .dropdown-menu {
    box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.dropdown-item {
    border-radius: var(--radius-sm);
    padding: 0.42rem 0.75rem;
    color: var(--text-main);
    font-size: 0.85rem;
}

.dropdown-item:hover {
    background-color: var(--primary-subtle);
    color: var(--primary);
}

/* İlerleme Çubukları (Progress) */
.progress {
    height: 6px;
    background-color: #e2e8f0;
    border-radius: 9999px;
    overflow: hidden;
}

[data-bs-theme="dark"] .progress {
    background-color: #334155;
}

/* Başarısız Bildirim Alarm Kutusu */
.failed-notification-alert {
    background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%);
    border: 1px solid #fca5a5;
    border-radius: var(--radius-lg);
    padding: 0.9rem 1.25rem;
    color: #991b1b;
    margin-bottom: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.06);
    font-size: 0.88rem;
}

[data-bs-theme="dark"] .failed-notification-alert {
    background: linear-gradient(135deg, rgba(153, 27, 27, 0.18) 0%, rgba(185, 28, 28, 0.25) 100%);
    border-color: #7f1d1d;
    color: #fca5a5;
}

/* Empty State */
.empty-state {
    padding: 2.5rem 1.5rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.empty-state-icon {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background-color: var(--primary-subtle);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.75rem;
}

.empty-state-icon .material-symbols-outlined {
    font-size: 1.75rem;
}

/* Loading Spinner Bar */
#ajax-loading-bar {
    position: fixed;
    top: 0;
    left: 0;
    height: 2.5px;
    width: 0;
    background: linear-gradient(90deg, #135bec, #06b6d4);
    z-index: 99999;
    transition: width 0.25s ease;
}

/* Nav Tabs */
.nav-tabs .nav-link {
    font-size: 0.88rem;
    padding: 0.7rem 1.15rem;
    border: none;
    border-bottom: 2px solid transparent;
    color: var(--text-muted);
    font-weight: 500;
}

.nav-tabs .nav-link:hover {
    color: var(--primary);
    border-color: transparent;
}

.nav-tabs .nav-link.active {
    color: var(--primary);
    border-bottom: 2px solid var(--primary);
    background: transparent;
    font-weight: 600;
}

/* Print CSS */
@media print {
    .app-sidebar, .app-header, .no-print, .btn, .sidebar-brand {
        display: none !important;
    }
    .app-main {
        margin-left: 0 !important;
    }
    .content-body {
        padding: 0 !important;
    }
    body {
        background-color: #fff !important;
        color: #000 !important;
        font-size: 12px !important;
    }
    .card-custom {
        border: none !important;
        box-shadow: none !important;
    }
}
