/* Auth Pages CSS — login.html & register.html */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&display=swap');

:root {
    --primary: #e07b39;
    --primary-dark: #c4612a;
    --primary-light: #f4a261;
    --dark: #1a0a00;
    --card-bg: rgba(255, 255, 255, 0.07);
    --border: rgba(255, 255, 255, 0.15);
    --text-light: rgba(255, 255, 255, 0.75);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Outfit', sans-serif;
    min-height: 100vh;
    background: linear-gradient(135deg, #1a0800 0%, #2d1200 40%, #1a0a05 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow-x: hidden;
}

/* Background decorative orbs */
body::before {
    content: '';
    position: fixed;
    top: -20%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(224,123,57,0.18) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}
body::after {
    content: '';
    position: fixed;
    bottom: -20%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(196,97,42,0.14) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

/* Logo */
.auth-logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-light);
    text-decoration: none;
    letter-spacing: 1px;
    margin-bottom: 2rem;
    display: inline-block;
    text-shadow: 0 0 30px rgba(224,123,57,0.4);
}

/* Auth Card */
.auth-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 24px;
    padding: 2.5rem 2.2rem;
    width: 100%;
    max-width: 440px;
    box-shadow: 0 24px 60px rgba(0,0,0,0.5);
    position: relative;
    z-index: 1;
}

.auth-card h1 {
    font-size: 1.7rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.3rem;
}

.auth-card .subtitle {
    color: var(--text-light);
    font-size: 0.95rem;
    margin-bottom: 1.8rem;
}

/* Form groups */
.form-group {
    margin-bottom: 1.2rem;
    position: relative;
}

.form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-light);
    margin-bottom: 0.4rem;
}

.form-group input {
    width: 100%;
    padding: 0.8rem 1rem;
    background: rgba(255,255,255,0.06);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: #fff;
    font-size: 0.95rem;
    font-family: 'Outfit', sans-serif;
    outline: none;
    transition: all 0.3s ease;
}

.form-group input::placeholder {
    color: rgba(255,255,255,0.3);
}

.form-group input:focus {
    border-color: var(--primary);
    background: rgba(224,123,57,0.07);
    box-shadow: 0 0 0 3px rgba(224,123,57,0.15);
}

/* Password toggle */
.input-wrapper {
    position: relative;
}

.toggle-pw {
    position: absolute;
    right: 0.9rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-light);
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
}

/* Submit button */
.btn-auth {
    width: 100%;
    padding: 0.9rem;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #fff;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    font-family: 'Outfit', sans-serif;
    cursor: pointer;
    margin-top: 0.5rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-auth:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(224,123,57,0.4);
}

.btn-auth:active { transform: translateY(0); }

.btn-auth:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.btn-auth .spinner {
    display: none;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255,255,255,0.4);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
    margin: 0 auto;
}

.btn-auth.loading .spinner { display: inline-block; }
.btn-auth.loading .btn-text { display: none; }

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Divider */
.auth-divider {
    text-align: center;
    color: var(--text-light);
    font-size: 0.85rem;
    margin: 1.3rem 0;
    position: relative;
}

.auth-divider::before, .auth-divider::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 38%;
    height: 1px;
    background: var(--border);
}
.auth-divider::before { left: 0; }
.auth-divider::after { right: 0; }

/* Switch link */
.auth-switch {
    text-align: center;
    color: var(--text-light);
    font-size: 0.9rem;
    margin-top: 1.2rem;
}

.auth-switch a {
    color: var(--primary-light);
    text-decoration: none;
    font-weight: 600;
}

.auth-switch a:hover { text-decoration: underline; }

/* Alert messages */
.auth-alert {
    padding: 0.75rem 1rem;
    border-radius: 10px;
    font-size: 0.88rem;
    margin-bottom: 1rem;
    display: none;
    animation: fadeIn 0.3s ease;
}

.auth-alert.error {
    background: rgba(220, 53, 69, 0.15);
    border: 1px solid rgba(220, 53, 69, 0.35);
    color: #ff8080;
    display: block;
}

.auth-alert.success {
    background: rgba(40, 167, 69, 0.15);
    border: 1px solid rgba(40, 167, 69, 0.35);
    color: #80e080;
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-6px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Name row (two columns for register) */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.8rem;
}

@media (max-width: 480px) {
    .auth-card {
        padding: 2rem 1.4rem;
        margin: 1rem;
        max-width: 100%;
        border-radius: 20px;
    }
    .form-row { grid-template-columns: 1fr; }
}
