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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Hiragino Sans', sans-serif;
  background: linear-gradient(to bottom, #020617, #0f172a, #1e1b4b);
  min-height: 100vh;
  color: white;
  overflow-x: hidden;
}

.serif {
  font-family: 'Noto Serif JP', serif;
}

/* 星空背景 */
.star-field {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

.star {
  position: absolute;
  background: #fef08a;
  border-radius: 50%;
  box-shadow: 0 0 6px 2px rgba(255, 215, 0, 0.6);
  animation: twinkle 3s ease-in-out infinite;
}

@keyframes twinkle {

  0%,
  100% {
    opacity: 0.3;
    transform: scale(1);
  }

  50% {
    opacity: 1;
    transform: scale(1.2);
  }
}

/* 三日月 */
.crescent-moon {
  filter: drop-shadow(0 0 10px rgba(255, 215, 0, 0.5));
  position: relative;
  z-index: 5;
}

.intro-moon {
  margin-bottom: 0.25rem;
}

@keyframes pulse {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.7;
  }
}

.animate-pulse {
  animation: pulse 2s ease-in-out infinite;
}

/* 画面コンテナ */
.screen {
  display: none;
  position: relative;
  z-index: 10;
}

.screen.active {
  display: flex;
}

/* ホワイトアウトオーバーレイ */
.whiteout-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: white;
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
}

.whiteout-overlay.active {
  animation: whiteout 0.6s ease-out forwards;
  pointer-events: auto;
}

@keyframes whiteout {
  0% {
    opacity: 0;
  }

  50% {
    opacity: 1;
  }

  100% {
    opacity: 0;
  }
}

/* ディゾルブ（フェード）アニメーション */
.screen.fade-out {
  animation: fadeOut 0.5s ease-out forwards;
}

.screen.fade-in {
  animation: fadeIn 0.5s ease-in forwards;
}

@keyframes fadeOut {
  0% {
    opacity: 1;
  }

  100% {
    opacity: 0;
  }
}

@keyframes fadeIn {
  0% {
    opacity: 0;
  }

  100% {
    opacity: 1;
  }
}

/* イントロ画面 */
.intro-screen {
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  min-height: 100vh;
  padding: 0 1.5rem 1.5rem;
  text-align: center;
}

.main-visual {
  width: 100vw;
  max-width: none;
  height: auto;
  border-radius: 0;
  margin: 0 -1.5rem 1rem -1.5rem;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
  object-fit: cover;
}

.sub-catch {
  color: #fcd34d;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  margin-bottom: 0.25rem;
}

.main-catch {
  font-size: 1.75rem;
  color: #fcd34d;
  margin-bottom: 0.5rem;
  font-weight: 300;
}

.description {
  color: #d1d5db;
  font-size: 0.75rem;
  line-height: 1.8;
  margin-bottom: 1.25rem;
}

.form-container {
  width: 100%;
  max-width: 300px;
  margin: 0 auto;
}

.input-label {
  color: #9ca3af;
  font-size: 0.75rem;
  margin-bottom: 0.375rem;
  margin-top: 0.75rem;
}

.input-label:first-of-type {
  margin-top: 0;
}

.name-inputs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  width: 100%;
  max-width: 100%;
}

.name-input {
  flex: 1;
  padding: 0.5rem 0.75rem;
  background: rgba(30, 41, 59, 0.8) !important;
  border: 1px solid rgba(202, 138, 4, 0.3) !important;
  border-radius: 0.5rem;
  color: white !important;
  font-size: 16px;
  /* iPhoneの自動拡大を防ぐため16px以上に設定 */
  outline: none;
  box-sizing: border-box;
}

.name-input::placeholder {
  color: rgba(156, 163, 175, 0.6) !important;
}

.name-input:focus {
  border-color: #eab308 !important;
}

.email-input {
  width: 100%;
  max-width: 100%;
  padding: 0.5rem 0.75rem;
  background: rgba(30, 41, 59, 0.8) !important;
  border: 1px solid rgba(202, 138, 4, 0.3) !important;
  border-radius: 0.5rem;
  color: white !important;
  font-size: 16px;
  /* iPhoneの自動拡大を防ぐため16px以上に設定 */
  outline: none;
  margin-bottom: 0.75rem;
  box-sizing: border-box;
}

.email-input::placeholder {
  color: rgba(156, 163, 175, 0.6) !important;
}

.email-input:focus {
  border-color: #eab308 !important;
}

.policy-agreement {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  margin-top: 0.5rem;
}

.policy-checkbox {
  width: 1.1rem;
  height: 1.1rem;
  margin: 0;
  cursor: pointer;
  accent-color: #fcd34d;
  flex-shrink: 0;
}

.email-notice {
  color: #9ca3af;
  font-size: 0.75rem;
  text-align: left;
  line-height: 1.2;
  cursor: pointer;
  margin: 0;
}

.policy-link {
  color: #fcd34d;
  text-decoration: underline;
  transition: color 0.3s;
}

.policy-link:hover {
  color: #eab308;
}

.date-inputs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.date-select {
  flex: 1;
  padding: 0.5rem 0.75rem;
  background: rgba(30, 41, 59, 0.8) !important;
  border: 1px solid rgba(202, 138, 4, 0.3) !important;
  border-radius: 0.5rem;
  color: white !important;
  font-size: 16px;
  /* iPhoneの自動拡大を防ぐため16px以上に設定 */
  appearance: none;
  cursor: pointer;
  outline: none;
  box-sizing: border-box;
}

.date-select:focus {
  border-color: #eab308 !important;
}

/* MyASPのクラスにも対応 */
.form_input_datetime1 {
  background: rgba(30, 41, 59, 0.8) !important;
  border: 1px solid rgba(202, 138, 4, 0.3) !important;
  color: white !important;
}

.form_input_datetime1:focus {
  border-color: #eab308 !important;
}

input.required,
input.form_input_datetime1,
select.required,
select.form_input_datetime1 {
  background: rgba(30, 41, 59, 0.8) !important;
  border: 1px solid rgba(202, 138, 4, 0.3) !important;
  color: white !important;
}

input.required:focus,
select.required:focus,
input.form_input_datetime1:focus,
select.form_input_datetime1:focus {
  border-color: #eab308 !important;
}

.summon-btn {
  padding: 0.875rem 2rem;
  background: linear-gradient(to right, #ca8a04, #eab308);
  color: white;
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  border: none;
  border-radius: 9999px;
  cursor: pointer;
  box-shadow: 0 10px 25px rgba(234, 179, 8, 0.3);
  transition: all 0.3s;
}

.summon-btn:hover {
  background: linear-gradient(to right, #eab308, #facc15);
}

.credit {
  color: #6b7280;
  font-size: 0.75rem;
  margin-top: 1rem;
}

/* ローディング画面 */
.loading-screen {
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  min-height: 100dvh;
  /* iOS Safari対応 */
  max-height: 100vh;
  max-height: 100dvh;
  padding: 1.5rem;
  text-align: center;
  overflow: hidden;
}

.loading-container {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: min(300px, 80vw);
  height: min(300px, 80vw);
}

.magic-circle-container {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  height: 100%;
  z-index: -1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.loading-screen.active .magic-circle {
  animation: magicSummon 3.5s ease-out forwards;
}

.magic-circle {
  width: 0;
  height: 0;
  opacity: 0;
  filter: drop-shadow(0 0 15px rgba(255, 215, 0, 0.5));
}

.loading-screen.active .magic-glow {
  animation: glowSummon 3.5s ease-out forwards;
}

.magic-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 0;
  height: 0;
  background: radial-gradient(circle, rgba(255, 215, 0, 0.4) 0%, transparent 70%);
  border-radius: 50%;
  opacity: 0;
}

@keyframes magicSummon {
  0% {
    width: 0;
    height: 0;
    opacity: 0;
    transform: rotate(0deg);
  }

  20% {
    width: 60%;
    height: 60%;
    opacity: 0.8;
    transform: rotate(90deg);
  }

  80% {
    width: 100%;
    height: 100%;
    opacity: 1;
    transform: rotate(360deg);
  }

  100% {
    width: 120%;
    height: 120%;
    opacity: 0;
    transform: rotate(450deg);
  }
}

@keyframes glowSummon {
  0% {
    width: 0;
    height: 0;
    opacity: 0;
  }

  30% {
    width: 60%;
    height: 60%;
    opacity: 0.5;
  }

  80% {
    width: 130%;
    height: 130%;
    opacity: 0.8;
  }

  100% {
    width: 200%;
    height: 200%;
    opacity: 0;
  }
}

.loading-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  animation: ping 1.5s ease-out infinite;
  z-index: 1;
}

.loading-ring-1 {
  width: 6rem;
  height: 6rem;
  border: 2px solid rgba(234, 179, 8, 0.3);
}

.loading-ring-2 {
  width: 8rem;
  height: 8rem;
  border: 1px solid rgba(234, 179, 8, 0.2);
  animation-delay: 0.5s;
}

@keyframes ping {
  0% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
  }

  100% {
    transform: translate(-50%, -50%) scale(1.5);
    opacity: 0;
  }
}

.loading-text {
  color: #fcd34d;
  font-size: 1.125rem;
  letter-spacing: 0.1em;
  margin-top: 2rem;
  animation: pulse 1.5s ease-in-out infinite;
}

.loading-sub {
  color: #6b7280;
  font-size: 0.75rem;
  margin-top: 0.5rem;
}

/* 結果画面 */
.result-screen {
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
  /* iOS Safari対応 */
  padding: 1rem 1rem;
}

.result-container {
  max-width: 28rem;
  margin: 0 auto;
  width: 100%;
  position: relative;
}

/* 召喚成功時の光るエフェクト */
.result-container.summon-success {
  animation: summonGlow 1s ease-out;
}

@keyframes summonGlow {
  0% {
    opacity: 0;
    transform: scale(0.95);
    filter: brightness(1);
  }

  50% {
    opacity: 1;
    transform: scale(1.02);
    filter: brightness(2) drop-shadow(0 0 30px rgba(255, 255, 255, 0.8));
  }

  100% {
    opacity: 1;
    transform: scale(1);
    filter: brightness(1);
  }
}

.result-container.summon-success::before {
  content: '';
  position: absolute;
  top: -10px;
  left: -10px;
  right: -10px;
  bottom: -10px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.4) 0%, transparent 70%);
  border-radius: 1.5rem;
  animation: lightPulse 1s ease-out;
  pointer-events: none;
  z-index: -1;
}

@keyframes lightPulse {
  0% {
    opacity: 0;
    transform: scale(0.8);
  }

  50% {
    opacity: 1;
    transform: scale(1.1);
  }

  100% {
    opacity: 0;
    transform: scale(1.2);
  }
}

.result-header {
  text-align: center;
  margin-bottom: 0.75rem;
}

.result-complete {
  color: rgba(252, 211, 77, 0.8);
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  margin-bottom: 0.25rem;
}

.result-complete-text {
  color: white;
  font-size: 0.875rem;
}

.goddess-intro {
  text-align: center;
  margin-bottom: 1.5rem;
}

.zodiac-image-card {
  width: 100%;
  max-width: min(18rem, 55vw, calc(50vh * (1066 / 1600)));
  aspect-ratio: 1066 / 1600;
  margin: 0 auto 0.75rem;
  position: relative;
  transform-style: preserve-3d;
  perspective: 1000px;
  transform-origin: center center;
}

.card-face {
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  border-radius: 1rem;
  overflow: hidden;
}

/* カードの高さを画像に合わせる */
.card-face img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.card-front {
  position: relative;
  background: rgba(30, 41, 59, 0.5);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(202, 138, 4, 0.3);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
  transform: rotateY(0deg);
  z-index: 2;
}

.card-back {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(30, 41, 59, 0.5);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(202, 138, 4, 0.3);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
  transform: rotateY(180deg);
  z-index: 1;
}

.zodiac-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 1rem;
  display: block;
}

.card-back-image {
  width: 100%;
  height: auto;
  border-radius: 1rem;
  display: block;
}

/* 女神カードの3D回転アニメーション */
.zodiac-image-card.rotate {
  animation: cardFlip3D 0.4s ease-in-out;
}

@keyframes cardFlip3D {
  0% {
    transform: perspective(1000px) rotateY(0deg) rotateX(5deg);
  }

  50% {
    transform: perspective(1000px) rotateY(180deg) rotateX(5deg);
  }

  100% {
    transform: perspective(1000px) rotateY(360deg) rotateX(5deg);
  }
}

.goddess-name {
  font-size: 1.875rem;
  color: white;
  margin-bottom: 0.25rem;
}

.goddess-name-en {
  color: rgba(202, 138, 4, 0.8);
  font-size: 0.75rem;
  letter-spacing: 0.05em;
}

.keywords {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.keyword {
  padding: 0.25rem 0.75rem;
  background: rgba(202, 138, 4, 0.2);
  border: 1px solid rgba(202, 138, 4, 0.3);
  border-radius: 9999px;
  color: #fcd34d;
  font-size: 0.75rem;
}

.card {
  background: rgba(30, 41, 59, 0.5);
  backdrop-filter: blur(10px);
  border-radius: 1rem;
  padding: 1.25rem;
  margin-bottom: 1rem;
  border: 1px solid rgba(202, 138, 4, 0.2);
}

.card-gold {
  background: linear-gradient(to bottom right, rgba(202, 138, 4, 0.2), rgba(146, 64, 14, 0.2));
  border: 1px solid rgba(234, 179, 8, 0.3);
}

.card-dark {
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(202, 138, 4, 0.3);
  padding: 0;
  /* 画像を端まで表示するため */
  overflow: hidden;
}

.cta-image {
  width: 100%;
  height: auto;
  display: block;
  margin-bottom: 1.5rem;
}

.card-dark>p,
.card-dark>a {
  padding-left: 1.25rem;
  padding-right: 1.25rem;
}

.card-dark .cta-btn {
  margin: 0 1.25rem 1.5rem;
  width: auto;
  display: block;
  text-align: center;
}

/* 女神からの啓示 - 神秘的なグラデーション */
.card-revelation {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.15) 0%, rgba(217, 70, 239, 0.15) 50%, rgba(236, 72, 153, 0.15) 100%);
  border: 1px solid rgba(217, 70, 239, 0.3);
  position: relative;
  overflow: hidden;
}

.profile-full-card {
  padding: 0 !important;
  overflow: hidden;
  border: 1px solid rgba(202, 138, 4, 0.3);
}

.profile-full-image {
  width: 100%;
  height: auto;
  display: block;
}

.card-revelation::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.05) 0%, transparent 50%);
  animation: shimmer 8s infinite linear;
}

@keyframes shimmer {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

/* 宿命の解読（あやの）- 星空・夜空のイメージ */
.card-ayano {
  background: linear-gradient(180deg, rgba(30, 27, 75, 0.9) 0%, rgba(49, 46, 129, 0.7) 50%, rgba(30, 27, 75, 0.9) 100%);
  border: 1px solid rgba(139, 92, 246, 0.3);
}

/* 運命の変革（佳菜）- 温かみのある暖色系 */
.card-kana {
  background: linear-gradient(135deg, rgba(251, 146, 60, 0.15) 0%, rgba(244, 114, 182, 0.15) 100%);
  border: 1px solid rgba(251, 146, 60, 0.3);
}

.card-title {
  color: rgba(252, 211, 77, 0.8);
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  margin-bottom: 0.75rem;
}

.card-subtitle {
  color: #9ca3af;
  font-size: 0.75rem;
  margin-bottom: 0.75rem;
}

/* カードヘッダー（タイトル・肩書き部分） */
.card-header {
  margin-bottom: 0.5rem;
}

/* 肩書きスタイル */
.card-role {
  color: #f472b6;
  font-size: 0.7rem;
  letter-spacing: 0.05em;
  margin-bottom: 0.25rem;
}

/* カードボディ（本文と画像） */
.card-body {
  overflow: hidden;
}

/* プロフィール画像 */
.profile-image {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid rgba(252, 211, 77, 0.5);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

/* 右上に配置（テキスト回り込み） */
.profile-image-right {
  float: right;
  margin: 0 0 0.75rem 1rem;
  shape-outside: circle(50%);
}

/* プロフィール画像付きカード */
.card-with-profile {
  overflow: hidden;
}

.card-with-profile .card-content {
  overflow: hidden;
}

/* ========== 新レイアウト: プロフィールカード ========== */
.card-profile {
  padding: 1.5rem;
}

/* ヘッダー部分（タイトル+写真横並び） */
.card-profile-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(252, 211, 77, 0.2);
}

/* タイトル・肩書き・名前エリア */
.card-profile-info {
  flex: 1;
}

/* 大きめタイトル */
.card-title-large {
  color: rgba(252, 211, 77, 0.9);
  font-size: 1.125rem;
  letter-spacing: 0.1em;
  margin-bottom: 0.5rem;
  font-weight: 500;
}

/* 大きめ肩書き */
.card-role-large {
  color: #f472b6;
  font-size: 0.875rem;
  letter-spacing: 0.05em;
  margin-bottom: 0.375rem;
}

/* 大きめ名前 */
.card-name-large {
  color: #d1d5db;
  font-size: 0.9375rem;
  letter-spacing: 0.05em;
}

/* ヘッダー内のプロフィール画像 */
.profile-image-header {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid rgba(252, 211, 77, 0.5);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  flex-shrink: 0;
}

/* スマホ対応: プロフィールカードのヘッダーを縦並びにする */
@media (max-width: 480px) {
  .card-profile-header {
    flex-direction: column-reverse;
    align-items: center;
    text-align: center;
  }

  .profile-image-header {
    width: 100px;
    height: 100px;
    margin-bottom: 0.5rem;
  }

  .card-title-large {
    font-size: 1rem;
  }
}

.message-text {
  color: #e5e7eb;
  font-size: 0.875rem;
  line-height: 1.8;
  white-space: pre-line;
}

.affirmation-text {
  color: white;
  font-size: 1rem;
  line-height: 1.6;
  text-align: center;
}

.lucky-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.lucky-item:last-child {
  margin-bottom: 0;
}

.color-circle {
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.3);
}

.power-icon {
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: rgba(202, 138, 4, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fcd34d;
}

.lucky-label {
  color: #9ca3af;
  font-size: 0.75rem;
}

.lucky-value {
  color: white;
  font-size: 0.875rem;
}

.cta-text {
  color: #d1d5db;
  font-size: 0.875rem;
  line-height: 1.6;
  margin-bottom: 1rem;
}

.cta-text .highlight {
  color: #fcd34d;
}

.cta-sub {
  color: #9ca3af;
  font-size: 0.75rem;
  line-height: 1.6;
  margin-bottom: 1rem;
}

.cta-credit {
  color: #6b7280;
  font-size: 0.75rem;
  margin-bottom: 0.75rem;
}

.cta-btn {
  display: block;
  width: 100%;
  padding: 0.875rem;
  background: linear-gradient(to right, #ca8a04, #eab308);
  color: white;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-align: center;
  text-decoration: none;
  border: none;
  border-radius: 9999px;
  cursor: pointer;
  box-shadow: 0 10px 25px rgba(234, 179, 8, 0.3);
  transition: all 0.3s;
}

.cta-btn:hover {
  background: linear-gradient(to right, #eab308, #facc15);
}

.cta-note {
  color: #9ca3af;
  font-size: 0.75rem;
  margin-top: 0.75rem;
  text-align: center;
}

.reset-container {
  display: flex;
  justify-content: center;
  margin-top: 0.5rem;
}

/* アプリ説明セクション */
.app-description {
  margin-top: 2.5rem;
  padding: 1.5rem;
  background: rgba(30, 41, 59, 0.5);
  border-radius: 1rem;
  border: 1px solid rgba(202, 138, 4, 0.2);
  text-align: left;
  max-width: 800px;
  width: 100%;
}

.app-desc-title {
  color: #fcd34d;
  font-size: 1.5rem;
  font-weight: 500;
  line-height: 1.6;
  margin-bottom: 1rem;
  text-align: center;
}

.title-line {
  display: inline;
}

/* 女神カード一覧グリッド */
.goddess-cards-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.goddess-cards-grid img {
  width: 100%;
  height: auto;
  border-radius: 0.5rem;
  border: 1px solid rgba(202, 138, 4, 0.3);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s, box-shadow 0.3s;
}

.goddess-cards-grid img:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 15px rgba(202, 138, 4, 0.4);
  cursor: pointer;
}

/* ライトボックス */
.lightbox {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  height: 100dvh;
  /* モバイルSafari対応 */
  background: rgba(0, 0, 0, 0.95);
  z-index: 10000;
  justify-content: center;
  align-items: center;
  padding: 1rem;
  -webkit-overflow-scrolling: touch;
}

.lightbox.active {
  display: flex;
}

.lightbox-content {
  position: relative;
  max-width: 90vw;
  max-height: 85vh;
  max-height: 85dvh;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lightbox-content img {
  max-width: 100%;
  max-height: 70vh;
  max-height: 70dvh;
  border-radius: 1rem;
  border: 3px solid #ca8a04;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), 0 0 30px rgba(202, 138, 4, 0.3);
  -webkit-touch-callout: none;
}

.lightbox-close {
  position: absolute;
  top: -10px;
  right: -10px;
  width: 44px;
  height: 44px;
  background: #ca8a04;
  border: none;
  border-radius: 50%;
  color: white;
  font-size: 1.5rem;
  cursor: pointer;
  z-index: 10001;
  transition: transform 0.3s;
  -webkit-tap-highlight-color: transparent;
}

.lightbox-close:hover {
  transform: scale(1.1);
}

.lightbox-caption {
  color: #fcd34d;
  font-size: 1.25rem;
  margin-top: 1rem;
  letter-spacing: 0.1em;
}

/* スマホ用ライトボックス調整 */
@media (max-width: 600px) {
  .lightbox {
    padding: 0.5rem;
  }

  .lightbox-content {
    max-width: 95vw;
    max-height: 90vh;
    max-height: 90dvh;
  }

  .lightbox-content img {
    max-height: 75vh;
    max-height: 75dvh;
  }

  .lightbox-close {
    top: 5px;
    right: 5px;
    width: 48px;
    height: 48px;
    font-size: 1.75rem;
  }

  .lightbox-caption {
    font-size: 1rem;
    margin-top: 0.75rem;
  }
}

/* スマホ対応：調整 */
@media (max-width: 600px) {
  .goddess-cards-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 0.375rem;
  }

  .app-description {
    padding: 1rem 0.75rem;
    margin-left: -0.5rem;
    margin-right: -0.5rem;
    max-width: calc(100% + 1rem);
  }

  .app-desc-title {
    font-size: 1.125rem;
  }

  .title-line {
    display: block;
  }

  .app-desc-text {
    font-size: 0.875rem;
  }

  .br-pc {
    display: none;
  }
}

.app-desc-text {
  color: #d1d5db;
  font-size: 1.125rem;
  line-height: 1.8;
  margin-bottom: 1rem;
}

.app-desc-text:last-child {
  margin-bottom: 0;
}

.app-desc-text strong {
  color: #fcd34d;
}

.app-desc-text.highlight-text {
  color: #fcd34d;
  font-weight: 500;
  text-align: center;
  margin-top: 1.5rem;
}

.supervisor-section {
  margin-top: 2rem;
  text-align: center;
  width: 100%;
}

.supervisor-title {
  color: rgba(252, 211, 77, 0.9);
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  margin-bottom: 1rem;
}

.supervisor-image {
  width: 100%;
  max-width: 800px;
  border-radius: 1rem;
  border: 1px solid rgba(202, 138, 4, 0.3);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

.reset-btn {
  padding: 0.5rem 1.5rem;
  background: transparent;
  border: 1px solid #4b5563;
  color: #9ca3af;
  font-size: 0.75rem;
  border-radius: 9999px;
  cursor: pointer;
  transition: all 0.3s;
}

.reset-btn:hover {
  border-color: #6b7280;
  color: #d1d5db;
}

.copyright {
  text-align: center;
  color: #4b5563;
  font-size: 0.75rem;
  margin-top: 1.5rem;
}


/* スマートフォン向けレスポンシブ調整 */
@media screen and (max-height: 700px) {
  .result-screen {
    padding: 0.5rem 1rem;
  }

  .result-header {
    margin-bottom: 0.5rem;
  }

  .result-complete {
    font-size: 0.625rem;
    margin-bottom: 0.125rem;
  }

  .result-complete-text {
    font-size: 0.75rem;
  }

  .goddess-intro {
    margin-bottom: 1rem;
  }

  .zodiac-image-card {
    max-width: min(14rem, 50vw);
    max-height: 45vh;
    max-height: 45dvh;
    margin-bottom: 0.5rem;
  }

  .zodiac-image {
    max-height: 45vh;
    max-height: 45dvh;
  }

  .goddess-name {
    font-size: 1.5rem;
    margin-bottom: 0.125rem;
  }

  .goddess-name-en {
    font-size: 0.625rem;
  }

  .keywords {
    margin-bottom: 1rem;
    gap: 0.375rem;
  }

  .keyword {
    padding: 0.125rem 0.5rem;
    font-size: 0.625rem;
  }
}

/* 更に小さい画面向け（iPhone SE等） */
@media screen and (max-height: 600px) {
  .result-screen {
    padding: 0.25rem 0.75rem;
  }

  .zodiac-image-card {
    max-width: min(12rem, 45vw);
    max-height: 40vh;
    max-height: 40dvh;
  }

  .zodiac-image {
    max-height: 40vh;
    max-height: 40dvh;
  }

  .goddess-name {
    font-size: 1.25rem;
  }
}

/* タブレット向けレスポンシブ (768px以上) */
@media screen and (min-width: 768px) {
  .intro-screen {
    padding: 0 2rem 2rem;
    justify-content: flex-start;
  }

  .main-visual {
    width: 100%;
    max-width: 32rem;
    margin: 0 auto 0.75rem auto;
    border-radius: 1rem;
  }

  .sub-catch {
    font-size: 1rem;
    margin-bottom: 0.5rem;
  }

  .main-catch {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
  }

  .description {
    font-size: 1rem;
    margin-bottom: 2rem;
  }

  .form-container {
    max-width: 400px;
  }

  .input-label {
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
    margin-top: 1rem;
  }

  .date-inputs,
  .name-inputs {
    gap: 0.75rem;
    margin-bottom: 1rem;
  }

  .date-select,
  .name-input,
  .email-input {
    padding: 0.75rem 1rem;
    font-size: 1rem;
  }

  .email-notice {
    font-size: 0.75rem;
    margin-bottom: 1rem;
  }

  .summon-btn {
    padding: 1rem 2.5rem;
    font-size: 1.125rem;
    margin-top: 0.5rem;
  }

  .credit {
    font-size: 0.875rem;
    margin-top: 1.5rem;
  }

  /* ローディング画面 */
  .loading-container .crescent-moon {
    width: 100px;
    height: 100px;
  }

  .loading-ring-1 {
    width: 8rem;
    height: 8rem;
  }

  .loading-ring-2 {
    width: 10rem;
    height: 10rem;
  }

  .loading-text {
    font-size: 1.5rem;
    margin-top: 2.5rem;
  }

  .loading-sub {
    font-size: 1rem;
    margin-top: 0.75rem;
  }

  /* 結果画面 */
  .result-screen {
    padding: 2rem;
  }

  .result-container {
    max-width: 36rem;
  }

  .result-complete {
    font-size: 1rem;
  }

  .result-complete-text {
    font-size: 1.125rem;
  }

  .zodiac-image-card {
    max-width: 22rem;
  }

  .goddess-name {
    font-size: 2.5rem;
  }

  .goddess-name-en {
    font-size: 1rem;
  }

  .keywords {
    gap: 0.75rem;
    margin-bottom: 2rem;
  }

  .keyword {
    padding: 0.375rem 1rem;
    font-size: 0.875rem;
  }

  .card {
    padding: 1.5rem;
    margin-bottom: 1.25rem;
  }

  .card-title {
    font-size: 0.875rem;
    margin-bottom: 1rem;
  }

  .message-text {
    font-size: 1rem;
    line-height: 2;
  }

  .affirmation-text {
    font-size: 1.25rem;
  }

  .lucky-label {
    font-size: 0.875rem;
  }

  .lucky-value {
    font-size: 1rem;
  }

  .cta-text {
    font-size: 1rem;
  }

  .cta-sub {
    font-size: 0.875rem;
  }

  .cta-btn {
    padding: 1rem;
    font-size: 1rem;
  }

  .reset-btn {
    padding: 0.625rem 2rem;
    font-size: 0.875rem;
  }
}

/* PC向けレスポンシブ (1024px以上) */
@media screen and (min-width: 1024px) {
  .intro-screen {
    padding: 0 2rem 2rem;
  }

  .main-visual {
    max-width: 36rem;
    margin-bottom: 1rem;
  }

  .sub-catch {
    font-size: 1.125rem;
  }

  .main-catch {
    font-size: 3rem;
    margin-bottom: 1rem;
  }

  .description {
    font-size: 1.125rem;
    margin-bottom: 2.5rem;
  }

  .form-container {
    max-width: 450px;
  }

  .date-select,
  .name-input,
  .email-input {
    padding: 0.875rem 1.25rem;
  }

  .summon-btn {
    padding: 1.125rem 3rem;
    font-size: 1.25rem;
  }

  /* 結果画面 */
  .result-container {
    max-width: 42rem;
  }

  .zodiac-image-card {
    max-width: 26rem;
  }

  .goddess-name {
    font-size: 3rem;
  }

  .goddess-name-en {
    font-size: 1.125rem;
  }

  .card {
    padding: 2rem;
    margin-bottom: 1.5rem;
  }

  .message-text {
    font-size: 1.125rem;
  }

  .affirmation-text {
    font-size: 1.5rem;
  }
}