/* =========================================================
   hikolog.app 共通デザインシステム
   site_redesign_plan.md §3 準拠。全ページ共用（/ /team/ /gakka/ 法務）。
   トークンはアプリと同一。クラス名は固定（変更しないこと）。
   ========================================================= */

/* ---------- 1. トークン ---------- */
:root {
  --ink: #0F1728;
  --muted: #667085;
  --faint: #98A2B3;
  --line: #E4E7EC;
  --canvas: #F7F8FA;
  --navy: #124E78;
  --navy-deep: #0E3F61;
  --success: #1B7A2F;

  --navy-tint: rgba(18, 78, 120, 0.08);
  --success-tint: rgba(27, 122, 47, 0.10);

  --r-card: 16px;
  --r-btn: 12px;

  /* 影は薄く1種のみ */
  --shadow: 0 1px 2px rgba(15, 23, 40, 0.05), 0 6px 20px rgba(15, 23, 40, 0.06);

  --font: -apple-system, BlinkMacSystemFont, "Hiragino Sans",
          "Hiragino Kaku Gothic ProN", "Yu Gothic UI", "Segoe UI",
          Meiryo, sans-serif;
}

/* ---------- 2. ベース ---------- */
* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.75;
  color: var(--ink);
  background: #FFFFFF;
  font-variant-numeric: tabular-nums; /* 数字はtabular */
  -webkit-font-smoothing: antialiased;
}

img, svg { max-width: 100%; }
img { height: auto; }

a { color: var(--navy); }
a:hover { color: var(--navy-deep); }

/* 見出し */
h1 {
  font-size: 34px;
  font-weight: 900;
  line-height: 1.4;
  letter-spacing: 0.01em;
  margin: 0 0 16px;
}

h2 {
  font-size: 24px;
  font-weight: 800;
  line-height: 1.45;
  margin: 0 0 20px;
  padding-left: 14px;
  border-left: 4px solid var(--navy); /* 左に4px紺バー */
}

h3 {
  font-size: 17px;
  font-weight: 800;
  line-height: 1.5;
  margin: 0 0 10px;
}

p { margin: 0 0 14px; }

/* 注記 */
.note {
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--muted);
}

/* リード文（見出し直下の説明） */
.lead {
  font-size: 16px;
  color: var(--muted);
  margin-bottom: 24px;
}

/* 横幅コンテナ */
.wrap {
  max-width: 1040px;
  margin: 0 auto;
  padding: 0 20px;
}

/* アクセシビリティ用（既存フォームのlabelで使用） */
.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

:focus-visible {
  outline: 3px solid var(--navy);
  outline-offset: 2px;
}

/* ---------- 3. ヘッダ（スティッキー・ぼかし背景） ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.86);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.site-header-inner {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 2px 12px;
  min-height: 56px;
  padding-top: 6px;
  padding-bottom: 6px;
}

.site-header .brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 17px;
  font-weight: 900;
  letter-spacing: 0.02em;
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}
.site-header .brand svg { display: block; flex: none; }

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

.site-nav > a,
.site-nav .nav-drop > summary {
  display: inline-block;
  padding: 7px 11px;
  border-radius: 8px;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--muted);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.site-nav > a:hover,
.site-nav .nav-drop > summary:hover {
  color: var(--navy);
  background: var(--navy-tint);
}

/* 現在ページ（実装側で aria-current="page" を付けると効く） */
.site-nav > a[aria-current="page"] {
  color: var(--navy);
  background: var(--navy-tint);
}

/* サポート▾ ドロップダウン（CSSのみ・details利用） */
.nav-drop { position: relative; }
.nav-drop > summary { list-style: none; }
.nav-drop > summary::-webkit-details-marker { display: none; }
.nav-drop > summary::after {
  content: "▾";
  margin-left: 4px;
  font-size: 11px;
  color: var(--faint);
}
.nav-drop[open] > summary {
  color: var(--navy);
  background: var(--navy-tint);
}
.nav-drop-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 180px;
  padding: 6px;
  background: #FFFFFF;
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--shadow);
}
.nav-drop-menu a {
  display: block;
  padding: 9px 12px;
  border-radius: 8px;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
}
.nav-drop-menu a:hover {
  color: var(--navy);
  background: var(--navy-tint);
}

/* ヘッダ右端の小CTA（公開前=公開通知。公開後はDLバッジに差し替え予定） */
.header-cta {
  margin-left: auto;
  padding: 8px 14px;
  font-size: 13px;
  white-space: nowrap;
}

/* ---------- 4. ボタン ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 13px 26px;
  background: var(--navy);
  color: #FFFFFF;
  border: 1.5px solid var(--navy);
  border-radius: var(--r-btn);
  font-family: var(--font);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.4;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, transform 0.05s;
}
.btn:hover {
  background: var(--navy-deep);
  border-color: var(--navy-deep);
  color: #FFFFFF;
}
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: 0.5; cursor: default; }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 13px 26px;
  background: #FFFFFF;
  color: var(--navy);
  border: 1.5px solid var(--line);
  border-radius: var(--r-btn);
  font-family: var(--font);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.4;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, transform 0.05s;
}
.btn-ghost:hover {
  border-color: var(--navy);
  background: var(--navy-tint);
  color: var(--navy-deep);
}
.btn-ghost:active { transform: translateY(1px); }

/* ---------- 5. セクション ---------- */
.section { padding: 64px 0; }
.section-alt {
  background: var(--canvas);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.section-alt + .section-alt { border-top: none; }

/* 汎用グリッド（カード並べ用） */
.grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

/* ---------- 6. カード ---------- */
.card {
  background: #FFFFFF;
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  padding: 24px;
  box-shadow: var(--shadow);
}
.card h3 { margin-top: 0; }

/* ---------- 7. 手順（.steps / .step） ---------- */
.steps {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  counter-reset: step;
  margin: 0;
  padding: 0;
  list-style: none;
}
.step {
  counter-increment: step;
  position: relative;
  background: #FFFFFF;
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  padding: 22px 20px 18px;
  box-shadow: var(--shadow);
}
.step::before {
  content: counter(step);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  margin-bottom: 10px;
  background: var(--navy);
  color: #FFFFFF;
  border-radius: 50%;
  font-size: 14px;
  font-weight: 800;
}
.step h3 { font-size: 15.5px; margin-bottom: 6px; }
.step p { font-size: 13.5px; color: var(--muted); margin: 0; }

/* ---------- 8. FAQ（.faq details） ---------- */
.faq details {
  background: #FFFFFF;
  border: 1px solid var(--line);
  border-radius: 12px;
  margin-bottom: 10px;
}
.faq summary {
  position: relative;
  padding: 15px 44px 15px 16px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 20px;
  font-weight: 400;
  color: var(--faint);
  transition: transform 0.15s;
}
.faq details[open] summary { color: var(--navy); }
.faq details[open] summary::after {
  content: "−";
  color: var(--navy);
}
.faq details > *:not(summary) {
  padding: 0 16px;
  font-size: 14.5px;
  line-height: 1.8;
}
.faq details > p:last-child,
.faq details > div:last-child { padding-bottom: 16px; }

/* ---------- 9. フォーム（.form-block） ---------- */
/* 見た目のみ。既存フォームの name属性・JS送信ロジックは変更しない */
.form-block {
  background: #FFFFFF;
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  padding: 26px 24px;
  box-shadow: var(--shadow);
  max-width: 560px;
}
.form-block label {
  display: block;
  margin: 16px 0 6px;
  font-size: 13px;
  font-weight: 700;
}
.form-block label:first-of-type { margin-top: 0; }
.form-block input[type="text"],
.form-block input[type="email"],
.form-block select,
.form-block textarea {
  display: block;
  width: 100%;
  padding: 12px 14px;
  background: #FFFFFF;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink);
}
.form-block input::placeholder,
.form-block textarea::placeholder { color: var(--faint); }
.form-block input:focus,
.form-block select:focus,
.form-block textarea:focus {
  outline: none;
  border-color: var(--navy);
  box-shadow: 0 0 0 3px var(--navy-tint);
}
.form-block textarea { resize: vertical; }
.form-block button[type="submit"] {
  display: block;
  width: 100%;
  margin-top: 20px;
  padding: 14px 26px;
  background: var(--navy);
  color: #FFFFFF;
  border: 1.5px solid var(--navy);
  border-radius: var(--r-btn);
  font-family: var(--font);
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  transition: background 0.15s;
}
.form-block button[type="submit"]:hover { background: var(--navy-deep); }
.form-block button[type="submit"]:disabled { opacity: 0.5; cursor: default; }
.form-block .note { margin-top: 12px; margin-bottom: 0; }
/* honeypot（既存の .hp / aria-hidden ラッパをそのまま隠す） */
.form-block .hp {
  position: absolute;
  left: -9999px;
  width: 1px; height: 1px;
  overflow: hidden;
}

/* 1項目インライン型（/ の公開通知フォームなど） */
.form-inline {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  max-width: 480px;
}
.form-inline input[type="email"] {
  flex: 1 1 220px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-family: var(--font);
  font-size: 15px;
  color: var(--ink);
}
.form-inline input[type="email"]:focus {
  outline: none;
  border-color: var(--navy);
  box-shadow: 0 0 0 3px var(--navy-tint);
}
.form-inline input::placeholder { color: var(--faint); }
.form-inline button {
  padding: 12px 22px;
  background: var(--navy);
  color: #FFFFFF;
  border: 1.5px solid var(--navy);
  border-radius: var(--r-btn);
  font-family: var(--font);
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  transition: background 0.15s;
}
.form-inline button:hover { background: var(--navy-deep); }
.form-inline button:disabled { opacity: 0.5; cursor: default; }
.form-inline .hp {
  position: absolute;
  left: -9999px;
  width: 1px; height: 1px;
  overflow: hidden;
}

/* ---------- 10. バッジ ---------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 11px;
  background: var(--navy-tint);
  color: var(--navy);
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 0.04em;
  white-space: nowrap;
}
.badge.success {
  background: var(--success-tint);
  color: var(--success);
}

/* ---------- 11. 実画面枠（.kv：iPhone風黒ベゼル角丸） ---------- */
/* 中身は site/assets/scr_*.png（同一オリジン・width/height/alt必須） */
.kv {
  display: inline-block;
  background: #0B0F14;
  border-radius: 34px;
  padding: 9px;
  box-shadow: var(--shadow);
  line-height: 0;
}
.kv img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 26px;
}
.kv-caption {
  display: block;
  margin-top: 10px;
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--muted);
  text-align: center;
}

/* ---------- 12. フッタ（4カラム・モバイルは縦積み） ---------- */
.site-footer {
  background: var(--ink);
  color: rgba(255, 255, 255, 0.72);
  padding: 48px 0 28px;
  font-size: 13.5px;
  line-height: 1.8;
}
.site-footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 6px;
  font-size: 16px;
  font-weight: 900;
  color: #FFFFFF;
}
.site-footer-brand svg { display: block; flex: none; }
.site-footer-desc {
  margin: 0 0 28px;
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.55);
}
.site-footer-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px 24px;
}
.site-footer-col h4 {
  margin: 0 0 10px;
  font-size: 12.5px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.45);
}
.site-footer-col ul {
  margin: 0;
  padding: 0;
  list-style: none;
}
.site-footer-col li { margin-bottom: 8px; }
.site-footer-col a {
  color: rgba(255, 255, 255, 0.78);
  text-decoration: none;
}
.site-footer-col a:hover {
  color: #FFFFFF;
  text-decoration: underline;
}
.site-footer-bottom {
  margin-top: 36px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}
.site-footer-bottom p {
  margin: 0 0 6px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
}

/* ---------- 13. レスポンシブ ---------- */
/* タブレット以下 */
@media (max-width: 900px) {
  h1 { font-size: 30px; }
  .section { padding: 52px 0; }
  .site-footer-grid { grid-template-columns: repeat(2, 1fr); }
}

/* モバイル */
@media (max-width: 640px) {
  h1 { font-size: 26px; }
  h2 { font-size: 20px; padding-left: 12px; }
  .section { padding: 44px 0; }
  .wrap { padding: 0 16px; }

  /* ヘッダ：1行目=ロゴ+CTA、2行目=ナビ（折返し可） */
  .site-header-inner {
    padding-top: 8px;
    padding-bottom: 8px;
    min-height: 0;
  }
  .site-header .brand { font-size: 16px; }
  .header-cta { padding: 7px 12px; font-size: 12.5px; }
  .site-nav {
    order: 3;
    width: 100%;
    margin: 2px -4px 0;
  }
  .site-nav > a,
  .site-nav .nav-drop > summary { padding: 6px 9px; font-size: 13px; }
  .nav-drop-menu { left: auto; right: 0; }

  .form-block { padding: 22px 18px; }

  /* フッタ：縦積み */
  .site-footer { padding: 40px 0 24px; }
  .site-footer-grid { grid-template-columns: 1fr; gap: 24px; }
}

/* App Store DLバッジ（2026-07-26 公開CTA差し替え・ct=lp） */
.hero-cta { margin: 22px 0 10px; }
.store-badge { display: inline-block; }
.store-badge img { display: block; height: 60px; width: auto; }
.store-badge:hover { opacity: .85; }
.band-badge { margin-top: 18px; }
.band-badge .store-badge img { height: 56px; }
