:root {
  --bg: #ffffff;
  --surface: #f6f7f9;
  --ink: #202329;
  --muted: #616a76;
  --line: #d9dee6;
  --accent: #f26a21;
  --accent-dark: #b74310;
  --graphite: #2b2f36;
  --soft-orange: #fff3ec;
  --max: 1160px;
  --radius: 8px;
}

* { box-sizing: border-box; }

html {
  color-scheme: light;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
}

img, svg { max-width: 100%; height: auto; }

a {
  color: var(--accent-dark);
  text-underline-offset: 0.18em;
}

a:hover { color: #7f2d0c; }

:focus-visible {
  outline: 3px solid rgba(242, 106, 33, 0.45);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 1000;
  padding: 0.7rem 1rem;
  background: var(--ink);
  color: #fff;
}

.skip-link:focus { top: 1rem; }

.site-header {
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.98);
}

.header-inner,
.container {
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto;
}

.header-inner {
  min-height: 74px;
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--ink);
  font-weight: 800;
  text-decoration: none;
  letter-spacing: 0;
}

.brand-mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  background: var(--graphite);
  color: var(--accent);
  font-weight: 900;
}

.nav-toggle {
  display: none;
  margin-left: auto;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  border-radius: var(--radius);
  padding: 0.55rem 0.75rem;
  font-weight: 700;
}

.primary-nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.15rem;
}

.primary-nav a {
  color: var(--ink);
  text-decoration: none;
  padding: 0.65rem 0.8rem;
  border-radius: 6px;
  font-weight: 700;
  font-size: 0.94rem;
}

.primary-nav a[aria-current="page"],
.primary-nav a:hover {
  background: var(--soft-orange);
  color: var(--accent-dark);
}

.nav-action {
  border: 1px solid var(--accent);
  color: var(--accent-dark) !important;
}

.hero {
  padding: 58px 0 34px;
  background:
    linear-gradient(90deg, rgba(242,106,33,0.08) 0, rgba(242,106,33,0) 36%),
    linear-gradient(#fff, #fff);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(320px, 1.1fr);
  gap: 2rem;
  align-items: center;
}

.eyebrow {
  margin: 0 0 0.9rem;
  color: var(--accent-dark);
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

h1, h2, h3 {
  margin: 0;
  line-height: 1.12;
  letter-spacing: 0;
}

h1 {
  max-width: 900px;
  font-size: clamp(2.35rem, 6vw, 4.8rem);
}

h2 { font-size: clamp(1.65rem, 3vw, 2.65rem); }
h3 { font-size: 1.18rem; }

.lead {
  max-width: 720px;
  color: var(--muted);
  font-size: 1.12rem;
}

.hero-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  overflow: hidden;
  box-shadow: 0 18px 50px rgba(32, 35, 41, 0.08);
}

.hero-panel img {
  display: block;
  width: 100%;
}

.panel-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--line);
}

.panel-row span {
  padding: 0.9rem;
  border-right: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.9rem;
}

.panel-row span:last-child { border-right: 0; }

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.72rem 1rem;
  border-radius: var(--radius);
  border: 1px solid var(--graphite);
  background: var(--graphite);
  color: #fff;
  text-decoration: none;
  font-weight: 800;
}

.btn:hover { color: #fff; background: #111318; }

.btn.secondary {
  background: #fff;
  color: var(--graphite);
}

.btn.secondary:hover {
  background: var(--surface);
  color: var(--graphite);
}

.section { padding: 54px 0; }
.section.alt { background: var(--surface); }

.section-head {
  display: flex;
  justify-content: space-between;
  gap: 1.5rem;
  align-items: end;
  margin-bottom: 1.6rem;
}

.section-head p {
  max-width: 580px;
  margin: 0;
  color: var(--muted);
}

.module-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: #fff;
}

.module-strip article {
  padding: 1.2rem;
  min-height: 188px;
  border-right: 1px solid var(--line);
}

.module-strip article:last-child { border-right: 0; }

.code {
  display: inline-block;
  margin-bottom: 0.9rem;
  color: var(--accent-dark);
  font-family: "Courier New", Courier, monospace;
  font-size: 0.82rem;
  font-weight: 800;
}

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

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

.card,
.note,
.toc {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 1.2rem;
}

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

.feature-line {
  display: grid;
  grid-template-columns: 190px 1fr;
  gap: 1rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--line);
}

.feature-line:last-child { border-bottom: 0; }

.feature-line strong { color: var(--graphite); }

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 680px;
}

th, td {
  padding: 0.95rem;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  background: var(--graphite);
  color: #fff;
}

tr:last-child td { border-bottom: 0; }

.steps {
  counter-reset: step;
  display: grid;
  gap: 0.85rem;
}

.step {
  counter-increment: step;
  display: grid;
  grid-template-columns: 52px 1fr;
  gap: 1rem;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.step::before {
  content: counter(step, decimal-leading-zero);
  color: var(--accent-dark);
  font-family: "Courier New", Courier, monospace;
  font-weight: 900;
}

.compact-list {
  margin: 0;
  padding-left: 1.15rem;
}

.compact-list li + li { margin-top: 0.45rem; }

.form-layout {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 1.5rem;
  align-items: start;
}

.contact-form {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.2rem;
  background: #fff;
}

.field { margin-bottom: 1rem; }

label {
  display: block;
  margin-bottom: 0.35rem;
  font-weight: 800;
}

input,
textarea {
  width: 100%;
  border: 1px solid #bfc6d0;
  border-radius: 6px;
  padding: 0.75rem;
  font: inherit;
  color: var(--ink);
  background: #fff;
}

textarea { min-height: 150px; resize: vertical; }

.hint {
  margin: 0.28rem 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.checkbox {
  display: grid;
  grid-template-columns: 22px 1fr;
  gap: 0.55rem;
  align-items: start;
}

.checkbox input { width: auto; margin-top: 0.25rem; }

.status {
  border-left: 4px solid var(--accent);
  background: var(--soft-orange);
  padding: 0.85rem 1rem;
  margin-bottom: 1rem;
}

.hp-field {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.legal-content {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 2rem;
  align-items: start;
}

.toc {
  position: sticky;
  top: 1rem;
}

.toc a {
  display: block;
  margin: 0.35rem 0;
}

.legal-section {
  padding-bottom: 2rem;
  margin-bottom: 2rem;
  border-bottom: 1px solid var(--line);
}

.site-footer {
  padding: 40px 0;
  border-top: 1px solid var(--line);
  background: var(--graphite);
  color: #fff;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 1.5rem;
}

.site-footer a,
.site-footer button {
  color: #fff;
}

.footer-links {
  display: grid;
  gap: 0.4rem;
}

.cookie-settings {
  padding: 0;
  border: 0;
  background: transparent;
  font: inherit;
  text-decoration: underline;
  cursor: pointer;
}

.cookie-banner {
  position: fixed;
  inset: auto 16px 16px 16px;
  z-index: 900;
  max-width: 760px;
  margin: 0 auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 18px 55px rgba(0, 0, 0, 0.18);
  padding: 1rem;
}

.cookie-banner[hidden],
.cookie-dialog[hidden] { display: none; }

.cookie-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.cookie-dialog {
  position: fixed;
  inset: 0;
  z-index: 950;
  display: grid;
  place-items: center;
  padding: 1rem;
  background: rgba(32, 35, 41, 0.55);
}

.cookie-modal {
  width: min(640px, 100%);
  max-height: calc(100vh - 2rem);
  overflow: auto;
  border-radius: var(--radius);
  background: #fff;
  padding: 1.2rem;
}

.cookie-option {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 0;
  border-bottom: 1px solid var(--line);
}

.cookie-option:last-child { border-bottom: 0; }

.switch input { width: auto; }

@media (max-width: 860px) {
  .nav-toggle { display: inline-flex; }
  .primary-nav {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 74px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 0.8rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: 0 20px 40px rgba(0,0,0,0.12);
  }
  .primary-nav.is-open { display: flex; }
  .hero-grid,
  .grid-2,
  .grid-3,
  .form-layout,
  .legal-content,
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .module-strip { grid-template-columns: repeat(2, 1fr); }
  .module-strip article { border-bottom: 1px solid var(--line); }
  .section-head { display: block; }
  .toc { position: static; }
}

@media (max-width: 560px) {
  .header-inner,
  .container { width: min(100% - 24px, var(--max)); }
  .hero { padding-top: 36px; }
  .module-strip { grid-template-columns: 1fr; }
  .module-strip article { border-right: 0; }
  .panel-row { grid-template-columns: 1fr; }
  .panel-row span { border-right: 0; border-bottom: 1px solid var(--line); }
  .feature-line { grid-template-columns: 1fr; }
  .button-row,
  .cookie-actions { flex-direction: column; }
  .btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}
