/**
 * =====================================================
 * KUYUMCU VERESİYE TAKİP SİSTEMİ
 * Ana CSS Dosyası - Modern Dark Theme
 * =====================================================
 */

:root {
    --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gold-gradient: linear-gradient(135deg, #f5af19 0%, #f12711 100%);
    --success-gradient: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    --danger-gradient: linear-gradient(135deg, #ff416c 0%, #ff4b2b 100%);
    --dark-bg: #0f0f1a;
    --card-bg: rgba(255, 255, 255, 0.05);
    --glass-bg: rgba(255, 255, 255, 0.1);
    --border-color: rgba(255, 255, 255, 0.1);
}

* {
    font-family: 'Inter', sans-serif;
}

body {
    background: var(--dark-bg);
    min-height: 100vh;
    color: #e0e0e0;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(ellipse at top left, rgba(102, 126, 234, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at bottom right, rgba(118, 75, 162, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at center, rgba(245, 175, 25, 0.05) 0%, transparent 70%);
    pointer-events: none;
    z-index: -1;
}

/* =====================================================
   NAVBAR
   ===================================================== */
.navbar {
    background: rgba(15, 15, 26, 0.9) !important;
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.4rem;
    background: var(--gold-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.navbar-brand i {
    background: var(--gold-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-link {
    color: rgba(255, 255, 255, 0.7) !important;
    font-weight: 500;
    transition: all 0.3s ease;
    padding: 0.5rem 1rem !important;
    border-radius: 8px;
    margin: 0 0.25rem;
}

.nav-link:hover,
.nav-link.active {
    color: #fff !important;
    background: var(--glass-bg);
}

/* =====================================================
   CARDS
   ===================================================== */
.card {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    transition: all 0.3s ease;
}

.card:hover {
    transform: translateY(-2px);
    border-color: rgba(102, 126, 234, 0.3);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.card-header {
    background: transparent;
    border-bottom: 1px solid var(--border-color);
    font-weight: 600;
}

/* =====================================================
   STAT CARDS
   ===================================================== */
.stat-card {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 1.5rem;
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--primary-gradient);
}

.stat-card.gold::before {
    background: var(--gold-gradient);
}

.stat-card.success::before {
    background: var(--success-gradient);
}

.stat-card.danger::before {
    background: var(--danger-gradient);
}

.stat-card .stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    background: var(--primary-gradient);
    color: white;
}

.stat-card.gold .stat-icon {
    background: var(--gold-gradient);
}

.stat-card.success .stat-icon {
    background: var(--success-gradient);
}

.stat-card.danger .stat-icon {
    background: var(--danger-gradient);
}

.stat-card .stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: #fff !important;
    -webkit-text-fill-color: #fff;
}

.stat-card.gold .stat-value {
    color: #f5af19 !important;
    -webkit-text-fill-color: #f5af19;
}

.stat-card.success .stat-value {
    color: #38ef7d !important;
    -webkit-text-fill-color: #38ef7d;
}

/* =====================================================
   BUTTONS
   ===================================================== */
.btn-primary {
    background: var(--primary-gradient);
    border: none;
    border-radius: 12px;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.4);
}

.btn-gold {
    background: var(--gold-gradient);
    border: none;
    border-radius: 12px;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    color: white;
    transition: all 0.3s ease;
}

.btn-gold:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(245, 175, 25, 0.4);
    color: white;
}

.btn-success {
    background: var(--success-gradient);
    border: none;
    border-radius: 12px;
}

.btn-danger {
    background: var(--danger-gradient);
    border: none;
    border-radius: 12px;
}

.btn-outline-light {
    border-radius: 12px;
    border-color: var(--border-color);
}

.btn-outline-light:hover {
    background: var(--glass-bg);
    border-color: rgba(255, 255, 255, 0.3);
}

/* =====================================================
   TABLES - Dark Theme Override
   ===================================================== */
.table {
    color: #e0e0e0 !important;
    --bs-table-bg: transparent !important;
    --bs-table-color: #e0e0e0 !important;
    --bs-table-striped-bg: transparent !important;
    --bs-table-striped-color: #e0e0e0 !important;
    --bs-table-hover-bg: rgba(255, 255, 255, 0.05) !important;
    --bs-table-hover-color: #fff !important;
    background-color: transparent !important;
}

.table> :not(caption)>*>* {
    background-color: transparent !important;
    color: #e0e0e0 !important;
    border-bottom-color: rgba(255, 255, 255, 0.1) !important;
}

.table thead {
    background: rgba(255, 255, 255, 0.08) !important;
}

.table thead th {
    background: rgba(255, 255, 255, 0.08) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.15) !important;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
    color: rgba(255, 255, 255, 0.7) !important;
    padding: 1rem !important;
}

.table tbody tr {
    background: transparent !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
    transition: all 0.3s ease;
}

.table tbody tr:hover {
    background: rgba(255, 255, 255, 0.05) !important;
}

.table tbody tr:hover>* {
    background: transparent !important;
}

.table td,
.table th {
    vertical-align: middle;
    border: none !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
    background: transparent !important;
    padding: 0.875rem 1rem !important;
}

.table-responsive {
    background: transparent !important;
    border-radius: 0 0 16px 16px;
}

/* Table separator rows */
.table-separator td,
.table tbody tr.table-separator td {
    background: rgba(255, 255, 255, 0.03) !important;
    padding: 0 !important;
    height: 8px !important;
    border: none !important;
}

/* Table hover override */
.table-hover>tbody>tr:hover>* {
    background-color: transparent !important;
    --bs-table-accent-bg: transparent !important;
}

/* =====================================================
   FORMS
   ===================================================== */
.form-control,
.form-select {
    background: rgba(255, 255, 255, 0.08) !important;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    color: #fff !important;
    padding: 0.75rem 1rem;
    transition: all 0.3s ease;
}

.form-control:focus,
.form-select:focus {
    background: rgba(255, 255, 255, 0.12) !important;
    border-color: rgba(102, 126, 234, 0.5);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
    color: #fff !important;
}

.form-control::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.form-select {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23ffffff' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e") !important;
    background-repeat: no-repeat !important;
    background-position: right 0.75rem center !important;
    background-size: 16px 12px !important;
}

.form-select option,
.form-select optgroup {
    background: #1a1a2e !important;
    color: #fff !important;
    padding: 10px;
}

.form-label {
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 0.5rem;
}

.input-group-text {
    background: rgba(255, 255, 255, 0.08) !important;
    border: 1px solid var(--border-color);
    color: rgba(255, 255, 255, 0.6);
}

/* =====================================================
   MODALS
   ===================================================== */
.modal-content {
    background: rgba(15, 15, 26, 0.98);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-color);
    border-radius: 20px;
}

.modal-header {
    border-bottom: 1px solid var(--border-color);
}

.modal-footer {
    border-top: 1px solid var(--border-color);
}

.btn-close {
    filter: invert(1);
}

/* =====================================================
   BALANCE CARD
   ===================================================== */
.balance-card {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.2) 0%, rgba(118, 75, 162, 0.2) 100%);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(102, 126, 234, 0.3);
    border-radius: 20px;
    padding: 2rem;
}

.balance-card h4 {
    background: var(--gold-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 700;
}

/* =====================================================
   CUSTOMER ITEMS
   ===================================================== */
.customer-item {
    background: var(--glass-bg);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 1.25rem;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.customer-item:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(102, 126, 234, 0.3);
    transform: translateX(5px);
}

.customer-avatar {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: var(--primary-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.2rem;
    color: white;
}

/* =====================================================
   BADGES
   ===================================================== */
.badge {
    border-radius: 8px;
    padding: 0.5rem 0.75rem;
    font-weight: 500;
}

.badge.bg-alacak {
    background: var(--success-gradient) !important;
}

.badge.bg-borc {
    background: var(--danger-gradient) !important;
}

/* =====================================================
   ALERTS
   ===================================================== */
.alert {
    border-radius: 12px;
    border: none;
}

.alert-success {
    background: rgba(17, 153, 142, 0.2);
    color: #38ef7d;
}

.alert-danger {
    background: rgba(255, 65, 108, 0.2);
    color: #ff6b6b;
}

.alert-warning {
    background: rgba(245, 175, 25, 0.2);
    color: #f5af19;
}

/* =====================================================
   LOGIN PAGE
   ===================================================== */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-card {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 3rem;
    width: 100%;
    max-width: 420px;
}

.login-logo {
    width: 80px;
    height: 80px;
    background: var(--gold-gradient);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    margin: 0 auto 1.5rem;
}

/* =====================================================
   ANIMATIONS
   ===================================================== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.5s ease-out forwards;
}

.fade-in-delay-1 {
    animation-delay: 0.1s;
    opacity: 0;
}

.fade-in-delay-2 {
    animation-delay: 0.2s;
    opacity: 0;
}

.fade-in-delay-3 {
    animation-delay: 0.3s;
    opacity: 0;
}

@keyframes pulse {

    0%,
    100% {
        box-shadow: 0 10px 40px rgba(245, 175, 25, 0.3);
    }

    50% {
        box-shadow: 0 10px 50px rgba(245, 175, 25, 0.5);
    }
}

/* =====================================================
   RESPONSIVE
   ===================================================== */
@media (max-width: 768px) {
    .stat-card .stat-value {
        font-size: 1.5rem;
    }

    .login-card {
        margin: 1rem;
        padding: 2rem;
    }

    .navbar-brand {
        font-size: 1.1rem;
    }

    .balance-card {
        padding: 1.5rem;
    }
}

/* =====================================================
   SCROLLBAR
   ===================================================== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}