.now-section,
.section-grid,
.media-faq,
.content-section {
  margin-top: 96px;
}

/* 섹션 제목("궁금하신 제품을 선택하세요")과 카드 사이는 과한 여백 없이 이어지게 */
.category-promo {
  margin-top: 40px;
}

.home-band {
  width: 100%;
  margin-top: 0;
  padding: 94px 20px 104px;
}

.category-promo-section,
.category-tiles-section {
  background: #f4f6fa;
}

/* 홈 카테고리 타일: 대분류별 그룹 + 소분류 타일 그리드 */
.category-tile-group {
  margin-bottom: 40px;
}

.category-tile-group:last-child {
  margin-bottom: 0;
}

.category-tile-group-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.category-tile-group-head h3 {
  margin: 0;
  color: #111114;
  font-size: 22px;
  font-weight: 800;
}

.category-tile-group-head a {
  flex: none;
  color: var(--brand-primary);
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
}

.category-tile-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 18px;
}

.category-tile {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #e7ebf3;
  border-radius: 16px;
  background: #fff;
  /* 회색 섹션 위에서 흰 카드가 또렷이 떠 보이도록 소프트 섀도우 */
  box-shadow: 0 10px 28px rgba(17, 17, 20, 0.07);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.category-tile-thumb {
  display: flex;
  aspect-ratio: 4 / 3;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  /* 이미지 배경을 흰색으로 두어 회색 섹션·회색 썸네일이 뭉개지던 문제 해소 */
  border-bottom: 1px solid #eef1f6;
  background: #fff;
}

.category-tile-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 14px;
}

.category-tile-thumb-empty {
  display: flex;
  width: 64px;
  height: 64px;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #e2e8f4;
  color: var(--brand-primary);
  font-size: 28px;
  font-weight: 800;
}

.category-tile strong {
  padding: 16px 18px;
  color: #111114;
  font-size: 16px;
  font-weight: 700;
}

@media (hover: hover) and (pointer: fine) {
  .category-tile:hover {
    transform: translateY(-4px);
    border-color: var(--brand-primary);
    box-shadow: 0 22px 44px rgba(17, 17, 20, 0.13);
  }
}

/* 최근 본 제품: 가로 스크롤 카드 행 (홈·제품 상세 공통) */
.recent-products-section {
  background: #fff;
}

.recent-products-section[hidden] {
  display: none;
}

.recent-products-viewport {
  position: relative;
}

/* 스크롤이 생길 때만 좌우에 화살표 자리를 확보해 카드와 겹치지 않게 한다. */
.recent-products-viewport.is-scrollable {
  padding: 0 54px;
}

.recent-products-row {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 210px; /* 적은 항목이 늘어나지 않게 고정 폭, 많으면 가로 스크롤 */
  gap: 16px;
  overflow-x: auto;
  /* overflow-x:auto는 세로도 잘라내므로, hover로 카드가 위로 떠도(-4px) 잘리지 않게 여유 */
  padding-top: 8px;
  padding-bottom: 8px;
  scroll-snap-type: x proximity;
  scroll-behavior: smooth;
  scrollbar-width: none; /* 스크롤바는 숨기고 좌/우 화살표로 이동 (Firefox) */
  -ms-overflow-style: none;
}

.recent-products-row::-webkit-scrollbar {
  height: 0;
  width: 0;
}

/* 넘칠 때만 JS가 hidden을 풀어 노출하는 좌/우 이동 화살표 */
.recent-products-arrow {
  position: absolute;
  top: 50%;
  z-index: 3;
  display: inline-flex;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  transform: translateY(-50%);
  border: 1px solid #e2e7f0;
  border-radius: 50%;
  background: #fff;
  color: #111114;
  box-shadow: 0 8px 22px rgba(17, 17, 20, 0.16);
  cursor: pointer;
  transition: background 160ms ease, color 160ms ease, box-shadow 160ms ease, opacity 160ms ease;
}

.recent-products-arrow[hidden] {
  display: none;
}

.recent-products-arrow.is-prev {
  left: 4px;
}

.recent-products-arrow.is-next {
  right: 4px;
}

.recent-products-arrow svg {
  width: 22px;
  height: 22px;
}

@media (hover: hover) and (pointer: fine) {
  .recent-products-arrow:hover {
    background: var(--brand-primary);
    border-color: var(--brand-primary);
    color: #fff;
  }
}

/* 모바일에서는 터치 스크롤을 쓰므로 화살표·좌우 여백 없이 카드를 넓게 쓴다. */
@media (max-width: 768px) {
  .recent-products-viewport.is-scrollable {
    padding: 0;
  }

  .recent-products-arrow {
    display: none !important;
  }
}

.recent-product-card {
  display: flex;
  scroll-snap-align: start;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #e4e8f0;
  border-radius: 14px;
  background: #fff;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.recent-product-thumb {
  display: flex;
  aspect-ratio: 4 / 3;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: #f5f7fb;
}

.recent-product-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 12px;
}

.recent-product-copy {
  display: grid;
  gap: 4px;
  padding: 12px 14px 16px;
}

.recent-product-copy small {
  color: var(--brand-primary);
  font-size: 12px;
  font-weight: 700;
}

.recent-product-copy strong {
  color: #111114;
  font-size: 15px;
  font-weight: 700;
}

@media (hover: hover) and (pointer: fine) {
  .recent-product-card:hover {
    transform: translateY(-4px);
    border-color: var(--brand-primary);
    box-shadow: 0 16px 32px rgba(17, 17, 20, 0.1);
  }
}

.now-section {
  background: #e9edf4;
}

.resource-section {
  background: #f3f7ff;
}

.board-section {
  background: #fff;
}

.home-band > .home-section-title,
.home-band > .headline-block,
.home-band > .category-promo,
.home-band > .category-tile-group,
.home-band > .product-strip,
.home-band > .recent-products-viewport,
.home-band > .media-faq,
.home-band > .board-preview {
  width: min(var(--max), calc(100vw - 40px));
  margin-right: auto;
  margin-left: auto;
}

.home-band .category-promo,
.home-band .product-strip,
.home-band .media-faq,
.home-band .section-grid {
  margin-top: 0;
}

.home-section-title,
.home-band .headline-block {
  margin-bottom: 48px;
  text-align: center;
}

.home-section-title h2 {
  margin: 0;
  color: #000;
  font-size: clamp(32px, 3.1vw, 46px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: 0;
}

.home-band .headline-block p {
  margin: 0 0 12px;
}

.home-band .headline-block span {
  max-width: 760px;
  margin-right: auto;
  margin-left: auto;
}

.headline-block h2,
.section-title span {
  margin: 0;
  color: #000;
  font-size: 35px;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: 0;
}

.headline-block span {
  display: block;
  margin-top: 14px;
  color: #777;
  font-weight: 500;
}

.product-strip {
  display: grid;
  grid-auto-columns: calc((100% - 48px) / 3);
  grid-auto-flow: column;
  gap: 24px;
  overflow: auto hidden;
  overflow-clip-margin: 36px;
  margin-top: 36px;
  padding: 8px 0 30px;
  scroll-snap-type: x proximity;
}

.product-strip::-webkit-scrollbar,
.gnar-maker-logos::-webkit-scrollbar,
.gnar-model-strip::-webkit-scrollbar {
  height: 0;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.product-card {
  position: relative;
  display: grid;
  min-height: 318px;
  grid-template-rows: auto 1fr auto;
  overflow: hidden;
  scroll-snap-align: start;
  border: 1px solid #dce4f2;
  border-radius: 18px;
  background:
    linear-gradient(180deg, #fff 0%, #f9fbff 100%);
  padding: 12px;
  box-shadow:
    0 18px 42px rgba(31, 42, 68, 0.09),
    inset 0 1px 0 rgba(255, 255, 255, 0.78);
  transition:
    border-color 220ms ease,
    transform 260ms ease,
    box-shadow 260ms ease;
}

@media (hover: hover) and (pointer: fine) {
  .product-card:hover {
    border-color: rgba(0, 157, 154, 0.34);
    transform: translateY(-4px);
    box-shadow:
      0 24px 54px rgba(31, 42, 68, 0.16),
      inset 0 1px 0 rgba(255, 255, 255, 0.86);
  }
}

.product-card-media {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border: 0;
  border-radius: 14px;
  /* 이미지가 4:3을 못 채울 때 남는 여백이 흰 배경 제품사진과 구분되지 않도록 순백으로 둔다. */
  background: #fff;
}

.product-card-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  object-fit: contain;
  transition:
    opacity 280ms ease,
    transform 360ms cubic-bezier(0.16, 1, 0.3, 1);
}

.product-card-img.is-hover {
  opacity: 0;
  transform: scale(1.03);
}

@media (hover: hover) and (pointer: fine) {
  .product-card.has-hover-image:hover .product-card-img.is-primary {
    opacity: 0;
    transform: scale(1.035);
  }

  .product-card:not(.has-hover-image):hover .product-card-img.is-primary {
    transform: scale(1.035);
  }

  .product-card:hover .product-card-img.is-hover {
    opacity: 1;
    transform: scale(1.035);
  }
}

.product-card-body {
  display: grid;
  align-content: start;
  padding: 15px 5px 0;
}

.product-card strong {
  display: block;
  color: #111;
  font-size: 18px;
  font-weight: 800;
  line-height: 1.26;
}

.product-card p {
  margin: 10px 0 0;
  color: #515866;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.55;
}

.product-card small {
  display: block;
  margin-top: 10px;
  color: #7a8291;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
}

.product-card-match {
  display: block;
  margin-top: 10px;
  color: #5f6876;
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
  line-height: 1.45;
}

.product-card-match span,
.product-card-match b {
  color: var(--brand-primary-deep);
  font-weight: 900;
}

.product-card-match b::after {
  color: #a0a7b3;
  content: ":";
  margin-right: 4px;
}

.product-search-highlight {
  border-radius: 4px;
  background: #fff2a8;
  color: inherit;
  padding: 0 0.12em;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}

.product-card-link {
  display: inline-flex;
  height: 38px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid #e8edf5;
  color: var(--brand-primary);
  padding: 0 5px;
  font-size: 13px;
  font-weight: 800;
}

.product-card-link i {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 50%;
  background: var(--brand-primary);
  color: #fff;
  font-style: normal;
  transition: transform 220ms ease;
}

@media (hover: hover) and (pointer: fine) {
  .product-card:hover .product-card-link i {
    transform: translateX(3px);
  }
}

.category-promo {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  width: 100%;
  margin-right: auto;
  margin-left: auto;
}

.category-promo .promo-card {
  position: relative;
  display: grid;
  min-height: 328px;
  grid-template-rows: 138px auto;
  align-items: start;
  overflow: hidden;
  border: 1px solid #e7ebf3;
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 16px 34px rgba(18, 31, 67, 0.07);
  color: var(--brand-ink);
  padding: 22px 24px 28px;
  touch-action: manipulation;
  transition: transform 260ms ease, box-shadow 260ms ease, border-color 260ms ease;
}

@media (hover: hover) and (pointer: fine) {
  .category-promo .promo-card:hover {
    border-color: rgba(0, 157, 154, 0.2);
    box-shadow: 0 22px 48px rgba(18, 31, 67, 0.12);
    transform: translateY(-3px);
  }
}

.promo-visual {
  display: flex;
  height: 130px;
  min-width: 0;
  align-items: flex-start;
  justify-content: center;
  overflow: hidden;
  border-radius: 0;
  background: transparent;
}

.promo-illustration {
  display: block;
  max-width: none;
  width: auto;
  height: auto;
  transform-origin: center;
  transform: translateY(var(--promo-offset-y, 0)) scale(var(--promo-hover-scale, 1));
  transition: transform 320ms cubic-bezier(.2, .8, .2, 1);
}

.promo-illustration.signal-icon {
  width: 204px;
  --promo-offset-y: -104px;
}

.promo-illustration.matrix-icon {
  width: 202px;
  --promo-offset-y: -96px;
}

.promo-illustration.support-icon {
  width: 132px;
  --promo-offset-y: 0;
}

.promo-copy {
  max-width: none;
  padding-right: 8px;
  padding-bottom: 48px;
}

.category-promo h3 {
  margin: 0;
  color: #111827;
  font-size: 27px;
  font-weight: 800;
  line-height: 1.25;
}

.category-promo p {
  margin: 12px 0 0;
  color: #4b5563;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.58;
}

.promo-arrow {
  position: absolute;
  right: 24px;
  bottom: 24px;
  display: grid;
  width: 50px;
  height: 50px;
  place-items: center;
  border-radius: 50%;
  background: var(--brand-primary);
  color: #fff;
  font-size: 34px;
  font-weight: 300;
  line-height: .9;
  box-shadow: 0 12px 24px rgba(0, 157, 154, 0.22);
  transform-origin: center;
  transition: transform 320ms cubic-bezier(.2, .8, .2, 1), box-shadow 320ms ease;
}

@media (hover: hover) and (pointer: fine) {
  .category-promo .promo-card:hover .promo-illustration {
    --promo-hover-scale: 1.06;
  }

  .category-promo .promo-card:hover .promo-arrow {
    box-shadow: 0 16px 30px rgba(0, 157, 154, 0.3);
    transform: scale(1.1);
  }
}

.section-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 26px;
}

.section-grid > article,
.notice-panel,
.catalog-panel,
.faq-panel,
.board,
.detail-panel,
.form-card,
.visual-card,
.catalog-card {
  border: 1px solid var(--brand-border);
  border-radius: 0;
  background: #fff;
}

.section-grid > article,
.notice-panel,
.catalog-panel,
.faq-panel,
.detail-panel,
.visual-card {
  padding: 28px;
}

.home-band .section-grid > article,
.home-band .faq-panel {
  border-radius: var(--radius);
}

.main-card-bg {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  min-height: 260px;
  box-shadow: 0 16px 38px rgba(31, 42, 68, 0.06);
}

.media-faq .main-card-bg {
  min-height: 430px;
}

.board-preview .main-card-bg {
  min-height: 250px;
}

.main-card-bg::before {
  position: absolute;
  right: 18px;
  bottom: 12px;
  z-index: -1;
  width: min(260px, 52%);
  aspect-ratio: 1 / 1;
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
  content: "";
  opacity: .24;
  pointer-events: none;
  transform: rotate(-2deg);
  transition: opacity 220ms ease, transform 260ms ease;
}

.main-card-bg::after {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(115deg, rgba(255, 255, 255, 0.98) 0%, rgba(255, 255, 255, 0.9) 58%, rgba(255, 255, 255, 0.5) 100%);
  content: "";
  pointer-events: none;
}

@media (hover: hover) and (pointer: fine) {
  .main-card-bg:hover::before {
    opacity: .32;
    transform: rotate(-2deg) scale(1.04);
  }
}

.notice-card::before {
  background-image: url("../img/legacy/main_notice.png");
}

.news-card::before {
  background-image: url("../img/legacy/main_news.png");
}

.tech-docs-card::before {
  background-image: url("../img/legacy/main_tech_docs.png");
}

.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.section-title a {
  color: var(--brand-primary);
  font-weight: 800;
}

.list-row,
.board-row {
  display: grid;
  gap: 6px 22px;
  padding: 22px 0;
  border-top: 1px solid #e5e8ef;
}

.list-row.has-thumb {
  grid-template-columns: 92px minmax(0, 1fr);
  align-items: center;
}

.list-row-thumb {
  display: block;
  width: 92px;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 10px;
  background: #eef2f7;
}

.list-row-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.list-row-copy {
  display: grid;
  min-width: 0;
  gap: 6px;
}

.list-row:first-of-type,
.board-row:first-child {
  border-top: 0;
}

.list-row strong,
.board-row strong {
  color: #111;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.45;
}

.list-row small,
.board-row small,
.muted {
  color: #777;
}

.list-row p,
.board-row p {
  margin: 0;
  color: #667085;
  font-size: 14px;
  line-height: 1.55;
}

.board-row {
  grid-template-columns: 118px minmax(0, 1fr) minmax(120px, 180px);
  align-items: start;
}

.board-row span {
  grid-column: 1;
  grid-row: 1 / span 2;
  margin-top: 1px;
  justify-self: start;
}

.board-row strong {
  grid-column: 2;
}

.board-row small {
  grid-column: 3;
  grid-row: 1;
  justify-self: end;
  color: #7b8190;
  text-align: right;
}

.board-row p {
  grid-column: 2 / 4;
  grid-row: 2;
}

.empty-state {
  margin: 0;
  color: #777;
  padding: 34px 0;
  text-align: center;
  font-size: 15px;
  font-weight: 700;
}

.catalog-chip,
.file-link,
.tabs a,
.tabs button {
  display: inline-flex;
  width: fit-content;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--brand-border);
  border-radius: 21px;
  background: #fff;
  color: var(--brand-primary);
  padding: 0 16px;
  cursor: pointer;
  font-weight: 800;
}

.tabs button.is-active {
  border-color: var(--brand-primary);
  background: var(--brand-primary);
  color: #fff;
}

.media-faq {
  display: grid;
  grid-template-columns: 610px minmax(0, 1fr);
  gap: 58px;
}

.resource-card {
  min-height: 430px;
}

.resource-card.side-banner strong {
  max-width: 390px;
  font-size: 42px;
}

.resource-card.side-banner p {
  max-width: 410px;
  font-size: 19px;
}

.resource-card .side-docs {
  right: 60px;
  bottom: 16px;
  width: 262px;
  height: 210px;
}

.video-card {
  position: relative;
}

.video-card img {
  width: 100%;
  border-radius: var(--radius);
  box-shadow: 14px 10px 0 rgba(0, 0, 0, 0.18);
}

.video-card > span {
  position: absolute;
  inset: 72px 0 0;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 46px;
}

.sub-hero {
  position: relative;
  border-bottom: 0;
  background: #fff;
  color: #111;
  padding: 18px 0 14px;
}

.sub-hero-heading {
  display: grid;
  gap: 12px;
}

.sub-hero h1 {
  min-width: 0;
  margin: 0;
  color: #111;
  font-size: clamp(30px, 2.8vw, 38px);
  font-weight: 800;
  line-height: 1.16;
}

.sub-hero-path {
  display: flex;
  flex-wrap: wrap;
  justify-self: end;
  justify-content: flex-end;
  align-items: center;
  gap: 6px;
  max-width: 100%;
  margin-bottom: 0;
  color: #7b8190;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.4;
  text-align: right;
}

.sub-hero-path a,
.sub-hero-path strong,
.sub-hero-path span {
  color: inherit;
  font: inherit;
  text-decoration: none;
}

.sub-hero-path a,
.sub-hero-path strong {
  display: inline-flex;
  align-items: center;
}

.sub-hero-path strong {
  color: #111827;
}

.sub-hero-path i {
  position: relative;
  display: block;
  width: 16px;
  height: 15px;
  color: currentColor;
}

.sub-hero-path i::before,
.sub-hero-path i::after {
  position: absolute;
  content: "";
}

.sub-hero-path i::before {
  left: 1px;
  bottom: 0;
  width: 14px;
  height: 10px;
  border: 2px solid currentColor;
  border-top: 0;
}

.sub-hero-path i::after {
  left: 2px;
  top: 0;
  width: 11px;
  height: 11px;
  border-top: 2px solid currentColor;
  border-left: 2px solid currentColor;
  transform: rotate(45deg);
}

.sub-hero p {
  max-width: 820px;
  margin: 14px 0 0;
  color: #5f6674;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.65;
}

.content-section {
  margin: 17px auto 92px;
}

.page-home .content-section {
  width: min(var(--max), calc(100vw - 40px));
}

.sub-hero + .content-section:not(.board-list-section) {
  margin-top: 24px;
}
