/* =========================================
   GRAPHI APP - ESTILOS PRINCIPALES
   Versión optimizada
   ========================================= */

/* =========================================
   1. ESTILOS GLOBALES Y UTILIDADES
   ========================================= */
@font-face {
  font-family: 'DroidSans';
  src: url('DroidSans.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

body {
  background-color: #0d0d0d;
  color: #f0f0f0;
  font-family: 'Inter', sans-serif;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.container {
  padding: 2rem 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
}

h1 {
  font-size: 2.2rem;
  margin: 1rem 0 0.5rem;
  text-align: center;
}

h5 {
  text-align: center;
}

p {
  font-size: 1.1rem;
  color: #cccccc;
  max-width: 600px;
  text-align: center;
}

/* Utilidades reutilizables */
.hidden {
  display: none !important;
}

/* =========================================
   2. BOTONES Y CONTROLES
   ========================================= */
.button {
  background-color: #00c3aa;
  color: #fff;
  border: none;
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  border-radius: 6px;
  cursor: pointer;
  text-decoration: none;
  margin-top: 1.5rem;
  transition: background-color 0.3s ease;
}

.button:hover {
  background-color: #00a992;
}

.button-container {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 1.5rem;
}

/* =========================================
   3. HEADER Y NAVEGACIÓN
   ========================================= */
.header-bar {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  box-sizing: border-box;
}

/* Estilos de logos */
.logo {
  max-width: 280px;
  height: auto;
  margin-top: 20px;
}

.logo-top-left {
  max-width: 140px;
  margin-top: 0;
  margin-left: 0;
}

#ga4-logo, #ga4-logo-page2 {
  max-width: 100px;
  height: auto;
  margin-top: -40px;
  margin-left: -25px !important;
}

/* Selector de idioma */
.language-selector {
  background: #1e1e1e;
  border: 1px solid #333;
  border-radius: 6px;
  padding: 0.4rem 0.8rem;
  cursor: pointer;
  color: #f0f0f0;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: background 0.3s;
}

.language-selector:hover {
  background: #2c2c2c;
}

/* =========================================
   4. FOOTER
   ========================================= */
footer {
  width: 100%;
  color: #777;
  padding: 0.8rem 1rem 1.2rem;
  text-align: center;
  margin-top: auto;
  box-sizing: border-box;
}

footer a {
  color: #00c3aa;
  text-decoration: none;
}

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

footer p {
  margin: 0 auto;
  text-align: center;
  font-size: 0.65rem !important;
}

/* =========================================
   5. PÁGINA DE INICIO (index.html)
   ========================================= */
.steps {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 3rem;
  max-width: 900px;
  width: 100%;
}

.step {
  background: #1e1e1e;
  border-left: 4px solid #00c3aa;
  padding: 1rem;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.step svg {
  width: 24px;
  height: 24px;
  fill: #ffffff;
  flex-shrink: 0;
}

.step-text {
  text-align: left;
  font-size: 0.95rem;
}

.step-text strong {
  color: #00c3aa;
  display: block;
  font-size: 1rem;
  margin-bottom: 0.2rem;
}

/* =========================================
   6. PÁGINA DE PROPIEDADES (ga4.html)
   ========================================= */
.property-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
  width: 90%;
  max-width: 1000px;
  margin-top: 2rem;
}

.card {
  background: #1e1e1e;
  padding: 1rem;
  border-radius: 8px;
  border-left: 4px solid #00c3aa;
  transition: background 0.2s, transform 0.2s;
}

.card:hover {
  background: #2a2a2a;
  transform: scale(1.02);
}

.card a {
  text-decoration: none;
  color: #00c3aa;
  display: block;
}

.card strong {
  color: #fff;
  font-size: 1rem;
}

/* =========================================
   7. PÁGINA DE DASHBOARD (dashboard.html)
   ========================================= */

/* 7.1 Contenedor para la infografía */
.infographic-container {
  width: 100%;
  max-width: 800px;
  margin-top: 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.infographic-preview {
  background: #1e1e1e;
  border-radius: 8px;
  padding: 1rem;
  min-height: 400px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  width: 100%;
}

#infographic-result {
  max-width: 100%;
  max-height: 2000px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
  border-radius: 6px;
}

.loading-indicator {
  font-size: 1.2rem;
  color: #00c3aa;
  text-align: center;
  padding: 2rem;
}

/* 7.2 Canvas de infografía */
.infographic-canvas {
  width: 1200px;
  height: 1554px;
  background-color: white;
  display: none;
  position: relative;
  color: #333;
  font-family: 'Roboto', sans-serif;
}

/* 7.3 Cabecera de la infografía */
.property-header {
  position: relative;
  padding: 30px 40px 0;
}

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

.dotted-line {
  height: 1.5px;
  background-image: linear-gradient(to right, #cccccc 50%, transparent 50%);
  background-size: 4px 100%;
  margin-top: -35px;
  margin-left: 230px;
  margin-right: -10px;
}

.base-line {
  height: 1.2px;
  background-color: #000000;
  margin-top: 0;
  margin-left: 0;
  margin-right: -10px;
}

.property-title {
  font-family: 'Roboto', monospace;
  font-size: 55px;
  color: #668E9E;
  text-align: left;
  padding-left: 230px;
  letter-spacing: -2.5px;
  /* Agregar estas líneas */
  position: absolute;
  top: 0px; /* Ajusta según necesites */
  left: 0;
  width: 100%;
}

#canvas-property-name, #canvas-property-name-page2 {
  position: relative;
  display: block;
  width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.decorative-bar, #decorative-bar-page2 {
  height: 55px;
  width: 1100px;
  margin: 15px 0;
  background-image: url('/assets/barra_titulo2.png');
  background-repeat: repeat-x;
  background-size: 60px 55px;
}

.content-title {
  display: flex;
  justify-content: flex-end;
  margin-right: 100px;
  margin-top: -88px;
}

.content-title-text {
  font-family: 'Pacifico', cursive;
  font-size: 50px;
  color: #656565;
}

.green-text {
  color: #92C048;
}

/* Título de la sección demográfica */
.decorative-bar2 {
  height: 55px;
  width: 1100px;
  margin: 150px 100px;
  background-image: url('/assets/barra_titulo2.png');
  background-repeat: repeat-x;
  background-size: 60px 55px;
}

.content-title2 {
  display: flex;
  justify-content: flex-end;
  margin-right: 420px;
  margin-top: -220px;
}

.content-title-text2 {
  font-family: 'Pacifico', cursive;
  font-size: 50px;
  color: #656565;
}

.content-title3 {
  display: flex;
  justify-content: flex-end;
  margin-right: 50px;
  margin-top: -88px;
}

.blue-text {
  color: #00ACC1;
}

.content-title-text3 {
  font-family: 'Pacifico', cursive;
  font-size: 50px;
  color: #656565;
}

.red-text {
  color: #E57373;
}

/* 7.4 Sección de visitas */
.visits-question {
  font-family: 'Roboto', monospace;    
  text-align: right;
  font-size: 22px;
  color: #3B3B3B;
  margin-right: 180px;
}

.people-icons {
  position: relative;
  top: -15px;
  display: inline-block;
  padding: 0;
  line-height: 0;
  font-size: 0;
  margin-left: 560px;
  margin-top: 0 !important;
  white-space: nowrap;
  z-index: 10;
}

.visits-total-container {
  position: absolute;
  right: 200px;
  top: 268px;
  text-align: left;
}

.visits-total {
  font-family: 'Roboto', monospace;  
  font-size: 40px;
  color: #3B3B3B;
  letter-spacing: -3px;
  font-weight: bold;
}

.visits-label { 
  position: absolute;
  font-size: 25px;
  color: #666;
}

.visits-label-top {
  margin-left: 10px;
  margin-top: 2px;
  letter-spacing: -1px;
  font-weight: normal;
}

.visits-label-bottom {
  margin-left: 10px;
  margin-top: 20px;
  letter-spacing: -1px;
  font-weight: normal;
}

.comparison-text {
  position: absolute;
  right: 180px;
  top: 320px;
  text-align: right;
  font-size: 20px;
}

.delta-text {
  font-weight: bold;
}

/* 7.5 Gráficos y datos de visitas */
.chart-area {
  margin: 5px 565px;
  position: relative;
  width: 530px;
  height: 100px;
}

.chart-container {
  display: flex;
  justify-content: flex-end;
  width: 530px;
  height: 120px;
  margin-left: auto;
}

.date-ruler {
  display: flex;
  justify-content: space-between;
  margin-top: 40px;
}

.date-label {
  font-weight: bold;
  font-size: 20px;
  color: #444;
}

.date-label-end {
  text-align: right;
}

.ruler-line {
  position: relative;
  height: 1.2px;
  background-color: #666;
  margin: -8px auto 0;
  width: 60%;
}

.ruler-tick {
  position: absolute;
  width: 1.2px;
  height: 10px;
  background-color: #666;
  top: -4px;
}

.ruler-tick-0 { left: 0%; }
.ruler-tick-10 { left: 10%; }
.ruler-tick-20 { left: 20%; }
.ruler-tick-30 { left: 30%; }
.ruler-tick-40 { left: 40%; }
.ruler-tick-50 { left: 50%; }
.ruler-tick-60 { left: 60%; }
.ruler-tick-70 { left: 70%; }
.ruler-tick-80 { left: 80%; }
.ruler-tick-90 { left: 90%; }
.ruler-tick-100 {left: 100%;}

/* 7.5.1 Sección de análisis de patrones de visita */
.visit-pattern-analysis {
  position: absolute;
  left: 105px;
  top: 555px;
  width: 930px;
  text-align: center;
  z-index: 6;
}

.visit-pattern-text {
  font-family: 'Roboto', monospace;
  font-size: 16px;
  color: #AAAAAA;
  font-weight: 400;
  letter-spacing: -1.4px;
  line-height: -1.2;
}

/* 7.6 Sección del cuadro de texto */
.text-box-container {
  position: absolute;
  left: 80px;
  top: 230px;
  z-index: 5;
}

.text-box-image {
  width: 430px;
  height: 130px;
  display: block;
  box-sizing: border-box;
}

.text-box-content {
  position: absolute;
  top: 15px;
  left: 25px;
  right: 25px;
  bottom: 15px;
  color: #333333;
  font-family: 'Roboto', sans-serif;
  letter-spacing: 1px;
  text-align: center;
  overflow: hidden;
}

.text-box-title {
  font-size: 25px;
  font-weight: bold;
  margin: 0 0 0 15px;
  color: #3B3B3B;
  font-family: 'Roboto', sans-serif;
  letter-spacing: -1.2px;
  text-transform: uppercase;
  text-align: left !important;
}

.text-box-paragraph {
  font-size: 20px;
  font-weight: lighter;
  margin: 0;
  color: #555555;
  font-family: 'Roboto';
  letter-spacing: -1.5px;
  line-height: 0.8;
}

/* 7.7 Imagen y sección de dispositivos */
.device-image-container {
  position: absolute;
  left: 160px;
  top: 365px;
  z-index: 4;
  width: 100px; /* Ancho fijo */
  height: 150px; /* Alto fijo */
}

.device-image {
  width: 100%; /* Ocupa todo el contenedor */
  height: 100%; /* Ocupa todo el contenedor */
  object-fit: contain; /* Mantiene la proporción */
}

.devices-chart-section {
  position: absolute;
  left: 50px;
  top: 530px;
  width: 270px;
  height: 200px;
  display: none;
}

.devices-chart-container {
  width: 100%;
  height: 100%;
  margin-bottom: 10px;
}

.devices-list-section {
  position: absolute;
  left: 250px;
  top: 355px;
  width: 300px;
  display: flex;
  flex-direction: column;
}

.devices-list-container {
  font-family: 'Roboto', sans-serif;
  margin: 3px 0;
  padding: 2px 0;
  text-align: center;
  color: #555555;
}

.device-percentage {
  font-size: 20px;
  font-weight: bold;
  color: #333333;
  margin-right: 25px;
}

.device-label {
  font-size: 16px;
}

/* Dispositivo principal */
#devices-list-container_1_porcent .device-percentage {
  font-family: 'DroidSans';  
  font-size: 50px;
  color: #3B3B3B;
  letter-spacing: -1.5px;
  font-weight:bolder;
   text-align: left;
}

#devices-list-container_1_name .device-label {
  font-size: 20px;
  font-weight: bold;
}

/* Texto explicativo dispositivos */
.device-unified-paragraph {
  font-family: 'Roboto';
  font-size: 20px;
  color: #555555;
  margin: 0 47px;
  line-height: 0.8;
  text-align: left !important;
  padding-left: 10px;
  white-space: normal;
}

.device-unified-paragraph span {
  color: inherit; /* Hereda el color del texto principal */
  /* La negrita se aplicará a través de inline styles en el JavaScript */
}

/* Alinear a la izquierda SOLO el porcentaje principal grande (fuera del párrafo) */
#devices-list-container_1_porcent {
  text-align: left !important;
  padding-left: 50px;
}

/* Mantener los estilos originales para los elementos DENTRO del párrafo unificado */
.device-unified-paragraph #devices-list-container_1_porcent,
.device-unified-paragraph #devices-list-container_2_porcent,
.device-unified-paragraph #devices-list-container_3_porcent,
.device-unified-paragraph #devices-list-container_1_name,
.device-unified-paragraph #devices-list-container_2_name,
.device-unified-paragraph #devices-list-container_3_name {
  color: inherit; /* Hereda el color del texto principal */
}

.device-unified-paragraph #devices-list-container_1_porcent {
  font-family: 'Roboto', monospace;  
  font-size: 22px;
  color: #3B3B3B;
  letter-spacing: -1px;
  margin-right: 5px;
}

/* 7.8 Secciones de gráficos analíticos */
/* Sección de tráfico */
.traffic-container {
  position: absolute;
  margin: 40px;
  margin-left: 100px; 
}

.traffic-chart-container {
  height: 200px;
  margin-top: 220px;
  margin-right: 85px;
}

.section-title {
  font-size: 18px;
  font-weight: bold;
  color: #60899A;
  margin-bottom: 10px;
  display: none;
}

/* Leyenda del gráfico de tráfico */
#traffic-custom-legend {
  margin: 10px 0 15px;
  font-family: 'Roboto', sans-serif;
  font-size: 12px;
  color: #555;
  text-align: center;
   display: none;
}

#traffic-custom-legend div {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
      display: none;
}

#traffic-custom-legend span {
  display: inline-block;
  width: 10px;
  height: 10px;
  margin-right: 5px;
  vertical-align: middle;
      display: none;
}

/* 7.9 Sección de tiempo de permanencia con gauge */
.avg-session-container {
  position: absolute;
  left: 25px;
  top: 288px;
  text-align: center;
  width: 300px;
  z-index: 7;
}

.gauge-container {
  width: 145px;
  height: 120px;
  margin: 0 auto 15px;
}

.clock-image-container, .clock-image-container3 {
  position: absolute;
  right: 850px;
  top: 283px;
  z-index: 5;
}

.avg-session-duration {
  font-family: 'Roboto', monospace;
  font-size: 30px;
  color: #3B3B3B;
  font-weight: bold;
  letter-spacing: -1px;
  margin-bottom: 0;
}

.session-benchmark {
  font-family: 'Roboto';
  font-size: 40px;
  color: #666;
}

.benchmark-label {
  font-weight: normal;
    display: none;
}

.benchmark-value {
  font-weight: bold;
  color: #92C048;
    display: none;
}

/* Contenedor de duración e imágenes de reloj */
.duration-container {
  position: absolute;
  left: 205px;
  top: 320px;
  text-align: center;
  width: 300px;
  z-index: 7;
}

.benchmark-container {
  position: absolute;
  left: 270px;
  top: 360px;
  text-align: center;
  width: 300px;
  z-index: 7;
  letter-spacing: -1px;
  line-height: 1;
    
}

/* Estilos para los componentes de tiempo */
.session-time-component {
  position: absolute;
  text-align: center;
}

/* Estilos de valores de tiempo */
.time-value {
  display: block;
  font-family: 'Roboto', monospace;
  line-height: 1;
  letter-spacing: -1px;
  font-weight: bold;
}

.hours-value {
  font-size: 45px;
  font-weight: 700;
  color: #3B3B3B;
}

.minutes-value {
  font-size: 50px !important;
  font-weight: 600;
  color: #444;
  line-height: 1;
  margin-bottom: -7px;
}

.seconds-value {
  font-size: 20px;
  font-weight: 500;
  color: #555;
}

/* Estilos de etiquetas de tiempo */
.time-label {
  display: block;
  margin-top: 0;
    
}

.hours-label {
  font-size: 22px;
  font-weight: 500;
  color: #666;
  margin-top: 2px;
  font-family: 'Roboto', sans-serif;
}

.minutes-label {
  font-size: 18px !important;
  font-weight: normal;
  color: #777;
  line-height: 1;
  margin-top: 0;
  display: block;
  width: 100%;
}

.seconds-label {
  font-size: 12px;
  font-weight: 300;
  color: #888;
  opacity: 0.9;
  font-family: 'Roboto', sans-serif;
}

/* Posicionamiento de componentes de tiempo */
#session-hours-container {
  left: 30px;
  top: 100px;
}

#session-minutes-container {
  position: absolute;
  left: 50px;
  top: -30px;
  width: auto;
  min-width: 200px;
  text-align: left;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

#session-seconds-container {
  left: 100px;
  top: -20px;
}

/* Estilos de componentes de tiempo */
.hours-component {
  border-radius: 8px;
  padding: 0 15px;
  display: none;
}

.minutes-component {
  border-radius: 0;
  padding: 0 15px;
}

.seconds-component {
  border-radius: 5px;
  padding: 0 20px;
}

/* Transiciones para elementos de tiempo */
.time-value, .time-label {
  transition: all 0.3s ease;
}

/* 7.10 Imágenes de reloj */

.clock-image, .clock-image3 {
  width: 150px;
  height: 177px;
  top: 185px;
  display: block;
}

.clock-image-container2 {
  position: absolute;
  right: 880px;
  top: 385px;
  z-index: 8;
  display: none;
}

.clock-image2 {
  width: 90px;
  height: 90px;
  display: none;
}

.clock-image-container3 {
  z-index: 10;
}



/* =========================================
   8. SEGUNDA PÁGINA DE INFOGRAFÍA
   ========================================= */

/* Canvas de página 2 */
#infographic-canvas-page2 {
  width: 1200px;
  height: 1554px;
  background-color: white;
  display: none;
  position: relative;
  color: #333;
  font-family: 'Roboto', sans-serif;
  page-break-before: always;
}

/* Footer de página */
.page-footer {
  position: absolute;
  bottom: 30px;
  width: 100%;
  text-align: center;
}

.page-number {
  font-family: 'Roboto', sans-serif;
  font-size: 14px;
  color: #888;
}

.benchmark-info-text {
  font-family: 'Roboto', sans-serif;
  font-size: 12px;
  color: #666;
  max-width: 800px;
  margin: 0 auto;
  line-height: 1.4;
  padding: 0 20px;
}

/* =========================================
   9. SECCIÓN DEMOGRÁFICA 
   ========================================= */

/* Contenedor principal para la sección demográfica moderna */
.demographics-modern-container {
  position: absolute;
  top: 700px;
  left: 50px;
  width: 1100px;
  height: auto;
  padding: 20px;
  font-family: 'Roboto', sans-serif;
  z-index: 10;
}

/* Título "La mayoría de tus fans son:" */
.demographics-heading {
  text-align: left;
  margin-bottom: -60px;
  padding-left: 520px;
}

.demographics-fans-title {
  font-family: 'DroidSans', sans-serif;
  font-size: 21px;
  color: #3B3B3B;
  font-weight:bolder;
  margin: 0;
  letter-spacing: -0.5px;
}

/* Sección principal con círculos y resumen */
.demographics-main-section {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 30px;
  margin-left: 40px;
  margin-bottom: 40px;
  position: relative;
}

/* Contenedor de círculos de género */
.gender-circles-container {
  display: flex;
  gap: 40px;
  justify-content: center;
  margin-bottom: 20px;
}

/* Wrapper para cada círculo de porcentaje */
.gender-circle-wrapper {
  width: 220px;
  height: 220px;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Círculo de porcentaje con progreso */
.gender-percentage-circle {
  width: 100%;
  height: 100%;
  position: relative;
}

/* Fondo del círculo */
.circle-background {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background-color: #ffffff !important;
}

/* Arcos para mostrar el progreso */
.circle-arc, .circle-arc-2 {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border-width: 35px !important; /* Hacerlo más grueso */
  box-sizing: border-box;
}

/* Etiquetas de porcentaje */
.percentage {
  position: absolute;
  top: 15%;
  left: 70%;
  transform: translate(-50%, -50%);
  font-size: 32px;
  font-weight: bold;
  font-family: 'DroidSans', sans-serif;
  text-align: center;
  z-index: 10;
  background-color: rgba(255, 255, 255, 0.7);
  border-radius: 50%;
  width: 70px;
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Resumen demográfico dominante */
.demographics-dominant-summary {
  text-align: center;
  margin-left: 0px;
  font-family: 'DroidSans', sans-serif;
}

/* Título principal (HOMBRES/MUJERES) */
.demographics-title-female, .demographics-title-male {
  font-size: 48px;
  font-weight: bold;
  margin: 0;
  line-height: 1.1;
  letter-spacing: -1px;
  font-family: 'DroidSans', sans-serif;
}

/* Ajuste de colores específicos */
.demographics-title-female {
  color: #FF6B98; /* Rosa para mujeres */
}

.demographics-title-male {
  color: #2D7FFF; /* Azul para hombres */
}

/* Subtítulo (ENTRE X-Y AÑOS) */
.demographics-subtitle-female, .demographics-subtitle-male {
  font-size: 24px;
  font-weight: 500;
  margin-top: 10px;
  line-height: 1.2;
  font-family: 'DroidSans', sans-serif;
}

/* Ajuste de colores específicos para subtítulos */
.demographics-subtitle-female {
  color: #FF6B98; /* Rosa para mujeres */
}

.demographics-subtitle-male {
  color: #2D7FFF; /* Azul para hombres */
}

/* Icono persona */
.demographics-person-icon {
  width: 158px;
  height: 300px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-left: 20px;
  position: relative;
}

.gender-dominant-icon {
  width: 158px;
  height: 300px;
  object-fit: contain;
}

/* GRÁFICO VERTICAL DE EDAD Y GÉNERO */
.age-bars-section {
  margin: -60px -40px;
  width: calc(100% - 80px);
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Contenedor del gráfico vertical */
.age-chart-container {
  width: 800px;
  height: 150px;
  position: relative;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
}

/* Contenedor de etiquetas de edad debajo del gráfico */
.age-labels-container {
  display: flex;
  justify-content: space-between;
  width: 83%;
  margin-top: -25px;
}

/* Etiquetas individuales de edad */
.age-label {
  font-size: 23px;
  color: #777;
  text-align: center;
  flex: 1;
  font-weight:lighter;
  font-family: 'DroidSans', sans-serif;
}

/* Grupo de barras por edad */
.age-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: calc(100% / 7); /* 7 grupos de edad */
  height: 100%;
  position: relative;
}

/* Barras individuales para cada género */
.age-bar {
  width: 130px;
  background-color: transparent;
  position: absolute;
  transition: height 0.5s ease-in-out;
}

/* Barra superior (mujeres) */
.female-bar {
  background-color: #FF6B98;
  bottom: 50%;
  border-radius: 4px 4px 0 0;
  transform-origin: bottom center;
}

/* Barra inferior (hombres) */
.male-bar {
  background-color: #2D7FFF;
  top: 50%;
  border-radius: 0 0 4px 4px;
  transform-origin: top center;
}

/* Línea decorativa para gráfico de edad */
.age-bar-line-absolute {
  position: absolute;
  left: 130px;
  top: 890px;
  width: 681px;
  height: 73px;
  z-index: 50;
  pointer-events: none;
}

.age-bar-line-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* =========================================
   10. SECCIÓN DE MAPA MUNDIAL
   ========================================= */

/* Contenedor del mapa mundial */
#world-map-container {
  position: absolute;
  left: 20px!important;
  top: 1150px;
  width: 990px;
  height: 352px;
  z-index: 15;
  display: block !important;
  visibility: visible !important;
  background-color: transparent;
  box-sizing: border-box;
  font-family: 'Roboto', sans-serif;
}

#world-map {
  width: 990px !important;
  height: 352px !important;
  margin: 0 auto;
  display: block !important;
  visibility: visible !important;
}

/* Regiones del mapa */
.jvm-regions path {
  transition: fill 0.3s ease;
  stroke: #fff;
  stroke-width: 0.5;
  fill-opacity: 1;
}

.jvm-regions path:hover {
  fill-opacity: 0.8;
  cursor: pointer;
  stroke-width: 1.2;
}

/* Marcadores del mapa */
.jvm-marker {
  fill: #1976d2 !important;
  fill-opacity: 0.9 !important;
  stroke: #fff !important;
  stroke-width: 1 !important;
}

.jvm-marker:hover {
  fill: #0d47a1 !important;
  fill-opacity: 1 !important;
  cursor: pointer;
}

/* Tooltip del mapa */
.jvm-tooltip {
  font-family: 'Roboto', sans-serif;
  background-color: white !important;
  color: #333 !important;
  padding: 5px 10px !important;
  border-radius: 4px !important;
  border: none !important;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2) !important;
  font-size: 12px !important;
}

/* Contenedor del icono de avión */
#airplane-icon-container {
  position: absolute;
  left: 900px!important;
  top: 1150px!important;
  width: 300px!important;
  height: 300px!important;
  z-index: 20;
  display: block !important;
  visibility: visible !important;
  pointer-events: none;
}

#airplane-icon-container img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(2px 4px 6px rgba(0,0,0,0.2));
}

/* Estilos para la leyenda de país principal */
#country-stats-legend {
  font-family: 'DroidSans', sans-serif;
  position: absolute;
  left: 870px;
  top: 1350px;
  width: 250px;
  text-align: left;
  z-index: 21;
}

#country-stats-legend .percentage {
  font-size: 60px;
  font-weight: bold;
  color: #00BCD4;
  line-height: 1;
  margin-bottom: -5px;
}

#country-stats-legend .label {
  font-size: 14px;
  color: #00BCD4;
  text-transform: uppercase;
  line-height: 1.2;
}

#country-stats-legend .country {
  font-size: 28px;
  font-weight: bold;
  color: #00BCD4;
  line-height: 1.1;
}

/* =========================================
   11. ESTILOS RESPONSIVE
   ========================================= */
@media (min-width: 768px) {
  .steps {
    flex-direction: row;
    justify-content: space-between;
  }

  .step {
    flex: 1;
    flex-direction: row;
    align-items: flex-start;
    text-align: left;
  }
}

/* Ajustes para la impresión */

/* Estilos para la página de créditos */
.credits-display {
  background: #1e1e1e;
  border-radius: 8px;
  padding: 2rem;
  margin: 2rem 0;
  text-align: center;
}

.credits-info {
  margin-bottom: 1rem;
}

.credits-counter {
  font-size: 2.5rem;
  font-weight: bold;
  color: #00c3aa;
}

.credits-label {
  font-size: 1.5rem;
  color: #cccccc;
  margin-left: 0.5rem;
}

.packages-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}

.package-card {
  background: #1e1e1e;
  border-radius: 8px;
  padding: 1.5rem;
  text-align: center;
  border-left: 4px solid #00c3aa;
  transition: transform 0.2s, background 0.2s;
}

.package-card:hover {
  background: #2a2a2a;
  transform: translateY(-5px);
}

.package-credits {
  font-size: 1.25rem;
  font-weight: bold;
  color: #00c3aa;
  margin: 1rem 0;
}

.package-price {
  font-size: 1.2rem;
  margin-bottom: 1.2rem;
}

.package-button {
  width: 100%;
}

.paypal-container {
  width: 100%;
  max-width: 600px;
  margin: 2rem auto;
}

/* Mostrar u ocultar elementos */
.hidden {
  display: none !important;
}

/* Estilos para la página de créditos */
.credits-display {
  background: linear-gradient(135deg, #1e1e1e 0%, #2a2a2a 100%);
  border-radius: 16px;
  padding: 2.5rem;
  margin: 2.5rem 0;
  text-align: center;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  border-left: 1px solid rgba(255, 255, 255, 0.1);
}

.credits-info {
  margin-bottom: 1.5rem;
}

.credits-info h2 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  font-weight: 600;
  color: #00c3aa;
}

.credits-counter {
  position: relative;
  display: inline-block;
  padding: 1rem 0;
}

.credits-counter:before {
  content: "";
  position: absolute;
  width: 150px;
  height: 150px;
  background: radial-gradient(circle, rgba(0, 195, 170, 0.1) 0%, rgba(0, 195, 170, 0) 70%);
  border-radius: 50%;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: -1;
}

#credits-count {
  font-size: 5rem;
  font-weight: bold;
  color: #00c3aa;
  text-shadow: 0 0 15px rgba(0, 195, 170, 0.5);
  display: block;
  line-height: 1;
}

.credits-label {
  font-size: 1.25rem;
  color: #cccccc;
  margin-top: 0.5rem;
  display: block;
  letter-spacing: 2px;
  text-transform: uppercase;
}

/* Nuevo estilo horizontal para paquetes */
.credits-packages {
  max-width: 1200px;
  margin: 0 auto;
}

.credits-packages h2 {
  text-align: center;
  margin-bottom: 1.5rem;
}

.packages-grid {
  display: flex;
  flex-direction: row;
  justify-content: center;
  gap: 2rem;
  margin: 2.5rem 0;
  flex-wrap: nowrap;
}

.package-card {
  flex: 0 0 320px;
  min-width: 320px;
  background: linear-gradient(135deg, #1e1e1e 0%, #2a2a2a 100%);
  border-radius: 16px;
  padding: 2rem;
  text-align: center;
  position: relative;
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  border-left: 1px solid rgba(255, 255, 255, 0.1);
}

.package-card:before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: linear-gradient(to bottom, #00c3aa, #00a992);
}

.package-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
}

.package-card h3 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: white;
}

.package-credits {
  font-size: 2.5rem;
  font-weight: bold;
  color: #00c3aa;
  margin: 1.5rem 0;
  text-shadow: 0 0 10px rgba(0, 195, 170, 0.3);
  position: relative;
  display: inline-block;
  padding: 0.5rem 1.5rem;
}

.package-credits:before {
  content: "";
  position: absolute;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle, rgba(0, 195, 170, 0.15) 0%, rgba(0, 195, 170, 0) 70%);
  border-radius: 30px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: -1;
}

.package-price {
  font-size: 1.5rem;
  margin: 1rem 0 1.5rem;
  color: #f0f0f0;
}

.package-button {
  width: 100%;
  padding: 1rem;
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: 1px;
  border-radius: 30px;
  background: linear-gradient(135deg, #00c3aa 0%, #00a992 100%);
  transition: transform 0.2s, box-shadow 0.2s;
}

.package-button:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(0, 195, 170, 0.3);
  background: linear-gradient(135deg, #00d0b5 0%, #00b6a0 100%);
}

.paypal-container {
  width: 100%;
  max-width: 600px;
  margin: 2.5rem auto;
  background: rgba(30, 30, 30, 0.7);
  border-radius: 16px;
  padding: 2rem;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  border-left: 1px solid rgba(255, 255, 255, 0.1);
}

/* Botón de prueba personalizado */
.test-button {
  display: block;
  width: 100%;
  margin-top: 1.5rem;
  padding: 1rem;
  font-size: 1.1rem;
  font-weight: 600;
  text-align: center;
  color: #fff;
  background: linear-gradient(135deg, #8e44ad 0%, #9b59b6 100%);
  border: none;
  border-radius: 30px;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.test-button:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(155, 89, 182, 0.3);
  background: linear-gradient(135deg, #9b59b6 0%, #8e44ad 100%);
}

/* Animación de brillo para los cards */
@keyframes shine {
  0% {
    background-position: -100% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

.package-card:after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 200%;
  height: 100%;
  background: linear-gradient(
    to right,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.05) 50%,
    rgba(255, 255, 255, 0) 100%
  );
  transform: skewX(-20deg);
  background-size: 50% 100%;
  animation: shine 5s infinite linear;
  pointer-events: none;
}

/* Estilo para el botón de volver */
#back-button {
  background: linear-gradient(135deg, #333 0%, #444 100%);
  border-radius: 30px;
  padding: 0.75rem 1.5rem;
  transition: transform 0.2s, box-shadow 0.2s;
}

#back-button:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
  background: linear-gradient(135deg, #444 0%, #555 100%);
}

/* Estilos para el indicador de créditos en el header */
.header-credits {
  display: flex;
  align-items: center;
  background: #1e1e1e;
  border-radius: 6px;
  padding: 0.4rem 0.8rem;
  margin-right: 1rem;
  cursor: pointer;
  transition: background 0.3s;
}

.header-credits:hover {
  background: #2c2c2c;
}

.header-credits-icon {
  width: 24px;
  height: 24px;
  margin-right: 8px;
}

.header-credits-count {
  font-size: 1rem;
  font-weight: bold;
  color: #f0f0f0;
}

.header-credits-count.no-credits {
  color: #F44336;
}

.header-credits-count.low-credits {
  color: #FFC107;
}

.credit-progress {
  width: 36px;
  height: 4px;
  background-color: #333;
  border-radius: 2px;
  margin-left: 8px;
  overflow: hidden;
}

.credit-progress-bar {
  height: 100%;
  background-color: #00c3aa;
  border-radius: 2px;
}

.credit-progress-bar.warning {
  background-color: #FFC107;
}

.credit-progress-bar.danger {
  background-color: #F44336;
}

/* Estilos para notificaciones de créditos */
.credit-notification {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background-color: #292929;
  border-left: 4px solid #00c3aa;
  padding: 15px;
  border-radius: 4px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  z-index: 1000;
  max-width: 350px;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.3s, transform 0.3s;
}

.credit-notification.show {
  opacity: 1;
  transform: translateY(0);
}

.credit-notification.warning {
  border-left-color: #FFC107;
}

.credit-notification.error {
  border-left-color: #F44336;
}

.credit-notification.success {
  border-left-color: #4CAF50;
}

.credit-notification-icon {
  margin-right: 10px;
  font-size: 1.5rem;
}

.credit-notification-content {
  flex: 1;
  font-size: 0.9rem;
}

.credit-notification-close {
  font-size: 1.2rem;
  cursor: pointer;
  margin-left: 10px;
  color: #888;
}

.credit-notification-close:hover {
  color: #f0f0f0;
}

/* Media query para dispositivos móviles */
@media (max-width: 1024px) {
  .packages-grid {
    overflow-x: auto;
    padding: 1rem;
    justify-content: flex-start;
  }
}


@media (max-width: 768px) {
  .packages-grid {
    flex-direction: column;
    align-items: center;
  }
  
  .package-card {
    width: 100%;
    min-width: auto;
    max-width: 320px;
  }
}
.traffic-chart-container {
  height: 300px;  /* Cambiado de 250px a 300px */
  width: 500px;   /* Cambiado de 350px a 500px */
  margin-top: 320px;
  margin-right: 5px;
  position: relative;
}

/* Añadir si no existe un estilo para el canvas dentro del contenedor */
.traffic-chart-container canvas {
  position: relative;
  z-index: 5;
}
.percent-format {
  font-family: monospace;
  font-size: 1.1rem;
  text-align: center;
}
/* Estilos para el contenedor del gráfico de eventos */
.events-chart-section {
  position: absolute;
  top: 950px; /* Ajustado para mejor visibilidad */
  left: 625px;
  width: 500px;
  height: 300px;
  padding: 20px;
  background-color: rgba(255, 255, 255, 0.02); /* Fondo muy sutil */
  border-radius: 16px;
  z-index: 25; /* Mayor para asegurar visibilidad */
  display: block !important; /* Forzar visibilidad */
  visibility: visible !important;
}

/* Título más visible */
.events-chart-section h3 {
  font-family: 'Roboto', sans-serif;
  font-size: 22px;
  color: #555;
  margin-bottom: 15px;
  text-align: center;
  letter-spacing: -0.5px;
  font-weight: 500;
}

/* Contenedor del canvas más alto */
.events-chart-container {
  width: 100%;
  height: 250px; /* Más altura para las barras */
  position: relative;
  display: block !important; /* Forzar visibilidad */
}

/* Forzar visibilidad del canvas */
#top-events-chart {
  display: block !important;
  visibility: visible !important;
}
/* Añadir estos estilos al final de graphi-app.css */

/* Estilos simplificados para el gráfico de burbujas de eventos */
/* Estilos para el gráfico de burbujas de eventos - área exacta 400x400 */
/* Canvas simplificado para el gráfico de burbujas de eventos - área exacta 800x600 */
#events-bubble-chart {
  position: absolute;
  top: 500px;
  left: 500px;
  width: 700px !important;
  height: 600px !important;
  display: block !important;
  visibility: visible !important;
  outline: none !important;
  margin: 0 !important;
  padding: 0 !important;
  z-index: 25;
}

/* Ajustes para el canvas en contexto de impresión/exportación */

/* Pregunta de tiempo de permanencia (segunda página) */
.time-question {
  font-family: 'Roboto', monospace;    
  text-align: right;
  font-size: 22px;
  color: #3B3B3B;
  margin-right: 180px;
  position: absolute;
  left: 100px;
  top: 235px;
}
/* Pregunta de fuente de tráfico (segunda página) */
.traffic-question {
  font-family: 'Roboto', monospace;    
  text-align: right;
  font-size: 22px;
  color: #3B3B3B;
  margin-right: 180px;
  position: absolute;
  left: 100px;
  top: 485px;
}
/* Pregunta de páginas(segunda página) */
.pages-question {
  font-family: 'Roboto', monospace;    
  text-align: right;
  font-size: 22px;
  color: #3B3B3B;
  margin-right: 180px;
  position: absolute;
  left: 100px;
  top: 875px;
}
/* 7.6.1 Sección del segundo cuadro de texto (página 2) */
.text-box-container2 {
  position: absolute;
  left: 670px;
  top: 235px;
  z-index: 5;
}

.text-box-image2 {
  width: 434px;
  height: 140px;
  display: block;
  box-sizing: border-box;
}

.text-box-content2 {
  position: absolute;
  top: 18px;
  left: 25px;
  right: 25px;
  bottom: 18px;
  color: #333333;
  font-family: 'Roboto', sans-serif;
  letter-spacing: 1px;
  text-align: center;
  overflow: hidden;
}

.text-box-title2 {
  font-size: 25px;
  font-weight: bold;
  margin: 0 0 5px 15px;
  color: #3B3B3B;
  font-family: 'Roboto', sans-serif;
  letter-spacing: -1.2px;
  text-transform: uppercase;
  text-align: left !important;
}

.text-box-paragraph2 {
  font-size: 20px;
  font-weight: lighter;
  margin: 0;
  color: #555555;
  font-family: 'Roboto';
  letter-spacing: -1.5px;
  line-height: 0.9;
}

/* Estilos para análisis de interacción */
.engagement-list-container {
  font-family: 'Roboto', sans-serif;
  margin: 3px 0;
  padding: 2px 0;
  text-align: center;
  color: #555555;
}

/* Porcentaje principal de interacción */
#engagement-list-container_1_percent .engagement-percentage {
  font-family: 'DroidSans';  
  font-size: 50px;
  color: #3B3B3B;
  letter-spacing: -1.5px;
  font-weight: bolder;
  text-align: left;
}

/* Texto explicativo de interacción */
.engagement-unified-paragraph {
  font-family: 'Roboto';
  font-size: 20px;
  color: #555555;
  margin: 0;
  line-height: 1.1;
  text-align: left !important;
  position: relative; /* Necesario para el posicionamiento absoluto de la imagen */
  width: 100%;
}


.engagement-unified-paragraph span {
  color: inherit;
}

.engagement-unified-paragraph > div {
  padding-left: 100px !important;
  margin-left: 50px !important;
  position: relative;
}

/* Alinear a la izquierda el porcentaje principal grande */
#engagement-list-container_1_percent {
  text-align: left !important;
  padding-left: 50px;
}
/* Barra decorativa para el título del sector */
.decorative-bar4 {
  position: absolute;
  left: 100px;
  top: 1100px; /* Ajusta según necesites */
  height: 55px;
  width: 1100px;
  background-image: url('/assets/barra_titulo2.png');
  background-repeat: repeat-x;
  background-size: 60px 55px;
  z-index: 5;
}
/* Título del benchmark del sector */
.content-title4 {
  position: absolute;
  left: 100px;
  top: 1085px; /* Ajusta según necesites la separación */
  z-index: 10;
}

.content-title-text4 {
  font-family: 'Pacifico', cursive;
  font-size: 50px;
  color: #656565; /* Gris para "Benchmark del Sector" */
    display: flex;
  align-items: center;
  z-index: 10;
}

.orange-text {
  color: #FE932E; /* Naranja para el nombre del sector */
}
/* Estilos CSS adicionales para el gauge de benchmark */
/* Añadir estos estilos al final de graphi-app.css */

/* Sección del gauge de benchmark de sector */
#benchmark-gauge-section {
  position: absolute;
  top: 1200px;
  left: 50px;
  width: 400px;
  height: 200px;
  z-index: 30;
  background: transparent;
  padding: 10px;
  border-radius: 8px;
}

#benchmark-gauge-section h3 {
  font-family: 'Roboto', sans-serif;
  font-size: 18px;
  color: #555;
  margin-bottom: 10px;
  text-align: center;
  font-weight: 500;
  letter-spacing: -0.5px;
}

/* Contenedor del canvas del gauge */
.benchmark-gauge-container {
  width: 300px;
  height: 150px;
  margin: 0 auto 15px;
  position: relative;
}

#benchmark-gauge-chart {
  display: block !important;
  visibility: visible !important;
  background: transparent;
}

/* Texto de comparación con estilo similar al de devices */
#benchmark-comparison-text {
  font-family: 'Roboto', sans-serif;
  font-size: 20px;
  color: #555555;
  line-height: 0.8;
  text-align: left;
  margin: 0 47px;
  letter-spacing: -1.5px;
  font-weight: lighter;
  display: block;
  max-width: 380px;
  margin-left: auto;
  margin-right: auto;
}

/* Estilos para impresión/exportación */

#engagement-list-container_1_percent {
  text-align: left !important;
  padding-left: 150px !important; /* Aumentado para hacer espacio para la imagen + 100px adicionales */
}
/* Añade estos estilos al final de graphi-app.css */

/* Estilos para la sección de páginas principales */
#top-pages-section {
  background-color: rgba(255, 255, 255, 0.02);
  border-radius: 10px;
  padding: 15px;
  box-sizing: border-box;
  height: 200px; /* Ajustado */

}

#top-pages-chart-container {
  width: 100%;
  height: 150px; /* Ajustado */
  position: relative;
}

#top-pages-chart {
  display: block !important;
  visibility: visible !important;
}
/* =========================================
   REDES SOCIALES MINIMALISTAS
   ========================================= */

/* Sección de redes sociales */
.social-section {
  margin-bottom: 1.5rem;
}

.social-label {
  color: #999;
  font-size: 0.9rem;
  margin-bottom: 0.8rem;
  font-weight: 500;
}

.social-links {
  display: flex;
  justify-content: center;
  gap: 1.2rem;
  margin-bottom: 1.5rem;
}

/* Solo iconos blancos minimalistas */
.social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: transparent;
  border: none;
  border-radius: 50%;
  color: #ffffff;
  text-decoration: none;
  transition: all 0.3s ease;
  padding: 0;
  min-width: auto;
}

.social-link:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(255, 255, 255, 0.1);
}

.social-link:active {
  transform: translateY(0);
}

.social-icon {
  width: 24px;
  height: 24px;
  fill: currentColor;
  flex-shrink: 0;
}

/* Responsive */
@media (max-width: 768px) {
  .social-links {
    gap: 1rem;
  }
  
  .social-link {
    width: 36px;
    height: 36px;
  }
  
  .social-icon {
    width: 20px;
    height: 20px;
  }
}

@media (max-width: 480px) {
  .social-label {
    font-size: 0.8rem;
  }
  
  .social-icon {
    width: 18px;
    height: 18px;
  }
}