/* ============================================= */
/* TRIKON - Subcategory Grid Module v9           */
/* Brandfarbe: #04697e                           */
/* ============================================= */

/* ===================== */
/* LAZY LOADING          */
/* ===================== */
.trikon-lazy {
  opacity: 0;
  transition: opacity 0.3s ease;
}

.trikon-loaded,
.trikon-home-icon img:not(.trikon-lazy),
.trikon-catgrid-img img:not(.trikon-lazy) {
  opacity: 1;
}

/* ========================================= */
/* ALTEN KATEGORIE-HEADER AUSBLENDEN         */
/* ========================================= */
body.page-category .category-cover,
body.page-category #category-description,
body.page-category .category-description,
body.page-category #content-wrapper > section > h1:first-of-type,
body.page-category .block-category,
body.page-category .block-category-inner {
  display: none !important;
}

/* PS-Breadcrumb ausblenden (eigene im Hero), Abstand beibehalten */
body.page-category nav.breadcrumb {
  visibility: hidden !important;
  height: 10px !important;
  min-height: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
}

/* ========================= */
/* HERO BANNER               */
/* ========================= */
.trikon-hero {
  position: relative;
  width: 100%;
  min-height: 180px;
  background-color: #0a2a33;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}

.trikon-hero--has-bg {
  min-height: 220px;
}

.trikon-hero-overlay {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.65) 100%);
  z-index: 1;
}

.trikon-hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 2rem 1.8rem;
}

/* Breadcrumb Pills */
.trikon-breadcrumbs {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
  margin-bottom: 0.8rem;
}

.trikon-breadcrumb-pill {
  display: inline-block;
  padding: 0.3rem 0.75rem;
  background: rgba(255,255,255,0.15);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 500;
  border-radius: 20px;
  text-decoration: none;
  transition: background 0.2s ease;
  white-space: nowrap;
}

.trikon-breadcrumb-pill:hover {
  background: rgba(4,105,126,0.7);
  color: #fff;
  text-decoration: none;
}

.trikon-breadcrumb-pill--active {
  background: rgba(4,105,126,0.6);
  cursor: default;
}

.trikon-breadcrumb-sep {
  color: rgba(255,255,255,0.5);
  font-size: 1rem;
}

.trikon-hero-title {
  font-size: 2.2rem;
  font-weight: 700;
  color: #fff;
  margin: 0;
  line-height: 1.2;
  text-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

/* ================================ */
/* SUBCATEGORY GRID (Thomann-Style) */
/* ================================ */
.trikon-catgrid-section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2.5rem 1rem 1.5rem;
}

.trikon-catgrid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1rem 0.5rem;
}

.trikon-catgrid-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 1rem 0.5rem;
  text-decoration: none;
  color: #333;
  border-radius: 8px;
  transition: background 0.15s ease, transform 0.15s ease;
}

.trikon-catgrid-item:hover {
  background: #f5f5f5;
  transform: translateY(-2px);
  text-decoration: none;
  color: #04697e;
}

.trikon-catgrid-img {
  width: 120px;
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.6rem;
}

.trikon-catgrid-img img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.trikon-catgrid-name {
  font-size: 0.88rem;
  font-weight: 500;
  line-height: 1.3;
}

.trikon-catgrid-count {
  font-size: 0.75rem;
  color: #999;
  margin-top: 0.15rem;
}

/* ===================================== */
/* HOMEPAGE KATEGORIEN (Thomann-Style)   */
/* ===================================== */
.trikon-home-categories {
  max-width: 1200px;
  margin: 2.5rem auto;
  padding: 0 15px;
}

.trikon-home-title {
  font-size: 1.6rem;
  font-weight: 700;
  color: #333;
  text-align: center;
  margin-bottom: 1.5rem;
}

.trikon-home-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  border: 1px solid #eee;
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
}

.trikon-home-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.2rem;
  text-decoration: none;
  color: #333;
  border-bottom: 1px solid #eee;
  transition: background 0.15s ease, color 0.15s ease;
}

.trikon-home-item:hover {
  background: rgba(4,105,126,0.04);
  text-decoration: none;
  color: #04697e;
}

.trikon-home-item:nth-child(3n+1),
.trikon-home-item:nth-child(3n+2) {
  border-right: 1px solid #eee;
}

.trikon-home-item:nth-last-child(-n+3) {
  border-bottom: none;
}

.trikon-home-icon {
  width: 56px;
  height: 56px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: 6px;
  background: #f8f8f8;
}

.trikon-home-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.trikon-home-name {
  font-size: 0.95rem;
  font-weight: 500;
  flex: 1;
}

.trikon-home-arrow {
  color: #ccc;
  flex-shrink: 0;
  transition: color 0.15s ease, transform 0.15s ease;
}

.trikon-home-item:hover .trikon-home-arrow {
  color: #04697e;
  transform: translateX(3px);
}

/* ============================================= */
/* RESPONSIVE                                    */
/* ============================================= */
@media (max-width: 1199px) {
  .trikon-catgrid {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (max-width: 991px) {
  .trikon-catgrid {
    grid-template-columns: repeat(3, 1fr);
  }
  .trikon-hero-title {
    font-size: 1.8rem;
  }
  .trikon-home-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .trikon-home-item:nth-child(3n+1),
  .trikon-home-item:nth-child(3n+2) {
    border-right: none;
  }
  .trikon-home-item:nth-child(2n+1) {
    border-right: 1px solid #eee;
  }
  .trikon-home-item:nth-last-child(-n+3) {
    border-bottom: 1px solid #eee;
  }
  .trikon-home-item:nth-last-child(-n+2) {
    border-bottom: none;
  }
}

@media (max-width: 767px) {
  .trikon-hero { min-height: 140px; }
  .trikon-hero--has-bg { min-height: 160px; }
  .trikon-hero-content { padding: 1.5rem 1rem 1.2rem; }
  .trikon-hero-title { font-size: 1.4rem; }
  .trikon-breadcrumb-pill { font-size: 0.7rem; padding: 0.25rem 0.6rem; }
  .trikon-catgrid { grid-template-columns: repeat(3, 1fr); gap: 0.5rem 0; }
  .trikon-catgrid-img { width: 80px; height: 80px; }
  .trikon-catgrid-name { font-size: 0.78rem; }
  .trikon-catgrid-section { padding: 1.5rem 0.5rem 1rem; }
  .trikon-home-grid { grid-template-columns: repeat(2, 1fr); }
  .trikon-home-icon { width: 44px; height: 44px; }
  .trikon-home-name { font-size: 0.85rem; }
}

@media (max-width: 479px) {
  .trikon-catgrid { grid-template-columns: repeat(2, 1fr); }
  .trikon-catgrid-img { width: 70px; height: 70px; }
  .trikon-catgrid-name { font-size: 0.75rem; }
  .trikon-home-grid { grid-template-columns: 1fr; }
  .trikon-home-item:nth-child(2n+1) { border-right: none; }
}
