/* Pretendard is declared once in styles.css (variable font, all weights). */
/* +150svh at the top of the hero is the scroll track for the three printed sheets. */
.home-content[data-scroll-motion] > #home { min-height: 630svh; }
#home .hero-stage { isolation: isolate; }
#home-title { position: relative; z-index: 3; }
#home .hero-connector { background: transparent; }
/* All four hero scenes share one centered, rounded viewport. */
#home .hero-media-frame {
  position: absolute; z-index: -1; pointer-events: none;
  left: var(--film-left, 15%); top: var(--film-top, 20%);
  width: var(--film-width, 70%); aspect-ratio: 1916 / 1080;
  border-radius: clamp(20px, 2.5vw, 36px); overflow: clip;
  background: #f5f5f5;
  opacity: var(--payment-frame-opacity, 1);
  visibility: visible;
  transform: translateY(var(--media-settle-y, 0px));
}
#home[data-media-hidden] .hero-media-frame { visibility: hidden; }
/* Rotated video and the oversized dial must not paint into an adjacent scene. */
#home :is(.hero-print-film, .hero-payment-panel, .hero-procurement-panel, .hero-stock-panel) {
  overflow: clip;
  isolation: isolate;
}
#home .hero-print-film {
  position: absolute; inset: 0;
  transform: translateY(var(--film-exit-y, 0px));
  will-change: transform;
}
#home[data-film-hidden] .hero-print-film { visibility: hidden; }
.hero-print-scene { position: absolute; inset: 0; }
.hero-print-video, .hero-print-fallback {
  display: block; width: 100%; height: 100%; object-fit: fill;
}
.hero-print-fallback { position: absolute; inset: 0; visibility: hidden; }
#home[data-video-fallback] .hero-print-fallback { visibility: visible; }
#home .hero-payment-panel {
  --hero-connector-width: var(--payment-ui-width, 260px);
  --hero-font-size: var(--payment-font-size, 56px);
  position: absolute; inset: 0;
  background: #f5f5f5;
  transform: translateY(var(--payment-enter-y, 100%));
  visibility: hidden; will-change: transform;
  font-family: 'Pretendard', sans-serif;
}
#home[data-payment-screen] .hero-payment-panel { visibility: visible; }
#home .hero-procurement-panel {
  position: absolute; inset: 0;
  background: #f5f5f5;
  transform: translateY(var(--procurement-enter-y, 100%));
  visibility: hidden; will-change: transform;
}
#home[data-procurement-screen] .hero-procurement-panel { visibility: visible; }
.hero-conveyor-video, .hero-conveyor-fallback {
  position: absolute;
  left: calc(50% - var(--conveyor-center-offset, 0px)); top: 50%;
  width: var(--conveyor-source-width, 177.4%);
  height: var(--conveyor-source-height, 100%);
  display: block; max-width: none; object-fit: fill;
  /* Tone the actual video, poster and fallback identically, including during
     composited card motion. Equivalent to a 25% light-gray lift. */
  filter: grayscale(1) contrast(.61) brightness(1.23);
  /* Rotate the source's rightward belt motion into a top-to-bottom flow. */
  transform: translate(-50%, -50%) rotate(90deg);
}
.hero-conveyor-fallback { visibility: hidden; }
#home[data-conveyor-fallback] .hero-conveyor-fallback { visibility: visible; }
#home[data-conveyor-fallback] .hero-conveyor-video { visibility: hidden; }
#home .hero-stock-panel {
  position: absolute; inset: 0; background: #f5f5f5;
  transform: translateY(var(--stock-enter-y, 100%));
  visibility: hidden; will-change: transform;
  font-family: 'Pretendard', sans-serif;
}
#home[data-stock-screen] .hero-stock-panel { visibility: visible; }
.stock-panel__tablet-photo {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  filter: grayscale(1);
}
.stock-panel__heading {
  --stock-screen-padding: calc(64px * var(--payment-scale, 1));
  position: absolute;
  left: calc(30.4% + var(--stock-screen-padding));
  /* Center the last row (the chip) on the hero copy's center line. */
  bottom: calc(100% - var(--payment-center-y, 50%) - 22px * var(--payment-scale, 1));
  display: flex; flex-direction: column; align-items: flex-start;
  gap: calc(12px * var(--payment-scale, 1));
  white-space: nowrap; color: #29292e;
}
.stock-panel__title {
  font-size: calc(38px * var(--payment-scale, 1));
  font-weight: 600; line-height: 1.25; letter-spacing: -.035em;
}
.stock-panel__chip {
  display: inline-flex; align-items: center;
  padding: calc(7px * var(--payment-scale, 1)) calc(12px * var(--payment-scale, 1));
  border-radius: calc(10px * var(--payment-scale, 1));
  background: #f1e6fb; color: #7d0ee8;
  transition: background-color 220ms, color 220ms;
}
#home[data-stock-state="out-of-stock"] .stock-panel__chip { background: #ffebee; color: #ce3e50; }
.stock-dial {
  /* A larger cropped arc surrounds the suffix symmetrically above/below.
     Keep its left pointer clear of the status column. */
  position: absolute; width: 92%; aspect-ratio: 1; left: 110%; top: var(--payment-center-y, 50%);
  transform: translate(-50%, -50%); color: #6d6d73;
}
.stock-dial__face {
  display: block; width: 100%; height: 100%; overflow: visible;
}
.stock-dial__rotor {
  transform-origin: 200px 200px;
  transform: rotate(calc(var(--stock-dial-angle, -132deg) - 90deg));
}
.stock-dial__ticks { stroke: #b7b7bd; stroke-width: 1.5; }
.stock-dial__ticks .is-major { stroke: #77777e; stroke-width: 2; }
.stock-dial__scale { font-size: 16px; font-weight: 500; }
.stock-dial__pointer { fill: #ce3e50; }
.stock-dial__hub { stroke: #e8e8eb; stroke-width: 1; }
.stock-dial__readout {
  /* The visible scale and status chip convey the value in this half-dial crop. */
  visibility: hidden;
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: calc(7px * var(--payment-scale, 1));
  color: #36353b; text-align: center;
}
.stock-dial__number-mask {
  height: 1.1em; overflow: clip;
  font-size: calc(54px * var(--payment-scale, 1));
  font-weight: 500; line-height: 1.1; letter-spacing: -.045em;
  font-variant-numeric: tabular-nums;
}
.stock-dial__number-track { transform: translateY(calc(var(--stock-status-step, 0) * -1.1em)); }
.stock-dial__number-track > span { display: block; height: 1.1em; }
.stock-dial__status-mask {
  display: block; height: 1.5em; overflow: clip;
  font-size: calc(20px * var(--payment-scale, 1));
  font-weight: 500; line-height: 1.5; letter-spacing: -.015em;
}
.stock-dial__status-track { display: block; transform: translateY(calc(var(--stock-status-step, 0) * -1.5em)); }
.stock-dial__status-track > span { display: block; height: 1.5em; white-space: nowrap; }
.stock-dial__status-track > span:last-child { color: #ce3e50; }
.payment-panel__phone-photo {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  filter: grayscale(1) brightness(1.025);
}
.payment-panel__summary {
  position: absolute; left: 50%; transform: translateX(-50%);
  bottom: calc(100% - var(--payment-center-y, 50%) + var(--hero-font-size) * .475 + 27px * var(--payment-scale, 1));
  width: var(--hero-connector-width); margin: 0;
  border-collapse: collapse; border-spacing: 0; border: 0;
  font-family: 'Pretendard', sans-serif;
  font-size: calc(13px * var(--payment-scale, 1)); line-height: 1.4; color: #8c8a94;
  letter-spacing: -.02em; font-variant-numeric: tabular-nums;
}
.payment-panel__summary th, .payment-panel__summary td {
  padding: calc(7px * var(--payment-scale, 1)) 0; min-width: 0; background: transparent; border: 0;
}
.payment-panel__summary th { text-align: left; font-weight: 400; }
.payment-panel__summary td { text-align: right; font-weight: 400; white-space: nowrap; }
.payment-panel__summary .summary-total > * {
  border-top: 1px solid #e5e3e9; padding-top: calc(15px * var(--payment-scale, 1)); color: #35313e;
}
.payment-panel__summary .summary-total th { font-size: calc(10px * var(--payment-scale, 1)); font-weight: 500; letter-spacing: .05em; }
.payment-panel__summary .summary-total td { font-size: calc(22px * var(--payment-scale, 1)); font-weight: 500; letter-spacing: -.035em; }
#home .hero-payment-panel .hero-payment {
  inset-inline: auto; left: 50%; top: var(--payment-center-y, 50%);
  width: var(--hero-connector-width);
  margin-left: calc(var(--hero-connector-width) / -2);
  font-size: var(--hero-font-size);
  font-family: 'Pretendard', sans-serif;
}
#home[data-payment-screen] .hero-payment {
  visibility: visible; opacity: 1; animation: none;
}
#home .hero-payment__paid { display: inline-flex; align-items: center; gap: .18em; left: .55em; }
#home .hero-payment__paid svg { width: .72em; height: .72em; flex: none; }
@media (prefers-reduced-motion: reduce) {
  .home-content[data-scroll-motion] > #home { min-height: 100svh; }
  #home .hero-media-frame { display: none; }
}
@media print { #home .hero-media-frame { display: none; } }
