:root {
  --bg: #0a0812;
  --panel: #15111f;
  --panel-raised: #1c1728;
  --ink: #eee9fb;
  --ink-soft: #a89bc4;
  --sub: #8a8fa3;
  --accent: #d153ee;
  --accent-2: #7c3aed;
  --accent-glow: rgba(209, 83, 238, 0.55);
  --accent-soft: rgba(209, 83, 238, 0.12);
  --grid-line: rgba(138, 143, 163, 0.14);
  --shadow: 0 12px 32px rgba(0, 0, 0, 0.55);
  --radius: 14px;
  --neon-text: #fff;
  --heading-font-en: 'Monoton', 'RocknRoll One', 'Zen Kaku Gothic New', sans-serif;
  --heading-font-jp: 'RocknRoll One', 'Zen Kaku Gothic New', sans-serif;
}

:root[data-theme='light'] {
  --bg: #f1eef8;
  --panel: #ffffff;
  --panel-raised: #ffffff;
  --ink: #221c2e;
  --ink-soft: #5b5470;
  --sub: #565b60;
  --accent: #a52ec9;
  --accent-2: #7c3aed;
  --accent-glow: rgba(165, 46, 201, 0.35);
  --accent-soft: rgba(165, 46, 201, 0.1);
  --grid-line: rgba(86, 91, 96, 0.16);
  --shadow: 0 12px 28px rgba(34, 28, 46, 0.14);
  --neon-text: #221c2e;
  --heading-font-en: 'Kiwi Maru', 'Zen Kaku Gothic New', sans-serif;
  --heading-font-jp: 'Kiwi Maru', 'Zen Kaku Gothic New', sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    linear-gradient(var(--grid-line) 1px, transparent 1px) 0 0 / 100% 42px,
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px) 0 0 / 42px 100%,
    var(--bg);
  color: var(--ink);
  font-family: 'LINE Seed JP', 'Zen Kaku Gothic New', 'Hiragino Kaku Gothic ProN', sans-serif;
  line-height: 1.8;
  letter-spacing: 0.02em;
  transition: background-color 0.3s ease, color 0.3s ease;
}

h1, h2, .nav-logo, .hero-line, .hero-line-sub {
  font-family: var(--heading-font-en);
  font-weight: 400;
}

a {
  color: var(--accent);
}

.hidden {
  display: none !important;
}

.material-symbols-outlined {
  font-family: 'Material Symbols Outlined';
  font-weight: normal;
  font-style: normal;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  display: inline-block;
  white-space: nowrap;
  word-wrap: normal;
  direction: ltr;
  -webkit-font-smoothing: antialiased;
  font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
  vertical-align: middle;
}

/* --- 追従ナビ (glassmorphism) --- */

#nav-bar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 24px;
  background: color-mix(in srgb, var(--bg) 55%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--grid-line);
}

.nav-logo {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 1rem;
  text-decoration: none;
  color: var(--neon-text);
  text-shadow: 0 0 8px var(--accent), 0 0 18px var(--accent-glow);
  white-space: nowrap;
  letter-spacing: 0.02em;
}

.logo-icon {
  width: 22px;
  height: 22px;
  filter: drop-shadow(0 0 6px var(--accent-glow));
}

.nav-links {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.nav-links a {
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  border-bottom: 2px solid transparent;
  padding-bottom: 2px;
  transition: border-color 0.2s ease, color 0.2s ease, text-shadow 0.2s ease;
}

.nav-links a:hover {
  color: var(--accent);
  border-color: var(--accent);
  text-shadow: 0 0 8px var(--accent-glow);
}

#theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--grid-line);
  background: var(--panel-raised);
  border-radius: 999px;
  width: 36px;
  height: 36px;
  cursor: pointer;
  color: var(--ink);
  flex-shrink: 0;
  box-shadow: 0 0 0 rgba(0, 0, 0, 0);
  transition: box-shadow 0.2s ease;
}

#theme-toggle:hover {
  box-shadow: 0 0 14px var(--accent-glow);
}

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

#hero {
  position: relative;
  padding: 88px 24px 72px;
  text-align: center;
  overflow: hidden;
}

#hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 15%, var(--accent-soft), transparent 42%),
    radial-gradient(circle at 82% 80%, rgba(124, 58, 237, 0.16), transparent 45%);
  pointer-events: none;
}

.hero-eyebrow {
  margin: 0 0 8px;
  font-size: 0.78rem;
  letter-spacing: 0.35em;
  color: var(--ink-soft);
  opacity: 0;
  animation: hero-rise 0.6s ease forwards;
  animation-delay: calc(var(--i) * 0.16s);
}

.hero-title {
  margin: 0;
  font-size: clamp(2.1rem, 6vw, 3.6rem);
  line-height: 1.25;
}

.hero-line {
  display: block;
  opacity: 0;
  transform: translateY(18px);
  animation: hero-rise 0.7s ease forwards;
  animation-delay: calc(var(--i) * 0.16s);
  color: var(--neon-text);
  text-shadow: 0 0 10px var(--accent-glow), 0 0 24px var(--accent-glow);
}

.hero-line-sub {
  color: var(--neon-text);
  text-shadow:
    0 0 10px var(--accent),
    0 0 24px var(--accent),
    0 0 48px var(--accent),
    0 0 90px var(--accent-glow);
}

@keyframes hero-rise {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* --- セクション共通 --- */

main {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 24px 80px;
}

.section {
  position: relative;
  padding: 48px 0 24px;
}

.section::before {
  content: '';
  display: block;
  width: 100%;
  height: 2px;
  margin-bottom: 36px;
  background: linear-gradient(90deg, transparent, var(--accent), var(--accent-2), transparent);
  box-shadow: 0 0 10px var(--accent-glow);
  opacity: 0.7;
}

.section-title {
  font-size: 1.4rem;
  margin: 0 0 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  letter-spacing: 0.04em;
}

.section-title::before {
  content: '';
  width: 12px;
  height: 12px;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent-glow);
  clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
  flex-shrink: 0;
}

.subsection-title {
  font-size: 1rem;
  color: var(--accent);
  letter-spacing: 0.1em;
  margin: 28px 0 14px;
}

.state-message {
  color: var(--ink-soft);
  padding: 12px 0;
}

.state-message.error {
  color: #ff6b81;
}

/* --- カードグリッド --- */

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 18px;
}

.media-card {
  position: relative;
  background: var(--panel);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  cursor: pointer;
  border: 1px solid var(--grid-line);
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.media-card:hover {
  transform: translateY(-5px);
  border-color: var(--accent);
  box-shadow: var(--shadow), 0 0 20px var(--accent-glow);
}

.media-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
  background: var(--grid-line);
}

.media-card-body {
  padding: 14px;
}

.media-card h4 {
  font-family: 'Zen Kaku Gothic New', sans-serif;
  font-weight: 700;
  font-size: 0.92rem;
  margin: 0 0 8px;
  line-height: 1.4;
  color: var(--ink);
}

.media-card .card-sub {
  margin: 0;
  font-size: 0.78rem;
  color: var(--ink-soft);
}

.status-badge {
  display: inline-block;
  font-size: 0.7rem;
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--sub);
  color: var(--bg);
  margin-bottom: 6px;
  letter-spacing: 0.04em;
}

.status-badge.live {
  background: #ff4d6d;
  color: #fff;
  box-shadow: 0 0 10px rgba(255, 77, 109, 0.6);
}

.status-badge.upcoming {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 0 10px var(--accent-glow);
}

.favorite-button {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 32px;
  height: 32px;
  border-radius: 999px;
  border: 1px solid var(--grid-line);
  background: rgba(10, 8, 18, 0.55);
  color: var(--ink-soft);
  cursor: pointer;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(4px);
}

.favorite-button .material-symbols-outlined {
  font-size: 18px;
}

.favorite-button.active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  box-shadow: 0 0 12px var(--accent-glow);
}

.favorite-button.active .material-symbols-outlined {
  font-variation-settings: 'FILL' 1, 'wght' 400, 'GRAD' 0, 'opsz' 24;
}

.card-play-button {
  position: absolute;
  top: 10px;
  left: 10px;
  width: 32px;
  height: 32px;
  border-radius: 999px;
  border: 1px solid var(--grid-line);
  background: rgba(10, 8, 18, 0.55);
  color: var(--ink-soft);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(4px);
}

.card-play-button .material-symbols-outlined {
  font-size: 18px;
}

.card-play-button:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  box-shadow: 0 0 12px var(--accent-glow);
}

.modal-play-button {
  margin-top: 16px;
  width: 100%;
  justify-content: center;
}

/* --- プロフィール --- */

.profile-card {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  background: var(--panel);
  border: 1px solid var(--grid-line);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
}

.profile-heading {
  font-size: 1.6rem;
  margin: 0;
  font-family: var(--heading-font-jp);
  color: var(--neon-text);
  text-shadow: 0 0 8px var(--accent), 0 0 20px var(--accent-glow);
}

.profile-name-en {
  color: var(--ink-soft);
  margin: 4px 0 0;
  letter-spacing: 0.05em;
}

.profile-facts dl {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 10px 18px;
  margin: 0;
}

.profile-facts dt {
  color: var(--sub);
  font-size: 0.82rem;
  white-space: nowrap;
}

.profile-facts dd {
  margin: 0;
}


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

#site-footer {
  text-align: center;
  padding: 32px 16px 120px;
  font-size: 0.85rem;
  color: var(--ink-soft);
}

/* --- モーダル --- */

.modal {
  position: fixed;
  inset: 0;
  background: rgba(5, 4, 10, 0.72);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  z-index: 30;
}

.modal-content {
  background: var(--panel);
  border: 1px solid var(--accent);
  box-shadow: 0 0 32px var(--accent-glow);
  border-radius: var(--radius);
  padding: 24px;
  max-width: 720px;
  width: 100%;
  position: relative;
  max-height: 90vh;
  overflow-y: auto;
  color: var(--ink);
}

#splash-screen {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

#splash-screen.splash-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.splash-paws {
  display: flex;
  gap: 14px;
  animation: splash-pop 0.4s ease;
}

.splash-paws .paw {
  font-size: 40px;
}

@keyframes splash-pop {
  from {
    opacity: 0;
    transform: scale(0.6);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.paw-loader {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  padding: 48px 0;
}

.paw-loader .paw {
  color: var(--accent);
  font-size: 26px;
  opacity: 0.3;
  font-variation-settings: 'FILL' 1, 'wght' 400, 'GRAD' 0, 'opsz' 24;
  animation: paw-bounce 1.2s ease-in-out infinite;
  animation-delay: calc(var(--i) * 0.15s);
}

@keyframes paw-bounce {
  0%,
  60%,
  100% {
    opacity: 0.3;
    transform: translateY(0) scale(0.9);
  }
  30% {
    opacity: 1;
    transform: translateY(-8px) scale(1.1);
  }
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  border: none;
  background: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--ink-soft);
  z-index: 1;
}

.video-embed {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: calc(var(--radius) - 6px);
  overflow: hidden;
  background: #000;
}

.video-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.video-modal-title {
  margin: 16px 0 8px;
  font-family: var(--heading-font-jp);
  font-size: 1.1rem;
  color: var(--neon-text);
}

.video-meta p {
  margin: 4px 0;
  font-size: 0.88rem;
  color: var(--ink-soft);
}

.load-more-button {
  display: block;
  margin: 24px auto 0;
  padding: 10px 28px;
  border-radius: 999px;
  border: 1px solid var(--accent);
  background: transparent;
  color: var(--accent);
  font-family: inherit;
  font-size: 0.88rem;
  cursor: pointer;
  transition: box-shadow 0.2s ease, background 0.2s ease;
}

.load-more-button:hover {
  background: var(--accent-soft);
  box-shadow: 0 0 16px var(--accent-glow);
}

.subsection-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 28px 0 14px;
}

.subsection-header .subsection-title {
  margin: 0;
}

.subsection-controls,
.section-controls {
  display: flex;
  gap: 8px;
}

.play-button {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--accent);
  background: transparent;
  color: var(--accent);
  font-family: inherit;
  font-size: 0.8rem;
  cursor: pointer;
  transition: box-shadow 0.2s ease, background 0.2s ease;
}

.play-button .material-symbols-outlined {
  font-size: 18px;
}

.play-button:hover {
  background: var(--accent-soft);
  box-shadow: 0 0 12px var(--accent-glow);
}

#bottom-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 28;
  display: flex;
  flex-direction: column;
}

.mini-player {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 20px;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid var(--accent);
  box-shadow: 0 -4px 20px var(--accent-glow);
}

.mini-player-artwork {
  position: relative;
  flex-shrink: 0;
}

.youtube-player-slot {
  position: relative;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  overflow: hidden;
  background: #000;
  transition: width 0.25s ease, height 0.25s ease, border-radius 0.25s ease;
}

.youtube-player-slot iframe {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 200px;
  height: 200px;
  transform: translate(-50%, -50%) scale(0.22);
  transform-origin: center;
  pointer-events: none;
  border: 0;
  transition: transform 0.25s ease;
}

.youtube-player-slot.expanded {
  position: absolute;
  bottom: calc(100% + 10px);
  left: 0;
  width: 200px;
  height: 200px;
  border-radius: var(--radius);
  box-shadow: 0 0 24px var(--accent-glow);
  z-index: 6;
}

.youtube-player-slot.expanded iframe {
  transform: translate(-50%, -50%) scale(1);
  pointer-events: auto;
}

#mini-player-expand-toggle {
  position: absolute;
  bottom: 2px;
  right: 2px;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  border: none;
  background: rgba(0, 0, 0, 0.65);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 7;
  padding: 0;
}

#mini-player-expand-toggle .material-symbols-outlined {
  font-size: 12px;
}

.mini-player-info {
  flex: 1;
  min-width: 0;
}

.mini-player-title {
  margin: 0 0 6px;
  font-size: 0.85rem;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mini-player-progress {
  height: 3px;
  border-radius: 999px;
  background: var(--grid-line);
  overflow: hidden;
}

.mini-player-progress-bar {
  height: 100%;
  width: 0%;
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent-glow);
}

.mini-player-controls {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.mini-player-controls button,
.mini-player-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  border: 1px solid var(--grid-line);
  background: var(--panel-raised);
  color: var(--ink);
  cursor: pointer;
}

#mini-player-shuffle.active,
#mini-player-favorite.active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  box-shadow: 0 0 10px var(--accent-glow);
}

.mini-player-volume {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.mini-player-volume button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  border: 1px solid var(--grid-line);
  background: var(--panel-raised);
  color: var(--ink);
  cursor: pointer;
  flex-shrink: 0;
}

#mini-player-volume-slider {
  width: 80px;
  accent-color: var(--accent);
}


#mobile-jump-nav {
  display: none;
}

@media (max-width: 640px) {
  .hero-title {
    font-size: 1.9rem;
  }

  .nav-links {
    display: none;
  }

  main {
    padding-left: 14px;
    padding-right: 14px;
  }

  .profile-card {
    padding: 20px 16px;
  }

  .profile-facts dl {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .profile-facts dt {
    margin-top: 14px;
    font-weight: bold;
  }

  .profile-facts dt:first-child {
    margin-top: 0;
  }

  .profile-facts dd {
    margin-top: 2px;
  }

  main {
    padding-bottom: 168px;
  }

  #site-footer {
    padding-bottom: 180px;
  }

  .mini-player {
    display: grid;
    grid-template-columns: 40px 1fr auto;
    grid-template-rows: auto auto;
    column-gap: 10px;
    row-gap: 8px;
    align-items: center;
    padding: 8px 14px;
  }

  .mini-player-artwork {
    grid-column: 1;
    grid-row: 1;
  }

  .youtube-player-slot {
    width: 40px;
    height: 40px;
  }

  .mini-player-info {
    grid-column: 2;
    grid-row: 1;
    min-width: 0;
  }

  .mini-player-title {
    max-width: none;
  }

  .mini-player-close {
    grid-column: 3;
    grid-row: 1;
  }

  .mini-player-controls {
    grid-column: 1 / -1;
    grid-row: 2;
    justify-content: center;
    gap: 10px;
  }

  .mini-player-volume {
    display: none;
  }

  #mobile-jump-nav {
    display: flex;
    justify-content: space-around;
    background: color-mix(in srgb, var(--bg) 85%, transparent);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-top: 1px solid var(--grid-line);
    padding: 8px 4px calc(8px + env(safe-area-inset-bottom, 0px));
  }

  #mobile-jump-nav a {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    flex: 1;
    padding: 4px 0;
    color: var(--ink-soft);
    text-decoration: none;
    font-size: 0.62rem;
    letter-spacing: 0.02em;
  }

  #mobile-jump-nav a.active {
    color: var(--accent);
    text-shadow: 0 0 8px var(--accent-glow);
  }

  .jump-icon {
    font-size: 1.15rem;
  }

  .modal {
    padding: 0;
    align-items: flex-end;
  }

  .modal-content {
    max-width: 100%;
    width: 100%;
    max-height: 100%;
    height: 100%;
    border-radius: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
  }

  .video-embed {
    border-radius: 0;
    flex-shrink: 0;
  }

  .video-modal-title,
  .video-meta {
    padding: 0 16px;
  }

  .video-modal-title {
    margin-top: 16px;
  }

  #video-modal-body {
    display: flex;
    flex-direction: column;
    justify-content: center;
    flex: 1;
    min-height: 0;
    overflow-y: auto;
  }

  .modal-close {
    top: 8px;
    right: 8px;
    background: rgba(5, 4, 10, 0.6);
    border-radius: 999px;
    width: 32px;
    height: 32px;
  }
}
