:root {
    --primary: #15124a;
    --secondary: #0c85a6;
    --success: #1f8f4d;
    --danger: #b91c1c;
    --light: #f5f7fb;
    --border: #d8dee9;
    --text: #1f2937;
}

* {
    box-sizing: border-box;
}

body {
    font-family: Arial, Helvetica, sans-serif;
    margin: 0;
    background: var(--light);
    color: var(--text);
}

.topbar {
    background: white;
    border-bottom: 1px solid var(--border);
    padding: 12px 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.brand {
    display: flex;
    align-items: center;
    gap: 14px;
}

.logo {
    height: 75px;
    object-fit: contain;
}

.brand h1 {
    margin: 0;
    color: var(--primary);
    font-size: 28px;
}

.brand p {
    margin: 0;
    color: var(--secondary);
    font-weight: bold;
}

nav a {
    text-decoration: none;
    color: #15124a;
    font-weight: bold;
}

nav a:hover {
    color: var(--secondary);
}

.dashboard-container{
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 20px;
}

.container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 40px 20px;
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dashboard-cards{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
    gap:20px;
    margin-bottom:25px;
}
.dashboard-card{
    background:#fff;
    border-radius:12px;
    padding:25px;
    box-shadow:0 2px 10px rgba(0,0,0,.08);
    border-left:5px solid #0d6efd;
}

.dashboard-warning{
    border-left:5px solid #dc3545;
}

.dashboard-icon{
    font-size:32px;
    margin-bottom:10px;
}

.dashboard-card h3{
    font-size:13px;
    color:#6c757d;
    margin-bottom:15px;
}

.dashboard-value{
    font-size:42px;
    font-weight:bold;
    color:#0d6efd;
}

.dashboard-success{
    border-left:5px solid #198754;
}

.dashboard-success .dashboard-value{
    color:#198754;
}

.dashboard-card,
.reporte-card,
.panel,
.form-card {
    background: white;
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.04);
}

.card a {
    color: var(--primary);
    text-decoration: none;
}

.card h3 {
    margin-top: 0;
    color: var(--primary);
}

.card p {
    font-size: 32px;
    font-weight: bold;
    margin: 0;
    color: var(--secondary);
}

table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border: 1px solid var(--border);
}

table a {
    color: #0c85a6;
    text-decoration: none;
}

table a:hover {
    text-decoration: underline;
}

th,
td {
    padding: 10px;
    border-bottom: 1px solid var(--border);
    text-align: left;
}

th {
    background: var(--primary);
    color: white;
}

.btn {
    display: inline-block;
    padding: 8px 14px;
    border-radius: 6px;
    background: #e5e7eb;
    color: #111827;
    text-decoration: none;
    border: none;
    cursor: pointer;
}

.btn.primary {
    background: var(--secondary);
    color: white;
}

.btn.success {
    background: var(--success);
    color: white;
}

.alert {
    padding: 12px;
    border-radius: 6px;
    margin-bottom: 12px;
}

.alert.success {
    background: #dcfce7;
    color: #166534;
}

.alert.error {
    background: #fee2e2;
    color: var(--danger);
}

input,
select,
textarea {
    width: 100%;
    padding: 8px;
    border: 1px solid var(--border);
    border-radius: 6px;
}

fieldset {
    border: 1px solid var(--border);
    margin-bottom: 18px;
    border-radius: 8px;
}

.totals {
    background: white;
    border: 1px solid var(--border);
    padding: 16px;
    margin-top: 16px;
    max-width: 360px;
    margin-left: auto;
}

/* Factura imprimible */
.print-body {
    background: white;
}

.invoice {
    width: 900px;
    margin: 10px auto;
    background: white;
    padding: 30px;
    border: 1px solid var(--border);
    font-family: Arial, sans-serif;
}

/* 1. Encabezado mejor distribuido */
.invoice-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 3px solid var(--primary);
    padding-bottom: 15px;
    margin-bottom: 15px;
}

.invoice-brand {
    display: flex;
    align-items: center;
    gap: 16px;
}

.invoice-brand2 {
    margin: 0;
    line-height: 1.2;
}

.invoice-logo {
    width: 160px;
    height: auto;
    object-fit: contain;
}

.invoice-info {
    text-align: right;
    margin: 0;
    line-height: 1.2;
}

.invoice-info h2 {
    color: var(--primary);
    margin: 0 0 5px 0;
    font-size: 24px;
}

/* 2. Cuadro del detalle del cliente más reducido */
.client-box {
    margin: 10px 0;
    padding: 8px 12px;
    border: 1px solid var(--border);
    background: #fafafa;
    border-radius: 4px;
}

.client-box p, 
.invoice p {
    margin: 2px 0 !important;
    line-height: 1.4 !important;
    font-size: 13px;
}

/* Estilos de la tabla de servicios */
.invoice-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

.invoice-table th,
.invoice-table td {
    padding: 6px 10px !important;
    font-size: 13px;
}

/* 3. Tabla / Sección de Totales Mejorada */
.invoice-totals {
    margin-left: auto;
    width: 300px;
    margin-top: 20px;
    border-top: 2px solid var(--primary);
    padding-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

/* Si manejas los totales como filas o párrafos dentro de .invoice-totals */
.invoice-totals p {
    display: flex;
    justify-content: space-between;
    margin: 2px 0;
    font-size: 13px;
}

.grand-total {
    font-size: 18px !important;
    color: var(--primary);
    font-weight: bold;
    border-top: 1px dashed var(--border);
    padding-top: 6px;
    margin-top: 4px;
}

.invoice-footer {
    margin-top: 30px;
    text-align: center;
    color: #666;
    border-top: 1px solid var(--border);
    padding-top: 10px;
    font-size: 12px;
}

@media print {
    .topbar,
    .btn,
    nav,
    .messages {
        display: none !important;
    }

    body {
        background: white;
    }

    .invoice {
        width: 100%;
        margin: 0;
        border: none;
        box-shadow: none;
        padding: 10px;
    }
}

/* ===== LOGIN CENTRADO ===== */

.login-body {
    margin: 0;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #f1f5f9; /* gris claro elegante */
    font-family: Arial, sans-serif;
}

/* Caja central */
.login-box {
    background: white;
    padding: 40px 30px;
    width: 100%;
    max-width: 350px;
    border-radius: 10px;
    border: 1px solid #d8dee9;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
    text-align: left;
}

/* Título */
.login-box h2 {
    margin-bottom: 20px;
    color: #1e7397;
}

/* Inputs */
.login-box input {
    width: 100%;
    padding: 10px;
    margin-bottom: 15px;
    border-radius: 6px;
    border: 1px solid #d8dee9;
    font-size: 14px;
}

/* Focus */
.login-box input:focus {
    outline: none;
    border-color: #0c85a6;
    box-shadow: 0 0 4px rgba(12, 133, 166, 0.3);
}

/* Botón */
.login-box button {
    width: 100%;
    padding: 10px;
    border-radius: 6px;
    background: #15124a;
    color: white;
    border: none;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
}

/* Hover botón */
.login-box button:hover {
    background: #0c85a6;
}

/* Mensajes error */
.login-box .errorlist {
    color: #b91c1c;
    list-style: none;
    padding: 0;
    margin-bottom: 10px;
    font-size: 14px;
}

.login-error{
    background: #fdeaea;
    color: #b42318;
    border: 1px solid #f5c2c7;
    border-radius: 8px;
    padding: 12px;
    margin: 15px 0;
    text-align: center;
    font-weight: bold;
}

/* ===== REPORTES ===== */
.report-filter{
    display:grid;
    grid-template-columns:repeat(4,1fr);
    gap:15px;
    align-items:end;
}

.report-filter label{
    display:block;
    font-weight:bold;
    margin-bottom:6px;
    color:var(--primary);
}

.report-actions{
    grid-column:1 / -1;
    display:flex;
    gap:10px;
    flex-wrap:wrap;
    margin-top:10px;
}

/* CONTENEDOR DE TARJETAS */
.reporte-cards{
    display:grid;
    grid-template-columns:repeat(5,1fr);
    gap:18px;
    margin:20px 0;
}

/* TARJETA */
.reporte-card{
    background:white;
    border:1px solid var(--border);
    border-radius:10px;
    padding:20px;
    box-shadow:0 4px 14px rgba(0,0,0,.04);
    text-align:center;
}

.reporte-card h3{
    margin:0;
    color:var(--primary);
    font-size:14px;
    text-transform:uppercase;
}

.reporte-card p{
    margin:15px 0 0;
    font-size:28px;
    font-weight:bold;
    color:var(--secondary);
}

/* ===== MODELO PARA DESPLAZAMIENTO EN TABLAS ===== */
.table-responsive{
    width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: thin;
}

.reporte-table{
    width: max-content;
    min-width: 1200px;
    border-collapse: collapse;
}

/* Estilos base para fijar la primera columna */
.reporte-table th:first-child,
.reporte-table td:first-child {
    position: sticky;
    left: 0;
    min-width: 120px;
    background-color: #ffffff;
    background-clip: padding-box;
    z-index: 2;
    /* Sombra proyectada hacia la derecha */
    box-shadow: 4px 0 6px -2px rgba(0, 0, 0, 0.1); 
}

/* Encabezado fijo de la primera columna */
.reporte-table th:first-child {
    background-color: #16145e;
    color: #ffffff;
    z-index: 3; /* Asegura que quede por encima de los td de la misma columna */
}

/* PENDIENTES DGII */

.reporte-card.warning{
    border-left:5px solid #f59e0b;
}

.reporte-card.warning p{
    color:#b45309;
}

/* BOTONES */

.btn.success{
    background:#1f8f4d;
    color:white;
}

.btn.success:hover{
    background:#166534;
}

.btn.danger{
    background:#b91c1c;
    color:white;
}

.btn.danger:hover{
    background:#991b1b;
}

/* TABLA REPORTES */

.panel{
    overflow-x:auto;
}

.panel table{
    min-width:1100px;
}

/* RESPONSIVE */

@media (max-width:1100px){

    .reporte-cards{
        grid-template-columns:repeat(2,1fr);
    }

}

@media (max-width:900px){

    .report-filter{
        grid-template-columns:1fr 1fr;
    }

}

@media (max-width:600px){

    .report-filter{
        grid-template-columns:1fr;
    }

    .report-actions{
        flex-direction:column;
    }

    .reporte-cards{
        grid-template-columns:1fr;
    }

}

/* ===== MENU PRINCIPAL ===== */
.main-nav {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 12px 25px;
}

/* Links normales */
.main-nav a {
    text-decoration: none;
    color: #15124a;
    font-weight: 600;
    padding: 6px 10px;
    border-radius: 6px;
    transition: 0.2s;
}

/* Hover */
.main-nav a:hover {
    background: rgba(12, 133, 166, 0.1);
    color: #0c85a6;
}

/* Botón destacado */
.btn-nav {
    background: #0c85a6;
    color: white !important;
    padding: 8px 14px;
    border-radius: 6px;
    font-weight: bold;
}

.btn-nav:hover {
    background: #0a6f8c;
}

/* Logout a la derecha */
.nav-right {
    margin-left: auto;
}

/* Botón logout */
.logout {
    background: #b91c1c;
    color: white !important;
    padding: 6px 12px;
    border-radius: 6px;
}

.logout:hover {
    background: #991b1b;
}

.main-nav a.active {
    border-bottom: 3px solid #0c85a6;
}

/* ===== LOGOUT BUTTON ===== */
.logout-form{
    margin-left:auto;
}

.logout-btn {
    background: #b91c1c;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: bold;
}

.logout-btn:hover {
    background: #991b1b;
}

/* ===== FORMULARIO CLINICA ===== */
/* ===== FONDO GENERAL ===== */
body {
    background: #f5f7fb;
}

/* ===== CONTENEDOR ===== */
.form-container {
    max-width: 900px;
    margin: 40px auto;
    padding: 0 20px; /* Evita que el texto toque los bordes en móviles */
    box-sizing: border-box; /* Asegura que el padding no rompa el ancho total */
}

/* ===== TARJETA PRINCIPAL ===== */
.form-card {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

/* ===== TITULO ===== */
.page-header h2 {
    text-align: center;
    color: #15124a;
    font-weight: bold;
    margin-bottom: 20px;
}

legend {
    font-weight: bold;
    font-size: 16px;
    color: #0c85a6;
    margin-bottom: 10px;
}

/* ===== GRID ===== */
.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

/* ===== LABEL ===== */
.form-grid label {
    font-size: 13px;
    font-weight: bold;
    margin-bottom: 5px;
    display: block;
}

/* ===== INPUTS ===== */
.form-grid input,
.form-grid textarea,
.form-grid select {
    width: 100%;
    padding: 8px 10px;
    border-radius: 6px;
    border: 1px solid #d8dee9;
    font-size: 14px;
    transition: 0.2s;
}

/* ===== INPUT FOCUS ===== */
.form-grid input:focus,
.form-grid textarea:focus,
.form-grid select:focus {
    border-color: #0c85a6;
    outline: none;
    box-shadow: 0 0 6px rgba(12, 133, 166, 0.2);
}

/* ===== LOGO ===== */
.logo-preview img {
    display: block;
    margin: 10px auto;
}

/* ===== BOTONES ===== */
.form-actions {
    margin-top: 20px;
    display: flex;
    justify-content: center;
    gap: 10px;
}

/* botón guardar */
.btn-success {
    background: #1f8f4d;
    color: white;
    padding: 10px 18px;
    border-radius: 6px;
    border: none;
    font-weight: bold;
}

.btn-success:hover {
    background: #166534;
}

/* botón cancelar */
.btn-cancel {
    background: #ccc;
    padding: 10px 18px;
    border-radius: 6px;
}

.btn-cancel:hover {
    background: #bbb;
}

/* ===== CHECKBOX ALINEADO ===== */
.checkbox-inline {
    display: flex;
    align-items: center;   /* ✅ centra verticalmente */
    justify-content: space-between;  /* ✅ separa texto y checkbox */
    padding-top: 18px;  /* ✅ alinea con inputs */
}

.checkbox-inline .label-text {
    font-size: 13px;
    font-weight: bold;
    color: #333;
}

/* ===== Sub menu pantalla clinica_form.html ===== */
.sub-menu-admin{
    display:flex;
    gap:10px;
    margin-bottom:20px;
    border-bottom:1px solid #dcdcdc;
    padding-bottom:10px;
}

.sub-item{
    text-decoration:none;
    padding:10px 18px;
    border-radius:6px 6px 0 0;
    background:#f1f3f5;
    color:#333;
    font-weight:600;
}

.sub-item:hover{
    background:#0d6efd;
    color:white;
}

.sub-item.active{
    background:#0d6efd;
    color:white;
}

/* ==================================================
   HOME PUBLICA CLIDEZ
================================================== */
/* HEADER */

.public-header{
    display:flex;
    justify-content:space-between;
    align-items:center;
    padding:15px 30px;
    background:#ffffff;
    box-shadow:0 2px 10px rgba(0,0,0,.08);
}

.logo img{
    height:90px;
    width:auto;
}

.public-nav{
    display:flex;
    align-items:center;
    gap:30px;
}

.public-nav a{
    text-decoration:none;
    color:#0c4da2;
    font-weight:600;
    font-size:20px;
    transition:.2s;
}

.public-nav a:hover{
    color:#1fa4d8;
}

/* HERO */
.home-hero{
    min-height:220px;
    display:flex;
    justify-content:center;
    align-items:center;
    text-align:center;
    background:linear-gradient(
        135deg,
        #0c4da2,
        #1fa4d8
    );
    color:white;
    padding:40px 20px;
}

.hero-content{
    max-width:900px;
}

.hero-content h1{
    margin:0;
    font-size:42px;
    font-weight:700;
}

.hero-content p{
    margin-top:10px;
    font-size:20px;
}

/* GALERIA */
.home-galeria{
    padding:50px 20px;
    text-align:center;
}

.home-galeria h2{
    color:#0c4da2;
    margin-bottom:30px;
}

.home-cards{
    display:flex;
    justify-content:center;
    gap:25px;
    flex-wrap:wrap;
}

.home-card-placeholder{
    width:320px;
    height:220px;
    background:white;
    border-radius:12px;
    display:flex;
    justify-content:center;
    align-items:center;
    box-shadow:0 3px 15px rgba(0,0,0,.10);
    font-weight:600;
    color:#555;
    transition:.2s;
}

.home-card-placeholder:hover{
    transform:translateY(-5px);
}

/* CONTACTO */
.home-contacto{
    background:white;
    max-width:1200px;
    margin:40px auto;
    padding:30px;
    border-radius:15px;
    box-shadow:0 3px 15px rgba(0,0,0,.08);
}

.home-contacto h2{
    text-align:center;
    color:#0c4da2;
    margin-bottom:30px;
}

.home-contacto-grid{
    display:flex;
    justify-content:space-around;
    align-items:flex-start;
    gap:30px;
    flex-wrap:wrap;
}

.home-contacto-item{
    text-align:center;
    min-width:250px;
}

.home-contacto-item h4{
    color:#0c4da2;
    margin-bottom:10px;
}

.home-contacto-item p{
    color:#555;
    margin:0;
}

.home-card{
    width:340px;
    background:white;
    border-radius:12px;
    overflow:hidden;
    box-shadow:0 4px 15px rgba(0,0,0,.10);
    transition:.2s;
}

.home-card:hover{
    transform:translateY(-5px);
}

.home-card img{
    width:100%;
    height:220px;
    object-fit:cover;
}

.home-card video{
    width:100%;
    height:220px;
    object-fit:cover;
}

.home-card-body{
    padding:15px;
}

.home-card-body h3{
    margin:0 0 10px;
    color:#0c4da2;
}

.home-card-body p{
    margin:0;
    color:#555;
    line-height:1.5;
}

/* RESPONSIVE */
@media (max-width:768px){

    .public-header{
        flex-direction:column;
        gap:15px;
    }

    .home-hero{
        min-height:180px;
    }

    .hero-content h1{
        font-size:30px;
    }

    .hero-content p{
        font-size:16px;
    }

    .home-card-placeholder{
        width:100%;
        max-width:350px;
    }

}

/* ======================================
   RESPONSIVE HOME - TABLET
====================================== */
@media (max-width: 768px){

    .public-header{
        flex-direction:column;
        align-items:center;
        gap:15px;
        padding:15px;
    }

    .logo img{
        height:70px;
    }

    .public-nav{
        flex-wrap:wrap;
        justify-content:center;
        gap:15px;
    }

    .public-nav a{
        font-size:14px;
    }

    .home-hero{
        min-height:180px;
        padding:30px 15px;
    }

    .hero-content h1{
        font-size:32px;
        line-height:1.2;
    }

    .hero-content p{
        font-size:16px;
    }

    .home-galeria{
        padding:30px 15px;
    }

    .home-galeria h2{
        font-size:24px;
    }

    .home-cards{
        flex-direction:column;
        align-items:center;
    }

    .home-card-placeholder{
        width:100%;
        max-width:400px;
        height:180px;
    }

    .home-contacto{
        margin:20px 15px;
        padding:20px;
    }

    .home-contacto-grid{
        flex-direction:column;
        gap:20px;
    }

    .home-contacto-item{
        min-width:unset;
        width:100%;
    }

}

/* ======================================
   RESPONSIVE HOME - MOVIL
====================================== */
@media (max-width: 480px){

    .public-header{
        padding:10px;
    }

    .logo img{
        height:60px;
    }

    .public-nav{
        flex-direction:column;
        gap:10px;
    }

    .public-nav a{
        font-size:13px;
    }

    .home-hero{
        min-height:150px;
        padding:25px 10px;
    }

    .hero-content h1{
        font-size:26px;
    }

    .hero-content p{
        font-size:14px;
    }

    .home-galeria h2{
        font-size:20px;
    }

    .home-card-placeholder{
        height:150px;
        font-size:14px;
    }

    .home-contacto h2{
        font-size:22px;
    }

    .home-contacto-item h4{
        font-size:16px;
    }

    .home-contacto-item p{
        font-size:14px;
    }

}

.action-buttons .btn{
    padding:6px 10px;
    font-size:13px;
}

.action-buttons{
    display:flex;
    justify-content:flex-end;
    gap:8px;
    white-space:nowrap;
}

table th:last-child,
table td:last-child{
    width:180px;
    text-align:center;
}

.form-actions .btn{
    min-width:120px;
    text-align:center;
}

.home-social{
    margin-top:25px;
    display:flex;
    justify-content:center;
    gap:12px;
    flex-wrap:wrap;
}

.home-social a{
    background:#0c4da2;
    color:white;
    text-decoration:none;
    padding:10px 15px;
    border-radius:8px;
    font-weight:600;
}

.home-social a:hover{
    background:#1fa4d8;
}

.home-social a{
    background:#0c4da2;
    color:white;
    padding:10px 15px;
    border-radius:8px;
    text-decoration:none;
    font-weight:600;
}

.home-social a:hover{

    background:#1fa4d8;
}

.about-header{
    background: linear-gradient(135deg, #0d47a1, #1976d2);
    color: white;
    text-align: center;
    padding: 80px 20px;
    margin-bottom: 50px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.about-header h1{
    color: white;
    font-size: 48px;
    margin-bottom: 15px;
}

.about-header p{
    color: rgba(255,255,255,0.9);
    font-size: 20px;
    margin: 0;
}

.historia-section{
    padding:60px 20px;
}

.historia-card{
    max-width:950px;
    margin:0 auto 60px auto;
    background:#fff;
    padding:40px;
    border-radius:20px;
    box-shadow:0 8px 20px rgba(0,0,0,0.08);
}

.historia-card h2{
    text-align:center;
    color:#1a4b84;
    margin-bottom:25px;
}

.historia-card p{
    text-align:justify;
    line-height:1.9;
}

.mvv-section{
    display:flex;
    gap:25px;
    flex-wrap:wrap;
    justify-content:center;
    margin:60px auto;
    max-width:1200px;
}

.mvv-card{
    flex:1;
    min-width:280px;
    background:#fff;
    border-radius:20px;
    padding:30px;
    text-align:center;
    box-shadow:0 8px 20px rgba(0,0,0,0.08);
    transition:.3s;
}

.mvv-card:hover{
    transform:translateY(-5px);
}

.mvv-card .icono{
    font-size:50px;
    margin-bottom:15px;
}

.mvv-card h3{
    color:#1a4b84;
    margin-bottom:15px;
}

.frase-final{
    text-align:center;
    padding:70px 20px;
    background:#1a4b84;
    color:white;
    margin-top:50px;
}

@media(max-width:768px){

    .mvv-section{
        flex-direction:column;
    }

    .mvv-card{
        width:100%;
    }

}

/* ===== FORMULARIO PAGINA WEB ===== */
/* ===== SERVICIOS WEB ===== */
.form-section{
    border:1px solid #dbe3ef;
    border-radius:12px;
    padding:25px;
    background:#fff;
}

.section-title{
    color:#0c7ea5;
    font-weight:700;
}

.table thead{
    background:#16145a;
    color:#fff;
}

.table thead th{
    color:#fff;
    border:none;
}

.img-servicio{
    width:80px;
    height:80px;
    object-fit:cover;
    border-radius:8px;
    border:1px solid #ddd;
}

.action-buttons .btn{
    font-size:13px;
    padding:6px 12px;
}

.table tbody tr:hover{
    background:#f8f9fb;
}

.servicio-imagen{
    width:100%;
    height:250px;
    object-fit:cover;
}

.servicios-page .container{
    max-width:1200px;
    margin:0 auto;
}

/******************************************/
/****** PANTALLA SERVICIOS OFRECIDOS ******/
/******************************************/
/* Variables de Diseño */
:root {
    --primary-color: #0f4c81; /* Azul corporativo */
    --secondary-color: #2a9d8f; /* Verde azulado médico */
    --text-dark: #2b2d42;
    --text-light: #6c757d;
    --bg-light: #f8f9fa;
    --white: #ffffff;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.05), 0 1px 3px rgba(0, 0, 0, 0.1);
    --radius: 12px;
}

/* Estilos Generales */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: var(--text-dark);
    background-color: var(--bg-light);
    margin: 0;
    padding: 0;
    line-height: 1.6;
}

/* Navbar */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: var(--white);
    padding: 15px 40px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.nav-links .nav-item {
    text-decoration: none;
    color: var(--text-dark);
    margin-left: 20px;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links .nav-item:hover {
    color: var(--primary-color);
}

/* Introducción */
.intro-section {
    text-align: center;
    margin-bottom: 60px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.intro-section h1 {
    color: var(--primary-color);
    font-size: 2.5rem;
    margin-bottom: 15px;
}

.intro-section .subtitle {
    font-size: 1.15rem;
    color: var(--text-light);
}

/* Grilla de Servicios (Tarjetas) */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
}

.service-card {
    background-color: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s, box-shadow 0.3s;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.card-image {
    width: 100%;
    height: 250px;
    background-color: #e9ecef; /* Fondo gris claro neutral */
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.card-image img {
    width: 100%;
    height: 250px;
    object-fit: cover;
}

.card-content {
    padding: 30px;
}

.card-content h2 {
    color: var(--primary-color);
    margin-top: 0;
    font-size: 1.6rem;
}

.card-description {
    color: var(--text-light);
    font-size: 1rem;
    margin-bottom: 20px;
}

.benefits-list {
    padding-left: 20px;
    margin: 0;
}

.benefits-list li {
    margin-bottom: 10px;
    color: var(--text-dark);
}

/* Sección de Cierre (CTA) */
.cta-section {
    background: linear-gradient(135deg, var(--primary-color), #1d72b8);
    color: var(--white);
    padding: 50px 40px;
    border-radius: var(--radius);
    text-align: center;
    box-shadow: var(--shadow);
}

.cta-section h2 {
    margin-top: 0;
    font-size: 2rem;
}

.cta-section p {
    font-size: 1.1rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

.btn-primary {
    display: inline-block;
    background-color: var(--secondary-color);
    color: var(--white);
    text-decoration: none;
    padding: 12px 30px;
    border-radius: 25px;
    font-weight: bold;
    transition: background-color 0.3s, transform 0.2s;
}

.btn-primary:hover {
    background-color: #218376;
    transform: scale(1.05);
}

/* Responsividad para móviles */
@media (max-width: 768px) {
    .services-grid {
        grid-template-columns: 1fr;
    }
    .navbar {
        flex-direction: column;
        gap: 15px;
    }
}


/*** PIE DE PAGINA PRINCIPAL ***/
/* Contenedor de botones con más separación */
.social-buttons-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;       /* Aumentado para que no estén pegados horizontalmente */
    margin-top: 40px; /* Separa los botones del bloque superior de dirección/teléfono */
    flex-wrap: wrap; 
}

/* Estilo Base Compartido */
.btn-social {
    display: inline-flex;
    align-items: center;
    gap: 10px;       /* Más espacio interno entre el icono SVG y el texto */
    padding: 12px 24px; /* Un botón ligeramente más espacioso y elegante */
    border-radius: 25px;
    font-size: 0.95rem;
    font-weight: 600;
    text-decoration: none;
    color: #ffffff !important;
    transition: background-color 0.3s, transform 0.2s, box-shadow 0.3s;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    border: none;
    cursor: pointer;
}

.btn-social:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.12);
}

/* Colores de redes sociales */
.btn-facebook { background-color: #1877F2; }
.btn-facebook:hover { background-color: #145dbf; }

.btn-instagram { background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%); }
.btn-instagram:hover { background: linear-gradient(45deg, #e08423 0%, #d6582c 25%, #cc1733 50%, #bc1356 75%, #ac0878 100%); }

.btn-tiktok { background-color: #010101; }
.btn-tiktok:hover { background-color: #252525; }

.btn-youtube { background-color: #FF0000; }
.btn-youtube:hover { background-color: #cc0000; }

.btn-whatsapp { background-color: #25D366; }
.btn-whatsapp:hover { background-color: #1ebd57; }

.btn-maps { background-color: #1a73e8; }
.btn-maps:hover { background-color: #155cb4; }

.btn-inicio {background-color: #0f4c81 !important; }
.btn-inicio:hover {background-color: #0c3d69 !important; }

.btn-social svg {
    display: inline-block;
    vertical-align: middle;
    flex-shrink: 0;
}

/* *** SUB MENU REPORTE DGII *** */

/* Contenedor principal que se alinea con los otros botones de la barra */
.nav-item-dropdown {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    padding: 0 10px;
}

/* El disparador imita el diseño de tus otros botones (icono arriba, texto abajo) */
.nav-dropdown-trigger {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.nav-dropdown-trigger .nav-icon {
    font-size: 20px;
    margin-bottom: 4px;
}

.nav-dropdown-trigger .nav-text {
    font-size: 15px;
    color: #333;
}

/* Menú oculto que se posiciona de forma flotante exactamente debajo */
.nav-dropdown-menu {
    display: block !important; /* Cambiamos display a block para poder animarlo */
    opacity: 0;
    visibility: hidden;
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background-color: #ffffff;
    min-width: 150px;
    box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.15);
    border: 1px solid #ddd;
    border-radius: 6px;
    z-index: 9999;
    margin-top: 5px;
    
    /* CONTROL DE TIEMPO (Aquí ocurre la magia) */
    /* opacity e visibility tardan 0.2s en cambiar, pero esperan 0.3s antes de empezar a desaparecer */
    transition: opacity 0.2s ease, visibility 0.2s ease;
    transition-delay: 0.3s; 
}

/* Estilos para los enlaces dentro del menú */
.nav-dropdown-menu a {
    display: block;
    padding: 10px 15px;
    color: #333;
    text-decoration: none;
    font-size: 15px;
    text-align: left;
    white-space: nowrap;
    transition: background-color 0.2s;
}

.nav-dropdown-menu a:first-child {
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
}

.nav-dropdown-menu a:last-child {
    border-bottom-left-radius: 8px;
    border-bottom-right-radius: 8px;
}

/* Cambia de color al pasar el cursor sobre las opciones */
.nav-dropdown-menu a:hover {
    background-color: #f8fafc;
    color: #007bff;
}

/* Muestra el menú flotante únicamente al pasar el mouse por encima del botón */
.nav-item-dropdown:hover .nav-dropdown-menu {
    opacity: 1 !important;
    visibility: visible !important;
    transition-delay: 0s; /* Se muestra de inmediato al pasar el mouse */
}

/* *** REPORTE 607 *** */
.reporte607-cards{
    display:flex;
    gap:15px;
    margin-bottom:25px;
    flex-wrap:wrap;
}

.stat-card{
    flex:1;
    min-width:180px;
    background:#fff;
    border:1px solid #d8dfe6;
    border-radius:10px;
    padding:20px;
    text-align:center;
    box-shadow:0 2px 5px rgba(0,0,0,.08);
}

.stat-card h4{
    font-size:14px;
    color:#1d2258;
    margin-bottom:20px;
}

.stat-number,
.stat-money{
    font-size:30px;
    font-weight:bold;
    color:#0b7fab;
}

.stat-pending{
    font-size:38px;
    font-weight:bold;
    color:#d46c00;
}

.stat-card.pending{
    border-left:5px solid #d46c00;
}

/* Vista dashboard_dgii() */
.dgii-dashboard{
    width:100%;
}

.dgii-title{
    color:#1f3b64;
    margin-bottom:5px;
}

.dgii-subtitle{
    color:#6b7280;
    margin-bottom:25px;
}

.dgii-dashboard-cards{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(240px,1fr));
    gap:20px;
    margin-bottom:30px;
}

.dgii-stat-card{
    background:#ffffff;
    border-radius:12px;
    padding:20px;
    box-shadow:0 2px 10px rgba(0,0,0,.08);
    border-left:5px solid #0d6efd;
}

.dgii-card-warning{
    border-left:5px solid #dc3545;
}

.dgii-card-icon{
    font-size:32px;
    margin-bottom:10px;
}

.dgii-card-title{
    font-size:13px;
    font-weight:600;
    color:#6c757d;
    margin-bottom:15px;
}

.dgii-card-value{
    font-size:38px;
    font-weight:bold;
    color:#0d6efd;
}

.dgii-card-money{
    font-size:28px;
    font-weight:bold;
    color:#198754;
}

.dgii-panel{
    background:#fff;
    border-radius:12px;
    overflow:hidden;
    box-shadow:0 2px 10px rgba(0,0,0,.08);
}

.dgii-panel-header{
    background:#1f3b64;
    color:#fff;
    padding:15px;
    font-weight:bold;
}

.dgii-panel-body{
    padding:20px;
}

.dgii-report-row{
    display:flex;
    justify-content:space-between;
    align-items:center;
    padding:15px 0;
    border-bottom:1px solid #eee;
}

.dgii-report-row:last-child{
    border-bottom:none;
}


/* *** MENSAJES DE 607_DGII Y 608_DGII *** */
.messages{
    margin-bottom:20px;
}

.alert{
    padding:14px 18px;
    border-radius:10px;
    margin-bottom:10px;
    font-weight:600;
    box-shadow:0 2px 6px rgba(0,0,0,.08);
}

/* Success */
.alert.success{
    background:#eafaf1;
    color:#146c43;
    border-left:5px solid #198754;
}

/* Warning */
.alert.warning{
    background:#fff8e1;
    color:#856404;
    border-left:5px solid #ffc107;
}

/* Error */
.alert.error{
    background:#fdecea;
    color:#842029;
    border-left:5px solid #dc3545;
}

/* Info */
.alert.info{
    background:#e8f4fd;
    color:#055160;
    border-left:5px solid #0dcaf0;
}


/* *** CONFIRMAR EMITIR FACTURA *** */
.confirmacion-card{
    max-width:700px;
    margin:30px auto;
    background:#fff;
    padding:25px;
    border-radius:10px;
    box-shadow:0 4px 15px rgba(0,0,0,.10);
}

.alert-warning{
    background:#fff3cd;
    border-left:5px solid #ffc107;
    padding:15px;
    margin:20px 0;
    border-radius:5px;
}

.acciones-confirmacion{
    display:flex;
    gap:10px;
    justify-content:flex-end;
    margin-top:25px;
}

/* =========================
   ESTILO PARA SERVICIOS WEB
========================= */
/* HERO */
.hero-servicios {
    background: linear-gradient(135deg, #0d6efd, #0b5ed7);
    color: white;
    text-align: center;
    padding: 80px 20px;
}

.hero-servicios h1 {
    font-size: 48px;
    margin-bottom: 15px;
}

.hero-servicios p {
    max-width: 800px;
    margin: auto;
    font-size: 18px;
}

/* SERVICIOS */
.servicios-page {
    padding: 60px 20px;
}

.section-title {
    text-align: center;
    margin-bottom: 50px;
}

.section-title h2 {
    color: #0d6efd;
    margin-bottom: 10px;
}

.section-title p {
    color: #666;
    max-width: 700px;
    margin: 0 auto;
}

.servicios-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.servicio-card {
    background: #ffffff;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.servicio-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.servicio-placeholder {
    background: #f3f7ff;
    height: 230px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 80px;
}

.servicio-body {
    padding: 25px;
}

.servicio-body h3 {
    color: #0d6efd;
    margin-bottom: 15px;
    font-size: 24px;
}

.servicio-body p {
    color: #555555;
    line-height: 1.6;
    margin-bottom: 20px;
}

.btn-servicio {
    display: inline-block;
    margin-top: 15px;
    padding: 10px 20px;
    background: #0d6efd;
    color: #ffffff;
    text-decoration: none;
    border-radius: 8px;
    transition: background 0.3s ease;
}

.btn-servicio:hover {
    background: #0b5ed7;
    color: #ffffff;
}

/* CTA */
.cta-servicios {
    background: #0d6efd;
    color: #ffffff;
    text-align: center;
    padding: 80px 20px;
    margin-top: 60px;
}

.cta-servicios h2 {
    margin-bottom: 15px;
}

.cta-servicios p {
    margin-bottom: 25px;
}

.btn-cita {
    display: inline-block;
    margin-top: 20px;
    background: #ffffff;
    color: #0d6efd;
    padding: 12px 25px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
}

.btn-cita:hover {
    background: #f2f2f2;
}

/* MENSAJE SIN SERVICIOS */
.sin-registros {
    grid-column: 1 / -1; /* Ocupa todo el ancho de la grilla */
    text-align: center;
    padding: 40px;
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    color: var(--text-light);
}

.sin-registros h3 {
    color: #6c757d;
}

/* RESPONSIVE */
@media (max-width: 768px) {

    .hero-servicios h1 {
        font-size: 36px;
    }

    .hero-servicios p {
        font-size: 16px;
    }

    .servicios-grid {
        grid-template-columns: 1fr;
    }

}

/* ========================================
   REPORTE DE COMPRAS CLIDEZ
======================================== */
.page-title {
    color: #0582b1;
    font-weight: 700;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.page-title i {
    color: #0091c9;
}

/* =========================================
   PANEL DE FILTROS
========================================= */
.panel-filtros {
    background: #ffffff;
    border: 1px solid #d9e1ec;
    border-radius: 10px;
    padding: 18px;
    margin-bottom: 25px;
    box-shadow: 0 2px 5px rgba(0,0,0,.06);
}

.panel-filtros .form-label {
    font-size: 14px;
    font-weight: 600;
    color: #0a1f44;
    margin-bottom: 6px;
}

.panel-filtros .form-control,
.panel-filtros .form-select {
    height: 42px;
    border: 1px solid #ced4da;
    border-radius: 6px;
    font-size: 14px;
}

.panel-filtros .form-control:focus,
.panel-filtros .form-select:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 .15rem rgba(13,110,253,.15);
}

/* =========================================
   FILA DE FILTROS
========================================= */
.filtros-row {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: end;
}

.filtro-item {
    flex: 1;
    min-width: 180px;
}

/* =========================================
   BOTONES
========================================= */
.filtro-botones {
    margin-top: 18px;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.btn-filtrar {
    background: #0ea5c6;
    border: none;
    color: white;
}

.btn-filtrar:hover {
    background: #0b8ca8;
    color: white;
}

.btn-excel {
    background: #198754;
    border: none;
    color: white;
}

.btn-excel:hover {
    background: #157347;
    color: white;
}

.btn-pdf {
    background: #dc3545;
    border: none;
    color: white;
}

.btn-pdf:hover {
    background: #bb2d3b;
    color: white;
}

.btn-limpiar {
    background: #6c757d;
    border: none;
    color: white;
}

.btn-limpiar:hover {
    background: #5c636a;
    color: white;
}

/* =========================================
   RESPONSIVE
========================================= */
@media (max-width: 768px) {

    .filtros-row {
        flex-direction: column;
    }

    .filtro-item {
        width: 100%;
    }

}/* ========================================
   KPIs REPORTE 606
======================================== */
.kpi-container{
    display:flex;
    flex-wrap:wrap;
    gap:15px;
    margin:25px 0;
}

.kpi-card{
    flex:1;
    min-width:180px;
    background:#fff;
    border:1px solid #d8dfe6;
    border-radius:10px;
    padding:20px;
    text-align:center;
    box-shadow:0 2px 5px rgba(0,0,0,.08);
    transition:.3s;
}

.kpi-card:hover{
    transform:translateY(-2px);
}

.kpi-card i{
    font-size:28px;
    margin-bottom:12px;
}

.kpi-card span{
    display:block;
    font-size:12px;
    font-weight:700;
    color:#050044;
    margin-bottom:10px;
}

.kpi-card h2,
.kpi-card h3{
    margin:0;
    font-size:30px;
    color:#0b7fab;
    font-weight:bold;
}

/* ========================================
   TABLA
======================================== */
.card-detalle {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,.05);
    overflow: hidden;
}

.card-detalle .card-header {
    background: white;
    border-bottom: 1px solid #e5ecf4;
    font-weight: 700;
    color: #0b1f44;
}

.table-reporte {
    margin-bottom: 0;
}

.table-reporte thead {
    background: #07004d;
    color: white;
}

.table-reporte thead th {
    border: none;
    padding: 14px;
    font-size: 13px;
    font-weight: 600;
}

.table-reporte tbody td {
    padding: 12px;
    vertical-align: middle;
    border-bottom: 1px solid #eef2f6;
}

.table-reporte tbody tr:hover {
    background: #f8fbff;
}

/* ========================================
   BADGES DGII
======================================== */
.badge-pendiente {
    background: #fff3cd;
    color: #856404;
    border-radius: 20px;
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 600;
}

.badge-enviada {
    background: #d1e7dd;
    color: #0f5132;
    border-radius: 20px;
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 600;
}

/* ========================================
   RESUMEN FISCAL
======================================== */
.resumen-fiscal {
    background: #f8fbff;
    border-left: 5px solid #0091c9;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
}

.resumen-fiscal h5 {
    color: #050044;
    font-weight: 700;
    margin-bottom: 15px;
}

.resumen-fiscal .valor {
    float: right;
    font-weight: 700;
}

/* ========================================
   RESPONSIVE
======================================== */
@media (max-width: 768px) {

    .kpi-container {
        grid-template-columns: 1fr;
    }

    .panel-filtros .row > div {
        margin-bottom: 12px;
    }

    .table-responsive {
        overflow-x: auto;
    }

}

/* ========================================
   COLORES ENCABEZADO PANELES REPORTE 606 
======================================== */
.kpi-total{
    border-top:4px solid #0d6efd;
}

.kpi-subtotal{
    border-top:4px solid #17a2b8;
}

.kpi-itbis{
    border-top:4px solid #6f42c1;
}

.kpi-total-compra{
    border-top:4px solid #198754;
}

.kpi-pendiente{
    border-top:4px solid #fd7e14;
}

.kpi-reportado{
    border-top:4px solid #20c997;
}
