:root {
  color-scheme: light;
  --ink: #132a3a;
  --muted: #5b6e79;
  --brand: #0866c6;
  --brand-dark: #064d96;
  --line: #d8e2e8;
  --soft: #f3f7fa;
  --green: #087f5b;
  --green-soft: #e8f7f0;
  --amber: #8a5900;
  --amber-soft: #fff7df;
  --blue-soft: #eaf4ff;
  --shadow: 0 14px 38px rgba(20, 48, 68, 0.1);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background: #fff;
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.55;
}

a { color: var(--brand-dark); }
a:hover { color: var(--brand); }

.hero {
  color: #fff;
  background: linear-gradient(125deg, #063a72 0%, #0874d6 62%, #09a6a0 130%);
  padding: 42px 24px;
}

.hero-inner,
main {
  width: min(1080px, 100%);
  margin: 0 auto;
}

.hero-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.brand { display: flex; align-items: center; gap: 18px; }
.brand img { width: 72px; height: 72px; object-fit: contain; }
.eyebrow { margin-bottom: 5px; font-size: 0.78rem; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; opacity: 0.85; }
h1 { margin: 0; font-size: clamp(2rem, 5vw, 3.25rem); line-height: 1.05; }
.hero p { max-width: 650px; margin: 12px 0 0; font-size: 1.08rem; opacity: 0.92; }
.hero-actions { display: grid; gap: 10px; min-width: 250px; }

.button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255,255,255,.8);
  border-radius: 10px;
  padding: 10px 16px;
  font: inherit;
  font-weight: 750;
  text-decoration: none;
  cursor: pointer;
}
.button.primary { color: var(--brand-dark); background: #fff; }
.button.secondary { color: #fff; background: rgba(255,255,255,.1); }

main { padding: 30px 24px 70px; }

.notice {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  border: 1px solid #b9e2d2;
  border-radius: 14px;
  padding: 18px 20px;
  background: var(--green-soft);
}
.notice-icon { display: grid; place-items: center; flex: 0 0 30px; height: 30px; border-radius: 50%; color: #fff; background: var(--green); font-weight: 900; }
.notice h2, .notice p { margin: 0; }
.notice h2 { font-size: 1.05rem; }

.quick-nav {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
  margin: 18px 0 34px;
}
.quick-nav a {
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 10px 8px;
  color: var(--ink);
  background: #fff;
  font-size: 0.88rem;
  font-weight: 750;
  text-align: center;
  text-decoration: none;
}
.quick-nav a:hover { border-color: #8ebbe5; background: var(--blue-soft); }

.section {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 20px;
  padding: 38px 0;
  border-top: 1px solid var(--line);
}
.section-number {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  color: #fff;
  background: var(--brand);
  font-size: 1.3rem;
  font-weight: 900;
  box-shadow: 0 8px 20px rgba(8, 102, 198, .22);
}
.section h2 { margin: 3px 0 4px; font-size: clamp(1.55rem, 3vw, 2.1rem); line-height: 1.2; }
.section h3 { margin: 30px 0 10px; font-size: 1.15rem; }
.lead { margin: 0 0 24px; color: var(--muted); font-size: 1.03rem; }

.checklist { display: grid; gap: 10px; }
.checklist label,
.acceptance label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 11px 13px;
  background: #fff;
}
input[type="checkbox"] { width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--brand); }

.callout { margin-top: 22px; border-left: 4px solid; border-radius: 10px; padding: 14px 16px; }
.callout p { margin: 4px 0 0; }
.callout.warning { border-color: #e4a11b; background: var(--amber-soft); }
.callout.info { border-color: var(--brand); background: var(--blue-soft); }
.callout.support { border-color: #6b7f8c; background: var(--soft); }

.steps { list-style: none; counter-reset: guide-step; margin: 0; padding: 0; }
.steps li {
  counter-increment: guide-step;
  position: relative;
  min-height: 55px;
  margin-left: 22px;
  padding: 4px 0 22px 48px;
  border-left: 2px solid #b8d3eb;
}
.steps li:last-child { border-left-color: transparent; padding-bottom: 0; }
.steps li::before {
  content: counter(guide-step);
  position: absolute;
  left: -20px;
  top: 0;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  color: var(--brand-dark);
  background: #fff;
  border: 2px solid var(--brand);
  font-weight: 900;
}
.steps strong, .steps span { display: block; }
.steps span { margin-top: 3px; color: var(--muted); }
.steps.compact li { padding-bottom: 17px; }

.acceptance { margin-top: 28px; border-radius: 14px; padding: 20px; background: var(--soft); }
.acceptance h3 { margin: 0 0 12px; }
.acceptance-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }

.simple-list { padding-left: 23px; }
.simple-list li { margin: 7px 0; }

.agent-card {
  border: 2px solid #a7cdeb;
  border-radius: 16px;
  padding: 24px;
  background: linear-gradient(145deg, #f8fbfe, #edf6ff);
  box-shadow: var(--shadow);
}
.agent-card-title { color: var(--brand-dark); font-size: 1.35rem; font-weight: 900; }
.agent-card li { margin: 9px 0; }
.agent-card p { margin-bottom: 0; }

.cards { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.card { border: 1px solid var(--line); border-radius: 13px; padding: 18px; background: #fff; box-shadow: 0 7px 20px rgba(20,48,68,.06); }
.card h3 { margin: 0 0 7px; }
.card p { margin: 0; color: var(--muted); }

.permission-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.permission { border-radius: 11px; padding: 16px; }
.permission strong, .permission span { display: block; }
.permission span { margin-top: 5px; }
.permission.yes { background: var(--green-soft); }
.permission.no { background: #fff1f0; }
.muted { color: var(--muted); }

.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; }
table { width: 100%; border-collapse: collapse; min-width: 650px; }
th, td { padding: 13px 15px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
th { color: #fff; background: #174f7d; }
td:first-child { width: 29%; font-weight: 800; }
tr:last-child td { border-bottom: 0; }
tbody tr:nth-child(even) { background: var(--soft); }

code { border-radius: 5px; padding: 2px 5px; background: #eaf0f4; font-family: Consolas, monospace; font-size: .92em; overflow-wrap: anywhere; }
.sources { border-top: 1px solid var(--line); padding-top: 28px; color: var(--muted); font-size: .92rem; }
.sources h2 { color: var(--ink); font-size: 1.2rem; }

@media (max-width: 800px) {
  .hero-inner { align-items: flex-start; flex-direction: column; }
  .hero-actions { width: 100%; }
  .quick-nav { grid-template-columns: repeat(3, 1fr); }
  .cards, .permission-grid { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .hero { padding: 28px 18px; }
  .brand { align-items: flex-start; }
  .brand img { width: 52px; height: 52px; }
  main { padding: 22px 16px 50px; }
  .quick-nav { grid-template-columns: 1fr 1fr; }
  .section { grid-template-columns: 1fr; gap: 10px; }
  .section-number { width: 40px; height: 40px; }
  .acceptance-grid { grid-template-columns: 1fr; }
  .steps li { margin-left: 18px; padding-left: 39px; }
}

@media print {
  @page { margin: 13mm; }
  body { font-size: 10.5pt; color: #000; }
  .hero { padding: 16px 0; color: #000; background: #fff; border-bottom: 2px solid #000; }
  .hero-inner, main { width: 100%; }
  .brand img { width: 48px; height: 48px; }
  .hero-actions, .quick-nav { display: none; }
  main { padding: 12px 0 0; }
  .section { padding: 18px 0; break-inside: auto; }
  .section-number { color: #000; background: #fff; border: 2px solid #000; box-shadow: none; }
  .card, .agent-card { box-shadow: none; break-inside: avoid; }
  .callout, .acceptance, table { break-inside: avoid; }
  a { color: #000; text-decoration: none; }
  a[href^="http"]::after { content: " (" attr(href) ")"; font-size: .75em; }
  input[type="checkbox"] { appearance: none; border: 1px solid #000; }
}
