/*
 * 駅みっけ・この駅なーんだ?・共通のサポートページの見た目。
 * 色と角丸はアプリの Theme.swift(画面仕様 1-1)と同じ値にしている。
 * 既定のアクセントは紺(駅みっけ)。この駅なーんだ? は <body data-app="which-station"> で緑にする。
 */
:root {
  color-scheme: light dark;
  --background: #F6F5F1;
  --card: #FFFFFF;
  --ink: #1B1B1F;
  --sub-ink: #5F5F67;
  --line: #E4E2DC;
  --on-accent: #FFFFFF;
  --accent: #20455B;
  --accent-soft: #E3EBF0;
}

[data-app="which-station"] {
  --accent: #0A7C6E;
  --accent-soft: #DDF0EC;
}

@media (prefers-color-scheme: dark) {
  :root {
    --background: #0F1A2B;
    --card: #1A2840;
    --ink: #F2F2F5;
    --sub-ink: #A7AEBB;
    --line: #2A3A55;
    --on-accent: #0F1A2B;
    --accent: #8FC1DE;
    --accent-soft: #1F3448;
  }

  [data-app="which-station"] {
    --accent: #3CC4B0;
    --accent-soft: #1F3D43;
  }
}

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

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  /* アプリと同じシステムフォント(Apple 製品では丸ゴシック系の SF Pro Rounded) */
  font-family: ui-rounded, "SF Pro Rounded", -apple-system, BlinkMacSystemFont, "Hiragino Sans",
    "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic UI", "Yu Gothic", Meiryo, sans-serif;
  background-color: var(--background);
  color: var(--ink);
  line-height: 1.8;
  min-height: 100vh;
  overflow-wrap: anywhere;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.container {
  max-width: 680px;
  margin: 0 auto;
  padding: 40px 20px 56px;
}

/* ===== 見出し ===== */
.page-header {
  margin-bottom: 24px;
}

.page-header__brand {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  font-size: 0.875rem;
  font-weight: 800;
  color: var(--sub-ink);
}

/* ホームの見出しの左にある丸い印 */
.page-header__brand::before {
  content: "";
  flex: none;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--ink);
}

.page-header__icon {
  display: block;
  width: 72px;
  height: 72px;
  margin-bottom: 12px;
  border-radius: 16px;
}

/* アイコンがあるページでは丸い印を出さない */
.page-header__icon + .page-header__brand::before {
  display: none;
}

.page-header__title {
  font-size: 1.75rem;
  font-weight: 800;
  line-height: 1.35;
}

.page-header__app {
  display: block;
  margin-bottom: 4px;
  font-size: 1rem;
  font-weight: 800;
  color: var(--accent);
}

/* ===== カード ===== */
.section {
  margin-bottom: 12px;
  padding: 20px;
  background: var(--card);
  border-radius: 16px;
}

/* 見出しの左の短い色の帯(アプリの札と同じ形) */
.section__heading {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  font-size: 1.125rem;
  font-weight: 800;
  line-height: 1.4;
}

.section__heading::before {
  content: "";
  flex: none;
  align-self: stretch;
  width: 5px;
  min-height: 18px;
  border-radius: 3px;
  background: var(--accent);
}

.section__sub-heading {
  margin: 20px 0 8px;
  font-size: 1rem;
  font-weight: 800;
}

.section__body {
  font-size: 0.9375rem;
}

.section__body p {
  margin-bottom: 12px;
}

.section__body p:last-child {
  margin-bottom: 0;
}

.section__body ul,
.section__body ol {
  margin: 12px 0;
  padding-left: 1.4em;
}

.section__body ul:last-child,
.section__body ol:last-child {
  margin-bottom: 0;
}

.section__body li {
  margin-bottom: 6px;
  padding-left: 2px;
}

.section__body li::marker {
  color: var(--accent);
}

.text-muted {
  color: var(--sub-ink);
  font-size: 0.875rem;
}

/* ===== リンク ===== */
a {
  color: var(--accent);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  opacity: 0.75;
}

a:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ===== サポートの連絡先 ===== */
.contact-block {
  padding: 16px;
  background: var(--accent-soft);
  border-radius: 14px;
}

.contact-block__label {
  margin-bottom: 8px;
  font-size: 0.8125rem;
  font-weight: 800;
  color: var(--sub-ink);
}

/* アプリの主ボタンと同じ形(角丸 14・高さ 56) */
.contact-block__email a {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 56px;
  padding: 8px 12px;
  background: var(--accent);
  border-radius: 14px;
  color: var(--on-accent);
  font-weight: 800;
  line-height: 1.4;
  text-align: center;
  text-decoration: none;
}

.contact-block__note {
  margin-top: 12px;
  font-size: 0.8125rem;
  line-height: 1.7;
  color: var(--sub-ink);
}

/* ===== フッター ===== */
.page-footer {
  margin-top: 24px;
  padding: 0 4px;
  font-size: 0.8125rem;
  color: var(--sub-ink);
}

.page-footer__dates {
  margin-bottom: 8px;
  line-height: 1.7;
}

@media print {
  :root {
    --background: #FFFFFF;
    --ink: #000000;
    --sub-ink: #333333;
  }

  .section {
    padding: 0;
    break-inside: avoid;
  }
}
