/* Indicadores de Calidad - CSS Optimizado para Máximo Rendimiento */

/* Variables CSS para consistencia y performance */
:root {
     --primary-orange: #ff9505;
     --primary-blue: #0d6efd;
     --primary-success: #198754;
     --primary-warning: #ffc107;
     --primary-info: #0dcaf0;
     --bg-light: rgba(248, 249, 250, 0.8);
     --border-radius: 8px;
     --transition-base: 0.3s ease;
     --shadow-sm: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
     --transform-hover: translate3d(0, -3px, 0);
     --transform-scale: scale(1.01);
}

/* Performance optimizations - contenido crítico */
* {
     box-sizing: border-box;
}

/* Optimización de fuentes y rendering */
body {
     -webkit-font-smoothing: antialiased;
     -moz-osx-font-smoothing: grayscale;
     text-rendering: optimizeSpeed;
}

/* Optimización de imágenes */
img {
     image-rendering: optimizeQuality;
     image-rendering: -webkit-optimize-contrast;
}

/* Utilidades de texto optimizadas */
.text-justify {
     text-align: justify;
     text-justify: inter-word;
     hyphens: auto;
}

.text-orange {
     color: var(--primary-orange) !important;
}

/* Optimización para métricas mensuales con GPU acceleration */
.metric-row {
     transition: background-color var(--transition-base), transform var(--transition-base);
     will-change: transform, background-color;
     transform: translateZ(0);
     /* Force hardware acceleration */
}

.metric-row:hover {
     background-color: rgba(255, 149, 5, 0.1) !important;
     transform: var(--transform-scale);
}

/* Badges optimizados */
.table .badge {
     font-size: 0.85rem;
     padding: 0.5rem 0.75rem;
     transition: transform var(--transition-base);
     will-change: transform;
     transform: translateZ(0);
}

.table .badge:hover {
     transform: scale(1.05);
}

/* Tabla Responsiva para Móviles */
@media (max-width: 768px) {
     .table-responsive {
          border: none;
          overflow: visible;
     }

     .responsive-table {
          display: none;
     }

     .mobile-metrics {
          display: block;
     }

     .mobile-metric-card {
          background: white;
          border-radius: var(--border-radius);
          box-shadow: var(--shadow-sm);
          margin-bottom: 1rem;
          padding: 1rem;
          border-left: 4px solid var(--primary-orange);
          transition: transform var(--transition-base), box-shadow var(--transition-base);
          animation: fadeInUp 0.6s ease forwards;
          opacity: 0;
          transform: translateY(20px);
     }

     .mobile-metric-card:hover {
          transform: translateY(-2px);
          box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
     }

     .mobile-metric-header {
          display: flex;
          justify-content: space-between;
          align-items: center;
          margin-bottom: 0.75rem;
          padding-bottom: 0.5rem;
          border-bottom: 1px solid #eee;
     }

     .mobile-metric-month {
          font-weight: 600;
          color: var(--primary-orange);
          font-size: 1.1rem;
     }

     .mobile-metric-status {
          padding: 0.25rem 0.75rem;
          border-radius: 20px;
          font-size: 0.85rem;
          font-weight: 500;
     }

     .mobile-metric-details {
          display: grid;
          grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
          gap: 0.75rem;
     }

     .mobile-metric-item {
          text-align: center;
          padding: 0.5rem;
          background: rgba(248, 249, 250, 0.5);
          border-radius: 6px;
          transition: background-color var(--transition-base);
     }

     .mobile-metric-item:hover {
          background: rgba(255, 149, 5, 0.1);
     }

     .mobile-metric-label {
          font-size: 0.85rem;
          color: #6c757d;
          margin-bottom: 0.25rem;
          font-weight: 500;
     }

     .mobile-metric-value {
          font-size: 1.25rem;
          font-weight: 600;
          color: #333;
     }

     .mobile-metric-value.success {
          color: var(--primary-success);
     }

     .mobile-metric-value.warning {
          color: var(--primary-warning);
     }

     .mobile-metric-value.primary {
          color: var(--primary-blue);
     }
}

@media (min-width: 769px) {
     .mobile-metrics {
          display: none;
     }

     .responsive-table {
          display: table;
     }
}

/* Optimización para tablets */
@media (max-width: 992px) and (min-width: 769px) {
     .table {
          font-size: 0.9rem;
     }

     .table th,
     .table td {
          padding: 0.6rem 0.5rem;
     }

     .badge {
          font-size: 0.75rem;
          padding: 0.35rem 0.6rem;
     }
}

/* Mejoras para pantallas muy pequeñas */
@media (max-width: 576px) {
     .mobile-metric-details {
          grid-template-columns: 1fr;
          gap: 0.5rem;
     }

     .mobile-metric-item {
          padding: 0.75rem;
     }

     .mobile-metric-value {
          font-size: 1.5rem;
     }

     .mobile-metric-card {
          margin-bottom: 0.75rem;
          padding: 0.75rem;
     }
}

/* Animaciones con GPU acceleration */
@keyframes fadeInUp {
     0% {
          opacity: 0;
          transform: translate3d(0, 20px, 0);
     }

     100% {
          opacity: 1;
          transform: translate3d(0, 0, 0);
     }
}

.metric-row {
     animation: fadeInUp 0.6s ease forwards;
}

.mobile-metric-card {
     animation: fadeInUp 0.6s ease forwards;
}

/* Hero Section optimizado para mejor performance */
.hero-indicadores {
     position: relative;
     min-height: 100vh;
     background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f1419 100%);
     overflow: hidden;
     display: flex;
     align-items: center;
     will-change: auto;
     contain: layout style paint;
}

.hero-background {
     position: absolute;
     top: 0;
     left: 0;
     width: 100%;
     height: 100%;
     z-index: 1;
}

/* Animaciones optimizadas con contenment y GPU acceleration */
.hero-waves {
     position: absolute;
     width: 100%;
     height: 100%;
     overflow: hidden;
     contain: layout style paint;
}

.wave {
     position: absolute;
     width: 200%;
     height: 200%;
     background: radial-gradient(circle, rgba(242, 92, 5, 0.1) 1px, transparent 1px);
     animation: waveMove 20s linear infinite;
     will-change: transform;
     transform: translateZ(0);
}

.wave-1 {
     background-size: 30px 30px;
     animation-delay: 0s;
}

.wave-2 {
     background-size: 40px 40px;
     animation-delay: -7s;
}

.wave-3 {
     background-size: 60px 60px;
     animation-delay: -14s;
}

@keyframes waveMove {
     0% {
          transform: translate3d(-50%, -50%, 0) rotate(0deg);
     }

     100% {
          transform: translate3d(-50%, -50%, 0) rotate(360deg);
     }
}

/* Grid optimizado con containment */
.hero-grid {
     position: absolute;
     width: 100%;
     height: 100%;
     opacity: 0.1;
     contain: layout style;
}

.grid-line {
     position: absolute;
     background: linear-gradient(90deg, transparent, var(--primary-orange), transparent);
     height: 1px;
     width: 100%;
     animation: gridPulse 4s ease-in-out infinite;
     will-change: opacity, transform;
}

.grid-line:nth-child(1) {
     top: 20%;
}

.grid-line:nth-child(2) {
     top: 40%;
     animation-delay: 0.8s;
}

.grid-line:nth-child(3) {
     top: 60%;
     animation-delay: 1.6s;
}

.grid-line:nth-child(4) {
     top: 80%;
     animation-delay: 2.4s;
}

@keyframes gridPulse {

     0%,
     100% {
          opacity: 0.1;
          transform: scaleX(0.5);
     }

     50% {
          opacity: 0.8;
          transform: scaleX(1);
     }
}

/* Layout optimizado */
.container {
     position: relative;
     z-index: 2;
}

.hero-content {
     color: white;
     padding: 2rem 0;
}

/* Componentes optimizados */
.hero-badge {
     display: inline-flex;
     align-items: center;
     background: rgba(242, 92, 5, 0.2);
     border: 1px solid rgba(242, 92, 5, 0.5);
     padding: 0.5rem 1rem;
     border-radius: 50px;
     font-size: 0.875rem;
     font-weight: 500;
     margin-bottom: 1.5rem;
     backdrop-filter: blur(10px);
}

/* Responsive typography con clamp para mejor performance */
.hero-title {
     font-size: clamp(2.5rem, 5vw, 3.5rem);
     font-weight: 800;
     line-height: 1.1;
     margin-bottom: 1rem;
}

.title-highlight {
     color: var(--primary-orange);
     display: block;
}

.title-main {
     color: white;
     display: block;
}

.hero-subtitle {
     font-size: clamp(1.25rem, 3vw, 1.5rem);
     font-weight: 300;
     margin-bottom: 1.5rem;
     color: rgba(255, 255, 255, 0.9);
}

.hero-description {
     font-size: 1.125rem;
     line-height: 1.6;
     margin-bottom: 2rem;
     color: rgba(255, 255, 255, 0.8);
}

/* Métricas optimizadas */
.hero-metrics {
     display: flex;
     gap: 2rem;
     margin-bottom: 2.5rem;
     flex-wrap: wrap;
}

.metric-item {
     text-align: center;
     color: white;
}

.metric-value {
     font-size: clamp(2rem, 4vw, 2.5rem);
     font-weight: 800;
     color: var(--primary-orange);
     line-height: 1;
}

.metric-label {
     font-size: 0.875rem;
     color: rgba(255, 255, 255, 0.8);
     margin-top: 0.5rem;
}

/* Botones optimizados con GPU acceleration */
.hero-buttons {
     display: flex;
     gap: 1rem;
     flex-wrap: wrap;
}

.btn-hero-primary {
     background: linear-gradient(45deg, var(--primary-orange), #ff7b29);
     border: none;
     color: white;
     padding: 1rem 2rem;
     border-radius: 50px;
     font-weight: 600;
     text-decoration: none;
     transition: transform var(--transition-base), box-shadow var(--transition-base);
     box-shadow: var(--shadow-sm);
     will-change: transform, box-shadow;
     transform: translateZ(0);
}

.btn-hero-primary:hover {
     transform: translateY(-2px);
     box-shadow: 0 6px 20px rgba(242, 92, 5, 0.4);
     color: white;
}

.btn-hero-secondary {
     background: rgba(255, 255, 255, 0.1);
     border: 2px solid rgba(255, 255, 255, 0.3);
     color: white;
     padding: 1rem 2rem;
     border-radius: 50px;
     font-weight: 600;
     text-decoration: none;
     transition: background-color var(--transition-base);
     backdrop-filter: blur(10px);
     will-change: background-color;
     transform: translateZ(0);
}

.btn-hero-secondary:hover {
     background: rgba(255, 255, 255, 0.2);
     color: white;
}

/* Cards optimizadas con containment */
.indicator-card,
.card {
     contain: layout style;
     will-change: transform, box-shadow;
     transform: translateZ(0);
}

/* Optimización de footer */
.footer-logo {
     max-width: 100px;
     height: auto;
}

/* Optimizaciones adicionales para performance */
@media (prefers-reduced-motion: reduce) {

     *,
     *::before,
     *::after {
          animation-duration: 0.01ms !important;
          animation-iteration-count: 1 !important;
          transition-duration: 0.01ms !important;
     }
}

/* Optimización de scroll performance */
* {
     scroll-behavior: smooth;
}

/* Critical CSS inline optimization hint */
.hero-indicadores,
.hero-content,
.hero-title {
     font-display: swap;
}

.grid-line:nth-child(3) {
     top: 60%;
     animation-delay: 1.6s;
}

.grid-line:nth-child(4) {
     top: 80%;
     animation-delay: 2.4s;
}

@keyframes gridPulse {

     0%,
     100% {
          opacity: 0.1;
          transform: scaleX(0.5);
     }

     50% {
          opacity: 0.8;
          transform: scaleX(1);
     }
}

/* Layout optimizado */
.container {
     position: relative;
     z-index: 2;
}

.hero-content {
     color: white;
     padding: 2rem 0;
}

/* Componentes optimizados */
.hero-badge {
     display: inline-flex;
     align-items: center;
     background: rgba(242, 92, 5, 0.2);
     border: 1px solid rgba(242, 92, 5, 0.5);
     padding: 0.5rem 1rem;
     border-radius: 50px;
     font-size: 0.875rem;
     font-weight: 500;
     margin-bottom: 1.5rem;
     backdrop-filter: blur(10px);
}

.hero-title {
     font-size: clamp(2.5rem, 5vw, 3.5rem);
     font-weight: 800;
     line-height: 1.1;
     margin-bottom: 1rem;
}

.title-highlight {
     color: var(--primary-orange);
     display: block;
}

.title-main {
     color: white;
     display: block;
}

.hero-subtitle {
     font-size: clamp(1.25rem, 3vw, 1.5rem);
     font-weight: 300;
     margin-bottom: 1.5rem;
     color: rgba(255, 255, 255, 0.9);
}

.hero-description {
     font-size: 1.125rem;
     line-height: 1.6;
     margin-bottom: 2rem;
     color: rgba(255, 255, 255, 0.8);
}

/* Métricas optimizadas */
.hero-metrics {
     display: flex;
     gap: 2rem;
     margin-bottom: 2.5rem;
     flex-wrap: wrap;
}

.metric-item {
     text-align: center;
     color: white;
}

.metric-value {
     font-size: clamp(2rem, 4vw, 2.5rem);
     font-weight: 800;
     color: var(--primary-orange);
     line-height: 1;
}

.metric-label {
     font-size: 0.875rem;
     color: rgba(255, 255, 255, 0.8);
     margin-top: 0.5rem;
}

/* Botones optimizados */
.hero-buttons {
     display: flex;
     gap: 1rem;
     flex-wrap: wrap;
}

.btn-hero-primary {
     background: linear-gradient(45deg, var(--primary-orange), #ff7b29);
     border: none;
     color: white;
     padding: 1rem 2rem;
     border-radius: 50px;
     font-weight: 600;
     text-decoration: none;
     transition: transform var(--transition-base), box-shadow var(--transition-base);
     box-shadow: var(--shadow-sm);
     will-change: transform, box-shadow;
}

.btn-hero-primary:hover {
     transform: translateY(-2px);
     box-shadow: 0 6px 20px rgba(242, 92, 5, 0.4);
     color: white;
}

.btn-hero-secondary {
     background: rgba(255, 255, 255, 0.1);
     border: 2px solid rgba(255, 255, 255, 0.3);
     color: white;
     padding: 1rem 2rem;
     border-radius: 50px;
     font-weight: 600;
     text-decoration: none;
     transition: background-color var(--transition-base);
     backdrop-filter: blur(10px);
     will-change: background-color;
}

.btn-hero-secondary:hover {
     background: rgba(255, 255, 255, 0.2);
     border-color: rgba(255, 255, 255, 0.5);
     color: white;
     transform: translateY(-2px);
}

.hero-visual {
     display: flex;
     justify-content: center;
     align-items: center;
     height: 100%;
}

.dashboard-container {
     position: relative;
     width: 100%;
     max-width: 500px;
}

.dashboard-card {
     background: rgba(255, 255, 255, 0.1);
     backdrop-filter: blur(20px);
     border: 1px solid rgba(255, 255, 255, 0.2);
     border-radius: 20px;
     padding: 2rem;
     animation: dashboardFloat 6s ease-in-out infinite;
}

.dashboard-header {
     display: flex;
     justify-content: space-between;
     align-items: center;
     margin-bottom: 1.5rem;
     padding-bottom: 1rem;
     border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.dashboard-header h4 {
     color: white;
     margin: 0;
     font-weight: 700;
}

.status-indicator {
     width: 12px;
     height: 12px;
     border-radius: 50%;
     animation: pulse 2s infinite;
}

.status-indicator.online {
     background: #28a745;
     box-shadow: 0 0 10px #28a745;
}

.metrics-grid {
     display: grid;
     grid-template-columns: 1fr 1fr;
     gap: 1rem;
     margin-bottom: 1.5rem;
}

.metric-box {
     background: rgba(255, 255, 255, 0.05);
     border-radius: 12px;
     padding: 1rem;
     text-align: center;
     transition: all 0.3s ease;
}

.metric-box:hover {
     background: rgba(255, 255, 255, 0.1);
     transform: translateY(-2px);
}

.metric-icon i {
     color: #f25c05;
     font-size: 1.5rem;
     margin-bottom: 0.5rem;
}

.metric-number {
     display: block;
     color: white;
     font-size: 1.25rem;
     font-weight: 700;
}

.metric-text {
     color: rgba(255, 255, 255, 0.7);
     font-size: 0.75rem;
}

.chart-visualization {
     margin-top: 1rem;
}

.chart-bars {
     display: flex;
     align-items: end;
     gap: 0.5rem;
     height: 60px;
     justify-content: center;
}

.bar {
     background: linear-gradient(180deg, #f25c05, #ff7b29);
     border-radius: 2px 2px 0 0;
     width: 8px;
     animation: barGrow 3s ease-in-out infinite;
}

.bar-1 {
     height: 40%;
     animation-delay: 0s;
}

.bar-2 {
     height: 70%;
     animation-delay: 0.2s;
}

.bar-3 {
     height: 85%;
     animation-delay: 0.4s;
}

.bar-4 {
     height: 60%;
     animation-delay: 0.6s;
}

.bar-5 {
     height: 90%;
     animation-delay: 0.8s;
}

.bar-6 {
     height: 75%;
     animation-delay: 1s;
}

.bar-7 {
     height: 80%;
     animation-delay: 1.2s;
}

@keyframes barGrow {

     0%,
     100% {
          transform: scaleY(0.8);
     }

     50% {
          transform: scaleY(1.1);
     }
}

.floating-stats {
     position: absolute;
     width: 100%;
     height: 100%;
     pointer-events: none;
}

.stat-bubble {
     position: absolute;
     background: rgba(242, 92, 5, 0.2);
     border: 1px solid rgba(242, 92, 5, 0.5);
     border-radius: 50px;
     padding: 0.5rem 1rem;
     color: white;
     font-size: 0.75rem;
     font-weight: 600;
     backdrop-filter: blur(10px);
     display: flex;
     align-items: center;
     gap: 0.5rem;
}

.stat-bubble i {
     color: #f25c05;
}

.stat-1 {
     top: -20px;
     left: 20px;
     animation: bubbleFloat1 4s ease-in-out infinite;
}

.stat-2 {
     top: 50%;
     right: -30px;
     animation: bubbleFloat2 5s ease-in-out infinite;
}

.stat-3 {
     bottom: -20px;
     left: 50%;
     transform: translateX(-50%);
     animation: bubbleFloat3 4.5s ease-in-out infinite;
}

@keyframes dashboardFloat {

     0%,
     100% {
          transform: translateY(0px);
     }

     50% {
          transform: translateY(-10px);
     }
}

@keyframes bubbleFloat1 {

     0%,
     100% {
          transform: translateY(0px);
     }

     50% {
          transform: translateY(-5px);
     }
}

@keyframes bubbleFloat2 {

     0%,
     100% {
          transform: translateY(0px);
     }

     50% {
          transform: translateY(8px);
     }
}

@keyframes bubbleFloat3 {

     0%,
     100% {
          transform: translateX(-50%) translateY(0px);
     }

     50% {
          transform: translateX(-50%) translateY(-7px);
     }
}

@keyframes pulse {
     0% {
          transform: scale(0.95);
          box-shadow: 0 0 0 0 rgba(40, 167, 69, 0.7);
     }

     70% {
          transform: scale(1);
          box-shadow: 0 0 0 10px rgba(40, 167, 69, 0);
     }

     100% {
          transform: scale(0.95);
          box-shadow: 0 0 0 0 rgba(40, 167, 69, 0);
     }
}

/* Responsive */
@media (max-width: 768px) {
     .hero-title {
          font-size: 2.5rem;
     }

     .hero-metrics {
          gap: 1rem;
          justify-content: center;
     }

     .metric-value {
          font-size: 2rem;
     }

     .dashboard-container {
          max-width: 350px;
     }

     .dashboard-card {
          padding: 1.5rem;
     }

     .metrics-grid {
          grid-template-columns: 1fr;
          gap: 0.5rem;
     }

     .stat-bubble {
          font-size: 0.6rem;
          padding: 0.25rem 0.75rem;
     }

     .stat-2 {
          right: -50px;
     }
}

/* Indicadores de contenido */
.indicator-card {
     transition: all 0.3s ease;
}

.indicator-card:hover {
     transform: translateY(-5px);
     box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.text-orange {
     color: #ff9505 !important;
}