* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Loading Spinner Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    opacity: 1;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loading-overlay.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.spinner-container {
    text-align: center;
}

.spinner {
    width: 60px;
    height: 60px;
    border: 5px solid rgba(61, 122, 31, 0.2);
    border-top-color: #3d7a1f;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.loading-text {
    color: #3d7a1f;
    font-size: 1.2rem;
    font-weight: bold;
    letter-spacing: 1px;
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 50%, #1a1a1a 100%);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    position: relative;
}

/* Admin Settings Button */
.admin-btn {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #3d7a1f 0%, #2d5016 100%);
    border: 2px solid rgba(61, 122, 31, 0.5);
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(61, 122, 31, 0.4);
    transition: all 0.3s ease;
    z-index: 1000;
}

.admin-btn:hover {
    transform: rotate(90deg) scale(1.1);
    box-shadow: 0 6px 25px rgba(61, 122, 31, 0.7);
}

.admin-btn:active {
    transform: rotate(90deg) scale(0.95);
}

.admin-btn svg {
    animation: rotate 8s linear infinite;
}

.admin-btn:hover svg {
    animation-play-state: paused;
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.container {
    width: 100%;
    max-width: 1400px;
    display: flex;
    gap: 50px;
    align-items: center;
    justify-content: center;
}

/* Stats Panel */
.stats-panel {
    flex: 0 0 420px;
    background: rgba(30, 30, 30, 0.95);
    border-radius: 20px;
    padding: 30px;
    border: 2px solid rgba(61, 122, 31, 0.3);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8), 0 0 40px rgba(61, 122, 31, 0.3);
    animation: slideInLeft 0.6s ease-out;
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.stats-panel h3 {
    color: #3d7a1f;
    font-size: 1.8rem;
    margin-bottom: 25px;
    text-align: center;
    text-shadow: 0 0 20px rgba(61, 122, 31, 0.5);
}

.stat-item {
    display: flex;
    gap: 15px;
    padding: 20px;
    margin-bottom: 15px;
    background: rgba(61, 122, 31, 0.1);
    border-radius: 15px;
    border: 1px solid rgba(61, 122, 31, 0.2);
    transition: all 0.3s ease;
    animation: fadeInUp 0.5s ease-out backwards;
}

.stat-item:nth-child(2) { animation-delay: 0.1s; }
.stat-item:nth-child(3) { animation-delay: 0.2s; }
.stat-item:nth-child(4) { animation-delay: 0.3s; }
.stat-item:nth-child(5) { animation-delay: 0.4s; }

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.stat-item:hover {
    background: rgba(61, 122, 31, 0.2);
    border-color: rgba(61, 122, 31, 0.4);
    transform: translateX(5px);
}

.stat-icon {
    font-size: 2rem;
    line-height: 1;
}

.stat-content {
    flex: 1;
}

.stat-label {
    color: #b0b0b0;
    font-size: 0.9rem;
    margin-bottom: 5px;
}

.stat-numbers {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 5px;
}

.stat-before {
    color: #888;
    font-size: 1rem;
}

.stat-arrow {
    color: #3d7a1f;
    font-weight: bold;
}

.stat-after {
    color: #3d7a1f;
    font-size: 1.3rem;
    font-weight: bold;
}

.stat-time {
    color: #666;
    font-size: 0.85rem;
}

.total-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-top: 25px;
    padding-top: 25px;
    border-top: 2px solid rgba(61, 122, 31, 0.2);
}

.total-stat {
    text-align: center;
    padding: 15px;
    background: rgba(61, 122, 31, 0.1);
    border-radius: 10px;
    border: 1px solid rgba(61, 122, 31, 0.2);
}

.total-stat strong {
    display: block;
    color: #3d7a1f;
    font-size: 1.5rem;
    margin-bottom: 5px;
}

.total-stat span {
    color: #b0b0b0;
    font-size: 0.85rem;
}

@media (max-width: 1024px) {
    .container {
        flex-direction: column;
        max-width: 450px;
    }
    
    .stats-panel {
        flex: 1;
        width: 100%;
    }
    
    .login-box {
        flex: 1;
    }
    
    .switch-text {
        margin-top: 25px;
        margin-bottom: 25px;
        padding: 10px;
    }
}

.login-box {
    flex: 0 0 520px;
    background: rgba(30, 30, 30, 0.95);
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8), 0 0 40px rgba(61, 122, 31, 0.3);
    overflow: hidden;
    animation: slideIn 0.5s ease-out;
    border: 2px solid rgba(61, 122, 31, 0.3);
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.logo {
    background: linear-gradient(135deg, #1a1a1a 0%, #0a0a0a 100%);
    color: white;
    text-align: center;
    padding: 40px 20px;
    border-bottom: 3px solid #3d7a1f;
}

.credits {
    margin-bottom: 20px;
    font-size: 0.75rem;
    opacity: 0.6;
    line-height: 1.4;
}

.credits p {
    margin: 3px 0;
    color: #aaa;
}

.logo h1 {
    font-family: 'Creepster', cursive;
    font-size: 3rem;
    font-weight: normal;
    letter-spacing: 5px;
    margin-bottom: 20px;
    color: #3d7a1f;
    text-shadow: 
        0 0 15px rgba(61, 122, 31, 0.9),
        2px 2px 5px rgba(0, 0, 0, 0.9),
        0 5px 10px rgba(61, 122, 31, 0.5);
}

.tagline {
    font-size: 1rem;
    opacity: 0.9;
    letter-spacing: 1px;
}

.form-container {
    padding: 40px;
    position: relative;
    background: rgba(20, 20, 20, 0.5);
}

.auth-form {
    display: none;
    animation: fadeIn 0.3s ease-in;
}

.auth-form.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.auth-form h2 {
    color: #e0e0e0;
    margin-bottom: 30px;
    font-size: 1.8rem;
    text-align: center;
    text-shadow: 0 0 10px rgba(61, 122, 31, 0.5);
}

.input-group {
    margin-bottom: 25px;
}

.input-group label {
    display: block;
    color: #b0b0b0;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.input-group input {
    width: 100%;
    padding: 14px;
    border: 2px solid #3a3a3a;
    border-radius: 10px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #2a2a2a;
    color: #e0e0e0;
}

.input-group input:focus {
    outline: none;
    border-color: #3d7a1f;
    background: #1a1a1a;
    box-shadow: 0 0 0 3px rgba(61, 122, 31, 0.2), 0 0 15px rgba(61, 122, 31, 0.3);
}

.input-group input::placeholder {
    color: #666;
}

.btn {
    width: 100%;
    padding: 15px;
    border: none;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn-primary {
    background: linear-gradient(135deg, #3d7a1f 0%, #2d5016 100%);
    color: white;
    margin-top: 10px;
    box-shadow: 0 4px 15px rgba(61, 122, 31, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(61, 122, 31, 0.6), 0 0 20px rgba(61, 122, 31, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

.switch-text {
    text-align: center;
    margin-top: 25px;
    color: #888;
    font-size: 0.95rem;
}

.switch-text a {
    color: #3d7a1f;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

.switch-text a:hover {
    color: #4d9a27;
    text-decoration: underline;
    text-shadow: 0 0 8px rgba(61, 122, 31, 0.5);
}

/* Responsive Design */
@media (max-width: 480px) {
    .logo h1 {
        font-size: 2rem;
    }
    
    .form-container {
        padding: 30px 25px;
    }
    
    .auth-form h2 {
        font-size: 1.5rem;
    }
    
    .switch-text {
        margin-top: 20px;
        margin-bottom: 20px;
        font-size: 0.9rem;
        padding: 10px;
    }
    
    .switch-text a {
        display: inline-block;
        padding: 5px 10px;
        font-size: 1rem;
    }
}
