/* ============================================================
   LITTIWALE PANDA & LITTI ANIMATED AUTH STYLES
   ============================================================ */

:root {
    --bg: #09090b;
    --card-bg: #121217;
    --card-border: rgba(255, 255, 255, 0.1);
    --gold: #f97316;
    --gold-glow: rgba(249, 115, 22, 0.35);
    --input-bg: #18181f;
    --text-primary: #ffffff;
    --text-muted: #94a3b8;
    --text-light: #e2e8f0;
    --font-heading: 'Outfit', 'Plus Jakarta Sans', sans-serif;
    --font-body: 'Plus Jakarta Sans', sans-serif;
    --white: #ffffff;
    --error: #ef4444;
    --button-text: #ffffff;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body.bg-primary {
    background: #09090b;
    font-family: var(--font-body);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow-x: hidden;
    position: relative;
}

#auth-container {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 1020px;
    min-height: 600px;
    margin: 20px;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 24px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.7), 0 0 40px rgba(249, 115, 22, 0.1);
    overflow: hidden;
    position: relative;
    z-index: 10;
}

.logo-overlay {
    position: absolute;
    top: 20px;
    left: 24px;
    z-index: 30;
}

.logo-icon img {
    height: 42px;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 4px 10px rgba(0,0,0,0.5));
}

/* LEFT PANEL (MASCOT PANDA ON DESKTOP) */
.left {
    flex: 1;
    height: 100%;
    min-height: 620px;
    background: radial-gradient(circle at center, rgba(249, 115, 22, 0.18) 0%, rgba(9, 9, 11, 0.95) 75%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    border-right: 1px solid var(--card-border);
}

.left::before {
    content: '';
    position: absolute;
    width: 320px;
    height: 320px;
    background: radial-gradient(circle, rgba(249, 115, 22, 0.3) 0%, transparent 70%);
    border-radius: 50%;
    filter: blur(40px);
    animation: pandaPulse 4s ease-in-out infinite alternate;
}

@keyframes pandaPulse {
    0% { transform: scale(0.85); opacity: 0.6; }
    100% { transform: scale(1.15); opacity: 1; }
}

.mascot-img {
    max-width: 82%;
    max-height: 480px;
    object-fit: contain;
    z-index: 2;
    filter: drop-shadow(0 15px 35px rgba(0, 0, 0, 0.7));
    transition: opacity 0.5s ease, transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.hero-img-signup {
    display: none;
    opacity: 0;
    transform: scale(0.9);
}

body.signup-mode .hero-img-login {
    display: none;
    opacity: 0;
}

body.signup-mode .hero-img-signup {
    display: block;
    opacity: 1;
    transform: scale(1);
    animation: popIn 0.5s ease;
}

@keyframes popIn {
    0% { transform: scale(0.85); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

/* RIGHT PANEL (FORM) */
.right {
    flex: 1.15;
    padding: 44px 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    background: #121217;
}

.card-inner {
    width: 100%;
    max-width: 440px;
    margin: 0 auto;
}

.tabs {
    display: flex;
    background: rgba(0, 0, 0, 0.4);
    border: 1.5px solid var(--card-border);
    border-radius: 14px;
    padding: 4px;
    margin-bottom: 24px;
    gap: 6px;
}

.tab {
    flex: 1;
    text-align: center;
    padding: 10px 14px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.25s ease;
    color: var(--text-muted);
}

.tab.active {
    background: linear-gradient(135deg, #f97316 0%, #ea580c 100%);
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(249, 115, 22, 0.4);
}

.card h1 {
    font-family: var(--font-heading);
    font-size: 30px;
    font-weight: 900;
    color: var(--white);
    margin-bottom: 6px;
    line-height: 1.2;
}

.card .sub {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 22px;
    line-height: 1.4;
}

.form-container {
    transition: all 0.35s ease;
}

.form-hide {
    display: none;
    opacity: 0;
    transform: translateY(10px);
}

.form-show {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.field-group {
    margin-bottom: 14px;
    position: relative;
}

.field-label {
    display: block;
    font-size: 11.5px;
    font-weight: 700;
    color: var(--text-muted);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

input {
    width: 100%;
    background: var(--input-bg);
    border: 1.5px solid var(--card-border);
    border-radius: 12px;
    padding: 12px 16px;
    font-size: 14px;
    font-family: var(--font-body);
    color: var(--text-primary);
    outline: none;
    transition: all 0.2s ease;
}

input::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

input:focus {
    border-color: var(--gold);
    box-shadow: 0 0 0 3px var(--gold-glow);
}

.btn-luxury {
    width: 100%;
    padding: 14px;
    border-radius: 12px;
    border: none;
    background: linear-gradient(135deg, #f97316 0%, #ea580c 100%);
    color: #ffffff;
    font-family: var(--font-body);
    font-size: 14px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    margin-top: 10px;
    transition: all 0.25s ease;
    box-shadow: 0 8px 25px rgba(249, 115, 22, 0.4);
}

.btn-luxury:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(249, 115, 22, 0.6);
}

.btn-luxury:active {
    transform: translateY(1px);
}

.divider {
    text-align: center;
    color: var(--text-muted);
    font-size: 11px;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin: 18px 0;
    position: relative;
}

.divider::before, .divider::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 40%;
    height: 1px;
    background: var(--card-border);
}

.divider::before { left: 0; }
.divider::after  { right: 0; }

.btn-social {
    width: 100%;
    padding: 12px;
    border-radius: 12px;
    border: 1.5px solid var(--card-border);
    background: rgba(255, 255, 255, 0.04);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    color: var(--text-light);
    font-size: 13.5px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.btn-social:hover {
    background: rgba(255, 255, 255, 0.09);
    border-color: rgba(255, 255, 255, 0.25);
}

.register-link {
    text-align: center;
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 20px;
}

.register-link button {
    background: none;
    border: none;
    color: var(--gold);
    font-weight: 800;
    cursor: pointer;
    font-family: var(--font-body);
    margin-left: 4px;
}

.register-link button:hover {
    text-decoration: underline;
}

.error-msg {
    color: var(--error);
    font-size: 12px;
    font-weight: 600;
    text-align: center;
    margin-top: 8px;
    min-height: 18px;
}

.success-msg {
    color: #22c55e;
    font-size: 12px;
    font-weight: 600;
    text-align: center;
    margin-top: 8px;
}

/* ============================================================
   LITTI FIRE LOADER ANIMATION
   ============================================================ */
#auth-loader {
    display: none;
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(18, 18, 23, 0.95);
    backdrop-filter: blur(8px);
    z-index: 50;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 24px;
}

.litti-loader {
    position: relative;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.litti-ball {
    width: 48px;
    height: 48px;
    background: radial-gradient(circle at 35% 35%, #f59e0b, #b45309, #78350f);
    border-radius: 50%;
    box-shadow: 0 0 25px rgba(245, 158, 11, 0.6);
    animation: littiRoast 2s infinite ease-in-out;
    position: relative;
    z-index: 2;
}

.litti-crack {
    position: absolute;
    width: 24px;
    height: 2px;
    background: #451a03;
    border-radius: 2px;
    top: 24px;
    left: 12px;
    transform: rotate(-25deg);
}

.litti-fire {
    position: absolute;
    bottom: 4px;
    width: 60px;
    height: 35px;
    display: flex;
    justify-content: center;
    gap: 6px;
    z-index: 1;
}

.flame {
    width: 14px;
    height: 28px;
    background: linear-gradient(to top, #ef4444, #f97316, #fde047);
    border-radius: 50% 50% 20% 20%;
    animation: flameFlicker 0.6s infinite alternate ease-in-out;
}

.flame.f1 { animation-delay: 0s; height: 32px; }
.flame.f2 { animation-delay: 0.2s; height: 26px; }
.flame.f3 { animation-delay: 0.4s; height: 30px; }

@keyframes littiRoast {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-8px) rotate(15deg); }
}

@keyframes flameFlicker {
    0% { transform: scaleY(0.9) scaleX(0.95); opacity: 0.85; }
    100% { transform: scaleY(1.2) scaleX(1.05); opacity: 1; }
}

.litti-loader-text {
    margin-top: 18px;
    font-size: 14px;
    font-weight: 800;
    color: #f97316;
    letter-spacing: 0.5px;
}

/* ============================================================
   MOBILE SWIPE PANDA SCREEN (Full screen on mobile)
   ============================================================ */
#mobile-panda-screen {
    display: none;
}

@media (max-width: 768px) {
    #auth-container {
        margin: 12px;
        min-height: auto;
        border-radius: 20px;
    }

    .left {
        display: none;
    }

    .right {
        padding: 30px 20px;
    }

    #mobile-panda-screen {
        display: flex;
        position: fixed;
        top: 0; left: 0;
        width: 100vw;
        height: 100vh;
        z-index: 99999;
        flex-direction: column;
        align-items: center;
        justify-content: flex-end;
        transition: transform 0.65s cubic-bezier(0.22, 1, 0.36, 1);
        overflow: hidden;
        background: #09090b;
    }

    #mobile-panda-img {
        position: absolute;
        top: 0; left: 0;
        width: 100%;
        height: 100%;
        object-fit: cover;
        object-position: center top;
        z-index: 0;
    }

    #mobile-panda-screen::before {
        content: '';
        position: absolute;
        bottom: 0; left: 0;
        width: 100%;
        height: 60%;
        background: linear-gradient(to top, rgba(9,9,11,0.98) 0%, rgba(9,9,11,0.75) 50%, transparent 100%);
        z-index: 1;
        pointer-events: none;
    }

    .mobile-brand-name {
        position: relative;
        z-index: 2;
        font-size: 30px;
        font-weight: 900;
        color: #f97316;
        letter-spacing: 5px;
        text-align: center;
        text-shadow: 0 0 30px rgba(249, 115, 22, 0.6);
        margin-bottom: 6px;
    }

    .mobile-swipe-hints {
        position: relative;
        z-index: 10;
        width: 100%;
        display: flex;
        flex-direction: column;
        align-items: center;
        padding: 0 16px 36px;
        gap: 8px;
        pointer-events: auto;
    }

    .swipe-hint-up, .swipe-hint-down {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 12px 16px;
        width: 100%;
        max-width: 320px;
        background: rgba(255, 255, 255, 0.05);
        border: 1px solid rgba(249, 115, 22, 0.3);
        border-radius: 14px;
        cursor: pointer;
        user-select: none;
        touch-action: manipulation;
        transition: transform 0.2s ease, background 0.2s ease;
    }

    .swipe-hint-up:active, .swipe-hint-down:active {
        transform: scale(0.96);
        background: rgba(249, 115, 22, 0.2);
    }

    .swipe-hint-up {
        animation: hintUp 1.8s ease-in-out infinite;
    }

    .swipe-hint-down {
        animation: hintDown 1.8s ease-in-out infinite 0.4s;
    }

    .swipe-arr {
        font-size: 20px;
        color: #f97316;
        line-height: 1;
        display: block;
        font-weight: 900;
    }

    .swipe-arr.dim { opacity: 0.4; }

    .swipe-arrows-down {
        transform: rotate(180deg);
    }

    .swipe-text-up, .swipe-text-down {
        font-size: 11.5px;
        letter-spacing: 2px;
        text-transform: uppercase;
        color: #ffffff;
        font-weight: 800;
        margin-top: 4px;
        text-shadow: 0 2px 8px rgba(0,0,0,0.8);
    }

    @keyframes hintUp {
        0%, 100% { transform: translateY(0); opacity: 0.85; }
        50% { transform: translateY(-6px); opacity: 1; }
    }

    @keyframes hintDown {
        0%, 100% { transform: translateY(0); opacity: 0.85; }
        50% { transform: translateY(6px); opacity: 1; }
    }

    #mobile-panda-screen.mpanda-hidden {
        transform: translateY(-100%) !important;
        opacity: 0 !important;
        pointer-events: none !important;
    }

    #mobile-panda-screen.mpanda-hidden-down {
        transform: translateY(100%) !important;
        opacity: 0 !important;
        pointer-events: none !important;
    }
}
