.hs-otp-login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100dvh;
    padding: 20px;
    background-color: #f8fafc;
}

.hs-otp-login-box {
    background: #fff;
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    width: 100%;
    max-width: 440px;
}

.hs-otp-login-box h2 {
    text-align: center;
    margin: 0 0 8px;
    color: var(--hs-otp-primary-color);
    font-size: 24px;
    font-weight: 600;
}

.subtitle {
    text-align: center;
    color: #6b7280;
    margin-bottom: 32px;
    font-size: 16px;
}

.hs-otp-tabs {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
    padding: 4px;
    background: #f3f4f6;
    border-radius: 8px;
}

.hs-otp-tab {
    flex: 1;
    padding: 12px;
    border: none;
    background: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 16px;
    color: #6b7280;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.2s ease;
}

.hs-otp-tab.active {
    background: #fff;
    color: var(--hs-otp-primary-color);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.tab-icon {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

.hs-otp-form {
    margin-top: 24px;
}

.form-step label {
    display: block;
    margin-bottom: 8px;
    color: var(--hs-otp-primary-color);
    font-weight: 500;
}

.phone-input-group,
.email-input-group {
    display: flex;
    align-items: center;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.2s ease;
}

.phone-input-group:focus-within,
.email-input-group:focus-within {
    border-color: var(--hs-otp-primary-color);
    box-shadow: 0 0 0 2px var(--hs-otp-primary-shadow);
}

.country-code {
    padding: 12px 16px;
    background: #f9fafb;
    border-right: 1px solid #d1d5db;
    color: var(--hs-otp-primary-color);
    font-weight: 500;
}

.phone-input-group input,
.email-input-group input {
    flex: 1;
    padding: 12px 16px;
    border: 0;
    font-size: 16px;
    outline: none;
}
input#phone {
    border: 0;
}

.input-hint {
    margin-top: 8px;
    color: #6b7280;
    font-size: 12px;
    margin-bottom: 0;
    text-align: center;
}

.hs-otp-send-btn,
.hs-otp-verify-btn {
    width: 100%;
    padding: 14px;
    background: var(--hs-otp-primary-color);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    margin-top: 24px;
    transition: background 0.2s ease;
}

.hs-otp-send-btn:hover,
.hs-otp-verify-btn:hover {
    background: var(--hs-otp-primary-hover);
}

.terms-text {
    margin-top: 24px;
    text-align: center;
    color: #6b7280;
    font-size: 14px;
}

.terms-text a {
    color: var(--hs-otp-primary-color);
    text-decoration: none;
}

.terms-text a:hover {
    color: var(--hs-otp-primary-hover);
    text-decoration: underline;
}

/* OTP Verification Screen */
.verify-title {
    margin-bottom: 8px;
}

.verify-subtitle {
    color: #6b7280;
    text-align: center;
    margin-bottom: 32px;
}

.otp-input-group {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin-bottom: 24px;
}

.otp-input {
    width: 48px;
    height: 48px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 20px;
    text-align: center;
    outline: none;
    transition: all 0.2s ease;
    background: #fff;
    text-align: center!important;
}

.otp-input:focus {
    border-color: var(--hs-otp-primary-color);
    box-shadow: 0 0 0 2px var(--hs-otp-primary-shadow);
}

.otp-timer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: #6b7280;
    font-size: 14px;
    background: #fff;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.timer-icon {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

.verify-footer {
    text-align: center;
}

.resend-btn {
    background: none;
    border: none;
    color: var(--hs-otp-primary-color);
    cursor: pointer;
    padding: 0;
    font-weight: 500;
}

.resend-btn:hover {
    color: var(--hs-otp-primary-hover);
}

.back-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: none;
    border: none;
    color: var(--hs-otp-primary-color);
    cursor: pointer;
    margin: 16px auto 0;
    padding: 8px 16px;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.back-btn:hover {
    background: var(--hs-otp-primary-shadow);
}

.back-icon {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

.hs-otp-message {
    margin-top: 16px;
    padding: 12px;
    border-radius: 8px;
    text-align: center;
    display: none;
}

.hs-otp-message.success {
    background: #dcfce7;
    color: #166534;
}

.hs-otp-message.error {
    background: #fee2e2;
    color: #991b1b;
}

/* Loading state */
.hs-otp-send-btn.loading,
.hs-otp-verify-btn.loading {
    position: relative;
    color: transparent;
}

.hs-otp-send-btn.loading::after,
.hs-otp-verify-btn.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin: -10px 0 0 -10px;
    border: 2px solid #fff;
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Email input container styling */
.email-input-container {
    position: relative;
    display: flex;
    align-items: center;
    background-color: #f8f9fa;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 12px 16px;
    margin-bottom: 20px;
    transition: all 0.2s ease;
}

.email-input-container:focus-within {
    border-color: var(--hs-otp-primary-color);
    box-shadow: 0 0 0 2px var(--hs-otp-primary-shadow);
}

/* Email icon styling */
.email-icon {
    width: 24px;
    height: 24px;
    margin-right: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.email-icon svg {
    width: 100%;
    height: 100%;
    fill: var(--hs-otp-primary-color);
}

/* Email input field styling */
#email {
    flex: 1;
    border: none;
    background: transparent;
    font-size: 18px;
    color: #1a202c;
    padding: 0;
    outline: none;
    height: 50px;
    text-indent: 10px;
    direction: ltr;
    text-align: center;
}

#email::placeholder {
    color: #a0aec0;
}

/* Label styling */
.email-label {
    display: block;
    font-size: 16px;
    font-weight: 500;
    color: #1a202c;
    margin-bottom: 8px;
}

/* OTP Section Styles */
.otp-section {
    background: #f8fafc;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
    border: 1px solid #e2e8f0;
}

.otp-section[data-type="sms"] {
    border-left: 4px solid var(--hs-otp-primary-color);
}

.otp-section[data-type="email"] {
    border-left: 4px solid #059669;
}

.otp-section .otp-input-group {
    margin-bottom: 20px;
}

.otp-section .otp-timer {
    margin-bottom: 20px;
}

.otp-section .hs-otp-verify-btn {
    margin-bottom: 16px;
}

.otp-section .verify-footer {
    margin-top: 0;
}

/* HS OTP Login Styles */
:root {
    --hs-otp-primary-color: #356C42;
    --hs-otp-primary-hover: #294c31;
    --hs-otp-primary-light: #4a4ca3;
    --hs-otp-primary-shadow: rgba(54, 56, 140, 0.1);
}

/* Verified Badge */
.verified-badge {
    background-color: var(--hs-otp-primary-color);
    color: #ffffff;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    margin-left: 8px;
    display: inline-block;
    vertical-align: middle;
}

/* Form Elements */
.hs-otp-form input[type="text"],
.hs-otp-form input[type="email"],
.hs-otp-form input[type="tel"],
.hs-otp-form input[type="password"] {
    border: 0;
    border-radius: 0;
    padding: 8px 12px;
    width: 100%;
    margin-bottom: 0;
}

.hs-otp-form input[type="text"]:focus,
.hs-otp-form input[type="email"]:focus,
.hs-otp-form input[type="tel"]:focus,
.hs-otp-form input[type="password"]:focus {
    border-color: var(--hs-otp-primary-color);
    outline: none;
}

/* Buttons */
.hs-otp-button {
    background-color: var(--hs-otp-primary-color);
    color: #ffffff;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.hs-otp-button:hover {
    background-color: var(--hs-otp-primary-hover);
}

/* Verification Fields */
.verified-phone input,
.verified-email input {
    background-color: #f8f9fa;
    border-color: var(--hs-otp-primary-color);
}

/* OTP Input Fields */
.otp-input {
    width: 40px;
    height: 40px;
    text-align: center;
    border: 2px solid #ddd;
    border-radius: 4px;
    font-size: 18px;
}

.otp-input:focus {
    border-color: var(--hs-otp-primary-color);
    outline: none;
}

/* Error Messages */
.hs-otp-error {
    color: #dc3545;
    font-size: 14px;
    margin-top: 5px;
}

/* Success Messages */
.hs-otp-success {
    color: #28a745;
    font-size: 14px;
    margin-top: 5px;
}

/* Loading State */
.hs-otp-loading {
    opacity: 0.7;
    pointer-events: none;
}

/* Resend OTP Link */
.resend-otp {
    color: var(--hs-otp-primary-color);
    text-decoration: none;
    font-size: 14px;
}

.resend-otp:hover {
    color: var(--hs-otp-primary-hover);
    text-decoration: underline;
}

/* Admin Settings Page */
.hs-otp-settings .form-table th {
    color: var(--hs-otp-primary-color);
}

.hs-otp-settings .submit .button-primary {
    background-color: var(--hs-otp-primary-color);
    border-color: var(--hs-otp-primary-color);
}

.hs-otp-settings .submit .button-primary:hover {
    background-color: var(--hs-otp-primary-hover);
    border-color: var(--hs-otp-primary-hover);
}

/* RTL Support */
body.rtl .hs-otp-tab {
    flex-direction: row-reverse;
}

body.rtl .phone-input-group {
    flex-direction: row-reverse;
}

body.rtl .tab-icon {
    margin-right: 0;
    margin-left: 8px;
}

body.rtl .country-code {
    direction: ltr;
}

body.rtl #phone {
    direction: ltr;
    text-align: left;
}

body.rtl .otp-input-group {
    flex-direction: row-reverse;
}

body.rtl .back-btn {
    flex-direction: row-reverse;
}

body.rtl .back-icon {
    margin-right: 0;
    margin-left: 8px;
}

body.rtl .resend-btn {
    margin-right: 0;
    margin-left: 8px;
}

body.rtl .email-icon {
    margin-right: 0;
    margin-left: 12px;
}


body.rtl .verified-badge {
    margin-right: 0;
    margin-left: 8px;
}

body.rtl .hs-otp-message {
    text-align: right;
}

/* RTL Form Elements */
body.rtl .form-step label {
    text-align: right;
}


body.rtl .otp-timer {
    flex-direction: row-reverse;
}

body.rtl .timer-icon {
    margin-right: 0;
    margin-left: 8px;
}

/* RTL Admin Settings */
body.rtl .hs-otp-settings .form-table th {
    text-align: right;
}

body.rtl .hs-otp-settings .form-table td {
    text-align: right;
}

/* RTL Input Focus States */
body.rtl .otp-input:focus {
    box-shadow: -2px 0 0 2px var(--hs-otp-primary-shadow);
}

/* RTL Message Alignment */
body.rtl .hs-otp-message.success,
body.rtl .hs-otp-message.error {
    text-align: center;
    padding-right: 12px;
    padding-left: 0;
}

/* RTL Terms Text */
body.rtl .terms-text {
    text-align: right;
}

/* RTL Loading States */
body.rtl .hs-otp-send-btn.loading::after,
body.rtl .hs-otp-verify-btn.loading::after {
    margin-right: 0;
    margin-left: 8px;
}

/* RTL Tab Icons */
body.rtl .tab-icon {
    transform: scaleX(-1);
}

/* RTL Back Button */
body.rtl .back-btn {
    margin-right: auto;
    margin-left: 0;
}

/* RTL Form Validation */
body.rtl .is-valid::after,
body.rtl .is-invalid::after {
    right: 12px;
    left: auto;
}

/* RTL Input Icons */
body.rtl .input-icon {
    right: 12px;
    left: auto;
}

/* RTL Message Icons */
body.rtl .message-icon {
    margin-right: 0;
    margin-left: 8px;
}

/* Exit Button */
.exit-btn {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    padding: 8px;
    cursor: pointer;
    color: #6b7280;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.exit-btn:hover {
    background-color: #f3f4f6;
    color: #374151;
}

.exit-icon {
    width: 24px;
    height: 24px;
}

/* RTL Support for Exit Button */
body.rtl .exit-btn {
    right: auto;
    left: 16px;
}

.hs-otp-login-header {
    text-align: center;
    margin-bottom: 2rem;
    padding: 1rem 0;
}

.hs-otp-login-header .site-logo {
    max-width: 200px;
    height: auto;
    margin: 0 auto;
    display: block;
}

.hs-otp-login-header .site-name {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1f2937;
    margin: 0;
    padding: 0;
}

[dir="rtl"] .hs-otp-login-header .site-name {
    font-family: 'Cairo', sans-serif;
} 