:root {
  --ink: #1d1d1f;
  --muted: #6e6e73;
  --paper: #ffffff;
  --soft: #f5f5f7;
  --line: #d2d2d7;
  --teal: #0071e3;
  --teal-deep: #005bb5;
  --line-green: #06c755;
  --line-green-deep: #05a947;
  --red: #bf4800;
  --amber: #86868b;
  --olive: #0071e3;
  --white: #ffffff;
  --shadow: 0 12px 30px rgba(0, 0, 0, 0.06);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Yu Gothic", sans-serif;
  color: var(--ink);
  background: var(--paper);
  letter-spacing: 0;
}

a {
  color: inherit;
}

button,
input,
select,
textarea {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 52px;
  padding: 8px clamp(18px, 4vw, 48px);
  background: rgba(251, 251, 253, 0.82);
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  backdrop-filter: saturate(180%) blur(20px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
}

.brand-mark {
  width: 18px;
  height: 18px;
  display: inline-block;
  background: linear-gradient(135deg, #1d1d1f, #8e8e93);
  border-radius: 50%;
  box-shadow: inset 0 0 0 5px var(--paper);
}

.top-nav {
  display: flex;
  align-items: center;
  gap: clamp(10px, 2vw, 28px);
  color: #424245;
  font-size: 0.82rem;
}

.top-nav a {
  text-decoration: none;
}

.top-nav a:hover {
  color: var(--teal);
}

.hero {
  position: relative;
  min-height: min(680px, calc(100vh - 86px));
  display: grid;
  align-items: center;
  overflow: hidden;
  background: var(--soft);
}

.hero-image,
.hero-shade {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero-image {
  object-fit: cover;
  object-position: center;
  filter: saturate(0.88) contrast(0.98);
}

.hero-shade {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(255, 255, 255, 0.92) 42%, rgba(255, 255, 255, 0.54) 100%);
}

.hero-content {
  position: relative;
  width: min(840px, calc(100% - 32px));
  margin: 0 auto;
  padding: 72px 0 210px;
  text-align: center;
}

.kicker,
.section-label {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: 0;
}

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

h1 {
  margin: 0;
  max-width: none;
  font-size: clamp(3.4rem, 8vw, 6.7rem);
  line-height: 0.95;
  letter-spacing: 0;
}

h1 span {
  display: block;
}

.hero-copy {
  max-width: 760px;
  margin: 26px auto 0;
  color: var(--muted);
  font-size: clamp(1.12rem, 1.9vw, 1.45rem);
  line-height: 1.7;
}

.hero-actions,
.button-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 30px;
}

.button {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 10px 19px;
  border: 1px solid transparent;
  border-radius: 999px;
  text-decoration: none;
  cursor: pointer;
  font-weight: 700;
}

.button svg,
.icon-button svg {
  width: 19px;
  height: 19px;
  flex: 0 0 auto;
}

.button.primary {
  color: var(--white);
  background: var(--teal);
}

.button.primary:hover {
  background: var(--teal-deep);
}

.button.line-button {
  color: var(--white);
  background: var(--line-green);
}

.button.line-button:hover {
  background: var(--line-green-deep);
}

.button.quiet {
  color: var(--teal);
  background: rgba(255, 255, 255, 0.78);
  border-color: rgba(0, 113, 227, 0.26);
}

.button.full {
  width: 100%;
}

.icon-button {
  width: 44px;
  height: 44px;
  display: inline-grid;
  place-items: center;
  color: var(--muted);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 999px;
  cursor: pointer;
}

.alert-band {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px clamp(16px, 5vw, 64px);
  color: var(--ink);
  background: var(--white);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  line-height: 1.7;
}

.section {
  padding: clamp(64px, 9vw, 112px) clamp(16px, 5vw, 64px);
}

.section-inner {
  width: min(1180px, 100%);
  margin: 0 auto;
}

.section-light,
.section-template {
  background: var(--paper);
}

.section-tool,
.section-lawyer,
.section-contacts {
  background: var(--soft);
}

.split,
.two-column {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.3fr);
  gap: clamp(36px, 6vw, 80px);
  align-items: start;
}

.section-intro h2,
.tool-heading h2 {
  margin: 0;
  font-size: clamp(2.1rem, 4vw, 3.7rem);
  line-height: 1.04;
  letter-spacing: 0;
}

.section-intro p:not(.section-label),
.tool-heading p {
  color: var(--muted);
  line-height: 1.9;
}

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

.step-list li {
  display: grid;
  grid-template-columns: 52px 1fr;
  gap: 18px;
  padding: 24px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: none;
}

.step-number {
  width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  color: var(--white);
  background: var(--ink);
  border-radius: 50%;
  font-weight: 900;
}

.step-list h3,
.contact-card h3 {
  margin: 0 0 8px;
  font-size: 1.1rem;
}

.step-list p,
.contact-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.8;
}

.tool-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 30px;
}

.tool-heading p {
  max-width: 420px;
  margin: 0;
}

.tool-layout,
.template-layout,
.lawyer-layout {
  display: grid;
  grid-template-columns: minmax(280px, 420px) minmax(0, 1fr);
  gap: 22px;
}

.tool-panel,
.result-panel,
.memo-output,
.lawyer-profile {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow);
}

.tool-panel {
  display: grid;
  gap: 18px;
  padding: 22px;
}

.tool-panel.compact {
  align-content: start;
}

label,
legend {
  color: var(--ink);
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  min-height: 46px;
  margin-top: 8px;
  padding: 10px 12px;
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 6px;
}

input:focus,
select:focus,
textarea:focus {
  outline: 3px solid rgba(0, 113, 227, 0.18);
  border-color: var(--teal);
}

textarea {
  resize: vertical;
  line-height: 1.7;
}

.field-wrap {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 8px;
}

fieldset {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  border: 0;
}

.check-row,
.checklist label {
  display: grid;
  grid-template-columns: 22px 1fr;
  align-items: start;
  gap: 10px;
  color: var(--ink);
  font-weight: 600;
  line-height: 1.6;
}

.check-row input,
.checklist input {
  width: 18px;
  min-height: 18px;
  height: 18px;
  margin: 3px 0 0;
  accent-color: var(--teal);
}

.result-panel {
  min-height: 100%;
  padding: 26px;
}

.risk-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.risk-line span {
  color: var(--muted);
  font-weight: 800;
}

.risk-line strong {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 82px;
  min-height: 42px;
  color: var(--white);
  background: var(--ink);
  border-radius: var(--radius);
  font-size: 1.15rem;
}

.risk-line strong.high {
  background: var(--red);
}

.risk-line strong.low {
  background: var(--teal);
}

.action-list {
  display: grid;
  gap: 12px;
  margin-top: 20px;
}

.action-item {
  padding: 16px;
  border-left: 4px solid var(--teal);
  background: var(--soft);
  border-radius: 6px;
  line-height: 1.75;
}

.action-item strong {
  display: block;
  margin-bottom: 4px;
}

.mini-note {
  margin-top: 18px;
  padding: 14px;
  color: var(--muted);
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 6px;
  line-height: 1.7;
}

.evidence-grid {
  display: grid;
  grid-template-columns: minmax(260px, 0.8fr) minmax(0, 1.2fr);
  gap: clamp(28px, 6vw, 72px);
}

.progress-wrap {
  margin-top: 28px;
}

.progress-meta {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-weight: 800;
}

.progress-bar {
  height: 12px;
  margin-top: 10px;
  overflow: hidden;
  background: #e8e8ed;
  border-radius: 999px;
}

.progress-bar span {
  display: block;
  width: 0;
  height: 100%;
  background: var(--teal);
  transition: width 160ms ease;
}

.checklist {
  display: grid;
  gap: 12px;
  padding: 22px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.memo-output {
  min-height: 480px;
  padding: 20px;
  line-height: 1.75;
}

.lawyer-profile {
  display: grid;
  align-content: start;
  gap: 16px;
  padding: 24px;
}

.lawyer-profile h3,
.lawyer-profile p {
  margin: 0;
}

.profile-label {
  width: fit-content;
  padding: 6px 10px;
  color: var(--white);
  background: var(--ink);
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 900;
}

.lawyer-profile h3 {
  font-size: 1.6rem;
}

.lawyer-profile dl {
  display: grid;
  gap: 10px;
  margin: 0;
}

.lawyer-profile dl div {
  display: grid;
  grid-template-columns: 70px 1fr;
  gap: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.lawyer-profile dt {
  color: var(--muted);
  font-weight: 900;
}

.lawyer-profile dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.lawyer-profile dd a {
  color: var(--teal);
  font-weight: 700;
  text-decoration: none;
}

.lawyer-profile dd a.line-link {
  color: var(--line-green);
}

.lawyer-profile dd a:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.lawyer-note {
  padding: 14px;
  color: var(--muted);
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 6px;
  line-height: 1.7;
}

.lawyer-output {
  width: 100%;
  min-height: 340px;
  margin-top: 22px;
}

.handoff-flow {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 22px;
}

.handoff-flow article {
  display: grid;
  gap: 8px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.handoff-flow span {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  color: var(--white);
  background: var(--ink);
  border-radius: 50%;
  font-weight: 900;
}

.handoff-flow h3,
.handoff-flow p {
  margin: 0;
}

.handoff-flow h3 {
  font-size: 1rem;
}

.handoff-flow p {
  color: var(--muted);
  line-height: 1.7;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
  margin-top: 34px;
}

.contact-card {
  display: grid;
  align-content: start;
  gap: 14px;
  min-height: 250px;
  padding: 20px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: none;
}

.contact-card a {
  align-self: end;
  color: var(--teal);
  font-weight: 700;
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

.site-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 26px clamp(16px, 5vw, 64px);
  color: #53615d;
  background: var(--soft);
  border-top: 1px solid var(--line);
  font-size: 0.9rem;
}

.site-footer p {
  margin: 0;
}

@media (max-width: 1000px) {
  .contact-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .split,
  .two-column,
  .tool-layout,
  .template-layout,
  .lawyer-layout,
  .handoff-flow,
  .evidence-grid {
    grid-template-columns: 1fr;
  }

  .tool-heading {
    align-items: start;
    flex-direction: column;
  }
}

@media (max-width: 700px) {
  .site-header {
    position: static;
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }

  .top-nav {
    width: 100%;
    justify-content: space-between;
  }

  .hero {
    min-height: 680px;
  }

  .hero-image {
    object-position: 62% center;
  }

  .hero-shade {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(255, 255, 255, 0.92) 48%, rgba(255, 255, 255, 0.58) 100%);
  }

  .hero-content {
    width: calc(100% - 32px);
    margin: 0 auto;
    padding: 64px 0 245px;
  }

  h1 {
    max-width: 10ch;
    font-size: clamp(2.6rem, 12vw, 4rem);
  }


  .alert-band {
    align-items: flex-start;
  }

  .step-list li {
    grid-template-columns: 42px 1fr;
    padding: 18px;
  }

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

  .contact-card {
    min-height: auto;
  }
}

@media print {
  .site-header,
  .hero,
  .icon-button,
  .hero-actions,
  .button,
  script {
    display: none !important;
  }

  .section {
    padding: 26px 0;
  }

  body {
    background: white;
  }

  .tool-panel,
  .result-panel,
  .memo-output,
  .contact-card,
  .step-list li,
  .checklist {
    box-shadow: none;
  }
}
