/* =============================================
   HESAP - Muhasebe Yonetim Sistemi
   ============================================= */

:root {
    --sidebar-width: 250px;
    --sidebar-bg: #1a1a2e;
    --sidebar-hover: #16213e;
    --primary: #0f3460;
    --primary-light: #3a7bd5;
    --accent: #e94560;
    --bg-color: #f0f2f5;
    --card-shadow: 0 2px 10px rgba(0,0,0,0.08);
    --transition: all 0.3s ease;
}

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

body {
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-color);
    overflow-x: hidden;
}

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

/* ===== SIDEBAR ===== */
.sidebar {
    width: var(--sidebar-width);
    background: var(--sidebar-bg);
    color: #fff;
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    transition: var(--transition);
    overflow-y: auto;
}

.sidebar.collapsed {
    margin-left: calc(var(--sidebar-width) * -1);
}

.sidebar-header {
    padding: 18px 20px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.sidebar-brand {
    color: #fff;
    text-decoration: none;
    font-size: 24px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
}

.sidebar-brand i {
    color: var(--accent);
    font-size: 28px;
}

.sidebar-brand:hover {
    color: #fff;
}

.sidebar-user {
    padding: 12px 0;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    flex-shrink: 0;
}

.sidebar-nav {
    flex: 1;
    padding: 10px 0;
    overflow-y: auto;
}

.sidebar-nav .nav-link {
    color: rgba(255,255,255,0.7);
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: var(--transition);
    border-left: 3px solid transparent;
    font-size: 14px;
}

.sidebar-nav .nav-link:hover {
    color: #fff;
    background: rgba(255,255,255,0.05);
    border-left-color: var(--accent);
}

.sidebar-nav .nav-link.active {
    color: #fff;
    background: rgba(255,255,255,0.1);
    border-left-color: var(--accent);
}

.sidebar-nav .nav-link i {
    width: 20px;
    text-align: center;
    font-size: 16px;
}

.nav-divider {
    padding: 8px 20px 4px;
    font-size: 11px;
    color: rgba(255,255,255,0.35);
    letter-spacing: 1px;
    font-weight: 600;
}

.sidebar-footer {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding: 8px 0;
}

.sidebar-footer .nav-link {
    color: rgba(255,255,255,0.6);
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: var(--transition);
    font-size: 14px;
}

.sidebar-footer .nav-link:hover {
    color: var(--accent);
    background: rgba(255,255,255,0.05);
}

.sidebar-footer .nav-link i {
    width: 20px;
    text-align: center;
}

/* ===== MAIN CONTENT ===== */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    transition: var(--transition);
    min-height: 100vh;
}

.sidebar.collapsed + .main-content {
    margin-left: 0;
}

/* ===== TOPBAR ===== */
.topbar {
    background: #fff;
    padding: 12px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    position: sticky;
    top: 0;
    z-index: 999;
}

.toggle-sidebar {
    color: #333;
    font-size: 20px;
    text-decoration: none;
    padding: 4px 8px;
    border: none;
    background: none;
}

.toggle-sidebar:hover {
    color: var(--accent);
}

.topbar-title {
    font-weight: 600;
    color: #333;
}

/* ===== PAGE TITLE ===== */
.page-title {
    font-weight: 600;
    color: #2c3e50;
    font-size: 22px;
}

/* ===== CARDS ===== */
.content-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: var(--card-shadow);
    overflow: hidden;
    margin-bottom: 0;
}

.card-header-custom {
    padding: 16px 20px;
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.card-header-custom h5 {
    margin: 0;
    font-size: 15px;
    font-weight: 600;
    color: #2c3e50;
}

/* ===== DASHBOARD CARDS ===== */
.dashboard-card {
    border-radius: 12px;
    color: #fff;
    box-shadow: var(--card-shadow);
    transition: transform 0.2s;
}

.dashboard-card:hover {
    transform: translateY(-2px);
}

.dashboard-card .card-body {
    padding: 20px;
}

.card-label {
    font-size: 12px;
    opacity: 0.9;
    margin-bottom: 4px;
    font-weight: 500;
}

.card-value {
    margin: 0;
    font-weight: 700;
    font-size: 24px;
}

.card-icon {
    font-size: 32px;
    opacity: 0.3;
}

.card-tl {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
}

.card-usd {
    background: linear-gradient(135deg, #27ae60, #2ecc71);
}

.card-eur {
    background: linear-gradient(135deg, #2980b9, #3498db);
}

.card-altin {
    background: linear-gradient(135deg, #f39c12, #e67e22);
}

.card-total {
    background: linear-gradient(135deg, #6c5ce7, #a29bfe);
}

.card-kasa {
    background: linear-gradient(135deg, #00b894, #00cec9);
}

.card-kur {
    background: linear-gradient(135deg, #2d3436, #636e72);
}

/* ===== TABLES ===== */
.table {
    margin-bottom: 0;
    font-size: 14px;
}

.table thead th {
    background: #f8f9fa;
    border-bottom: 2px solid #eee;
    color: #666;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    padding: 10px 12px;
}

.table tbody td {
    padding: 10px 12px;
    vertical-align: middle;
}

.table-hover tbody tr:hover {
    background: #f8f9ff;
}

/* ===== LOGIN PAGE ===== */
.login-page {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-container {
    width: 100%;
    max-width: 420px;
    padding: 20px;
}

.login-card {
    background: #fff;
    border-radius: 16px;
    padding: 40px 32px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
}

.login-icon {
    text-align: center;
    margin: 0 auto 12px;
    padding: 10px 0;
}

.login-logo {
    max-width: 100%;
    width: 260px;
    height: auto;
    display: inline-block;
}

.login-header h2 {
    font-weight: 700;
    color: #2c3e50;
    font-size: 22px;
}

.login-header p {
    font-size: 13px;
}

.login-form .form-label {
    font-weight: 500;
    color: #555;
    font-size: 13px;
}

.login-form .input-group-text {
    background: #f8f9fa;
    border-right: none;
}

.login-form .form-control {
    border-left: none;
}

.login-form .form-control:focus {
    box-shadow: none;
    border-color: #ced4da;
}

/* ===== MODAL ===== */
.modal-content {
    border: none;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
}

.modal-header {
    border-bottom: 1px solid #eee;
    padding: 16px 20px;
}

.modal-header .modal-title {
    font-weight: 600;
    font-size: 16px;
}

.modal-body {
    padding: 20px;
}

.modal-footer {
    border-top: 1px solid #eee;
    padding: 12px 20px;
}

/* ===== FORMS ===== */
.form-control, .form-select {
    border-radius: 8px;
    padding: 10px 14px;
    font-size: 14px;
    border: 1.5px solid #e0e0e0;
    transition: var(--transition);
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-light);
    box-shadow: 0 0 0 3px rgba(58, 123, 213, 0.15);
}

.form-label {
    font-size: 13px;
    font-weight: 500;
    color: #555;
    margin-bottom: 4px;
}

/* ===== BADGES ===== */
.badge {
    font-weight: 500;
    padding: 4px 8px;
    font-size: 11px;
}

/* ===== BUTTONS ===== */
.btn {
    border-radius: 8px;
    font-weight: 500;
    padding: 8px 16px;
    font-size: 14px;
    transition: var(--transition);
}

.btn-primary {
    background: var(--primary-light);
    border-color: var(--primary-light);
}

.btn-primary:hover {
    background: #2d6fc4;
    border-color: #2d6fc4;
}

.btn-outline-primary {
    border-color: var(--primary-light);
    color: var(--primary-light);
}

.btn-outline-primary:hover {
    background: var(--primary-light);
    color: #fff;
}

/* ===== LIST GROUP ===== */
.list-group-item {
    border: none;
    border-bottom: 1px solid #f0f0f0;
    padding: 10px 16px;
    font-size: 13px;
}

.list-group-item:last-child {
    border-bottom: none;
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: rgba(0,0,0,0.15);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(0,0,0,0.25);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .sidebar {
        margin-left: calc(var(--sidebar-width) * -1);
    }

    .sidebar.mobile-open {
        margin-left: 0;
    }

    .main-content {
        margin-left: 0;
    }

    .topbar {
        padding: 10px 16px;
    }

    .container-fluid.p-4 {
        padding: 16px !important;
    }

    .dashboard-card .card-value {
        font-size: 20px;
    }
}

/* ===== TOGGLE PASSWORD ===== */
.toggle-password {
    border-radius: 0 8px 8px 0 !important;
}

/* ===== ANIMATIONS ===== */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.content-card, .dashboard-card {
    animation: fadeIn 0.3s ease;
}

/* ===== ADDITIONAL UTILITIES ===== */
.text-white-50 {
    color: rgba(255,255,255,0.6) !important;
}

/* ===== GLOBAL ALERT / CONFIRM MODAL ===== */
.alert-dialog-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 99999;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.2s ease;
}
.alert-dialog {
    background: #fff;
    border-radius: 16px;
    padding: 32px 40px;
    max-width: 420px;
    width: 90%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}
.alert-dialog-icon {
    font-size: 48px;
    margin-bottom: 12px;
    color: #f39c12;
}
.alert-dialog-icon .fa-check-circle { color: #27ae60; }
.alert-dialog-icon .fa-times-circle { color: #e74c3c; }
.alert-dialog-icon .fa-question-circle { color: #3498db; }
.alert-dialog-msg {
    font-size: 15px;
    color: #333;
    line-height: 1.5;
    margin-bottom: 8px;
}
