/*
 * 朝比奈愛衣の天下取り指南 ランディングページ
 * 色・余白・フォントは :root のトークンで管理する。
 */

:root {
  /* 色 */
  --ink: #140c10;
  --ink-2: #1e1318;
  --ink-3: #2a1a20;
  --paper: #f6eee4;
  --paper-2: #ece0d1;
  --text: #f4ebe3;
  --text-muted: #b9a69f;
  --text-dark: #2b1d1f;
  --text-dark-muted: #6d5a55;
  --vermilion: #c8352c;
  --vermilion-light: #e2554a;
  --sakura: #f3b2c1;
  --gold: #d6ad5f;
  --line: rgb(214 173 95 / 0.28);

  /* フォント */
  --font-serif: "Shippori Mincho", "Hiragino Mincho ProN", "Yu Mincho", serif;
  --font-sans: "Zen Kaku Gothic New", "Hiragino Sans", "Noto Sans JP", sans-serif;

  /* レイアウト */
  --container: 1120px;
  --gutter: clamp(16px, 4vw, 40px);
  --section-space: clamp(88px, 12vw, 160px);
  --radius: 14px;
  --header-height: 64px;
}

/* ---------------------------------------------------------------- ベース */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-height);
}

body {
  margin: 0;
  background: var(--ink);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.9;
  letter-spacing: 0.04em;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: var(--font-serif);
  font-weight: 700;
  line-height: 1.4;
}

p {
  margin: 0;
}

/* content.js 内の "\n" をそのまま改行として表示する */
.hero__title,
.hero__lead,
.section-lead,
.character__quote,
.character__description,
.chat__bubble,
.register__body {
  white-space: pre-line;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.container--narrow {
  max-width: 760px;
}

.note {
  margin-top: 24px;
  color: var(--text-muted);
  font-size: 13px;
  text-align: center;
}

.noscript {
  padding: 24px;
  text-align: center;
}

/* ---------------------------------------------------------------- 共通パーツ */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 52px;
  padding: 0 32px;
  border: 0;
  border-radius: 999px;
  font: inherit;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-decoration: none;
  cursor: pointer;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    background-color 0.2s ease;
}

.button--primary {
  background: linear-gradient(135deg, var(--vermilion-light), var(--vermilion));
  color: #fff;
  box-shadow: 0 10px 30px -10px rgb(200 53 44 / 0.7);
}

.button--primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 36px -12px rgb(200 53 44 / 0.85);
}

.button:disabled {
  background: var(--ink-3);
  color: var(--text-muted);
  box-shadow: none;
  transform: none;
  cursor: not-allowed;
}

.button:focus-visible,
a:focus-visible,
.field__input:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

.badge {
  display: inline-block;
  margin-left: 12px;
  padding: 2px 12px;
  border: 1px solid var(--gold);
  border-radius: 999px;
  color: var(--gold);
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  vertical-align: middle;
}

.section-heading {
  margin-bottom: clamp(32px, 5vw, 56px);
  text-align: center;
}

.section-heading__kicker {
  color: var(--gold);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.32em;
}

.section-heading__title {
  margin-top: 8px;
  font-size: clamp(26px, 4.2vw, 40px);
}

.section-heading__title::after {
  content: "";
  display: block;
  width: 48px;
  height: 2px;
  margin: 20px auto 0;
  background: var(--vermilion);
}

.section-lead {
  max-width: 680px;
  margin: 0 auto clamp(40px, 6vw, 64px);
  color: var(--text-muted);
  text-align: center;
}

/*
 * 立ち絵から顔まわりだけを切り出す枠。
 * 画像を枠の高さの --zoom 倍で表示し、上端に揃えることで、
 * 縦横比の異なる立ち絵でも同じ位置（頭〜胸）を見せる。
 */
.point-card__face,
.chat__avatar,
.gallery__face {
  --zoom: 3;
  position: relative;
  overflow: hidden;
}

.point-card__face img,
.chat__avatar img,
.gallery__face img {
  position: absolute;
  top: 2%;
  left: 50%;
  width: auto;
  max-width: none;
  height: calc(var(--zoom) * 100%);
  transform: translateX(-50%);
}

/* ---------------------------------------------------------------- スクロール表示 */

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition:
    opacity 0.9s ease,
    transform 0.9s cubic-bezier(0.2, 0.7, 0.2, 1);
  transition-delay: var(--delay, 0ms);
}

.reveal--left {
  transform: translateX(-40px);
}

.reveal--right {
  transform: translateX(40px);
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* ---------------------------------------------------------------- ヘッダー */

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: var(--header-height);
  padding-inline: var(--gutter);
  transition:
    background-color 0.3s ease,
    backdrop-filter 0.3s ease;
}

.site-header.is-solid {
  background: rgb(20 12 16 / 0.82);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.site-header__logo {
  font-family: var(--font-serif);
  font-size: 17px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.site-header__logo .logo {
  height: 54px;
  width: auto;
}

.site-header__nav {
  display: flex;
  gap: clamp(12px, 2.4vw, 28px);
}

.site-header__link {
  position: relative;
  font-size: 14px;
  text-decoration: none;
  opacity: 0.85;
}

.site-header__link:hover {
  opacity: 1;
}

.site-header__link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -4px;
  height: 1px;
  background: var(--gold);
  transform: scaleX(0);
  transition: transform 0.25s ease;
}

.site-header__link:hover::after {
  transform: scaleX(1);
}

/* ---------------------------------------------------------------- ヒーロー */

.hero {
  --scroll: 0;
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: stretch;
  overflow: hidden;
  isolation: isolate;
}

.hero__bg {
  position: absolute;
  inset: -4% 0 0;
  z-index: -2;
  background-image:
    linear-gradient(180deg, rgb(20 12 16 / 0.15) 0%, rgb(20 12 16 / 0.35) 55%, var(--ink) 100%),
    linear-gradient(90deg, rgb(20 12 16 / 0.75) 0%, rgb(20 12 16 / 0.1) 60%),
    var(--hero-bg);
  background-size: cover;
  background-position: center 30%;
  transform: translateY(calc(var(--scroll) * 0.3px)) scale(1.06);
}

.hero__petals {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}

.hero__petal {
  position: absolute;
  top: -5%;
  left: var(--x);
  width: var(--size);
  height: calc(var(--size) * 0.8);
  border-radius: 80% 0 80% 0;
  background: linear-gradient(135deg, #ffe1e8, var(--sakura));
  opacity: 0.85;
  animation: petal-fall var(--duration) linear var(--delay) infinite;
}

@keyframes petal-fall {
  0% {
    transform: translate3d(0, -5vh, 0) rotate(0deg);
    opacity: 0;
  }
  10% {
    opacity: 0.85;
  }
  100% {
    transform: translate3d(var(--drift), 110vh, 0) rotate(540deg);
    opacity: 0;
  }
}

.hero__inner {
  position: relative;
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding: calc(var(--header-height) + 24px) var(--gutter) 0;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
}

.hero__copy {
  position: relative;
  z-index: 1;
  padding-bottom: 80px;
  animation: hero-in 1.2s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

.hero__eyebrow {
  display: inline-block;
  padding: 4px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgb(20 12 16 / 0.45);
  color: var(--gold);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
}

.hero__title {
  margin-top: 20px;
  font-size: clamp(38px, 6.2vw, 84px);
  /* 「朝比奈愛衣の」「天下取り指南」の行を途中で折り返さない */
  white-space: pre;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: 0.06em;
  text-shadow: 0 4px 30px rgb(20 12 16 / 0.6);
}

/* ロゴ画像を使うときは文字用の装飾を外し、画像の幅で大きさを決める */
.hero__title--logo {
  margin-top: 12px;
  white-space: normal;
}

.hero__title--logo .logo {
  width: min(100%, 620px);
  height: auto;
  margin-left: -2%;
  filter: drop-shadow(0 8px 24px rgb(20 12 16 / 0.55));
}

.hero__lead {
  margin: 28px 0 36px;
  max-width: 34em;
  font-family: var(--font-serif);
  font-size: clamp(15px, 1.6vw, 18px);
  line-height: 2;
  text-shadow: 0 2px 12px rgb(20 12 16 / 0.8);
}

.hero__portrait {
  align-self: end;
  justify-self: center;
  height: min(88svh, 860px);
  animation: hero-portrait-in 1.4s cubic-bezier(0.2, 0.7, 0.2, 1) 0.2s both;
}

.hero__portrait img {
  height: 100%;
  width: auto;
  /* 足元を背景になじませる（drop-shadow と併用すると Chromium で矩形ノイズが出るため影は付けない） */
  mask-image: linear-gradient(180deg, #000 82%, transparent 100%);
}

@keyframes hero-in {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
}

@keyframes hero-portrait-in {
  from {
    opacity: 0;
    transform: translateX(40px);
  }
}

.hero__scroll {
  position: absolute;
  left: 50%;
  bottom: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  letter-spacing: 0.3em;
  text-decoration: none;
  text-transform: uppercase;
  transform: translateX(-50%);
}

.hero__scroll::after {
  content: "";
  width: 1px;
  height: 48px;
  background: linear-gradient(var(--gold), transparent);
  animation: scroll-line 2s ease-in-out infinite;
  transform-origin: top;
}

@keyframes scroll-line {
  0% {
    transform: scaleY(0);
  }
  50% {
    transform: scaleY(1);
  }
  100% {
    transform: scaleY(1);
    opacity: 0;
  }
}

/* ---------------------------------------------------------------- お知らせ */

.news {
  padding-block: 32px;
}

.news__inner {
  display: flex;
  align-items: baseline;
  gap: 24px;
  padding-block: 20px;
  border-block: 1px solid var(--line);
}

.news__label {
  flex: none;
  color: var(--gold);
  font-family: var(--font-serif);
  font-weight: 700;
}

.news__list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.news__item {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 20px;
}

.news__item time {
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

/* ---------------------------------------------------------------- ゲーム紹介 */

.about {
  padding-block: var(--section-space);
}

.about__points {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.point-card {
  position: relative;
  padding: 36px 28px 32px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--ink-2), var(--ink));
  text-align: center;
}

.point-card__face {
  --zoom: 4.6;
  width: 112px;
  height: 112px;
  margin: 0 auto 20px;
  border: 2px solid var(--gold);
  border-radius: 50%;
  background: radial-gradient(circle at 50% 30%, var(--ink-3), var(--ink));
}

.point-card__num {
  color: var(--vermilion-light);
  font-family: var(--font-serif);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.2em;
}

.point-card__title {
  margin: 4px 0 12px;
  font-size: 22px;
}

.point-card__text {
  color: var(--text-muted);
  font-size: 15px;
  text-align: left;
}

/* ---------------------------------------------------------------- キャラクター */

.character {
  position: relative;
  padding-block: var(--section-space);
  background:
    radial-gradient(ellipse at 20% 50%, rgb(200 53 44 / 0.22), transparent 60%),
    linear-gradient(180deg, var(--ink), var(--ink-2) 50%, var(--ink));
  overflow: hidden;
}

.character__inner {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: clamp(32px, 6vw, 80px);
  align-items: center;
}

.character__visual {
  position: relative;
  display: flex;
  justify-content: center;
}

.character__image {
  position: relative;
  height: min(78vh, 760px);
  width: auto;
  filter: drop-shadow(0 24px 48px rgb(0 0 0 / 0.55));
}

/* 立ち絵の背後に縦書きの名前を大きく敷く */
.character__name-vertical {
  position: absolute;
  top: 50%;
  left: 50%;
  color: rgb(214 173 95 / 0.12);
  font-family: var(--font-serif);
  font-size: clamp(80px, 12vw, 150px);
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
  writing-mode: vertical-rl;
  transform: translate(-50%, -50%);
  user-select: none;
}

.character__name {
  margin-top: 8px;
  font-size: clamp(34px, 5vw, 52px);
  letter-spacing: 0.12em;
}

.character__kana {
  display: block;
  color: var(--text-muted);
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.3em;
}

.character__role {
  margin-top: 12px;
  color: var(--gold);
  font-size: 14px;
}

.character__quote {
  position: relative;
  margin: 28px 0;
  padding: 20px 24px 20px 28px;
  border-left: 3px solid var(--vermilion);
  background: rgb(255 255 255 / 0.04);
  font-family: var(--font-serif);
  font-size: clamp(16px, 1.8vw, 19px);
  line-height: 2;
}

.character__description {
  color: var(--text-muted);
}

.character__profile {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 12px 24px;
  margin: 32px 0 0;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  font-size: 15px;
}

.character__profile dt {
  color: var(--gold);
  font-weight: 700;
}

.character__profile dd {
  margin: 0;
}

/* ---------------------------------------------------------------- 遊び方（和紙の明るい面） */

.howto {
  padding-block: var(--section-space);
  background:
    radial-gradient(circle at 10% 10%, rgb(243 178 193 / 0.35), transparent 40%),
    radial-gradient(circle at 90% 90%, rgb(214 173 95 / 0.25), transparent 40%),
    var(--paper);
  color: var(--text-dark);
}

.howto .section-heading__kicker {
  color: var(--vermilion);
}

.steps {
  display: grid;
  gap: clamp(40px, 6vw, 72px);
  margin: 0;
  padding: 0;
  list-style: none;
}

.step {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: clamp(24px, 4vw, 56px);
  align-items: center;
  max-width: 860px;
}

/* 偶数ステップは左右を入れ替えて、ジグザグに読ませる */
.step:nth-child(even) {
  grid-template-columns: 1fr 220px;
  margin-left: auto;
}

.step:nth-child(even) .step__visual {
  order: 2;
}

.step__visual {
  position: relative;
  height: 300px;
  display: flex;
  justify-content: center;
  overflow: hidden;
  border-radius: 110px 110px var(--radius) var(--radius);
  background: linear-gradient(180deg, var(--paper-2), #e3d2c0);
}

.step__visual img {
  width: auto;
  height: 210%;
  margin-top: 12px;
}

.step__num {
  color: var(--vermilion);
  font-family: var(--font-serif);
  font-weight: 800;
  letter-spacing: 0.2em;
}

.step__title {
  margin: 4px 0 12px;
  font-size: clamp(22px, 3vw, 28px);
}

.step__text {
  color: var(--text-dark-muted);
}

/* ---------------------------------------------------------------- 会話 */

.conversation {
  padding-block: var(--section-space);
  background:
    linear-gradient(180deg, var(--ink) 0%, rgb(20 12 16 / 0.9) 30%, rgb(20 12 16 / 0.9) 70%, var(--ink) 100%),
    var(--hero-bg, none);
  background-size: cover;
  background-position: center;
}

.chat {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: clamp(20px, 4vw, 36px);
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgb(30 19 24 / 0.85);
  box-shadow: 0 30px 60px -30px rgb(0 0 0 / 0.8);
}

.message {
  opacity: 0;
  transform: translateY(16px);
  transition:
    opacity 0.5s ease,
    transform 0.5s ease;
}

.message.is-visible {
  opacity: 1;
  transform: none;
}

.chat__row {
  display: flex;
  gap: 14px;
}

.chat__row--lord {
  justify-content: flex-end;
}

.chat__avatar {
  --zoom: 5.4;
  flex: none;
  width: 56px;
  height: 56px;
  border: 2px solid var(--gold);
  border-radius: 50%;
  background: var(--ink-3);
}

.chat__content {
  max-width: 82%;
}

.chat__speaker {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
  font-size: 13px;
  font-weight: 700;
}

.chat__emotion {
  padding: 0 8px;
  border-radius: 999px;
  background: rgb(214 173 95 / 0.18);
  color: var(--gold);
  font-size: 11px;
}

.chat__bubble {
  padding: 14px 18px;
  border-radius: 4px 18px 18px 18px;
  background: var(--paper);
  color: var(--text-dark);
  font-size: 15px;
  line-height: 1.85;
}

.chat__row--lord .chat__bubble {
  max-width: 82%;
  border-radius: 18px 4px 18px 18px;
  background: var(--vermilion);
  color: #fff;
}

/* ---------------------------------------------------------------- システム */

.features {
  padding-block: var(--section-space);
}

.features__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.feature-card {
  position: relative;
  padding: 32px 32px 32px 40px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--ink-2);
  overflow: hidden;
}

.feature-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: linear-gradient(var(--vermilion-light), var(--gold));
}

.feature-card__title {
  margin-bottom: 8px;
  font-size: 24px;
}

.feature-card__text {
  color: var(--text-muted);
  font-size: 15px;
}

/* ---------------------------------------------------------------- 表情ギャラリー */

.emotions {
  padding-block: var(--section-space);
  background: linear-gradient(180deg, var(--ink), var(--ink-2));
}

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 16px;
  max-width: calc(var(--container) + 120px);
  margin: 0 auto;
  padding: 0 var(--gutter);
  list-style: none;
}

.gallery__item {
  text-align: center;
}

.gallery__face {
  --zoom: 2.8;
  aspect-ratio: 3 / 4;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    radial-gradient(circle at 50% 35%, rgb(243 178 193 / 0.18), transparent 70%),
    var(--ink-3);
  transition:
    transform 0.3s ease,
    border-color 0.3s ease;
}

.gallery__item:not(.gallery__item--locked):hover .gallery__face {
  transform: translateY(-4px);
  border-color: var(--gold);
}

.gallery__label {
  margin-top: 8px;
  font-size: 14px;
  font-weight: 700;
}

/*
 * 関係が深まるまで見られない表情は、ぼかしてシルエットにする。
 * ぼかし・暗さ・彩度は画像（landing/scripts/optimize_images.py）に焼き込み済みで、
 * 元の鮮明な画像は配信しない。
 */
.gallery__item--locked .gallery__face::after {
  content: "？";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--sakura);
  font-family: var(--font-serif);
  font-size: 44px;
  font-weight: 800;
}

.gallery__item--locked .gallery__label {
  color: var(--sakura);
  font-size: 12px;
}

/* ---------------------------------------------------------------- 関係の段階 */

.affinity {
  padding-block: 0 var(--section-space);
  background: var(--ink-2);
}

.affinity__stages {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: stage;
}

.stage {
  position: relative;
  padding: 28px 24px;
  text-align: center;
}

/* 段階の間を矢印でつなぐ */
.stage + .stage::before {
  content: "";
  position: absolute;
  top: 50%;
  left: -8px;
  width: 16px;
  height: 16px;
  border-top: 2px solid var(--gold);
  border-right: 2px solid var(--gold);
  transform: translateY(-50%) rotate(45deg);
  opacity: 0.6;
}

.stage__num {
  color: var(--sakura);
  font-family: var(--font-serif);
  font-size: 14px;
  letter-spacing: 0.2em;
}

.stage__title {
  margin: 4px 0 8px;
  font-size: 22px;
}

.stage:last-child .stage__title {
  color: var(--sakura);
}

.stage__text {
  color: var(--text-muted);
  font-size: 15px;
}

/* ---------------------------------------------------------------- 事前登録 */

.register {
  position: relative;
  /* 直前の関係セクションと余白が二重にならないよう上側は半分にする */
  padding-block: calc(var(--section-space) / 2) 0;
  background:
    radial-gradient(ellipse at 70% 60%, rgb(200 53 44 / 0.35), transparent 60%),
    linear-gradient(180deg, var(--ink-2), #2b1015);
  overflow: hidden;
}

.register__inner {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: clamp(24px, 5vw, 64px);
  align-items: end;
}

.register__card {
  margin-bottom: var(--section-space);
  padding: clamp(28px, 5vw, 52px);
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgb(20 12 16 / 0.72);
  backdrop-filter: blur(6px);
}

.register__title {
  margin-top: 8px;
  font-size: clamp(30px, 4.5vw, 44px);
}

.register__body {
  margin: 16px 0 32px;
  color: var(--text-muted);
}

.register__fields {
  display: grid;
  gap: 18px;
  margin: 0;
  padding: 0;
  border: 0;
}

.register__fields:disabled {
  opacity: 0.6;
}

.field {
  display: grid;
  gap: 6px;
}

.field__label {
  font-size: 14px;
  font-weight: 700;
}

.field__input {
  min-height: 50px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgb(255 255 255 / 0.06);
  color: var(--text);
  font: inherit;
}

.field__input::placeholder {
  color: rgb(185 166 159 / 0.6);
}

.field__input:disabled {
  cursor: not-allowed;
}

.register__fields .button {
  justify-self: start;
  margin-top: 8px;
}

.register__visual {
  position: relative;
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.register__visual img {
  height: min(72vh, 640px);
  width: auto;
  filter: drop-shadow(0 20px 40px rgb(0 0 0 / 0.5));
}

.register__closing {
  order: -1;
  margin-bottom: 16px;
  padding: 12px 18px;
  border-radius: 14px;
  background: var(--paper);
  color: var(--text-dark);
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 700;
  box-shadow: 0 10px 24px -10px rgb(0 0 0 / 0.6);
}

/* ---------------------------------------------------------------- フッター */

.site-footer {
  padding: 40px var(--gutter);
  border-top: 1px solid var(--line);
  background: var(--ink);
  color: var(--text-muted);
  text-align: center;
}

.site-footer__title .logo {
  width: 220px;
  height: auto;
  margin: 0 auto 8px;
}

.site-footer__title {
  margin-bottom: 4px;
  color: var(--text);
  font-family: var(--font-serif);
  font-weight: 700;
}

/* ---------------------------------------------------------------- レスポンシブ */

@media (max-width: 900px) {
  .hero__inner {
    grid-template-columns: 1fr;
    align-items: end;
  }

  /* スマホでは立ち絵を背景側に置き、コピーを手前に重ねる */
  .hero__portrait {
    position: absolute;
    right: -8%;
    bottom: 0;
    height: 78svh;
    opacity: 0.9;
  }

  .hero__copy {
    padding-bottom: 72px;
  }

  .hero__scroll {
    display: none;
  }

  .hero__title,
  .hero__lead {
    text-shadow: 0 2px 16px rgb(20 12 16 / 0.95);
  }

  .about__points,
  .features__grid,
  .affinity__stages {
    grid-template-columns: 1fr;
  }

  .stage + .stage::before {
    top: -8px;
    left: 50%;
    transform: translateX(-50%) rotate(135deg);
  }

  .character__inner,
  .register__inner {
    grid-template-columns: 1fr;
  }

  .character__image {
    height: 60vh;
  }

  .register__card {
    margin-bottom: 0;
  }

  .register__visual img {
    height: 48vh;
  }

}

@media (max-width: 640px) {
  .site-header__nav {
    display: none;
  }

  .news__inner {
    flex-direction: column;
    gap: 8px;
  }

  .step,
  .step:nth-child(even) {
    grid-template-columns: 1fr;
  }

  .step:nth-child(even) .step__visual {
    order: 0;
  }

  .step__visual {
    height: 240px;
    max-width: 260px;
  }

  .gallery {
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
  }

  .chat__content,
  .chat__row--lord .chat__bubble {
    max-width: 100%;
  }
}

/* 動きを減らす設定の利用者にはアニメーションを止める */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  .hero__petals {
    display: none;
  }
}
