/* アイのあるミライ 公式サイト — ヒーロー / コンセプト / 世界観 */

.section {
  position: relative;
  padding-block: var(--block);
}

/* 見出しは折り返させたくないので幅を制限しない。本文だけ .section-lead で抑える */
.section-head {
  margin-bottom: clamp(36px, 5vw, 64px);
}

/* ---------- ヒーロー（PCでは画面いっぱいのキービジュアル） ---------- */

.hero {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: calc(100vh - 72px);
  min-height: calc(100svh - 72px);
  overflow: hidden;
}

.hero-aura {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  background:
    radial-gradient(42rem 30rem at 16% 18%, var(--glow-cyan), transparent 70%),
    radial-gradient(38rem 28rem at 78% 6%, var(--glow-pink), transparent 70%);
  filter: blur(10px);
  animation: aura-drift 18s ease-in-out infinite alternate;
}

@keyframes aura-drift {
  to {
    transform: translate3d(-3%, 2%, 0) scale(1.08);
  }
}

/* 左のコピーはページの左端に揃え、右の立ち絵は画面の右端まで抜ける */
.hero-main {
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr);
  align-items: center;
  gap: clamp(20px, 3vw, 48px);
  padding-left: max(var(--gutter), calc((100vw - var(--page)) / 2));
  padding-block: clamp(20px, 3vh, 44px) 0;
}

.hero-copy {
  max-width: 620px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 8px 8px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  font-size: 0.8rem;
  font-weight: 700;
}

.hero-badge b {
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  background: linear-gradient(100deg, var(--brand-pink), var(--brand-cyan));
  color: #fff;
  font-family: var(--font-en);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
}

.hero h1 {
  margin-block: 20px 18px;
  font-size: var(--step-4);
  line-height: 1.06;
  letter-spacing: -0.01em;
}

.hero h1 .line {
  display: block;
  overflow: hidden;
}

.hero h1 .line > span {
  display: block;
  transform: translateY(105%);
  animation: line-rise 1s var(--ease) forwards;
  animation-delay: var(--delay, 0ms);
}

@keyframes line-rise {
  to {
    transform: none;
  }
}

.hero-lead {
  max-width: 44ch;
  color: var(--ink-soft);
  font-size: var(--step-1);
  text-wrap: pretty;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

/* ヒーロー下端の帯：更新情報と配信チャネル */
.hero-bar {
  border-top: 1px solid var(--line);
  backdrop-filter: blur(6px);
}

.hero-bar-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 32px;
  padding-block: 14px;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 22px;
  font-size: 0.84rem;
  color: var(--ink-soft);
}

.hero-meta .author {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
}

.hero-meta .author img {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--plate);
}

.hero-channels {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
}

.hero-channels-label {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--ink-faint);
}

.channel-icons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.channel-icons a {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1.5px solid var(--line);
  border-radius: 13px;
  background: var(--surface);
  color: var(--ink-soft);
  transition: transform 0.4s var(--ease), border-color 0.4s var(--ease), color 0.3s var(--ease),
    background 0.4s var(--ease), box-shadow 0.4s var(--ease);
}

.channel-icons svg {
  width: 19px;
  height: 19px;
  fill: currentColor;
}

.channel-icons a:hover {
  transform: translateY(-3px);
  border-color: transparent;
  color: #fff;
  background: linear-gradient(100deg, var(--brand-pink), var(--brand-cyan));
  box-shadow: 0 12px 26px -12px var(--glow-pink);
}

/* キービジュアル：ロゴと藍の立ち絵 */

.hero-visual {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  height: 100%;
  padding-right: clamp(0px, 2.5vw, 48px);
}

.kv-glow {
  position: absolute;
  inset: 6% -20% 0 -10%;
  pointer-events: none;
  background: radial-gradient(closest-side at 54% 56%, var(--glow-cyan), transparent 72%);
  filter: blur(16px);
}

.kv-stage {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  width: 100%;
  transform: translate3d(var(--px, 0px), var(--py, 0px), 0);
  transition: transform 0.9s var(--ease);
}

/* ロゴと円は立ち絵の幅を基準に置くので、画面幅が変わっても重なり具合は変わらない */
.kv-frame {
  position: relative;
  display: flex;
  align-items: flex-end;
}

.kv-disc {
  position: absolute;
  left: 50%;
  bottom: 2%;
  z-index: 0;
  width: 250%;
  aspect-ratio: 1;
  transform: translateX(-50%);
  border-radius: 50%;
  border: 1px solid var(--line);
  background: linear-gradient(155deg, rgba(255, 102, 196, 0.16), rgba(56, 182, 255, 0.14));
}

.kv-figure {
  position: relative;
  z-index: 2;
  width: auto;
  height: clamp(400px, 74vh, 800px);
  max-width: none;
  filter: drop-shadow(0 34px 44px rgba(20, 24, 42, 0.3));
  animation: kv-rise 1.2s var(--ease) both 0.2s;
}

@keyframes kv-rise {
  from {
    opacity: 0;
    transform: translateY(34px);
  }
}

.kv-logo {
  position: absolute;
  z-index: 3;
  top: 3%;
  left: -172%;
  width: 210%;
  max-width: none;
  height: auto;
  filter: drop-shadow(0 10px 26px rgba(255, 102, 196, 0.38));
  animation: kv-float 7s ease-in-out infinite alternate, kv-rise 1.1s var(--ease) both;
}

@keyframes kv-float {
  to {
    transform: translate3d(0, -12px, 0);
  }
}

.kv-badge {
  position: absolute;
  z-index: 4;
  left: 0;
  bottom: 12%;
  display: grid;
  place-items: center;
  width: clamp(92px, 9vw, 124px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--ink);
  color: var(--bg);
  text-align: center;
  font-size: 0.7rem;
  font-weight: 900;
  line-height: 1.45;
  letter-spacing: 0.02em;
  box-shadow: var(--shadow-md);
  animation: badge-spin 18s linear infinite;
}

.kv-badge span {
  animation: badge-spin 18s linear infinite reverse;
}

@keyframes badge-spin {
  to {
    transform: rotate(360deg);
  }
}

/* ---------- 流れる帯 ---------- */

.marquee {
  position: relative;
  display: flex;
  overflow: hidden;
  padding-block: 18px;
  border-block: 1px solid var(--line);
  background: var(--surface);
  user-select: none;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.marquee ul {
  display: flex;
  flex-shrink: 0;
  gap: 40px;
  padding-right: 40px;
  animation: marquee-run 32s linear infinite;
}

.marquee li {
  display: inline-flex;
  align-items: center;
  gap: 40px;
  white-space: nowrap;
  font-family: var(--font-en);
  font-size: clamp(0.9rem, 2vw, 1.15rem);
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.marquee li::after {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: linear-gradient(100deg, var(--brand-pink), var(--brand-cyan));
}

@keyframes marquee-run {
  to { transform: translateX(-100%); }
}

/* ---------- 世界観 ---------- */

.world {
  background: var(--bg-alt);
  border-block: 1px solid var(--line);
}

.world-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(255px, 1fr));
  gap: 16px;
}

/* 挿絵＋タイトルを見せ、ホバー（またはタップ）で説明を絵の上に重ねる。
   カードの高さは変わらないので、開いても隣のカードがずれない。 */
.world-card {
  position: relative;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  overflow: hidden;
  transition: transform 0.5s var(--ease), border-color 0.5s var(--ease), box-shadow 0.5s var(--ease);
}

.world-thumb {
  position: relative;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  background: var(--plate);
}

.world-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s var(--ease);
}

.world-body {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  padding: 16px 18px;
  overflow: hidden;
  background: linear-gradient(rgba(16, 19, 32, 0.25), rgba(16, 19, 32, 0.9) 58%);
  opacity: 0;
  transition: opacity 0.45s var(--ease);
}

.world-body p {
  font-size: 0.82rem;
  line-height: 1.65;
  color: #fff;
  transform: translateY(8px);
  transition: transform 0.5s var(--ease);
}

.world-main {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-height: 92px;
  padding: 16px 52px 18px 20px;
}

.world-card .num {
  font-family: var(--font-en);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  color: var(--ink-faint);
  transition: color 0.4s var(--ease);
}

.world-title {
  font-size: var(--step-1);
  font-weight: 900;
  line-height: 1.5;
}

/* カードのどこを押しても開く。＋の見た目だけ右下に置く */
.world-cover {
  position: absolute;
  inset: 0;
  z-index: 2;
}

.world-plus {
  position: absolute;
  right: 18px;
  bottom: 20px;
  width: 26px;
  height: 26px;
  border: 1.5px solid var(--line-strong);
  border-radius: 50%;
  color: var(--ink-soft);
  transition: transform 0.5s var(--ease), border-color 0.4s var(--ease), color 0.4s var(--ease);
}

.world-plus::before,
.world-plus::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 10px;
  height: 1.5px;
  background: currentColor;
  transform: translate(-50%, -50%);
}

.world-plus::after {
  transform: translate(-50%, -50%) rotate(90deg);
}

.world-card.is-open,
.world-card:focus-within {
  transform: translateY(-6px);
  border-color: transparent;
  box-shadow: var(--shadow-md);
}

.world-card.is-open .world-body,
.world-card:focus-within .world-body {
  opacity: 1;
}

.world-card.is-open .world-body p,
.world-card:focus-within .world-body p {
  transform: none;
}

.world-card.is-open .world-thumb img,
.world-card:focus-within .world-thumb img {
  transform: scale(1.06);
}

.world-card.is-open .world-plus,
.world-card:focus-within .world-plus {
  transform: rotate(135deg);
  border-color: var(--brand-pink);
  color: var(--brand-pink);
}

.world-card.is-open .num,
.world-card:focus-within .num {
  color: var(--brand-pink);
}

@media (hover: hover) {
  .world-card:hover {
    transform: translateY(-6px);
    border-color: transparent;
    box-shadow: var(--shadow-md);
  }

  .world-card:hover .world-body {
    opacity: 1;
  }

  .world-card:hover .world-body p {
    transform: none;
  }

  .world-card:hover .world-thumb img {
    transform: scale(1.06);
  }

  .world-card:hover .world-plus {
    transform: rotate(135deg);
    border-color: var(--brand-pink);
    color: var(--brand-pink);
  }

  .world-card:hover .num {
    color: var(--brand-pink);
  }
}

@media (max-width: 700px) {
  .world-main {
    min-height: 0;
    padding: 14px 50px 16px 18px;
  }

  .world-body {
    padding: 14px 16px;
  }

  .world-plus {
    bottom: 16px;
  }
}

/* 横幅が足りなくなったら、画面いっぱいの構図をやめて縦並びに戻す */
@media (max-width: 900px) {
  .hero {
    min-height: 0;
  }

  .hero-main {
    grid-template-columns: 1fr;
    padding-inline: var(--gutter);
    padding-block: clamp(16px, 3vw, 32px) clamp(24px, 4vw, 40px);
  }

  .hero-copy {
    max-width: none;
  }

  .hero-visual {
    order: -1;
    height: auto;
    padding-right: 0;
    min-height: clamp(380px, 54vh, 540px);
    margin-inline: auto;
    width: min(100%, 560px);
  }

  /* 縦並びでは、ロゴがはみ出す分だけ立ち絵をずらして、ロゴ＋立ち絵の全体を中央に置く */
  .kv-stage {
    justify-content: center;
  }

  .kv-frame {
    transform: translateX(66%);
  }

  .kv-figure {
    height: clamp(330px, 48vh, 470px);
  }

  .kv-logo {
    left: -132%;
    width: 170%;
  }

  .kv-glow {
    inset: 6% -6% 0;
  }

  .hero-bar-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
  }
}

@media (max-width: 560px) {
  .hero-visual {
    min-height: 360px;
  }

  .kv-figure {
    height: clamp(300px, 44vh, 400px);
  }

  .kv-badge {
    left: 0;
    bottom: 4%;
  }

  .hero-actions .btn {
    flex: 1 1 100%;
  }
}
