/* Base styles for all modals */
.signin-isPreview {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: none; /* Initially hidden */
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

/* Specific styles for modals with background images */
.signin-isPreview--withImage {
    background-color: transparent; /* Remove background color for modals with images */
}

/* Container for the background image */
.signin-y_pSY {
    background-position: 50%;
    background-size: cover;
    display: block;
    min-height: 384px;
}

/* Specific background image for the first child */
.signin-y_pSY:nth-child(1) {
    background-image: none;
    background: linear-gradient(180deg, #f7f8fb 0%, #eef2f7 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 288px;
}

/* Styles for the content container */
.signin-QrgnX {
    padding: 22px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
}

/* Styles for the header section */
.signin-R5I4c {
    text-align: center;
}

/* Styles for the header text */
.signin-gGLia {
    margin-bottom: 6px;
    font-size: 18px;
}

/* Styles for the subheader text */
.signin-Zrhh7 {
    margin-bottom: 14px;
    color: #6b7280;
    font-size: 13px;
    line-height: 1.6;
}

/* Styles for the form container */
.signin-P4grn {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Styles for the input container */
.signin-uO2Nt {
    position: relative;
}

/* Styles for the input field */
.signin-bETlx {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 15px;
    background: #fff;
}

/* Styles for the input label */
.signin-UX763 {
    position: absolute;
    top: 10px;
    left: 10px;
    background-color: white;
    padding: 0 5px;
    font-size: 13px;
    color: #666;
    transition: top 0.3s, font-size 0.3s;
}

/* Styles for the label when the input is focused or has content */
.signin-bETlx:focus + .signin-UX763,
.signin-bETlx:not(:placeholder-shown) + .signin-UX763 {
    top: -7px;
    font-size: 11px;
}

/* Styles for the submit button */
.signin-POo7P {
    width: 100%;
    padding: 10px 16px;
    background-color: #111827;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 15px;
}

/* Hover effect for the submit button */
.signin-POo7P:hover {
    background-color: #1f2937;
}

.signin-social-divider {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 4px 0 2px;
    color: #9ca3af;
    font-size: 12px;
}

.signin-social-divider::before,
.signin-social-divider::after {
    content: '';
    flex: 1;
    border-top: 1px solid #e5e7eb;
}

.signin-social-divider span {
    padding: 0 10px;
    white-space: nowrap;
}

.signin-google-section {
    margin: 0 0 8px;
}

.signin-wechat-section {
    margin: 0 0 10px;
}

.signin-wechat-btn {
    width: 100%;
    padding: 12px 20px;
    background-color: #07c160;
    color: #fff;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
}

.signin-wechat-btn:hover {
    background-color: #06ad56;
}

.signin-google-button {
    width: 98%;
    min-height: 40px;
}

.signin-google-button > div,
.signin-google-button iframe {
    width: 100% !important;
}

.signin-google-status {
    margin-top: 8px;
    min-height: 18px;
    font-size: 12px;
    color: #666;
}

.signin-google-status.is-error {
    color: #d13a3a;
}

.signin-google-section.is-loading {
    opacity: 0.65;
    pointer-events: none;
}

/* Styles for the footer text */
.signin-cmVHa {
    margin-top: 8px;
    font-size: 12px;
    color: #666;
}

/* Styles for the close button */
.signin-B_HlB {
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
}

/* Styles for the close button icon */
.signin-B_HlB svg {
    width: 12px;
    height: 12px;
}

/* Hover effect for the close button icon */
.signin-B_HlB:hover path {
    fill: #000;
}

/* Styles for the modal container */
.signin-aZuqK {
    display: grid;
    grid-template-columns: 1fr 1fr;
    background-color: white;
    border-radius: 16px;
    overflow: visible;
    max-width: 512px;
    width: 90%;
    box-shadow: 0 24px 80px rgba(15, 23, 42, 0.15);
}

/* Additional styles for the verification code container */
.signincode-container {
    display: none; /* Initially hidden */
    position: fixed; /* 设置为固定定位 */
    top: 50%; /* 垂直居中 */
    left: 50%; /* 水平居中 */
    transform: translate(-50%, -50%); /* 确保完全居中 */
    text-align: center;
    padding: 20px;
    background-color: white;
    border-radius: 10px;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    z-index: 1001; /* 确保在最上层 */
}

/* Styles for the verification code input fields */
.signincode-code-input {
    display: flex;
    justify-content: space-between;
    margin: 20px 0;
}

.signincode-code-input input {
    width: 20% !important;
    padding: 5px !important;
    text-align: center;
    border: 2px solid #ccc !important;
    border-radius: 5px;
    font-size: 16px !important;
    font-weight: bold !important; /* 文字加粗 */
    color: #000 !important; /* 文字颜色为黑色 */
}

/* Styles for the resend code link */
.signincode-resend {
    margin-top: 10px;
    font-size: 14px;
    color: #666;
}

.signincode-resend a {
    color: #28a745;
    text-decoration: none;
}

.signincode-resend a:hover {
    text-decoration: underline;
}

/* Styles for the resend link when countdown is complete */
#signincode-resendLink {
    cursor: pointer; /* 鼠标悬停时变成手形 */
}

.signin-wechat-qr-wrap {
    background: #fff;
    padding: 20px;
}

.signin-wechat-qr-shell {
    width: 100%;
    max-width: 288px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 18px;
    padding: 16px 14px 14px;
    box-shadow: 0 12px 36px rgba(15, 23, 42, 0.08);
    text-align: center;
}

.signin-wechat-qr-title {
    font-size: 15px;
    font-weight: 700;
    color: #111827;
    margin-bottom: 12px;
}

.signin-wechat-qr {
    width: 240px;
    height: 320px;
    margin: 0 auto;
    border-radius: 18px;
    border: 1px solid #e5e7eb;
    overflow: visible;
    background: #f9fafb;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6b7280;
    font-size: 14px;
}

.signin-wechat-qr img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.signin-wechat-qr iframe {
    width: 100% !important;
    height: 100% !important;
    border: 0 !important;
    display: block;
}

.signin-wechat-qr.is-placeholder {
    padding: 12px;
}

.signin-wechat-status {
    margin-top: 10px;
    font-size: 12px;
    color: #6b7280;
    line-height: 1.5;
}

.signin-wechat-status.is-error {
    color: #dc2626;
}

/* Media query for mobile devices */
@media (max-width: 768px) {
    .signin-y_pSY:nth-child(1) {
        min-height: 256px;
        min-width: 0;
    }
    .signin-aZuqK {
        grid-template-columns: 1fr; /* Change to single column layout */
    }

    .signin-QrgnX {
        padding: 18px 16px;
    }

    .signin-wechat-qr-shell {
        max-width: 100%;
        padding: 14px 12px 12px;
    }

    .signin-wechat-qr {
        width: min(240px, 100%);
        height: auto;
        aspect-ratio: 3 / 4;
    }
}
