@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@300;400;500;600;700&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Montserrat', sans-serif;
}

html, body {
    height: 100%; 
    overflow: hidden; 
}

body {
    background-color: #c9d6ff;
    background: linear-gradient(to right, #e2e2e2, #c9d6ff);
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100vh;
}

.container {
    background-color: #fff;
    border-radius: 0px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.35);
    position: relative;
    overflow: hidden;
    width: 100%;
    height: 100%;
    max-width: 100%;
    min-height: 100%;
}

.container p {
    font-size: 14px;
    line-height: 20px;
    letter-spacing: 0.3px;
    margin: 15px 0;
}

.container span{
    font-size: 12px;
}

.container a{
    color: #333;
    font-size: 13px;
    text-decoration: none;
    margin: 15px 0 10px;
}

.container button{
    background-color: #F28C28;
    color: #fff;
    font-size: 12px;
    padding: 10px 45px;
    border: 1px solid transparent;
    border-radius: 8px;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    margin-top: 10px;
    cursor: pointer;
}

.container form{
    background-color: #fff;
    display: flex;
    align-items: center;
    flex-direction: column;
    padding: 80px 40px;
    height: 100%;
}

.container input{
    background-color: #eee;
    border: none;
    margin: 8px 0;
    padding: 10px 15px;
    font-size: 15px;
    border-radius: 8px;
    width: 80%;
    outline: none;
}

.form-container{
    position: absolute;
    top: 0;
    height: 100%;
    transition: all 0.6s ease-in-out;
    padding: 0 40px;
}

.sign-in{
    left: 0;
    width: 50%;
    z-index: 2;
}

.container.active .sign-in{
    transform: translateX(100%);
}

.sign-up{
    left: 0;
    width: 50%;
    opacity: 0;
    z-index: 1;
}

.container.active .sign-up{
    transform: translateX(100%);
    opacity: 1;
    z-index: 5;
    animation: move 0.6s;
}

@keyframes move{
    0%, 49.99%{
        opacity: 0;
        z-index: 1;
    }
    50%, 100%{
        opacity: 1;
        z-index: 5;
    }
}

.social-icons{
    margin: 20px 0;
}

.social-icons a{
    border: 1px solid #ccc;
    border-radius: 20%;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    margin: 0 3px;
    width: 40px;
    height: 40px;
}

.toggle-container{
    position: absolute;
    top: 0;
    left: 50%;
    width: 50%;
    height: 100%;
    overflow: hidden;
    transition: all 0.6s ease-in-out;
    z-index: 1000;
    border-radius: 0;
    -webkit-clip-path: polygon(0 0, 100% 0, 100% 100%, 0% 100%);
    clip-path: polygon(20% 0, 100% 0, 100% 100%, 20% 100%, 0% 50%);
}

.container.active .toggle-container{
    transform: translateX(-100%);
    -webkit-clip-path: polygon(0% 0, 80% 0, 100% 50%, 80% 100%, 0% 100%);
    clip-path: polygon(0% 0, 80% 0, 100% 50%, 80% 100%, 0% 100%);
}

.toggle{
    background-color: #512da8;
    height: 100%;
    background: linear-gradient(to bottom, #002749, #001A33);
    color: #fff;
    position: relative;
    left: -100%;
    height: 100%;
    width: 200%;
    transform: translateX(0);
    transition: all 0.6s ease-in-out;
}

.container.active .toggle{
    transform: translateX(50%);
}

.toggle-panel{
    position: absolute;
    width: 50%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    padding: 0 30px;
    text-align: center;
    top: 0;
    transform: translateX(0);
    transition: all 0.6s ease-in-out;
}

.toggle-left{
    transform: translateX(-200%);
}

.toggle-panel.toggle-left {
    justify-content: flex-start; 
    text-align: left;
    padding-left: 10px; 
    padding-right: 100px; 
    padding-top:100px; 
}

.toggle-panel.toggle-right {
    justify-content: flex-start; 
    text-align: left;
    padding-left: 100px; 
    padding-right: 10px; 
    padding-top:0px; 
}

.container.active .toggle-left{
    transform: translateX(0);
}

.toggle-right{
    right: 0;
    transform: translateX(0);
}

.container.active .toggle-right{
    transform: translateX(200%);
}

.input-group {
    display: flex; 
    gap: 10px; 
    width: 80%; 
    margin: 8px 0; 
}

.input-group input {
    flex: 1; 
    background-color: #eee;
    border: none;
    padding: 10px 15px;
    font-size: 13px;
    border-radius: 8px;
    outline: none;
}

.internal-navbar {
    display: flex; 
    justify-content: space-around; 
    align-items: center; 
    width: 100%;
    padding: 5px 0; 
    margin-bottom: 0px; 
    box-sizing: border-box; 
}

.internal-navbar a {
    color: #555; 
    font-size: 14px;
    text-decoration: none; 
    font-weight: 500; 
    transition: color 0.3s ease; 
}


.modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.4);
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: #fff;
    margin: auto;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.35);
    width: 500px;
    text-align: center;
    position: relative;
}

.modal-icon {
    margin: 10px 0 15px 0;
    display: flex;
    justify-content: center;
}

#modalIcon {
    width: 150px;
    height: 150px;
    max-width: 100%;
    transition: opacity 0.3s ease;
}

.modal-icon.error #modalIcon {
    display: block;
}

.modal-icon.success #modalIcon {
    display: block;
}

.modal-close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.modal-close:hover {
    color: #000;
}

.btn-primary {
    background-color: #F28C28;
    color: #fff;
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    margin-top: 10px;
}

.btn-secondary {
    background-color: #ccc;
    color: #333;
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    margin-top: 10px;
    margin-right: 10px;
}

.modal-input {
    width: 80%;
    padding: 10px;
    margin: 10px 0;
    border: 1px solid #ccc;
    border-radius: 8px;
    outline: none;
}

.modal-buttons {
    display: flex;
    justify-content: center;
}

body.modal-open {
    overflow: hidden;
}


.password-toggle-container {
    position: relative; 
    width: 100%; 
}

.password-toggle-container input {
    width: 100%; 
    padding-right: 40px;
}

.password-toggle-icon {
    position: absolute;
    top: 65%;
    right: 15px; 
    transform: translateY(-50%);
    cursor: pointer;
    color: #9e9e9e; 
    z-index: 10; 
}

input[type="password"]::-ms-reveal,
input[type="password"]::-ms-clear {
    display: none;
}

input[type="password"]::-webkit-contacts-auto-fill-button,
input[type="password"]::-webkit-credentials-auto-fill-button {
    visibility: hidden;
    pointer-events: none;
    position: absolute;
    right: 0;
}

#frmContrasenaPM,
#frmConfirmarContrasenaPM {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}


.input-wrapper {
    display: flex; 
    flex-direction: column;
    width: 100%; 
    margin: 0 0 20px 0; 
}

.full-width-input {
    width: 80%; 
}

.input-label {
    text-align: left;
    font-size: 14px; 
    font-weight: 500;
    color: #002749;
    margin-bottom: 8px; 
    width: 100%; 
}

.container form .input-wrapper input,
.container form .password-toggle-container input {
    width: 100%; 
    margin: 0; 
}

.input-group .input-wrapper,
.input-group .password-toggle-container {
    flex: 1;
    margin: 0;
}

.terms-group {
    display: flex;
    align-items: center;
    width: 80%;
    margin: 15px 0 10px 0;
}

.terms-group input[type="checkbox"] {
    width: auto;
    margin-right: 10px;
}

.terms-group .terms-text {
    text-align: left;
    flex-grow: 1;
    margin-top: 0;
    font-size: 0.8rem;
}

.form-title {
    color: #002749; 
    margin-bottom: 20px;
}

.form-instruction {
    margin-bottom: 20px;
    font-size: 14px;
}

.password-instruction {
    width: 80%;
    text-align: left;
    margin-top: -10px;
}

.password-instruction p {
    font-size: 11px;
    line-height: 1.3;
    color: #666;
    margin: 0;
    padding: 0;
}

#frmRazonSocialPM,
#frmRFCPM {
    text-transform: uppercase;
}

.large-title {
    font-size: 2.5rem;
}

.large-margin {
    margin-bottom: 30px !important;
}

.margin-bottom-large {
    margin-bottom: 20px !important; 
}

.button-margin-top {
    margin-top: 20px !important; 
}

.login-fields-wrapper {
    width: 50%; 
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
}

.login-fields-wrapper .input-wrapper,
.login-fields-wrapper .password-toggle-container {
    width: 100%;
}

.error-message {
    width: 80%;
    font-size: 12px;
    color: #dc3545;
    text-align: left;
    margin-top: -5px;
    margin-bottom: 10px;
}

#frmLoginEmail-error, 
#frmLoginPassword-error {
    width: 50%;
    margin-left: auto;
    margin-right: auto;
}

.form-container.sign-in form a[id="recoverPassLink"],
.form-container.sign-in form button[type="submit"] {
    margin-left: auto;
    margin-right: auto;
}

.form-container.sign-in form button[type="submit"] {
     margin-top: 15px !important;
}

@media screen and (max-width: 768px) {
    
    html, body {
        overflow: auto;
        height: auto;
        min-height: 100vh;
    }
    
    body {
        padding: 20px 0;
    }
    
    .container {
        width: 100%;
        height: auto;
        min-height: 100vh;
        max-width: 100%;
        border-radius: 0;
        position: relative;
        display: flex;
        flex-direction: column;
    }
    
    .toggle-container {
        display: none !important;
    }
    
    .mobile-globe-container {
        width: 100%;
        padding: 30px 20px;
        background: linear-gradient(to bottom, #002749, #001A33);
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        text-align: center;
        color: #fff;
        order: -1;
    }
    
    .mobile-globe-container h2 {
        font-size: 1.5rem;
        margin-bottom: 10px;
        color: #fff;
    }
    
    .mobile-globe-container p {
        font-size: 13px;
        margin-bottom: 20px;
        color: rgba(255, 255, 255, 0.9);
        line-height: 1.5;
    }
    
    .mobile-globe-wrapper {
        width: 100%;
        max-width: 300px;
        height: 250px;
        position: relative;
        margin: 0 auto;
    }
    
    .mobile-globe-wrapper #globe {
        width: 100%;
        height: 100%;
    }
    
    .mobile-globe-wrapper canvas {
        width: 100% !important;
        height: 100% !important;
    }
    
    .mobile-globe-container .logo-container {
        margin-bottom: 20px;
    }
    
    .mobile-globe-container .logo-container img {
        height: 40px;
        width: auto;
    }
    
    .form-container {
        position: relative !important;
        width: 100% !important;
        height: auto !important;
        min-height: 100vh;
        transform: none !important;
        opacity: 1 !important;
        padding: 20px;
        left: 0 !important;
        top: 0 !important;
    }
    
    .container form {
        padding: 40px 20px;
        height: auto;
        width: 100%;
    }
    
    .sign-in {
        z-index: 2;
    }
    
    .sign-up {
        z-index: 1;
        display: none;
    }
    
    .container.active .sign-in {
        display: none;
        transform: none;
    }
    
    .container.active .sign-up {
        display: block;
        transform: none;
        z-index: 2;
    }
    
    .internal-navbar {
        flex-wrap: wrap;
        justify-content: center;
        gap: 15px;
        padding: 15px 0;
        margin-bottom: 20px;
    }
    
    .internal-navbar a {
        font-size: 13px;
    }
    
    .internal-navbar img {
        width: 100%;
        max-width: 120px !important;
        height: auto !important;
    }
    
    .container input {
        width: 100%;
        padding: 12px 15px;
        font-size: 14px;
    }
    
    .input-group {
        flex-direction: column;
        width: 100%;
        gap: 0;
    }
    
    .input-group .input-wrapper,
    .input-group .password-toggle-container {
        width: 100%;
        margin: 8px 0;
    }
    
    .input-wrapper,
    .full-width-input {
        width: 100% !important;
    }
    
    .login-fields-wrapper {
        width: 100% !important;
        max-width: 100%;
    }
    
    #frmLoginEmail-error, 
    #frmLoginPassword-error {
        width: 100%;
    }

    .form-container.sign-in form {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 5px;
    }

    .form-container.sign-in form button[type="submit"],
    .form-container.sign-in form a[id="recoverPassLink"] {
        width: 80%;
        margin-left: auto;
        margin-right: auto;
        text-align: center;
    }

    
   
    
    .terms-group {
        width: 100%;
        flex-direction: row;
        align-items: flex-start;
    }
    
    .terms-group input[type="checkbox"] {
        margin-top: 3px;
        flex-shrink: 0;
    }
    
    .password-instruction {
        width: 100%;
    }
    
    .mobile-toggle-buttons {
        display: flex;
        justify-content: center;
        gap: 15px;
        margin: 20px 0;
        padding: 0 20px;
    }
    
    .mobile-toggle-btn {
        background-color: transparent;
        border: 2px solid #002749;
        color: #002749;
        padding: 10px 30px;
        border-radius: 8px;
        font-weight: 600;
        font-size: 13px;
        cursor: pointer;
        transition: all 0.3s ease;
    }
    
    .mobile-toggle-btn.active {
        background-color: #002749;
        color: #fff;
    }
    
    .social-icons {
        margin: 15px 0;
    }
    
    .social-icons a {
        width: 35px;
        height: 35px;
        font-size: 14px;
    }
    
    .form-title,
    .container form h1 {
        font-size: 1.8rem !important;
        margin-bottom: 15px;
    }
    
    .container p {
        font-size: 13px;
    }
    
    .container span {
        font-size: 12px;
    }
    
    .modal-content {
        width: 90%;
        max-width: 400px;
        padding: 20px 15px;
    }
    
    #modalIcon {
        width: 100px;
        height: 100px;
    }
    
    .modal-buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .btn-primary,
    .btn-secondary {
        width: 100%;
        margin: 5px 0;
    }
    
    .modal-input {
        width: 100%;
    }
    
    .error-message {
        width: 100%;
        font-size: 12px;
        color: #dc3545;
        text-align: left;
        margin-top: -5px;
        margin-bottom: 5px;
    }
}

@media screen and (max-width: 480px) {
    
    body {
        padding: 0;
    }
    
    .container form {
        padding: 30px 15px;
    }
    
    .form-container {
        padding: 15px;
    }
    
    .container input {
        padding: 10px 12px;
        font-size: 13px;
    }
    
    .form-title,
    .container form h1 {
        font-size: 1.5rem !important;
    }
    
    .container button {
        padding: 10px 30px;
        font-size: 11px;
    }
    
    .internal-navbar {
        gap: 10px;
    }
    
    .internal-navbar img {
        max-width: 100px !important;
    }
    
    .social-icons a {
        width: 32px;
        height: 32px;
        font-size: 13px;
        margin: 0 2px;
    }
    
    .password-instruction p {
        font-size: 10px;
    }
    
    .terms-text {
        font-size: 11px;
    }
    
    .mobile-toggle-btn {
        padding: 8px 20px;
        font-size: 12px;
    }
}

@media screen and (min-width: 769px) and (max-width: 1024px) {
    
    .toggle-container {
        width: 45%;
        left: 55%;
    }
    
    .sign-in,
    .sign-up {
        width: 55%;
    }
    
    .container form {
        padding: 60px 30px;
    }
    
    .toggle-panel {
        padding: 0 20px;
    }
    
    .toggle-panel h1 {
        font-size: 1.8rem;
    }
    
    .toggle-panel img,
    #globe {
        max-height: 300px;
    }
}

@media screen and (min-width: 769px) {
    .mobile-toggle-buttons {
        display: none;
    }
}