:root {
    --gradient: linear-gradient(to top right, #4eaa38, #5eebd8, #3f8bee, #365e8e);
    --primary-color: #4eaa38;
    --secondary-color: #5eebd8;
    --accent-color: #3f8bee;
    --dark-color: #365e8e;
}

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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--gradient);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-container {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    width: 100%;
    max-width: 400px;
    padding: 2rem;
    margin: 1rem;
}

.dashboard-container {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    width: 100%;
    max-width: 1200px;
    padding: 2rem;
    margin: 1rem;
    min-height: 80vh;
}

.brand {
    text-align: center;
    margin-bottom: 2rem;
}

.brand h1 {
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.brand p {
    color: #666;
    font-size: 0.9rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-control {
    border: 2px solid #e1e5e9;
    border-radius: 10px;
    padding: 12px 16px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.8);
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(78, 170, 56, 0.25);
    outline: none;
    background: white;
}

.btn-primary {
    background: var(--gradient);
    border: none;
    border-radius: 12px;
    padding: 14px 28px;
    font-size: 1rem;
    font-weight: 600;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
}

.btn-generate {
    background: linear-gradient(45deg, #ff6b6b, #ee5a24);
    font-size: 1.1rem;
    padding: 16px 32px;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(255, 107, 107, 0.3);
}

.btn-generate:hover {
    box-shadow: 0 12px 35px rgba(255, 107, 107, 0.4);
    transform: translateY(-4px);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.8);
    border: 2px solid var(--primary-color);
    border-radius: 10px;
    padding: 10px 20px;
    color: var(--primary-color);
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 0 5px;
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: white;
}

.btn-danger {
    background: #dc3545;
    border: none;
    border-radius: 10px;
    padding: 10px 20px;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.auth-links {
    text-align: center;
    margin-top: 1.5rem;
}

.auth-links a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
}

.auth-links a:hover {
    text-decoration: underline;
}

.auth-footer {
    text-align: center;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.footer-link {
    color: #666;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 400;
}

.footer-link:hover {
    color: var(--primary-color);
    text-decoration: underline;
}

.copyright {
    margin-top: 0.5rem;
    font-size: 0.75rem;
    color: #999;
    text-align: center;
}

.dashboard-copyright {
    position: fixed;
    bottom: 80px;
    left: 0;
    right: 0;
    text-align: center;
    font-size: 0.7rem;
    color: #999;
    padding: 0.5rem;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(5px);
    z-index: 999;
}

.alert {
    padding: 12px 16px;
    border-radius: 10px;
    margin-bottom: 1rem;
    font-weight: 500;
}

.alert-success {
    background: rgba(78, 170, 56, 0.1);
    color: var(--primary-color);
    border: 1px solid rgba(78, 170, 56, 0.3);
}

.alert-danger {
    background: rgba(220, 53, 69, 0.1);
    color: #dc3545;
    border: 1px solid rgba(220, 53, 69, 0.3);
}

.card {
    background: rgba(255, 255, 255, 0.8);
    border-radius: 15px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.token-display {
    background: var(--gradient);
    color: white;
    padding: 2rem;
    border-radius: 20px;
    margin: 2rem 0;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
}

.token-display::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: var(--gradient);
    border-radius: 22px;
    z-index: -1;
    animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
    from { box-shadow: 0 0 20px rgba(94, 235, 216, 0.3); }
    to { box-shadow: 0 0 30px rgba(94, 235, 216, 0.6); }
}

.token-number {
    font-family: 'Courier New', monospace;
    font-size: 3rem;
    font-weight: bold;
    letter-spacing: 0.5rem;
    margin: 1rem 0;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.token-label {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 1rem;
    opacity: 0.9;
}

.token-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.countdown-display {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
}

.countdown-icon {
    width: 20px;
    height: 20px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
}

.gateway-item {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border-left: 5px solid var(--primary-color);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.gateway-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.15);
    border-left-color: var(--secondary-color);
}

.header {
    background: var(--gradient);
    color: white;
    padding: 1rem 0;
    border-radius: 15px;
    margin-bottom: 2rem;
    text-align: center;
}

.nav-tabs {
    background: rgba(255, 255, 255, 0.8);
    border-radius: 10px;
    padding: 0.5rem;
    margin-bottom: 2rem;
}

.nav-tab {
    background: transparent;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: #666;
    font-weight: 500;
}

.nav-tab.active {
    background: var(--gradient);
    color: white;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

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

.hidden {
    display: none !important;
}

.loading {
    text-align: center;
    padding: 2rem;
    color: #666;
}

.countdown {
    font-weight: bold;
    color: var(--accent-color);
}

.pin-input {
    font-family: 'Courier New', monospace;
    font-size: 1.5rem;
    text-align: center;
    letter-spacing: 0.5rem;
    font-weight: bold;
}

.pin-input:focus {
    letter-spacing: 0.5rem;
    font-size: 1.5rem;
}

.user-welcome {
    text-align: center;
    margin-bottom: 2rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}

/* Bottom Navigation */
.dashboard {
    position: relative;
    padding-bottom: 100px; /* Make space for bottom nav */
}

.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 0.5rem 0;
    box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0.5rem 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 15px;
    min-width: 70px;
}

.nav-item:hover {
    background: rgba(78, 170, 56, 0.1);
    transform: translateY(-2px);
}

.nav-item.active {
    background: var(--gradient);
    color: white;
    box-shadow: 0 5px 15px rgba(78, 170, 56, 0.3);
}

.nav-icon {
    font-size: 1.5rem;
    margin-bottom: 0.25rem;
    transition: all 0.3s ease;
}

.nav-label {
    font-size: 0.75rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.nav-item.active .nav-icon {
    transform: scale(1.1);
}

.nav-item.active .nav-label {
    font-weight: 600;
}

/* Remove old nav tabs styles */
.nav-tabs {
    display: none;
}

@media (max-width: 768px) {
    .dashboard-container {
        margin: 0.5rem;
        padding: 1rem;
        padding-bottom: 2rem;
    }
    
    .brand h1 {
        font-size: 2rem;
    }
    
    .token-number {
        font-size: 2.5rem;
        letter-spacing: 0.3rem;
    }
    
    .token-footer {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
    
    .btn-generate {
        padding: 14px 24px;
        font-size: 1rem;
    }
    
    .gateway-item {
        padding: 1rem;
    }
    
    .gateway-item .d-flex {
        flex-direction: column;
        gap: 1rem;
    }
    
    .gateway-item .text-end {
        text-align: center !important;
    }
    
    .nav-item {
        min-width: 60px;
        padding: 0.4rem 0.8rem;
    }
    
    .nav-icon {
        font-size: 1.3rem;
    }
    
    .nav-label {
        font-size: 0.7rem;
    }
}