/* F-2 MISSIONS — marketing site design system
   Deck Steel (dark, HUD sections) + Chart Tan (light, topo sections).
   Amber/green accents follow the in-game FLOLS (meatball) lighting logic:
   amber = caution / off-glidepath, green = on-glidepath / good. */

:root {
  --deck-steel: #10151a;
  --panel-slate: #1b232b;
  --panel-slate-2: #222c35;
  --line-slate: #2c3944;
  --phosphor-amber: #ffb238;
  --phosphor-amber-dim: #a87626;
  --glidepath-green: #6fe38f;
  --alert-red: #ff5d4e;
  --chart-tan: #e7dcc2;
  --chart-tan-2: #ddd0af;
  --chart-ink: #2a2419;
  --fog-white: #eef2f0;
  --fog-white-dim: #aab4b8;

  --font-display: "Turret Road", "Hiragino Sans", sans-serif;
  --font-body: "IBM Plex Sans JP", "Hiragino Sans", "Yu Gothic", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "SF Mono", monospace;

  --container: 1180px;
  --edge: clamp(20px, 5vw, 64px);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

body {
  margin: 0;
  background: var(--deck-steel);
  color: var(--fog-white);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

img, video { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding-left: var(--edge);
  padding-right: var(--edge);
}

/* ---------- Eyebrows / labels ---------- */
.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--phosphor-amber);
}

.eyebrow::before { content: "// "; color: var(--phosphor-amber-dim); }

h1, h2, h3 { margin: 0; font-weight: 700; }

h2.section-title {
  font-family: var(--font-body);
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  letter-spacing: 0.01em;
  margin-top: 0.5em;
  max-width: 50ch;
}

.codename {
  font-family: var(--font-display);
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px var(--edge);
  background: rgba(16, 21, 26, 0.86);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line-slate);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 1.05rem;
  letter-spacing: 0.04em;
}

.brand img { width: 28px; height: 28px; border-radius: 6px; }

.site-nav { display: flex; align-items: center; gap: 28px; }

.site-nav a {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--fog-white-dim);
  transition: color 0.15s ease;
}

.site-nav a:hover, .site-nav a:focus-visible { color: var(--phosphor-amber); }

.lang-switch {
  display: flex;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
}

.lang-switch a {
  padding: 3px 8px;
  border: 1px solid var(--line-slate);
  color: var(--fog-white-dim);
}

.lang-switch a[aria-current="true"] {
  color: var(--phosphor-amber);
  border-color: var(--phosphor-amber-dim);
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line-slate);
  color: var(--fog-white);
  font-family: var(--font-mono);
  padding: 6px 10px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 24px;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--phosphor-amber);
  color: #201400;
}

.btn-primary:hover, .btn-primary:focus-visible {
  box-shadow: 0 0 0 3px rgba(255, 178, 56, 0.25);
}

.btn-primary[aria-disabled="true"] {
  background: var(--panel-slate-2);
  color: var(--fog-white-dim);
  border-color: var(--line-slate);
  cursor: default;
  pointer-events: none;
}

.btn-ghost {
  background: transparent;
  color: var(--fog-white);
  border-color: var(--line-slate);
}

.btn-ghost:hover, .btn-ghost:focus-visible { border-color: var(--phosphor-amber); color: var(--phosphor-amber); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 140px var(--edge) 80px;
  overflow: hidden;
  background: radial-gradient(120% 90% at 20% 0%, #1a232b 0%, var(--deck-steel) 60%);
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-media video, .hero-media .hero-poster {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.5;
}

.hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(16,21,26,0.35) 0%, rgba(16,21,26,0.55) 45%, var(--deck-steel) 96%);
}

.hero-scanline {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: repeating-linear-gradient(180deg, rgba(255,255,255,0.025) 0px, rgba(255,255,255,0.025) 1px, transparent 1px, transparent 3px);
  mix-blend-mode: overlay;
  animation: scan-drift 9s linear infinite;
}

@keyframes scan-drift { from { background-position: 0 0; } to { background-position: 0 120px; } }

.hero-inner { position: relative; z-index: 2; max-width: 760px; }

.hero-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--glidepath-green);
  border: 1px solid rgba(111, 227, 143, 0.35);
  padding: 6px 12px;
  margin-bottom: 22px;
}

.hero-status .dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--glidepath-green);
  box-shadow: 0 0 8px var(--glidepath-green);
  animation: pulse 1.6s ease-in-out infinite;
}

@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.35; } }

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.6rem, 8vw, 5.2rem);
  line-height: 0.98;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  color: var(--fog-white);
}

.hero-tagline {
  margin-top: 18px;
  font-family: var(--font-mono);
  font-size: clamp(0.85rem, 1.6vw, 1.05rem);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fog-white-dim);
}

.hero-jp-line {
  margin-top: 14px;
  font-weight: 700;
  font-size: clamp(1.3rem, 2.6vw, 2rem);
  letter-spacing: 0.02em;
  color: var(--fog-white);
}

.hero-lede {
  margin-top: 22px;
  font-size: 1.08rem;
  color: var(--fog-white-dim);
  max-width: 54ch;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }

/* ---------- HUD tape divider (signature motif) ---------- */
.tape-divider {
  position: relative;
  height: 46px;
  background: var(--panel-slate);
  border-top: 1px solid var(--line-slate);
  border-bottom: 1px solid var(--line-slate);
  overflow: hidden;
}

.tape-divider .tape-track {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  white-space: nowrap;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.3em;
  color: var(--fog-white-dim);
  background-image: repeating-linear-gradient(
    90deg,
    var(--line-slate) 0, var(--line-slate) 1px,
    transparent 1px, transparent 60px
  );
  animation: tape-scroll 40s linear infinite;
}

.tape-track span { padding: 0 30px; }

@keyframes tape-scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- Section shells ---------- */
section { padding: 96px 0; }

.section-dark { background: var(--deck-steel); }
.section-slate { background: var(--panel-slate); }

.section-head { display: flex; flex-direction: column; gap: 4px; margin-bottom: 48px; }

/* ---------- Feature grid ---------- */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 28px;
  margin-top: 48px;
}

.feature-card {
  padding: 26px 24px;
  background: var(--panel-slate);
  border: 1px solid var(--line-slate);
}

.feature-card .readout {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  color: var(--glidepath-green);
  margin-bottom: 12px;
}

.feature-card h3 {
  font-size: 1.12rem;
  margin-bottom: 10px;
}

.feature-card p { color: var(--fog-white-dim); font-size: 0.96rem; margin: 0; }

/* ---------- Mission cards (corner-bracket, not rounded) ---------- */
.mission-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 48px;
}

.bracket {
  position: relative;
}

.bracket::before, .bracket::after,
.bracket .br-tl, .bracket .br-br {
  content: "";
  position: absolute;
  width: 18px; height: 18px;
  border-color: var(--phosphor-amber);
  z-index: 3;
}

.bracket::before { top: -1px; left: -1px; border-top: 2px solid; border-left: 2px solid; }
.bracket::after { bottom: -1px; right: -1px; border-bottom: 2px solid; border-right: 2px solid; }

.mission-card {
  background: var(--panel-slate);
  border: 1px solid var(--line-slate);
  padding: 22px;
}

.mission-card .art {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  margin-bottom: 18px;
  background: var(--deck-steel);
}

.mission-card .art img { width: 100%; height: 100%; object-fit: cover; }

.mission-card .eyebrow { display: block; margin-bottom: 6px; }

.mission-card h3 { font-size: 1.2rem; margin-bottom: 8px; }

.mission-card p { color: var(--fog-white-dim); font-size: 0.92rem; }

.grade-row { display: flex; gap: 8px; margin-top: 16px; }

.grade-pill {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  padding: 4px 9px;
  border: 1px solid currentColor;
}

.grade-pill.normal { color: var(--glidepath-green); }
.grade-pill.hard { color: var(--phosphor-amber); }
.grade-pill.ace { color: var(--alert-red); }

.stage-note {
  margin-top: 40px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--fog-white-dim);
  border-left: 2px solid var(--phosphor-amber-dim);
  padding: 10px 16px;
  max-width: calc(94ch + 32px); /* 94ch 分の本文 + 左右 padding (border-box) */
}

/* ---------- Terrain / chart section (light "paper") ---------- */
.section-chart {
  background: var(--chart-tan);
  color: var(--chart-ink);
  position: relative;
  overflow: hidden;
}

.section-chart .contour-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  opacity: 0.55;
}

.section-chart .container { position: relative; z-index: 1; }

.section-chart .eyebrow { color: var(--phosphor-amber-dim); }
.section-chart .eyebrow::before { color: var(--phosphor-amber-dim); }

.section-chart .section-title { color: var(--chart-ink); }

.chart-lede { max-width: 56ch; color: #4a4227; font-size: 1.02rem; }

.terrain-map {
  margin-top: 56px;
  position: relative;
  border: 1px solid var(--chart-ink);
  background: #f1e8d2;
  padding: 20px;
}

.terrain-map svg { width: 100%; height: auto; display: block; }

.terrain-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
  margin-top: 40px;
}

.terrain-item {
  border-top: 2px solid var(--phosphor-amber-dim);
  padding-top: 14px;
}

.terrain-item .codename { font-size: 1.05rem; display: block; }
.terrain-item p { margin: 6px 0 0; font-size: 0.92rem; color: #55492c; }

/* ---------- Gameplay video gallery ---------- */
.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
  margin-top: 48px;
}

.video-frame {
  position: relative;
  background: #000;
  border: 1px solid var(--line-slate);
}

.video-frame::before, .video-frame::after {
  content: "";
  position: absolute;
  width: 16px; height: 16px;
  border-color: var(--phosphor-amber);
  z-index: 3;
  pointer-events: none;
}

.video-frame::before { top: 8px; left: 8px; border-top: 2px solid; border-left: 2px solid; }
.video-frame::after { bottom: 8px; right: 8px; border-bottom: 2px solid; border-right: 2px solid; }

.video-frame video, .video-frame .video-poster {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  opacity: 0.92;
}

.video-caption {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 10px 12px;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  color: var(--fog-white-dim);
  border-top: 1px solid var(--line-slate);
}

.video-caption .tag { color: var(--phosphor-amber); }

.video-poster {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: linear-gradient(135deg, #1b232b 0%, #10151a 100%);
  color: var(--fog-white-dim);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-align: center;
  padding: 20px;
}

.video-poster .ph-tag { color: var(--phosphor-amber-dim); font-size: 0.68rem; letter-spacing: 0.16em; }
.video-poster .ph-title { color: var(--fog-white); font-size: 0.86rem; }
.video-poster .ph-note { font-size: 0.68rem; opacity: 0.75; }

/* ---------- Screenshot strip ---------- */
.shot-strip {
  display: flex;
  gap: 18px;
  overflow-x: auto;
  padding-bottom: 8px;
  margin-top: 40px;
  scrollbar-width: thin;
}

.shot-strip img, .shot-strip .shot-placeholder {
  flex: 0 0 auto;
  width: min(80vw, 460px);
  aspect-ratio: 2868 / 1320;
  object-fit: cover;
  background: var(--panel-slate);
  border: 1px solid var(--line-slate);
}

.shot-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--fog-white-dim);
  text-align: center;
  padding: 14px;
}

/* ---------- CTA band ---------- */
.cta-band {
  text-align: center;
  padding: 100px var(--edge);
  background: linear-gradient(180deg, var(--panel-slate) 0%, var(--deck-steel) 100%);
}

.cta-band h2 { font-family: var(--font-display); font-size: clamp(1.8rem, 4vw, 2.8rem); text-transform: uppercase; }

.cta-band .hero-actions { justify-content: center; }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--line-slate);
  padding: 48px var(--edge) 32px;
  background: var(--deck-steel);
}

.footer-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 32px;
}

.footer-links { display: flex; flex-wrap: wrap; gap: 24px; }

.footer-links a {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.05em;
  color: var(--fog-white-dim);
}

.footer-links a:hover { color: var(--phosphor-amber); }

.footer-fine {
  margin-top: 32px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: #5c6870;
  letter-spacing: 0.04em;
}

/* ---------- Simple content pages (privacy/terms/support) ---------- */
.doc-page { padding: 160px 0 100px; max-width: 820px; margin: 0 auto; }
.doc-page h1 { font-family: var(--font-display); font-size: clamp(2rem, 5vw, 2.8rem); text-transform: uppercase; }
.doc-page .updated { font-family: var(--font-mono); font-size: 0.78rem; color: var(--fog-white-dim); margin-top: 10px; }
.doc-page h2 { font-size: 1.3rem; margin-top: 44px; margin-bottom: 12px; color: var(--phosphor-amber); }
.doc-page p, .doc-page li { color: var(--fog-white-dim); font-size: 0.98rem; }
.doc-page ul { padding-left: 1.2em; }
.doc-note {
  margin-top: 40px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--fog-white-dim);
  border: 1px dashed var(--line-slate);
  padding: 14px 18px;
}

/* ---------- Contact form ---------- */
.contact-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  max-width: 640px;
}

.field { display: flex; flex-direction: column; gap: 8px; margin-bottom: 20px; }

.field label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fog-white-dim);
}

.field input, .field textarea, .field select {
  background: var(--panel-slate);
  border: 1px solid var(--line-slate);
  color: var(--fog-white);
  padding: 12px 14px;
  font-family: var(--font-body);
  font-size: 0.98rem;
  resize: vertical;
}

.field input:focus, .field textarea:focus, .field select:focus {
  outline: none;
  border-color: var(--phosphor-amber);
}

.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.form-status {
  margin-top: 18px;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  padding: 12px 14px;
  border: 1px solid var(--line-slate);
  display: none;
}

.form-status.ok { display: block; color: var(--glidepath-green); border-color: var(--glidepath-green); }
.form-status.error { display: block; color: var(--alert-red); border-color: var(--alert-red); }

/* ---------- Scroll reveal ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

[data-reveal].is-visible { opacity: 1; transform: translateY(0); }

/* ---------- Focus visibility ---------- */
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--phosphor-amber);
  outline-offset: 2px;
}

/* ---------- Responsive ---------- */
@media (max-width: 940px) {
  .site-nav { position: fixed; inset: 62px 0 auto 0; background: var(--deck-steel); flex-direction: column; align-items: flex-start; padding: 20px var(--edge); border-bottom: 1px solid var(--line-slate); gap: 18px; display: none; }
  .site-nav.open { display: flex; }
  .nav-toggle { display: inline-flex; }
  .lang-switch { order: 2; }
  section { padding: 64px 0; }
  .hero { padding-top: 120px; min-height: auto; }
}
