@font-face { font-family: 'DM Sans'; font-style: normal; font-weight: 100 900; font-display: swap; src: url('../assets/dm-sans.woff2') format('woff2'); }
@font-face { font-family: 'DM Serif Display'; font-style: normal; font-weight: 400; font-display: swap; src: url('../assets/dm-serif.woff2') format('woff2'); }
@font-face { font-family: 'DM Serif Display'; font-style: italic; font-weight: 400; font-display: swap; src: url('../assets/dm-serif-italic.woff2') format('woff2'); }

:root {
  --forest: #214c43;
  --forest-deep: #173c34;
  --ink: #243f38;
  --muted: #69766f;
  --cream: #f6f7f1;
  --pale: #edf1e7;
  --line: #dde3d9;
  --danger: #a3322b;
  --serif: 'DM Serif Display', Georgia, serif;
  --sans: 'DM Sans', 'Segoe UI', sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ink);
  background: #fff;
  line-height: 1.55;
}

.top { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .8rem 1.25rem; border-bottom: 1px solid var(--line); background: var(--cream); }
.brand { display: flex; align-items: center; gap: .75rem; color: var(--forest-deep); text-decoration: none; line-height: 1.2; }
.brand img { display: block; }
.brand strong { display: block; font-size: .95rem; }
.brand small { color: var(--muted); font-size: .8rem; }
.back { color: var(--forest); text-decoration: none; font-weight: 500; white-space: nowrap; }
.back:hover { text-decoration: underline; }

.wrap { max-width: 760px; margin: 0 auto; padding: 2rem 1.25rem 4rem; }
h1 { font-family: var(--serif); font-weight: 400; font-size: clamp(2rem, 5vw, 2.6rem); margin: 0 0 .35rem; color: var(--forest-deep); }
h2 { font-family: var(--serif); font-weight: 400; color: var(--forest-deep); }
.lead { margin: 0 0 1.75rem; color: var(--muted); }

fieldset { border: 1px solid var(--line); border-radius: 8px; padding: 1.25rem; margin: 0 0 1.25rem; }
legend { font-weight: 700; padding: 0 .4rem; color: var(--forest); }

.grid { display: grid; gap: 1rem; grid-template-columns: repeat(3, 1fr); margin-bottom: 1rem; }
.grid.two { grid-template-columns: repeat(2, 1fr); }

label { display: flex; flex-direction: column; gap: .3rem; font-size: .92rem; font-weight: 500; }
.opt { color: var(--muted); font-weight: 400; }
.field-title { display: block; font-size: .92rem; font-weight: 500; margin-bottom: .45rem; }

select, input:not([type=checkbox]) {
  font: inherit;
  padding: .6rem .7rem;
  border: 1px solid #c9d2c6;
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  width: 100%;
}
select:focus, input:focus { outline: 2px solid var(--forest); outline-offset: 1px; }
select:disabled { background: var(--pale); color: var(--muted); }

.slots { display: flex; flex-wrap: wrap; gap: .5rem; }
.slot input { position: absolute; opacity: 0; pointer-events: none; }
.slot span {
  display: inline-block;
  min-width: 4.4rem;
  text-align: center;
  padding: .5rem .75rem;
  border: 1px solid #c9d2c6;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 500;
}
.slot input:checked + span { background: var(--forest); border-color: var(--forest); color: #fff; }
.slot input:focus-visible + span { outline: 2px solid var(--forest); outline-offset: 2px; }

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

.consent { flex-direction: row; align-items: flex-start; gap: .6rem; margin-top: 1rem; font-weight: 400; font-size: .88rem; color: var(--muted); }
.consent input { width: auto; margin-top: .25rem; }

.trap { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

.notice { background: var(--pale); border: 1px solid var(--line); border-radius: 8px; padding: 1rem 1.25rem; }
.error { color: var(--danger); font-weight: 500; margin: 0 0 1rem; }

.primary {
  display: inline-block;
  background: var(--forest);
  color: #fff;
  border: 0;
  border-radius: 6px;
  padding: .8rem 1.6rem;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
}
.primary:hover:not(:disabled) { background: var(--forest-deep); }
.primary:disabled { opacity: .5; cursor: not-allowed; }

.done { border: 1px solid var(--line); border-radius: 8px; padding: 1.5rem; background: var(--cream); }

@media (max-width: 680px) {
  .grid, .grid.two { grid-template-columns: 1fr; }
}

.again { margin-left: 1rem; color: var(--forest); font-weight: 500; }
.slot-status { color: var(--danger); }
@media (max-width: 480px) { .brand small { display: none; } .again { display: block; margin: 1rem 0 0; } }
