/* Modern CSS Reset and Variables */
:root {
    --primary-color: #3e7bd6;
    --primary-hover: #3172d3;
    --success-color: #30b08f;
    --error-color: #ff3b30;
    --warning-color: #ff9500;
    --background: #f3f5f7;
    --surface: #ffffff;
    --text-primary: #1d1d1f;
    --text-secondary: #6b7179;
    --border: #dee1e6;
    --blur-bg: rgba(255, 255, 255, 0.7);
    --card-shadow: 0 10px 40px rgba(0, 0, 0, 0.08), 0 2px 10px rgba(0, 0, 0, 0.03);
    --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-success: linear-gradient(135deg, #30b08f, #2a9c7f);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}

body {
    background: var(--background);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
}

/* Login Page Styles */
.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
    background: var(--gradient-primary);
}

.login-form {
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 24px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1), 0 10px 20px rgba(0, 0, 0, 0.05);
    padding: 2.5rem;
    width: 100%;
    max-width: 400px;
}

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

.login-header h1 {
    color: white;
    margin-bottom: 0.5rem;
    font-size: 2.2rem;
    font-weight: 600;
}

.login-header p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1rem;
}

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

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: white;
    font-size: 0.95rem;
    font-weight: 500;
}

.form-group input[type="text"],
.form-group input[type="password"] {
    width: 100%;
    padding: 0.9rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    color: white;
}

.form-group input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.form-group input:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.6);
    background: rgba(255, 255, 255, 0.25);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.1);
}

.password-field {
    position: relative;
    display: flex;
    align-items: center;
}

.password-field input {
    padding-right: 3rem;
}

.toggle-password {
    position: absolute;
    right: 12px;
    background: none;
    border: none;
    cursor: pointer;
    color: rgba(255, 255, 255, 0.7);
    padding: 4px;
}

.toggle-password:hover {
    color: white;
}

.eye-icon {
    display: block;
}

.login-button {
    width: 100%;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 0.5rem;
}

.login-button:hover {
    background: rgba(255, 255, 255, 0.35);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

/* Main App Styles */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    background: var(--surface);
    border-radius: 20px;
    box-shadow: var(--card-shadow);
    padding: 1.5rem 2rem;
    margin-bottom: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    backdrop-filter: blur(20px);
    background: var(--blur-bg);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

header h1 {
    font-size: 1.75rem;
    font-weight: 600;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.user-info span {
    color: var(--text-secondary);
    font-weight: 500;
}

/* Form Sections */
.form-section {
    background: var(--surface);
    border-radius: 20px;
    box-shadow: var(--card-shadow);
    padding: 2rem;
    margin-bottom: 2rem;
    backdrop-filter: blur(20px);
    background: var(--blur-bg);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.form-section h2 {
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    font-size: 1.4rem;
    font-weight: 600;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.input-group {
    display: flex;
    flex-direction: column;
}

.input-group.full-width {
    grid-column: 1 / -1;
}

.input-group label {
    font-weight: 500;
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.input-group input,
.input-group select,
.input-group textarea {
    padding: 0.9rem 1rem;
    border: 1px solid var(--border);
    border-radius: 14px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
}

.input-group input:focus,
.input-group select:focus,
.input-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(62, 123, 214, 0.1);
    background: rgba(255, 255, 255, 0.9);
}

.input-group input.error,
.input-group select.error,
.input-group textarea.error {
    border-color: var(--error-color);
    box-shadow: 0 0 0 3px rgba(255, 59, 48, 0.1);
}

.field-hint {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
    font-style: italic;
}

/* Submit Section */
.submit-section {
    background: rgba(255, 255, 255, 0.5);
    padding: 1.5rem;
    border-radius: 16px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-submit {
    background: var(--gradient-success);
    color: white;
    border: none;
    padding: 1.2rem 2.5rem;
    border-radius: 16px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    box-shadow: 0 8px 25px rgba(48, 176, 143, 0.3);
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 35px rgba(48, 176, 143, 0.4);
}

.btn-submit:active {
    transform: translateY(0);
}

.btn-icon {
    font-size: 1.2rem;
    font-weight: bold;
}

.submit-hint {
    margin-top: 1rem;
    color: var(--text-secondary);
    font-size: 0.875rem;
    opacity: 0.8;
}

/* Stats Section */
.stats-section {
    background: var(--surface);
    border-radius: 20px;
    box-shadow: var(--card-shadow);
    padding: 2rem;
    backdrop-filter: blur(20px);
    background: var(--blur-bg);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.stats-section h2 {
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    font-size: 1.4rem;
    font-weight: 600;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.stat-card {
    background: rgba(255, 255, 255, 0.6);
    padding: 1.5rem;
    border-radius: 16px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
}

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

.stat-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Button Styles */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.9rem 1.8rem;
    background: var(--primary-color);
    color: white;
    text-decoration: none;
    border: none;
    border-radius: 14px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.btn:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(62, 123, 214, 0.2);
}

.btn-logout {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border);
}

.btn-logout:hover {
    background: rgba(0, 0, 0, 0.03);
}

/* Toast Notification Styles */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    max-width: 400px;
}

.toast {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 16px;
    padding: 1rem 1.5rem;
    margin-bottom: 1rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15), 0 2px 10px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.3);
    display: flex;
    align-items: center;
    gap: 1rem;
    transform: translateX(400px);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    overflow: hidden;
}

.toast.show {
    transform: translateX(0);
    opacity: 1;
}

.toast.hiding {
    transform: translateX(400px);
    opacity: 0;
}

.toast-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    width: 100%;
    background: linear-gradient(90deg, var(--toast-color), transparent);
    animation: toastProgress 5s linear forwards;
}

.toast-icon {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--toast-color);
    color: white;
    font-weight: bold;
    font-size: 0.875rem;
}

.toast-content {
    flex: 1;
}

.toast-title {
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 0.25rem;
    color: #1d1d1f;
}

.toast-message {
    font-size: 0.875rem;
    color: #6b7179;
    line-height: 1.4;
}

.toast-close {
    background: none;
    border: none;
    color: #8e8e93;
    cursor: pointer;
    padding: 0.25rem;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.toast-close:hover {
    background: rgba(0, 0, 0, 0.05);
    color: #1d1d1f;
}

/* Toast Types */
.toast-success {
    --toast-color: #30b08f;
    border-left: 4px solid #30b08f;
}

.toast-error {
    --toast-color: #ff3b30;
    border-left: 4px solid #ff3b30;
}

.toast-warning {
    --toast-color: #ff9500;
    border-left: 4px solid #ff9500;
}

.toast-info {
    --toast-color: #007aff;
    border-left: 4px solid #007aff;
}

@keyframes toastProgress {
    0% {
        width: 100%;
    }
    100% {
        width: 0%;
    }
}

/* Error Message */
.error-message {
    background: rgba(239, 68, 68, 0.2);
    backdrop-filter: blur(10px);
    color: #fecaca;
    padding: 0.75rem 1rem;
    border-radius: 10px;
    margin-bottom: 1.5rem;
    text-align: center;
    border: 1px solid rgba(254, 202, 202, 0.3);
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
        padding: 1.5rem;
    }
    
    .user-info {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .form-section,
    .stats-section {
        padding: 1.5rem;
    }
    
    .form-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .toast-container {
        top: 10px;
        right: 10px;
        left: 10px;
        max-width: none;
    }
    
    .toast {
        padding: 1rem;
    }
    
    .login-form {
        padding: 2rem 1.5rem;
    }
    
    .login-header h1 {
        font-size: 1.8rem;
    }
}

@media (max-width: 480px) {
    .btn-submit {
        width: 100%;
        padding: 1rem 1.5rem;
    }
    
    .form-section h2,
    .stats-section h2 {
        font-size: 1.2rem;
    }
    
    .stat-card h3 {
        font-size: 2rem;
    }
}


/* Logo Header Styles */
header:first-of-type {
    text-align: center;
    background: transparent !important;
    box-shadow: none !important;
    padding: 1rem 0 !important;
    border: none !important;
    backdrop-filter: none !important;
}

header:first-of-type img {
    display: block;
    margin: 0 auto;
}



/* Beautiful Footer Styles */
.main-footer {
    background: linear-gradient(135deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0.05) 100%);
    backdrop-filter: blur(20px);
    border-top: 1px solid rgba(255,255,255,0.2);
    padding: 2rem 0;
    margin-top: 3rem;
    border-radius: 24px 24px 0 0;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
    padding: 0 20px;
}

.footer-heart {
    font-size: 2rem;
    margin-bottom: 1rem;
    animation: heartbeat 2s ease-in-out infinite;
}

.footer-text {
    color: var(--text-primary);
}

.footer-main {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, var(--primary-color), #2c5aa0);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.footer-sub {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 0.25rem;
    font-weight: 500;
}

.footer-company {
    font-size: 0.85rem;
    color: var(--text-secondary);
    opacity: 0.8;
    font-style: italic;
}

@keyframes heartbeat {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* Responsive Footer */
@media (max-width: 768px) {
    .main-footer {
        padding: 1.5rem 0;
        margin-top: 2rem;
    }
    
    .footer-heart {
        font-size: 1.5rem;
    }
    
    .footer-main {
        font-size: 1rem;
    }
    
    .footer-sub {
        font-size: 0.9rem;
    }
    
    .footer-company {
        font-size: 0.8rem;
    }
}

