.dtbg-grid,
.dtbg-grid * {
  box-sizing: border-box;
}

.dtbg-grid {
  --dtbg-gap: 14px;
  display: grid;
  /* 1210×840 main artwork beside a square 2×2 banner panel. */
  grid-template-columns: minmax(0, 1.44fr) minmax(360px, 1fr);
  gap: var(--dtbg-gap);
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0;
}

.dtbg-main,
.dtbg-small {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  background: #f6f6f6;
}

.dtbg-main {
  min-height: 0;
  aspect-ratio: 1210 / 840;
}

.dtbg-slider,
.dtbg-slide,
.dtbg-banner-link {
  display: block;
  width: 100%;
  height: 100%;
}

.dtbg-banner-link {
  cursor: pointer;
}

.dtbg-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity .55s ease, visibility .55s ease;
}

.dtbg-slide.is-active {
  opacity: 1;
  visibility: visible;
  z-index: 1;
}

.dtbg-main-image,
.dtbg-small-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.dtbg-small-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: var(--dtbg-gap);
  min-height: 0;
  aspect-ratio: 1 / 1;
}

.dtbg-small {
  min-height: 0;
}

.dtbg-small > span {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  min-height: 140px;
  color: #777;
  font: 600 13px/1.4 Arial, sans-serif;
}

.dtbg-arrow {
  position: absolute;
  top: 50%;
  z-index: 3;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, .62);
  color: #fff;
  font-size: 30px;
  line-height: 36px;
  cursor: pointer;
  transform: translateY(-50%);
  transition: background .2s ease, transform .2s ease;
}

.dtbg-arrow:hover,
.dtbg-arrow:focus-visible {
  background: #e84a16;
  transform: translateY(-50%) scale(1.05);
}

.dtbg-prev { left: 14px; }
.dtbg-next { right: 14px; }

.dtbg-dots {
  position: absolute;
  left: 50%;
  bottom: 14px;
  z-index: 3;
  display: flex;
  gap: 8px;
  transform: translateX(-50%);
}

.dtbg-dot {
  width: 9px;
  height: 9px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, .85);
  border-radius: 50%;
  background: rgba(0, 0, 0, .32);
  cursor: pointer;
  transition: width .2s ease, border-radius .2s ease, background .2s ease;
}

.dtbg-dot.is-active {
  width: 25px;
  border-radius: 10px;
  background: #e84a16;
}

.dtbg-empty {
  padding: 20px;
  border: 1px dashed #aaa;
  border-radius: 8px;
  background: #fafafa;
  color: #555;
  text-align: center;
}

@media (max-width: 900px) {
  .dtbg-grid {
    grid-template-columns: 1fr;
  }

  .dtbg-small-grid {
    aspect-ratio: 2 / 1;
  }
}

@media (max-width: 600px) {
  .dtbg-grid {
    --dtbg-gap: 9px;
  }

  .dtbg-main,
  .dtbg-small {
    border-radius: 9px;
  }

  .dtbg-small-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: repeat(2, minmax(0, 1fr));
    aspect-ratio: 1 / 1;
  }

  .dtbg-arrow {
    width: 34px;
    height: 34px;
    font-size: 25px;
    line-height: 30px;
  }

  .dtbg-prev { left: 8px; }
  .dtbg-next { right: 8px; }
  .dtbg-dots { bottom: 9px; }
}

@media (prefers-reduced-motion: reduce) {
  .dtbg-slide,
  .dtbg-arrow,
  .dtbg-dot {
    transition: none;
  }
}
