.inhouse-customlogin {
    display: none;
}

.inhouse-customlogin.inline {
    display: block;
}

.inhouse-customlogin.active {
    display: block;
}

.inhouse-customlogin .customlogin-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 900;
    opacity: 0;
    transition: opacity .2s ease;
}

.inhouse-customlogin.active .customlogin-overlay {
    opacity: 1;
}

.inhouse-customlogin .customlogin-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(.95);
    background: #fff;
    padding: 40px 36px;
    width: 92%;
    max-width: 480px;
    border-radius: 18px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.18);
    z-index: 901;
    opacity: 0;
    transition: opacity .2s ease, transform .2s ease;
    border-top: 6px solid #9e8a50;
}

.inhouse-customlogin.inline .customlogin-modal {
    position: relative;
    top: auto;
    left: auto;
    transform: none;
    box-shadow: none;
    border-radius: 16px;
    margin: 24px 0;
}

.inhouse-customlogin.inline .customlogin-modal::before {
    display: none;
}

.inhouse-customlogin.active .customlogin-modal {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.inhouse-customlogin.inline.active .customlogin-modal {
    transform: none;
}

.customlogin-close {
    position: absolute;
    top: 14px;
    right: 14px;
    background: none;
    border: none;
    font-size: 22px;
    cursor: pointer;
    color: #3c3c3c;
}

.customlogin-header {
    text-align: center;
    margin-bottom: 24px;
}

.customlogin-header h3 {
    margin-bottom: 0;
    font-size: 24px;
    color: #1f1f1f;
}

.customlogin-mode-toggle {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin: 28px 0;
}

.customlogin-mode-toggle .toggle {
    padding: 14px 18px;
    border-radius: 12px;
    border: 2px solid rgba(158, 138, 80, 0.3);
    cursor: pointer;
    background: transparent;
    font-weight: 600;
    color: #6f6f6f;
    transition: all .2s ease;
}

.customlogin-mode-toggle .toggle.active {
    border-color: #9e8a50;
    background: transparent;
    color: #9e8a50;
    box-shadow: none;
}

.customlogin-form {
    display: none;
    flex-direction: column;
    gap: 24px;
}

.customlogin-form.active {
    display: flex;
}

.customlogin-form label {
    display: flex;
    flex-direction: column;
    gap: 10px;
    font-size: 14px;
    color: #1f1f1f;
}

.customlogin-form input {
    padding: 14px 16px;
    border-radius: 12px;
    border: 1px solid #d7d7d7;
    transition: border-color .2s ease, box-shadow .2s ease;
    font-size: 16px;
    height: 48px;
    box-sizing: border-box;
}

.customlogin-form input::placeholder {
    font-size: 16px;
    color: #999;
}

.customlogin-form input:focus {
    border-color: #9e8a50;
    box-shadow: 0 0 0 2px rgba(158, 138, 80, 0.15);
    outline: none;
}

.customlogin-form .prefix {
    font-size: 16px;
    font-weight: 600;
    margin-right: 8px;
    color: #9e8a50;
}

.customlogin-form .field {
    display: flex;
    flex-direction: column;
}

.customlogin-form.otp {
    align-items: center;
    text-align: center;
    gap: 20px;
}

.customlogin-form.otp .otp-hint {
    font-weight: 600;
    color: #4d4d4d;
    margin-bottom: 8px;
}

.customlogin-form.otp .otp-widget {
    margin: 12px 0 8px;
    width: 100%;
}

.customlogin-form.otp .customlogin-actions {
    flex-direction: column;
    align-items: center;
    gap: 16px;
    width: 100%;
    margin-top: 12px;
}

.customlogin-form.otp .customlogin-actions .action {
    width: 100%;
    max-width: 360px;
}

.customlogin-form.otp .customlogin-actions .action.link {
    border: 1px solid rgba(158, 138, 80, 0.3);
    background: #fff;
    color: #9e8a50;
    text-decoration: none;
    box-shadow: none;
}

.customlogin-form.otp .customlogin-countdown,
.customlogin-form.otp + .customlogin-messages {
    text-align: center;
}

.customlogin-input-row {
    display: flex;
    align-items: center;
    gap: 12px;
    border: 1px solid #d7d7d7;
    border-radius: 12px;
    padding: 0 16px;
    background: #fff;
    direction: ltr;
    height: 48px;
    box-sizing: border-box;
}

.customlogin-input-row:focus-within {
    border-color: #9e8a50;
    box-shadow: 0 0 0 2px rgba(158, 138, 80, 0.15);
}

.customlogin-input-row .prefix {
    margin: 0;
    font-weight: 700;
    color: #9e8a50;
    min-width: 60px;
    font-size: 16px;
}

.customlogin-input-row input {
    border: none;
    flex: 1;
    padding: 0;
    font-size: 16px;
    height: 100%;
}

.customlogin-input-row input::placeholder {
    font-size: 16px;
    color: #999;
}

.customlogin-input-row input:focus {
    outline: none;
    box-shadow: none;
}

.otp-widget {
    padding: 6px 0 4px;
    display: flex;
    justify-content: center;
    gap: 10px;
    direction: ltr;
}

.customlogin-actions {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    margin-top: 8px;
}

.customlogin-actions .action {
    flex: 1;
    padding: 14px 20px;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    font-weight: 600;
    font-size: 16px;
    transition: transform .2s ease, box-shadow .2s ease;
}

.customlogin-actions .action.primary {
    background: #9e8a50;
    color: #fff;
    box-shadow: 0 15px 25px rgba(158, 138, 80, 0.35);
}

.customlogin-actions .action.primary:disabled {
    background: rgba(158, 138, 80, 0.5);
    box-shadow: none;
    cursor: not-allowed;
}

.customlogin-actions .action.primary:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 20px 30px rgba(158, 138, 80, 0.45);
}

.customlogin-actions .action.link {
    background: none;
    color: #9e8a50;
    text-decoration: underline;
}

.customlogin-messages {
    margin-top: 20px;
    font-size: 14px;
    min-height: 18px;
    text-align: center;
}

.customlogin-messages .error {
    color: #b3261e;
}

.customlogin-messages .success {
    color: #146c43;
}

.customlogin-countdown {
    font-size: 13px;
    color: #7a7a7a;
    margin-top: 12px;
    text-align: center;
}

.customer-account-login .login-container {
    display: none;
}

.customer-account-login .column.main,
.customer-account-create .column.main,
.customer-account-forgotpassword .column.main {
    display: flex;
    justify-content: center;
}

.customer-account-login .inhouse-customlogin.inline .customlogin-modal,
.customer-account-create .inhouse-customlogin.inline .customlogin-modal,
.customer-account-forgotpassword .inhouse-customlogin.inline .customlogin-modal {
    margin: 40px auto;
    max-width: 480px;
}

.customer-account-login .inhouse-customlogin.inline,
.customer-account-create .inhouse-customlogin.inline,
.customer-account-forgotpassword .inhouse-customlogin.inline {
    width: 100%;
}

.customer-account-login,
.customer-account-create,
.customer-account-forgotpassword {
    background: #f4f5f7;
    min-height: 100vh;
}

.customer-account-login .page-title-wrapper,
.customer-account-create .page-title-wrapper,
.customer-account-forgotpassword .page-title-wrapper {
    text-align: center;
    margin: 40px 0 10px;
}

.customer-account-login .page-title .base,
.customer-account-create .page-title .base,
.customer-account-forgotpassword .page-title .base {
    font-size: 42px;
    font-weight: 700;
    color: #1f1f1f;
}

/* Mobile Responsive Styles */
@media (max-width: 768px) {
    .inhouse-customlogin .customlogin-modal {
        padding: 24px 20px;
        width: 92%;
        max-width: 100%;
    }

    .customlogin-header h3 {
        font-size: 20px;
    }

    .customlogin-mode-toggle {
        gap: 8px;
        margin: 20px 0;
    }

    .customlogin-mode-toggle .toggle {
        padding: 12px 14px;
        font-size: 12px;
    }

    .customlogin-form {
        gap: 18px;
    }

    .customlogin-form label {
        font-size: 13px;
        gap: 8px;
    }

    .customlogin-form input {
        padding: 12px 14px;
        font-size: 14px;
        height: 44px;
    }

    .customlogin-form input::placeholder {
        font-size: 14px;
    }

    .customlogin-form .prefix {
        font-size: 14px;
    }

    .customlogin-input-row {
        padding: 0 12px;
        height: 44px;
        box-shadow: none;
        background: #fff;
    }

    .customlogin-input-row:focus-within {
        box-shadow: 0 0 0 2px rgba(158, 138, 80, 0.15);
    }

    .customlogin-input-row .prefix {
        font-size: 14px;
        min-width: 50px;
    }

    .customlogin-input-row input {
        font-size: 14px;
        background: transparent;
    }

    .customlogin-input-row input::placeholder {
        font-size: 14px;
    }

    .customlogin-actions .action {
        padding: 12px 16px;
        font-size: 14px;
    }

    .customlogin-form.otp .otp-hint {
        font-size: 14px;
    }

    .customlogin-messages {
        font-size: 13px;
    }

    .customlogin-countdown {
        font-size: 12px;
    }

    .customer-account-login .page-title .base,
    .customer-account-create .page-title .base,
    .customer-account-forgotpassword .page-title .base {
        font-size: 28px;
    }

    .customer-account-login .page-title-wrapper,
    .customer-account-create .page-title-wrapper,
    .customer-account-forgotpassword .page-title-wrapper {
        margin: 24px 0 8px;
    }

    .customlogin-close {
        font-size: 20px;
        top: 12px;
        right: 12px;
    }
}

