/**
 * Shared styles for authentication pages (login, register)
 */

/* Auth Page Layout */
.auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(46, 139, 87, 0.9), rgba(70, 130, 180, 0.9)),
                url('../background.jpg') center/cover;
    padding: 20px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.auth-container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    padding: 50px 40px;
    max-width: 450px;
    width: 100%;
    animation: slideUp 0.5s ease-out;
}

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

/* Header */
.auth-header {
    text-align: center;
    margin-bottom: 40px;
}

.auth-logo {
    font-size: 2rem;
    font-weight: bold;
    color: #2E8B57;
    margin-bottom: 10px;
}

.auth-title {
    font-size: 1.8rem;
    color: #333;
    margin-bottom: 10px;
}

.auth-subtitle {
    color: #666;
    font-size: 0.95rem;
}

/* Form */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    position: relative;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 500;
    font-size: 0.9rem;
}

.form-input {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.form-input:focus {
    outline: none;
    border-color: #4caf50;
    box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.1);
}

.form-input.field-error {
    border-color: #f44336;
}

.field-error-message {
    color: #f44336;
    font-size: 0.85rem;
    margin-top: 5px;
    display: block;
}

/* Button */
.auth-button {
    background: linear-gradient(135deg, #4caf50, #2E8B57);
    color: white;
    padding: 16px;
    border: none;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
}

.auth-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(46, 139, 87, 0.3);
}

.auth-button:active {
    transform: translateY(0);
}

.auth-button:disabled,
.auth-button.button-loading {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

/* Links */
.auth-links {
    text-align: center;
    margin-top: 25px;
    color: #666;
    font-size: 0.95rem;
}

.auth-link {
    color: #4682b4;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s;
}

.auth-link:hover {
    color: #2E8B57;
    text-decoration: underline;
}

/* Notifications */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    min-width: 300px;
    max-width: 500px;
    padding: 16px 20px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 10000;
    opacity: 0;
    transform: translateX(400px);
    transition: all 0.3s ease;
}

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

.notification-hide {
    opacity: 0;
    transform: translateX(400px);
}

.notification-error {
    background: #f44336;
    color: white;
}

.notification-success {
    background: #4caf50;
    color: white;
}

.notification-info {
    background: #2196F3;
    color: white;
}

.notification-icon {
    font-size: 1.5rem;
}

.notification-message {
    flex: 1;
    font-size: 0.95rem;
}

.notification-close {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.notification-close:hover {
    opacity: 1;
}

/* Loading Overlay */
.loader-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.loader-content {
    text-align: center;
    color: white;
}

.spinner {
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid white;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loader-message {
    font-size: 1.1rem;
    margin: 0;
}

/* Responsive */
@media (max-width: 768px) {
    .auth-container {
        padding: 40px 25px;
    }
    
    .auth-title {
        font-size: 1.5rem;
    }
    
    .notification {
        min-width: auto;
        max-width: calc(100% - 40px);
        right: 20px;
        left: 20px;
    }
}
