/* auth.css - Modern BrainBash Authentication UI */

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

body {
    font-family: 'Poppins', sans-serif;
    background: radial-gradient(circle at 10% 30%, #1e2b3f, #0b0f17);
    min-height: 100vh;
    color: #eef5ff;
    line-height: 1.5;
    overflow-x: hidden;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: #1e293b;
}

::-webkit-scrollbar-thumb {
    background: #5f9df3;
    border-radius: 20px;
}

/* Navbar - glassmorphism */
.head {
    padding: 0.8rem 2rem;
    background: rgba(10, 20, 35, 0.75);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid rgba(95, 157, 243, 0.2);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1300px;
    margin: 0 auto;
}

.left {
    font-size: 2rem;
    font-weight: 700;
    background: linear-gradient(135deg, #a6c9ff, #5f9df3);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    letter-spacing: -0.5px;
    transition: transform 0.2s ease;
}

.left:hover {
    transform: scale(1.02);
}

.right a {
    color: #cddfff;
    text-decoration: none;
    margin-left: 2.4rem;
    font-weight: 500;
    position: relative;
    transition: color 0.2s;
    font-size: 1.1rem;
}

.right a:after {
    content: '';
    position: absolute;
    width: 0%;
    height: 2.5px;
    bottom: -6px;
    left: 0;
    background: #5f9df3;
    border-radius: 4px;
    transition: width 0.25s ease;
}

.right a:hover {
    color: white;
}

.right a:hover::after {
    width: 100%;
}

.right a#authLink {
    background: rgba(95, 157, 243, 0.18);
    padding: 0.5rem 1.3rem;
    border-radius: 40px;
    border: 1px solid rgba(95, 157, 243, 0.4);
    margin-left: 2rem;
    transition: all 0.2s;
}

.right a#authLink:hover {
    background: #5f9df3;
    color: #0b0f17;
    border-color: #5f9df3;
}

.right a#authLink:after {
    display: none;
}

/* Main container */
.container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 6rem 1.5rem 2rem;
    animation: fadeInUp 0.8s cubic-bezier(0.2, 0.9, 0.3, 1) forwards;
}

@keyframes fadeInUp {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Auth Card (shared for login/register) */
.auth-card {
    background: rgba(18, 28, 45, 0.8);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(95, 157, 243, 0.25);
    border-radius: 40px;
    padding: 3rem 3.2rem;
    width: 100%;
    max-width: 500px;
    box-shadow: 0 40px 70px -10px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(95, 157, 243, 0.1) inset;
    transition: transform 0.35s, box-shadow 0.45s;
    color: #f0f6ff;
}

.auth-card:hover {
    transform: translateY(-8px) scale(1.01);
    box-shadow: 0 50px 90px -5px #03050a, 0 0 0 2px rgba(95, 157, 243, 0.4) inset;
}

.auth-card h3 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2.4rem;
    font-weight: 600;
    background: linear-gradient(to right, #ffffff, #bfd9ff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    letter-spacing: -0.3px;
}

/* Input group with icons */
.input-group {
    position: relative;
    margin-bottom: 1.8rem;
}

.input-group i {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: #5f9df3;
    font-size: 1.3rem;
    opacity: 0.8;
    transition: opacity 0.2s;
    pointer-events: none;
    z-index: 2;
}

.email, .inp, #role {
    width: 100%;
    padding: 1.2rem 1.2rem 1.2rem 3.2rem;
    background: rgba(0, 0, 0, 0.35);
    border: 1.5px solid rgba(255, 255, 255, 0.08);
    border-radius: 50px;
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    color: white;
    outline: none;
    transition: all 0.25s;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.email:focus, .inp:focus, #role:focus {
    border-color: #5f9df3;
    background: rgba(20, 35, 60, 0.9);
    box-shadow: 0 0 0 4px rgba(95, 157, 243, 0.25);
}

/* Custom select arrow */
#role {
    appearance: none;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%235f9df3' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'/></svg>");
    background-repeat: no-repeat;
    background-position: right 1.5rem center;
    background-size: 1.2rem;
    padding-right: 3rem;
}

#role option {
    background: #1b263b;
    color: white;
}

/* Modern button */
button {
    width: 100%;
    padding: 1.2rem;
    background: linear-gradient(145deg, #5f9df3, #3f7ad0);
    border: none;
    border-radius: 60px;
    font-family: 'Poppins', sans-serif;
    font-size: 1.2rem;
    font-weight: 600;
    color: #0b0f17;
    letter-spacing: 0.3px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 15px 25px -8px #0f1a2e, 0 4px 0 #2a4b85, 0 0 10px #5f9df3;
    margin-top: 0.5rem;
    position: relative;
    overflow: hidden;
}

button::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -20%;
    width: 150%;
    height: 200%;
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(25deg) translateY(0);
    transition: transform 0.6s ease;
    pointer-events: none;
}

button:hover {
    transform: translateY(-4px);
    box-shadow: 0 25px 35px -10px #0a121f, 0 6px 0 #2a4b85, 0 0 25px #7db1ff;
}

button:hover::after {
    transform: rotate(25deg) translateY(30px);
}

button:active {
    transform: translateY(4px);
    box-shadow: 0 8px 15px -5px #0a121f, 0 2px 0 #2a4b85;
}

/* Links */
p {
    text-align: center;
    margin-top: 2.2rem;
    color: #b2c9f0;
    font-weight: 400;
}

a {
    color: #9bc0ff;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s, text-shadow 0.2s;
}

a:hover {
    color: white;
    text-shadow: 0 0 8px #5f9df3;
}

/* Floating background bubbles */
.bg-bubble {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.bubble {
    position: absolute;
    background: rgba(95, 157, 243, 0.1);
    border-radius: 50%;
    backdrop-filter: blur(2px);
    animation: float 18s infinite ease-in-out;
    box-shadow: inset 0 0 30px rgba(95, 157, 243, 0.2);
}

.bubble1 {
    width: 250px;
    height: 250px;
    top: 10%;
    left: 5%;
    animation-duration: 24s;
}

.bubble2 {
    width: 400px;
    height: 400px;
    bottom: -100px;
    right: -50px;
    background: rgba(70, 130, 230, 0.06);
    animation-duration: 32s;
}

.bubble3 {
    width: 180px;
    height: 180px;
    top: 60%;
    left: 80%;
    animation-duration: 19s;
}

.bubble4 {
    width: 320px;
    height: 320px;
    top: 70%;
    left: 10%;
    background: rgba(40, 100, 220, 0.05);
    animation-duration: 27s;
}

@keyframes float {
    0% {
        transform: translate(0, 0) scale(1);
    }
    50% {
        transform: translate(-30px, 40px) scale(1.1);
    }
    100% {
        transform: translate(0, 0) scale(1);
    }
}

/* Responsive */
@media (max-width: 550px) {
    .auth-card {
        padding: 2.2rem 1.8rem;
    }
    
    .right a {
        margin-left: 1rem;
        font-size: 0.95rem;
    }
    
    .right a#authLink {
        padding: 0.4rem 0.8rem;
    }
    
    .auth-card h3 {
        font-size: 2rem;
    }
}