/* ==========================================================================
   精密マネー＆制度シミュレーター 共通スタイルシート
   (Dark FinTech Modern Theme)
   ========================================================================== */

:root {
  --sim-bg: #0a0e1a;
  --sim-card-bg: rgba(18, 24, 38, 0.95);
  --sim-card-border: rgba(56, 189, 248, 0.2);
  --sim-blue: #38bdf8;
  --sim-green: #34d399;
  --sim-red: #f87171;
  --sim-gold: #fbbf24;
  --sim-purple: #c084fc;
  --sim-text: #f8fafc;
  --sim-text-sub: #94a3b8;
  --sim-border: rgba(255, 255, 255, 0.08);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

body {
  background-color: var(--sim-bg);
  background-image: 
    radial-gradient(circle at 50% 0%, rgba(30, 58, 138, 0.25) 0%, transparent 60%),
    linear-gradient(rgba(56, 189, 248, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(56, 189, 248, 0.03) 1px, transparent 1px);
  background-size: 100% 100%, 30px 30px, 30px 30px;
  color: var(--sim-text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", "Hiragino Sans", "Meiryo", sans-serif;
  line-height: 1.6;
  padding-bottom: 60px;
}

.sim-container {
  max-width: 960px;
  margin: 0 auto;
  padding: 16px;
}

/* ナビゲーションバー */
.sim-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0 20px;
  font-size: 13px;
  border-bottom: 1px solid var(--sim-border);
  margin-bottom: 24px;
}
.sim-nav a {
  color: var(--sim-blue);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-weight: 600;
}
.sim-nav a:hover {
  text-decoration: underline;
}
.sim-breadcrumbs {
  color: var(--sim-text-sub);
  font-size: 11px;
}

/* ヘッダー */
.sim-header {
  text-align: center;
  padding: 10px 0 24px;
}
.sim-badge {
  display: inline-block;
  background: linear-gradient(135deg, #0284c7, #2563eb);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 14px;
  border-radius: 9999px;
  letter-spacing: 0.05em;
  margin-bottom: 12px;
  box-shadow: 0 0 15px rgba(37, 99, 235, 0.4);
}
.sim-title {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 10px;
  background: linear-gradient(180deg, #ffffff 30%, #cbd5e1 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
@media (min-width: 768px) {
  .sim-title {
    font-size: 30px;
  }
}
.sim-subtitle {
  font-size: 13px;
  color: var(--sim-text-sub);
  max-width: 700px;
  margin: 0 auto;
}

/* グリッドレイアウト */
.sim-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-bottom: 30px;
}
@media (min-width: 860px) {
  .sim-grid {
    grid-template-columns: 380px 1fr;
  }
}

/* カード */
.sim-card {
  background: var(--sim-card-bg);
  border: 1px solid var(--sim-card-border);
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(12px);
}
.sim-card-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--sim-blue);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid var(--sim-border);
  padding-bottom: 10px;
}

/* フォームコントロール */
.sim-control-group {
  margin-bottom: 18px;
}
.sim-label-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}
.sim-label {
  font-size: 13px;
  font-weight: 600;
  color: #e2e8f0;
}
.sim-val {
  font-size: 15px;
  font-weight: 800;
  color: var(--sim-gold);
}
input[type=range] {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 3px;
  outline: none;
  -webkit-appearance: none;
  cursor: pointer;
}
input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--sim-blue);
  cursor: pointer;
  box-shadow: 0 0 10px rgba(56, 189, 248, 0.8);
  transition: transform 0.1s;
}
input[type=range]::-webkit-slider-thumb:hover {
  transform: scale(1.15);
}

/* ボタングループ */
.sim-pill-group {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(70px, 1fr));
  gap: 6px;
  margin-top: 8px;
}
.sim-pill-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--sim-text-sub);
  padding: 6px 10px;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  text-align: center;
}
.sim-pill-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}
.sim-pill-btn.active {
  background: rgba(56, 189, 248, 0.2);
  border-color: var(--sim-blue);
  color: var(--sim-blue);
  font-weight: 700;
}

/* 結果表示カード */
.sim-stat-box {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid var(--sim-border);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 12px;
}
.sim-stat-title {
  font-size: 11px;
  color: var(--sim-text-sub);
  margin-bottom: 4px;
}
.sim-stat-value {
  font-size: 22px;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.01em;
}
.sim-stat-diff {
  font-size: 11px;
  margin-top: 4px;
  font-weight: 600;
}

/* グラフエリア */
.sim-chart-wrap {
  position: relative;
  height: 280px;
  margin-top: 16px;
}

/* 診断コメントボックス */
.sim-coach-box {
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.8), rgba(15, 23, 42, 0.9));
  border-left: 4px solid var(--sim-gold);
  border-radius: 10px;
  padding: 14px 16px;
  margin-top: 20px;
  font-size: 13px;
  color: #cbd5e1;
  line-height: 1.65;
}
.sim-coach-title {
  font-size: 13px;
  font-weight: 800;
  color: var(--sim-gold);
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* 二階建てSEO解説エリア */
.sim-article-wrap {
  background: var(--sim-card-bg);
  border: 1px solid var(--sim-border);
  border-radius: 16px;
  padding: 24px;
  margin-top: 30px;
}
@media (min-width: 768px) {
  .sim-article-wrap {
    padding: 36px 40px;
  }
}
.sim-article h2 {
  font-size: 20px;
  font-weight: 800;
  color: #fff;
  margin: 32px 0 16px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--sim-blue);
  display: flex;
  align-items: center;
  gap: 8px;
}
.sim-article h2:first-of-type {
  margin-top: 0;
}
.sim-article h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--sim-blue);
  margin: 22px 0 10px;
}
.sim-article p {
  font-size: 14px;
  color: #cbd5e1;
  line-height: 1.8;
  margin-bottom: 16px;
}
.sim-table-wrap {
  overflow-x: auto;
  margin: 20px 0;
  border-radius: 10px;
  border: 1px solid var(--sim-border);
}
.sim-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  text-align: left;
}
.sim-table th {
  background: rgba(30, 41, 59, 0.8);
  color: #94a3b8;
  padding: 10px 14px;
  font-weight: 700;
  border-bottom: 1px solid var(--sim-border);
  white-space: nowrap;
}
.sim-table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--sim-border);
  color: #e2e8f0;
}
.sim-table tr:last-child td {
  border-bottom: none;
}
.sim-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

/* Q&A アコーディオン */
.sim-qa-item {
  border: 1px solid var(--sim-border);
  border-radius: 10px;
  margin-bottom: 12px;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.4);
}
.sim-qa-q {
  padding: 14px 16px;
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(255, 255, 255, 0.02);
}
.sim-qa-a {
  padding: 14px 16px;
  font-size: 13px;
  color: #94a3b8;
  line-height: 1.7;
  border-top: 1px solid var(--sim-border);
}

/* ポータルカード（tools/index.html向け） */
.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 18px;
  margin-top: 24px;
}
.tool-card {
  background: var(--sim-card-bg);
  border: 1px solid var(--sim-card-border);
  border-radius: 16px;
  padding: 22px;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}
.tool-card:hover {
  transform: translateY(-3px);
  border-color: var(--sim-blue);
  box-shadow: 0 12px 25px -5px rgba(56, 189, 248, 0.25);
}
.tool-card-cat {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  padding: 3px 8px;
  border-radius: 6px;
  display: inline-block;
  margin-bottom: 10px;
  width: fit-content;
}
.tool-card-title {
  font-size: 17px;
  font-weight: 800;
  color: #fff;
  margin-bottom: 8px;
  line-height: 1.4;
}
.tool-card-desc {
  font-size: 12px;
  color: var(--sim-text-sub);
  line-height: 1.6;
  margin-bottom: 16px;
}
.tool-card-badge {
  font-size: 11px;
  font-weight: 700;
  color: var(--sim-blue);
  display: flex;
  align-items: center;
  gap: 4px;
}

/* フッター免責事項 */
.sim-disclaimer {
  font-size: 11px;
  color: #64748b;
  margin-top: 30px;
  text-align: center;
  line-height: 1.7;
}
