/* 
   Bibans Inventaire - Premium Login Styling 
   Theme: Cyber Dark / Glassmorphism
*/

:root {
    --bg-dark: #020617;
    --text-primary: #ffffff;
    --text-secondary: #94a3b8;
    --accent-color: #3b82f6;
    --accent-glow: rgba(59, 130, 246, 0.5);
    --glass-bg: rgba(30, 41, 59, 0.7);
    --glass-border: rgba(255, 255, 255, 0.1);
    --input-bg: rgba(15, 23, 42, 0.6);
    --font-main: 'Outfit', sans-serif;
}

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

body {
    font-family: var(--font-main);
    background-color: var(--bg-dark);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow-x: hidden;
    overflow-y: auto;
    position: relative;
    padding: 20px;
}

/* --- Responsive Container --- */
.auth-page-container {
    display: flex;
    width: 100%;
    max-width: 1100px;
    min-height: 700px;
    background: var(--glass-bg);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid var(--glass-border);
    border-radius: 32px;
    overflow: hidden;
    box-shadow: 0 50px 100px -20px rgba(0, 0, 0, 0.6);
    z-index: 10;
    margin: auto;
    animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Side Panel (Desktop Only) */
.auth-side-panel {
    flex: 1;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(37, 99, 235, 0.1));
    border-right: 1px solid var(--glass-border);
    padding: 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
}

.auth-side-panel::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.05) 0%, transparent 70%);
    pointer-events: none;
}

.side-content {
    position: relative;
    z-index: 1;
}

.side-content h1 {
    font-size: 2.8rem;
    font-weight: 800;
    margin-bottom: 24px;
    background: linear-gradient(to bottom right, #fff, #94a3b8);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1.1;
}

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

.features-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 15px;
    color: var(--text-primary);
    font-weight: 500;
}

.feature-item i {
    width: 24px;
    height: 24px;
    background: rgba(59, 130, 246, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-color);
}

/* Auth Card (Form Side) */
.auth-card {
    width: 100%;
    max-width: 480px;
    padding: 60px;
    display: flex;
    flex-direction: column;
    background: rgba(15, 23, 42, 0.3);
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-header {
    text-align: center;
    margin-bottom: 32px;
}

.modal-header h2 {
    font-family: 'Cairo', sans-serif;
    font-size: 2.2rem;
    font-weight: 800;
    margin-bottom: 8px;
    color: white;
}

.modal-body {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* --- Forms --- */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-left: 2px;
}

.form-group input {
    width: 100%;
    padding: 14px 18px;
    background: var(--input-bg);
    border: 1px solid var(--glass-border);
    border-radius: 14px;
    color: white;
    font-size: 1rem;
    font-family: var(--font-main);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    outline: none;
}

.form-group input:focus {
    border-color: var(--accent-color);
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
    background: rgba(15, 23, 42, 0.9);
    transform: translateY(-1px);
}

.password-wrapper {
    position: relative;
    width: 100%;
}

.password-wrapper input {
    padding-right: 48px !important;
}

/* Hide Browser Default Eye Icons */
input::-ms-reveal,
input::-ms-clear {
    display: none;
}

.toggle-password {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    z-index: 5;
    opacity: 0;
    pointer-events: none;
}

.toggle-password.visible {
    opacity: 1;
    pointer-events: auto;
}

.toggle-password:hover {
    color: var(--accent-color);
}

/* --- Social Buttons --- */
.social-auth {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 16px;
}

.divider {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 8px 0;
    color: var(--text-secondary);
    font-size: 0.8rem;
    font-weight: 600;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--glass-border);
}

.btn-social {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 14px;
    border-radius: 14px;
    border: 1px solid var(--glass-border);
    background: var(--input-bg);
    color: white;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-social:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
}

.btn-social svg {
    width: 20px;
    height: 20px;
}

.hidden {
    display: none !important;
}

/* --- Premium Offer Cards --- */
.offer-cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    margin-top: 8px;
}

.offer-card {
    position: relative;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 16px;
    overflow: hidden;
}

.offer-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.05), transparent);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
}

.offer-card:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.2);
    transform: scale(1.02);
}

.offer-card:hover::before {
    transform: translateX(100%);
}

.offer-card.selected {
    background: rgba(59, 130, 246, 0.08);
    border-color: var(--accent-color);
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.15);
}

.offer-card input[type="radio"] {
    appearance: none;
    width: 20px;
    height: 20px;
    border: 2px solid var(--glass-border);
    border-radius: 50%;
    cursor: pointer;
    position: relative;
    transition: all 0.3s;
    flex-shrink: 0;
}

.offer-card input[type="radio"]:checked {
    border-color: var(--accent-color);
    background: var(--accent-color);
}

.offer-card input[type="radio"]:checked::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 8px;
    height: 8px;
    background: white;
    border-radius: 50%;
}

.offer-info {
    flex: 1;
}

.offer-title {
    font-weight: 700;
    color: white;
    font-size: 1rem;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.offer-desc {
    color: var(--text-secondary);
    font-size: 0.8rem;
    line-height: 1.4;
}

.offer-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    font-size: 0.65rem;
    font-weight: 800;
    padding: 4px 8px;
    border-radius: 6px;
    background: var(--accent-color);
    color: white;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    opacity: 0;
    transform: translateY(-5px);
    transition: all 0.3s ease;
}

.offer-card.selected .offer-badge {
    opacity: 1;
    transform: translateY(0);
}

/* --- Buttons --- */
.btn-save {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
    border: none;
    padding: 18px;
    border-radius: 16px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 10px 30px -5px rgba(59, 130, 246, 0.4);
    margin-top: 10px;
}

.btn-save:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 20px 40px -10px rgba(59, 130, 246, 0.5);
    filter: brightness(1.1);
}

.btn-save:active {
    transform: scale(0.98);
}

/* --- Animated Background --- */
.background-blobs {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 1;
    overflow: hidden;
    pointer-events: none;
}

.blob-1 {
    width: 800px;
    height: 800px;
    top: -200px;
    left: -200px;
}

.blob-2 {
    width: 900px;
    height: 900px;
    bottom: -300px;
    right: -200px;
}

/* --- Responsive Adjustments --- */
@media (max-width: 1024px) {
    .auth-page-container {
        max-width: 900px;
    }

    .auth-side-panel {
        padding: 40px;
    }

    .auth-card {
        padding: 40px;
    }

    .side-content h1 {
        font-size: 2.2rem;
    }
}

@media (max-width: 768px) {
    body {
        padding: 15px;
        align-items: flex-start;
    }

    .auth-page-container {
        flex-direction: column;
        border-radius: 24px;
        min-height: auto;
    }

    .auth-side-panel {
        display: none;
        /* Hide on small screens to focus on form */
    }

    .auth-card {
        max-width: 100%;
        padding: 30px 20px;
    }

    .modal-header h2 {
        font-size: 1.8rem;
    }
}

/* --- Language Selector --- */
select#login-language {
    background: rgba(15, 23, 42, 0.6) !important;
    border: 1px solid var(--glass-border) !important;
    backdrop-filter: blur(15px);
    font-family: var(--font-main);
    font-weight: 500;
    color: white;
    padding: 10px 15px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s;
}

select#login-language:hover {
    background: rgba(15, 23, 42, 0.8) !important;
    border-color: var(--accent-color) !important;
}