/* --------------------
    VARIABLES Y RESET 
    -------------------- */
:root {
    --primary-color: #071D49;   /* Azul FGJ */
    --accent-color: #A69E8B;    /* Dorado/Ocre/Caqui (Botones) */
    --text-color-dark: #333;    /* Texto oscuro */
    --text-color-light: #fff;   /* Texto claro */
    
    /* COLORES DE FONDO DE SECCIÓN */
    --background-white: #ffffff;        
    --background-khaki: #b5a485;        
    --background-gray: #676767;        
    
    --font-family-fgj: 'Montserrat', Helvetica, Arial, sans-serif;

    --space-0: 0;
    --space-1: 0.5rem;   /* 8px */
    --space-2: 1rem;     /* 16px */
    --space-3: 1.5rem;   /* 24px */
    --space-4: 2rem;     /* 32px */
    --space-5: 3rem;     /* 48px */
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0; 
}

 
body {
    font-family: var(--font-family-fgj);
    line-height: 1.6;
    color: var(--text-color-dark); 
}
 
/* --------------------
    1. HERO SECTION (Sección Principal)
    -------------------- */
.hero-section {
    position: relative;
    min-height: 90vh;
    padding: 20px;
    padding-bottom: 50px; 
    overflow: hidden; 
}

/* ================================================= */
/* === ESTILOS BASE PARA EL FONDO DEL HERO SECTION === */
/* ================================================= */
.collage-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%; 
    z-index: -1;
    background-image: url('../images/portadamemorias.jpg'); 
    background-size: cover; 
    background-repeat: no-repeat;
    background-position: center center;
}
  

/* ===========================
   HEADER GENERAL
=========================== */

.main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 5px 30px;
    width: 100%;
    margin-left: 50px;
    margin-right: 150px;
}

.logo-fgj {
    height: 120px;
    width: auto;
}

.logo-izquierdo-fgj {
    height: 200px;
    width: auto;
}

/* ===========================
   HERO CONTENT (3 columnas)
=========================== */

.hero-content {
    display: flex;
    width: 100%;
    align-items: center;      /* centra verticalmente */
    min-height: 300px;        /* evita brincos al iniciar */
}

.hero-item {
    flex: 1;                  /* cada sección toma el mismo espacio */
    display: flex;
    align-items: center;      /* centra verticalmente */
}

/* LEFT */
.hero-item.left {
    justify-content: flex-end;
}

/* CENTER */
.hero-item.center-btn {
    justify-content: center;
}

.hero-item.right {
    justify-content: flex-start;
    align-items: flex-end;     /* ahora se coloca abajo */
}

/* ===========================
   IMÁGENES + ANIMACIONES
=========================== */

/* IZQUIERDA */
.left-img {
    height: 480px;
    width: auto;
    opacity: 0;
    transform: translateX(-60px);     /* estado inicial */
    animation: slideLeft 1.2s ease-out forwards;
}

/* DERECHA */
.right-img {
    height: 350px;
    width: auto;
    opacity: 0;
    transform: translateX(60px);      /* estado inicial */
    animation: slideRight 1.2s ease-out 0.3s forwards;
}



/* LOGO IZQUIERDO: Animación de deslizar desde la izquierda */
.logo-izquierdo-fgj {
    height: 200px;
    width: auto;
    opacity: 0; /* Estado inicial */

    /* Nueva animación (Asegúrate de que no se ejecute inmediatamente, la controlaremos con JS) */
    transition: opacity 1s ease-out, transform 1s ease-out; 
}

/* LOGO CENTRAL (FGJ): Animación de aparecer/zoom */
.logo-fgj {
    height: 120px;
    width: auto;
    opacity: 0; /* Estado inicial */
    transform: scale(0.9); /* Estado inicial */
    /* Nueva animación (Asegúrate de que no se ejecute inmediatamente, la controlaremos con JS) */
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

/* ------------------------------------------------ */
/* CLASES PARA ACTIVAR ANIMACIONES CON JS (después del loader) */
/* ------------------------------------------------ */

/* Logo Izquierdo (Deslizar a la izquierda) */
.logo-izquierdo-fgj.start-anim {
    opacity: 1;
    transform: translateX(0);
    transition-delay: 0.1s; /* Pequeño delay */
}

/* Logo Central (Zoom/Aparecer) */
.logo-fgj.start-anim {
    opacity: 1;
    transform: scale(1);
    transition-delay: 0.2s; /* Pequeño delay */
}


/* BOTÓN CENTRO */
.center-btn button {
    opacity: 0;
    transform: scale(0.8);
    animation: zoomIn 1s ease-out 0.4s forwards;
}

/* ===========================
   KEYFRAMES
=========================== */

@keyframes slideLeft {
    0% {
        transform: translateX(-60px);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideRight {
    0% {
        transform: translateX(60px);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes zoomIn {
    0% {
        opacity: 0;
        transform: scale(0.8);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

.report-cta {
    padding: 12px 28px;
    font-size: 22px;
    border: none;
    border-radius: 8px;
    background: #003366;
    color: #fff;
    cursor: pointer;
    font-weight: bold;
}

.report-cta:hover {
    background: #0055a1;
}


/* (No hay main-person-image en el CSS proporcionado, pero lo mantengo si estaba en el HTML) */
.main-person-image {
    width: 250px;
    height: auto;
    object-fit: cover;
    margin-right: 50px;
    box-shadow: 5px 5px 15px rgba(0, 0, 0, 0.2);
}

.main-title-area {
    flex-grow: 1;
    text-align: center;
    padding-top: 50px; 
}

.report-cta {
    background-color: var(--primary-color);
    color: var(--text-color-light);
    border: none;
    padding: 20px 30px;
    cursor: pointer;
    font-weight: bold;
    margin-bottom: 20px;
    transition: background-color 0.3s;
    border-radius: 15px;
    border: #fff solid 2px;
}

.report-cta:hover {
    background-color: var(--background-white);
    color: var(--primary-color);
}

/* --------------------
    2. MINIS DE INFORMES (STICKY MENU)
    -------------------- */
.report-minis-container {
    /* Mantenemos el margen negativo para que se superponga al Hero Section */
    margin-top: -120px;
    
    /* Propiedades de Sticky */ 
    top: 0;
    z-index: 1000;
   
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2); 
    
    width: 100%;
    display: flex;
    justify-content: center; 
    gap: 25px;
    padding: 15px; 
}

.report-mini {
    text-align: center;
    cursor: pointer; 
    transition: opacity 0.3s, transform 0.3s, box-shadow 0.3s; 
     background-color: #fff; 
     padding: 10px;
}

.report-mini:hover {
    opacity: 1;
    transform: scale(1.1);  
}

.report-mini.active {
    opacity: 1;
    transform: translateY(-10px); 
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); 
}

.report-mini img {
    width: 200PX;
    height: auto; 
}


/* --------------------
    3. SECCIONES DETALLADAS
    -------------------- */

    .report-informe-section {
    display: flex;
    align-items: center; 
    margin: auto;
    gap: 50px;
}

.report-detail-section {
    display: flex;
    align-items: center; 
    min-height: 85vh; /* ⬅️ MODIFICADO: Aumenta la altura mínima para evitar compresión */
    padding: 80px 15%; 
    margin: auto;
    gap: 50px; 
}

.primary-report {
    
    background-color: var(--background-white); 
}

.report-image-side {
    position: relative;
    flex-shrink: 0; 
    overflow: hidden; /* Importante para la animación de recorte */
    min-height: 500px; /* ⬅️ AÑADIDO: Altura mínima para la imagen */
    flex-basis: 380px; /* ⬅️ AÑADIDO: Ancho base fijo para la imagen */
}

/* Tamaño de la PORTADA GRANDE */
.report-cover {
    width: 350px; 
    height: 450px; 
    object-fit: cover; 
    transition: transform 0.3s; 
}

/* Rotación del año de informe */
.report-year {
    position: absolute; 
    top: 0px;      
    right: 10px;      
    z-index: 5;      
    font-size: 2em;
    font-weight: bold;
    color: white; 
    padding: 5px 10px;
    background-color: rgba(0, 0, 0, 0.5);
}

.report-text-side {
    flex-grow: 1;
}

 
/* --- Estilos para el Botón Scroll-to-Top (Home) --- */

.scroll-to-top-btn {
    
    position: fixed;
    bottom: 30px; 
    right: 30px; 
    z-index: 1000;
    background-color: var(--background-gray); 
    border: none;
    border-radius: 50%;
    cursor: pointer;
    width: 60px; 
    height: 60px;
    display: flex; 
    align-items: center;
    justify-content: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.4); 
    transition: all 0.3s ease;
    opacity: 0;
}

 

.scroll-to-top-btn:hover {
    background-color: #4b4b4b; 
    transform: scale(1.1) translateY(-2px); 
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.5); 
}

/* Estilos del SVG (Icono Home) */
.scroll-to-top-btn svg {
    width: 28px; 
    height: 28px;
    stroke: white; 
    fill: none; 
}

/* Clase para mostrarlo con JavaScript */
.scroll-to-top-btn.show {
    display: flex;
    opacity: 1;
    animation: pulse 2s infinite ease-in-out; 
}



/* ------------------------------------------------------------------ */
/* 🌟🌟🌟 ESTILOS DE BOTÓN MODERNO (Gris/Blanco) 🌟🌟🌟 */
/* ------------------------------------------------------------------ */

.report-cta-detail {
    padding: 15px 40px;
    font-size: 1.1em; 
    font-weight: 700; 
    cursor: pointer;
    border-radius: 10px; 
    transition: background-color 0.3s, color 0.3s, box-shadow 0.3s, transform 0.3s;
}

/* 2. ESTILOS PARA LA SECCIÓN PRIMARIA (Fondo Blanco) */

.primary-report .report-cta-detail {
    background-color: var(--background-gray); 
    border: 2px solid var(--text-color-dark); 
    color: var(--text-color-light);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15); 
    margin: 15px 0px;
}

.primary-report .report-cta-detail:hover {
    background-color: var(--text-color-dark); 
    color: var(--text-color-light); 
    border-color: var(--text-color-dark);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4); 
    transform: translateY(-3px); 
}


/* 3. ESTILOS PARA LA SECCIÓN SECUNDARIA (Fondo Caqui) */
.secondary-report {
    
    flex-direction: row-reverse; 
    background-color: var(--background-khaki); 
}

/* Estilos para texto en la sección secundaria (blanco) */
.secondary-report .report-counter, 
.secondary-report h2,.secondary-report h1,
.secondary-report p {
    color: var(--text-color-light); 
}

.report-counter{
    font-size: x-large;
}

.secondary-report .report-cta-detail {
    background: none;
    border: 2px solid var(--text-color-light); 
    color: var(--text-color-light);        
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3); 
    margin: 15px 0px; 
}

.secondary-report .report-cta-detail:hover {
    background-color: var(--text-color-light); 
    color: var(--background-khaki); 
    box-shadow: 0 8px 20px rgba(255, 255, 255, 0.6); 
    transform: translateY(-3px);
}

/* --------------------
    4. PIE DE PÁGINA
    -------------------- */
footer {
    background-color: var(--background-gray);
    border-top: 1px solid #ddd;
    text-align: center;
    padding: 15px 0;
    font-size: 0.8em;
    color: var(--text-color-light); 
}


/* --------------------
    5. RESPONSIVE DESIGN (Móviles)
    -------------------- */
@media (max-width: 900px) {
    .report-minis-container {
        justify-content: flex-start;
        padding-left: 20px;
        overflow-x: auto; 
    }
    
    .report-detail-section {
        flex-direction: column;
        text-align: center;
    }

    .secondary-report {
        flex-direction: column; 
    }
    
    .report-cover {
        width: 80%;
        height: auto;
    }
    .report-year {
        top: -10px;
        right: 10px;
        transform: none; 
    }

    /* Ajuste adicional para móviles: restablecer las nuevas propiedades de imagen */
    .report-image-side {
        min-height: auto; /* La altura se adaptará al contenido (la imagen) */
        flex-basis: auto; /* El ancho se ajustará automáticamente */
        margin-bottom: 20px; /* Separación después de la imagen */
    }
}

 /* ============================
      LOADER DE INICIO
    ============================ */
     .page-loader {
      position: fixed;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      background: var(--accent-color);
      display: flex;
      flex-direction: column;
      justify-content: center;
      align-items: center;
      z-index: 9999;
      transition: opacity 1s ease, visibility 1s ease;
     }

  
     .loader-text {
      color: var(--text-light);
      font-size: 24px;
      letter-spacing: 3px;
      margin-bottom: 20px;
      opacity: 0;
      animation: fadeInUp 1s ease 1s forwards;
      font-family: 'Montserrat', sans-serif;
      font-weight: 500;
     }

     .loader-progress {
      width: 300px;
      height: 4px;
      background: rgba(255, 255, 255, 0.2);
      border-radius: 4px;
      overflow: hidden;
     }

     .loader-progress-bar {
      height: 100%;
      width: 0%;
      background: linear-gradient(90deg, var(--accent-color), #ffffff);
      border-radius: 4px;
      animation: progressLoad 2s ease-in-out 1.5s forwards;
     }

     /* Animaciones */
     @keyframes fadeInScale {
      0% {
        opacity: 0;
        transform: scale(0.8);
      }

      100% {
        opacity: 1;
        transform: scale(1);
      }
     }

     @keyframes fadeInUp {
      0% {
        opacity: 0;
        transform: translateY(20px);
      }

      100% {
        opacity: 1;
        transform: translateY(0);
      }
     }

     @keyframes progressLoad {
      0% {
        width: 0%;
      }

      100% {
        width: 100%;
      }
     }




        /* ============================
           CONTENIDO
        ============================ */
        .contenido { 
            text-align: center;
            color: #333;
                margin: 10px !important;
        padding: 0 15px;
        font-size: 0.9rem;
        }

        .fullscreen-btn {
            position: absolute;
            top: 100px;
            right: 70px;
            padding: 12px 18px;
            background: rgba(255, 255, 255, 0.9);
            border-radius: var(--border-radius);
            cursor: pointer;
            z-index: 1000;
            transition: 0.3s ease;
            border: none;
            font-weight: 600;
            box-shadow: var(--shadow-light);
            font-family: 'Poppins', sans-serif;
            backdrop-filter: blur(10px);
            border: 1px solid rgba(255, 255, 255, 0.2);
            color: #003366;
            display: flex;
            align-items: center;
            gap: 8px;
        }

        .fullscreen-btn:hover {
            background: #fff;
            transform: translateY(-2px);
            box-shadow: var(--shadow-medium);
            color: var(--primary-color);
        }

       

  
    /* cursores controlados por el contenedor (no por la imagen) */
.zoom-area {
  width: 100%;
  height: 100%;
  overflow: hidden;
  position: relative;
  cursor: zoom-in !important;    /* lupa inicial */
  touch-action: none;            /* evita scroll del navegador al arrastrar */
}

.zoom-area.zoomed {
  cursor: zoom-out !important;   /* cuando está ampliado */
}

.zoom-area.grabbing {
  cursor: grabbing !important;   /* cuando hace drag */
}

/* imagen hereda el cursor del contenedor para no "pisar" la lupa */
.zoom-image {
  width: 100%; 
  object-fit: contain;
  cursor: inherit;               /* <--- clave */
  user-select: none;
  -webkit-user-drag: none;
  -webkit-user-select: none;
  display: block;
}

/* tip visual */
.zoom-tip {
  position: absolute;
  bottom: 10px;
  right: 10px;
  background: rgba(0,0,0,0.65);
  color: #fff;
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 13px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .45s ease;
  z-index: 40;
}
.zoom-area.show-tip .zoom-tip { opacity: 1; }
.zoom-area::after{
  content: "\f00e"; /* icono font-awesome lupa (código unicode) */
  font-family: "Font Awesome 6 Free"; 
  font-weight: 900;
  position:absolute;
  left:12px; top:12px;
  color: rgba(255,255,255,0.9);
  font-size: 18px;
  pointer-events: none;
  opacity: 0.85;
}
 

/* --------------------
   CLASES GENERALES: MARGIN (m-)
   -------------------- */

.m-0 { margin: var(--space-0) !important; }
.m-1 { margin: var(--space-1) !important; }
.m-2 { margin: var(--space-2) !important; }
.m-3 { margin: var(--space-3) !important; }
.m-4 { margin: var(--space-4) !important; }
.m-5 { margin: var(--space-5) !important; }

.mb-5 { margin-bottom: var(--space-5) !important; }


/* Margin - Eje Vertical (my-) */
.my-1 { margin-top: var(--space-1) !important; margin-bottom: var(--space-1) !important; }
.my-auto { margin-top: auto; margin-bottom: auto; }

/* Margin - Eje Horizontal (mx-) */
.mx-1 { margin-left: var(--space-1) !important; margin-right: var(--space-1) !important; }
.mx-auto { margin-left: auto; margin-right: auto; } /* Para centrar elementos de bloque */

/* Margin - Direcciones Específicas (mt-, mb-, ml-, mr-) */
.mt-2 { margin-top: var(--space-2) !important; }
.mb-4 { margin-bottom: var(--space-4) !important; }
.ml-3 { margin-left: var(--space-3) !important; }
.mr-5 { margin-right: var(--space-5) !important; }


/* --------------------
   CLASES GENERALES: PADDING (p-)
   -------------------- */

.p-0 { padding: var(--space-0) !important; }
.p-1 { padding: var(--space-1) !important; }
.p-2 { padding: var(--space-2) !important; }
.p-3 { padding: var(--space-3) !important; }
.p-4 { padding: var(--space-4) !important; }
.p-5 { padding: var(--space-5) !important; }

/* Padding - Eje Vertical (py-) */
.py-2 { padding-top: var(--space-2) !important; padding-bottom: var(--space-2) !important; }

/* Padding - Eje Horizontal (px-) */
.px-4 { padding-left: var(--space-4) !important; padding-right: var(--space-4) !important; }

/* Padding - Direcciones Específicas (pt-, pb-, pl-, pr-) */
.pt-1 { padding-top: var(--space-1) !important; }
.pb-3 { padding-bottom: var(--space-3) !important; }
.pl-5 { padding-left: var(--space-5) !important; }
.pr-0 { padding-right: var(--space-0) !important; }

 
.grid {
    display: grid
;
}
.absolute {
    position: absolute;
}
.grid-cols-4 {
    grid-template-columns: repeat(8, minmax(0, 1fr));
}
.w-64 {
    width: 31rem
}
.object-cover {
    -o-object-fit: cover;
    object-fit: cover;
}
/* La galería debe ocupar todo el espacio del HERO */
.gallery {
    /* Mantenemos absolute, grid, grid-cols-4 y gap-2 */
    /* Lo esencial es la posición absoluta y el estiramiento completo: */
    position: absolute; /* Ya existe en .absolute */
    top: 0; /* Cubre todo el alto del padre */
    bottom: 0;
    left: 0; /* Cubre todo el ancho del padre */
    right: 0;
    z-index: -1; /* CLAVE: lo envía al fondo, detrás de header y contenido */
    overflow: hidden; /* Oculta cualquier desborde que quede por la animación */
}

.gallery img {
    /* Hace que la imagen llene su celda de la cuadrícula y mantenga la proporción */
    width: 100%; 
    height: 100%;
    object-fit: cover; /* Ya existe en .object-cover */
}

/* =========================
   RESPONSIVE MOBILE (<768px)
   ========================= */
@media (max-width: 768px) {

    /* HERO SECTION */
    .hero-section {
        padding: 15px;
        padding-bottom: 30px;
        min-height: 70vh; /* Ajusta altura para móviles */
    }

    .hero-content {
        flex-direction: column; /* De 3 columnas a stack vertical */
        align-items: center;
        min-height: auto;
        gap: 20px; /* separación entre items */
    }

    .hero-item {
        flex: none; /* que no crezca */
        width: 100%;
        justify-content: center; /* todos centrados */
        align-items: center;
    }

    .hero-item.left,
    .hero-item.center-btn,
    .hero-item.right {
        justify-content: center;
        align-items: center; /* todos centrados vertical y horizontal */
    }

    /* Imágenes hero */
    .left-img,
    .right-img,
    .main-person-image {
        width: 90%;
        max-width: 200px;
        height: auto;
        transform: none; /* quita translate inicial */
    }



    


    .logo-fgj {
        height: 100px;
    }

    /* Botón central */
    .center-btn button,
    .report-cta {
        width: 80%;
        max-width: 250px;
        font-size: 1rem;
        padding: 12px 18px;
    }

    /* SECCIÓN DETALLE REPORTES */
    .report-detail-section {
        flex-direction: column;
        text-align: center;
        padding: 40px 10px;
        gap: 30px;
        min-height: auto; 
    }

    .report-image-side {
        flex-basis: auto;
        min-height: auto;
        margin-bottom: 20px;
    }

    .report-cover {
        width: 80%;
        height: auto;
        margin: 0 auto;
    }

    .report-year {
        top: -5px;
        right: 5px;
        font-size: 1.5em;
    }

    /* MINI REPORTS STICKY */
    .report-minis-container {
        padding-left: 15px;
        justify-content: flex-start;
        gap: 15px;
        overflow-x: auto;
    }

    .report-mini img {
        width: 120px;
        height: auto;
    }

    /* FULLSCREEN BUTTON */
    .fullscreen-btn {
        top: 20px;
        right: 15px;
        padding: 10px 14px;
        font-size: 0.85rem;
    }

    /* SCROLL TO TOP */
    .scroll-to-top-btn {
        width: 45px;
        height: 45px;
        bottom: 15px;
        right: 15px;
    }

    /* TIPOS DE TEXTO */
    .main-title-area {
        padding-top: 30px;
        font-size: 1.1rem;
    }

 

    /* GALERÍA DE FONDO */
    .gallery {
        grid-template-columns: repeat(2, 1fr); /* menos columnas */
        gap: 5px;
    }

    /* ZOOM AREA */
    .zoom-area {
        width: 100%;
        height: auto;
    }

    .zoom-image {
        width: 100%;
        height: auto;
    }
}


.header-elegante {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 7%;
    background: linear-gradient(90deg, var(--background-khaki), var(--accent-color));
    border-bottom: 2px solid #e6e6e6;
    gap: 40px;
}

.header-texto h1 {
    font-size: 2rem;
    font-weight: 700;
    color: #fff;
    margin: 0;
    line-height: 1.2;
    text-align: end;
}

.header-texto .subtitulo {
    margin-top: 8px;
    font-size: 1.7rem;
    color: #fff;
    font-weight: 400;
    text-align: end;
}

.header-imagen img {
    max-width: 180px;
    height: auto;
    object-fit: contain;
    filter: drop-shadow(0 5px 10px rgba(0,0,0,0.15));
}

/* RESPONSIVE */
@media (max-width: 768px) {
    .header-elegante {
        flex-direction: column-reverse;
        text-align: center;
        padding: 25px 5%;
    }

    .header-imagen img {
        max-width: 150px;
    }

    .header-texto h1 {
        font-size: 1.8rem;
    }

    .header-texto .subtitulo {
        font-size: 1rem;
    }
}
/* ===========================
   BOTÓN FLOTANTE PARA REGRESAR
   =========================== */
.btn-regresar {
    position: fixed;
    bottom: 60px;
    right: 40px;
    width: 55px;
    height: 55px;
    border-radius: 50%;
    background-color: var(--accent-color);
    color: var(--text-color-light);
    border: 3px solid var(--accent-color);
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 22px;
    cursor: pointer;
    z-index: 9999;
    box-shadow: 0 4px 15px rgba(0,0,0,0.25);
    transition: all 0.25s ease;
}

.btn-regresar:hover {
    background-color: var(--background-khaki);
    color: var(--primary-color);
    transform: scale(1.1);
}



/* --------------------
   BOTÓN HOME
--------------------- */
#btnHome {
    position: fixed;
    top: 20px;
    left: 20px;
    background: #ffffffcc;
    padding: 10px 16px;
    border-radius: 8px;
    font-size: 17px;
    border: none;
    cursor: pointer;
    z-index: 2000;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

/* --------------------
   ÁREA DEL VISOR
--------------------- */
#viewerWrapper { 
    top: 100px;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: auto;
    padding: 10px 0;
    background: #e8e8e8;
}

/* Contenedor del libro */
#viewerContainer {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    width: 100%;
    margin-top: 10px;
}

/* CANVAS — PDF */
canvas {
    background: white;
    width: auto;
    height: auto;
        max-width: none; /* quita la limitación */
    border-radius: 4px;
    transition: transform 0.25s ease;
}

/* BOTONES LATERALES */
#btnPrev, #btnNext {
    position: fixed;
    top: 55%;
    transform: translateY(-50%);
    background: #ffffff;
    border: none;
    padding: 14px;
    font-size: 26px;
    cursor: pointer;
    border-radius: 8px;
    z-index: 1000;
}

#btnPrev { left: 20px; }
#btnNext { right: 20px; }

/* CONTROLES DE ZOOM */
#zoomControls {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    gap: 12px;
    z-index: 1000;
}

#zoomControls button {
    background: white;
    border: none;
    padding: 12px 16px;
    font-size: 18px;
    cursor: pointer;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}

/* -------------------------
   LOADER ELEGANTE FGJ
-------------------------- */  
.loader-container {
  position: fixed;
  inset: 0;
  background: linear-gradient(to bottom, #676767, #333);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  opacity: 1;
  transition: opacity .6s ease;
}

.loader-logo {
  width: 250px;
  opacity: 0;
  animation: fadeIn 1.5s forwards;
}

.dots {
  display: flex;
  margin-top: 20px;
}

.dots span {
  width: 12px;
  height: 12px;
  margin: 0 6px;
  background: white;
  border-radius: 50%;
  opacity: 0.3;
  animation: blink 1.4s infinite ease-in-out;
}
.logo-area{
    margin-right: 150px !important;
    }


.dots span:nth-child(2) { animation-delay: 0.2s; }
.dots span:nth-child(3) { animation-delay: 0.4s; }

@keyframes blink {
  0% { opacity: 0.3; }
  50% { opacity: 1; }
  100% { opacity: 0.3; }
}

@keyframes fadeIn {
  to { opacity: 1; }
}

 
