/* --------------------------------------------------------------------------
   QZH intro / video gate
   -------------------------------------------------------------------------- */

body.page-welcome {
  background: #fff8e6;
  color: var(--ink);
}

.welcome {
  position: relative;
  display: flex;
  min-height: 100svh;
  flex-direction: column;
  overflow: hidden;
  padding: clamp(16px, 2.4vw, 30px) var(--gutter) 0;
}

.welcome__bg {
  position: absolute;
  z-index: 0;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}
.welcome__bg::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(43, 38, 24, 0.09) 1px, transparent 1px);
  background-size: 18px 18px;
  opacity: 0.7;
}
.welcome__sun {
  position: absolute;
  top: -24vw;
  right: -12vw;
  width: 62vw;
  height: 62vw;
  min-width: 380px;
  min-height: 380px;
  border-radius: 50%;
  background: var(--gold);
  opacity: 0.9;
}
.welcome__sun::after {
  content: "";
  position: absolute;
  inset: 13%;
  border: 2px dashed rgba(43, 38, 24, 0.28);
  border-radius: 50%;
}
.welcome__grid {
  position: absolute;
  left: -6vw;
  bottom: 10vh;
  width: 48vw;
  height: 48vw;
  border: 2px solid rgba(43, 38, 24, 0.08);
  background-image:
    linear-gradient(rgba(43, 38, 24, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(43, 38, 24, 0.055) 1px, transparent 1px);
  background-size: 46px 46px;
  transform: rotate(-9deg);
}
.welcome__word {
  position: absolute;
  right: -0.08em;
  bottom: -0.2em;
  color: rgba(242, 106, 27, 0.055);
  font-family: var(--sans);
  font-size: clamp(180px, 29vw, 440px);
  font-weight: 900;
  line-height: 0.8;
  letter-spacing: -0.12em;
}

.welcome__top,
.welcome__stage,
.welcome__foot {
  position: relative;
  z-index: 1;
}
.welcome__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.welcome__brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--ink);
  text-decoration: none;
}
.welcome__brand img {
  width: 48px;
  height: 48px;
  border: 2px solid var(--ink);
  border-radius: 50%;
  background: #fff8e6;
  object-fit: cover;
  box-shadow: 3px 3px 0 var(--ink);
}
.welcome__brand strong {
  display: block;
  font-size: 17px;
  line-height: 1.1;
  letter-spacing: 0.02em;
}
.welcome__brand small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 7px;
  font-weight: 700;
  letter-spacing: 0.16em;
}
.welcome__badge {
  padding: 5px 11px;
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  background: #fff8e6;
  color: var(--cinnabar);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.08em;
  transform: rotate(2deg);
}

.welcome__stage {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  padding: clamp(22px, 4vh, 46px) 0 clamp(14px, 2.4vh, 24px);
  text-align: center;
}
.welcome__eyebrow {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.welcome__title {
  margin: 0;
  font-family: var(--sans);
  font-size: clamp(38px, 6.3vw, 84px);
  font-weight: 900;
  line-height: 1.06;
  letter-spacing: -0.055em;
  text-wrap: balance;
}
.welcome__title em {
  position: relative;
  z-index: 0;
  color: var(--cinnabar);
  font-style: normal;
  padding: 0 0.04em;
}
.welcome__title em::after {
  content: "";
  position: absolute;
  z-index: -1;
  left: -0.02em;
  right: -0.02em;
  bottom: 0.08em;
  height: 0.32em;
  background: var(--gold);
  transform: rotate(-1.5deg);
}
.welcome__lead {
  max-width: 32em;
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.7;
}

.welcome__frame {
  width: min(100%, 550px);
  margin: clamp(20px, 3.4vh, 32px) auto 0;
  padding: 9px;
  border: 3px solid var(--ink);
  border-radius: 26px;
  background: #171610;
  box-shadow: 10px 10px 0 var(--ink);
  text-align: left;
}
.welcome__frame-top,
.welcome__frame-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 5px 8px;
  color: #fff8e6;
  font-size: 7px;
  font-weight: 800;
  letter-spacing: 0.14em;
}
.welcome__frame-top { padding-bottom: 9px; }
.welcome__frame-bottom {
  justify-content: flex-end;
  padding-top: 9px;
  color: rgba(255, 248, 230, 0.62);
}
.welcome__screen {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  border: 2px solid #fff8e6;
  border-radius: 16px;
  background: #f7f4eb;
}
.welcome__fallback {
  position: absolute;
  z-index: 0;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 50%;
  transform-origin: 50% 62%;
  animation: welcome-bob 2.8s ease-in-out infinite;
}
.welcome__video {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 50%;
  opacity: 0;
  pointer-events: none;
  user-select: none;
  transition: opacity 0.45s ease;
}
.welcome__video.is-ready {
  opacity: 1;
}
.welcome__video::-webkit-media-controls,
.welcome__video::-webkit-media-controls-enclosure {
  display: none !important;
}
.welcome__rec {
  position: absolute;
  top: 12px;
  left: 12px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 8px;
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  background: #fff8e6;
  color: var(--ink);
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.1em;
  box-shadow: 2px 2px 0 var(--ink);
}
.welcome__rec i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--cinnabar);
  animation: welcome-rec 1.2s steps(2, end) infinite;
}
@keyframes welcome-bob {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-1.2%) scale(1.015); }
}
@keyframes welcome-rec {
  50% { opacity: 0.25; }
}
.welcome__sticker {
  position: absolute;
  right: 12px;
  top: 12px;
  padding: 6px 10px;
  border: 2px solid var(--ink);
  border-radius: 4px;
  background: var(--gold);
  color: var(--ink);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.08em;
  transform: rotate(4deg);
  box-shadow: 3px 3px 0 var(--ink);
}
.welcome__peek {
  position: absolute;
  z-index: 3;
  right: 10px;
  bottom: 10px;
  width: 86px;
  height: 86px;
  border: 2px solid var(--ink);
  border-radius: 50%;
  background: #fff8e6;
  object-fit: cover;
  transform: rotate(9deg);
  box-shadow: 4px 4px 0 var(--ink);
  pointer-events: none;
}

.welcome__sound {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 12px;
  padding: 8px 17px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  background: var(--gold);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.03em;
  cursor: pointer;
  box-shadow: 3px 3px 0 var(--ink);
  transition: transform 0.16s ease, box-shadow 0.16s ease;
}
.welcome__sound:hover,
.welcome__sound:focus-visible {
  transform: translate(-1px, -1px);
  box-shadow: 4px 4px 0 var(--ink);
}
.welcome__sound:active {
  transform: translate(2px, 2px);
  box-shadow: 1px 1px 0 var(--ink);
}
.welcome__sound[hidden] {
  display: none !important;
}
.welcome__sound + .welcome__enter {
  margin-top: 13px;
}

.welcome__enter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  min-width: min(100%, 330px);
  min-height: 62px;
  margin-top: clamp(22px, 3.4vh, 34px);
  padding: 14px 30px;
  border: 3px solid var(--ink);
  border-radius: 999px;
  background: var(--cinnabar);
  color: #fff8e6;
  font-size: 17px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-decoration: none;
  box-shadow: 6px 6px 0 var(--ink);
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}
.welcome__enter b {
  font-size: 24px;
  line-height: 1;
}
.welcome__enter:hover,
.welcome__enter:focus-visible {
  background: #d45207;
  color: #fff8e6;
  transform: translate(-2px, -2px);
  box-shadow: 8px 8px 0 var(--ink);
}
.welcome__enter:active {
  transform: translate(3px, 3px);
  box-shadow: 3px 3px 0 var(--ink);
}
.welcome__note {
  margin: 13px 0 0;
  color: var(--muted);
  font-size: 9px;
  letter-spacing: 0.02em;
}

.welcome__foot {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 10px 0 13px;
  border-top: 1.5px solid rgba(43, 38, 24, 0.14);
  color: var(--muted);
  font-size: 8px;
  letter-spacing: 0.02em;
}

@media (min-width: 721px) and (max-height: 980px) {
  .welcome__stage { padding: 16px 0 10px; }
  .welcome__title { font-size: clamp(34px, 5.2vw, 64px); }
  .welcome__lead { margin-top: 8px; }
  .welcome__frame { width: min(100%, 450px); margin-top: 14px; padding: 7px; }
  .welcome__peek { width: 64px; height: 64px; }
  .welcome__enter { min-height: 54px; margin-top: 18px; }
  .welcome__foot { padding: 8px 0 10px; }
}

@media (min-width: 721px) and (max-height: 820px) {
  .welcome__stage { padding: 8px 0 4px; }
  .welcome__title { font-size: clamp(30px, 4.6vw, 48px); }
  .welcome__lead { margin-top: 6px; font-size: 10.5px; }
  .welcome__frame { width: min(100%, 360px); margin-top: 10px; padding: 6px; }
  .welcome__peek { width: 54px; height: 54px; }
  .welcome__enter { min-height: 48px; margin-top: 12px; padding: 9px 22px; font-size: 14px; }
  .welcome__note { margin-top: 8px; font-size: 8px; }
  .welcome__foot { padding: 6px 0 8px; font-size: 7px; }
}

@media (max-width: 720px) {
  .welcome { padding: 13px 16px 0; }
  .welcome__brand img { width: 40px; height: 40px; }
  .welcome__brand strong { font-size: 15px; }
  .welcome__badge { padding: 4px 8px; font-size: 8px; }
  .welcome__stage { padding: 20px 0 18px; }
  .welcome__eyebrow { font-size: 8px; letter-spacing: 0.1em; }
  .welcome__title { font-size: clamp(34px, 10.4vw, 48px); }
  .welcome__lead { max-width: 25em; margin-top: 11px; font-size: 10.5px; }
  .welcome__frame { width: min(100%, 360px); margin-top: 18px; padding: 7px; border-radius: 20px; box-shadow: 7px 7px 0 var(--ink); }
  .welcome__frame-top, .welcome__frame-bottom { font-size: 6px; padding-left: 5px; padding-right: 5px; }
  .welcome__screen { border-radius: 13px; }
  .welcome__rec { top: 8px; left: 8px; padding: 3px 6px; font-size: 7px; }
  .welcome__sticker { top: 8px; right: 8px; padding: 4px 7px; font-size: 8px; }
  .welcome__peek { right: 8px; bottom: 8px; width: 62px; height: 62px; }
  .welcome__enter { min-height: 54px; min-width: min(100%, 300px); margin-top: 22px; padding: 11px 24px; font-size: 15px; box-shadow: 5px 5px 0 var(--ink); }
  .welcome__note { font-size: 8px; }
  .welcome__foot { flex-direction: column; gap: 4px; font-size: 7px; }
}

@media (max-width: 420px) {
  .welcome__peek { width: 54px; height: 54px; right: 7px; bottom: 7px; }
  .welcome__title { font-size: clamp(31px, 10.2vw, 42px); }
}

@media (prefers-reduced-motion: reduce) {
  .welcome__rec i { animation: none; }
  .welcome__enter { transition: none; }
}
