/* =========================================
   ESTILOS BASE DE AUTENTICACIÓN (KOKORO)
   ========================================= */

/* Contenedor Principal Split */
.kk-split-wrapper {
    display: flex;
    min-height: 100vh;
    width: 100%;
    background-color: var(--background);
}

/* Panel Visual (Izquierdo) */
.kk-visual-panel {
    flex: 1;
    background-size: cover;
    background-position: center;
    display: flex;
    position: relative;
}

/* Imágenes específicas por página */
.kk-visual-login {
    background-image: url('../images/login-photo.jpg');
}

.kk-visual-register {
    background-image: url('https://images.unsplash.com/photo-1631214499500-2e34edcaccfe?fm=jpg&q=60&w=3000&auto=format&fit=crop&ixlib=rb-4.1.0&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D');
}

.kk-visual-overlay {
    flex: 1;
    background: linear-gradient(to bottom, rgba(107, 46, 46, 0.2), var(--soft-wine));
    display: flex;
    align-items: flex-end;
    padding: 4rem;
    color: white;
}

.kk-visual-tagline {
    font-size: 3rem;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
    line-height: 1.1;
    color: white;
}

.kk-visual-desc {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 2rem;
    max-width: 90%;
}

/* Panel Formulario (Derecho) */
.kk-form-panel {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background-color: white;
}

.kk-auth-box {
    width: 100%;
    max-width: 460px; /* Tamaño unificado para Login y Sign Up */
}

/* Tipografía de Cabecera */
.kk-login-header {
    margin-bottom: 2.5rem;
}

.kk-brand-title {
    color: var(--contrast);
    font-size: 2.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.kk-brand-subtitle {
    color: #666;
    font-size: 0.95rem;
}

/* Inputs y Formularios */
.kk-custom-form {
    width: 100%;
}

.kk-input-group {
    margin-bottom: 1.5rem;
}

.kk-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.kk-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--soft-wine);
    margin-bottom: 0.5rem;
}

.kk-input {
    width: 100%;
    border: 1px solid #e0e0e0;
    padding: 14px 15px;
    font-size: 1rem;
    border-radius: 0 !important; /* Estilo Cuadrado estricto */
    transition: border-color 0.3s ease;
    background-color: #fafafa;
    color: var(--contrast);
}

.kk-input:focus {
    outline: none;
    border-color: var(--soft-wine);
    background-color: white;
}

.kk-password-wrapper {
    position: relative;
    display: flex; /* Añadido para mejor alineación del input y botón */
}

.kk-view-btn {
    position: absolute;
    right: 0;
    top: 0;
    height: 100%;
    width: 45px;
    background: none;
    border: none;
    color: var(--soft-wine);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease;
}

.kk-view-btn:hover {
    color: var(--contrast);
}

/* Opciones extras (Recordarme, Olvidé mi clave) */
.kk-form-tools {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 10px;
}

.kk-mt-2 {
    margin-top: 1rem;
    margin-bottom: 1.5rem;
}

/* Checkbox Personalizado Cuadrado */
.kk-check-container {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
    color: #666;
}

.kk-check-container span {
    line-height: 1.4;
}

.kk-checkbox {
    width: 20px;
    height: 20px;
    border: 1px solid var(--soft-wine);
    cursor: pointer;
    border-radius: 0 !important;
    flex-shrink: 0;
    transition: background-color 0.2s ease;
}

.kk-checkbox.checked {
    background-color: var(--soft-wine);
    position: relative;
}

.kk-checkbox.checked::after {
    content: '✕';
    color: white;
    font-size: 12px;
    position: absolute;
    left: 4px;
    top: 1px;
}

/* Enlaces */
.kk-link {
    color: var(--soft-wine);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.kk-link:hover {
    color: var(--contrast);
    text-decoration: underline;
}

.kk-link-bold {
    color: var(--contrast);
    text-decoration: none;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.9rem;
    border-bottom: 2px solid var(--soft-wine);
    padding-bottom: 2px;
    transition: all 0.3s ease;
}

.kk-link-bold:hover {
    color: var(--soft-wine);
}

/* Botones Principales */
.kk-main-btn {
    width: 100%;
    background-color: var(--contrast);
    color: white;
    border: none;
    padding: 16px;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    border-radius: 0 !important;
    cursor: pointer;
    transition: background 0.3s ease;
    margin-top: 0.5rem;
}

.kk-main-btn:hover {
    background-color: var(--soft-wine);
}

/* Separador y Social Login */
.kk-separator {
    display: flex;
    align-items: center;
    margin: 2rem 0;
    color: #888;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.kk-separator::before,
.kk-separator::after {
    content: '';
    flex: 1;
    height: 1px;
    background-color: #eee;
}

.kk-separator span {
    padding: 0 1rem;
}

.kk-social-grid {
    display: flex;
    gap: 15px;
    margin-bottom: 2rem;
}

.kk-social-item {
    flex: 1;
    border: 1px solid #e0e0e0;
    background: white;
    color: var(--contrast);
    padding: 12px;
    font-weight: 500;
    border-radius: 0 !important;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    transition: border-color 0.2s ease, background-color 0.2s ease;
}

.kk-social-item:hover {
    border-color: var(--soft-wine);
    background-color: #fafafa;
}

/* Footer de Autenticación */
.kk-login-footer {
    text-align: center;
    margin-top: 1rem;
}

.kk-login-footer p {
    color: #666;
    font-size: 0.95rem;
}

/* Mensajes de Alerta */
.kk-alert {
    padding: 12px 15px;
    margin-bottom: 1.5rem;
    border-radius: 0 !important;
    border-left: 4px solid transparent;
    font-size: 0.9rem;
}

.kk-alert-error {
    background-color: #fff1f0;
    border-left-color: #ff4d4f;
    color: #cf1322;
}

.kk-alert-success {
    background-color: #f6ffed;
    border-left-color: #52c41a;
    color: #389e0d;
}

/* =========================================
   MEDIA QUERIES (RESPONSIVE)
   ========================================= */
@media (max-width: 991px) {
    .kk-visual-panel {
        display: none;
    }
    .kk-split-wrapper {
        min-height: calc(100vh - 60px); /* Ajusta según el alto de tu navbar */
    }
}

@media (max-width: 576px) {
    .kk-form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }
    .kk-auth-box {
        padding: 0 1rem;
    }
}