/* ============================
   原っぱマーケット2026 分析レポート
   共通スタイルシート
   ============================ */

@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+JP:wght@400;500;700&display=swap');

:root {
  --green-dark: #2d6a4f;
  --green-mid: #40916c;
  --green-light: #52b788;
  --green-pale: #d8f3dc;
  --green-bg: #f0faf3;
  --terra: #bc6c25;
  --terra-pale: #fdf3e7;
  --blue-accent: #1d6fa4;
  --blue-pale: #e8f4fd;
  --red-warn: #c0392b;
  --red-pale: #fdf0ef;
  --yellow: #f4a261;
  --yellow-pale: #fff8f0;
  --gray-dark: #2b2d42;
  --gray-mid: #555770;
  --gray-light: #8d8fa6;
  --gray-border: #e4e6f0;
  --gray-bg: #f8f9fc;
  --white: #ffffff;
  --shadow: 0 2px 12px rgba(0,0,0,0.08);
  --shadow-hover: 0 6px 24px rgba(0,0,0,0.14);
  --radius: 12px;
  --radius-sm: 8px;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: 'Noto Sans JP', 'Hiragino Kaku Gothic ProN', 'Yu Gothic', sans-serif;
  background: var(--gray-bg);
  color: var(--gray-dark);
  line-height: 1.8;
  font-size: 15px;
}

/* ---- Layout ---- */
.page-wrapper {
  display: grid;
  grid-template-columns: 260px 1fr;
  grid-template-rows: auto 1fr;
  min-height: 100vh;
}

/* ---- Top Nav ---- */
.top-nav {
  grid-column: 1 / -1;
  background: var(--green-dark);
  color: white;
  padding: 0 32px;
  display: flex;
  align-items: center;
  gap: 16px;
  height: 56px;
  position: sticky;
  top: 0;
  z-index: 100;
}
.top-nav .logo {
  font-weight: 700;
  font-size: 14px;
  color: var(--green-pale);
  text-decoration: none;
  white-space: nowrap;
}
.top-nav .nav-links {
  display: flex;
  gap: 4px;
  list-style: none;
  margin-left: auto;
  flex-wrap: wrap;
}
.top-nav .nav-links a {
  color: rgba(255,255,255,0.8);
  text-decoration: none;
  font-size: 13px;
  padding: 6px 12px;
  border-radius: 6px;
  transition: background 0.2s;
}
.top-nav .nav-links a:hover,
.top-nav .nav-links a.active {
  background: rgba(255,255,255,0.15);
  color: white;
}

/* ---- Sidebar ---- */
.sidebar {
  background: var(--white);
  border-right: 1px solid var(--gray-border);
  padding: 24px 0;
  position: sticky;
  top: 56px;
  height: calc(100vh - 56px);
  overflow-y: auto;
}
.sidebar-section {
  padding: 0 0 16px;
}
.sidebar-section-title {
  font-size: 11px;
  font-weight: 700;
  color: var(--gray-light);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 12px 20px 6px;
}
.sidebar a {
  display: block;
  padding: 8px 20px;
  color: var(--gray-mid);
  text-decoration: none;
  font-size: 13px;
  border-left: 3px solid transparent;
  transition: all 0.15s;
  line-height: 1.5;
}
.sidebar a:hover {
  color: var(--green-dark);
  background: var(--green-bg);
  border-left-color: var(--green-light);
}
.sidebar a.active {
  color: var(--green-dark);
  background: var(--green-bg);
  border-left-color: var(--green-dark);
  font-weight: 700;
}

/* ---- Main Content ---- */
.main-content {
  padding: 40px 48px 80px;
  max-width: 960px;
}

/* ---- Page Header ---- */
.page-header {
  margin-bottom: 40px;
  padding-bottom: 24px;
  border-bottom: 2px solid var(--gray-border);
}
.page-header .tag {
  display: inline-block;
  background: var(--green-pale);
  color: var(--green-dark);
  font-size: 12px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  margin-bottom: 10px;
}
.page-header h1 {
  font-size: 28px;
  font-weight: 700;
  color: var(--gray-dark);
  margin-bottom: 8px;
  line-height: 1.4;
}
.page-header .meta {
  font-size: 13px;
  color: var(--gray-light);
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}
.page-header .meta span {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* ---- Summary Box ---- */
.summary-box {
  background: linear-gradient(135deg, var(--green-dark) 0%, var(--green-mid) 100%);
  color: white;
  border-radius: var(--radius);
  padding: 28px 32px;
  margin-bottom: 40px;
}
.summary-box .label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  opacity: 0.7;
  margin-bottom: 8px;
}
.summary-box .text {
  font-size: 17px;
  font-weight: 500;
  line-height: 1.7;
}

/* ライト版サマリーボックス */
.summary-box.summary-box-light {
  background: var(--white);
  color: var(--gray-dark);
  border: 1.5px solid var(--green-pale);
  border-left: 5px solid var(--green-mid);
  box-shadow: var(--shadow);
  margin-top: 8px;
}
.summary-box.summary-box-light .label {
  color: var(--green-dark);
  opacity: 1;
  font-size: 10px;
  letter-spacing: 0.12em;
}
.summary-box.summary-box-light .text {
  font-size: 18px;
  font-weight: 700;
  color: var(--gray-dark);
  line-height: 1.7;
}

/* ---- Sections ---- */
.section {
  margin-bottom: 56px;
}
.section-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--green-dark);
  padding-bottom: 10px;
  border-bottom: 2px solid var(--green-pale);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.section-title .num {
  background: var(--green-dark);
  color: white;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  flex-shrink: 0;
}
.section-subtitle {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--green-dark);
  margin-bottom: 20px;
  padding: 8px 14px;
  background: var(--green-bg);
  border-left: 3px solid var(--green-mid);
  border-radius: 0 6px 6px 0;
  line-height: 1.6;
}
.subsection {
  margin-bottom: 36px;
}
.subsection-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--gray-dark);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.subsection-title::before {
  content: '';
  width: 4px;
  height: 18px;
  background: var(--green-light);
  border-radius: 2px;
  flex-shrink: 0;
}

/* ---- Finding Cards ---- */
.finding-card {
  background: var(--white);
  border: 1px solid var(--gray-border);
  border-radius: var(--radius);
  padding: 24px 28px;
  margin-bottom: 16px;
  box-shadow: var(--shadow);
}
.finding-card .card-header {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 14px;
}
.finding-card .card-num {
  background: var(--green-pale);
  color: var(--green-dark);
  font-size: 12px;
  font-weight: 700;
  padding: 2px 9px;
  border-radius: 12px;
  white-space: nowrap;
  flex-shrink: 0;
  margin-top: 2px;
}
.finding-card .card-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--gray-dark);
}
.finding-card .card-body {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 12px;
  font-size: 13.5px;
}
.finding-card .card-col-label {
  font-size: 11px;
  font-weight: 700;
  color: var(--gray-light);
  letter-spacing: 0.06em;
  margin-bottom: 4px;
}
.finding-card .card-col-content {
  color: var(--gray-dark);
  line-height: 1.7;
}
.finding-card.full-width .card-body {
  grid-template-columns: 1fr;
}
.finding-card.two-col .card-body {
  grid-template-columns: 1fr 1fr;
}

/* ---- Data Highlight ---- */
.data-highlight {
  color: var(--green-dark);
  font-weight: 700;
}
/* 数字・%用のバッジハイライト（インラインで背景あり） */
.num-highlight {
  display: inline;
  background: var(--green-pale);
  color: var(--green-dark);
  font-weight: 700;
  padding: 1px 5px;
  border-radius: 4px;
}

/* ---- Stats Grid ---- */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}
.stat-card {
  background: var(--white);
  border: 1px solid var(--gray-border);
  border-radius: var(--radius-sm);
  padding: 20px;
  text-align: center;
  box-shadow: var(--shadow);
}
.stat-card .stat-value {
  font-size: 32px;
  font-weight: 700;
  color: var(--green-dark);
  line-height: 1.1;
  margin-bottom: 4px;
}
.stat-card .stat-label {
  font-size: 12px;
  color: var(--gray-mid);
  line-height: 1.4;
}
.stat-card .stat-sub {
  font-size: 11px;
  color: var(--gray-light);
  margin-top: 4px;
}

/* ---- Bar Chart ---- */
.bar-chart {
  margin: 16px 0;
}
.bar-item {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}
.bar-item .bar-label {
  font-size: 13px;
  color: var(--gray-mid);
  width: 200px;
  flex-shrink: 0;
  text-align: right;
}
.bar-item .bar-track {
  flex: 1;
  background: var(--gray-border);
  border-radius: 4px;
  height: 24px;
  position: relative;
  overflow: hidden;
}
.bar-item .bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--green-mid), var(--green-light));
  border-radius: 4px;
  display: flex;
  align-items: center;
  padding-left: 8px;
  transition: width 0.6s ease;
}
.bar-item .bar-fill.terra {
  background: linear-gradient(90deg, var(--terra), var(--yellow));
}
.bar-item .bar-pct {
  font-size: 13px;
  font-weight: 700;
  color: var(--gray-dark);
  width: 50px;
  flex-shrink: 0;
}

/* ---- Funnel ---- */
.funnel {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  margin: 24px auto;
  max-width: 500px;
}
.funnel-step {
  width: 100%;
  text-align: center;
  padding: 14px 20px;
  color: white;
  font-weight: 700;
  position: relative;
}
.funnel-step .f-label { font-size: 13px; opacity: 0.85; }
.funnel-step .f-value { font-size: 24px; }
.funnel-step .f-sub { font-size: 12px; opacity: 0.8; }
.funnel-arrow {
  font-size: 18px;
  color: var(--gray-light);
  margin: -2px 0;
}

/* ---- Table ---- */
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
  margin: 16px 0;
  background: var(--white);
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.data-table th {
  background: var(--green-dark);
  color: white;
  padding: 10px 14px;
  text-align: left;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.data-table td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--gray-border);
  color: var(--gray-dark);
  vertical-align: top;
  line-height: 1.6;
}
.data-table tr:last-child td { border-bottom: none; }
.data-table tr:nth-child(even) td { background: var(--gray-bg); }
.data-table .good { color: var(--green-mid); font-weight: 700; }
.data-table .bad { color: var(--red-warn); font-weight: 700; }

/* ---- Alert boxes ---- */
.alert {
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  margin: 16px 0;
  font-size: 14px;
  line-height: 1.7;
  display: flex;
  gap: 12px;
}
.alert-icon { font-size: 18px; flex-shrink: 0; margin-top: 1px; }
.alert.caution { background: var(--red-pale); border-left: 4px solid var(--red-warn); }
.alert.caution .alert-icon { color: var(--red-warn); }
.alert.info { background: var(--blue-pale); border-left: 4px solid var(--blue-accent); }
.alert.info .alert-icon { color: var(--blue-accent); }
.alert.action { background: var(--terra-pale); border-left: 4px solid var(--terra); }
.alert.action .alert-icon { color: var(--terra); }
.alert.success { background: var(--green-bg); border-left: 4px solid var(--green-mid); }
.alert.success .alert-icon { color: var(--green-mid); }

/* ---- Action List ---- */
.action-list {
  list-style: none;
  padding: 0;
}
.action-list li {
  display: flex;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--gray-border);
  font-size: 14px;
  line-height: 1.7;
}
.action-list li:last-child { border-bottom: none; }
.action-list .action-tag {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 10px;
  white-space: nowrap;
  height: fit-content;
  margin-top: 3px;
  flex-shrink: 0;
}
.action-tag.immediate { background: #fde8e8; color: #c0392b; }
.action-tag.next { background: #fdf3e7; color: #bc6c25; }
.action-tag.longterm { background: #e8f4fd; color: #1d6fa4; }
.action-tag.measure { background: var(--green-bg); color: var(--green-dark); }

/* ---- Divider ---- */
.divider {
  border: none;
  border-top: 1px solid var(--gray-border);
  margin: 32px 0;
}

/* ---- Pill tags ---- */
.pill {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 12px;
  margin: 2px;
}
.pill.green { background: var(--green-pale); color: var(--green-dark); }
.pill.terra { background: var(--terra-pale); color: var(--terra); }
.pill.blue { background: var(--blue-pale); color: var(--blue-accent); }
.pill.gray { background: var(--gray-border); color: var(--gray-mid); }

/* ---- Cross-tab card ---- */
.cross-card {
  background: var(--white);
  border: 1px solid var(--gray-border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 16px;
  box-shadow: var(--shadow);
}
.cross-card .cross-header {
  background: var(--green-bg);
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.cross-card .cross-header .num {
  background: var(--green-dark);
  color: white;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  flex-shrink: 0;
}
.cross-card .cross-header .title {
  font-weight: 700;
  font-size: 14px;
  color: var(--green-dark);
}
.cross-card .cross-body {
  padding: 20px;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 16px;
  font-size: 13.5px;
}
.cross-card .cross-body .col-label {
  font-size: 11px;
  font-weight: 700;
  color: var(--gray-light);
  letter-spacing: 0.06em;
  margin-bottom: 6px;
}
.cross-card .cross-body .col-content {
  line-height: 1.7;
  color: var(--gray-dark);
}

/* ---- Footer ---- */
.page-footer {
  margin-top: 80px;
  padding: 32px 0;
  border-top: 1px solid var(--gray-border);
  font-size: 12px;
  color: var(--gray-light);
  text-align: center;
}

/* ---- Responsive ---- */
@media (max-width: 900px) {
  .page-wrapper {
    grid-template-columns: 1fr;
  }
  .sidebar {
    display: none;
  }
  .main-content {
    padding: 24px 20px 60px;
  }
  .finding-card .card-body {
    grid-template-columns: 1fr;
  }
  .cross-card .cross-body {
    grid-template-columns: 1fr;
  }
}
