:root {
  --ink: #182f2c;
  --muted: #526660;
  --line: #d1dad2;
  --accent: #145446;
  --bg: #f4f6f1;
  font-family: Inter, "Segoe UI", Roboto, Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
}
* { box-sizing: border-box; }
body { margin: 0; }
h1, h2, h3, p, form { margin: 0; }
a { color: var(--accent); text-underline-offset: 0.2em; }
a:hover { color: #092f28; }
:focus-visible { outline: 3px solid #166fca; outline-offset: 4px; }
.skip {
  position: absolute;
  z-index: 1;
  top: 0.5rem;
  left: 0.5rem;
  padding: 0.7rem;
  background: white;
  transform: translateY(-200%);
}
.skip:focus { transform: translateY(0); }
.wrap { width: min(68rem, calc(100% - 3rem)); margin-inline: auto; }
.header { border-bottom: 1px solid var(--line); background: #fbfcf9; }
.nav {
  min-height: 4.5rem;
  padding-block: 0.65rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.brand, .nav-link { text-decoration: none; }
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  max-width: 100%;
  color: var(--ink);
  font-size: 1.15rem;
  font-weight: 750;
  overflow-wrap: anywhere;
}
.brand-mark {
  flex: none;
  width: 1.85rem;
  height: 1.85rem;
  display: grid;
  place-items: center;
  border-radius: 0.55rem;
  background: var(--accent);
}
.brand-mark::before {
  content: "";
  width: 0.9rem;
  height: 0.28rem;
  border-block: 0.18rem solid #d2e998;
  transform: skew(-12deg);
}
.nav-link { padding-block: 0.65rem; font-size: 0.95rem; font-weight: 650; }
.nav-link:hover, .back:hover { text-decoration: underline; }
.main { padding-block: clamp(1.75rem, 4vw, 3.3rem) 4rem; }
.demo {
  background: #e8efcf;
  color: #364521;
  border-radius: 0.6rem;
  padding: 0.8rem 1rem;
  margin-bottom: 2rem;
  font-size: 0.94rem;
  line-height: 1.5;
}
.section-heading { margin: 0 0 1.8rem; }
h1 {
  font-size: clamp(2.3rem, 5.6vw, 4.2rem);
  line-height: 1.06;
  font-weight: 720;
  letter-spacing: -0.055em;
  overflow-wrap: anywhere;
}
.section-heading > p, .order-body > p, .error p, .description {
  color: var(--muted);
  line-height: 1.58;
  overflow-wrap: anywhere;
}
.section-heading > p { margin-top: 0.8rem; }
.products { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(18.5rem, 100%), 1fr)); gap: 1rem; }
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 1rem;
  padding: clamp(1.2rem, 3vw, 1.75rem);
}
.product {
  display: flex;
  justify-content: space-between;
  flex-direction: column;
  gap: 2rem;
}
.product h2, .order h2 {
  font-size: 1.45rem;
  letter-spacing: -0.03em;
  line-height: 1.24;
  overflow-wrap: anywhere;
}
.description { margin-top: 0.65rem; white-space: pre-line; }
.buy-row, .order-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}
.buy-row { border-top: 1px solid var(--line); padding-top: 1.2rem; }
.price { font-weight: 680; font-size: 1.45rem; line-height: 1.2; white-space: nowrap; }
.price span { font-weight: 500; }
.button, button {
  min-height: 2.8rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.7rem 1.1rem;
  border: 1px solid transparent;
  border-radius: 0.6rem;
  color: white;
  background: var(--accent);
  font: 650 1rem/1.3 Inter, "Segoe UI", Roboto, Arial, sans-serif;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}
.button:hover, button:hover { color: white; background: #0b3d32; }
.narrow { max-width: 44rem; margin-inline: auto; }
.back { display: inline-block; margin-bottom: 1.5rem; padding-block: 0.35rem; text-decoration: none; }
.order-id span { font-family: "IBM Plex Mono", Consolas, monospace; }
.state {
  display: inline-block;
  margin-bottom: 0.65rem;
  font-size: 0.86rem;
  border-radius: 0.4rem;
  padding: 0.3rem 0.55rem;
  background: #edf1ed;
  color: #3f514d;
}
.state.paid { background: #e0f2d9; color: #295c30; }
.order-body { border-top: 1px solid var(--line); padding-top: 1.3rem; margin-top: 1.4rem; }
.order-body p + form, .order-body p + .button { margin-top: 1rem; }
.order-body h3 { margin-bottom: 0.6rem; font-size: 1.1rem; }
.delivery {
  padding: 1rem;
  border-left: 3px solid var(--accent);
  background: #f2f6ef;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  line-height: 1.6;
}
.order-links { display: flex; flex-wrap: wrap; gap: 0.4rem 1.4rem; margin-top: 1rem; }
.order-links a { display: inline-block; padding-block: 0.55rem; }
.error p { margin: 1rem 0 1.3rem; }
.footer { padding-block: 1.5rem; border-top: 1px solid var(--line); overflow-wrap: anywhere; }
.order-links .refresh { background: transparent; color: var(--accent); padding: 0.55rem 0; text-decoration: underline; }
@media (max-width: 36rem) {
  .wrap { width: calc(100% - 2rem); }
  .nav { min-height: 3.8rem; column-gap: 0.7rem; row-gap: 0; }
  .brand { font-size: 1.02rem; }
  .nav-link { font-size: 0.86rem; }
  .product { gap: 1.3rem; }
  .demo { margin-bottom: 1.5rem; }
}
