/* =========================================
   Login Modal — Premium Redesign v2
   ========================================= */

/* Overlay — deep dark blur, perfect centering */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(10, 9, 8, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    padding: 24px;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Card — floats centered, generous padding */
.login-card {
    background: #FFFFFF;
    width: 100%;
    max-width: 400px;
    border-radius: 28px;
    padding: 48px 44px 40px;
    position: relative;
    box-shadow:
        0 4px 6px rgba(0, 0, 0, 0.04),
        0 12px 32px rgba(0, 0, 0, 0.1),
        0 40px 80px rgba(0, 0, 0, 0.12);
    transform: translateY(20px);
    opacity: 0;
    transition:
        transform 0.45s cubic-bezier(0.16, 1, 0.3, 1),
        opacity 0.45s ease;
}

.modal-overlay.active .login-card {
    transform: translateY(0);
    opacity: 1;
}

/* Close — tiny, top-right, unobtrusive */
.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: none;
    background: rgba(0, 0, 0, 0.05);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(0, 0, 0, 0.4);
    transition: background 0.2s, color 0.2s, transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    flex-shrink: 0;
}

.modal-close:hover {
    background: rgba(204, 107, 79, 0.1);
    color: #CC6B4F;
    transform: rotate(90deg);
}


/* Header — left-aligned, airy */
.login-header {
    margin-bottom: 32px;
}

.login-header h2 {
    font-size: 1.75rem;
    font-weight: 700;
    color: #111110;
    letter-spacing: -0.6px;
    line-height: 1.15;
    margin-bottom: 8px;
}

.login-header p {
    font-size: 0.875rem;
    color: #6B6A69;
    line-height: 1.5;
    font-weight: 400;
}

/* Form */
.login-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

/* Input Groups */
.input-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.input-group label {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #111110;
    opacity: 0.45;
}

.login-form input[type="email"],
.login-form input[type="password"] {
    width: 100%;
    padding: 14px 16px;
    background: #F7F7F6;
    border: 1.5px solid transparent;
    border-radius: 14px;
    font-family: inherit;
    font-size: 0.95rem;
    color: #111110;
    outline: none;
    transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
    -webkit-appearance: none;
    appearance: none;
}

.login-form input::placeholder {
    color: #9C9C9A;
    font-weight: 400;
}

.login-form input:focus {
    border-color: #CC6B4F;
    background: #FFFFFF;
    box-shadow: 0 0 0 3.5px rgba(204, 107, 79, 0.13);
}

/* Form meta row */
.form-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 2px;
    padding-bottom: 2px;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 0.825rem;
    color: #6B6A69;
    user-select: none;
}

.remember-me input[type="checkbox"] {
    width: 15px;
    height: 15px;
    accent-color: #CC6B4F;
    cursor: pointer;
    flex-shrink: 0;
}

.forgot-password {
    font-size: 0.825rem;
    font-weight: 600;
    color: #CC6B4F;
    text-decoration: none;
    transition: opacity 0.2s;
}

.forgot-password:hover {
    opacity: 0.7;
}

/* Primary CTA — full-width pill */
.login-btn-primary {
    width: 100%;
    padding: 15px 24px;
    margin-top: 6px;
    background: #CC6B4F;
    color: #FFFFFF;
    border: none;
    border-radius: 99px;
    font-family: inherit;
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    cursor: pointer;
    transition: opacity 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.login-btn-primary:hover {
    opacity: 0.88;
    transform: translateY(-1.5px);
    box-shadow: 0 6px 20px rgba(204, 107, 79, 0.38);
}

.login-btn-primary:active {
    transform: translateY(0);
    box-shadow: none;
    opacity: 1;
}

/* Divider */
.social-divider {
    display: flex;
    align-items: center;
    gap: 14px;
    margin: 22px 0;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    color: #111110;
    opacity: 0.25;
    white-space: nowrap;
}

.social-divider::before,
.social-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: currentColor;
    opacity: 0.4;
}

/* Social Buttons — stacked for multilingual compatibility */
.social-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.social-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 13px 16px;
    background: #FFFFFF;
    border: 1.5px solid rgba(0, 0, 0, 0.1);
    border-radius: 14px;
    font-family: inherit;
    font-size: 0.85rem;
    font-weight: 600;
    color: #111110;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, transform 0.2s;
    white-space: nowrap;
}

.social-btn:hover {
    background: #F7F7F6;
    border-color: rgba(0, 0, 0, 0.18);
    transform: translateY(-1px);
}

.social-btn:active {
    transform: translateY(0);
}

.social-btn svg {
    flex-shrink: 0;
}

.social-btn svg.apple-logo-svg path {
    fill: #000;
}

/* Mobile */
@media (max-width: 480px) {
    .login-card {
        padding: 40px 28px 32px;
        border-radius: 24px;
    }

    .login-header h2 {
        font-size: 1.5rem;
    }

    .social-buttons {
        grid-template-columns: 1fr;
    }
}