:root {
    --auth-bg-1: #f6f8fb;
    --auth-bg-2: #eef3f8;
    --auth-card-border: rgba(15, 23, 42, 0.10);
    --auth-text: #0f172a;
    --auth-muted: #475569;
    --primary: #0092CF;
    --primary-dark: #003359;
}

.auth-shell {
    background: linear-gradient(135deg, #0092CF 0%, #003359 50%, #001122 100%);
    padding: 4rem 1rem;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    isolation: isolate;
    pointer-events: auto;
}

.auth-shell::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 30%, rgba(255,255,255,0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(255,255,255,0.1) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

.auth-container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 450px;
    pointer-events: auto;
}

.auth-card {
    border: none;
    border-radius: 16px;
    background: white;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    position: relative;
    z-index: 2;
}

.auth-card:hover {
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
    transform: translateY(-4px);
}

.auth-card .card-body {
    padding: 3rem 2.5rem;
}

.auth-logo {
    height: 45px;
    width: auto;
    max-width: 200px;
    object-fit: contain;
    display: block;
    mix-blend-mode: multiply;
    margin-bottom: 1rem;
}

.auth-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 0.75rem;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 2px solid rgba(0, 146, 207, 0.1);
}

.auth-header > div {
    max-width: 100%;
    width: 100%;
}

.auth-brand {
    font-weight: 800;
    color: var(--primary-dark);
    line-height: 1.2;
    letter-spacing: -0.01em;
    font-size: 1.5rem;
    margin: 0;
}

.auth-subbrand {
    color: #666;
    font-size: 0.9rem;
    line-height: 1.4;
    margin: 0;
    font-weight: 500;
}

.auth-card h1 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--auth-text);
    margin-bottom: 0.5rem;
    text-align: center;
}

.auth-card > .card-body > p {
    text-align: center;
    color: #666;
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
}

.auth-card .form-control {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 0.85rem 1rem;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #fafafa;
}

.auth-card .form-control:focus {
    background: white;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(0, 146, 207, 0.1);
}

.auth-card .form-label {
    font-weight: 600;
    color: #333;
    margin-bottom: 0.6rem;
    font-size: 0.95rem;
}

.auth-card .btn.btn-primary {
    border-radius: 8px;
    padding: 0.9rem 1.5rem;
    font-weight: 600;
    font-size: 1rem;
    border: none;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    transition: all 0.3s ease;
    text-shadow: 0 1px 2px rgba(0,0,0,0.1);
    box-shadow: 0 4px 12px rgba(0, 146, 207, 0.25);
}

.auth-card .btn.btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, #0092CF 0%, #003359 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 146, 207, 0.35);
}

.auth-card .btn.btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.auth-footer-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(0, 146, 207, 0.1);
    font-size: 0.9rem;
}

.auth-footer-links a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    z-index: 3;
}

.auth-footer-links a:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

.auth-divider {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin: 1.5rem 0;
    color: #999;
    font-size: 0.85rem;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e0e0e0;
}

.alert {
    border: none;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
}

.alert-warning {
    background: #fff3cd;
    color: #856404;
}

.alert-success {
    background: #d4edda;
    color: #155724;
}

.alert-info {
    background: #d1ecf1;
    color: #0c5460;
}

.form-check {
    margin-bottom: 1rem;
}

.form-check-input {
    border: 1.5px solid #ddd;
    border-radius: 4px;
    width: 18px;
    height: 18px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.form-check-input:checked {
    background-color: var(--primary);
    border-color: var(--primary);
    box-shadow: 0 2px 6px rgba(0, 146, 207, 0.3);
}

.form-check-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(0, 146, 207, 0.1);
}

.form-check-label {
    color: #333;
    font-weight: 500;
    cursor: pointer;
    user-select: none;
    margin-bottom: 0;
}

.back-to-home {
    text-align: center;
    margin-top: 2rem;
    position: relative;
    z-index: 3;
}
.back-to-home a {
    color: #fff !important;
    font-weight: 700;
    text-shadow: 0 2px 8px #003359, 0 1px 2px #000;
    font-size: 1.1rem;
    letter-spacing: 0.01em;
    text-decoration: none;
    transition: all 0.3s ease;
}
.back-to-home a:hover {
    color: #fff;
    text-decoration: underline;
}

.back-to-home a {
    color: rgba(255, 255, 255, 0.92);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    text-shadow: 0 1px 2px rgba(0,0,0,0.35);
}

.back-to-home a:hover {
    color: white;
    text-decoration: underline;
}

/* Responsive */
@media (max-width: 767px) {
    .auth-shell {
        padding: 2rem 0.75rem;
        min-height: auto;
    }

    .auth-container {
        max-width: 100%;
    }

    .auth-card .card-body {
        padding: 2rem 1.75rem;
    }

    .auth-card h1 {
        font-size: 1.5rem;
    }

    .auth-header {
        margin-bottom: 1.5rem;
        padding-bottom: 1rem;
        gap: 0.5rem;
    }

    .auth-brand {
        font-size: 1.25rem;
    }

    .auth-subbrand {
        font-size: 0.85rem;
    }

    .auth-card .form-control {
        padding: 0.75rem 0.875rem;
        font-size: 16px; /* Prevents iOS zoom */
    }
}

@media (max-width: 575px) {
    .auth-shell {
        padding: 1.5rem 0.5rem;
    }

    .auth-card .card-body {
        padding: 1.75rem 1.25rem;
    }

    .auth-card h1 {
        font-size: 1.35rem;
        margin-bottom: 0.75rem;
    }

    .auth-header {
        margin-bottom: 1.25rem;
        padding-bottom: 1rem;
    }

    .auth-brand {
        font-size: 1.15rem;
    }

    .auth-logo {
        height: 40px;
    }

    .auth-footer-links {
        flex-direction: column;
        gap: 0.75rem;
    }

    .back-to-home {
        margin-top: 1.5rem;
    }
}