/* 註冊頁面-start */
.register-section {
    padding: 0 0 88px;
    background: #ffffff;
    border-top: 1px solid rgba(24, 24, 24, 0.08);

    .my-container {
        max-width: 1200px;
    }

    .register-card {
        width: 100%;
        max-width: 640px;
        margin: 0 auto;
        padding: 40px 44px 44px;
        border-radius: 16px;
        background: #ffffff;
        /* border: 1px solid rgba(24, 24, 24, 0.08);
        box-shadow: 0 8px 32px rgba(15, 23, 42, 0.04); */

        .register-card__head {
            padding-bottom: 24px;
            text-align: left;

            .register-card__title {
                margin: 0 0 8px;
                font-size: 32px;
                font-weight: 600;
                line-height: 1.2;
                color: var(--black-color);
            }

            .register-card__subtitle {
                margin: 0;
                font-size: 14px;
                line-height: 1.6;
                color: #7b7b7b;

                .register-card__subtitle-link {
                    color: var(--main-color);
                    font-weight: 600;
                    text-decoration: none;

                    &:hover {
                        color: var(--yellow-color);
                    }
                }
            }
        }

        .register-form {
            .register-form__group {
                margin-bottom: 24px;

                .register-form__group-title {
                    margin: 0 0 12px;
                    font-size: 15px;
                    font-weight: 600;
                    color: var(--black-color);
                }

                .register-form__required {
                    margin-right: 4px;
                    color: #d64545;
                }

                .register-form__group-body {
                    display: flex;
                    flex-direction: column;
                    gap: 16px;

                    .register-form__field-row {
                        display: grid;
                        gap: 16px;
                        width: 100%;

                        &.register-form__field-row--name {
                            grid-template-columns: 112px minmax(0, 1fr) minmax(0, 1fr);
                        }

                        &.register-form__field-row--password {
                            grid-template-columns: repeat(2, minmax(0, 1fr));
                        }

                        .register-form__field {
                            margin-bottom: 0;
                            min-width: 0;
                        }
                    }

                    .register-form__password-rules {
                        margin-top: -4px;

                        .register-form__password-rules-list {
                            display: grid;
                            grid-template-columns: repeat(2, minmax(0, 1fr));
                            gap: 8px 16px;
                            margin: 0;
                            padding: 0;
                            list-style: none;

                            .register-form__password-rule {
                                position: relative;
                                padding-left: 12px;
                                font-size: 12px;
                                line-height: 1.5;
                                color: #18181889;
                                transition: color 0.2s ease;

                                &::before {
                                    content: "";
                                    position: absolute;
                                    left: 0;
                                    top: 4px;
                                    width: 8px;
                                    height: 8px;
                                    background: #18181889;
                                    /* border: 1px solid #d1d5db; */
                                    border-radius: 50%;
                                    transition: border-color 0.2s ease, background 0.2s ease;
                                }

                                &.is-valid {
                                    color: #16a34a;

                                    &::before {
                                        /* border-color: #16a34a; */
                                        background: #16a34a;
                                        /* box-shadow: inset 0 0 0 2px #ffffff; */
                                    }
                                }

                                &.is-invalid {
                                    color: #dc2626;

                                    &::before {
                                        background-color: #dc2626;
                                    }
                                }
                            }
                        }
                    }

                    .register-form__field {
                        margin-bottom: 0;

                        .register-form__label {
                            display: block;
                            margin-bottom: 8px;
                            font-size: 13px;
                            font-weight: 400;
                            color: #7b7b7b;
                        }

                        .register-form__input-wrap {
                            position: relative;

                            &.register-form__input-wrap--sms {
                                flex: 1;
                                min-width: 0;
                            }

                            &.register-form__input-wrap--date {
                                .register-form__input {
                                    cursor: pointer;
                                    padding-right: 42px;
                                    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%23181818' stroke-width='1.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 1.5v2M11 1.5v2M2.5 6.5h11M3.5 2.5h9a1 1 0 0 1 1 1V13a1 1 0 0 1-1 1h-9a1 1 0 0 1-1-1V3.5a1 1 0 0 1 1-1Z'/%3E%3C/svg%3E");
                                    background-repeat: no-repeat;
                                    background-position: right 14px center;
                                    background-size: 16px 16px;
                                }
                            }

                            &.register-form__input-wrap--password {
                                .register-form__input {
                                    padding-right: 44px;
                                }
                            }

                            .register-form__password-toggle {
                                position: absolute;
                                top: 50%;
                                right: 10px;
                                z-index: 2;
                                display: inline-flex;
                                align-items: center;
                                justify-content: center;
                                width: 32px;
                                height: 32px;
                                padding: 0;
                                border: none;
                                border-radius: 8px;
                                background: transparent;
                                color: #7b7b7b;
                                cursor: pointer;
                                transform: translateY(-50%);
                                transition: color 0.2s ease, background-color 0.2s ease;

                                &:hover {
                                    color: var(--black-color);
                                    background: rgba(24, 24, 24, 0.06);
                                }

                                .register-form__password-icon {
                                    width: 18px;
                                    height: 18px;
                                    display: block;
                                }

                                .register-form__password-icon--hide {
                                    display: none;
                                }

                                &.is-visible {
                                    .register-form__password-icon--show {
                                        display: none;
                                    }

                                    .register-form__password-icon--hide {
                                        display: block;
                                    }
                                }
                            }

                            .register-form__input {
                                width: 100%;
                                min-height: 48px;
                                padding: 0 14px;
                                border: 1px solid rgba(24, 24, 24, 0.16);
                                border-radius: 10px;
                                background: #ffffff;
                                font-size: 15px;
                                font-weight: 400;
                                color: var(--black-color);
                                outline: none;
                                transition: border-color 0.2s ease, box-shadow 0.2s ease;

                                &:focus {
                                    border-color: rgba(24, 24, 24, 0.35);
                                }

                                &::placeholder {
                                    color: #b0b5bf;
                                }
                            }
                        }

                        .register-form__select-wrap {
                            position: relative;

                            .layui-form-select {
                                width: 100%;

                                .layui-input {
                                    width: 100%;
                                    min-height: 48px;
                                    padding: 0 14px;
                                    border: 1px solid rgba(24, 24, 24, 0.16);
                                    border-radius: 10px;
                                    background: #ffffff;
                                    font-size: 15px;
                                    font-weight: 400;
                                    color: var(--black-color);
                                    outline: none;
                                    transition: border-color 0.2s ease, box-shadow 0.2s ease;

                                    &:focus {
                                        border-color: rgba(24, 24, 24, 0.35);
                                    }
                                }

                                dl {
                                    top: calc(100% + 6px);
                                    border-radius: 10px;
                                    border: 1px solid rgba(24, 24, 24, 0.1);
                                    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
                                }
                            }
                        }

                        .register-form__phone {
                            display: flex;
                            align-items: stretch;
                            min-height: 48px;
                            border: 1px solid rgba(24, 24, 24, 0.16);
                            border-radius: 10px;
                            background: #ffffff;
                            overflow: visible;
                            transition: border-color 0.2s ease, box-shadow 0.2s ease;

                            &:focus-within {
                                border-color: rgba(24, 24, 24, 0.35);
                            }

                            .register-form__phone-code-wrap {
                                flex-shrink: 0;
                                width: 102px;
                                position: relative;
                                z-index: 2;

                                .layui-form-select {
                                    width: 100%;

                                    .layui-input {
                                        min-height: 46px;
                                        margin: 0;
                                        padding: 0 28px 0 14px;
                                        border: none !important;
                                        border-right: 1px solid rgba(24, 24, 24, 0.1) !important;
                                        border-radius: 10px 0 0 10px !important;
                                        background: rgba(24, 24, 24, 0.03) !important;
                                        box-shadow: none !important;
                                        font-size: 14px;
                                        font-weight: 600;
                                        color: var(--black-color);
                                        outline: none;
                                    }

                                    .layui-edge {
                                        border-width: 5px;
                                        margin-top: -2px;
                                        right: 12px;
                                    }

                                    dl {
                                        left: 0;
                                        top: calc(100% + 6px);
                                        min-width: 120px;
                                        max-height: 180px;
                                        padding: 6px 0;
                                        overflow-x: hidden;
                                        overflow-y: auto;
                                        border-radius: 10px;
                                        border: 1px solid rgba(24, 24, 24, 0.1);
                                        box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
                                        -webkit-overflow-scrolling: touch;

                                        dd {
                                            padding: 0 14px;
                                            line-height: 40px;
                                            font-size: 14px;
                                            font-weight: 500;

                                            &.layui-this {
                                                background: rgba(30, 140, 230, 0.1);
                                                color: var(--main-color);
                                                font-weight: 600;
                                            }

                                            &:hover {
                                                background: rgba(24, 24, 24, 0.04);
                                            }
                                        }
                                    }
                                }
                            }

                            .register-form__phone-input {
                                flex: 1;
                                min-width: 0;
                                min-height: 46px;
                                padding: 0 16px;
                                border: none !important;
                                border-radius: 0 10px 10px 0 !important;
                                box-shadow: none !important;
                                background: transparent !important;

                                &:focus {
                                    border: none !important;
                                    box-shadow: none !important;
                                }
                            }
                        }

                        .register-form__sms-row {
                            display: flex;
                            align-items: stretch;
                            gap: 12px;

                            .register-form__sms-btn {
                                flex-shrink: 0;
                                min-width: 128px;
                                min-height: 48px;
                                padding: 0 18px;
                                border: 1px solid var(--main-color);
                                border-radius: 10px;
                                background: #ffffff;
                                font-size: 14px;
                                font-weight: 400;
                                color: var(--main-color);
                                cursor: pointer;
                                transition: background 0.2s ease, color 0.2s ease, opacity 0.2s ease;

                                &:hover:not(:disabled) {
                                    border-color: var(--yellow-color);
                                    color: #ffffff;
                                }

                                &:disabled {
                                    border-color: rgba(24, 24, 24, 0.12);
                                    background: #f5f5f5;
                                    color: #18181889;
                                    cursor: not-allowed;

                                    &:hover {
                                        &::before {
                                            display: none;
                                        }
                                    }
                                }
                            }
                        }

                        .register-form__sms-tip {
                            margin: 8px 0 0;
                            font-size: 13px;
                            line-height: 1.5;
                            color: #9ca3af;
                        }

                        .register-form__birthday-tip {
                            margin: 8px 0 0;
                            font-size: 13px;
                            line-height: 1.5;
                            color: #9ca3af;
                        }
                    }
                }
            }

            .register-form__footer {
                margin-top: 8px;
                padding-top: 24px;
                border-top: 1px solid rgba(24, 24, 24, 0.08);

                .register-form__field {
                    &.register-form__field--checkbox {
                        margin-bottom: 20px;
                    }

                    .register-form__checkbox {
                        display: inline-flex;
                        align-items: flex-start;
                        gap: 10px;
                        cursor: pointer;
                        user-select: none;

                        input[type="checkbox"] {
                            width: 18px;
                            height: 18px;
                            margin: 1px 0 0;
                            flex-shrink: 0;
                            accent-color: var(--main-color);
                            cursor: pointer;
                        }

                        .register-form__checkbox-text {
                            font-size: 13px;
                            line-height: 1.6;
                            color: #7b7b7b;

                            .register-form__checkbox-link {
                                color: var(--main-color);
                                font-weight: 600;
                                text-decoration: none;

                                &:hover {
                                    color: var(--yellow-color);
                                }
                            }
                        }
                    }
                }

                .register-form__submit {
                    width: 100%;
                    min-height: 52px;
                    border: none;
                    font-size: 16px;
                    cursor: pointer;

                    &:disabled {
                        background: #d1d5db;
                        cursor: not-allowed;
                    }
                }
            }
        }
    }
}
/* 註冊頁面-end */
