/* 配色トークン: ライトを基準とし、ダークは上書きのみ */
:root {
  --bg: #fbfaf8;
  --bg-sub: #ffffff;
  --fg: #17191d;
  --fg-sub: #62697a;
  --line: #e6e3dd;
  --accent: #2f6df6;
  --accent-2: #8a5cf6;
  --accent-soft: rgba(47, 109, 246, .1);
  --shadow: 0 1px 2px rgba(20, 24, 40, .05), 0 8px 24px rgba(20, 24, 40, .06);
  --shadow-hover: 0 2px 4px rgba(20, 24, 40, .06), 0 14px 34px rgba(20, 24, 40, .12);
  --radius: 18px;
  --maxw: 760px;
}

/* 端末設定がダーク、かつ手動でライト指定していない場合 */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #101216;
    --bg-sub: #191c22;
    --fg: #edeff3;
    --fg-sub: #9aa2b1;
    --line: #2a2f38;
    --accent: #79a5ff;
    --accent-2: #b492ff;
    --accent-soft: rgba(121, 165, 255, .14);
    --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 8px 24px rgba(0, 0, 0, .35);
    --shadow-hover: 0 2px 4px rgba(0, 0, 0, .45), 0 14px 34px rgba(0, 0, 0, .5);
  }
}

/* 手動でダーク指定した場合(端末設定より優先) */
:root[data-theme="dark"] {
  --bg: #101216;
  --bg-sub: #191c22;
  --fg: #edeff3;
  --fg-sub: #9aa2b1;
  --line: #2a2f38;
  --accent: #79a5ff;
  --accent-2: #b492ff;
  --accent-soft: rgba(121, 165, 255, .14);
  --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 8px 24px rgba(0, 0, 0, .35);
  --shadow-hover: 0 2px 4px rgba(0, 0, 0, .45), 0 14px 34px rgba(0, 0, 0, .5);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: system-ui, -apple-system, "Hiragino Sans", "Noto Sans JP", sans-serif;
  line-height: 1.85;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

/* 画面上部にうっすら色を敷いて、白一色の平板さをなくす */
body::before {
  content: "";
  position: fixed;
  inset: 0 0 auto 0;
  height: 380px;
  background: radial-gradient(80% 100% at 20% 0%, var(--accent-soft), transparent 70%);
  pointer-events: none;
  z-index: -1;
}

a { color: var(--accent); text-underline-offset: 3px; }

/* ---- ヘッダ ---- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(12px);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  border-bottom: 1px solid var(--line);
}
.site-header .inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
.site-title {
  font-weight: 800;
  font-size: 21px;
  letter-spacing: .02em;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--fg);
}
/* サイト名の頭に置く丸いマーク */
.site-title .mark {
  width: 28px;
  height: 28px;
  border-radius: 9px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 14px;
  font-weight: 800;
  box-shadow: var(--shadow);
}

.site-header nav {
  margin-left: auto;
  display: flex;
  gap: 6px;
  align-items: center;
}
.site-header nav a {
  text-decoration: none;
  color: var(--fg-sub);
  font-size: 14px;
  padding: 5px 11px;
  border-radius: 999px;
  transition: background .18s, color .18s;
}
.site-header nav a:hover { color: var(--fg); background: var(--accent-soft); }

#theme-toggle {
  border: 1px solid var(--line);
  background: var(--bg-sub);
  color: var(--fg);
  border-radius: 999px;
  width: 34px;
  height: 34px;
  margin-left: 4px;
  cursor: pointer;
  font-size: 15px;
  line-height: 1;
  transition: transform .18s, border-color .18s;
}
#theme-toggle:hover { transform: rotate(-18deg) scale(1.08); border-color: var(--accent); }

/* ---- 本文 ---- */
main {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 52px 20px 84px;
}

h1 {
  font-size: clamp(30px, 6vw, 42px);
  line-height: 1.35;
  letter-spacing: -.01em;
  margin: 0 0 10px;
  font-weight: 800;
}
/* トップの見出しだけ色をのせる */
.hero h1 {
  background: linear-gradient(120deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ヒーロー上部の小見出し */
.eyebrow {
  display: inline-block;
  margin: 0 0 16px;
  padding: 4px 14px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .04em;
}

.hero { padding-bottom: 8px; }

h2 {
  font-size: 19px;
  font-weight: 700;
  margin: 48px 0 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}
/* 見出しの左に小さな丸を置いて区切りにする */
h2::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex: none;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
}
h3 { font-size: 16px; font-weight: 700; margin: 26px 0 8px; }
h4 { font-size: 18px; font-weight: 700; margin: 0 0 6px; }

/* プロダクトのカテゴリ見出し */
.cat {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  color: var(--fg-sub);
  margin: 28px 0 12px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.cat::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}
p { margin: 0 0 15px; }

.lead { color: var(--fg-sub); font-size: 17px; margin-bottom: 26px; }

ul { padding-left: 1.3em; margin: 0 0 15px; }
li { margin-bottom: 5px; }

/* ---- ポリシー本文 ---- */
/* 日本語版と英語版の区切り */
main hr {
  margin: 56px 0 44px;
  border: 0;
  border-top: 1px solid var(--line);
}
/* メールアドレス(リンクにしない) */
.mail {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: .95em;
  background: var(--accent-soft);
  border-radius: 6px;
  padding: 2px 8px;
  word-break: break-all;
}

/* アプリ名・更新日などの補足行 */
.meta {
  color: var(--fg-sub);
  font-size: 14px;
}

/* ---- アプリカード ---- */
.app-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 16px; }
.app-card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-sub);
  padding: 22px 24px;
  box-shadow: var(--shadow);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
/* カード左端の色帯 */
.app-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, var(--accent), var(--accent-2));
}
.app-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
  border-color: color-mix(in srgb, var(--accent) 40%, var(--line));
}
.app-card h4 { margin-top: 0; }
.app-card h4 a { color: inherit; text-decoration: none; }
.app-card h4 a:hover { text-decoration: underline; }
.app-card p { margin-bottom: 12px; color: var(--fg-sub); }

/* プライバシーポリシー一覧: アプリ名の下に概要を添える */
.policy-list li { margin-bottom: 10px; }
.policy-list .note {
  display: block;
  font-size: 14px;
  color: var(--fg-sub);
  margin-top: 2px;
}

/* プライバシーポリシー本文の目次 */
.toc {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 6px 22px 16px;
  margin-bottom: 30px;
}
.toc h2 { font-size: 16px; margin-bottom: 8px; }
.toc ul { margin: 0; }
.toc li { margin-bottom: 4px; font-size: 15px; }

.badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  padding: 2px 11px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  margin-left: 9px;
  vertical-align: middle;
  white-space: nowrap;
}

.app-links { font-size: 14px; display: flex; gap: 10px; flex-wrap: wrap; }
.app-links a {
  text-decoration: none;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 14px;
  color: var(--fg-sub);
  transition: background .18s, color .18s, border-color .18s;
}
.app-links a:hover {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-soft);
}

/* 概要(会社概要にあたる表) */
.about {
  margin: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-sub);
}
.about-row {
  display: flex;
  gap: 20px;
  padding: 15px 22px;
  border-bottom: 1px solid var(--line);
}
.about-row:last-child { border-bottom: none; }
.about dt {
  flex: none;
  width: 110px;
  color: var(--fg-sub);
  font-size: 14px;
  font-weight: 600;
}
.about dd { margin: 0; }

@media (max-width: 480px) {
  .about-row { flex-direction: column; gap: 2px; }
  .about dt { width: auto; }
}

/* 一覧などへ誘導する行 */
.more { margin-top: 20px; font-size: 15px; }
.more a { text-decoration: none; font-weight: 600; }
.more a:hover { text-decoration: underline; }

/* ---- フッタ ---- */
.site-footer {
  border-top: 1px solid var(--line);
  color: var(--fg-sub);
  font-size: 13px;
}
.site-footer .inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 24px 20px 40px;
}

/* 動きを減らす設定の端末では変形をやめる */
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
  .app-card:hover { transform: none; }
  #theme-toggle:hover { transform: none; }
}
