/* Estilos generales - Tema Claro Minimalista */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, sans-serif;
}

body {
    background-color: #ffffff; 
    color: #000000;
}

body.inicio {
    background-color: #ffffff;
}

/* --- ESTILOS DEL ENCABEZADO ESTRUCTURADO (UNA SOLA LÍNEA) --- */
header {
    background-color: #ffffff; 
    color: #000000;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 20px;
    width: 100%;
}

body.inicio header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    border-bottom: 1px solid #e0e0e0;
}

/* Fila Central - Alineación de Logo e Iniciar Sesión */
.middle-bar {
    display: contents; 
}

.logo-area {
    order: 1;
    display: flex;
    align-items: center;
}

.bottom-bar {
    order: 2;
    flex: 1;
    display: flex;
    justify-content: center;
    border-top: none;
    padding: 0 20px;
}

.user-actions {
    order: 3;
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.header-logo {
    height: 70px; 
    width: auto;
    display: block;
    object-fit: contain; 
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1)); 
}

.action-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #000000;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.action-btn:hover {
    color: #555555;
    transform: scale(1.05); 
}

.action-btn .icon {
    font-size: 1.8rem; 
}

.action-btn .text {
    line-height: 1.2;
    text-align: left;
    font-weight: bold;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 20px; 
    align-items: center;
    justify-content: center; 
    flex-wrap: nowrap; 
    width: 100%; 
}

.nav-links a {
    color: #000000;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: bold;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    white-space: nowrap; 
}

.nav-links a:hover {
    color: #666666;
}

/* --- ESTILOS GENERALES Y LAYOUT --- */
main {
    max-width: 1200px;
    margin: 40px auto 100px auto; 
    padding: 0 20px;
    text-align: center;
    min-height: 60vh;
}

body.inicio main {
    margin: 120px auto 100px auto; 
}

.special-hero {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 50px;
}

.hero h2 {
    font-size: 2.5rem;
    margin-bottom: 15px;
    color: #000000; 
}

body.inicio .hero h2 {
    font-family: "Garamond", "Times New Roman", serif; 
    font-weight: bold;
}

.hero p {
    font-size: 1.2rem;
    color: #333333;
}

.slider-container {
    width: 100%;
    max-width: 900px;
    margin: 40px auto;
    overflow: hidden;
    border-radius: 20px; 
    box-shadow: 0 10px 30px rgba(0,0,0,0.1); 
    position: relative;
    border: 1px solid #e0e0e0; 
}

.slider {
    display: flex;
    width: 300%;
    animation: deslizar 15s infinite;
}

.slide {
    width: 33.3333%;
}

.slide img {
    width: 100%;
    height: 450px;
    object-fit: cover;
    display: block;
}

@keyframes deslizar {
    0% { transform: translateX(0); }
    25% { transform: translateX(0); }
    33% { transform: translateX(-33.3333%); }
    58% { transform: translateX(-33.3333%); }
    66% { transform: translateX(-66.6666%); }
    91% { transform: translateX(-66.6666%); }
    100% { transform: translateX(0); }
}

footer {
    background-color: #f9f9f9; 
    color: #333333;
    text-align: center;
    padding: 1.5rem 0;
    width: 100%;
    border-top: 1px solid #e0e0e0;
}

body.inicio footer {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    position: fixed;
    bottom: 0;
    z-index: 1000;
    box-shadow: 0 -4px 15px rgba(0,0,0,0.05); 
    border-top: 1px solid #e0e0e0;
    color: #000000;
}

/* --- ESTILOS PARA EL SLIDER DE SERVICIOS --- */
.slider-wrapper-parent {
    position: relative;
    display: flex;
    align-items: center;
    max-width: 1100px;
    margin: 0 auto;
}

.slider-servicios-wrapper {
    width: 100%;
    overflow-x: scroll;
    padding: 30px 0;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
}

.slider-servicios-wrapper::-webkit-scrollbar {
    display: none;
}

.slider-servicios {
    display: flex;
    gap: 20px;
    padding: 0 50px;
    width: max-content;
}

.servicio-slide {
    position: relative;
    width: 300px;
    height: 450px;
    border-radius: 15px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    scroll-snap-align: center;
    flex-shrink: 0;
}

.servicio-slide:hover {
    transform: translateY(-10px);
}

.servicio-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    background-color: #f5f5f5;
}

.nav-btn {
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid #e0e0e0;
    color: #000;
    font-size: 1.5rem;
    padding: 15px;
    cursor: pointer;
    border-radius: 50%;
    z-index: 10;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.nav-btn:hover {
    background: #000;
    color: #fff;
}

.overlay-info {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.98);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 30px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    text-align: center;
}

.servicio-slide.activo .overlay-info {
    opacity: 1;
    visibility: visible;
}

.servicio-tag {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #888;
    margin-bottom: 15px;
}

.overlay-info h3 {
    font-family: "Garamond", serif;
    font-size: 1.5rem;
    margin-bottom: 20px;
    color: #000;
}

.overlay-info p {
    font-size: 0.9rem;
    line-height: 1.8;
    color: #444;
}

/* --- ESTILOS PARA UBICACIÓN --- */
.location-header-modern h2 {
    font-family: "Garamond", serif;
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.location-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
    max-width: 1100px;
    margin: 50px auto;
}

.location-card-modern {
    background: #ffffff;
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid #f0f0f0;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    transition: transform 0.3s ease;
}

.location-card-modern:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.1);
}

.card-image-header {
    background: #000;
    padding: 30px;
    color: #fff;
    text-align: center;
}

.card-image-header h3 {
    font-family: "Garamond", serif;
    font-size: 1.8rem;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.card-body {
    padding: 30px;
    text-align: left;
}

.info-group {
    margin-bottom: 20px;
}

.info-group strong {
    display: block;
    font-size: 0.75rem;
    color: #888;
    letter-spacing: 1px;
    margin-bottom: 5px;
}

.info-group p {
    font-size: 1rem;
    color: #333;
}

.map-container-mini {
    margin: 20px 0;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid #eee;
}

.btn-ruta {
    display: block;
    width: 100%;
    padding: 15px;
    background: #000;
    color: #fff;
    text-decoration: none;
    text-align: center;
    border-radius: 10px;
    font-weight: bold;
    font-size: 0.9rem;
    transition: background 0.3s;
}

.btn-ruta:hover {
    background: #444;
}

@media (max-width: 768px) {
    .location-grid {
        grid-template-columns: 1fr;
        padding: 0 20px;
    }
}

/* --- ESTILOS DE ACERCA DE MODERNO --- */
.about-header-modern {
    margin-bottom: 60px;
    text-align: center;
}

.about-header-modern h2 {
    font-family: "Garamond", serif;
    font-size: 2.8rem;
    margin-bottom: 10px;
    font-weight: bold;
    letter-spacing: -1px;
}

.about-header-modern p {
    font-size: 1.1rem;
    color: #666;
    max-width: 600px;
    margin: 0 auto;
}

.about-bento-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    grid-template-rows: auto auto;
    gap: 30px;
    max-width: 1100px;
    margin: 0 auto 100px auto;
    text-align: left;
}

.bento-box {
    background: #fff;
    border-radius: 24px;
    border: 1px solid #f0f0f0;
    padding: 50px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 10px 30px rgba(0,0,0,0.03);
}

.bento-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.08);
    border-color: #000;
}

.card-number-watermark {
    position: absolute;
    bottom: -20px;
    right: 20px;
    font-size: 12rem;
    font-weight: bold;
    color: rgba(0,0,0,0.03);
    user-select: none;
    z-index: 0;
    font-family: Arial, sans-serif;
}

.about-text-block {
    grid-row: 1 / 3;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.about-text-block h3 {
    font-family: "Garamond", serif;
    font-size: 2.2rem;
    margin-bottom: 20px;
    color: #000;
    z-index: 1;
    font-weight: bold;
}

.about-text-block p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #444;
    z-index: 1;
}

.bento-stack-right {
    display: grid;
    grid-template-rows: 1fr 1fr;
    gap: 30px;
}

.mission-block, .vision-block, .values-block {
    padding: 40px;
}

.mission-block h4, .vision-block h4, .values-block h4 {
    font-family: "Garamond", serif;
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: #000;
    z-index: 1;
    font-weight: bold;
}

.mission-block p, .vision-block p {
    font-size: 1rem;
    line-height: 1.6;
    color: #555;
    z-index: 1;
}

.values-block {
    background: #fcfcfc;
    grid-column: 2 / 3;
}

.values-list-modern {
    list-style-type: none;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 1;
}

.values-list-modern li {
    font-size: 1rem;
    line-height: 1.6;
    color: #555;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 10px;
}

.value-bullet {
    color: #000; 
    font-size: 1.2rem;
}

/* --- ESTILOS ESPECIALIDADES --- */
.especialidades-header-modern {
    margin-bottom: 60px;
    text-align: center;
}

.especialidades-header-modern h2 {
    font-family: "Garamond", serif;
    font-size: 2.8rem;
    margin-bottom: 10px;
    font-weight: bold;
    letter-spacing: -1px;
}

.especialidades-header-modern p {
    font-size: 1.1rem;
    color: #666;
    max-width: 600px;
    margin: 0 auto;
}

.especialidades-bento-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: minmax(280px, auto);
    gap: 30px;
    max-width: 1000px;
    margin: 0 auto 100px auto;
}

.bento-esp-card {
    background: #fff;
    border-radius: 24px;
    border: 1px solid #f0f0f0;
    padding: 40px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 10px 30px rgba(0,0,0,0.03);
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: left;
}

.bento-esp-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.08);
    border-color: #000;
}

.esp-watermark {
    position: absolute;
    bottom: -20px;
    right: -10px;
    font-size: 12rem;
    opacity: 0.03;
    user-select: none;
    z-index: 0;
    filter: grayscale(100%);
}

.esp-icon-modern {
    font-size: 3.5rem;
    margin-bottom: 20px;
    z-index: 1;
}

.bento-esp-card h3 {
    font-family: "Garamond", serif;
    font-size: 1.8rem;
    margin-bottom: 15px;
    color: #000;
    z-index: 1;
    font-weight: bold;
}

.bento-esp-card p {
    font-size: 1.05rem;
    line-height: 1.7;
    color: #555;
    z-index: 1;
}

.neuro-pediatra-block { grid-column: span 1; background: #fcfcfc; }
.internista-geriatra-block { grid-column: span 1; }
.neuropsi-block { grid-column: span 1; }
.rehab-block { grid-column: span 1; background: #fcfcfc; }

@media (max-width: 768px) {
    .especialidades-bento-grid {
        grid-template-columns: 1fr;
        padding: 0 20px;
    }
    .neuro-pediatra-block, .internista-geriatra-block, .neuropsi-block, .rehab-block {
        grid-column: span 1;
    }
}

/* --- ESTILOS DE LOGIN Y REGISTRO --- */
.login-main {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 75vh;
    padding: 40px 0;
}

.login-wrapper {
    width: 100%;
    max-width: 1100px;
    padding: 0 20px;
}

.login-bento-box {
    display: grid;
    grid-template-columns: 1.1fr 1.3fr;
    background: #fff;
    border-radius: 30px;
    border: 1px solid #eaeaea;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0,0,0,0.04);
}

.relative-box {
    position: relative;
    overflow: hidden;
}

.login-watermark {
    position: absolute;
    bottom: -30px;
    left: -20px;
    font-size: 15rem;
    opacity: 0.02;
    z-index: 0;
    user-select: none;
    filter: grayscale(100%);
}

.info-content-z {
    position: relative;
    z-index: 1;
}

.login-info-side {
    background: #fcfcfc;
    padding: 60px 50px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border-right: 1px solid #f0f0f0;
}

.login-info-side h2 {
    font-family: "Garamond", serif;
    font-size: 2.8rem;
    margin-bottom: 15px;
    color: #000;
    font-weight: bold;
    letter-spacing: -0.5px;
}

.login-info-side p {
    font-size: 1.1rem;
    color: #666;
    margin-bottom: 40px;
    line-height: 1.6;
}

.roles-grid-modern {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.role-card {
    background: #fff;
    padding: 20px;
    border-radius: 16px;
    border: 1px solid #eee;
    transition: all 0.3s ease;
}

.role-card:hover {
    transform: translateY(-3px);
    border-color: #ccc;
    box-shadow: 0 5px 15px rgba(0,0,0,0.03);
}

.full-width-role {
    grid-column: span 2;
    background: #fafafa;
}

.role-icon {
    font-size: 1.5rem;
    margin-bottom: 10px;
}

.role-card strong {
    display: block;
    font-size: 1rem;
    color: #000;
    margin-bottom: 4px;
}

.role-card span {
    font-size: 0.85rem;
    color: #777;
    line-height: 1.4;
    display: block;
}

.login-form-side {
    padding: 60px 70px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: #ffffff;
}

.form-header {
    margin-bottom: 40px;
}

.form-header h3 {
    font-size: 2rem;
    margin-bottom: 8px;
    color: #000;
}

.form-header p {
    color: #666;
    font-size: 1rem;
}

.cineg-form .input-group {
    margin-bottom: 25px;
    text-align: left;
    width: 100%;
}

.cineg-form .form-row {
    display: flex;
    gap: 15px;
}

.cineg-form label {
    display: block;
    font-size: 0.85rem;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #555;
    margin-bottom: 10px;
}

.cineg-form input {
    width: 100%;
    padding: 16px 20px;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    font-size: 1rem;
    background: #fcfcfc;
    transition: all 0.3s ease;
}

.cineg-form input:focus {
    outline: none;
    border-color: #000;
    background: #fff;
    box-shadow: 0 0 0 4px rgba(0,0,0,0.03);
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 35px;
    font-size: 0.95rem;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #444;
    cursor: pointer;
}

.forgot-password {
    color: #000;
    text-decoration: none;
    font-weight: bold;
    border-bottom: 1px solid transparent;
    transition: border-color 0.3s;
}

.forgot-password:hover {
    border-color: #000;
}

.btn-submit {
    width: 100%;
    padding: 18px;
    background: #000;
    color: #fff;
    border: none;
    border-radius: 12px;
    font-size: 1.05rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

.btn-submit:hover {
    background: #333;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
}

.modern-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 35px 0;
    color: #aaa;
    font-size: 0.85rem;
    letter-spacing: 2px;
}

.modern-divider::before,
.modern-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid #eee;
}

.modern-divider span {
    padding: 0 15px;
}

.register-prompt-modern {
    text-align: center;
}

.register-prompt-modern p {
    font-size: 0.95rem;
    color: #666;
    margin-bottom: 15px;
}

.btn-register-modern {
    display: inline-block;
    padding: 14px 30px;
    background: #fff;
    color: #000;
    text-decoration: none;
    border: 1px solid #ccc;
    border-radius: 12px;
    font-weight: bold;
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.btn-register-modern:hover {
    border-color: #000;
    background: #fafafa;
}

/* --- ESTILOS DE DASHBOARDS GLOBALES --- */
.dashboard-main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px 100px;
    text-align: left;
}

.dashboard-header-modern {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 40px;
    border-bottom: 2px solid #f0f0f0;
    padding-bottom: 20px;
}

.welcome-text h2 {
    font-family: "Garamond", serif;
    font-size: 2.8rem;
    color: #000;
    margin-bottom: 10px;
    font-weight: bold;
    letter-spacing: -0.5px;
}

.welcome-text p {
    color: #666;
    font-size: 1.1rem;
}

.date-badge span {
    display: inline-block;
    padding: 8px 16px;
    background: #f9f9f9;
    border: 1px solid #eaeaea;
    border-radius: 20px;
    font-size: 0.9rem;
    color: #555;
    font-weight: bold;
}

.dashboard-bento-grid-modern {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

.dash-card-modern {
    background: #fff;
    border-radius: 24px;
    padding: 35px;
    border: 1px solid #eaeaea;
    box-shadow: 0 10px 30px rgba(0,0,0,0.02);
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
}

.dash-card-modern:hover {
    transform: translateY(-4px);
    border-color: #ccc;
    box-shadow: 0 15px 40px rgba(0,0,0,0.05);
}

.dash-card-modern.span-2 { grid-column: span 2; }
.dash-card-modern.span-3 { grid-column: span 3; }

.dash-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 25px;
}

.dash-card-header h3 {
    font-size: 1.4rem;
    color: #000;
    font-weight: bold;
    font-family: "Garamond", serif;
    margin: 0;
}

.icon-circle {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 20px;
}

.dark-icon { background: #f0f0f0; color: #000; }
.light-icon { background: rgba(255,255,255,0.1); color: #fff; }

.highlight-card {
    background: #000;
    color: #fff;
    border: none;
}

.highlight-card .dash-card-header h3 { color: #fff; }

.status-badge-modern {
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: bold;
}

.confirmed-dark {
    background: rgba(255,255,255,0.15);
    color: #fff;
    border: 1px solid rgba(255,255,255,0.3);
}

.badge-paid {
    background: #e6f4ea;
    color: #1e8e3e;
    border: 1px solid #1e8e3e;
}

.badge-pending {
    background: #fef7e0;
    color: #f9ab00;
    border: 1px solid #f9ab00;
}

.highlight-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.highlight-info h4 {
    font-size: 1.6rem;
    margin-bottom: 8px;
    font-weight: bold;
}

.doc-name-light { color: #aaa; font-size: 1rem; }

.highlight-datetime {
    display: flex;
    gap: 30px;
}

.time-block {
    display: flex;
    flex-direction: column;
}

.time-block .label {
    font-size: 0.8rem;
    color: #888;
    letter-spacing: 1px;
    margin-bottom: 5px;
}

.time-block strong { font-size: 1.2rem; }

.card-footer-actions {
    display: flex;
    gap: 15px;
}

.light-btn { background: #fff; color: #000; }
.light-btn:hover { background: #eee; }

.outline-light {
    background: transparent;
    color: #fff;
    border: 1px solid rgba(255,255,255,0.3);
}
.outline-light:hover { background: rgba(255,255,255,0.1); }

.border-none { border: none !important; }
.cursor-pointer { cursor: pointer; }
.w-100 { width: 100%; }

.dash-action-btn {
    display: inline-block;
    padding: 14px 24px;
    text-decoration: none;
    border-radius: 12px;
    font-weight: bold;
    text-align: center;
    transition: all 0.3s;
}

.dark-btn { background: #000; color: #fff; width: 100%; }
.dark-btn:hover { background: #333; }

.outline-dark {
    background: transparent;
    color: #000;
    border: 1px solid #ccc;
    width: 100%;
}
.outline-dark:hover { border-color: #000; background: #fafafa; }

.tight-btn { padding: 10px 20px; font-size: 0.9rem; }
.spacer { flex-grow: 1; }

.profile-card { background: #fafafa; }

.profile-list-modern {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.profile-list-modern li {
    display: flex;
    justify-content: space-between;
    border-bottom: 1px solid #eaeaea;
    padding-bottom: 10px;
}
.profile-list-modern li:last-child { border-bottom: none; }

.p-label { color: #666; font-size: 0.9rem; }
.p-value { color: #000; font-size: 0.95rem; text-align: right; }

.result-list-modern {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.result-item-modern {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: #fafafa;
    border-radius: 16px;
    border: 1px solid #eee;
    transition: background 0.3s;
}
.result-item-modern:hover { background: #f0f0f0; }

.result-info-modern strong {
    display: block;
    color: #000;
    font-size: 1.05rem;
    margin-bottom: 5px;
}

.result-info-modern span { font-size: 0.85rem; color: #666; }

.btn-download-modern {
    color: #000;
    text-decoration: none;
    font-weight: bold;
    padding: 10px 18px;
    border: 1px solid #ccc;
    border-radius: 10px;
    font-size: 0.85rem;
    transition: all 0.3s;
    white-space: nowrap;
    background: #fff;
}
.btn-download-modern:hover { border-color: #000; background: #000; color: #fff; }

.support-banner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    flex-direction: row;
    padding: 30px 40px;
}

.support-content { display: flex; align-items: center; gap: 20px; }
.support-content .icon-circle { margin-bottom: 0; }

.support-text h3 { margin-bottom: 5px; font-size: 1.3rem; }
.support-text p { color: #666; font-size: 0.95rem; margin: 0; }
.support-banner .dash-action-btn { width: auto; white-space: nowrap; }

/* CLASES PARA PANELES MÉDICO Y ASISTENTE */
.patient-list {
    list-style: none;
    display: flex;
    flex-direction: column;
}

.patient-item {
    display: flex;
    align-items: center;
    padding: 20px 0;
    border-bottom: 1px solid #eee;
    gap: 20px;
}

.p-time {
    font-weight: bold;
    font-size: 1.1rem;
    color: #000;
    min-width: 90px;
}

.p-details {
    flex-grow: 1;
}

.p-details strong {
    display: block;
    font-size: 1.1rem;
    color: #000;
    margin-bottom: 4px;
}

.p-details span {
    font-size: 0.9rem;
    color: #666;
}

.cash-summary-modern {
    display: flex;
    flex-direction: column;
    margin-bottom: 20px;
}

.cash-amount {
    font-size: 3.5rem;
    font-weight: bold;
    color: #fff;
    font-family: "Garamond", serif;
    line-height: 1;
    margin-bottom: 5px;
}

.cash-label {
    color: #aaa;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* CLASES EXCLUSIVAS DEL ADMINISTRADOR */
.admin-metrics-split {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 30px;
    margin-top: 30px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 35px;
}

.split-divider {
    width: 1px;
    background: rgba(255, 255, 255, 0.1);
}

.doctor-split-section {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.metric-label {
    color: #aaa;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 5px;
    display: block;
}

.metric-value {
    font-weight: bold;
    color: #fff;
    font-family: "Garamond", serif;
}

/* --- ESTILOS PARA VENTANAS EMERGENTES (MODALES) --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    display: none; 
    justify-content: center;
    align-items: center;
    z-index: 2000;
}

.modal-box {
    background: #fff;
    width: 90%;
    max-width: 550px;
    padding: 40px;
    border-radius: 24px;
    position: relative;
    box-shadow: 0 25px 50px rgba(0,0,0,0.2);
    animation: modalAparecer 0.3s ease-out forwards;
}

@keyframes modalAparecer {
    from { opacity: 0; transform: translateY(20px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.modal-close {
    position: absolute;
    top: 25px;
    right: 25px;
    background: transparent;
    border: none;
    font-size: 1.8rem;
    color: #888;
    cursor: pointer;
    transition: color 0.3s;
}

.modal-close:hover { color: #000; }

.modal-title {
    font-family: "Garamond", serif;
    font-size: 2rem;
    color: #000;
    margin-bottom: 10px;
    font-weight: bold;
}

.modal-subtitle {
    color: #666;
    font-size: 1rem;
    margin-bottom: 30px;
}

.modal-content-info p {
    font-size: 1.05rem;
    color: #444;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #f0f0f0;
}

.modal-content-info p strong {
    color: #000;
    display: inline-block;
    width: 120px;
}

.modal-alert-box {
    background: #fdfaf2;
    border-left: 4px solid #f9ab00;
    padding: 15px;
    margin: 25px 0;
    border-radius: 0 8px 8px 0;
}

.modal-alert-box strong {
    display: block;
    color: #d69200;
    margin-bottom: 5px;
}

.modal-alert-box p {
    border: none;
    margin: 0;
    padding: 0;
    font-size: 0.95rem;
    color: #666;
}

.modal-select {
    width: 100%;
    padding: 16px 20px;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    font-size: 1rem;
    background: #fcfcfc;
    transition: all 0.3s ease;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
}

.modal-select:focus {
    outline: none;
    border-color: #000;
}

/* --- ADAPTACIÓN A DISPOSITIVOS MÓVILES --- */
@media (max-width: 900px) {
    header {
        flex-direction: column;
        padding: 15px;
        gap: 15px;
    }
    
    .middle-bar {
        display: flex;
        width: 100%;
        justify-content: space-between;
        align-items: center;
        order: 1;
    }

    .logo-area {
        order: 1;
    }

    .user-actions {
        order: 2;
    }

    .bottom-bar {
        order: 2;
        width: 100%;
        overflow-x: auto;
        padding-bottom: 5px;
        justify-content: flex-start;
    }

    .nav-links {
        justify-content: flex-start;
        gap: 15px;
    }

    .dashboard-bento-grid-modern {
        grid-template-columns: 1fr;
    }
    .dash-card-modern.span-2, 
    .dash-card-modern.span-3 {
        grid-column: span 1;
    }
    .dashboard-header-modern {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    .highlight-content {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }
    .support-banner {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }
    .support-banner .dash-action-btn {
        width: 100%;
    }
    .result-item-modern {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    .btn-download-modern {
        width: 100%;
        text-align: center;
    }
    .modal-box {
        padding: 30px 20px;
    }
    .patient-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    .p-actions {
        width: 100%;
        flex-direction: row !important;
        justify-content: space-between;
    }
    .admin-metrics-split {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .split-divider {
        width: 100%;
        height: 1px;
    }
}