:root {
  --bg-color: #060101;
  --bg-darker: #020000;
  --text-main: #ececec;
  --text-muted: #8c8c8c;
  --accent-red: #ff1f1f;
  --accent-red-glow: rgba(255, 31, 31, 0.6);
  --border-color: #380808;
  --card-bg: rgba(18, 3, 3, 0.85);
  --font-serif: 'Zen Old Mincho', 'Shippori Mincho', serif;
  --font-mono: 'Share Tech Mono', monospace;
  --mouse-x: 50vw;
  --mouse-y: 50vh;
  --flashlight-size: 280px;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background-color: var(--bg-color);
  color: var(--text-main);
  font-family: var(--font-serif);
  line-height: 1.8;
  overflow-x: hidden;
  position: relative;
}

/* CRT走査線 & ビンテージノイズ */
.crt-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.4) 50%), linear-gradient(90deg, rgba(255, 0, 0, 0.03), rgba(0, 255, 0, 0.01), rgba(0, 0, 255, 0.03));
  background-size: 100% 3px, 3px 100%;
  pointer-events: none;
  z-index: 9998;
}

/* 懐中電灯マスク */
.flashlight-mask {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 999;
  background: radial-gradient(
    circle var(--flashlight-size) at var(--mouse-x) var(--mouse-y),
    transparent 0%,
    rgba(0, 0, 0, 0.3) 70%,
    rgba(0, 0, 0, 0.75) 100%
  );
  transition: opacity 0.3s ease;
}

.flashlight-mask.disabled {
  opacity: 0;
}

/* サブリミナル ジャンプスケア */
.subliminal-scare {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: #000;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 99999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.05s ease;
}

.subliminal-scare.active {
  opacity: 1;
  animation: scare-shake 0.1s infinite;
}

.scare-text {
  font-size: 6rem;
  color: #ff0000;
  font-weight: 900;
  letter-spacing: 0.5em;
  text-shadow: 0 0 30px #ff0000, 5px 0 0 #00ffff;
  z-index: 2;
}

.scare-img {
  position: absolute;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.8;
  filter: contrast(180%) invert(20%);
}

@keyframes scare-shake {
  0% { transform: translate(6px, -4px) rotate(1deg); }
  50% { transform: translate(-6px, 4px) rotate(-1deg); }
  100% { transform: translate(4px, 6px) rotate(0deg); }
}

.container {
  max-width: 1050px;
  margin: 0 auto;
  padding: 0 24px;
  position: relative;
  z-index: 2;
}

/* ナビゲーションバー */
.site-nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: rgba(6, 1, 1, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-color);
  z-index: 1000;
  padding: 12px 0;
}

.nav-container {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 20px;
}

.nav-logo {
  font-family: var(--font-mono);
  font-size: 1.15rem;
  font-weight: bold;
  color: var(--accent-red);
  text-decoration: none;
  text-shadow: 0 0 10px var(--accent-red-glow);
  display: flex;
  align-items: center;
  gap: 8px;
}

.blinking-red {
  color: #ff0000;
  animation: blink-dot 1s infinite alternate;
}

@keyframes blink-dot {
  0% { opacity: 0.2; }
  100% { opacity: 1; }
}

.nav-controls {
  display: flex;
  gap: 15px;
  align-items: center;
}

.tool-btn {
  background: #1a0404;
  color: #ff6666;
  border: 1px solid #440c0c;
  padding: 6px 14px;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  cursor: pointer;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.tool-btn:hover {
  background: var(--accent-red);
  color: #000;
  box-shadow: 0 0 10px var(--accent-red-glow);
}

.nav-steam-btn {
  background: #ff1f1f;
  color: #000;
  font-family: var(--font-mono);
  font-weight: bold;
  font-size: 0.85rem;
  padding: 6px 16px;
  border-radius: 4px;
  text-decoration: none;
  transition: all 0.3s ease;
}

.nav-steam-btn:hover {
  background: #ffffff;
  box-shadow: 0 0 15px #ffffff;
}

/* ヒーローセクション */
.hero-section {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 120px 20px 80px;
  background: radial-gradient(circle at center, #2e0505 0%, #060101 80%);
  overflow: hidden;
}

.classified-badge {
  font-family: var(--font-mono);
  color: var(--accent-red);
  background: rgba(255, 31, 31, 0.1);
  border: 1px solid var(--accent-red);
  padding: 4px 16px;
  font-size: 0.85rem;
  letter-spacing: 0.2em;
  margin-bottom: 25px;
  display: inline-block;
}

.hero-title {
  font-family: var(--font-serif);
  font-size: 5rem;
  font-weight: 900;
  color: #ffffff;
  margin-bottom: 20px;
  text-shadow: 4px 4px 0px #ff0000, 0 0 40px rgba(255, 31, 31, 0.6);
  letter-spacing: 0.05em;
  line-height: 1.1;
}

.glitch-text {
  animation: glitch-anim 4s infinite;
}

@keyframes glitch-anim {
  0%, 90%, 100% { transform: skew(0deg); text-shadow: 4px 4px 0px #ff0000; }
  92% { transform: skew(6deg) translate(-2px, 1px); text-shadow: -4px 0px #00ffff, 4px 0px #ff0000; }
  94% { transform: skew(-4deg) translate(2px, -1px); text-shadow: 4px -2px #00ff00; }
  96% { transform: skew(0deg); }
}

.hero-catchcopy {
  font-size: 1.4rem;
  color: #dcdcdc;
  margin-bottom: 45px;
  letter-spacing: 0.15em;
  font-weight: 700;
  text-shadow: 0 0 10px rgba(0, 0, 0, 0.9);
}

.hero-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn {
  display: inline-block;
  padding: 16px 36px;
  font-family: var(--font-mono);
  font-size: 1.05rem;
  font-weight: bold;
  text-decoration: none;
  border-radius: 4px;
  transition: all 0.3s ease;
  cursor: pointer;
  letter-spacing: 0.05em;
}

.btn-trailer {
  background: transparent;
  color: var(--accent-red);
  border: 2px solid var(--accent-red);
  box-shadow: 0 0 15px rgba(255, 31, 31, 0.2);
}

.btn-trailer:hover {
  background: var(--accent-red);
  color: #000;
  box-shadow: 0 0 25px var(--accent-red-glow);
  transform: translateY(-2px);
}

.btn-steam {
  background: #ff1f1f;
  color: #000;
  border: 2px solid #ff1f1f;
  box-shadow: 0 0 20px rgba(255, 31, 31, 0.4);
}

.btn-steam:hover {
  background: #ffffff;
  border-color: #ffffff;
  color: #000;
  box-shadow: 0 0 30px #ffffff;
  transform: translateY(-2px);
}

.scroll-prompt {
  position: absolute;
  bottom: 25px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.15em;
}

.scroll-line {
  width: 1px;
  height: 25px;
  background: var(--accent-red);
  animation: scroll-drop 1.5s infinite;
}

@keyframes scroll-drop {
  0% { transform: scaleY(0); transform-origin: top; }
  50% { transform: scaleY(1); transform-origin: top; }
  50.1% { transform: scaleY(1); transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; }
}

/* 共通セクション */
.section {
  padding: 100px 0;
  border-bottom: 1px solid var(--border-color);
}

.section-header {
  text-align: center;
  margin-bottom: 50px;
}

.section-tag {
  font-family: var(--font-mono);
  color: var(--accent-red);
  font-size: 0.85rem;
  letter-spacing: 0.3em;
  display: block;
  margin-bottom: 10px;
}

.section-title {
  font-size: 2.4rem;
  color: #ffffff;
  margin-bottom: 15px;
  letter-spacing: 0.08em;
}

.section-desc {
  color: var(--text-muted);
  font-size: 1rem;
}

/* 監視カメラモニター */
.trailer-wrapper {
  max-width: 900px;
  margin: 0 auto;
}

.monitor-frame {
  border: 2px solid var(--accent-red);
  background: #000;
  box-shadow: 0 0 30px rgba(255, 31, 31, 0.4);
  border-radius: 6px;
  overflow: hidden;
}

.monitor-top-bar {
  background: #1a0404;
  padding: 10px 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  border-bottom: 1px solid var(--border-color);
}

.rec-badge {
  color: #ff3333;
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: bold;
}

.rec-dot {
  width: 10px;
  height: 10px;
  background-color: #ff0000;
  border-radius: 50%;
  box-shadow: 0 0 8px #ff0000;
  animation: blink 1s infinite alternate;
}

.monitor-title {
  color: #777;
}

.video-container {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  background: #000;
}

.video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* 被検体0号セクション */
.monster-card {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 40px;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  padding: 40px;
  border-radius: 6px;
  box-shadow: 0 0 30px rgba(0, 0, 0, 0.8);
  align-items: center;
}

.monster-img-container {
  position: relative;
  border: 2px solid #550a0a;
  border-radius: 4px;
  overflow: hidden;
  background: #000;
}

.monster-main-img {
  width: 100%;
  height: 350px;
  object-fit: cover;
  display: block;
  filter: contrast(130%) brightness(0.8);
  transition: all 0.3s ease;
}

.monster-img-container:hover .monster-main-img {
  filter: contrast(180%) brightness(1.1) hue-rotate(-20deg);
  transform: scale(1.04);
}

.monster-caption {
  background: rgba(0, 0, 0, 0.9);
  color: #ff8888;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  padding: 8px 12px;
  text-align: center;
  border-top: 1px solid var(--border-color);
}

.warning-box {
  background: rgba(255, 31, 31, 0.15);
  border: 1px solid var(--accent-red);
  padding: 16px 20px;
  border-radius: 4px;
  display: flex;
  gap: 15px;
  align-items: center;
  margin-bottom: 25px;
  color: #ffcccc;
  font-size: 1.05rem;
}

.warning-icon {
  font-size: 2rem;
}

.monster-specs {
  list-style: none;
  margin-top: 25px;
  font-family: var(--font-mono);
  font-size: 0.95rem;
}

.monster-specs li {
  padding: 8px 0;
  border-bottom: 1px dashed #330808;
}

/* ストーリー・手記セクション */
.story-box {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  padding: 50px 40px;
  max-width: 850px;
  margin: 0 auto;
  border-radius: 6px;
  box-shadow: 0 0 30px rgba(0, 0, 0, 0.8);
}

.story-lead {
  font-size: 1.3rem !important;
  color: #ffffff;
  font-weight: 700;
  margin-bottom: 20px;
}

.redacted-instruction {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: #ff6666;
  margin: 20px 0 10px;
}

.diary-text {
  background: rgba(0, 0, 0, 0.6);
  border-left: 4px solid var(--accent-red);
  padding: 25px;
  font-size: 1.15rem;
  line-height: 2.2;
}

.redacted {
  background: #ff1f1f;
  color: #ff1f1f;
  padding: 2px 6px;
  cursor: pointer;
  transition: all 0.3s ease;
  user-select: none;
  font-weight: bold;
}

.redacted:hover {
  background: #000;
  color: #ff3333;
  text-shadow: 0 0 10px #ff0000;
}

/* ギャラリーグリッド */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
}

.gallery-card {
  border: 1px solid var(--border-color);
  background: var(--card-bg);
  border-radius: 6px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.gallery-card:hover {
  border-color: var(--accent-red);
  box-shadow: 0 0 25px rgba(255, 31, 31, 0.3);
  transform: translateY(-4px);
}

.img-wrapper {
  position: relative;
  height: 250px;
  overflow: hidden;
  background: #000;
}

.scary-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease, filter 0.4s ease;
}

.gallery-card:hover .scary-photo {
  transform: scale(1.08);
  filter: contrast(160%) brightness(1.1);
}

.gallery-info {
  padding: 20px;
}

.gallery-info h4 {
  font-size: 1.15rem;
  color: #fff;
  margin-bottom: 6px;
}

.gallery-info p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* 特徴グリッド */
.features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 25px;
}

.feature-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  padding: 35px 30px;
  border-radius: 6px;
  transition: all 0.3s ease;
}

.feature-card:hover {
  border-color: var(--accent-red);
  box-shadow: 0 0 20px rgba(255, 31, 31, 0.25);
  transform: translateY(-3px);
}

.feature-icon {
  font-size: 2.5rem;
  margin-bottom: 15px;
}

.feature-title {
  font-size: 1.25rem;
  color: #ffffff;
  margin-bottom: 12px;
}

.feature-text {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.8;
}

/* Steam CTAセクション */
.cta-section {
  background: radial-gradient(circle at center, #380505 0%, #060101 80%);
  text-align: center;
  padding: 120px 0;
}

.cta-badge {
  font-family: var(--font-mono);
  color: var(--accent-red);
  font-size: 0.9rem;
  letter-spacing: 0.3em;
  display: block;
  margin-bottom: 15px;
}

.cta-title {
  font-size: 3.2rem;
  color: #ffffff;
  margin-bottom: 20px;
  letter-spacing: 0.05em;
}

.cta-desc {
  color: #bbb;
  font-size: 1.2rem;
  margin-bottom: 40px;
}

.btn-steam-pulse {
  background: #ff1f1f;
  color: #000;
  font-size: 1.25rem;
  padding: 20px 50px;
  border-radius: 6px;
  font-weight: 900;
  box-shadow: 0 0 35px rgba(255, 31, 31, 0.6);
  display: inline-flex;
  align-items: center;
  gap: 12px;
  animation: pulse-steam 2s infinite;
}

@keyframes pulse-steam {
  0% { transform: scale(1); box-shadow: 0 0 25px rgba(255, 31, 31, 0.5); }
  50% { transform: scale(1.04); box-shadow: 0 0 45px rgba(255, 31, 31, 0.9); }
  100% { transform: scale(1); box-shadow: 0 0 25px rgba(255, 31, 31, 0.5); }
}

.btn-steam-pulse:hover {
  background: #ffffff;
  color: #000;
  box-shadow: 0 0 50px #ffffff;
}

/* フッター */
.site-footer {
  padding: 40px 0;
  text-align: center;
  border-top: 1px solid var(--border-color);
  background: var(--bg-darker);
}

.footer-logo {
  font-family: var(--font-mono);
  color: var(--accent-red);
  font-size: 1.1rem;
  font-weight: bold;
  margin-bottom: 10px;
}

.copyright {
  color: #555555;
  font-size: 0.8rem;
  font-family: var(--font-mono);
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
  .hero-title { font-size: 2.8rem; }
  .hero-catchcopy { font-size: 1.1rem; }
  .monster-card { grid-template-columns: 1fr; }
  .gallery-grid, .features-grid { grid-template-columns: 1fr; }
  .cta-title { font-size: 2.2rem; }
  .btn-steam-pulse { font-size: 1rem; padding: 15px 25px; }
  .nav-controls { gap: 8px; }
}
