:root {
    --primary: #000000;
    --secondary: #1a1a1a;
    --accent: #fbc318;
    --success: #27ae60;
    --danger: #e74c3c;
    --warning: #fbc318;
    --bg-light: #f4f4f4;
    --text-main: #000000;
    --text-muted: #666666;
    --white: #ffffff;
    --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Roboto, sans-serif;
    -webkit-tap-highlight-color: transparent;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

body {
    background: linear-gradient(135deg, #fbc318 0%, #000000 100%);
    background-attachment: fixed;
    color: var(--text-main);
    line-height: 1.5;
}

.screen {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Login Styles */
#loginScreen {
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.login-container {
    background: var(--white);
    padding: 40px 30px;
    border-radius: 20px;
    width: 100%;
    max-width: 400px;
    box-shadow: 0 20px 25px -5px rgb(0 0 0 / 0.3);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.logo {
    margin-bottom: 30px;
}

.logo img {
    width: 150px;
    height: auto;
    margin: 0 auto 15px auto;
    display: block;
}

.logo h1 {
    font-size: 1.5rem;
    color: var(--primary);
    letter-spacing: 0.5px;
    font-weight: 800;
}

.logo p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.input-group {
    position: relative;
    margin-bottom: 20px;
}

.input-group i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

.input-group input {
    width: 100%;
    padding: 15px 15px 15px 45px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.3s;
}

.input-group input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(251, 195, 24, 0.2);
}

#loginBtn {
    width: 100%;
    padding: 15px;
    background-color: var(--primary);
    color: var(--accent);
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    border: 1px solid var(--accent);
}

#loginBtn:hover {
    background-color: var(--accent);
    color: var(--primary);
}

/* Dashboard Styles */
header {
    background-color: var(--primary);
    color: var(--accent);
    padding: 15px 20px;
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 2px solid var(--accent);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 800px;
    margin: 0 auto;
}

.user-info span {
    display: block;
    font-weight: 700;
}

.user-info small {
    color: var(--white);
    opacity: 0.8;
}

.header-logo {
    height: 35px;
    width: auto;
    object-fit: contain;
}

#logoutBtn {
    background: rgba(251, 195, 24, 0.2);
    border: 1px solid var(--accent);
    color: var(--accent);
    width: 40px;
    height: 40px;
    border-radius: 10px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
}

main {
    padding: 20px;
    max-width: 800px;
    margin: 0 auto;
    width: 100%;
}

.status-banner {
    background: var(--white);
    padding: 10px 15px;
    border-radius: 12px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.85rem;
    font-weight: 500;
    box-shadow: var(--shadow);
}

.status-banner.open { border-left: 4px solid var(--success); }
.status-banner.closed { border-left: 4px solid var(--warning); }

.hero-card {
    background: linear-gradient(135deg, #1a1a1a 0%, #000000 100%);
    color: var(--accent);
    padding: 30px;
    border-radius: 24px;
    margin-bottom: 20px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(251, 195, 24, 0.3);
}

.hero-card h3 {
    font-size: 0.9rem;
    opacity: 0.9;
    font-weight: 400;
    margin-bottom: 10px;
}

.main-value {
    font-size: 2.8rem;
    font-weight: 800;
    margin-bottom: 15px;
}

.sub-values {
    display: flex;
    gap: 20px;
}

.sub-values span {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
}

.card-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 20px;
}

.mini-card {
    background: var(--white);
    padding: 20px;
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    box-shadow: var(--shadow);
}

.mini-card i {
    font-size: 1.5rem;
}

.card-info label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
}

.card-info span {
    font-size: 1.25rem;
    font-weight: 700;
}

.highlight-green i { color: var(--success); }
.highlight-blue i { color: #2563eb; }

.details-section {
    background: var(--white);
    padding: 20px;
    border-radius: 20px;
    box-shadow: var(--shadow);
}

.details-section h4 {
    margin-bottom: 15px;
    font-size: 1rem;
    color: var(--text-muted);
}

.detail-row {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid #f1f5f9;
}

.detail-row:last-child { border-bottom: none; }

.detail-row span {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.95rem;
}

.text-green { color: var(--success); }
.text-red { color: var(--danger); }
.text-orange { color: var(--warning); }

.floating-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--accent);
    color: var(--primary);
    border: none;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.4);
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2rem;
    cursor: pointer;
    z-index: 99;
    border: 1px solid var(--primary);
}

.loader-overlay {
    position: fixed;
    inset: 0;
    background: var(--white);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@media (min-width: 600px) {
    main { 
        padding: 40px 20px;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 20px;
        align-items: start;
    }
    
    .hero-card {
        grid-column: span 2;
    }
    
    .status-banner {
        grid-column: span 2;
    }
}

@media (min-width: 900px) {
    .header-content, main {
        max-width: 1000px;
    }
}
