@import url("./fontt/css/all.css");

@font-face {
  font-family: "noodle";
  src: url("../fonts/UbuntuCondensed-Regular.ttf") format("truetype");
}

:root {
  --color-1: #e6324b;
  --color-2: #2ecc71;
  --color-fondo: #ffffff;
  --texto-color: #333333;
}

body {
  background-color: rgba(16, 41, 48, 0.9);
  background-attachment: fixed;
  background-size: cover;
  font-family: "noodle", sans-serif;
  max-width: 1200px;
  width: 100%;
  margin: 5px auto;
}

section {
  display: grid;
  grid-template-areas: 
    "head head"
    "main main"
    "nav nav";
  grid-gap: 5px;
  width: 100%;
}

@media screen and (max-width: 1200px) {
  body {
    margin: 0 auto;
  }
}

/* NAV */
nav {
  grid-area: nav;
  margin: 50px auto auto auto; /* Superior de 50px, laterales automáticos */
}

/* FOOTER */
footer {
  grid-area: foot; /* Nota de QA: Recuerda agregar "foot foot" a la propiedad grid-template-areas de tu <section> */
}

/* BOTÓN FLOTANTE INTERACTIVO */
.plus {
  background-color: #1ab188;
  border-radius: 50%;
  bottom: 10%;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 25px;
  height: 50px;
  position: fixed;
  right: 10%;
  text-align: center;
  text-decoration: none;
  width: 50px;
  z-index: 99;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3); /* Sombra para resaltar en la interfaz */
  transition: background-color 0.3s ease, color 0.3s ease, transform 0.2s ease;
}

.plus:hover {
  background-color: #ffffff;
  color: #1ab188;
  transform: scale(1.05); /* Efecto sutil de agrandado al pasar el cursor */
}

/* CONTAINER PRINCIPAL DE SESIÓN */
.session {
  border: 2px solid #34B7F1;
  border-radius: 10px;
  display: inline-block;
  margin: 0 auto 2px auto;
  padding: 10px;
  text-align: left;
  width: calc(50% - 25px);
  box-sizing: border-box; /* QA Note: Garantiza que el padding no altere el tamaño calculado */
}

/* RESPONSIVIDAD MÓVIL */
@media screen and (max-width: 500px) {
  .session {
    border-radius: 0;
    margin: 10px 5px 0 5px;
    width: calc(100% - 10px);
  }
}

/* TIPOGRAFÍAS INTERNAS */
.session h2 {
  color: #ffffff;
  font-size: 1.5em;
}

.session h3 {
  color: #ff5252;
  font-size: 1em;
}

.session span {
  color: #ff5252;
  display: block;
}

.session .time {
  margin-left: auto; /* Reemplazo de float por alineación limpia */
}

.session img {
  display: block; /* Permite que el margen automático funcione */
  height: 75px;
  margin: 10px auto;
  width: 75px;
}

/* SUB-CONTENEDORES */
.session .main1 {
  display: flex;
  margin: 0;
  padding: 0;
  width: calc(100% - 50px);
}

.session .pro {
  height: 150px;
  width: 150px;
}

.session .pro img {
  height: 150px;
  margin: 0;
  object-fit: contain;
  padding: 0;
  width: 100%; /* Corregido calc() innecesario */
}

.session .main {
  margin: 5px 15px;
  width: calc(100% - 130px);
}

.session .main pre {
  color: #ffffff;
  font-family: "noodle", sans-serif;
}

/* FORMULARIOS Y ENTRADAS DE DATOS Y CORRECCIÓN DE ÁMBITO GLOBAL */
.session form {
  color: #ffffff;
  margin: 0;
}

.session form input,
.session form input[type="date"],
.session form textarea,
.session form select {
  background: transparent;
  border: 2px solid #34B7F1;
  color: inherit;
  font-family: "noodle", sans-serif;
  font-size: 1em;
  margin: 2px auto;
  padding: 5px;
  text-decoration: none;
  width: 100%;
  box-sizing: border-box;
}

/* CONTROL DEL FOCO (COMPATIBILIDAD PLANA Y LIMPIA) */
.session form input:focus,
.session form input[type="date"]:focus,
.session form textarea:focus,
.session form select:focus {
  outline: none;
  color: #34B7F1;
}

/* ESTILOS DE PLACEHOLDERS */
.session form input::placeholder,
.session form input[type="date"]::placeholder,
.session form textarea::placeholder {
  color: #34B7F1;
}

/* SELECTOR DE ARCHIVOS PERSONALIZADO */
.session input[type="file"]::file-selector-button {
  background-color: #ff5252;
  border: 2px solid #ff5252;
  border-radius: 5px 0 0 5px;
  color: #ffffff;
  font-family: "noodle", sans-serif;
  margin: -5px 5px -5px -5px;
  padding: 0.2em 0.4em;
  transition: background-color 0.3s ease, border-color 0.3s ease; /* Optimización del tiempo de animación */
}

/* CONTENEDOR DE LA IMAGEN (BLOQUE LIMPIO) */
.bimg img {
  display: block;
  height: 300px;
  object-fit: cover;
  width: 300px;
}

/* CONTENEDOR RELATIVO PARA EL BOTÓN SUPERPUESTO */
.bimg .brr {
  display: inline-block;
  position: relative;
}

/* BOTÓN FLOTANTE (POSICIONAMIENTO ELÁSTICO SEGURO) */
.bimg .brr a {
  background-color: rgba(26, 177, 136, 0.85); /* Fondo inicial con ligera transparencia */
  border-radius: 50%;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 25px;
  height: 50px;
  position: absolute;
  top: 15px; /* Margen fijo y limpio desde la esquina superior */
  right: 15px; /* Margen fijo y limpio desde la esquina derecha */
  text-decoration: none;
  width: 50px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25); /* Sombra para dar relieve */
  transition: background-color 0.3s ease, color 0.3s ease, transform 0.2s ease;
}

/* EFECTO HOVER SUAVE */
.bimg .brr a:hover {
  background-color: #ffffff;
  color: #1ab188;
  transform: scale(1.08); /* Pequeño pulso interactivo */
}

/* CONTENEDOR DE BOTONES */
.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  width: 100%;
}

/* ESTILOS UNIFICADOS (COMPARTIDOS PARA BUTTON Y A) */
.btn button,
.btn a {
  background-color: #34B7F1;
  border: none;
  border-radius: 50px;
  color: #ffffff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-around;
  font-family: "noodle", sans-serif;
  font-size: 1em;
  font-weight: 300;
  height: 30px;
  margin: 10px 1px;
  text-decoration: none; /* Asegura quitar el subrayado en los enlaces <a> */
  text-shadow: none;
  width: calc(50% - 10px);
  box-sizing: border-box;
  transition: background-color 0.25s ease, color 0.25s ease; /* Transición ágil y moderna */
}

/* EFECTO HOVER UNIFICADO */
.btn button:hover,
.btn a:hover {
  background-color: #ffffff;
  color: #34B7F1;
}

/* CONTENEDOR PRINCIPAL DE LA APLICACIÓN */
main {
  grid-area: main;
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  flex-wrap: wrap;
  margin-top: 60px;
}

/* ENLACES INTERNOS */
main a {
  text-decoration: none;
}

/* TARJETAS DE OPCIONES / ICONOS DEL MENÚ */
main figure {
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin: 25px;
  min-height: 100px; /* QA Note: Usamos altura mínima para evitar desbordamientos si el texto es largo */
  width: 110px;      /* Ancho sutilmente ampliado para dar espacio al texto */
  transition: transform 0.2s ease;
}

/* EFECTO DE SELECCIÓN VISUAL */
main figure:hover {
  transform: translateY(-3px); /* Pequeña elevación interactiva al pasar el cursor */
}

/* ICONOS INTERNOS */
main figure img {
  height: 75px;
  object-fit: contain; /* Evita que las imágenes se deformen */
  width: 75px;
}

/* ETIQUETAS DE TEXTO / TÍTULOS DE ICONO */
main figure figcaption {
  background-color: #ff5252;
  border-radius: 5px;
  color: #ffffff;
  font-size: 0.9em;
  margin-top: 8px; /* Separación limpia entre el icono y el texto */
  padding: 5px;
  text-align: center;
  width: 100%;
  box-sizing: border-box;
}

/* CONTENEDOR PRINCIPAL DE INFORMACIÓN */
.info {
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  box-sizing: border-box; /* QA Note: Garantiza que el padding no desborde el 100% de ancho */
  display: flex;
  flex-flow: row wrap;
  align-items: center;
  margin: 5px auto;
  padding: 15px;
  text-shadow: 0 0 2px #000000;
  width: 100%;
}

/* CONTENEDOR DE IMAGEN / AVATAR */
.info .aside-1 {
  flex: 1 1 auto; /* Sintaxis corregida usando auto como base flexible */
}

.info .aside-1 .imgv {
  border-radius: 50%;
  display: block; /* Habilita el correcto funcionamiento del margin auto */
  height: 75px;
  margin: auto;
  object-fit: cover;
  width: 75px;
}

/* CONTENEDOR DE TEXTOS PRINCIPALES */
.info .aside {
  flex: 0 1 calc(100% - 200px); /* El cálculo de ancho se integra nativamente en el flex-basis */
  margin: 5px;
}

/* ENCABEZADOS CONTROLADOS (SIN FUGAS GLOBALES) */
.info h1, 
.info h2, 
.info h3 {
  color: #ffffff;
  margin: 2px;
  text-align: left;
}

.info h1 {
  font-size: 18px;
}

.info h2 {
  font-size: 15px;
}

.info h3 {
  font-size: 12px;
}

/* PIE DEL BLOQUE INFO */
.info .foot {
  display: flex;
  flex: 0 0 100%; /* Ajuste a tamaño completo de base flexible */
  box-sizing: border-box;
  margin: 5px 0;
  padding: 5px;
  width: 100%;
}

.info .foot span {
  color: #ffffff;
  font-size: 12px;
  width: 100%;
}

/* CONTENEDOR HEADER PRINCIPAL */
header {
  grid-area: head;
  background-color: #34B7F1;
  border-radius: 5px;
  color: #ffffff;
  display: flex;
  align-items: center; /* Centrado vertical limpio de hijos usando Flexbox */
  height: 50px;
  left: 0;
  right: 0;
  margin: 5px auto;
  max-width: 1200px; /* Limita el ancho al máximo de tu layout sin romper móviles */
  position: fixed;
  width: 100%;
  z-index: 999;
  box-sizing: border-box;
}

/* LOGOTIPO Y TÍTULO */
header .logo {
  display: flex;
  align-items: center;
  flex: 1 1 auto;
  height: 50px;
  margin: 0 15px;
  width: 50px;
}

header .logo img {
  height: auto;
  width: 50px;
}

header .logo h1 {
  color: #ffffff;
  display: inline-block;
  font-size: 1.5em;
  line-height: 1.2;
}

/* FORMULARIO DE BÚSQUEDA INTERNO */
header form {
  background-color: #ffffff;
  border-radius: 40px;
  display: flex;
  align-items: center;
  flex: 1 1 auto;
  height: 40px;
  margin: 5px;
  width: calc(50% - 200px);
}

/* CONTROLES DEL FORMULARIO UNIFICADOS */
header form input, 
header form select, 
header form button, 
header form input[type="date"] {
  border: none;
  background: transparent;
  color: #ff5252;
  display: inline-block;
  flex: 1 1 auto;
  font-family: "noodle", sans-serif;
  font-size: 18px; /* Ajuste sutil de tamaño para ergonomía visual */
  margin: 2px;
  outline: none;
  padding: 0 10px;
}

/* INPUTS Y SELECTS ESPECÍFICOS */
header form input, 
header form datalist {
  width: 40%;
}

header form input[type="date"] {
  width: 40%;
}

/* CORRECCIÓN DE TYPO Y AISLAMIENTO DE FUGA GLOBAL */
header form input[type="date"]::-webkit-inner-spin-button,
header form input[type="date"]::-webkit-calendar-picker-indicator {
  filter: drop-shadow(16px 16px 20px rgb(255, 255, 255)) invert(100%);
}

header form input::placeholder {
  color: #ff5252;
}

header form select {
  background: none;
  border-right: 2px solid #ff5252;
  border-radius: 40px 0 0 40px;
  padding: 0 10px;
  width: 20%;
}

header form select option {
  background-color: rgba(16, 41, 48, 0.9);
  color: #ffffff;
}

/* BOTÓN DE ENVÍO */
header form button {
  background-color: #ff5252;
  border-radius: 40px;
  color: #ffffff;
  cursor: pointer;
  width: 40px;
  padding: 10px;
  transition: background-color 0.25s ease, color 0.25s ease;
}

header form button:hover {
  background-color: #ffffff;
  color: #ff5252;
}

header .short {
  width: 30px;
}

/* ICONOS DE CONFIGURACIÓN/NAVEGACIÓN */
.icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1 1 auto;
  height: 40px;
  margin: 5px;
}

.icon a {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1 1 auto;
  color: #ffffff;
  cursor: pointer;
  border-radius: 10px;
  font-size: 25px;
  height: 40px;
  text-decoration: none;
  transition: background-color 0.25s ease, color 0.25s ease;
}

.icon a label {
  height: 20px;
}

.icon a:hover {
  background-color: #ffffff;
  color: #34B7F1;
}

/* BLOQUE DE ICONOS / BOTONES SECUNDARIOS (ICON2) */
.icon2 {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  width: 100%;
}

/* UNIFICACIÓN DE PROPIEDADES COMPARTIDAS (BUTTON Y A) */
.icon2 button,
.icon2 a {
  background: none;
  border: none;
  border-radius: 50px;
  color: rgba(0, 0, 0, 0.6);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-around;
  font-family: "noodle", sans-serif;
  font-size: 1em;
  font-weight: 300;
  height: 30px;
  margin: 10px 1px;
  text-align: center;
  text-decoration: none;
  text-shadow: none;
  width: calc(50% - 10px);
  box-sizing: border-box;
  transition: background-color 0.25s ease, color 0.25s ease;
}

/* HOVER ESTANDARIZADO Y COHERENTE PARA AMBOS ELEMENTOS */
.icon2 button:hover,
.icon2 a:hover {
  background-color: rgba(255, 82, 82, 0.1); /* Sutil fondo rojo transparente en lugar de blanco o vacío */
  color: #ff5252;
}

/* LÍNEAS DE ENFASIS */
.line {
  background-color: #ffffff;
  color: #34B7F1;
}

.line i, 
.line span {
  color: #34B7F1;
}

/* MENÚ DESPLEGABLE / CONTENEDOR "VER" */
.ver {
  background-color: #ff5252;
  border-radius: 10px;
  display: none; /* Por defecto oculto. QA Note: Usa una clase como .is-active con display:flex para mostrarlo vía JS */
  align-items: center;
  justify-content: center;
  height: auto;
  position: absolute;
  right: 0;
  top: 50px;
  width: 500px;
  z-index: 100;
}

/* LISTAS DESPLEGABLES */
.ver ul {
  list-style-type: none;
  padding: 0 10px;
  width: 100%;
}

.ver ul li {
  border-bottom: 1px solid #ffffff;
}

.ver ul li a {
  color: #ffffff;
  display: flex; /* Cambiado a flex para activar el comportamiento de los hijos */
  align-items: center;
  font-family: "noodle", sans-serif;
  font-size: 20px;
  margin: 5px;
  padding: 0 20px;
  text-decoration: none; /* Quita el subrayado por defecto */
}

.ver ul li a i {
  flex: 1 1 auto;
}

/* FORMULARIO INTERNO DEL MENÚ DESPLEGABLE */
.ver form {
  background-color: #ffffff;
  border-radius: 5px;
  height: 50px;
  width: 100%;
}

.ver form input, 
.ver form select, 
.ver form button {
  border: none;
  background: transparent;
  color: #ff5252;
  display: inline-block;
  border-radius: 0;
}

.ver form select {
  border-radius: 10px 0 0 1px;
  width: 15%;
}

.ver form button {
  background-color: #ff5252;
  border-radius: 10px;
  color: #ffffff;
  width: 30px;
}

header form button:hover {
  background-color: #ffffff;
  color: #ff5252;
}

.ver form input::placeholder {
  color: #ff5252; /* Corregido doble punto y coma */
}

/* CLASES DE UTILERÍA Y DISEÑO ATÓMICO */
.full {
  display: block;
  margin: 0;
  width: 25%;
}

.mini {
  display: flex;
}

.hidden {
  display: none !important; /* QA Note: !important garantiza que nada sobreescriba la orden de ocultar */
}

/* HEADER RESPONSIVE (MEDIA QUERIES INTEGRADAS) */
@media screen and (max-width: 900px) {
  header {
    border-radius: 0;
    margin-top: 5px;
    width: 100%;
  }

  header h1 {
    display: none;
  }

  .ver {
    width: 100%;
  }

  header .logo {
    display: none;
  }
}

/* ESTILOS GENERALES PARA TABLAS DE DATOS */
table {
  border-collapse: collapse; /* QA Note: Une los bordes de las celdas eliminando espacios por defecto del navegador */
  box-sizing: border-box;
  color: #333333; /* Color oscuro suave para mejor contraste si la tabla va sobre fondo blanco */
  margin: 0;
  padding: 5px;
  text-align: center;
  width: 100%;
}

/* ENCABEZADOS Y CELDAS DE CONTENIDO */
table tr th,
table tr td {
  border-bottom: 1px solid #34B7F1;
  padding: 12px 15px; /* REEMPLAZO QA: Cambiado margin por padding para dar aire y legibilidad al texto */
}

/* ESTILO ESPECÍFICO PARA EL ENCABEZADO (OPCIONAL PARA MEJORAR UI) */
table tr th {
  background-color: #34B7F1;
  color: #ffffff;
  font-family: "noodle", sans-serif;
  font-size: 1.1em;
}

/* EFECTO DE RESALTADO AL PASAR EL CURSOR (HOVER DE FILA) */
table tr:hover {
  background-color: rgba(52, 183, 241, 0.1); /* Cambiado de un tono rojizo a un azul coherente con tu paleta */
  transition: background-color 0.2s ease;
}

/* CONTENEDOR DE PERFIL DE USUARIO */
.perfil {
  border-bottom: 1px dashed #ffffff; /* Ajustado a 1px para garantizar consistencia en pantallas móviles */
  display: flex;
  align-items: center;
  margin: 10px;
}

/* AVATAR DE USUARIO (UNIFICADO Y OPTIMIZADO) */
.perfil .photo,
.perfil .photo1 {
  height: 40px;
  margin: 10px;
  width: 40px;
  box-sizing: border-box;
}

/* REDONDEADO EXCLUSIVO PARA CONTENEDOR PHOTO */
.perfil .photo {
  border-radius: 50%;
}

/* CONTROL SEGURO DE LA IMAGEN DENTRO DEL AVATAR */
.perfil .photo img,
.perfil .photo1 img {
  display: block;
  height: 100%;
  object-fit: cover;
  width: 100%;
}

/* CONTENEDOR DE TEXTO / METADATOS */
.perfil .conten {
  display: flex;
  flex-direction: column;
  margin: 0;
  text-align: left;
}

/* TIPOGRAFÍAS DE PERFIL */
.perfil .conten h1 {
  color: #333333; /* Ajustado a un negro suave para ergonomía visual */
  font-size: 1.5em;
  margin: 0;
}

.perfil .conten h2 {
  font-size: 1em;
  margin: 0; /* Removido !important mediante especificidad correcta */
  text-align: left;
}

.perfil .conten span {
  color: inherit;
  font-size: 1em;
  margin: 0;
}

/* RESPONSIVIDAD SUTIL PARA MÓVILES (OPCIONAL) */
@media screen and (max-width: 900px) {
  .perfil {
    margin: 5px;
  }
}

/* TARJETA DE PRODUCTO */
.producto {
  background-color: #ffffff;
  border-radius: 5px;
  display: inline-block;
  margin: 1.5px auto;
  width: calc(50% - 2.5px);
  box-sizing: border-box;
}

.producto img {
  display: block;
  height: 100px;
  object-fit: cover;
  margin: 0;
  width: 100%;
}

/* MENSAJE DE LISTA VACÍA */
.empty {
  color: #ff5252;
  width: 100%;
}

.empty h1,
.empty h3 {
  color: #ff5252;
  font-weight: 900;
  text-align: center;
}

/* ENCABEZADOS DE PRODUCTO */
.producto h3 {
  color: #ff5252;
  display: block;
  font-size: 1em;
  font-weight: 900;
  margin: 15px;
  text-align: left;
}

.producto h4 {
  color: #ff5252;
  display: inline-block;
  font-weight: 300;
  margin: 0;
  text-align: left;
  width: calc(50% - 15px);
}

/* FORMULARIO INTERNO DE PRODUCTO (CORRECCIÓN DE FUGA GLOBAL) */
.producto form {
  color: #ff5252;
  display: block;
  margin: 5px;
}

.producto form input,
.producto form input[type="date"],
.producto form textarea,
.producto form select {
  background: transparent;
  border: 2px solid #ff5252;
  border-radius: 10px;
  color: #ff5252;
  display: inline-block;
  font-family: "noodle", sans-serif;
  font-size: 20px;
  margin: 5px;
  padding: 5px;
  text-decoration: none;
  width: calc(50% - 15px);
  box-sizing: border-box;
}

/* CONTROL DEL FOCO (COMPATIBILIDAD PLANA GARANTIZADA) */
.producto form input:focus,
.producto form input[type="date"]:focus,
.producto form textarea:focus,
.producto form select:focus,
.producto form button:focus {
  outline: none;
  color: #ff5252;
}

.producto form datalist {
  font-size: 30px;
}

.producto form input::placeholder,
.producto form input[type="date"]::placeholder,
.producto form textarea::placeholder {
  color: #ff5252;
}

/* SELECTOR DE ARCHIVOS */
.producto input[type="file"]::file-selector-button {
  background-color: #ff5252;
  border: 2px solid #ff5252;
  border-radius: 5px 0 0 5px;
  color: #ffffff;
  font-family: "noodle", sans-serif;
  margin: -5px 5px -5px -5px;
  padding: 0.2em 0.4em;
  transition: background-color 0.25s ease; /* Animación ágil */
}

.producto form fieldset {
    margin: 0px;
    padding: 0px;
    border: none;
    flex: 1;
    align-items: flex-start;
}

/* BLOQUE DE INFORMACIÓN COMPLEMENTARIA */
.producto .info1 {
  color: #333333; /* Ajustado a oscuro suave para que sea legible sobre la tarjeta blanca */
  font-family: "noodle", sans-serif;
  margin: 0;
  padding: 10px;
  text-align: left;
  width: calc(100% - 200px); /* Ajustado para evitar desbordamientos de caja */
  box-sizing: border-box;
}

.producto .info1 h3 {
  font-size: 20px;
  font-weight: 600;
  margin: 5px 0;
  text-transform: uppercase;
}

.producto .info1 pre {
  color: #000000;
  font-family: "noodle", sans-serif;
  font-size: 18px;
  margin: 0;
  text-transform: lowercase;
  white-space: pre-wrap;
  width: 100%;
}

.producto .info1 span {
  color: #ff5252; /* Corregido a rojo/contraste para hacerlo visible sobre fondo blanco */
  display: block;
  margin: 10px;
  text-align: right;
  width: 100%;
}

.inactivo {
  display: none !important;
}

/* PIE DE TARJETA */
.producto .foot-2 {
  display: flex;
  align-items: flex-end;
  margin: 10px 0;
  padding: 5px;
}

.producto .foot-2 span {
  color: #333333; /* Ajustado para legibilidad */
}

.producto .time1 {
  background-color: #ffffff;
  border-radius: 10px;
  color: #ff5252;
  font-weight: 900;
  margin-left: auto; /* Reemplazo limpio de float en entornos modernos */
  padding: 0 10px;
  text-shadow: none;
}

/* RESPONSIVIDAD DE PRODUCTO */
@media screen and (max-width: 900px) {
  .producto {
    border-radius: 5px;
    margin: 5px 0;
    width: 100%;
  }

  .producto img {
    border-radius: 0;
    height: 100px;
  }
}

/* CONTENEDOR DE LA GALERÍA COMPLETA (LIGHTBOX) */
.lightbox {
  background-color: rgba(0, 0, 0, 0.85); /* Un poco más oscuro para mejorar el enfoque visual */
  display: none;
  height: 100%;
  left: 0;
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 9999; /* Máxima prioridad sobre menús y barras fijas */
  box-sizing: border-box;
}

/* ACTIVACIÓN DE LA GALERÍA VÍA CSS (:TARGET) */
.lightbox:target {
  display: flex; /* Cambiado a Flexbox para lograr un centrado perfecto y elástico de la imagen */
  align-items: center;
  justify-content: center;
  flex-direction: column;
  outline: none;
}

/* IMAGEN DENTRO DE LA GALERÍA */
.lightbox img {
  border-radius: 4px;
  box-shadow: 0 5px 25px rgba(0, 0, 0, 0.5);
  height: auto;
  max-height: 80vh; /* No ocupará más del 80% del alto total de la ventana */
  max-width: 85%;   /* No ocupará más del 85% del ancho total, eliminando el calc rígido */
  object-fit: contain; /* Cambiado a contain para mostrar la foto completa sin recortarla */
}

/* FLECHA DE NAVEGACIÓN ANTERIOR */
.previous {
  left: 5%;
  position: fixed;
  top: 50%;
  transform: translateY(-50%); /* Centrado vertical matemático perfecto sin importar la pantalla */
  width: 40px;
  z-index: 10000;
}

/* BOTÓN DE CIERRE (SALIDA EN ESQUINA SUPERIOR DERECHA ROBUSTO) */
.exit {
  color: #ff5252;
  font-size: 35px;
  position: fixed;
  right: 25px; /* Fijado de forma segura desde la esquina derecha */
  top: 20px;   /* Fijado de forma segura desde la esquina superior */
  text-decoration: none;
  width: auto;
  z-index: 10000;
  transition: transform 0.2s ease, color 0.2s ease;
}

.exit:hover {
  color: #ffffff;
  transform: scale(1.15);
}

/* RESPONSIVIDAD ERGONÓMICA DE LA GALERÍA */
@media screen and (max-width: 900px) {
  .lightbox:target {
    justify-content: center;
  }

  .lightbox img {
    max-height: 60vh;
    max-width: 95%;
  }

  /* CORRECCIÓN QA CRÍTICA: El botón se mantiene visible, pero se mueve arriba a la derecha */
  .exit {
    display: block; 
    font-size: 40px; /* Más grande en móviles para facilitar el toque con el dedo */
    right: 20px;
    top: 15px;
  }
}

/* CUADRO DE DIÁLOGO / NOTAS COMPARTIDAS */
.dialog {
  background-color: #ffffff; /* Añadido fondo blanco limpio para asegurar legibilidad */
  border-radius: 8px;
  box-sizing: border-box;
  color: #333333; /* Ajustado a negro/gris oscuro suave */
  display: flex;
  flex-direction: column; /* Apila el título, la lista y el pre verticalmente */
  margin: 10px 5px;
  max-width: 100%;
  padding: 15px; /* Relleno homogéneo en los 4 lados para ergonomía visual */
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); /* Sombra ligera para dar efecto de ventana/diálogo */
}

/* TÍTULO DEL DIÁLOGO */
.dialog h2 {
  color: #ff5252;
  font-size: 15px;
  margin: 0 0 10px 0; /* Separación fija hacia abajo */
  text-transform: uppercase;
}

/* LISTA DE ATRIBUTOS */
.dialog ul {
  flex: 1 1 auto;
  list-style-type: none;
  margin: 0;
  padding: 0;
}

.dialog ul li {
  border-bottom: 1px solid #ff5252;
  display: flex;
  justify-content: space-between; /* REEMPLAZO QA: Separa el texto a la izquierda y el span a la derecha sin usar float */
  align-items: center;
  padding: 6px 2px; /* Incrementado sutilmente para facilitar la lectura */
  text-align: left;
}

.dialog ul li span {
  color: #666666;
  font-weight: 300;
}

/* BLOQUE DE TEXTO LIBRE / PREFORMATEADO */
.dialog pre {
  color: #222222; /* CORRECCIÓN CRÍTICA DE CONTRASTE: Cambiado de blanco a oscuro para fondo claro */
  font-family: "noodle", sans-serif;
  font-size: 18px; /* Ajuste ergonómico de tamaño */
  margin: 10px 0 0 0;
  text-align: justify;
  white-space: pre-wrap;
  word-break: break-word; /* Evita que palabras extremadamente largas rompan el ancho de la caja */
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

/* CONTENEDOR PRINCIPAL DE LA LISTA */
#lista2 {
  font-size: 15px; /* Sintaxis corregida de font-size */
  list-style: none;
  margin: 5px;
  padding: 0;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.1);
  counter-reset: li-counter; /* Inicializa el contador de forma robusta desde el contenedor padre */
}

/* SOPORTE PARA ESTRUCTURAS OL INTERNAS */
#lista2 ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

/* ELEMENTOS DE LA LISTA (FILAS DE CLIENTES) */
#lista2 li {
  counter-increment: li-counter; /* Incrementa el contador personalizado */
  background-color: #dddddd;
  border-radius: 0.3em;
  color: #ff5252;
  display: block;
  font-family: "noodle", sans-serif;
  font-size: 16px;
  margin: 0.5em 0;
  padding: 0.9em 0.4em 1.2em 3.5em;
  position: relative;
  text-decoration: none;
  text-align: left;
  width: 100%; /* Cambiado a 100% elástico usando box-sizing interno */
  box-sizing: border-box;
  transition: all 0.3s ease-out;
}

/* ANIMACIÓN SUTIL AL PASAR EL CURSOR POR LA FILA */
#lista2 li:hover {
  background-color: #e5e5e5;
  transform: translateX(3px); /* Desplazamiento interactivo ergonómico */
}

/* BURBUJA NUMÉRICA CON CONTADOR CSS (:BEFORE) */
#lista2 li:before {
  content: counter(li-counter); /* Invoca el contador corregido */
  background-color: #87ceeb;
  border: 0.3em solid #ffffff;
  border-radius: 2em;
  color: #ffffff; /* CORRECCIÓN DE CONTRASTE: Número blanco sobre fondo celeste */
  font-weight: bold;
  height: 2em;
  line-height: 2em;
  left: 0.3em;
  margin-top: 0.3em;
  position: absolute;
  text-align: center;
  top: 50%; /* Centrado vertical moderno */
  transform: translateY(-50%); /* Garantiza que el círculo número quede alineado al centro del li */
  width: 2em;
  z-index: 2;
  transition: all 0.3s ease-out;
}

/* EFECTO HOVER EN LA BURBUJA */
#lista2 li:hover:before {
  background-color: #ff5252; /* Invierte el color del círculo al pasar el cursor sobre la fila */
}

/* TEXTOS PREFORMATEADOS INTERNOS */
#lista2 pre {
  color: #000000;
  font-family: "noodle", sans-serif;
  font-size: 15px;
  margin: 0 10px 0 0;
  text-align: justify;
  white-space: pre-wrap;
  word-break: break-word;
  -webkit-overflow-scrolling: touch;
}

/* CONTAINER PRINCIPAL DE LA BÚSQUEDA */
.search {
  border-radius: 40px;
  box-sizing: border-box;
  color: #ffffff;
  margin: 0 0 -5px 0;
  width: 100%;
}

/* ENTORNO FLEXBOX PARA EL FORMULARIO (ALINEACIÓN AUTOMÁTICA) */
.search form {
  display: flex;
  align-items: center; /* Centrado vertical perfecto de inputs y botones */
  gap: 8px;            /* Separación uniforme y controlada entre los campos */
  width: 100%;
  box-sizing: border-box;
}

/* CONTROLES BASE DEL FORMULARIO UNIFICADOS */
.search form input, 
.search form select, 
.search form button {
  background: transparent;
  color: #34B7F1;
  display: inline-block;
  font-family: "noodle", sans-serif;
  font-size: 22px;
  outline: none;
  padding: 5px;
  box-sizing: border-box;
}

/* CUADRO DE TEXTO (INPUT) */
.search form input {
  border: 2px solid #34B7F1;
  border-radius: 40px;
  flex: 1 1 auto; /* El input tomará automáticamente todo el espacio disponible */
  padding: 5px 15px;
}

.search form input::placeholder {
  color: #34B7F1;
}

/* SELECTOR DE FILTROS */
.search form select {
  background: none;
  border: none;
  border-right: 2px solid #34B7F1;
  border-radius: 40px 0 0 40px;
  padding: 0 10px;
  width: 20%;
  min-width: 120px; /* Evita que el select se vuelva demasiado pequeño en pantallas medianas */
}

.search form select option {
  background-color: #ff5252;
  color: #ffffff;
}

/* BOTÓN DE ENVÍO REFACTURADO (SIN FLOATS NI MÁRGENES NEGATIVOS) */
.search form button {
  background-color: #34B7F1;
  border: none;
  border-radius: 40px;
  color: #ffffff;
  cursor: pointer;
  width: 100px;
  height: 42px; /* Altura controlada para emparejar simétricamente con el input */
  transition: background-color 0.25s ease, color 0.25s ease;
}

.search form button:hover {
  background-color: #ffffff;
  color: #34B7F1;
}

/* ADAPTACIONES RESPONSIVAS */
@media screen and (max-width: 1200px) {
  .search {
    margin-top: 10px;
  }
}

@media screen and (max-width: 600px) {
  .search form input,
  .search form select {
    width: 100%;
    border-radius: 40px;
  }
  
  .search form select {
    border: 2px solid #34B7F1; /* Añade borde en móviles al desapilarse */
  }
}

/* COMPONENTE DE NOTAS Y COMENTARIOS DEL CLIENTE */
.notas {
  background-color: #34B7F1;
  border-radius: 10px;
  box-sizing: border-box;
  color: #ffffff;
  font-family: "noodle", sans-serif;
  margin: 5px 0;
  padding: 10px 15px; /* REEMPLAZO QA: Incrementado el relleno vertical para darle aire al texto */
  width: 100%;
}

/* CONTENEDOR DE TEXTO PREFORMATEADO INTERNO */
.notas pre {
  color: #ffffff;
  font-family: "noodle", sans-serif;
  font-size: 20px;
  margin: 0;
  text-align: justify;
  white-space: pre-wrap;
  word-break: break-word; /* Evita que cadenas largas rompan la caja de la nota */
  -webkit-overflow-scrolling: touch;
}

/* CONTENEDOR DE IMÁGENES AUXILIARES O DE ESTADO */
.ima {
  max-width: 500px; /* Cambiado a ancho máximo para ser elástico y fluido */
  width: 100%;
  margin: 8vh auto; /* REEMPLAZO QA: Usamos vh (view height) para un control vertical simétrico y real respecto a la pantalla */
}

/* PROTECCIÓN PARA IMÁGENES INTERNAS DE .IMA */
.ima img {
  display: block;
  height: auto;
  width: 100%;
}

/* ADAPTACIONES RESPONSIVAS Y BLINDAJE MÓVIL */
@media screen and (max-width: 900px) {
  .notas {
    border-radius: 5px; /* Suavizado en móviles */
  }

  .ima {
    max-width: 250px;
    margin: 5vh auto;
  }

  /* Ajuste complementario para cuadros de diálogo integrados */
  .dialog {
    border-radius: 0;
    width: 100%;
  }
}

/* PANTALLA MODAL NATIVA (DIALOG) */
dialog {
  background-color: #00a65a;
  border: none;
  border-radius: 5px;
  box-sizing: border-box;
  color: #ffffff;
  
  /* ❌ ELIMINADO: display: inline-flex; de aquí */
  
  margin: auto;
  max-width: 95%; 
  padding: 20px 15px; 
  position: relative; 
  width: 500px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3); 
}

/* ✅ SOLUCIÓN UX/UI: Aplica Flexbox SOLO cuando el modal está abierto nativamente */
dialog[open] {
  display: inline-flex; 
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

/* TÍTULO INTERNO DEL MODAL */
dialog h3 {
  font-size: 1.1em;
  font-weight: 900;
  margin: 0 0 15px 0;
  text-transform: uppercase;
  text-align: center;
}

/* FORMULARIO INTERNO DEL MODAL (CORRECCIÓN DE FUGA GLOBAL) */
dialog form {
  width: 100%;
  box-sizing: border-box;
}

dialog form input, 
dialog form input[type="date"], 
dialog form textarea, 
dialog form select {
  background-color: #34B7F1;
  border: 2px solid #34B7F1;
  border-radius: 10px;
  color: inherit;
  display: block;
  font-family: "noodle", sans-serif;
  font-size: 1em;
  margin: 8px auto; /* Centrado horizontal con separación vertical limpia */
  padding: 6px 10px;
  text-decoration: none;
  width: 100%;
  box-sizing: border-box;
}

/* CONTROL DEL FOCO (COMPATIBILIDAD PLANA Y LIMPIA) */
dialog form input:focus, 
dialog form input[type="date"]:focus, 
dialog form textarea:focus, 
dialog form select:focus {
  outline: none;
  color: #ffffff;
  border-color: #ffffff; /* El borde cambia a blanco al hacer foco para dar feedback visual */
}

/* BOTÓN DE CIERRE (ESQUINA SUPERIOR DERECHA SEGURO) */
dialog .close {
  background-color: #ff5252;
  border: none;
  border-radius: 4px;
  color: #ffffff;
  cursor: pointer;
  height: 30px;
  position: absolute;
  right: 10px;
  top: 10px;
  width: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s ease, transform 0.1s ease;
}

dialog .close:hover {
  background-color: #d43f3f;
  transform: scale(1.05);
}

/* ADAPTACIÓN MÓVIL ADICIONAL */
@media screen and (max-width: 600px) {
  dialog {
    padding: 25px 10px;
    width: 100%; /* Toma todo el ancho disponible en celulares */
  }
  
  dialog .close {
    top: 5px; /* Ajuste sutil de espacio en pantallas pequeñas */
  }
}

/* BOTONES DE SELECCIÓN TIPO RADIO (ESTILO ENLACE - RADIOT) */
.radioT {
  display: inline-block;
  position: relative;
}

.radioT a {
  border-radius: 3px;
  color: #34B7F1;
  display: inline-block;
  cursor: pointer;
  padding: 5px 15px 5px 40px;
  position: relative;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.radioT a:before {
  content: "";
  background: transparent;
  border: 3px solid #34B7F1;
  border-radius: 50%;
  display: inline-block;
  height: 12px;
  left: 12px;
  position: absolute;
  top: 50%;
  transform: translateY(-50%); /* Centrado vertical simétrico del círculo */
  width: 12px;
  box-sizing: border-box;
}

.radioT a:hover:before {
  background-color: #34B7F1;
  color: #ffffff;
}

/* VARIANTE DE SELECCIÓN (RADIOT1) */
.radioT1 {
  display: inline-block;
  position: relative;
}

.radioT1 a {
  background-color: #FF4136;
  border-radius: 3px;
  color: #ffffff;
  display: inline-block;
  cursor: pointer;
  padding: 5px 5px;
  position: relative;
  transition: background-color 0.3s ease;
}

/* COMPONENTES DE FORMULARIO MODERNOS Y ACCESIBLES (RADIO-2 Y CHECKBOX) */
.radio-2 label, 
.checkbox label {
  border-radius: 5px;
  color: #FF4136;
  display: inline-block;
  cursor: pointer;
  font-size: 1em;
  padding: 5px 10px;
  position: relative;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.radio-2 label:hover, 
.checkbox label:hover {
  background-color: rgba(255, 65, 54, 0.1);
}

.radio-2 input[type="radio"],
.checkbox input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  margin: 0;
  padding: 0;
  pointer-events: none;
}

.radio-2 input[type="radio"]:checked + label {
  background-color: #FF4136;
  border-radius: 5px; /* Sincronizado con el borde del estado pasivo */
  color: #ffffff;
  padding: 5px 10px;
}

.checkbox input[type="checkbox"]:checked + label {
  background-color: #FF4136;
  border-radius: 5px;
  color: #ffffff;
  padding: 5px 10px;
}

.radio-2 input[type="radio"]:focus-visible + label,
.checkbox input[type="checkbox"]:focus-visible + label {
  outline: 2px dashed #FF4136;
  outline-offset: 2px;
}

/* CONTENEDOR PRINCIPAL DE PRECIOS */
.precio {
  box-sizing: border-box;
  margin: 0;
  text-align: center;
  width: 100%;
}

/* ETIQUETA DE MARCA DEL PRODUCTO */
.precio .marca {
  background-color: #ff5252;
  padding: 10px;
}

.precio .marca h1 {
  color: #ffffff;
  font-size: 1em;
  margin: 0;
  text-shadow: none;
  text-transform: uppercase;
}

/* CONTENEDOR DEL MONTO / PRECIO PRINCIPAL */
.precio .monto {
  background-color: #ffffff;
  padding: 10px;
}

.precio .monto h2 {
  color: #222222; /* Ajustado a un gris oscuro suave para mejorar la ergonomía visual */
  font-size: 2em;
  margin: 0;
  text-shadow: none; /* Nota de QA: Heredado automáticamente, pero se mantiene si deseas forzar la anulación */
}

/* SECCIÓN DE CUOTA INICIAL (PRIMA) */
.precio .prima {
  background-color: #ff5252;
  padding: 10px;
}

.precio .prima span {
  color: #ffffff;
  font-size: 1em;
  text-shadow: none;
}

/* COLUMNA ESTRUCTURAL DE LA REJILLA (GRID/FLEX) */
.column {
  box-sizing: border-box;
  display: flex;
  justify-content: space-around;
  margin: 6px 3px;
  padding: 0;
  width: calc(33.33% - 10px);
}

/* CONTENEDOR DE LA TARJETA (CARD) */
.post-module {
  background: transparent;
  display: block;
  max-height: 450px; /* Incrementado sutilmente para dar margen al crecimiento del texto */
  position: relative;
  width: 100%; /* Simplificado calc() redundante */
  z-index: 1;
}

/* MINI CONTENEDOR DE IMAGEN O MINIATURA */
.thumbnail {
  background: transparent;
  height: 300px;
  position: relative; /* Otorga el contexto relativo correcto para la burbuja de la fecha */
  width: 100%;
}

.thumbnail img {
  border-radius: 5px 5px 0 0;
  height: 300px;
  object-fit: cover;
  width: 100%;
}

/* BURBUJA DE FECHA DINÁMICA */
.thumbnail .date {
  border-radius: 50%;
  color: #ffffff;
  display: flex;
  flex-direction: column; /* Apila el día arriba y el mes abajo */
  align-items: center;
  justify-content: center;
  font-weight: 700;
  height: 55px;
  position: absolute;
  right: 10px;
  top: 10px;
  text-align: center;
  width: 55px;
  z-index: 2;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.thumbnail .date .day {
  font-size: 18px;
  line-height: 1;
}

.thumbnail .date .month {
  font-size: 10px;
  line-height: 1;
  text-transform: uppercase;
}

/* CORRECCIÓN EN CASO DE USAR IMAGEN EN LA FECHA */
.thumbnail .date .ima {
  border-radius: 50%;
  height: 100%;
  left: 0;
  object-fit: cover;
  position: absolute;
  top: 0;
  width: 100%;
  z-index: -1; /* Se mueve detrás del texto para servir de fondo */
}

/* CAPA DE TEXTO E INFORMACIÓN (REFACTURADA CONTRA DESBORDAMIENTOS) */
.post-content {
  background: rgba(0, 0, 0, 0.65); /* Un poco más oscuro para mejorar el contraste del texto */
  border-radius: 0 0 5px 5px; /* Sincronizado con las esquinas superiores de la imagen */
  bottom: 0;
  box-sizing: border-box;
  min-height: 100px; /* REEMPLAZO QA: Permite que la caja se estire si el título ocupa dos líneas */
  height: auto;
  padding: 15px 10px 10px 10px;
  position: absolute;
  width: 100%;
}

/* ETIQUETA DE CATEGORÍA FLOTANTE */
.category {
  background-color: #ff5252;
  color: #ffffff;
  font-size: 1.1em;
  font-weight: 700;
  left: 0;
  padding: 6px 12px;
  position: absolute;
  top: -32px; /* Ajustado simétricamente al nuevo padding */
  text-transform: uppercase;
  border-radius: 3px 3px 0 0;
}

/* TÍTULOS Y DESCRIPCIONES INTERNAS */
.title {
  color: #ff5252;
  display: inline-block;
  font-size: 1.2em;
  font-weight: 700;
  margin: 0;
  padding: 0 0 5px 0;
}

.sub_title {
  color: #ffffff; /* Cambiado a blanco para contrastar adecuadamente sobre el fondo oscuro */
  display: inline-block;
  font-size: 0.95em;
  font-weight: 400;
  margin: 0;
  padding: 0 0 10px 0;
}

.description {
  color: #dddddd; /* Ajustado para legibilidad */
  display: none; /* QA Note: Si cambias esto a 'block' vía JS, la caja .post-content respirará sin romperse */
  font-size: 14px;
  line-height: 1.6;
}

/* PIE DE LA TARJETA */
.post-module .foot {
  background: none;
  border-top: 1px solid rgba(255, 255, 255, 0.2); /* Ajustado a blanco transparente para que sea visible */
  position: relative;
  width: 100%;
}

/* RESPONSIVIDAD DE TARJETAS EN DISPOSITIVOS MÓVILES */
@media screen and (max-width: 900px) {
  .column {
    width: 100%; /* Ocupa todo el ancho disponible en celulares */
    margin: 10px 0;
  }
  
  .thumbnail {
    height: 250px; /* Sutil reducción de altura para pantallas pequeñas */
  }
  
  .thumbnail img {
    height: 250px;
  }
}

/* CONTAINER BASE DE LA TARJETA (.CARD) */
.card {
  background-color: #ffffff;
  border-radius: 10px;
  box-sizing: border-box;
  display: inline-block;
  margin: 0 auto 3px auto;
  padding: 5px;
  text-align: center;
  width: calc(33% - 1px);
}

@media screen and (max-width: 900px) {
  .card {
    margin: 10px 5px 0 5px;
    width: calc(100% - 10px);
  }
}

.card h2 {
  color: #000000;
  font-size: 1.3em;
  text-transform: uppercase;
}

.card h3 {
  color: #000000;
  font-size: 1em;
  text-transform: uppercase;
}

.card span {
  color: #000000;
  display: block;
}

.card .time {
  margin-left: auto;
}

.card .main1 {
  margin: 0;
  padding: 0;
  width: calc(100% - 30px);
}

.card .pro {
  border-radius: 10px;
  height: 200px;
  margin: 0 auto;
  width: 100%;
  overflow: hidden;
}

.card .pro img {
  display: block;
  height: 200px;
  margin: 0 auto;
  object-fit: cover;
  padding: 0;
  width: 100%;
  border-radius: 10px;
}

.card .main {
  margin: 5px 15px;
  width: 100%;
}

.card .main pre {
  color: #000000;
  font-family: "noodle", sans-serif;
}

.card form {
  color: #ffffff;
  margin: 0;
  box-sizing: border-box;
}

.card form label {
  background-color: #34B7F1;
  border-radius: 10px 0 0 10px;
  color: #ffffff;
  float: left;
  text-align: center;
  font-size: 16px;
  margin: 2px auto;
  padding: 7.5px 10px;
  width: 25%;
  height: 33px;
  box-sizing: border-box;
}

.card form input, 
.card form input[type="date"], 
.card form textarea, 
.card form select {
  background-color: #d0d3d4;
  border: 2px solid #34B7F1;
  border-radius: 0 10px 10px 0;
  color: #34B7F1;
  font-family: "noodle", sans-serif;
  font-size: 18px;
  margin: 2px auto;
  padding: 5px;
  text-decoration: none;
  width: 75%;
  box-sizing: border-box;
}

.card form input, 
.card form input[type="date"], 
.card form select {
    height: 33px;
}

.card form input:focus, 
.card form input[type="date"]:focus, 
.card form textarea:focus, 
.card form select:focus {
  outline: none;
  color: #34B7F1;
}

.card form input::placeholder, 
.card form input[type="date"]::placeholder, 
.card form textarea::placeholder {
  color: #34B7F1;
}

.card input[type="file"]::file-selector-button {
  background-color: #34B7F1;
  border: none;
  border-radius: 5px;
  color: #ffffff;
  font-family: "noodle", sans-serif;
  margin: -5px 5px -5px -5px;
  padding: 0.2em 0.4em;
  transition: background-color 0.25s ease;
}

.card form fieldset {
    margin: 0px;
    padding: 0px;
    border: none;
    flex: 1;
}

.card .foot {
  border-top: 1px solid rgba(0, 0, 0, 0.6);
  bottom: 0;
  width: 100%;
}

.card span {
    font-weight: 900;
    color: #000;
}

@media screen and (max-width: 900px) {
  .card form label {
    padding: 7.3px 10px;
  }
  
  .card form input, 
  .card form input[type="date"], 
  .card form textarea, 
  .card form select {
    width: calc(75% - 0px);
    font-size: 18px;
  }
}

/* CONTAINER BASE DE LA TARJETA FORMULARIO (.CARD2) */
.card2 {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  box-sizing: border-box;
  display: inline-block;
  margin: 0 auto 8px auto;
  padding: 10px;
  text-align: left;
  width: calc(33% - 24px);
}

/* RESPONSIVIDAD GENERAL DE LA TARJETA */
@media screen and (max-width: 900px) {
  .card2 {
    margin: 10px 5px 0 5px;
    width: calc(100% - 10px);
  }
}

/* TIPOGRAFÍAS INTERNAS */
.card2 h2,
.card2 h3 {
  color: #ffffff;
  text-align: center;
  text-transform: uppercase;
}

.card2 h2 {
  font-size: 1.1em;
}

.card2 h3 {
  font-size: 1em;
}

.card2 span {
  color: #ff5252;
  display: block;
}

/* COMPONENTE DE TIEMPO / ALINEACIÓN REFACTURADA */
.card2 .time {
  margin-left: auto; /* Reemplazo elástico y moderno de float y table-row */
}

/* CONTENEDORES DE IMÁGENES REFACTURADOS CON FLEXBOX CORRECTO */
.card2 .circle {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 10px;
}

.card2 .circle img {
  border: 4px solid #ffffff;
  border-radius: 999px;
  height: 150px;
  object-fit: cover;
  overflow: hidden;
  width: 150px;
}

.card2 .square {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
}

.card2 .square img {
  border: 2px solid #ffffff;
  border-radius: 10px;
  height: 200px;
  object-fit: cover;
  overflow: hidden;
  width: calc(100% - 5px);
}

/* SUB-CONTENEDORES */
.card2 .main1 {
  display: flex;
  margin: 0;
  padding: 0;
  width: calc(100% - 50px);
}

.card2 .pro {
  height: 150px;
  width: 150px;
}

.card2 .pro img {
  height: 150px;
  margin: 0;
  object-fit: contain;
  padding: 0;
  width: 100%; /* Simplificado calc() redundante */
}

.card2 .main {
  margin: 5px 15px;
  width: calc(100% - 130px);
}

.card2 .main pre {
  color: #ffffff;
  font-family: "noodle", sans-serif;
}

/* FORMULARIOS CON ÁMBITO PROTEGIDO (SIN FUGA GLOBAL) */
.card2 form {
  color: #ffffff;
  margin: 0;
  box-sizing: border-box;
}

.card2 form label {
  color: #ff5252;
  font-size: 1em;
  font-weight: 600;
}

.card2 form input, 
.card2 form input[type="date"], 
.card2 form textarea, 
.card2 form select {
  background-color: #34B7F1;
  border: 2px solid #34B7F1;
  border-radius: 10px;
  color: inherit;
  display: block;
  font-family: "noodle", sans-serif;
  font-size: 1em;
  margin: 2px auto;
  padding: 5px;
  text-decoration: none;
  width: 100%;
  box-sizing: border-box;
}

/* CONTROL DE ENFOQUE (COMPATIBILIDAD PLANA) */
.card2 form input:focus, 
.card2 form input[type="date"]:focus, 
.card2 form textarea:focus, 
.card2 form select:focus {
  outline: none;
  color: #ffffff;
}

.card2 form input::placeholder, 
.card2 form input[type="date"]::placeholder, 
.card2 form textarea::placeholder {
  color: #ffffff;
}

/* SELECTOR DE ARCHIVOS */
.card2 input[type="file"]::file-selector-button {
  background-color: #ff5252;
  border: 2px solid #ff5252;
  border-radius: 5px 0 0 5px;
  color: #ffffff;
  font-family: "noodle", sans-serif;
  margin: -5px 5px -5px -5px;
  padding: 0.2em 0.4em;
  transition: background-color 0.25s ease;
}
 .card2 form fieldset {
    margin: 0px;
    padding: 10px;
    border: none;
    flex: 1;
 }

/* PIE DE TARJETA */
.card2 .foot {
  border-top: 1px solid #ffffff;
  margin: 10px 0;
  width: 100%;
}

/* CONTENEDOR PRINCIPAL DE LISTAS (.LIST) */
.list {
  position: relative;
  box-sizing: border-box;
}

.list h2 {
  color: #ffffff;
  font-weight: 700;
  letter-spacing: 1px;
  margin-bottom: 10px;
}

/* REINICIO SEGURO DE LISTA */
.list ul {
  margin: 0;
  padding: 0;
  position: relative;
  list-style: none;
}

/* FILAS DE LA LISTA CON ANIMACIÓN OPTIMIZADA */
.list ul li {
  background-color: rgba(255, 255, 255, 0.05); /* Sutil fondo base para dar cuerpo a la fila */
  border-left: 2px solid #f50057;
  color: #fce4ec;
  cursor: pointer;
  margin: 4px 0;
  position: relative;
  transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* REEMPLAZO QA: Animación con transform para evitar Reflow y mejorar FPS en móviles */
.list ul li:hover {
  transform: translateX(8px);
}

/* TEXTO INTERNO CON ACCESIBILIDAD Y CAPAS COMPROBADAS */
.list ul li span {
  display: inline-block;
  font-size: 16px;
  padding: 8px 8px 8px 12px;
  position: relative;
  z-index: 2; /* Incrementado para asegurar que quede por encima del fondo rosa */
  transition: color 0.3s ease;
}

/* CORRECCIÓN CRÍTICA DE CONTRASTE: Texto blanco para fondo rosa oscuro */
.list ul li:hover span {
  color: #ffffff; 
}

/* FONDO EXPANDIBLE FLUIDO */
.list ul li:before {
  content: "";
  background-color: #f50057;
  height: 100%;
  left: 0;
  position: absolute;
  top: 0;
  transform: scaleX(0);
  transform-origin: left;
  width: 100%;
  z-index: 1;
  transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.list ul li:hover:before {
  transform: scaleX(1);
}

/* DISTRIBUCIÓN LATERAL DE PANELES (DETALLES COHERENTES) */
.det {
  position: -webkit-sticky;
  position: sticky;
  top: 20px;
  width: 35%;
  z-index: 10;
  box-sizing: border-box;
}

.det1 {
  width: 65%;
  box-sizing: border-box;
}

/* RESPONSIVIDAD SINCRONIZADA PARA PANELES LATERALES */
@media screen and (max-width: 900px) {
  .det {
    display: none; /* Oculta el panel secundario en pantallas de teléfonos */
  }

  .det1 {
    width: calc(100% - 10px);
  }
}

/* CONTENEDOR FLUIDO DE FILAS (Añadir esta clase a los bloques envolventes en tu HTML) */
.form-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px; /* Controla la separación exacta entre columnas de forma automática */
  margin-bottom: 10px;
  width: 100%;
  box-sizing: border-box;
}

/* COLUMNA COMPLETA (100%) */
.colum-1 {
  flex: 0 0 100%;
  width: 100%;
  box-sizing: border-box;
}

/* MEDIA COLUMNA (50% - ELÁSTICA Y SEGURA) */
.colum-2 {
  flex: 1 1 calc(50% - 5px); /* Se adapta dinámicamente restando el espacio del gap */
  box-sizing: border-box;
}

/* UN TERCIO DE COLUMNA (33.33%) */
.colum-3 {
  flex: 1 1 calc(33.33% - 7px);
  box-sizing: border-box;
}

/* ADAPTACIÓN MÓVIL CRÍTICA: Apila todas las columnas al 100% en pantallas de teléfonos */
@media screen and (max-width: 600px) {
  .colum-2,
  .colum-3 {
    flex: 0 0 100%;
    width: 100%;
    margin-right: 0 !important;
  }
}

/* CONTENEDOR PRINCIPAL DE BOTONES DE ACCIÓN (.BTN1) */
.btn1 {
  display: flex;
  margin: 5px 0 0 0;
  width: 100%;
  box-sizing: border-box;
}

/* 1. COMPORTAMIENTO POR DEFECTO (UN SOLO BOTÓN) */
.btn1 .bt {
  flex: 1;                     
  background-color: #34B7F1; 
  border: 1px solid #1B85B4;  
  color: #ffffff;
  cursor: pointer;
  display: flex;        
  align-items: center;
  justify-content: center; /* Por defecto centrado si es hijo único */
  gap: 8px;                    
  font-family: sans-serif;
  font-size: 13px;
  font-weight: bold;
  margin: 0;                  
  padding: 10px 16px;          
  text-align: center;
  box-sizing: border-box;
  transition: background-color 0.2s ease; 
}

.btn1 .bt:has(* + *) {
  justify-content: space-between;
}

/* LIMPIEZA Y RESET DE ELEMENTOS INTERNOS */
.btn1 .bt span, 
.btn1 .bt svg, 
.btn1 .bt i {
  margin: 0;
  padding: 0;
  display: inline-flex;
  align-items: center;
  color: #fff;
}


/* CONTROL DE BORDES INTERMEDIOS */
.btn1 .bt:not(:last-child) {
  border-right: none;
}

/* REDONDEADO SEGURO DE EXTREMOS (MODELO CÁPSULA) */
.btn1 .bt:first-child {
  border-top-left-radius: 25px;
  border-bottom-left-radius: 25px;
}

.btn1 .bt:last-child {
  border-top-right-radius: 25px;
  border-bottom-right-radius: 25px;
}

/* EFECTO HOVER */
.btn1 .bt:hover {
  background-color: #1B85B4;
}

/* CONTENEDOR PRINCIPAL OSCURO DE FONDO */
.search-wrapper {
  display: flex;
  justify-content: center; /* Eliminado space-around duplicado redundante */
  align-items: center;
  box-sizing: border-box;
  margin: 0px 0px 10px 0px;
  width: 100%;
}

/* BARRA BLANCA CON BORDES REDONDEADOS */
.search-bar-container {
  background-color: #ffffff;
  border-radius: 50px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  display: flex;
  align-items: center;
  height: 42px;
  overflow: hidden; /* Corta cualquier desborde o esquina que intente salirse de la curva */
  width: 100%;
  box-sizing: border-box;
  padding-right: 3px;
}

/* SECCIÓN DEL SELECTOR DE TEXTO / INPUT */
.input-group {
  display: flex;
  align-items: center;
  flex: 1; /* Toma todo el espacio disponible empujando las acciones a la derecha */
  margin: 0;
  padding-left: 20px;
}

/* ESTILO DEL INPUT (CORREGIDO ANCHO FLUIDO PARA EVITAR DESBORDAMIENTOS) */
.input-group input,
.input-group select {
  background: transparent;
  border: none;
  color: #ff5252;
  font-family: "noodle";
  font-size: 16px;
  margin: 0;
  padding: 0px 5px;
  outline: none;
  width: 100%; /* QA Note: Garantiza que el texto se comprima internamente sin empujar los botones */
}
.input-group input::placeholder {
  color: #ff5252;
}

/* CONTENEDOR DE LOS BOTONES ROJOS DE ACCIÓN */
.actions-group {
  display: flex;
  gap: 1; 
  margin: 0;
  padding-right: 0;
  align-items: center;
  justify-content: flex-end;
  height: 100%;
}

/* ESTILO BASE DE LOS BOTONES OVALADOS */
.btn-action {
  background-color: #ff5252;
  border: none;
  border-radius: 50px; /* Asegura cápsula perfecta en ambos botones por igual */
  color: #ffffff;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 16px;
  height: 36px;
  min-width: 100px;
  text-decoration: none;
  flex-shrink: 0; /* Evita que Flexbox intente deformar el botón en pantallas medianas */
  box-sizing: border-box;
  transition: background-color 0.2s ease;
}

/* EFECTO HOVER */
.btn-action:hover {
  background-color: #e23e3e;
}

/* ESTRATEGIA RESPONSIVA CRÍTICA */
@media (max-width: 768px) {
  .search-wrapper {
    margin: -5px 0 -20px 0;
    padding: 0 15px;
  }

  /* En celulares los botones se encogen manteniendo la forma redondeada limpia */
  .btn-action {
    min-width: 54px; 
    height: 36px;
    border-radius: 50px;
    padding: 0;
  }

  .input-group {
    padding-left: 15px;
  }

  .input-group input {
    font-size: 14px;
  }
}