/* 
   ADWE 2026 - SENIOR ARCHITECTURE: AUTHENTICATION
   Elite Responsiveness & High-Fidelity Geometry
*/

:root {
    --auth-primary: #9D4EDD;
    --auth-primary-light: #C77DFF;
    --auth-bg: #0B0014;
    --auth-surface: rgba(26, 11, 46, 0.4);
    --auth-text: #F0E6FA;
    --auth-text-muted: #E0B0FF;
    --auth-input-bg: rgba(255, 255, 255, 0.02);
    --auth-border: rgba(157, 78, 221, 0.15);
    --auth-radius: 24px;
}

/* --- CORE RESET --- */
body.auth-body {
    background-color: var(--auth-bg);
    color: var(--auth-text);
    font-family: 'Inter', sans-serif;
    margin: 0;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden !important; /* Force zero scroll */
    padding: 20px;
    position: relative;
}

/* --- HIGH-INTENSITY BACKGROUND --- */
.auth-bg-engine {
    position: fixed;
    inset: 0;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.auth-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.15;
    animation: auth-move 20s infinite alternate;
}

.blob-1 {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--auth-primary) 0%, transparent 70%);
    top: -10%; left: -10%;
}

.blob-2 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--auth-primary-light) 0%, transparent 70%);
    bottom: -10%; right: -10%;
    animation-delay: -5s;
}

.blob-3 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, #7B2CBF 0%, transparent 70%);
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    animation: auth-move-alt 25s infinite alternate;
}

@keyframes auth-move {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(100px, 100px) scale(1.2); }
}

@keyframes auth-move-alt {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-30%, -30%) rotate(360deg); }
}

/* --- FIX SELECT2 SHIFT --- */
.select2-container { width: 100% !important; }
body.select2-container--open { overflow: hidden !important; } /* Stop scroll jumping */

/* --- ELITE LAYOUT ENGINE --- */
.auth-wrapper {
    width: 100%;
    max-width: 1100px;
    display: flex;
    background: var(--auth-surface);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border: 1px solid var(--auth-border);
    border-radius: var(--auth-radius);
    overflow: hidden;
    box-shadow: 0 50px 100px rgba(0,0,0,0.5);
    margin: auto;
    max-height: 90vh;
}

.auth-side-art {
    flex: 1;
    padding: 50px;
    background: linear-gradient(135deg, rgba(157, 78, 221, 0.08), transparent);
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    border-right: 1px solid var(--auth-border);
}

.auth-main {
    flex: 1.2;
    padding: 50px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow: hidden;
}

.auth-main::-webkit-scrollbar { display: none; }

.auth-wrapper.centered {
    max-width: 480px;
    display: block;
    max-height: none;
}

.auth-wrapper.centered .auth-main {
    padding: 50px 40px;
}

/* --- TYPOGRAPHY & IDENTITY --- */
.auth-title {
    font-size: clamp(1.6rem, 3vw, 2rem);
    font-weight: 800;
    margin-bottom: 6px;
    background: linear-gradient(135deg, #fff, var(--auth-primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.auth-subtitle {
    color: var(--auth-text-muted);
    font-size: 0.9rem;
    margin-bottom: 30px;
    opacity: 0.7;
}

/* --- ELITE FORM ELEMENTS --- */
.input-lux {
    width: 100%;
    background: var(--auth-input-bg);
    border: 1px solid var(--auth-border);
    border-radius: 12px;
    padding: 12px 16px;
    color: #fff;
    font-size: 0.9rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-sizing: border-box;
    appearance: none;
}

/* Custom Select Arrow for Senior UX */
select.input-lux {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23C77DFF'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    background-size: 18px;
    padding-right: 45px;
    cursor: pointer;
}

select.input-lux option {
    background: #1A0B2E;
    color: #fff;
    padding: 10px;
}

.input-lux:focus {
    border-color: var(--auth-primary);
    background: rgba(157, 78, 221, 0.05);
    box-shadow: 0 0 20px rgba(157, 78, 221, 0.15);
    outline: none;
}

.field-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 15px;
}

.form-group-lux {
    margin-bottom: 15px;
}

.label-lux {
    display: block;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--auth-text-muted);
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

/* --- TRUST ARCHITECTURE --- */
.trust-feature {
    display: flex;
    gap: 20px;
    margin-bottom: 25px;
    background: rgba(255, 255, 255, 0.02);
    padding: 20px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.03);
    transition: all 0.4s ease;
}

.trust-feature:hover {
    background: rgba(157, 78, 221, 0.05);
    border-color: rgba(157, 78, 221, 0.2);
    transform: translateX(10px);
}

.trust-icon-box {
    width: 45px;
    height: 45px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--auth-primary), var(--auth-primary-light));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.1rem;
    flex-shrink: 0;
    box-shadow: 0 10px 20px rgba(157, 78, 221, 0.2);
}

/* --- BUTTONS --- */
.btn-lux {
    width: 100%;
    padding: 16px;
    background: var(--auth-primary);
    border: none;
    border-radius: 14px;
    color: white;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    overflow: hidden;
}

.btn-lux:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(157, 78, 221, 0.4);
}

/* --- RESPONSIVE ADAPTATION --- */
@media (max-width: 900px) {
    .auth-side-art { display: none; }
    .auth-wrapper { max-width: 500px; }
    .auth-main { padding: 40px; }
}

@media (max-width: 500px) {
    .field-grid { grid-template-columns: 1fr; }
    .auth-main { padding: 30px 20px; }
    .auth-wrapper { border-radius: 0; border: none; background: transparent; backdrop-filter: none; box-shadow: none; }
    body.auth-body { padding: 0; align-items: flex-start; background: var(--auth-bg); }
}

/* --- ENTRANCE ANIMATIONS --- */
.reveal-up {
    animation: reveal-up 0.8s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes reveal-up {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}
