/* Reset y Base */
:root {
    --brand-blue: #0073e6;
    --dark-blue: #0059a4;
    --text-dark: #333333;
    --text-gray: #666666;
    --border-color: #cccccc;
    --bg-white: #ffffff;
    --error-red: #d32f2f;
    --success-green: #28a745;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-dark);
    height: 100vh;
    overflow: hidden;
}

/* Layout Dividido */
.split-layout {
    display: flex;
    width: 100vw;
    height: 100vh;
}

/* --- PANEL IZQUIERDO --- */
.left-panel {
    flex: 1;
    background-color: var(--bg-white);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 40px;
}

.logo-header {
    position: absolute;
    top: 50px;
    width: 100%;
    text-align: center;
}

.brand-logo {
    color: var(--brand-blue);
    font-size: 28px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.tooth-icon {
    width: 32px;
    height: 32px;
}

.form-container {
    width: 100%;
    max-width: 360px;
    position: relative;
    min-height: 400px;
}

.view {
    position: absolute;
    width: 100%;
    top: 0;
    left: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.active-view {
    opacity: 1;
    transform: translateY(0);
    pointer-events: all;
    z-index: 2;
}

.hidden-view {
    opacity: 0;
    transform: translateY(20px);
    pointer-events: none;
    z-index: 1;
}

.welcome-text {
    text-align: center;
    margin-bottom: 30px;
}

.welcome-text h2 {
    font-size: 24px;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 10px;
}

.tenant-name {
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Alerta de Error */
.error-alert {
    background: #FEE2E2;
    border: 1px solid #FCA5A5;
    border-radius: 8px;
    padding: 12px 14px;
    margin-bottom: 20px;
    font-size: 13px;
    color: #DC2626;
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
}

.helper-text {
    font-size: 12px;
    color: var(--text-gray);
    margin-top: 4px;
    display: inline-block;
}

/* Inputs y Subdominio */
.input-group {
    position: relative;
    margin-bottom: 16px;
    width: 100%;
}

.domain-group {
    display: flex;
    align-items: stretch;
}

.domain-group input {
    flex: 1;
    border-radius: 4px 0 0 4px;
    border-right: none;
}

.domain-suffix {
    background: rgba(0,0,0,0.03);
    border: 1px solid var(--border-color);
    border-left: none;
    border-radius: 0 4px 4px 0;
    padding: 0 14px;
    display: flex;
    align-items: center;
    color: var(--text-gray);
    font-size: 14px;
    white-space: nowrap;
}

.input-group input {
    width: 100%;
    padding: 14px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 14px;
    font-family: inherit;
    color: var(--text-dark);
    outline: none;
    transition: border-color 0.2s;
}

.input-group input:focus {
    border-color: var(--brand-blue);
}

.input-group input::placeholder {
    color: #999;
}

.password-group .toggle-password {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: #999;
}

.eye-icon {
    width: 20px;
    height: 20px;
}

/* Simulación Captcha */
.captcha-box {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 10px 15px;
    margin-bottom: 20px;
    background: #fafafa;
}

.captcha-content {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    color: var(--text-dark);
}

.check-icon {
    color: white;
    background-color: var(--success-green);
    border-radius: 50%;
    padding: 3px;
    width: 24px;
    height: 24px;
}

.captcha-brand {
    text-align: right;
    color: #666;
}

.captcha-links {
    font-size: 9px;
}

/* Botones */
.btn-primary {
    width: 100%;
    padding: 14px;
    background-color: var(--brand-blue);
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s;
}

.btn-primary:hover {
    background-color: #005bb5;
}

.form-footer {
    text-align: center;
    margin-top: 20px;
}

.forgot-link {
    color: #999;
    font-size: 13px;
    text-decoration: none;
}

.forgot-link:hover {
    text-decoration: underline;
}

/* --- PANEL DERECHO --- */
.right-panel {
    flex: 1;
    background-color: var(--dark-blue);
    position: relative;
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 60px;
}

/* Slider Styles */
.slider-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center bottom;
    background-repeat: no-repeat;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    display: flex;
    align-items: center;
    padding: 60px;
    z-index: 0;
}

.slide::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Gradiente para asegurar legibilidad del texto sobre cualquier imagen */
    background: linear-gradient(to right, rgba(0, 89, 164, 0.98) 0%, rgba(0, 89, 164, 0.3) 100%);
    z-index: 1;
}

.slide.active-slide {
    opacity: 1;
    z-index: 2;
}

.slide-content {
    position: relative;
    z-index: 3;
    max-width: 450px;
}

.slide-content h2 {
    font-size: 36px;
    font-weight: 600;
    margin-bottom: 20px;
    line-height: 1.2;
}

.slide-content p {
    font-size: 16px;
    line-height: 1.5;
    margin-bottom: 30px;
    opacity: 0.9;
}

.slider-dots {
    position: absolute;
    bottom: 40px;
    left: 60px;
    z-index: 10;
    display: flex;
    gap: 12px;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition: all 0.3s;
}

.dot.active-dot {
    background-color: white;
    transform: scale(1.3);
}

.btn-outline {
    padding: 12px 24px;
    background: transparent;
    border: 1px solid white;
    color: white;
    font-size: 14px;
    font-weight: 500;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-outline:hover {
    background: white;
    color: var(--dark-blue);
}

/* Responsividad básica */
@media (max-width: 768px) {
    .split-layout {
        flex-direction: column;
    }
    
    .right-panel {
        display: none; /* Ocultar panel derecho en móviles como suele ser estándar */
    }
}
