@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Fraunces:wght@700;800&display=swap');

:root {
    --primary: #D4A373;        /* Creamy Latte */
    --primary-dark: #A68664;
    --secondary: #2A1810;     /* Deep Bean */
    --accent: #FAEDCD;
    --text-light: #ffffff;
    --text-muted: rgba(255, 255, 255, 0.6);
    --glass: rgba(10, 10, 10, 0.45);
    --glass-border: rgba(255, 255, 255, 0.1);
    --danger: #EF4444;
    --success: #10B981;
    --radius: 30px;
    --transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
}

body {
    background-color: var(--secondary);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow-x: hidden;
    color: var(--text-light);
}

/* Dynamic Background */
.auth-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background-image: 
        linear-gradient(rgba(0,0,0,0.4), rgba(0,0,0,0.8)),
        url('../login_background_coffee_1776575043299.png'); /* Using generated image */
    background-size: cover;
    background-position: center;
    transform: scale(1.1);
    animation: zoomOut 20s infinite alternate;
}

@keyframes zoomOut {
    from { transform: scale(1.1); }
    to { transform: scale(1); }
}

/* Floating Coffee Beans (Motion Graphics effect) */
.floating-elements {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

.bean {
    position: absolute;
    opacity: 0.15;
    animation: float 15s infinite linear;
}

@keyframes float {
    0% { transform: translate(0, 0) rotate(0deg); }
    100% { transform: translate(100px, 100vh) rotate(360deg); }
}

/* Auth Container */
.auth-wrapper {
    width: 100%;
    max-width: 1000px;
    padding: 20px;
    display: flex;
    justify-content: center;
}

.auth-card {
    background: var(--glass);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    display: flex;
    overflow: hidden;
    width: 100%;
    box-shadow: 0 25px 50px rgba(0,0,0,0.5);
    animation: cardAppear 0.8s cubic-bezier(0.2, 1, 0.3, 1);
}

@keyframes cardAppear {
    from { opacity: 0; transform: translateY(40px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

/* Side Info */
.auth-side {
    flex: 1;
    padding: 60px;
    background: linear-gradient(135deg, rgba(201, 147, 95, 0.3), rgba(0, 0, 0, 0));
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
}

@media (max-width: 768px) {
    .auth-side { display: none; }
    .auth-form-container { width: 100% !important; }
}

.auth-side h1 {
    font-family: 'Fraunces', serif;
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 15px;
    background: linear-gradient(135deg, #fff 30%, var(--primary));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.02em;
}

.auth-side p {
    font-size: 1.1rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 40px;
}

.feature-list {
    list-style: none;
}

.feature-list li {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
    font-weight: 500;
    animation: fadeInRight 0.5s ease forwards;
    opacity: 0;
}

.feature-list li:nth-child(1) { animation-delay: 0.3s; }
.feature-list li:nth-child(2) { animation-delay: 0.4s; }
.feature-list li:nth-child(3) { animation-delay: 0.5s; }

@keyframes fadeInRight {
    from { opacity: 0; transform: translateX(-20px); }
    to { opacity: 1; transform: translateX(0); }
}

.feature-list li i {
    width: 40px;
    height: 40px;
    background: rgba(201, 147, 95, 0.2);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    color: var(--primary);
    border: 1px solid rgba(201, 147, 95, 0.3);
}

/* Form Area */
.auth-form-container {
    flex: 1;
    padding: 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.auth-header {
    margin-bottom: 40px;
}

.auth-header h2 {
    font-family: 'Fraunces', serif;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.auth-header p {
    color: var(--text-muted);
    font-size: 1.1rem;
}

.form-group {
    margin-bottom: 25px;
    position: relative;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-muted);
    transition: var(--transition);
}

.input-wrapper {
    position: relative;
}

.input-wrapper i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    transition: var(--transition);
}

.form-control {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 15px 15px 15px 45px;
    color: #fff;
    font-size: 1rem;
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 0 15px rgba(201, 147, 95, 0.2);
}

.form-control:focus + i {
    color: var(--primary);
}

.auth-tools {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    font-size: 0.9rem;
}

.forgot-pw {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition);
}

.forgot-pw:hover {
    color: var(--primary-dark);
    text-shadow: 0 0 10px rgba(201, 147, 95, 0.5);
}

.btn-auth {
    width: 100%;
    padding: 18px;
    border-radius: 16px;
    border: none;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 25px;
    box-shadow: 0 10px 25px rgba(212, 163, 115, 0.2);
}

.btn-auth:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 15px 35px rgba(212, 163, 115, 0.3);
    filter: brightness(1.1);
}

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

.footer-link {
    text-align: center;
    color: var(--text-muted);
}

.footer-link a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

/* Alerts */
.alert {
    padding: 15px;
    border-radius: 12px;
    margin-bottom: 25px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.95rem;
    animation: shake 0.5s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

.alert-danger {
    background: rgba(255, 77, 77, 0.15);
    border: 1px solid rgba(255, 77, 77, 0.3);
    color: var(--danger);
}

.alert-success {
    background: rgba(0, 200, 81, 0.15);
    border: 1px solid rgba(0, 200, 81, 0.3);
    color: var(--success);
}

/* Quick Login for Demo */
.demo-login {
    margin-top: 30px;
    border-top: 1px solid var(--glass-border);
    padding-top: 20px;
}

.demo-title {
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 15px;
}

.demo-btns {
    display: flex;
    gap: 10px;
}

.btn-demo {
    flex: 1;
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--glass-border);
    color: #fff;
    padding: 10px;
    border-radius: 8px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: var(--transition);
}

.btn-demo:hover {
    background: rgba(255,255,255,0.1);
    border-color: var(--primary);
}
