@import url("https://fonts.googleapis.com/css2?family=Inter:wght@500;600&family=Noto+Sans+JP:wght@400;500;700&family=Noto+Serif+JP:wght@600;700&display=swap");

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  background: linear-gradient(135deg, #8b0000 0%, #ca0109 40%, #e63946 70%, #8b0000 100%);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  -webkit-text-size-adjust: 100%;
}

/* Responsive scaling wrapper -------------------------------------------- */
#stage-wrap {
  position: relative;
  width: 100%;
  overflow: hidden;
}

#stage {
  position: absolute;
  top: 0;
  left: 0;
  width: 838px;
  height: 8680px;
  background: #ffffff;
  transform-origin: top left;
  overflow: hidden;
}

/* Generic primitives ---------------------------------------------------- */
#stage img {
  display: block;
}

.abs {
  position: absolute;
}

.layer-bg {
  z-index: 0;
}
.layer-img {
  z-index: 1;
}
.layer-fore {
  z-index: 2;
}

.fit-fill {
  width: 100%;
  height: 100%;
}
.fit-cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.clip {
  overflow: hidden;
}
.clip > img {
  position: absolute;
  max-width: none;
}

/* Text ------------------------------------------------------------------ */
.t {
  position: absolute;
  z-index: 2;
  color: #000;
  white-space: nowrap;
  word-break: break-word;
}
.ns {
  font-family: "Noto Sans JP", sans-serif;
}
.serif {
  font-family: "Noto Serif JP", serif;
}
.inter {
  font-family: "Inter", "Noto Sans JP", sans-serif;
}
.center {
  text-align: center;
  transform: translateX(-50%);
}

/* separator lines */
.line {
  position: absolute;
  z-index: 2;
}

/* Buttons --------------------------------------------------------------- */
.btn {
  position: absolute;
  z-index: 3;
  display: block;
  cursor: pointer;
  transition:
    opacity 0.2s ease,
    transform 0.2s ease;
}
.btn:hover {
  opacity: 0.9;
  transform: translateY(-2px);
}
.btn.center:hover {
  transform: translateX(-50%) translateY(-2px);
}

/* ======================================================================
   Header card
   ====================================================================== */
.site-header {
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 0 30px;
  background: #ffffff;
  border: 1px solid #ece8e3;
  border-radius: 18px;
  box-shadow: 0 6px 18px rgba(80, 60, 40, 0.06);
  z-index: 6;
}
.sh-brand {
  display: flex;
  align-items: center;
  gap: 16px;
  text-decoration: none;
  flex: 0 0 auto;
}
.sh-logo {
  width: 74px;
  height: 74px;
  display: block;
}
.sh-titles {
  display: flex;
  flex-direction: column;
}
.sh-title {
  font-family: "Noto Sans JP", sans-serif;
  font-weight: 700;
  font-size: 33px;
  line-height: 1.15;
  letter-spacing: 0.5px;
  color: #1a1a1a;
}
.sh-sub {
  font-family: "Noto Sans JP", sans-serif;
  font-weight: 500;
  font-size: 14.5px;
  letter-spacing: 0.2px;
  color: #555;
  margin-top: 3px;
}
.sh-sub b {
  color: #c0362b;
  font-weight: 700;
}

.sh-divider {
  width: 1px;
  height: 64px;
  background: #e3ded8;
  flex: 0 0 auto;
  margin-left: auto;
}
.sh-nav {
  display: flex;
  align-items: center;
  gap: 26px;
  flex: 0 0 auto;
}
.sh-navitem {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  text-decoration: none;
  color: #c0362b;
  transition:
    transform 0.2s ease,
    opacity 0.2s ease;
}
.sh-navitem:hover {
  transform: translateY(-3px);
  opacity: 0.85;
}
.navicon {
  height: 30px;
  width: auto;
  display: block;
}
.sh-navitem span {
  font-family: "Noto Sans JP", sans-serif;
  font-weight: 700;
  font-size: 14px;
  color: #2a2a2a;
  white-space: nowrap;
}

/* ======================================================================
   Animations
   ====================================================================== */

/* ---- Scroll reveal (opacity + focus-in blur, no transform conflicts) ---- */
#stage.anim .reveal {
  opacity: 0;
  filter: blur(10px);
  transition:
    opacity 0.9s cubic-bezier(0.22, 0.61, 0.36, 1),
    filter 0.9s cubic-bezier(0.22, 0.61, 0.36, 1),
    transform 0.35s ease;
}
#stage.anim .reveal.in {
  opacity: 1;
  filter: blur(0);
}

/* ---- Card hover lift ---- */
.card-hover {
  cursor: default;
}
.card-hover:hover {
  transform: translateY(-6px);
}

/* ---- Button sparkle (shine sweep) ---- */
.shine-layer {
  position: absolute;
  pointer-events: none;
  overflow: hidden;
  z-index: 2;
  -webkit-mask-size: 100% 100%;
  mask-size: 100% 100%;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
}
.shine-layer::before {
  content: "";
  position: absolute;
  top: -60%;
  left: -85%;
  width: 55%;
  height: 220%;
  background: linear-gradient(
    100deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.85) 50%,
    rgba(255, 255, 255, 0) 100%
  );
  transform: skewX(-22deg);
  animation: btnShine 3.6s ease-in-out infinite;
}
@keyframes btnShine {
  0% {
    left: -85%;
  }
  55% {
    left: 150%;
  }
  100% {
    left: 150%;
  }
}

/* ---- Button glow (hugs the pill via drop-shadow on the PNG alpha) ---- */
.glow {
  animation: btnGlow 2.8s ease-in-out infinite;
}
@keyframes btnGlow {
  0%,
  100% {
    filter: drop-shadow(0 5px 9px rgba(170, 20, 20, 0.3));
  }
  50% {
    filter: drop-shadow(0 7px 22px rgba(225, 45, 45, 0.62));
  }
}

/* glow variant for clipped buttons (box-shadow on a rounded capsule) */
.glow-box {
  border-radius: 62px;
  animation: boxGlow 2.8s ease-in-out infinite;
}
@keyframes boxGlow {
  0%,
  100% {
    box-shadow: 0 5px 12px rgba(170, 20, 20, 0.3);
  }
  50% {
    box-shadow: 0 7px 26px rgba(225, 55, 55, 0.6);
  }
}

/* ---- Floating accents ---- */
.float-slow {
  animation: floatY 6s ease-in-out infinite;
}
@keyframes floatY {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-12px);
  }
}

/* ---- Pulse (e.g. the 無料 badge) ---- */
.pulse {
  animation: pulse 2.2s ease-in-out infinite;
  transform-origin: center;
}
@keyframes pulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.08);
  }
}

/* ---- Arrow nudge ---- */
.arrow-nudge {
  animation: nudge 1.6s ease-in-out infinite;
}
@keyframes nudge {
  0%,
  100% {
    transform: translateX(0);
  }
  50% {
    transform: translateX(7px);
  }
}

/* ---- Respect reduced-motion preference ---- */
@media (prefers-reduced-motion: reduce) {
  #stage.anim .reveal {
    opacity: 1 !important;
    filter: none !important;
  }
  .shine-layer::before,
  .glow,
  .glow-box,
  .float-slow,
  .pulse,
  .arrow-nudge {
    animation: none !important;
  }
}
