/* Enclosed catalog list & detail pages */

.enclosed-catalog-page {
  padding-top: 0;
}

.enclosed-intro {
  max-width: 820px;
  margin-bottom: 28px;
  line-height: 1.75;
  color: var(--text-body);
  font-size: 15px;
}

.enclosed-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 16px;
  align-items: flex-end;
  margin-bottom: 20px;
  padding: 16px 20px;
  background: var(--bg-section);
  border-radius: 8px;
  border: 1px solid var(--border-light);
}

.enclosed-filters label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-gray);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.enclosed-filters select,
.enclosed-filters input[type="search"] {
  min-width: 120px;
  padding: 8px 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 14px;
  background: #fff;
}

.enclosed-filters input[type="search"] {
  min-width: 200px;
}

.enclosed-filter-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

.enclosed-reset-btn {
  padding: 8px 14px;
  border: 1px solid #ccc;
  background: #fff;
  border-radius: 4px;
  font-size: 13px;
  cursor: pointer;
}

.enclosed-reset-btn:hover {
  border-color: var(--main-color);
  color: var(--main-color);
}

.enclosed-result-count {
  font-size: 14px;
  color: var(--text-gray);
  margin-bottom: 12px;
}

.enclosed-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border-light);
  border-radius: 8px;
  background: #fff;
}

.enclosed-catalog-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  table-layout: auto;
}

.enclosed-catalog-table th {
  background: #f5f5f5;
  padding: 12px 14px;
  text-align: left;
  font-weight: 600;
  white-space: normal;
  line-height: 1.35;
  border-bottom: 2px solid #e0e0e0;
}

.enclosed-catalog-table td {
  padding: 10px 14px;
  border-bottom: 1px solid #eee;
  vertical-align: middle;
  white-space: normal;
  line-height: 1.4;
  overflow-wrap: anywhere;
}

.enclosed-catalog-table tbody tr:hover {
  background: #fffaf5;
}

.catalog-code-link {
  color: var(--main-color);
  font-weight: 600;
  text-decoration: none;
}

.catalog-code-link:hover {
  text-decoration: underline;
}

.catalog-view-link {
  font-size: 12px;
  color: var(--main-color);
  font-weight: 600;
}

.enclosed-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 24px;
}

.catalog-page-btn {
  padding: 8px 16px;
  border: 1px solid var(--main-color);
  background: #fff;
  color: var(--main-color);
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
}

.catalog-page-btn:hover {
  background: var(--main-color);
  color: #fff;
}

.catalog-page-info {
  font-size: 14px;
  color: var(--text-gray);
}

/* Detail page */
.enclosed-detail-page .product-breadcrumb {
  margin-bottom: 24px;
}

.enclosed-detail-meta {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 12px;
  margin-bottom: 28px;
}

.enclosed-detail-meta div {
  background: #fff;
  border: 1px solid #eee;
  border-radius: 8px;
  padding: 14px 16px;
}

.enclosed-detail-meta dt {
  font-size: 11px;
  color: #888;
  margin: 0 0 4px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.enclosed-detail-meta dd {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: #222;
}

.enclosed-related {
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid #eee;
}

.enclosed-related h2 {
  font-size: 18px;
  margin-bottom: 12px;
}

.enclosed-related ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
}

.enclosed-related a {
  color: var(--main-color);
  font-size: 14px;
}

.enclosed-related-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
}

.enclosed-related-list .related-r {
  color: var(--text-gray);
  font-size: 13px;
}

.product-media-block {
  margin-bottom: 28px;
  background: #f7f8fa;
  border: 1px solid var(--border-light);
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  min-height: 0;
  height: auto;
  box-sizing: border-box;
}

.product-hero-meta {
  margin-bottom: 20px;
  padding: 20px 24px;
  background: #fff;
  border: 1px solid var(--border-light);
  border-radius: 8px;
}

.product-hero-meta-list {
  margin: 0;
}

.product-hero-meta-row {
  display: grid;
  grid-template-columns: minmax(88px, 120px) 1fr;
  gap: 8px 20px;
  align-items: start;
}

.product-hero-meta-row + .product-hero-meta-row {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border-light);
}

.product-hero-meta-row dt {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-gray);
  line-height: 1.5;
}

.product-hero-meta-row dd {
  margin: 0;
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-body);
}

.product-hero-model {
  font-size: 18px;
  font-weight: 700;
  color: var(--main-color);
  line-height: 1.45;
  word-break: break-word;
}

.product-hero-code {
  font-family: inherit;
  letter-spacing: 0.01em;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.55;
}

.product-hero-desc {
  color: var(--text-dark);
}

@media (max-width: 640px) {
  .product-hero-meta-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }
}

.product-intro-block {
  margin-bottom: 28px;
  line-height: 1.75;
  color: var(--text-body);
}

.product-intro-block p {
  margin: 0 0 12px;
}

.enclosed-overview-section-title {
  margin-top: 4px;
}

.enclosed-overview-list {
  margin: 0 0 16px;
  padding-left: 1.25em;
  line-height: 1.75;
}

.enclosed-overview-list li {
  margin-bottom: 8px;
}

.enclosed-data-note {
  font-size: 14px;
  color: var(--text-gray);
  margin-top: 8px;
}

.enclosed-spec-intro {
  font-size: 14px;
  color: var(--text-gray);
  margin: 0 0 20px;
}

.enclosed-specs-wrap {
  margin-top: 8px;
}

.enclosed-hi-spec {
  margin-bottom: 32px;
}

.enclosed-hi-spec-title {
  font-size: 16px;
  font-weight: 600;
  margin: 0 0 12px;
  color: var(--text-dark);
}

.enclosed-hi-count {
  font-weight: 400;
  font-size: 14px;
  color: var(--text-gray);
}

.spec-table-scroll {
  overflow-x: auto;
  border: 1px solid var(--border-light);
  border-radius: 8px;
  background: #fff;
}

.enclosed-spec-table-wrap {
  border: 1px solid var(--border-light);
  border-radius: 8px;
  background: #fff;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.enclosed-spec-table {
  margin: 0;
}

.enclosed-detail-page .enclosed-spec-table--compact,
.enclosed-category-page .enclosed-spec-table--compact {
  width: 100%;
  min-width: 680px;
  font-size: 13px;
  table-layout: auto;
}

.enclosed-detail-page .enclosed-spec-table--compact thead th,
.enclosed-category-page .enclosed-spec-table--compact thead th {
  padding: 10px 8px;
  font-size: 12px;
  text-align: center;
  white-space: normal;
  line-height: 1.35;
  vertical-align: bottom;
}

.enclosed-detail-page .enclosed-spec-table--compact tbody td,
.enclosed-category-page .enclosed-spec-table--compact tbody td {
  padding: 9px 8px;
  text-align: center;
  white-space: normal;
  line-height: 1.4;
  vertical-align: middle;
  overflow-wrap: anywhere;
}

.enclosed-detail-page .enclosed-spec-table--compact .col-code,
.enclosed-category-page .enclosed-spec-table--compact .col-code {
  text-align: left;
  font-size: 12px;
  word-break: break-all;
  white-space: normal;
  line-height: 1.35;
  padding-left: 8px;
  padding-right: 4px;
}

.enclosed-detail-page .enclosed-spec-table--compact th:nth-child(1),
.enclosed-detail-page .enclosed-spec-table--compact td:nth-child(1),
.enclosed-category-page .enclosed-spec-table--compact th:nth-child(1),
.enclosed-category-page .enclosed-spec-table--compact td:nth-child(1) {
  width: 1%;
  max-width: 10.5em;
  min-width: 9em;
}

.enclosed-detail-page .enclosed-spec-table--compact th:nth-child(n+2):nth-child(-n+7),
.enclosed-detail-page .enclosed-spec-table--compact td:nth-child(n+2):nth-child(-n+7),
.enclosed-category-page .enclosed-spec-table--compact th:nth-child(n+2):nth-child(-n+7),
.enclosed-category-page .enclosed-spec-table--compact td:nth-child(n+2):nth-child(-n+7) {
  width: 1%;
  white-space: nowrap;
  padding-left: 5px;
  padding-right: 5px;
}

.enclosed-detail-page .enclosed-spec-table--compact th:nth-child(8),
.enclosed-detail-page .enclosed-spec-table--compact td:nth-child(8),
.enclosed-category-page .enclosed-spec-table--compact th:nth-child(8),
.enclosed-category-page .enclosed-spec-table--compact td:nth-child(8) {
  min-width: 4.75em;
  white-space: normal;
}

.enclosed-detail-page .enclosed-spec-table--compact th:nth-child(9),
.enclosed-detail-page .enclosed-spec-table--compact td:nth-child(9),
.enclosed-category-page .enclosed-spec-table--compact th:nth-child(9),
.enclosed-category-page .enclosed-spec-table--compact td:nth-child(9) {
  min-width: 9.5em;
  white-space: normal;
}

.enclosed-detail-page .enclosed-spec-table--compact th:nth-child(10),
.enclosed-detail-page .enclosed-spec-table--compact td:nth-child(10),
.enclosed-category-page .enclosed-spec-table--compact th:nth-child(10),
.enclosed-category-page .enclosed-spec-table--compact td:nth-child(10) {
  min-width: 4.75em;
  white-space: nowrap;
}

.enclosed-detail-page .enclosed-specs-wrap,
.enclosed-category-page .enclosed-specs-wrap {
  overflow: visible;
}

@media (max-width: 1100px) {
  .enclosed-detail-page .enclosed-spec-table--compact,
  .enclosed-category-page .enclosed-spec-table--compact {
    font-size: 12px;
  }

  .enclosed-detail-page .enclosed-spec-table--compact .col-code,
  .enclosed-category-page .enclosed-spec-table--compact .col-code {
    font-size: 11px;
  }
}

.enclosed-hi-nav .enclosed-nav-count {
  font-size: 12px;
  color: var(--text-gray);
  font-weight: 400;
}

.enclosed-hi-nav .product-model-link.active {
  color: var(--main-color);
  font-weight: 700;
}

.enclosed-product-note {
  margin-top: -12px;
  margin-bottom: 24px;
}

.enclosed-product-note p {
  margin: 0;
  line-height: 1.75;
  color: var(--text-body);
}

.enclosed-detail-page .enclosed-spec-table-wrap {
  overflow-x: auto;
}

.enclosed-category-page .enclosed-spec-table-wrap {
  max-height: 520px;
  overflow-y: auto;
}

.enclosed-code-nav {
  max-height: 480px;
  overflow-y: auto;
}

.enclosed-code-nav .product-model-link {
  font-size: 12px;
  word-break: break-all;
}

.enclosed-hi-index-wrap {
  margin-top: 8px;
}

.enclosed-hi-index-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.enclosed-hi-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 16px 18px;
  border: 1px solid var(--border-light);
  border-radius: 8px;
  background: #fff;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.enclosed-hi-card:hover {
  border-color: var(--main-color);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.enclosed-hi-card-value {
  font-size: 16px;
  font-weight: 600;
  color: var(--main-color);
}

.enclosed-hi-card-count {
  font-size: 13px;
  color: var(--text-gray);
}

.enclosed-back-series {
  margin-top: 24px;
}

.enclosed-hi-page .product-model-code {
  font-size: 20px;
  font-weight: 700;
  margin: 0 0 4px;
}

.enclosed-category-page .product-media-block img,
.product-media-block img {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  margin: 0;
  padding: 0;
}

.enclosed-detail-meta--side {
  margin-bottom: 20px;
}

.enclosed-back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 20px;
  color: var(--main-color);
  font-weight: 600;
  text-decoration: none;
  font-size: 14px;
}

.enclosed-back-link:hover {
  text-decoration: underline;
}

@media (max-width: 768px) {
  .enclosed-filters {
    flex-direction: column;
    align-items: stretch;
  }
  .enclosed-filters label {
    width: 100%;
  }
  .enclosed-filters select,
  .enclosed-filters input[type="search"] {
    width: 100%;
  }
}

/* Hi sidebar + product grid (catalog levels 1–2) */
.enclosed-catalog-page {
  padding-top: 24px;
  padding-bottom: 48px;
}

.enclosed-catalog-layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 32px;
  align-items: start;
}

.enclosed-catalog-layout--sidebar-only {
  grid-template-columns: minmax(0, 320px);
}

.enclosed-hi-sidebar {
  position: sticky;
  top: 88px;
  background: #fff;
  border: 1px solid var(--border-light);
  border-radius: 8px;
  padding: 16px 0;
}

.enclosed-hi-sidebar-title {
  margin: 0 16px 12px;
  font-size: 14px;
  font-weight: 700;
  color: var(--main-color);
  line-height: 1.4;
}

.enclosed-hi-nav {
  list-style: none;
  margin: 0;
  padding: 0;
}

.enclosed-hi-link {
  display: block;
  padding: 10px 16px;
  font-size: 14px;
  color: var(--text-body);
  text-decoration: none;
  border-left: 3px solid transparent;
  line-height: 1.45;
}

.enclosed-hi-link:hover {
  background: var(--main-color-light);
  color: var(--main-color);
}

.enclosed-hi-link.active {
  background: var(--main-color-light);
  color: var(--main-color);
  border-left-color: var(--main-color);
  font-weight: 600;
}

.enclosed-hi-count {
  color: var(--text-gray);
  font-weight: 400;
  font-size: 12px;
}

.enclosed-series-lead {
  font-size: 15px;
  line-height: 1.75;
  color: var(--text-body);
  margin: 0 0 12px;
}

.enclosed-series-hint {
  font-size: 14px;
  color: var(--text-gray);
  margin: 0 0 32px;
  line-height: 1.65;
}

.enclosed-hi-section {
  margin-bottom: 48px;
  padding-bottom: 40px;
  border-bottom: 1px solid var(--border-light);
  scroll-margin-top: 96px;
}

.enclosed-hi-section:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.enclosed-hi-section-head {
  margin-bottom: 20px;
}

.enclosed-hi-section-title {
  margin: 0 0 6px;
  font-size: 20px;
  font-weight: 700;
  color: var(--text-dark);
}

.enclosed-hi-section-title a {
  color: inherit;
  text-decoration: none;
}

.enclosed-hi-section-title a:hover {
  color: var(--main-color);
}

.enclosed-hi-section-meta {
  margin: 0;
  font-size: 13px;
  color: var(--text-gray);
  line-height: 1.5;
}

.enclosed-hi-section-meta a {
  color: var(--main-color);
  font-weight: 600;
  text-decoration: none;
}

.enclosed-hi-section-meta a:hover {
  text-decoration: underline;
}

.enclosed-grid-toolbar {
  margin-bottom: 8px;
}

.enclosed-grid-heading {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  color: var(--text-dark);
}

.enclosed-hi-lead {
  margin: 0 0 20px;
  font-size: 14px;
  color: var(--text-gray);
  line-height: 1.6;
}

.enclosed-product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 24px;
}

.enclosed-grid-card {
  background: #fff;
  border: 1px solid var(--border-light);
  border-radius: 8px;
  overflow: hidden;
  transition: box-shadow 0.2s, border-color 0.2s;
}

.enclosed-grid-card:hover {
  border-color: var(--main-color);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.enclosed-grid-card-link {
  display: block;
  color: inherit;
  text-decoration: none;
}

.enclosed-grid-card-media {
  background: #f7f8fa;
  padding: 24px 20px;
  min-height: 168px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}

.enclosed-grid-card-media img {
  width: auto;
  height: auto;
  max-width: 100%;
  display: block;
}

.enclosed-grid-card-body {
  padding: 14px 16px 16px;
}

.enclosed-grid-card-title {
  margin: 0 0 8px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.45;
  color: var(--text-dark);
}

.enclosed-grid-card-meta {
  margin: 0 0 10px;
  font-size: 12px;
  color: var(--text-gray);
  line-height: 1.5;
}

.enclosed-grid-card-model {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  color: var(--main-color);
}

.enclosed-grid-card-model span {
  color: var(--text-gray);
  font-weight: 400;
}

.page-banner--compact {
  padding: 32px 0;
}

@media (max-width: 900px) {
  .enclosed-catalog-layout {
    grid-template-columns: 1fr;
  }

  .enclosed-hi-sidebar {
    position: static;
  }

  .enclosed-hi-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    padding: 0 12px 8px;
  }

  .enclosed-hi-nav li {
    flex: 1 1 auto;
  }

  .enclosed-hi-link {
    border-left: none;
    border-radius: 4px;
    padding: 8px 12px;
    border: 1px solid var(--border-light);
  }

  .enclosed-hi-link.active {
    border-color: var(--main-color);
  }
}

.product-media-block--placeholder .product-skeleton-media {
  min-height: 360px;
  margin: 0;
  border: none;
  border-radius: 0;
}

.enclosed-grid-card-media--placeholder .product-skeleton-media {
  min-height: 180px;
  margin: 0;
  border: none;
  border-radius: 0;
  aspect-ratio: 4 / 3;
}
