/*
mpdal
*/
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
}

.modal.active {
    display: flex;
    justify-content: center;
    align-items: center;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}

.modal-content {
    position: relative;
    width: 90%;
    max-width: 480px;
    max-height: 90vh;
    overflow-y: auto;
    background: white;
    border-radius: 24px;
    padding: 50px 60px;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.2);
    z-index: 10000;
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 36px;
    height: 36px;
    border: 2px solid #e0e0e0;
    border-radius: 50%;
    background: white;
    font-size: 24px;
    color: #707070;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.modal-close:hover {
    background: #f5f5f5;
    border-color: #d0d0d0;
}

.login-title {
    font-size: 26px;
    font-weight: 700;
    text-align: center;
    color: #282828;
    margin-bottom: 40px;
}

.login-form {
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #505050;
    margin-bottom: 8px;
}

.form-group input {
    width: 100%;
    height: 44px;
    padding: 0 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.form-group input:focus {
    outline: none;
    border-color: #b70701;
}

.error-message {
    display: block;
    color: #b70701;
    font-size: 13px;
    margin-top: 6px;
    min-height: 0px;
}

.form-group input.error {
    border-color: #b70701;
}

.form-group input.error:focus {
    border-color: #b70701;
}

.btn-login {
    width: 100%;
    height: 48px;
    background: #b70701;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 12px;
}

.btn-login:hover {
    background: #c70000;
}

.login-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    margin-top: 16px;
    font-size: 14px;
}

.login-links a {
    color: #707070;
    text-decoration: none;
    transition: color 0.3s ease;
}

.login-links a:hover {
    color: #b70701;
}

.login-links .divider {
    color: #d0d0d0;
}

.social-login {
    border-top: 1px solid #e0e0e0;
    padding-top: 30px;
}

.social-title {
    text-align: center;
    font-size: 14px;
    font-weight: 600;
    color: #707070;
    margin-bottom: 20px;
}

.social-buttons {
    display: flex;
    justify-content: center;
    gap: 16px;
}

.btn-social-circle {
    width: 100%;
    height: 48px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    background: rgb(240, 240, 240);
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-google {
    color: #111;
    border-color: #f0f0f0;
}

.btn-google:hover {
    background: rgb(202, 202, 202);
    color: #111
}

.social-logo {
    width: 20px;
    height: 20px;
    margin-right: 8px;
    vertical-align: middle;
}

.social-buttons  a {
    text-decoration-line: none;
}


/*
Signup
*/
.signup-form {
    margin-bottom: 20px;
}

.gender-select {
    display: flex;
    gap: 20px;
    margin-top: 8px;
}

.radio-label {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-size: 15px;
    color: #505050;
}

.radio-label input[type="radio"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

select {
    width: 100%;
    height: 44px;
    padding: 0 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s ease;
    box-sizing: border-box;
    background: white;
    cursor: pointer;
}

select:focus {
    outline: none;
    border-color: #b70701;
}

.terms-group {
    margin-top: 24px;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 12px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 14px;
    color: #505050;
    margin-bottom: 12px;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.terms-items {
    margin-left: 26px;
    margin-top: 12px;
}

.terms-items .checkbox-label {
    font-size: 13px;
    margin-bottom: 8px;
}

.btn-signup {
    width: 100%;
    height: 52px;
    background: #b70701;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 20px;
}

.btn-signup:hover {
    background: #c70000;
}

.modal-content-inner {
    width: 100%;
}

.modal-content {
    position: relative;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    background: white;
    border-radius: 24px;
    padding: 50px 50px 50px 60px;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.2);
    z-index: 10000;
    animation: modalSlideIn 0.3s ease-out;
}


/*
Scroll
*/
.modal-content::-webkit-scrollbar {
    width: 6px;
}

.modal-content::-webkit-scrollbar-track {
    background: transparent;
    border-radius: 24px;
    margin: 30px 0;
}

.modal-content::-webkit-scrollbar-thumb {
    background: #d0d0d0;
    border-radius: 10px;
}

.modal-content::-webkit-scrollbar-thumb:hover {
    background: #b0b0b0;
}

.modal-content::-webkit-scrollbar-button {
    display: none;
}

.modal-content {
    scrollbar-width: thin;
    scrollbar-color: #d0d0d0 transparent;
}

/* Terms Agreement Section */
.terms-subtitle {
    text-align: center;
    font-size: 15px;
    color: #707070;
    margin-bottom: 30px;
}

.terms-section {
    margin-bottom: 20px;
}

/* Agree to All */
.terms-all-check {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 60px;
    padding: 0;
    border-bottom: 2px solid #e0e0e0;
    margin: 0;
    font-weight: 600;
    font-size: 16px;
    color: #282828;
}

.terms-all-check input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin: 0;
    flex-shrink: 0;
}

/* Accordion Container */
.terms-accordion {
    margin: 0;
    padding: 0;
}

.terms-accordion-item {
    margin: 0;
    padding: 0;
    border-bottom: 1px solid #f0f0f0;
}

.terms-accordion-item:last-child {
    border-bottom: none;
}

/* Accordion Header */
.terms-accordion-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 60px;
    padding: 0;
    margin: 0;
    background: white;
    cursor: pointer;
}

.terms-accordion-header:hover {
    background: #fafafa;
}

/* Checkbox Label */
.terms-accordion-header .checkbox-label {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0;
    padding: 0;
    font-size: 14px;
    color: #505050;
}

.terms-accordion-header input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin: 0;
    flex-shrink: 0;
    cursor: pointer;
}

.terms-accordion-header .checkbox-label span {
    margin: 0;
    padding: 0;
    line-height: 1.4;
}

.terms-accordion-header .terms-label {
    flex: 1;
    margin: 0;
    padding: 0 12px;
    font-size: 14px;
    color: #505050;
    cursor: pointer;
}

.terms-accordion-header .terms-label span {
    line-height: 1.4;
}

/* Toggle Button */
.terms-toggle {
    width: 40px;
    height: 60px;
    margin: 0;
    padding: 0;
    border: none;
    background: transparent;
    font-size: 16px;
    color: #b0b0b0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: transform 0.3s ease, color 0.3s ease;
}

.terms-accordion-item.active .terms-toggle {
    transform: rotate(90deg);
    color: #707070;
}

/* Accordion Body */
.terms-accordion-body {
    max-height: 0;
    overflow: hidden;
    background: #ffffff;
    border-radius: 8px;
    margin: 0 auto;
    padding: 0;
    width: calc(100% - 40px);
}

.terms-accordion-item.active .terms-accordion-body {
    max-height: 400px;
    padding: 16px;
    margin: 8px auto 12px auto;
    overflow-y: auto;
    border: 1px solid #e0e0e0;
}

.terms-accordion-body iframe {
    width: 100%;
    height: 350px;
    border: none;
    background: white;
}

.terms-accordion-body p {
    font-size: 13px;
    line-height: 1.7;
    color: #606060;
    margin: 0;
}

.terms-accordion-body::-webkit-scrollbar {
    width: 4px;
}

.terms-accordion-body::-webkit-scrollbar-track {
    background: transparent;
}

.terms-accordion-body::-webkit-scrollbar-thumb {
    background: #d0d0d0;
    border-radius: 4px;
}

/* Next Button */
.btn-next {
    width: 100%;
    height: 52px;
    background: #b70701;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 30px;
}

.btn-next:hover {
    background: #c70000;
}

.btn-next:disabled {
    background: #d0d0d0;
    cursor: not-allowed;
}



@media (max-width: 768px) {
    .modal-content {
        padding: 40px 40px;
    }

    .login-title {
        font-size: 28px;
    }
}

@media (max-width: 480px) {
    .modal-content {
        width: 95%;
        padding: 30px 25px;
    }

    .login-title {
        font-size: 24px;
        margin-bottom: 30px;
    }
}