:root {
  color-scheme: light;
  --ink: #202631;
  --muted: #657082;
  --line: #d8dee8;
  --paper: #f7f8fb;
  --surface: #ffffff;
  --teal: #14766d;
  --teal-dark: #0d4f4a;
  --gold: #b77a19;
  --rose: #b34e5c;
  --blue: #2f5f9f;
  --shadow: 0 18px 50px rgba(22, 32, 45, 0.16);
}

* {
  box-sizing: border-box;
}

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

a {
  color: inherit;
}

img {
  max-width: 100%;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 64px;
  padding: 0 32px;
  color: #ffffff;
  background: rgba(23, 31, 42, 0.92);
  backdrop-filter: blur(16px);
}

.brand {
  font-weight: 800;
  text-decoration: none;
}

.nav-links {
  display: flex;
  gap: 20px;
  font-size: 0.95rem;
}

.nav-links a,
.site-footer a {
  text-decoration: none;
}

.ad-disclosure {
  margin: 0;
  padding: 10px 32px;
  color: #16202e;
  background: #e7f2ef;
  border-bottom: 1px solid #c8ded8;
  font-size: 0.9rem;
}

.diagnosis-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(360px, 0.72fr);
  gap: 36px;
  align-items: end;
  min-height: calc(100vh - 105px);
  padding: 64px 48px 72px;
  overflow: hidden;
  color: #ffffff;
  background:
    linear-gradient(90deg, rgba(14, 20, 29, 0.88), rgba(14, 20, 29, 0.48)),
    url("/assets/hero-declutter.png") center / cover;
}

.hero-copy {
  max-width: 760px;
  padding-bottom: 18px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--gold);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero-copy .eyebrow {
  color: #f1b94d;
}

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

h1 {
  margin: 0;
  max-width: 820px;
  font-size: 3.1rem;
  line-height: 1.18;
  letter-spacing: 0;
}

.hero-copy p:last-child {
  max-width: 680px;
  margin: 18px 0 0;
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.08rem;
}

.diagnosis-panel {
  display: grid;
  gap: 14px;
  padding: 24px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

label {
  display: grid;
  gap: 7px;
  font-size: 0.92rem;
  font-weight: 700;
}

textarea,
select,
input {
  width: 100%;
  min-height: 44px;
  padding: 11px 12px;
  color: var(--ink);
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 8px;
  font: inherit;
}

textarea {
  resize: vertical;
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.primary-button,
.link-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 18px;
  color: #ffffff;
  background: var(--teal);
  border: 0;
  border-radius: 8px;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
}

.primary-button:hover,
.link-button:hover {
  background: var(--teal-dark);
}

.results-zone,
.content-band,
.article-layout,
.simple-page {
  max-width: 1180px;
  margin: 0 auto;
  padding: 72px 32px;
}

.section-heading {
  max-width: 760px;
  margin-bottom: 26px;
}

.section-heading h2 {
  margin: 0;
  font-size: 2rem;
  line-height: 1.3;
  letter-spacing: 0;
}

.empty-state,
.checker,
.side-panel {
  padding: 22px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.result-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 18px;
}

.result-summary span {
  padding: 10px 12px;
  text-align: center;
  color: #ffffff;
  background: var(--blue);
  border-radius: 8px;
  font-weight: 800;
}

.result-summary span:nth-child(2) {
  background: var(--rose);
}

.result-summary span:nth-child(3) {
  background: var(--teal);
}

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

.lane-column {
  display: grid;
  align-content: start;
  gap: 14px;
}

.lane-heading {
  min-height: 132px;
  padding: 18px;
  color: #ffffff;
  background: #293342;
  border-radius: 8px;
}

.lane-heading h3 {
  margin: 0 0 8px;
  font-size: 1.05rem;
}

.lane-heading p {
  margin: 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.92rem;
}

.result-card,
.program-card {
  display: grid;
  gap: 14px;
  min-height: 300px;
  padding: 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.result-card h3,
.program-card h3 {
  margin: 0 0 8px;
  font-size: 1.12rem;
  line-height: 1.45;
}

.result-card p,
.program-card p {
  margin: 0;
  color: var(--muted);
}

.match-reason,
.lane-label {
  color: var(--gold) !important;
  font-size: 0.82rem;
  font-weight: 800;
}

.mini-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 1.2em;
  color: var(--muted);
  font-size: 0.9rem;
}

.card-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.text-link,
.secondary-link {
  color: var(--teal-dark);
  font-weight: 800;
}

.soft-note {
  margin: 0;
  color: var(--muted);
}

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

.page-tile {
  min-height: 132px;
  padding: 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 5px solid var(--teal);
  border-radius: 8px;
  text-decoration: none;
}

.page-tile span {
  display: block;
  color: var(--gold);
  font-size: 0.84rem;
  font-weight: 800;
}

.page-tile strong {
  display: block;
  margin-top: 8px;
  font-size: 1.05rem;
  line-height: 1.45;
}

.checker-band {
  padding-top: 20px;
}

.checker {
  display: grid;
  gap: 14px;
}

.checker-result {
  min-height: 54px;
  padding: 14px;
  background: #f3f6f8;
  border: 1px dashed #c7d0dc;
  border-radius: 8px;
}

.checker-result span {
  color: var(--rose);
  font-weight: 800;
}

.article-hero {
  min-height: 340px;
  display: grid;
  align-items: end;
  padding: 54px 32px;
  color: #ffffff;
  background:
    linear-gradient(90deg, rgba(14, 20, 29, 0.9), rgba(14, 20, 29, 0.42)),
    url("/assets/hero-declutter.png") center / cover;
}

.article-hero > div {
  max-width: 960px;
  margin: 0 auto;
  width: 100%;
}

.article-hero h1 {
  font-size: 2.7rem;
}

.article-hero p:last-child {
  max-width: 760px;
  color: rgba(255, 255, 255, 0.88);
}

.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 28px;
  align-items: start;
}

.article-body {
  display: grid;
  gap: 22px;
}

.article-body h2,
.simple-page h1 {
  margin: 0;
  line-height: 1.35;
}

.article-body p,
.simple-page p {
  margin: 0;
  color: var(--muted);
}

.side-panel {
  position: sticky;
  top: 92px;
}

.side-panel h2 {
  margin-top: 0;
  font-size: 1.15rem;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 34px 32px;
  color: #dbe4ee;
  background: #202631;
}

.site-footer p {
  margin: 6px 0 0;
  color: #aeb9c6;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-content: start;
}

.tracking-pixel {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

@media (max-width: 960px) {
  .diagnosis-hero,
  .article-layout {
    grid-template-columns: 1fr;
  }

  .lane-grid,
  .page-grid,
  .program-grid {
    grid-template-columns: 1fr;
  }

  .lane-heading {
    min-height: auto;
  }

  h1,
  .article-hero h1 {
    font-size: 2.25rem;
  }

  .side-panel {
    position: static;
  }
}

@media (max-width: 640px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
    padding: 14px 18px;
  }

  .nav-links {
    gap: 14px;
    font-size: 0.88rem;
  }

  .ad-disclosure {
    padding: 9px 18px;
  }

  .diagnosis-hero,
  .article-hero {
    min-height: auto;
    padding: 44px 18px;
  }

  .diagnosis-panel {
    padding: 18px;
  }

  .field-grid,
  .result-summary {
    grid-template-columns: 1fr;
  }

  .results-zone,
  .content-band,
  .article-layout,
  .simple-page {
    padding: 48px 18px;
  }

  h1,
  .article-hero h1 {
    font-size: 1.85rem;
  }

  .section-heading h2 {
    font-size: 1.55rem;
  }

  .site-footer {
    flex-direction: column;
    padding: 28px 18px;
  }
}
