/* DG Tech Machinery — supplier banner carousel (Apple-style home page tiles) */
.banners { --mx: 0; --my: 0; background: #fff; padding-bottom: 22px; position: relative; }
.bn-viewport { position: relative; overflow: hidden; }
.bn-track { display: flex; transition: transform 1s cubic-bezier(.65, 0, .2, 1); will-change: transform; }

.bn { flex: 0 0 100%; position: relative; overflow: hidden; min-height: min(84vh, 780px); min-height: min(84svh, 780px);
  display: grid; grid-template-rows: auto 1fr auto; justify-items: center; text-align: center;
  padding: clamp(34px, 6vh, 64px) max(16px, env(safe-area-inset-right, 0px)) 0 max(16px, env(safe-area-inset-left, 0px));
  background:
    radial-gradient(60% 45% at 50% 78%, rgba(41, 171, 226, .16), transparent 70%),
    linear-gradient(180deg, #fff 0%, var(--tint, #eef3f9) 100%); }

/* copy */
.bn-copy { max-width: 820px; display: flex; flex-direction: column; align-items: center; position: relative; z-index: 3; }
.bn-logo { height: 40px; width: auto; max-width: 220px; object-fit: contain; mix-blend-mode: multiply; margin-bottom: 14px; }
.bn-word { font: 900 22px/1 var(--head); letter-spacing: .02em; color: var(--indigo); margin-bottom: 14px; text-transform: uppercase; }
.bn-eyebrow { font: 600 13px/1.3 var(--body); letter-spacing: .14em; text-transform: uppercase; color: var(--cobalt); }
.bn-title { font: 800 clamp(34px, 5.4vw, 70px)/1.04 var(--head); letter-spacing: -0.035em; color: var(--ink); margin-top: 12px; text-wrap: balance; }
.bn-sub { font-size: clamp(16px, 1.6vw, 21px); color: var(--muted); max-width: 640px; margin-top: 12px; text-wrap: balance; }
.bn-ctas { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 22px; }
.bn-link { background: transparent; color: var(--cobalt); padding: 0 14px; }
.bn-link:hover { text-decoration: underline; }

/* product stage */
.bn-stage { position: relative; width: min(1180px, 100%); min-height: 300px; perspective: 1400px; z-index: 2; }
.bn-stage img { position: absolute; object-fit: contain; object-position: center bottom; mix-blend-mode: multiply; pointer-events: none; user-select: none;
  transition: transform 1.1s cubic-bezier(.2, .8, .2, 1), opacity .9s ease; }
.bn-main { left: 20%; width: 60%; bottom: 8%; height: 84%;
  transform: translate3d(calc(var(--mx) * -14px), calc(var(--my) * -8px), 0); filter: drop-shadow(0 26px 24px rgba(15, 40, 100, .16)); z-index: 2; }
.bn-side { width: 27%; height: 52%; bottom: 12%; opacity: .95; z-index: 1; filter: saturate(.95) drop-shadow(0 18px 16px rgba(15, 40, 100, .12)); }
.bn-side.l { left: 0; transform: translate3d(calc(var(--mx) * -26px), 0, -60px) rotateY(16deg); transform-origin: right center; }
.bn-side.r { right: 0; transform: translate3d(calc(var(--mx) * -26px), 0, -60px) rotateY(-16deg); transform-origin: left center; }
.bn-floor { position: absolute; left: 12%; right: 12%; bottom: 4%; height: 40px; border-radius: 50%; background: radial-gradient(closest-side, rgba(15, 40, 100, .16), transparent); z-index: 0; }

/* long, low machines (injection molding): one hero machine, larger */
.bn-wide .bn-side { display: none; }
.bn-wide .bn-main { left: 6%; width: 88%; height: 80%; bottom: 10%; }

/* entry animation each time a slide becomes active */
.bn:not(.is-active) .bn-main { opacity: 0; transform: translate3d(0, 50px, 0) scale(.94); }
.bn:not(.is-active) .bn-side.l { opacity: 0; transform: translate3d(-80px, 20px, -60px) rotateY(16deg); }
.bn:not(.is-active) .bn-side.r { opacity: 0; transform: translate3d(80px, 20px, -60px) rotateY(-16deg); }
.bn.is-active .bn-main { transition-delay: .25s; }
.bn.is-active .bn-side { transition-delay: .45s; }
.bn .bn-copy > * { transition: opacity .7s ease, transform .7s cubic-bezier(.2, .8, .2, 1); }
.bn:not(.is-active) .bn-copy > * { opacity: 0; transform: translateY(18px); }
.bn.is-active .bn-copy > :nth-child(2) { transition-delay: .08s; }
.bn.is-active .bn-copy > :nth-child(3) { transition-delay: .14s; }
.bn.is-active .bn-copy > :nth-child(4) { transition-delay: .2s; }
.bn.is-active .bn-copy > :nth-child(5) { transition-delay: .26s; }

/* series chips along the bottom */
.bn-chips { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; padding: 0 0 22px; position: relative; z-index: 3; }
.bn-chips span { font: 600 12.5px/1 var(--body); color: var(--indigo); background: rgba(255, 255, 255, .8); border: 1px solid rgba(15, 75, 161, .12); padding: 8px 12px; border-radius: 999px; backdrop-filter: blur(8px); }

/* arrows */
.bn-arrow { position: absolute; top: 50%; transform: translateY(-50%); z-index: 4; width: 52px; height: 52px; border-radius: 50%; border: 0; cursor: pointer;
  background: rgba(255, 255, 255, .85); color: var(--ink); font: 400 32px/1 var(--body); box-shadow: var(--shadow); backdrop-filter: blur(10px);
  opacity: 0; transition: opacity .3s, transform .3s; }
.bn-arrow.prev { left: max(16px, env(safe-area-inset-left, 0px)); }
.bn-arrow.next { right: max(16px, env(safe-area-inset-right, 0px)); }
.bn-viewport:hover .bn-arrow, .bn-arrow:focus-visible { opacity: 1; }
.bn-arrow:hover { transform: translateY(-50%) scale(1.06); }

/* supplier tabs with progress */
.bn-nav { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 16px max(16px, env(safe-area-inset-right, 0px)) 0 max(16px, env(safe-area-inset-left, 0px)); }
.bn-tabs { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding: 4px; background: #f1f4f8; border-radius: 999px; max-width: 100%; }
.bn-tabs::-webkit-scrollbar { display: none; }
.bn-tabs button { position: relative; flex: none; border: 0; background: transparent; cursor: pointer; font: 600 13px/1 var(--body); color: #4a5060;
  padding: 10px 14px; border-radius: 999px; overflow: hidden; min-height: 36px; transition: background .3s, color .3s; }
.bn-tabs button:hover { color: var(--ink); }
.bn-tabs button.on { background: #fff; color: var(--ink); box-shadow: 0 1px 3px rgba(16, 24, 64, .12); }
.bn-tabs button i { position: absolute; left: 14px; right: 14px; bottom: 5px; height: 2px; border-radius: 2px; background: rgba(15, 75, 161, .12); opacity: 0; }
.bn-tabs button.on i { opacity: 1; }
.bn-tabs button i::after { content: ""; position: absolute; inset: 0; border-radius: 2px; background: var(--grad); transform-origin: left; transform: scaleX(0); }
.banners.bn-tick .bn-tabs button.on i::after { animation: bnFill var(--bn-dur) linear forwards; }
.banners:not(.bn-playing) .bn-tabs button.on i::after { animation-play-state: paused; }
@keyframes bnFill { to { transform: scaleX(1); } }
.bn-pause { flex: none; width: 40px; height: 40px; border-radius: 50%; border: 0; background: #f1f4f8; cursor: pointer; display: grid; place-items: center; }
.bn-pause span { width: 10px; height: 12px; border-left: 3px solid var(--ink); border-right: 3px solid var(--ink); }
.bn-pause.paused span { width: 0; height: 0; border: 0; border-left: 11px solid var(--ink); border-top: 7px solid transparent; border-bottom: 7px solid transparent; margin-left: 3px; }

@media (max-width: 760px) {
  .bn { min-height: 640px; padding-top: 28px; }
  .bn-logo { height: 26px; margin-bottom: 10px; }
  .bn-eyebrow { font-size: 11px; }
  .bn-sub { font-size: 15px; }
  .bn-ctas .btn { min-height: 42px; padding: 0 18px; font-size: 15px; }
  .bn-stage { min-height: 230px; }
  .bn-main, .bn-wide .bn-main { left: 4%; width: 92%; height: 78%; bottom: 10%; }
  .bn-side { width: 34%; height: 34%; bottom: 4%; opacity: .9; }
  .bn-side.l { left: -6%; } .bn-side.r { right: -6%; }
  .bn-chips { padding-bottom: 16px; gap: 6px; }
  .bn-chips span { font-size: 11px; padding: 6px 9px; }
  .bn-chips span:nth-child(n+4) { display: none; }
  .bn-arrow { display: none; }
  .bn-tabs { background: transparent; gap: 2px; padding: 0; }
  .bn-tabs button { padding: 0; width: 22px; min-height: 24px; }
  .bn-tabs button .bn-tab-name { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .bn-tabs button i { opacity: 1; left: 7px; right: 7px; top: 9px; bottom: auto; height: 6px; border-radius: 3px; background: #cdd6e3; transition: left .3s, right .3s; }
  .bn-tabs button.on { background: transparent; box-shadow: none; width: 40px; }
  .bn-tabs button.on i { left: 4px; right: 4px; }
  .bn-tabs button i::after { border-radius: 3px; }
}
@media (prefers-reduced-motion: reduce) {
  .bn-track, .bn-stage img, .bn .bn-copy > * { transition: none !important; }
}

/* Bigger side machines (desktop & tablet) */
@media (min-width: 761px) {
  .bn-stage { min-height: clamp(300px, 36vh, 360px); }
  .bn-main { left: 23%; width: 54%; }
  .bn-side { width: 36%; height: 78%; bottom: 8%; }
  .bn-side.l { left: -3%; } .bn-side.r { right: -3%; }
}
/* Phones: larger side machines peeking in from the edges */
@media (max-width: 760px) {
  .bn-side { width: 44%; height: 46%; bottom: 4%; }
  .bn-side.l { left: -10%; } .bn-side.r { right: -10%; }
}

/* Supplier logos at twice the size */
.bn-logo { height: 80px; max-width: 440px; margin-bottom: 18px; }
.bn-word { font-size: 44px; margin-bottom: 18px; }
@media (max-width: 760px) { .bn-logo { height: 52px; max-width: 300px; margin-bottom: 12px; } .bn-word { font-size: 32px; } }

/* One-line keyword tagline under each banner heading */
.bn-sub { font-weight: 600; color: var(--cobalt); max-width: none; }
@media (min-width: 761px) { .bn-sub { white-space: nowrap; } }

/* OUGE: larger side machines */
@media (min-width: 761px) { #bn-ouge .bn-side { width: 34%; height: 86%; bottom: 6%; } #bn-ouge .bn-side.l { left: 2%; } #bn-ouge .bn-side.r { right: 2%; } }
@media (max-width: 760px) { #bn-ouge .bn-side { width: 46%; height: 56%; } }

/* ================= Banner layout v3 =================
   Machines sit side by side (never overlapping) and are ~1.5x larger;
   smaller heading; no eyebrow line under the logo. */
.bn-eyebrow { display: none; }
.bn-title { font-size: clamp(28px, 3.4vw, 46px); margin-top: 4px; }
.bn-sub { margin-top: 8px; }
.bn-ctas { margin-top: 16px; }
.bn-stage { display: flex; align-items: flex-end; justify-content: center; gap: 2.5%;
  width: min(1320px, 96%); height: clamp(360px, 52vh, 500px); min-height: 0; margin-top: 8px; perspective: none; }
.bn-stage img, .bn-wide .bn-stage img { position: static; inset: auto; left: auto; right: auto; bottom: auto; min-width: 0; object-fit: contain; object-position: center bottom; }
.bn-stage .bn-main { order: 2; flex: 0 1 46%; width: 46%; height: 100%; transform: translate3d(calc(var(--mx) * -8px), 0, 0); }
.bn-stage .bn-side { flex: 0 1 25%; width: 25%; height: 80%; opacity: 1; }
.bn-stage .bn-side.l { order: 1; left: auto; transform: translate3d(calc(var(--mx) * -5px), 0, 0); }
.bn-stage .bn-side.r { order: 3; right: auto; transform: translate3d(calc(var(--mx) * -5px), 0, 0); }
.bn-wide .bn-stage .bn-main { flex-basis: 92%; width: 92%; height: 100%; }
#bn-ouge .bn-stage .bn-side { width: 25%; height: 80%; }
/* entrance animation without overlap */
.bn:not(.is-active) .bn-stage .bn-main { opacity: 0; transform: translate3d(0, 40px, 0) scale(.96); }
.bn:not(.is-active) .bn-stage .bn-side.l { opacity: 0; transform: translate3d(-50px, 20px, 0); }
.bn:not(.is-active) .bn-stage .bn-side.r { opacity: 0; transform: translate3d(50px, 20px, 0); }
.bn-floor { left: 4%; right: 4%; bottom: -6px; }
@media (max-width: 760px) {
  .bn-title { font-size: clamp(24px, 7vw, 30px); }
  .bn-stage { height: clamp(220px, 40vh, 320px); width: 100%; gap: 0; }
  .bn-stage .bn-side, #bn-ouge .bn-stage .bn-side { display: none; }   /* phones: one big machine, no overlap */
  .bn-stage .bn-main, .bn-wide .bn-stage .bn-main { flex-basis: 96%; width: 96%; height: 100%; }
}

/* ================= Banner fits the screen =================
   Banner + supplier tabs fill exactly one screen under the header, so the logo is
   never pushed off the top and nothing needs scrolling. The machines shrink to fit. */
.bn { min-height: 0; height: clamp(500px, calc(100vh - 196px), 860px); height: clamp(500px, calc(100svh - 196px), 860px);
  grid-template-rows: auto minmax(0, 1fr) auto; padding-top: clamp(18px, 3.5vh, 44px); }
.bn-stage { height: 100%; max-height: 520px; align-self: end; }
.banners { padding-bottom: 12px; }
@media (max-height: 820px) and (min-width: 761px) {
  .bn-logo { height: 62px; margin-bottom: 10px; }
  .bn-word { font-size: 34px; margin-bottom: 10px; }
  .bn-title { font-size: clamp(26px, 3vw, 38px); }
  .bn-ctas { margin-top: 12px; }
  .bn-chips { padding-bottom: 14px; }
}
@media (max-width: 760px) {
  .bn { height: auto; min-height: 0; }
  .bn-stage { height: clamp(220px, 38vh, 320px); }
}

/* ================= Banner layout v4: bigger machines =================
   Compact text block, machines share the row by weight (main = 1.7x a side),
   any number of side machines, never overlapping. */
@media (min-width: 761px) {
  .bn { padding-top: clamp(14px, 2.6vh, 34px); }
  .bn-logo { height: 66px; margin-bottom: 8px; }
  .bn-word { font-size: 36px; margin-bottom: 8px; }
  .bn-title { font-size: clamp(26px, 2.8vw, 40px); }
  .bn-sub { font-size: clamp(15px, 1.25vw, 18px); margin-top: 4px; }
  .bn-ctas { margin-top: 12px; }
  .bn-ctas .btn { min-height: 44px; }
  .bn-stage { width: min(1480px, 98%); max-height: 640px; gap: 1.6%; margin-top: 4px; }
  .bn-stage .bn-main { flex: 1.7 1 0; width: auto; height: 100%; }
  .bn-stage .bn-side, #bn-ouge .bn-stage .bn-side { flex: 1 1 0; width: auto; height: 92%; }
  .bn-wide .bn-stage .bn-main { flex: 1 1 0; }
  .bn-chips { padding-bottom: 10px; margin-top: 6px; }
  #bn-smanl .bn-stage .bn-side { height: 86%; }
}
@media (max-height: 820px) and (min-width: 761px) {
  .bn-logo { height: 52px; }
  .bn-title { font-size: clamp(24px, 2.4vw, 32px); }
}
