*,
*::before,
*::after { box-sizing: border-box; margin: 0; padding: 0; }

html, body { max-width: 100%; overflow-x: hidden; }

body {
  font-family: Manrope, system-ui, sans-serif;
  background: #EEF3EF;
  color: #1F3D2A;
  min-height: 100dvh;
  line-height: 1.5;
}

a { color: #3D7A58; text-decoration: none; }
button, input { font: inherit; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid #3D7A58; outline-offset: 2px; }

.bar, main, footer {
  width: min(430px, 100%);
  margin: 0 auto;
  padding-left: 16px;
  padding-right: 16px;
}

.bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: calc(14px + env(safe-area-inset-top));
  padding-bottom: 8px;
}

.bar span {
  font-size: 12px;
  font-weight: 800;
  background: #fff;
  padding: 4px 8px;
  border-radius: 10px;
}

h1 {
  margin: 12px 0 6px;
  font-size: 1.7rem;
  letter-spacing: -0.03em;
}

.lead, .note, footer { color: #6B7F72; font-size: 0.92rem; }

.card {
  margin: 16px 0 24px;
  padding: 18px 16px;
  background: #fff;
  border-radius: 18px;
}

.lbl {
  margin: 12px 0 4px;
  font-size: 12px;
  font-weight: 800;
  color: #3D7A58;
}

.lbl:first-child { margin-top: 0; }

.num {
  font-size: clamp(1.5rem, 7vw, 1.9rem);
  font-weight: 800;
  white-space: nowrap;
}

.num.sm { font-size: 1.25rem; }

.row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  margin: 10px 0;
}

.chip {
  min-height: 42px;
  border: 1px solid #D5E3DA;
  background: #EEF3EF;
  border-radius: 12px;
  font-size: 0.72rem;
  font-weight: 800;
  cursor: pointer;
}

.chip.is-on { background: #1F3D2A; border-color: #1F3D2A; color: #fff; }
.chip:disabled { opacity: 0.45; }

input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 28px;
  background: transparent;
}

input[type="range"]::-webkit-slider-runnable-track {
  height: 6px;
  border-radius: 99px;
  background: linear-gradient(90deg, #3D7A58 var(--progress, 14%), #D5E3DA var(--progress, 14%));
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  margin-top: -8px;
  border-radius: 50%;
  background: #1F3D2A;
  border: 3px solid #fff;
}

input[type="range"]::-moz-range-track { height: 6px; background: #D5E3DA; }
input[type="range"]::-moz-range-thumb {
  width: 22px;
  height: 22px;
  border: 3px solid #fff;
  background: #1F3D2A;
  border-radius: 50%;
}

.ends {
  display: flex;
  justify-content: space-between;
  font-size: 0.74rem;
  color: #6B7F72;
}

.note { margin: 14px 0; }

.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 52px;
  border: 0;
  border-radius: 14px;
  background: #1F3D2A;
  color: #fff;
  font-weight: 800;
  cursor: pointer;
}

.btn.ghost {
  margin-top: 8px;
  background: transparent;
  border: 1px solid #D5E3DA;
  color: #1F3D2A;
}

.btn:disabled { opacity: 0.5; }

.wait { text-align: center; padding: 28px 0; font-weight: 800; }

.out { text-align: center; }
.k { font-size: 12px; font-weight: 800; color: #3D7A58; text-transform: uppercase; }
.code {
  margin: 6px 0 10px;
  font-size: 2.6rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  padding-left: 0.16em;
}

.faq-item { margin-bottom: 8px; background: #fff; border-radius: 14px; }
.faq-q {
  width: 100%;
  min-height: 50px;
  padding: 12px 14px;
  border: 0;
  background: transparent;
  text-align: left;
  font-weight: 700;
  cursor: pointer;
}
.faq-a { display: none; padding: 0 14px 12px; color: #6B7F72; font-size: 0.9rem; }
.faq-item.is-open .faq-a { display: block; }

footer {
  padding: 24px 16px calc(32px + env(safe-area-inset-bottom));
  text-align: center;
}

footer nav {
  display: flex;
  justify-content: center;
  gap: 14px;
  margin-top: 10px;
}

.legal { padding-top: 8px; }
.legal h1 { font-size: 1.5rem; }
.paper { margin: 16px 0 32px; padding: 18px 16px; background: #fff; border-radius: 16px; }
.paper h2 { margin: 18px 0 8px; font-size: 1rem; }
.paper p, .paper li { color: #6B7F72; }
.paper ul { padding-left: 18px; margin-top: 8px; }
.back { display: inline-block; margin-bottom: 10px; }
