/* ============================================================
   CasLive LP (加久間案) - メインスタイル
   below-the-fold 用 (above-the-fold は index.html にインライン)
   ============================================================ */

/* ========== CSS 変数 ========== */
:root {
  /* カラーパレット */
  --color-pink: #ffb9df;
  --color-purple: #c0a1fb;
  --color-purple-light: #c7bffd;
  --color-red-shadow: #ff7a7a;
  --color-yellow: #ffd136;
  --color-white: #fff;
  --color-text-mute: rgba(0, 0, 0, .6);

  /* 背景グラデーション */
  --gradient-experience: linear-gradient(180deg, rgba(157,116,249,.5) 0%, rgba(255,128,196,.5) 90%, rgba(255,218,115,.5) 100%);
  --gradient-footer: linear-gradient(180deg, rgba(157,116,249,.5) 0%, rgba(255,128,196,.5) 60%, rgba(255,218,115,.5) 100%);
  --gradient-button: linear-gradient(180deg, rgba(255,128,196,.3) 0%, rgba(255,209,54,.3) 100%);
  --gradient-card-overlay: linear-gradient(180deg, rgba(255,128,196,.2) 40%, rgba(255,209,54,.2) 100%);

  /* タイポグラフィ */
  --font-display: 'M PLUS Rounded 1c', sans-serif;
  --font-body: 'Noto Sans JP', -apple-system, BlinkMacSystemFont, 'Hiragino Sans', sans-serif;

  /* 寸法 */
  --lp-width: 390px;
  --content-width: 350px;
  --card-inner-width: 310px;

  /* シャドウ */
  --shadow-button: 6px 6px 10px rgba(0, 0, 0, .1);

  /* パターン (ドット) */
  --pattern-grid: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='15' height='15'><path d='M 15 0 L 0 0 0 15' fill='none' stroke='%23ff5fa8' stroke-width='1'/></svg>");
}

/* ========== 共通: 見出し ========== */
.heading-en {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 44px;
  line-height: 50px;
  color: var(--color-white);
  text-transform: uppercase;
}
.heading-en.purple {
  text-shadow:
    -3px -3px 0 var(--color-purple),
     3px -3px 0 var(--color-purple),
    -3px  3px 0 var(--color-purple),
     3px  3px 0 var(--color-purple),
    -3px  0   0 var(--color-purple),
     3px  0   0 var(--color-purple),
     0   -3px 0 var(--color-purple),
     0    3px 0 var(--color-purple);
}
.heading-en.pink {
  text-shadow:
    -3px -3px 0 var(--color-pink),
     3px -3px 0 var(--color-pink),
    -3px  3px 0 var(--color-pink),
     3px  3px 0 var(--color-pink),
    -3px  0   0 var(--color-pink),
     3px  0   0 var(--color-pink),
     0   -3px 0 var(--color-pink),
     0    3px 0 var(--color-pink);
}

/* ========== 共通: ピル (小見出し) ========== */
.pill {
  display: inline-flex;
  align-items: center;
  padding: 6px 20px;
  background: var(--color-white);
  border-radius: 50px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 16px;
}
.pill.purple { color: var(--color-purple); }
.pill.pink   { color: var(--color-pink); }

/* ========== 共通: 注釈テキスト ========== */
.caption {
  width: var(--content-width);
  margin: 0 auto;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 14px;
  color: rgba(0,0,0,.6);
  text-align: right;
  text-shadow:
    -1px -1px 0 #fff,
     1px -1px 0 #fff,
    -1px  1px 0 #fff,
     1px  1px 0 #fff,
    -1px  0   0 #fff,
     1px  0   0 #fff,
     0   -1px 0 #fff,
     0    1px 0 #fff;
}

/* ============================================================
   introduction セクション
   ============================================================ */
.introduction {
  background: var(--color-pink);
  padding: 80px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
}
.intro__head {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  width: var(--content-width);
}
.intro__text {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: var(--content-width);
  font-size: 16px;
  line-height: 32px;
  text-align: left;
  color: var(--color-white);
}
.intro__card-wrap {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.intro__card {
  position: relative;
  width: var(--content-width);
  padding: 40px 0;
  border: 4px solid var(--color-white);
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
  overflow: hidden;
}
.intro__card::before,
.intro__card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
}
.intro__card::before {
  background-color: rgba(255, 255, 255, .2);
}
.intro__card::after {
  background-image: var(--pattern-grid);
  background-size: 15px 15px;
  opacity: .4;
}
.intro__card-text {
  position: relative;
  z-index: 1;
  width: var(--card-inner-width);
  font-size: 16px;
  line-height: 32px;
  text-align: left;
  color: var(--color-white);
}
.intro__slider-wrap {
  position: relative;
  z-index: 1;
  width: 100%;
}
.intro__slider {
  width: 200px;
  margin: 0 auto;
  display: flex;
  gap: 30px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding: 0;
  scrollbar-width: none;       /* Firefox */
  -ms-overflow-style: none;    /* IE/Edge */
  -webkit-overflow-scrolling: touch;
}
.intro__slider::-webkit-scrollbar { display: none; }  /* Chrome/Safari */

.intro__arrow-box {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px 6px;
  background: var(--color-white);
  border: none;
  cursor: pointer;
  transition: transform .15s ease;
}
.intro__arrow-box:hover  { transform: translateY(-50%) scale(1.05); }
.intro__arrow-box:active { transform: translateY(-50%) scale(.95); }
.intro__arrow-box--left  { left: 10px;  border-radius: 10px 0 0 10px; }
.intro__arrow-box--right { right: 10px; border-radius: 0 10px 10px 0; }
.intro__arrow-box svg {
  display: block;
  width: 16px;
  height: 16px;
}

.intro__circle {
  flex: 0 0 200px;
  scroll-snap-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.intro__circle img {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  object-fit: cover;
}
.intro__circle-label {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 26px;
  line-height: 32px;
  color: var(--color-white);
  text-shadow:
    -2px -2px 0 var(--shadow, var(--color-red-shadow)),
     2px -2px 0 var(--shadow, var(--color-red-shadow)),
    -2px  2px 0 var(--shadow, var(--color-red-shadow)),
     2px  2px 0 var(--shadow, var(--color-red-shadow)),
    -2px  0   0 var(--shadow, var(--color-red-shadow)),
     2px  0   0 var(--shadow, var(--color-red-shadow)),
     0   -2px 0 var(--shadow, var(--color-red-shadow)),
     0    2px 0 var(--shadow, var(--color-red-shadow));
  white-space: nowrap;
}

/* ============================================================
   experience セクション
   ============================================================ */
.experience {
  background: var(--gradient-experience), var(--color-white);
  padding: 80px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
}
.exp__head {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  width: var(--content-width);
}
.exp__list {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
}
.exp__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.exp__visual {
  position: relative;
  width: var(--content-width);
}
.exp__visual img {
  width: var(--content-width);
  height: 450px;
  object-fit: cover;
  border-radius: 8px;
}
.exp__label-wrap {
  position: absolute;
  left: 10px;
  bottom: -10px;
  width: 280px;
}
.exp__label {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 60px;
  background: var(--color-pink);
  border: 4px solid var(--color-white);
  border-bottom: none;
  border-radius: 10px 10px 0 0;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 26px;
  line-height: 40px;
  color: var(--color-white);
  text-transform: uppercase;
}
.exp__body {
  position: relative;
  width: var(--content-width);
  padding: 30px 20px 40px;
  border: 4px solid var(--color-white);
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow: hidden;
}
.exp__body::before,
.exp__body::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
}
.exp__body::before {
  background: var(--gradient-card-overlay), rgba(255, 185, 223, .6);
}
.exp__body::after {
  background-image: var(--pattern-grid);
  background-size: 15px 15px;
  opacity: .4;
}
.exp__body p {
  position: relative;
  z-index: 1;
  font-size: 16px;
  line-height: 32px;
  text-align: left;
  color: var(--color-white);
}
.exp__scroll-hint {
  position: absolute;
  right: 10px;
  bottom: 10px;
  z-index: 2;
  animation: blink 1s ease-in-out infinite;
}
@keyframes blink {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0.3; }
}

/* ============================================================
   cta セクション
   ============================================================ */
.cta {
  background: var(--color-pink);
  padding: 80px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 40px;
}
.cta__title-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}
.cta__catch {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 20px;
  color: var(--color-white);
  text-transform: uppercase;
  text-shadow:
    -2px -2px 0 var(--color-purple-light),
     2px -2px 0 var(--color-purple-light),
    -2px  2px 0 var(--color-purple-light),
     2px  2px 0 var(--color-purple-light),
    -2px  0   0 var(--color-purple-light),
     2px  0   0 var(--color-purple-light),
     0   -2px 0 var(--color-purple-light),
     0    2px 0 var(--color-purple-light);
  white-space: nowrap;
}
.cta__logo {
  width: 330px;
  height: 106px;
  object-fit: contain;
}
.cta__mock-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.cta__mock {
  position: relative;
  width: 232px;
  height: 480px;
}
.cta__mock-frame {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  z-index: 2;
}
.cta__mock-inner {
  position: absolute;
  top: 7px;
  left: 9.76px;
  width: 215px;
  height: 466px;
  border-radius: 30px;
  object-fit: cover;
  z-index: 1;
}

/* ============================================================
   footer
   ============================================================ */
.site-footer {
  background: var(--gradient-footer), var(--color-white);
  display: flex;
  flex-direction: column;
  align-items: center;
}
.footer__menu {
  width: 100%;
  display: flex;
  flex-direction: column;
}
.footer__link {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 70px;
  padding: 0 10px;
  color: var(--color-white);
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 18px;
  text-transform: uppercase;
  transition: opacity .15s ease;
}
.footer__link:hover { opacity: .7; }
.footer__divider {
  width: 100%;
  height: 3px;
  background: var(--color-pink);
}
.footer__copyright {
  width: 100%;
  padding: 10px 20px;
  background: var(--color-pink);
  color: var(--color-white);
  font-weight: 700;
  font-size: 12px;
  text-align: center;
}

/* ============================================================
   モーション (アクセシビリティ配慮)
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}

/* ============================================================
   PC レイアウト (768px 以上)
   - body は通常フロー (flex 解除)
   - .lp は中央配置で通常スクロール
   - .pc-side は position: fixed で画面の左右に固定
     → スクロールしても両サイドはビューポートに張り付いたまま
   - 背景は fixed なので背景もスクロールしない
   ============================================================ */
@media (min-width: 768px) {
  body {
    min-height: 100vh;
    padding: 0;
    /* Figma 完全一致:
       - base: #FFFFFF
       - gradient: linear-gradient(180deg, #9D74F9 0%, #FF80C4 60%, #FFDA73 100%) at 30%
       - grid: introduction カード内と同じ格子 (15px / #ff5fa8 / opacity 0.4) */
    background-color: #ffffff;
    background-image:
      url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='15' height='15'><path d='M 15 0 L 0 0 0 15' fill='none' stroke='%23ff5fa8' stroke-width='1' stroke-opacity='0.4'/></svg>"),
      linear-gradient(180deg, rgba(157,116,249,.3) 0%, rgba(255,128,196,.3) 60%, rgba(255,218,115,.3) 100%);
    background-size: 20px 20px, 100% 100%;
    background-repeat: repeat, no-repeat;
    background-attachment: fixed, fixed;
  }

  /* PC ではコンテンツ列を 390 → 500px に拡大 (project-zero と同じ列幅)。
     内側コンテンツ幅・カード幅・固定幅画像も連動して拡大する。
     画像は全て2倍解像度 (mv.png 780px 等) のため拡大しても劣化しない。 */
  :root {
    --lp-width: 500px;
    --content-width: 420px;
    --card-inner-width: 375px;
  }

  .lp {
    max-width: 500px;
    margin: 0 auto;
    box-shadow: 0 20px 80px rgba(192, 161, 251, .25);
    border-radius: 10px;
    overflow: hidden;
  }

  /* 固定幅の要素も列拡大に合わせて比例拡大 (約1.2倍) */
  .intro__slider,
  .intro__circle {
    width: 240px;
  }
  .exp__label-wrap {
    width: 336px;
  }
  .cta__logo {
    width: 396px;
  }
  .cta__mock {
    width: 278px;
  }
  .cta__mock-inner {
    width: 258px;
  }

  /* PC サイドは画面に固定 (スクロール追従) */
  .pc-side {
    display: flex;
    position: fixed;
    top: 50%;
    /* left を基準点とし、translate(-50%) で装飾自体を中央寄せ
       (clamp 幅でも余白中央に正確に配置するため) */
    transform: translate(-50%, -50%);
    z-index: 10;
  }

  .pc-side--left {
    /* 左余白 (0 〜 50vw-195px) の中央 = 25vw - 97.5px に配置 (project-zero準拠) */
    left: calc(25vw - 97.5px);
    right: auto;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    filter: drop-shadow(0 0 65px rgba(255, 255, 255, .7));
  }
  .pc-side--right {
    /* 右余白 (50vw+195px 〜 100vw) の中央 = 75vw + 97.5px に配置 (project-zero準拠) */
    left: calc(75vw + 97.5px);
    right: auto;
  }

  .pc-side__catch {
    font-family: var(--font-display);
    font-weight: 900;
    font-size: clamp(13px, 1.5vw, 26px);
    color: var(--color-white);
    text-shadow: 2px 2px 0 var(--color-purple-light);
    white-space: nowrap;
    text-transform: uppercase;
  }
  .pc-side__logo {
    width: clamp(170px, 22vw, 420px);
    height: auto;
    object-fit: contain;
  }

  .pc-qr-box {
    width: clamp(150px, 16vw, 300px);
    aspect-ratio: 1 / 1;
    background: var(--color-white);
    border-radius: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 40px rgba(192, 161, 251, .25);
  }
  .pc-qr {
    width: 73%;
    height: 73%;
    display: block;
  }
}

/* ============================================================
   恋愛シミュレーションゲーム風アニメーション
   - CTA ボタン: 優しいパルス + グロー (ゲームのスタートボタン感)
   - MV ロゴ: ふわふわ float (上下に揺れる)
   - prefers-reduced-motion で全停止 (アクセシビリティ)
   ============================================================ */
.cta-button {
  animation: ctaPulse 2.5s ease-in-out infinite;
}
@keyframes ctaPulse {
  0%, 100% {
    box-shadow: 6px 6px 10px rgba(0,0,0,.1),
                0 0 0 rgba(255,185,223,0);
    transform: scale(1);
  }
  50% {
    box-shadow: 6px 6px 10px rgba(0,0,0,.1),
                0 0 30px rgba(255,185,223,.7);
    transform: scale(1.02);
  }
}
/* ホバー時はパルスを一時停止して別の動きに */
.cta-button:hover {
  animation-play-state: paused;
}

.mv__logo {
  animation: float 3.5s ease-in-out infinite;
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-8px); }
}

/* ============================================================
   テキストアニメーション (ゲーム風)
   ============================================================ */

/* スクロール時のフェードイン + スライドアップ
   JS で .reveal クラスが付与され、ビューポートに入ると .is-visible が追加される */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .8s ease-out, transform .8s ease-out;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* 見出し (INTRODUCTION / EXPERIENCE) のグローパルス */
.heading-en {
  animation: headingGlow 3s ease-in-out infinite;
}
@keyframes headingGlow {
  0%, 100% { filter: drop-shadow(0 0 0 rgba(255,255,255,0)); }
  50%      { filter: drop-shadow(0 0 12px rgba(255,255,255,.6)); }
}

/* MV キャッチコピーの登場演出 (文字間隔が広がりつつフェードイン) */
.mv__catch {
  animation: catchIn 1.2s ease-out .3s both;
}
@keyframes catchIn {
  0%   { opacity: 0; letter-spacing: -.5em; }
  100% { opacity: 1; letter-spacing: normal; }
}

/* タイピング演出: 1 文字ずつフェードイン (ゲームの会話ウィンドウ風) */
.typing-char {
  opacity: 0;
  transition: opacity .12s ease-out;
}
.typing-char.is-shown {
  opacity: 1;
}
