/* Premium Aesthetic Overhaul for CB Brand */
@import url('https://fonts.googleapis.com/css2?family=Syncopate:wght@700&family=Outfit:wght@300;400;500;600;700;800&display=swap');

:root {
    --primary: #080808;
    --primary-light: #121212;
    --accent: #d4af37;
    --accent-gradient: linear-gradient(135deg, #d4af37 0%, #f1d573 50%, #b8860b 100%);
    --bg-main: #f8f9fa;
    --card-shadow: 0 4px 12px rgba(0,0,0,0.02), 0 20px 40px rgba(0,0,0,0.04);
    --glass: rgba(255, 255, 255, 0.7);
    --glass-border: 1px solid rgba(255, 255, 255, 0.2);
    --success: #10b981;
    --danger: #ef4444;
    --text-main: #0a0a0a;
    --text-light: #64748b;
}

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

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg-main); }
::-webkit-scrollbar-thumb { background: #e2e8f0; border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: #cbd5e1; }

.main-content {
    margin-left: 280px;
    padding: 40px;
    min-height: 100vh;
    animation: fadeIn 0.6s ease-out;
}

.sidebar {
    width: 280px;
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    background: var(--primary);
    color: #fff;
    padding: 30px;
    z-index: 1000;
}

.sidebar-brand h2 {
    font-family: 'Syncopate', sans-serif;
    font-size: 1.2rem;
    letter-spacing: 4px;
    margin-bottom: 5px;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-link {
    display: flex;
    align-items: center;
    padding: 14px 18px;
    color: rgba(255,255,255,0.6);
    text-decoration: none;
    border-radius: 12px;
    margin-bottom: 8px;
    transition: 0.3s;
    font-weight: 500;
}

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

.nav-link svg { margin-right: 12px; stroke: currentColor; }

/* Cards & Containers */
.card, .stat-card {
    background: #fff;
    border-radius: 20px;
    padding: 30px;
    border: var(--glass-border);
    box-shadow: var(--card-shadow);
    transition: 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.card:hover, .stat-card:hover { border-color: var(--accent); }

.stat-card h3 { font-size: 0.85rem; color: var(--text-light); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 12px; }
.stat-card h2 { font-size: 2rem; font-weight: 800; color: var(--primary); }

/* Buttons */
.btn {
    padding: 14px 28px;
    border-radius: 14px;
    font-weight: 700;
    font-size: 0.85rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    transition: 0.3s;
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background: var(--accent-gradient);
    color: #000;
    box-shadow: 0 10px 20px rgba(212, 175, 55, 0.2);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(212, 175, 55, 0.3);
}

.btn-secondary {
    background: #fff;
    color: var(--text-main);
    border: 1px solid #e2e8f0;
}

.btn-secondary:hover { background: #f8fafc; }

/* Form Elements */
.form-control {
    width: 100%;
    padding: 16px 20px;
    border: 1.5px solid #e2e8f0;
    border-radius: 14px;
    font-family: inherit;
    font-size: 0.95rem;
    transition: 0.3s;
}

.form-control:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 4px rgba(212, 175, 55, 0.1);
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}

.glass {
    background: var(--glass);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
}

/* --- Login Page --- */
.login-bg { 
    background: radial-gradient(circle at top right, #1a1a1a, #000); 
    height: 100vh; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    overflow: hidden; 
}

.login-card { 
    background: rgba(255, 255, 255, 0.03); 
    backdrop-filter: blur(20px); 
    padding: 60px; 
    border-radius: 40px; 
    width: 450px; 
    border: 1px solid rgba(255, 255, 255, 0.1); 
    box-shadow: 0 40px 100px rgba(0,0,0,0.5); 
    text-align: center; 
}

.login-card h1 { 
    font-family: 'Syncopate', sans-serif; 
    font-weight: 800; 
    font-size: 2.5rem; 
    background: var(--accent); 
    -webkit-background-clip: text; 
    background-clip: text;
    -webkit-text-fill-color: transparent; 
    margin-bottom: 5px; 
}

.login-card .slogan { 
    color: #666; 
    font-size: 0.9rem; 
    letter-spacing: 3px; 
    text-transform: uppercase; 
    margin-bottom: 40px; 
}

/* --- Status Badges --- */
.badge {
    padding: 6px 14px;
    border-radius: 30px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: inline-flex;
    align-items: center;
}

.badge-success { background: rgba(16, 185, 129, 0.1); color: #10b981; }
.badge-warning { background: rgba(245, 158, 11, 0.1); color: #f59e0b; }
.badge-danger { background: rgba(239, 68, 68, 0.1); color: #ef4444; }
.badge-primary { background: rgba(212, 175, 55, 0.1); color: #d4af37; }

/* --- 58mm Receipt Styling --- */
#bill-template {
    display: none;
    width: 58mm;
    padding: 10px;
    font-family: 'Courier New', Courier, monospace;
    color: #000;
}

.bill-header { text-align: center; border-bottom: 1px dashed #000; padding-bottom: 10px; margin-bottom: 10px; }
.bill-logo { font-size: 1.2rem; font-weight: 900; }
.bill-footer { border-top: 1px dashed #000; padding-top: 10px; margin-top: 10px; }

@media print {
    @page {
        size: 58mm auto;
        margin: 0;
    }
    body * { visibility: hidden; }
    #bill-template, #bill-template * { visibility: visible; }
    #bill-template {
        display: block !important;
        position: absolute;
        left: 0;
        top: 0;
        width: 58mm;
    }
    .main-content, .sidebar, .modal { display: none !important; }
}
