:root {
  color-scheme: light;
  --bg: #f6f8f7;
  --surface: #ffffff;
  --surface-soft: #eef5f2;
  --text: #18201d;
  --muted: #5d6b66;
  --line: #dce5e1;
  --green: #147a4f;
  --green-soft: #e5f4ed;
  --blue: #2367a2;
  --blue-soft: #e8f1fb;
  --amber: #9a6516;
  --amber-soft: #fff2da;
  --red: #9d4a2c;
  --red-soft: #fff0e8;
  --shadow: 0 18px 50px rgba(27, 42, 35, 0.1);
  --radius: 12px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family:
    "Yu Gothic",
    "Hiragino Kaku Gothic ProN",
    Meiryo,
    system-ui,
    sans-serif;
  line-height: 1.72;
}

button,
input,
textarea {
  font: inherit;
}

.hero,
.section,
.report-band,
.cta-section {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.65fr);
  gap: 28px;
  align-items: center;
  min-height: 420px;
  padding: 56px 0 36px;
}

.hero__copy {
  max-width: 780px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--green);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1 {
  margin: 0;
  max-width: 850px;
  font-size: clamp(2rem, 5vw, 4.35rem);
  line-height: 1.13;
  letter-spacing: 0;
}

h2 {
  margin: 0;
  font-size: clamp(1.35rem, 2.3vw, 2rem);
  line-height: 1.25;
  letter-spacing: 0;
}

h3 {
  margin: 0;
  font-size: 1.1rem;
  line-height: 1.35;
  letter-spacing: 0;
}

.lead {
  max-width: 720px;
  margin: 24px 0 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.6vw, 1.18rem);
}

.today-panel,
.demo-box,
.report-card,
.value-card,
.case-card,
.cta-box {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.today-panel {
  padding: 22px;
}

.panel-title {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  font-weight: 700;
}

.panel-title strong {
  display: inline-grid;
  place-items: center;
  min-width: 64px;
  height: 40px;
  border-radius: 999px;
  background: var(--green-soft);
  color: var(--green);
  font-size: 1.08rem;
}

.result-list,
.report-list {
  display: grid;
  gap: 10px;
  margin: 0;
}

.result-list div,
.report-list div {
  display: flex;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  border-top: 1px solid var(--line);
}

dt {
  color: var(--muted);
}

dd {
  margin: 0;
  font-weight: 800;
}

.section {
  padding: 38px 0;
}

.help-section {
  padding-top: 20px;
}

.section-heading {
  margin-bottom: 18px;
}

.section-heading.compact {
  margin-bottom: 14px;
}

.section-note {
  margin: 8px 0 0;
  color: var(--muted);
}

.value-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.value-card {
  min-height: 150px;
  padding: 20px;
}

.value-card p {
  margin: 10px 0 0;
  color: var(--muted);
}

.steps {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.step {
  min-height: 142px;
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.step span {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  margin-bottom: 14px;
  border-radius: 50%;
  background: var(--blue-soft);
  color: var(--blue);
  font-weight: 800;
}

.step p {
  margin: 0;
  font-weight: 700;
  line-height: 1.48;
}

.case-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.case-card {
  display: grid;
  gap: 12px;
  padding: 20px;
  line-height: 1.82;
}

.case-card p {
  margin: 0;
  color: var(--muted);
}

.case-detail {
  display: grid;
  gap: 8px;
  margin-top: 4px;
}

.case-detail div {
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.case-detail b,
.customer-note b {
  display: block;
  margin-bottom: 2px;
  color: var(--text);
}

.customer-note {
  margin-top: 4px;
  padding: 14px;
  background: var(--surface-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.label {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 32px;
  padding: 4px 11px;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 800;
}

.label.review {
  background: var(--blue-soft);
  color: var(--blue);
}

.label.pause {
  background: var(--amber-soft);
  color: var(--amber);
}

.split-section {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(360px, 1.1fr);
  gap: 24px;
  align-items: start;
}

.plain-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.plain-list li {
  padding: 14px 16px;
  background: var(--surface-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-weight: 700;
}

.demo-box {
  padding: 22px;
}

.button-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.action-button,
.cta-button {
  min-height: 48px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  font-weight: 800;
}

.action-button:hover,
.action-button:focus-visible,
.cta-button:hover,
.cta-button:focus-visible {
  border-color: var(--blue);
  outline: none;
}

.action-button.is-active,
.cta-button {
  background: var(--blue);
  border-color: var(--blue);
  color: #ffffff;
}

.demo-result {
  min-height: 136px;
  margin-top: 16px;
  padding: 18px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
}

.demo-result.ok {
  background: var(--green-soft);
}

.demo-result.caution {
  background: var(--red-soft);
}

.demo-result strong {
  display: block;
  margin-bottom: 6px;
  font-size: clamp(1.45rem, 2.4vw, 1.85rem);
  line-height: 1.2;
}

.demo-result p {
  margin: 0;
  color: var(--muted);
}

.report-band {
  padding: 38px 0 44px;
}

.report-card {
  padding: 26px;
}

.report-list {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0;
  border-top: 1px solid var(--line);
}

.report-list div {
  display: grid;
  align-content: start;
  min-height: 98px;
  padding: 16px;
  border-top: 0;
  border-right: 1px solid var(--line);
}

.report-list div:last-child {
  border-right: 0;
}

.report-list dd {
  font-size: 1.08rem;
}

.saved-message {
  margin: 24px 0 0;
  padding: 18px;
  border-radius: var(--radius);
  background: #18382d;
  color: #ffffff;
  font-size: clamp(1.15rem, 2vw, 1.55rem);
  font-weight: 800;
  text-align: center;
}

.cta-section {
  padding: 20px 0 64px;
}

.cta-box {
  padding: 30px;
  text-align: center;
}

.cta-box p {
  max-width: 720px;
  margin: 14px auto 22px;
  color: var(--muted);
}

.cta-button {
  min-width: 220px;
}

@media (max-width: 980px) {
  .hero,
  .split-section {
    grid-template-columns: 1fr;
  }

  .steps,
  .value-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .case-grid {
    grid-template-columns: 1fr;
  }

  .report-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .report-list div {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
}

@media (max-width: 640px) {
  .hero,
  .section,
  .report-band,
  .cta-section {
    width: min(100% - 28px, 1120px);
  }

  .hero {
    min-height: auto;
    padding-top: 34px;
  }

  .steps,
  .button-row,
  .report-list,
  .value-grid {
    grid-template-columns: 1fr;
  }

  .step,
  .value-card {
    min-height: auto;
  }

  .today-panel,
  .demo-box,
  .report-card,
  .case-card,
  .value-card,
  .cta-box {
    padding: 18px;
  }
}

/* ===== PAIN SECTION ===== */
.pain-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.pain-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 22px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--red);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.pain-icon {
  font-size: 1.6rem;
}

.pain-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.72;
}

/* ===== EVIDENCE NOTE IN CASES ===== */
.evidence-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 4px;
  padding: 12px 14px;
  background: var(--green-soft);
  border: 1px solid #b6dfc9;
  border-radius: var(--radius);
}

.evidence-icon {
  font-size: 1.1rem;
  flex-shrink: 0;
  margin-top: 2px;
}

.evidence-note b {
  display: block;
  margin-bottom: 2px;
  color: var(--green);
  font-size: 0.88rem;
}

.evidence-note p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
}

/* ===== TAMPER DEMO — CENTERPIECE ===== */
.tamper-section {
  padding: 48px 0;
}

.tamper-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 24px;
  align-items: start;
}

.tamper-steps {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.tamper-step {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  opacity: 0.45;
  transition: opacity 0.2s, border-color 0.2s;
}

.tamper-step.is-active {
  opacity: 1;
  border-color: var(--blue);
  box-shadow: 0 0 0 3px var(--blue-soft);
}

.ts-num {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--blue-soft);
  color: var(--blue);
  font-weight: 800;
  font-size: 0.85rem;
  flex-shrink: 0;
}

.ts-body .ts-title {
  font-weight: 800;
  font-size: 0.92rem;
  margin-bottom: 2px;
}

.ts-body .ts-desc {
  font-size: 0.82rem;
  color: var(--muted);
}

.tamper-arrow {
  text-align: center;
  padding: 6px 0;
  color: var(--line);
  font-size: 1.2rem;
}

.tamper-demo-area {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.tamper-buttons {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.tamper-btn {
  min-height: 48px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  font-weight: 800;
  font-size: 0.88rem;
  transition: border-color 0.15s;
}

.tamper-btn:hover { border-color: var(--blue); }
.tamper-btn.is-active {
  background: var(--blue);
  border-color: var(--blue);
  color: #fff;
}

.tamper-result {
  min-height: 220px;
  padding: 22px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
  transition: background 0.2s;
}

.tamper-result.ok     { background: var(--green-soft); border-color: #b6dfc9; }
.tamper-result.caution{ background: var(--red-soft);   border-color: #f5c0a0; }
.tamper-result.info   { background: var(--blue-soft);  border-color: #b3d0f0; }

.tamper-result strong {
  display: block;
  margin-bottom: 8px;
  font-size: clamp(1.2rem, 2vw, 1.55rem);
  line-height: 1.2;
}

.tamper-result > p {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.72;
}

.td-grid {
  display: grid;
  gap: 8px;
}

.td-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 0.9rem;
  background: rgba(255,255,255,0.6);
  border: 1px solid rgba(0,0,0,0.06);
}

.td-row.ng {
  background: rgba(157,74,44,0.07);
  border-color: rgba(157,74,44,0.2);
}

.td-label { color: var(--muted); font-size: 0.85rem; }
.td-value { font-weight: 800; }
.td-row.ok  .td-value { color: var(--green); }
.td-row.ng  .td-value { color: var(--red); }

/* ===== ADIC BRIDGE ===== */
.adic-bridge {
  padding-bottom: 16px;
}

.adic-card {
  background: #18382d;
  border-radius: var(--radius);
  overflow: hidden;
}

.adic-inner {
  padding: 36px 40px;
}

.adic-inner .eyebrow {
  color: #6ee7b7;
  margin-bottom: 12px;
}

.adic-inner h2 {
  color: #ffffff;
  margin-bottom: 16px;
  font-size: clamp(1.2rem, 2.2vw, 1.75rem);
}

.adic-inner p {
  color: #a7c5b8;
  max-width: 760px;
  font-size: 0.97rem;
  line-height: 1.82;
  margin: 0 0 22px;
}

.adic-inner strong {
  color: #ffffff;
}

.adic-link {
  display: inline-block;
  padding: 10px 22px;
  background: rgba(255,255,255,0.12);
  color: #ffffff;
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 8px;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.9rem;
  transition: background 0.15s;
}

.adic-link:hover {
  background: rgba(255,255,255,0.2);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 980px) {
  .pain-grid {
    grid-template-columns: 1fr;
  }
  .tamper-layout {
    grid-template-columns: 1fr;
  }
  .tamper-steps {
    flex-direction: row;
    overflow-x: auto;
    gap: 8px;
  }
  .tamper-arrow {
    display: none;
  }
  .tamper-step {
    min-width: 160px;
  }
  .tamper-buttons {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .adic-inner {
    padding: 24px 20px;
  }
}

/* ===== GATE DEMO ===== */
.gate-section {
  padding: 48px 0;
}

.gate-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.gate-card {
  background: var(--surface);
  border: 2px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: box-shadow 0.15s;
}

.gate-card.blocked {
  border-left: 5px solid var(--red);
}

.gate-card.allowed {
  border-left: 5px solid var(--green);
}

.gate-card-header {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 18px 20px;
  cursor: pointer;
  user-select: none;
}

.gate-card-header:hover {
  background: var(--surface-soft);
}

.gate-status-badge {
  flex-shrink: 0;
  padding: 5px 14px;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 800;
  white-space: nowrap;
  margin-top: 2px;
}

.gate-status-badge.blocked {
  background: var(--red-soft);
  color: var(--red);
}

.gate-status-badge.allowed {
  background: var(--green-soft);
  color: var(--green);
}

.gate-card-title {
  flex: 1;
}

.gate-card-title h3 {
  margin: 0 0 4px;
  font-size: 1rem;
}

.gate-card-title p {
  margin: 0;
  font-size: 0.88rem;
  color: var(--muted);
  line-height: 1.6;
}

.gate-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 8px;
  font-size: 0.82rem;
  color: var(--muted);
}

.gate-chevron {
  font-size: 11px;
  color: var(--muted);
  transition: transform 0.2s;
  flex-shrink: 0;
  margin-top: 4px;
}

.gate-chevron.open {
  transform: rotate(180deg);
}

.gate-detail {
  display: none;
  padding: 0 20px 18px;
  border-top: 1px solid var(--line);
  margin-top: 0;
}

.gate-detail.open {
  display: block;
}

.gate-checks {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 8px;
  padding: 16px 0 12px;
}

.gate-check {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 0.88rem;
  border: 1px solid var(--line);
}

.gate-check.ok {
  background: var(--green-soft);
  border-color: #b6dfc9;
}

.gate-check.ng {
  background: var(--red-soft);
  border-color: #f5c0a0;
}

.gc-icon {
  font-size: 1rem;
  flex-shrink: 0;
}

.gate-check.ok .gc-icon { color: var(--green); }
.gate-check.ng .gc-icon { color: var(--red); }

.gc-label {
  flex: 1;
  font-weight: 700;
}

.gc-status {
  font-size: 0.78rem;
  color: var(--muted);
  white-space: nowrap;
}

.gate-verdict {
  padding: 12px 16px;
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.6;
}

.gate-verdict.blocked {
  background: var(--red-soft);
  color: var(--red);
  border: 1px solid #f5c0a0;
}

.gate-verdict.allowed {
  background: var(--green-soft);
  color: var(--green);
  border: 1px solid #b6dfc9;
}

@media (max-width: 640px) {
  .gate-card-header {
    flex-wrap: wrap;
    gap: 10px;
  }
  .gate-checks {
    grid-template-columns: 1fr;
  }
}
