/* ==============================
   INDUSTRIAL SECTION (DARK VERSION)
================================ */

.industrial-section {
  padding: 100px 20px;
  background: linear-gradient(180deg, #0f172a 0%, #0C1623 100%);
  color: #cbd5e1;
}

.industrial-container {
  max-width: 1200px;
  margin: auto;
}

/* ==============================
   HEADER
================================ */

.industrial-header {
  text-align: center;
  margin-bottom: 50px;
}

.industrial-header h2 {
  color: var(--accent-color);
  font-size: 32px;
  margin-bottom: 12px;
}

.industrial-header p {
  color: #94a3b8;
  max-width: 700px;
  margin: auto;
}

/* ==============================
   FILTROS
================================ */

.industrial-filters {
  text-align: center;
  margin-bottom: 40px;
}

.filter-btn {
  background: rgba(22,165,244,0.08);
  border: 1px solid rgba(22,165,244,0.3);
  color: var(--brackground-button);
  padding: 8px 18px;
  margin: 5px;
  border-radius: 30px;
  cursor: pointer;
  transition: all .3s ease;
  font-size: 14px;
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--brackground-button);
  color: #ffffff;
  box-shadow: 0 0 15px rgba(22,165,244,.4);
}

/* ==============================
   GRID
================================ */

.industrial-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 25px;
}

/* ==============================
   CARD
================================ */

.industrial-card {
  background: #111c2b;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,0.05);
  overflow: hidden;

  opacity: 1;
  transform: scale(1);
  transition: all .35s ease;

  box-shadow: 0 4px 20px rgba(0,0,0,.25);
}

.industrial-card:hover {
  transform: translateY(-6px);
  border-color: rgba(22,165,244,.4);
  box-shadow: 0 8px 30px rgba(22,165,244,.2);
}

/* Animación salida */

.industrial-card.fade-out {
  opacity: 0;
  transform: scale(.95);
}

/* ==============================
   IMAGEN
================================ */

.industrial-card img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  transition: transform .4s ease;
}

.industrial-card:hover img {
  transform: scale(1.05);
}

/* ==============================
   CUERPO
================================ */

.card-body {
  padding: 20px;
}

.card-body span {
  font-size: 12px;
  color: #16a5f4;
  font-weight: 600;
}

.card-body h3 {
  margin: 8px 0;
  font-size: 18px;
  color: #f1f5f9;
}

.card-body p {
  font-size: 14px;
  color: #94a3b8;
  margin-bottom: 12px;
}

.card-body a {
  color: var(--accent-color);
  font-weight: 600;
  text-decoration: none;
  transition: all .3s ease;
}

.card-body a:hover {
  color: var(--accent-color);
}

.sale-link i {
    transition: transform 0.3s ease;
}

.sale-link:hover i {
    transform: translateX(4px);
}

/* ==============================
   TOGGLE BUTTON
================================ */

.industrial-toggle {
  text-align: center;
  margin-top: 50px;
}

#toggleCards {
  background: rgba(22,165,244,0.15);
  border: 1px solid rgba(22,165,244,0.4);
  color: var(--brackground-button);
  padding: 10px 26px;
  border-radius: 30px;
  cursor: pointer;
  font-weight: 600;

  display: inline-flex;
  align-items: center;
  gap: 8px;

  transition: all .3s ease;
}

#toggleCards:hover {
  background: var(--brackground-button);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 0 15px rgba(22,165,244,.4);
}

.toggle-icon {
  transition: transform .3s ease;
}

.rotate {
  transform: rotate(180deg);
}



/* ==============================
   RESPONSIVE
================================ */

/* ==============================
   RESPONSIVE GRID PROFESIONAL
================================ */

/* Desktop grande */
@media (max-width: 1200px) {
  .industrial-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Tablet */
@media (max-width: 992px) {
  .industrial-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Celular */
@media (max-width: 576px) {
  .industrial-grid {
    grid-template-columns: 1fr;
  }

  .industrial-section {
    padding: 70px 15px;
  }

  .industrial-header h2 {
    font-size: 24px;
  }

  .industrial-header p {
    font-size: 14px;
  }
}

/* Mobile: Ocultar cards, estilizar filtros como botones grandes */
@media (max-width: 768px) {
  /* Estilizar filtros como botones grandes en mobile */
  .industrial-filters {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 30px;
  }

  .filter-btn {
    padding: 16px 25px;
    font-size: 1rem;
    border-radius: 10px;
    border: 2px solid var(--accent-color);
    background: var(--surface-color);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
  }

  .filter-btn:hover,
  .filter-btn.active {
    background: var(--accent-color);
    color: #ffffff;
    transform: none;
  }

  /* Ocultar grid en mobile */
  .industrial-grid {
    display: none !important;
  }

  /* Ocultar el botón toggle en mobile */
  .industrial-toggle {
    display: none;
  }
}



.card-carousel {
  position: relative;
  height: 120px;
  display: flex;
  justify-content: center;
  align-items: center;
  background: #0f1a2b;
}

.card-carousel img {
  position: absolute;
  max-height: 120px;
  opacity: 0;
  transition: opacity .6s ease;
  /* filter: brightness(0) invert(1); */
}

.card-carousel img.active {
  opacity: 1;
}

/* ==============================
   THEME LIGHT OVERRIDES
================================ */

.industrial-section.section-light {
  background: #f8f9fa !important;
  color: #333 !important;
}

.industrial-section.section-light .industrial-header h2 {
  color: #2f9fb8 !important;
}

.industrial-section.section-light .industrial-header p {
  color: #555 !important;
}

.industrial-section.section-light .filter-btn {
  background: rgba(47, 159, 184, 0.08);
  border: 1px solid rgba(47, 159, 184, 0.3);
  color: #2f9fb8;
}

.industrial-section.section-light .filter-btn:hover,
.industrial-section.section-light .filter-btn.active {
  background: #2f9fb8;
  color: #ffffff;
  box-shadow: 0 0 15px rgba(47, 159, 184, 0.4);
}

/* ==============================
   PRODUCTS MODAL (Mobile Only)
================================ */

.products-modal {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.85);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.products-modal.active {
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
}

.products-modal-content {
  background: var(--surface-color);
  border-radius: 12px;
  max-width: 800px;
  width: 90%;
  max-height: 80vh;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  transform: scale(0.9);
  transition: transform 0.3s ease;
  border: 2px solid var(--accent-color);
}

.products-modal.active .products-modal-content {
  transform: scale(1);
}

.products-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 25px 30px;
  border-bottom: 2px solid rgba(47, 159, 184, 0.3);
  background: linear-gradient(135deg, rgba(47, 159, 184, 0.1), rgba(47, 159, 184, 0.05));
}

.products-modal-header h3 {
  margin: 0;
  color: var(--heading-color);
  font-size: 1.8rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 12px;
}

.products-modal-close {
  background: transparent;
  border: none;
  color: var(--default-color);
  font-size: 2rem;
  cursor: pointer;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  transition: all 0.2s ease;
  line-height: 1;
  padding: 0;
  opacity: 0.8;
}

.products-modal-close:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--accent-color);
  opacity: 1;
}

.products-modal-body {
  padding: 30px;
  overflow-y: auto;
  max-height: calc(80vh - 90px);
}

/* Grid de cards dentro del modal */
.modal-cards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

.modal-cards-grid .industrial-card {
  display: block;
  opacity: 1;
  transform: none;
}

.modal-cards-grid .industrial-card:hover {
  transform: translateY(-3px);
}

/* Mobile Responsive para modal */
@media (max-width: 768px) {
  .products-modal-content {
    width: 95%;
    max-height: 90vh;
  }

  .products-modal-header {
    padding: 20px;
  }

  .products-modal-header h3 {
    font-size: 1.4rem;
  }

  .products-modal-body {
    padding: 15px;
    max-height: calc(90vh - 80px);
  }

  /* Cards en el modal mobile */
  .modal-cards-grid {
    gap: 15px;
  }

  .modal-cards-grid .industrial-card {
    border-radius: 10px;
  }

  .modal-cards-grid .industrial-card img {
    height: 180px;
  }

  .modal-cards-grid .card-body {
    padding: 15px;
  }

  .modal-cards-grid .card-body h3 {
    font-size: 16px;
  }

  .modal-cards-grid .card-body p {
    font-size: 13px;
  }
}
}

/* Scrollbar personalizado para el modal */
.products-modal-body::-webkit-scrollbar {
  width: 8px;
}

.products-modal-body::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 10px;
}

.products-modal-body::-webkit-scrollbar-thumb {
  background: var(--accent-color);
  border-radius: 10px;
}

.products-modal-body::-webkit-scrollbar-thumb:hover {
  background: #1e7a8f;
}

.industrial-section.section-light .industrial-card {
  background: #ffffff;
  border: 1px solid rgba(47, 159, 184, 0.15);
}

.industrial-section.section-light .industrial-card:hover {
  border-color: rgba(47, 159, 184, 0.4);
  box-shadow: 0 8px 30px rgba(47, 159, 184, 0.2);
}

.industrial-section.section-light .card-body span {
  color: #2f9fb8;
}

.industrial-section.section-light .card-body h3 {
  color: #2f9fb8 !important;
}

.industrial-section.section-light .card-body p {
  color: #666 !important;
}

.industrial-section.section-light #toggleCards {
  background: rgba(47, 159, 184, 0.15);
  border: 1px solid rgba(47, 159, 184, 0.4);
  color: #2f9fb8;
}

.industrial-section.section-light #toggleCards:hover {
  background: #2f9fb8;
  color: white;
  box-shadow: 0 0 15px rgba(47, 159, 184, 0.4);
}

.industrial-section.section-light .card-carousel {
  background: #ffffff;
}

