/* assets/css/style.css - Premium Auth UI Redesign */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

:root {
    --primary-color: #075E54;
    --primary-light: #128C7E;
    --accent-color: #25D366; /* Vibrant WhatsApp Green */
    --bg-gradient: linear-gradient(135deg, #075E54 0%, #128C7E 100%);
    --white: #ffffff;
    --text-main: #111b21;
    --text-muted: #54656f;
    --glass-bg: rgba(255, 255, 255, 0.95);
    --glass-border: rgba(255, 255, 255, 0.2);
    --card-shadow: 0 20px 40px rgba(0,0,0,0.15);
    --border-radius: 24px;
    --input-bg: #f8f9fa;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: var(--bg-gradient);
    background-attachment: fixed;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--text-main);
    overflow: hidden;
}

/* Background Decoration */
body::before, body::after {
    content: '';
    position: absolute;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    z-index: -1;
}

body::before {
    top: -100px;
    left: -100px;
}

body::after {
    bottom: -100px;
    right: -100px;
}

.auth-container {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    padding: 30px 25px; /* Reduced padding from 50px 40px */
    border-radius: var(--border-radius);
    box-shadow: var(--card-shadow);
    width: 100%;
    max-width: 550px; /* Increased width slightly for 2-column support */
    text-align: center;
    animation: authFadeIn 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
    position: relative;
    max-height: 95vh;
    overflow-y: auto;
}

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

.auth-container h1 {
    font-size: 28px; /* Slightly smaller */
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 5px;
    letter-spacing: -1px;
}

.auth-container p {
    color: var(--text-muted);
    font-size: 14px;
    margin-bottom: 20px; /* Reduced from 35px */
    font-weight: 400;
}

.form-group {
    margin-bottom: 15px; /* Reduced from 22px */
    text-align: left;
}

.form-group label {
    display: block;
    font-size: 11px; /* Slightly smaller */
    font-weight: 700;
    color: var(--text-muted);
    margin-bottom: 4px; /* Reduced from 8px */
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding-left: 4px;
}

.form-control {
    width: 100%;
    padding: 10px 14px; /* Reduced from 14px 18px */
    font-size: 14px;
    background: var(--input-bg);
    border: 2px solid transparent;
    border-radius: 10px; /* Slightly smaller radius */
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    color: var(--text-main);
    font-family: inherit;
}

.form-control:focus {
    outline: none;
    background: var(--white);
    border-color: var(--primary-color);
    box-shadow: 0 8px 20px rgba(7, 94, 84, 0.1);
    transform: translateY(-2px);
}

.form-control.is-invalid {
    border-color: #ff4757;
    background: #fff5f6;
}

.invalid-feedback {
    color: #ff4757;
    font-size: 12px;
    margin-top: 6px;
    font-weight: 500;
    padding-left: 4px;
}

.btn {
    width: 100%;
    background: var(--primary-color);
    color: var(--white);
    padding: 12px; /* Reduced from 16px */
    border: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 8px 20px rgba(7, 94, 84, 0.25);
    margin-top: 5px;
    text-decoration: none;
    display: block;
}

.btn:hover {
    background: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(7, 94, 84, 0.35);
}

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

.auth-link {
    margin-top: 20px; /* Reduced from 30px */
    font-size: 13px;
    color: var(--text-muted);
}

/* Grid Layout for Forms */
.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 15px;
}

.form-grid-full {
    grid-column: span 2;
}

.auth-link a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 700;
    transition: color 0.3s;
}

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

/* Alerts */
.alert {
    padding: 16px;
    border-radius: 14px;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 25px;
    text-align: left;
    border: none;
    animation: slideDown 0.4s ease-out;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.alert-danger {
    background: #ffe5e5;
    color: #cc0000;
}

.alert-success {
    background: #e7f9ee;
    color: #008a3e;
}

/* Scrollbar for long forms */
.auth-container::-webkit-scrollbar {
    width: 6px;
}
.auth-container::-webkit-scrollbar-thumb {
    background: rgba(7, 94, 84, 0.2);
    border-radius: 10px;
}

@media (max-width: 480px) {
    .auth-container {
        padding: 40px 25px;
        margin: 20px;
    }
    .auth-container h1 {
        font-size: 26px;
    }
}