﻿/* =========================================================
   STARLIFE – SOLAR AMBER REGISTER UI (WEB + MOBILE)
   ========================================================= */


/* =========================================================
   LOGO & TAGLINE INTRO ANIMATIONS (SOLAR AMBER)
   ========================================================= */

.brand-logo-container {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-bottom: 8px;
}

/* Star Orbit & Pulse */
.orbital-star-wrapper {
    position: relative;
    width: 55px;
    height: 55px;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: starIgnite 1.2s cubic-bezier(0.34, 1.56, 0.64, 1) forwards, starOrbitRing 12s linear infinite;
    transform-origin: center;
    opacity: 0;
    filter: drop-shadow(0 0 12px rgba(245, 158, 11, 0.8));
}

.orbital-star {
    width: 100%;
    height: 100%;
    animation: starPulse 2.5s ease-in-out infinite alternate;
}

/* Cosmic orbital tail effect */
.star-orbit-tail {
    position: absolute;
    inset: -6px;
    border: 1px dashed rgba(255, 216, 77, 0.25);
    border-radius: 50%;
    animation: rotateTail 6s linear infinite;
    pointer-events: none;
}

    .star-orbit-tail::after {
        content: '';
        position: absolute;
        top: 50%;
        right: -3px;
        width: 6px;
        height: 6px;
        border-radius: 50%;
        background: #ffffff;
        box-shadow: 0 0 10px #f59e0b, 0 0 20px #ffd84d;
    }

/* Main Text Reveal and Shine */
.animate-starlife {
    position: relative;
    margin: 0;
    font-family: 'Orbitron', sans-serif;
    font-size: 42px;
    font-weight: 700;
    letter-spacing: 3px;
    background: linear-gradient(90deg, #ffd84d 0%, #f59e0b 50%, #ffd84d 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    opacity: 0;
    animation: textReveal 1.2s cubic-bezier(0.215, 0.610, 0.355, 1.000) 0.5s forwards, textMetallicShine 5s linear infinite;
    text-shadow: 0 0 24px rgba(245, 158, 11, 0.35);
    transform-origin: left;
}

/* Tagline "My Star Life" Reveal */
.animate-tagline {
    margin: 6px 0 24px;
    font-size: 19px;
    font-weight: 500;
    letter-spacing: 2px;
    color: var(--text-muted);
    opacity: 0;
    transform: translateY(6px);
    animation: taglineReveal 1.2s cubic-bezier(0.16, 1, 0.3, 1) 1.6s forwards;
    position: relative;
}

    .animate-tagline::after {
        content: '';
        position: absolute;
        left: 15%;
        bottom: -6px;
        width: 70%;
        height: 1px;
        background: linear-gradient(90deg, transparent, rgba(245, 158, 11, 0.4), transparent);
        transform: scaleX(0);
        animation: lineStretch 1s ease-out 1.9s forwards;
    }

/* =========================================================
   KEYFRAMES
   ========================================================= */

@keyframes starIgnite {
    0% {
        opacity: 0;
        transform: scale(0.2) rotate(-90deg);
    }

    50% {
        opacity: 0.5;
    }

    100% {
        opacity: 1;
        transform: scale(1) rotate(0deg);
    }
}

@keyframes starPulse {
    0% {
        transform: scale(0.9);
        filter: drop-shadow(0 0 8px rgba(245, 158, 11, 0.6));
    }

    100% {
        transform: scale(1.15);
        filter: drop-shadow(0 0 16px rgba(255, 216, 77, 0.9));
    }
}

@keyframes rotateTail {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes starOrbitRing {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@keyframes textReveal {
    0% {
        opacity: 0;
        transform: scale(0.92) translateX(12px);
        filter: blur(4px);
    }

    100% {
        opacity: 1;
        transform: scale(1) translateX(0);
        filter: blur(0);
    }
}

@keyframes textMetallicShine {
    0% {
        background-position: 0% center;
    }

    100% {
        background-position: 200% center;
    }
}

@keyframes taglineReveal {
    0% {
        opacity: 0;
        transform: translateY(8px);
        filter: blur(2px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
        filter: blur(0);
    }
}

@keyframes lineStretch {
    0% {
        transform: scaleX(0);
        opacity: 0;
    }

    100% {
        transform: scaleX(1);
        opacity: 1;
    }
}

:root {
    --bg-obsidian: #080501;
    --bg-amber-glow: rgba(245, 158, 11, 0.16);
    --card-bg: rgba(18, 12, 4, 0.78);
    --card-border: rgba(245, 158, 11, 0.45);
    --input-bg: rgba(12, 8, 2, 0.85);
    --input-border: rgba(245, 158, 11, 0.35);
    --amber-primary: #f59e0b;
    --amber-bright: #ffd84d;
    --amber-deep: #b45309;
    --text-main: #fff7e6;
    --text-muted: #d6b682;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: 'Rajdhani', system-ui, sans-serif;
    background: radial-gradient(circle at 20% 18%, rgba(245, 158, 11, 0.22), transparent 42%), radial-gradient(circle at 82% 78%, rgba(217, 119, 6, 0.18), transparent 45%), linear-gradient(135deg, #070401 0%, #120b02 55%, #070401 100%);
    color: var(--text-main);
    overflow-x: hidden;
}

/* ================= SPLIT LAYOUT ================= */
.auth-wrapper {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1fr 1.15fr;
    position: relative;
}

/* ================= LEFT BRAND PANEL ================= */
.auth-left {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
    overflow: hidden;
    border-right: 1px solid rgba(245, 158, 11, 0.2);
}

    .auth-left::before {
        content: "";
        position: absolute;
        inset: 0;
        background-image: linear-gradient(rgba(245, 158, 11, 0.06) 1px, transparent 1px), linear-gradient(90deg, rgba(245, 158, 11, 0.06) 1px, transparent 1px);
        background-size: 42px 42px;
        pointer-events: none;
    }

#gradientCanvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.brand-orb {
    position: absolute;
    width: 390px;
    height: 390px;
    border-radius: 50%;
    border: 1px solid rgba(255, 216, 77, 0.28);
    box-shadow: 0 0 60px rgba(245, 158, 11, 0.22), inset 0 0 50px rgba(245, 158, 11, 0.12);
    background: radial-gradient(circle, rgba(245, 158, 11, 0.14) 0%, transparent 70%);
    pointer-events: none;
}

.brand-card {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 44px 36px;
    border-radius: 22px;
    background: rgba(15, 10, 3, 0.72);
    border: 1px solid rgba(255, 216, 77, 0.35);
    backdrop-filter: blur(12px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.7), 0 0 35px rgba(245, 158, 11, 0.22);
    max-width: 400px;
    width: 100%;
}

.brand-badge {
    display: inline-block;
    font-family: 'Orbitron', sans-serif;
    font-size: 11px;
    letter-spacing: 2px;
    color: var(--amber-bright);
    background: rgba(245, 158, 11, 0.14);
    border: 1px solid rgba(255, 216, 77, 0.35);
    padding: 6px 14px;
    border-radius: 999px;
    margin-bottom: 18px;
}

.brand-card h1 {
    margin: 0;
    font-family: 'Orbitron', sans-serif;
    font-size: 42px;
    font-weight: 700;
    letter-spacing: 3px;
    background: linear-gradient(90deg, #ffd84d, #f59e0b, #fff0b3);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 24px rgba(245, 158, 11, 0.35);
}

.brand-card p {
    margin: 10px 0 24px;
    font-size: 19px;
    font-weight: 500;
    letter-spacing: 1px;
    color: var(--text-muted);
}

.brand-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
}

    .brand-dots span {
        width: 8px;
        height: 8px;
        border-radius: 50%;
        background: rgba(245, 158, 11, 0.3);
    }

        .brand-dots span.active {
            width: 24px;
            border-radius: 999px;
            background: linear-gradient(90deg, var(--amber-primary), var(--amber-bright));
        }

/* ================= RIGHT FORM PANEL ================= */
.auth-right {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px 24px;
}

.auth-card {
    width: 100%;
    max-width: 620px;
    padding: 28px;
    border-radius: 22px;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(16px);
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.82), 0 0 36px rgba(245, 158, 11, 0.2), inset 0 0 24px rgba(245, 158, 11, 0.08);
}

/* MOBILE BRAND (HIDDEN ON DESKTOP) */
.mobile-brand {
    display: none;
    text-align: center;
    margin-bottom: 16px;
}

.mobile-brand-title {
    display: block;
    font-family: 'Orbitron', sans-serif;
    font-size: 28px;
    font-weight: 700;
    letter-spacing: 2px;
    background: linear-gradient(90deg, #ffd84d, #f59e0b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.mobile-brand-sub {
    font-size: 15px;
    color: var(--text-muted);
}

/* ================= REGISTER / LOGIN TABS ================= */
.toggle {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    padding: 6px;
    border-radius: 16px;
    background: rgba(10, 7, 2, 0.85);
    border: 1px solid rgba(245, 158, 11, 0.25);
    margin-bottom: 22px;
}

    .toggle button {
        border: none;
        border-radius: 12px;
        padding: 11px 16px;
        font-family: 'Orbitron', sans-serif;
        font-size: 13px;
        font-weight: 600;
        letter-spacing: 0.8px;
        cursor: pointer;
        background: transparent;
        color: var(--text-muted);
        transition: all 0.25s ease;
    }

        .toggle button.active {
            background: linear-gradient(90deg, var(--amber-primary), var(--amber-bright));
            color: #160d02;
            box-shadow: 0 0 22px rgba(245, 158, 11, 0.55);
        }

        .toggle button:not(.active):hover {
            color: var(--amber-bright);
            background: rgba(245, 158, 11, 0.1);
        }

/* ================= FORM GRID & FIELDS ================= */
.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px 16px;
}

.form-group {
    margin-bottom: 0;
}

    .form-group.full-row {
        grid-column: 1 / -1;
    }

    .form-group label {
        display: block;
        font-size: 14px;
        font-weight: 600;
        letter-spacing: 0.5px;
        color: var(--amber-bright);
        margin-bottom: 6px;
    }

.input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.form-control {
    width: 100%;
    height: 44px;
    border-radius: 12px;
    border: 1px solid var(--input-border);
    background: var(--input-bg);
    color: var(--text-main);
    font-family: 'Rajdhani', sans-serif;
    font-size: 16px;
    font-weight: 500;
    padding: 8px 14px;
    outline: none;
    transition: all 0.25s ease;
    box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.5);
}

    .form-control::placeholder {
        color: rgba(214, 182, 130, 0.52);
    }

    .form-control:focus {
        border-color: var(--amber-bright);
        background: rgba(22, 14, 4, 0.95);
        box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.18), 0 0 18px rgba(245, 158, 11, 0.35);
    }

    .form-control.readonly-field {
        background: rgba(245, 158, 11, 0.06);
        color: var(--amber-bright);
        font-weight: 600;
    }

/* INPUT ICONS */
.input-wrap.has-icon-left .form-control {
    padding-left: 38px;
}

.input-wrap.has-icon-right .form-control {
    padding-right: 38px;
}

.input-icon-left,
.input-icon-right {
    position: absolute;
    font-size: 14px;
    color: rgba(255, 216, 77, 0.78);
    pointer-events: none;
}

.input-icon-left {
    left: 13px;
}

.input-icon-right {
    right: 13px;
}

/* ================= SUBMIT BUTTON ================= */
.btn-main {
    margin-top: 22px;
    width: 100%;
    height: 48px;
    border: none;
    border-radius: 14px;
    background: linear-gradient(90deg, #d97706 0%, #f59e0b 48%, #ffd84d 100%);
    color: #150c01;
    font-family: 'Orbitron', sans-serif;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 1.4px;
    cursor: pointer;
    box-shadow: 0 10px 28px rgba(245, 158, 11, 0.35), 0 0 24px rgba(255, 216, 77, 0.35);
    transition: transform 0.2s ease, box-shadow 0.25s ease;
}

    .btn-main:hover {
        transform: translateY(-2px);
        box-shadow: 0 14px 34px rgba(245, 158, 11, 0.5), 0 0 32px rgba(255, 216, 77, 0.55);
    }

    .btn-main:active {
        transform: scale(0.98);
    }

/* ================= TABLET & MOBILE RESPONSIVE ================= */
@media (max-width: 991px) {
    .auth-wrapper {
        grid-template-columns: 1fr;
    }

    .auth-left {
        display: none;
    }

    .auth-right {
        padding: 20px 14px;
        align-items: flex-start;
    }

    .mobile-brand {
        display: block;
    }

    .auth-card {
        max-width: 480px;
        padding: 20px 16px;
        border-radius: 20px;
    }

    .form-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .form-group.full-row {
        grid-column: auto;
    }
}


.msg-popup {
    display: none;
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    max-width: 380px;
    padding: 14px 18px;
    border-radius: 12px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 16px;
    font-weight: 600;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.65);
}

    .msg-popup.error {
        background: rgba(69, 10, 10, 0.95);
        border: 1px solid #f87171;
        color: #fecaca;
    }

    .msg-popup.success {
        background: rgba(6, 78, 59, 0.95);
        border: 1px solid #34d399;
        color: #d1fae5;
    }