/**
 * HyperSpace Marketing Theme Custom Styles
 */

body {
  background: linear-gradient(180deg, #070914 0%, #0B1024 25%, #130E28 50%, #0C1226 75%, #05070E 100%);
  color: #E2E8F0;
  overflow-x: hidden;
  min-height: 100vh;
}

.space-grid {
  background-image: 
    linear-gradient(to right, rgba(99, 102, 241, 0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(99, 102, 241, 0.05) 1px, transparent 1px);
  background-size: 48px 48px;
}

.glow-cyan {
  box-shadow: 0 0 35px -5px rgba(0, 240, 255, 0.3);
}

.glow-indigo {
  box-shadow: 0 0 45px -5px rgba(99, 102, 241, 0.3);
}

.card-glass {
  background: rgba(14, 19, 38, 0.7);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-glass:hover {
  border-color: rgba(0, 240, 255, 0.4);
  background: rgba(18, 25, 50, 0.8);
  transform: translateY(-2px);
}

.text-gradient {
  background: linear-gradient(135deg, #FFFFFF 0%, #E0E7FF 45%, #00F0FF 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.text-gradient-purple {
  background: linear-gradient(135deg, #C084FC 0%, #818CF8 50%, #00F0FF 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-bg-cover {
  background-image: url('../images/hsm_hyperspace_cover.jpg');
  background-size: cover;
  background-position: center center;
}

/* 星々の瞬きアニメーション */
@keyframes star-twinkle {
  0%, 100% { opacity: 0.2; transform: scale(0.8); }
  50% { opacity: 0.8; transform: scale(1.2); }
}
.twinkle-1 { animation: star-twinkle 3s ease-in-out infinite; }
.twinkle-2 { animation: star-twinkle 4.5s ease-in-out infinite 1s; }
.twinkle-3 { animation: star-twinkle 6s ease-in-out infinite 2s; }

/* ファルコン号の漂うアニメーション（ページ中ほど・スクロール非追従） */
@keyframes falcon-float-mid {
  0%, 100% { transform: translateY(0px) rotate(-14deg); }
  50% { transform: translateY(-16px) rotate(-12deg); }
}
.falcon-mid-motion {
  animation: falcon-float-mid 14s ease-in-out infinite;
}

/* Xウイング浮遊アニメーション */
@keyframes xwing-float {
  0%, 100% { transform: translateY(0px) rotate(12deg); }
  50% { transform: translateY(-14px) rotate(15deg); }
}
.xwing-motion {
  animation: xwing-float 10s ease-in-out infinite;
}

/* タイ・ファイター浮遊アニメーション */
@keyframes tie-float {
  0%, 100% { transform: translateY(0px) rotate(-8deg); }
  50% { transform: translateY(12px) rotate(-5deg); }
}
.tie-motion {
  animation: tie-float 12s ease-in-out infinite;
}

/* アニメーション要素 */
.hidden-droid {
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.hidden-droid.discovered {
  transform: scale(2.4);
  opacity: 1 !important;
  filter: drop-shadow(0 0 12px rgba(251, 191, 36, 0.8));
}
.hidden-droid-r2.discovered {
  transform: scale(2.4);
  opacity: 1 !important;
  filter: drop-shadow(0 0 12px rgba(0, 240, 255, 0.8));
}
.hidden-droid-bb8.discovered {
  transform: scale(2.4);
  opacity: 1 !important;
  filter: drop-shadow(0 0 14px rgba(234, 88, 12, 0.9));
}

/* 発見後のモーダル吹き出し */
.droid-bubble {
  display: none;
  animation: popIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}
.droid-bubble.active {
  display: block;
}
@keyframes popIn {
  0% { opacity: 0; transform: translateY(10px) scale(0.9); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}

#back-to-top {
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

#back-to-top.visible {
  opacity: 1;
  visibility: visible;
}
