/* ============================================
   LUCKY CASE - Premium CSS Styles
   Design by Vibe Coding
   ============================================ */

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Colors */
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #818cf8;
    --secondary: #ec4899;
    --accent: #f59e0b;

    --background: #0f172a;
    --background-light: #1e293b;
    --surface: rgba(30, 41, 59, 0.8);
    --surface-light: rgba(255, 255, 255, 0.1);

    --text: #f8fafc;
    --text-muted: #94a3b8;
    --text-dark: #1e293b;

    --border: rgba(255, 255, 255, 0.1);
    --border-light: rgba(255, 255, 255, 0.2);

    /* Gradients */
    --gradient-primary: linear-gradient(135deg, #6366f1 0%, #ec4899 100%);
    --gradient-secondary: linear-gradient(135deg, #f59e0b 0%, #ef4444 100%);
    --gradient-dark: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    --gradient-glass: linear-gradient(135deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0.05) 100%);

    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-glow: 0 0 20px rgba(99, 102, 241, 0.3);

    /* Border Radius */
    --radius-sm: 0.375rem;
    --radius: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;
    --radius-full: 9999px;

    /* Transitions */
    --transition-fast: 150ms ease;
    --transition: 300ms ease;
    --transition-slow: 500ms ease;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    background: var(--background);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
}

/* ============================================
   Auth Pages (Login / Register)
   ============================================ */
.auth-page {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
}

.auth-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--gradient-dark);
    z-index: -1;
}

.bg-shapes {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.5;
    animation: float 20s infinite ease-in-out;
}

.shape-1 {
    width: 600px;
    height: 600px;
    background: var(--primary);
    top: -200px;
    left: -200px;
    animation-delay: 0s;
}

.shape-2 {
    width: 500px;
    height: 500px;
    background: var(--secondary);
    bottom: -150px;
    right: -150px;
    animation-delay: 7s;
}

.shape-3 {
    width: 400px;
    height: 400px;
    background: var(--accent);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation-delay: 14s;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0) rotate(0deg); }
    25% { transform: translate(50px, -50px) rotate(5deg); }
    50% { transform: translate(-30px, 30px) rotate(-5deg); }
    75% { transform: translate(20px, 20px) rotate(3deg); }
}

.auth-container {
    width: 100%;
    max-width: 480px;
    animation: fadeInUp 0.6s ease-out;
}

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

.auth-card {
    background: var(--surface);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border);
    border-radius: var(--radius-2xl);
    padding: 3rem 2.5rem;
    box-shadow: var(--shadow-xl);
}

.auth-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.logo {
    animation: logoPulse 2s infinite;
}

@keyframes logoPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.logo-icon {
    display: inline-block;
    font-size: 4rem;
    margin-bottom: 1rem;
    filter: drop-shadow(0 0 20px rgba(99, 102, 241, 0.5));
}

.logo h1 {
    font-size: 2rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
    letter-spacing: -0.025em;
}

.logo p {
    font-size: 0.875rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.2em;
}

.auth-body {
    margin-bottom: 1.5rem;
}

/* Alerts */
.alert {
    display: flex;
    align-items: center;
    padding: 1rem;
    border-radius: var(--radius);
    margin-bottom: 1.5rem;
    border: 1px solid transparent;
    animation: alertSlide 0.3s ease-out;
}

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

.alert-error {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.3);
    color: #fca5a5;
}

.alert-success {
    background: rgba(34, 197, 94, 0.1);
    border-color: rgba(34, 197, 94, 0.3);
    color: #86efac;
}

.alert-icon {
    font-size: 1.25rem;
    margin-right: 0.75rem;
}

/* Form */
.auth-form {
    margin-bottom: 1.5rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text);
    margin-bottom: 0.5rem;
}

.input-group {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 1rem;
    font-size: 1.125rem;
    z-index: 1;
    opacity: 0.6;
}

.input-group input {
    width: 100%;
    padding: 0.875rem 1rem 0.875rem 3rem;
    background: var(--surface-light);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    color: var(--text);
    font-size: 1rem;
    transition: all var(--transition);
}

.input-group input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.input-group input::placeholder {
    color: var(--text-muted);
}

.form-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.checkbox {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 0.875rem;
    color: var(--text-muted);
}

.checkbox input {
    margin-right: 0.5rem;
    accent-color: var(--primary);
}

.forgot-password {
    font-size: 0.875rem;
    color: var(--text-muted);
    text-decoration: none;
    transition: color var(--transition);
}

.forgot-password:hover {
    color: var(--primary);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    border: none;
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all var(--transition);
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transform: translateX(-100%);
    transition: transform 0.6s;
}

.btn:hover::before {
    transform: translateX(100%);
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-primary {
    background: var(--gradient-primary);
    color: white;
    box-shadow: var(--shadow);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-glow);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-block {
    width: 100%;
}

.btn-large {
    padding: 1rem 1.5rem;
    font-size: 1.125rem;
}

.btn-icon {
    font-size: 1.25rem;
    transition: transform var(--transition);
}

.btn:hover .btn-icon {
    transform: translateX(5px);
}

/* Auth Footer */
.auth-footer {
    text-align: center;
    font-size: 0.875rem;
    color: var(--text-muted);
}

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

.auth-footer a:hover {
    color: var(--primary-light);
}

.auth-footer-nav {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
}

.auth-footer-nav a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.875rem;
    transition: color var(--transition);
}

.auth-footer-nav a:hover {
    color: var(--text);
}

/* ============================================
   Responsive Design
   ============================================ */
@media (max-width: 640px) {
    .auth-card {
        padding: 2rem 1.5rem;
    }

    .logo-icon {
        font-size: 3rem;
    }

    .logo h1 {
        font-size: 1.5rem;
    }

    .btn-large {
        padding: 0.875rem 1.25rem;
        font-size: 1rem;
    }
}

/* ============================================
   Utility Classes
   ============================================ */
.text-center {
    text-align: center;
}

.text-muted {
    color: var(--text-muted);
}

.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 0.75rem; }
.mt-4 { margin-top: 1rem; }
.mt-5 { margin-top: 1.5rem; }

.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-5 { margin-bottom: 1.5rem; }
