:root {
  --bg: #f7f6f2;
  --surface: #ffffff;
  --text: #1c1f1e;
  --muted: #4f5553;
  --line: #d9dbd6;
  --accent: #0f6b5c;
  --accent-strong: #0a5246;
  --accent-soft: #e2f1ed;
  --danger: #a32121;
  --danger-soft: #fbeaea;
  --focus: #c45a00;
  --radius: 12px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #121514;
    --surface: #1b1f1e;
    --text: #eceeed;
    --muted: #b3b9b6;
    --line: #333a38;
    --accent: #4fc2a9;
    --accent-strong: #7ad6c1;
    --accent-soft: #1d3430;
    --danger: #ff8a80;
    --danger-soft: #3a1f1f;
    --focus: #ffb454;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { font-size: 112.5%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
}
.wrap { max-width: 60rem; margin: 0 auto; padding: 0 16px; }
main.wrap { padding-top: 2rem; padding-bottom: 3rem; }
main:focus { outline: none; }

a { color: var(--accent); text-underline-offset: 0.18em; }
a:hover { color: var(--accent-strong); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }

.skip {
  position: absolute; left: 16px; top: -100px;
  background: var(--surface); color: var(--text); padding: 0.5rem 1rem; z-index: 10;
  border: 2px solid var(--focus); border-radius: 8px;
}
.skip:focus { top: 12px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

header.site { background: var(--surface); border-bottom: 1px solid var(--line); }
.bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem 1.5rem; padding-top: 0.8rem; padding-bottom: 0.8rem; }
.brand { font-weight: 700; font-size: 1.15rem; color: var(--text); text-decoration: none; }
header nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.25rem 1.25rem; align-items: center; }
footer.site { border-top: 1px solid var(--line); color: var(--muted); padding: 1.5rem 0; }

h1 { font-size: 2rem; line-height: 1.2; margin: 0 0 1rem; letter-spacing: -0.01em; }
h2 { font-size: 1.4rem; margin: 2.5rem 0 1rem; }
h3 { font-size: 1.15rem; margin: 1.5rem 0 0.5rem; }
.lead { font-size: 1.12rem; color: var(--muted); max-width: 42rem; }
.hero { padding: 1rem 0 0.5rem; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.95em; background: var(--accent-soft); padding: 0.1em 0.35em; border-radius: 5px; word-break: break-all; }

.cards { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr)); gap: 1rem; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.25rem 1.4rem 1.5rem; display: flex; flex-direction: column; }
.card h3 { margin-top: 0; }
.card .button, .card .soldout { margin-top: auto; align-self: flex-start; }
.price { font-size: 1.3rem; font-weight: 700; color: var(--accent); margin: 0; }
.soldout { font-weight: 600; color: var(--muted); }
.steps li { margin-bottom: 0.4rem; }

.button, button.button {
  display: inline-block; font: inherit; font-weight: 600; cursor: pointer;
  background: var(--accent); color: #fff; border: 2px solid var(--accent);
  padding: 0.6rem 1.2rem; border-radius: 10px; text-decoration: none; line-height: 1.3;
}
@media (prefers-color-scheme: dark) { .button, button.button { color: #0b1512; } }
.button:hover { background: var(--accent-strong); border-color: var(--accent-strong); color: #fff; }
@media (prefers-color-scheme: dark) { .button:hover { color: #0b1512; } }
.button.secondary { background: transparent; color: var(--accent); }
.button.secondary:hover { background: var(--accent-soft); color: var(--accent-strong); }
.button.danger { background: var(--danger); border-color: var(--danger); color: #fff; }
@media (prefers-color-scheme: dark) { .button.danger { color: #1b0b0b; } }
.linklike { font: inherit; background: none; border: 0; padding: 0; color: var(--accent); text-decoration: underline; text-underline-offset: 0.18em; cursor: pointer; }
form.inline { display: inline; }

.stack { display: flex; flex-direction: column; gap: 1rem; max-width: 40rem; }
.stack.narrow { max-width: 26rem; }
fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.25rem 1.25rem; margin: 0; background: var(--surface); display: flex; flex-direction: column; gap: 1rem; }
legend { font-weight: 700; padding: 0 0.4rem; }
.field { display: flex; flex-direction: column; gap: 0.3rem; min-width: 0; }
.field label { font-weight: 600; }
.field.check { flex-direction: row; align-items: flex-start; gap: 0.6rem; flex-wrap: wrap; }
.field.check input { width: 1.3rem; height: 1.3rem; margin-top: 0.2rem; flex: none; }
.field.check label { flex: 1; font-weight: 500; }
.row { display: grid; grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr)); gap: 1rem; }
input:not([type=checkbox]), select, textarea {
  font: inherit; color: var(--text); background: var(--bg); width: 100%;
  border: 2px solid var(--line); border-radius: 8px; padding: 0.55rem 0.7rem;
}
input:focus, select:focus, textarea:focus { border-color: var(--accent); }
.help { margin: 0; color: var(--muted); font-size: 0.93rem; }
.error { margin: 0; color: var(--danger); font-weight: 600; }
.has-error input:not([type=checkbox]) { border-color: var(--danger); }

.notice { background: var(--accent-soft); border-left: 5px solid var(--accent); border-radius: 8px; padding: 0.6rem 1rem; margin: 0 0 1.5rem; }
.notice p { margin: 0.3rem 0; }
.error-summary { background: var(--danger-soft); border: 2px solid var(--danger); border-radius: var(--radius); padding: 0.4rem 1.2rem 0.8rem; margin-bottom: 1.5rem; }
.error-summary h2 { margin: 0.6rem 0 0.4rem; font-size: 1.15rem; }
.error-summary a { color: var(--danger); font-weight: 600; }

.service { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 0.4rem 1.4rem 1.4rem; margin: 1.5rem 0; }
.facts { display: grid; grid-template-columns: max-content 1fr; gap: 0.35rem 1.25rem; margin: 1rem 0; }
.facts dt { font-weight: 600; color: var(--muted); }
.facts dd { margin: 0; min-width: 0; }
@media (max-width: 34rem) { .facts { grid-template-columns: 1fr; } .facts dd { margin-bottom: 0.5rem; } }
.actions { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 0.6rem; margin: 1rem 0; }
.panel { border: 1px solid var(--line); border-radius: var(--radius); padding: 0.2rem 1rem 1rem; margin: 1rem 0; background: var(--surface); }
.panel.danger { border-color: var(--danger); }
details > summary { cursor: pointer; padding: 0.5rem 0; }
details > summary h3 { display: inline; margin: 0; font-size: 1.05rem; }
.wrap-text { white-space: pre-wrap; word-break: break-word; font-size: 0.9rem; }

table { width: 100%; border-collapse: collapse; font-size: 0.92rem; display: block; overflow-x: auto; }
th, td { text-align: left; padding: 0.4rem 0.6rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.features { padding-left: 1.2rem; margin: 0 0 1.2rem; }
.features li { margin-bottom: 0.2rem; }
