/* PDC CUSTOM LOGIN STYLES - SCOPED VERSION */

:root {
    --pdc-primary: rgb(104, 153, 52);
    --pdc-primary-soft: rgba(104, 153, 52, 0.1);
    --pdc-success: rgb(76, 133, 36);
    --pdc-danger: rgb(198, 28, 28);
    --pdc-warning: rgb(243, 137, 68);
    --pdc-gray-100: #f3f4f6;
    --pdc-gray-200: #e5e7eb;
    --pdc-gray-700: #374151;
    --pdc-gray-800: #1f2937;
    --pdc-gray-900: #111827;
}

/* Aggressive Reset SCOPED to login only */
.pdc-login-wrapper ~ .fi-simple-layout,
body:has(.pdc-login-wrapper) .fi-simple-layout {
    display: block !important;
    background: white !important;
    min-height: 100vh !important;
}

.dark .pdc-login-wrapper ~ .fi-simple-layout,
.dark body:has(.pdc-login-wrapper) .fi-simple-layout {
    background: var(--pdc-gray-900) !important;
}

body:has(.pdc-login-wrapper) .fi-simple-main {
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
    max-width: none !important;
    height: 100vh !important;
    min-height: 100vh !important;
    display: flex !important;
    align-items: stretch !important;
    justify-content: stretch !important;
    background: white !important;
}

.dark body:has(.pdc-login-wrapper) .fi-simple-main {
    background: var(--pdc-gray-900) !important;
}

body:has(.pdc-login-wrapper) .fi-simple-main section {
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
    max-width: none !important;
    height: 100% !important;
    min-height: 100% !important;
    background: transparent !important;
    box-shadow: none !important;
    border: none !important;
    display: block !important;
}

body:has(.pdc-login-wrapper) .fi-simple-main-ctn {
    padding: 0 !important;
    margin: 0 !important;
    max-width: none !important;
    width: 100% !important;
}

/* Base Wrapper */
.pdc-login-wrapper {
    display: flex;
    min-height: 100vh;
    width: 100%;
    background: white;
    font-family: 'AptosNarrow', sans-serif;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 1; 
}

.dark .pdc-login-wrapper {
    background: var(--pdc-gray-900);
}

/* Ensure Filament Notifications are ALWAYS on top of the fixed wrapper */
.fi-notifications {
    z-index: 10000 !important;
}

/* ══════════════════════════════════
   IZQUIERDA: Branding
   ══════════════════════════════════ */
.pdc-login-image-side {
    position: relative;
    width: 45%;
    background: linear-gradient(135deg, #2d3748 0%, #1a202c 100%); /* Neutral dark background */
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    color: white;
    padding: 4rem;
}

.pdc-bg-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.4;
    mix-blend-mode: normal; /* Normal blend to see the video better */
}

.pdc-image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(104, 153, 52, 0.4), rgba(0,0,0,0.6)); /* Subtle green to dark overlay */
}

.pdc-brand-content {
    position: relative;
    z-index: 10;
    text-align: center;
    max-width: 550px;
}

.pdc-brand-badge {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    padding: 0.6rem 2rem;
    border-radius: 50px;
    display: inline-block;
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.pdc-brand-headline {
    font-size: 4rem;
    font-weight: 900;
    line-height: 1;
    margin-bottom: 2rem;
    text-transform: uppercase;
    letter-spacing: -1px;
}

.pdc-brand-headline span {
    display: block;
    color: #fff;
    text-shadow: 0 10px 20px rgba(0,0,0,0.2);
    font-size: 6rem;
    margin-top: 0.5rem;
}

.pdc-brand-sub {
    font-size: 1.25rem;
    opacity: 0.95;
    line-height: 1.6;
    font-weight: 500;
}

/* ══════════════════════════════════
   DERECHA: Formulario
   ══════════════════════════════════ */
.pdc-login-form-side {
    width: 55%;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    position: relative;
}

.dark .pdc-login-form-side {
    background: var(--pdc-gray-900);
}

.pdc-form-container {
    width: 100%;
    max-width: 480px;
}

.pdc-logo-wrap {
    text-align: center;
    margin-bottom: 3.5rem;
}

.pdc-logo {
    height: 120px;
    display: inline-block;
    filter: drop-shadow(0 5px 15px rgba(0,0,0,0.05));
}

.pdc-form-header {
    text-align: center;
    margin-bottom: 3rem;
}

.pdc-form-title {
    font-size: 2.8rem;
    font-weight: 800;
    color: var(--pdc-gray-700);
    margin-bottom: 0.75rem;
    letter-spacing: -0.5px;
}

.dark .pdc-form-title {
    color: white;
}

.pdc-form-subtitle {
    color: #6b7280;
    font-size: 1.15rem;
}

.dark .pdc-form-subtitle {
    color: #9ca3af;
}

.pdc-divider {
    display: flex;
    align-items: center;
    margin: 3rem 0;
}

.pdc-divider-line {
    flex: 1;
    height: 1px;
    background: var(--pdc-gray-200);
}

.dark .pdc-divider-line {
    background: var(--pdc-gray-700);
}

.pdc-divider-icon {
    padding: 0 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pdc-icon {
    width: 2.5rem;
    height: 2.5rem;
    color: var(--pdc-primary);
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1));
}

/* Filament Overrides SCOPED to the PDC wrapper */
.pdc-login-wrapper .fi-btn {
    background-color: var(--pdc-primary) !important;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
    border-radius: 12px !important;
    padding: 0.85rem !important;
    font-weight: 700 !important;
    font-size: 1.1rem !important;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06) !important;
}

.pdc-login-wrapper .fi-btn:hover {
    background-color: var(--pdc-success) !important;
    transform: translateY(-3px);
    box-shadow: 0 20px 25px -5px rgba(104, 153, 52, 0.3), 0 10px 10px -5px rgba(104, 153, 52, 0.2) !important;
}

.pdc-login-wrapper .fi-btn:active {
    transform: translateY(-1px);
}

/* Hyper-specific Label Overrides */
.pdc-login-wrapper .fi-fo-field-wrp-label label,
.pdc-login-wrapper .fi-fo-field-wrp-label span,
.pdc-login-wrapper .fi-fo-field-wrp-label-text {
    font-weight: 900 !important;
    color: var(--pdc-gray-700) !important;
    font-size: 1.3rem !important;
    margin-bottom: 0.85rem !important;
    display: inline-block !important;
    letter-spacing: -0.5px !important;
    text-transform: none !important;
}

.dark .pdc-login-wrapper .fi-fo-field-wrp-label label,
.dark .pdc-login-wrapper .fi-fo-field-wrp-label span,
.dark .pdc-login-wrapper .fi-fo-field-wrp-label-text {
    color: white !important;
}

.pdc-login-wrapper .fi-input-wrp {
    border-radius: 10px !important;
    transition: all 0.3s ease !important;
    border-color: var(--pdc-gray-200) !important;
}

.dark .pdc-login-wrapper .fi-input-wrp {
    background-color: var(--pdc-gray-800) !important;
    border-color: var(--pdc-gray-700) !important;
}

.dark .pdc-login-wrapper .fi-input-wrp input {
    color: white !important;
}

.pdc-login-wrapper .fi-input-wrp:focus-within {
    border-color: var(--pdc-primary) !important;
    box-shadow: 0 0 0 3px var(--pdc-primary-soft) !important;
}

.pdc-form-footer {
    margin-top: 4rem;
    text-align: center;
    font-size: 0.95rem;
    color: #9ca3af;
    border-top: 1px solid var(--pdc-gray-100);
    padding-top: 2rem;
}

/* Responsive */
@media (max-width: 1200px) {
    .pdc-brand-headline { font-size: 3rem; }
    .pdc-brand-headline span { font-size: 4.5rem; }
}

@media (max-width: 1024px) {
    body:has(.pdc-login-wrapper) .fi-simple-main {
        flex-direction: column !important;
        height: auto !important;
        min-height: 100vh !important;
    }
    .pdc-login-wrapper {
        flex-direction: column !important;
        position: relative !important;
        height: auto !important;
        width: 100% !important;
    }
    .pdc-login-image-side {
        width: 100% !important;
        height: 350px !important;
        padding: 2.5rem !important;
    }
    .pdc-login-form-side {
        width: 100% !important;
        padding: 3.5rem 1.5rem !important;
    }
}


