:root {
  color-scheme: light;
  --ink: #17231f;
  --muted: #60706a;
  --line: #d8e1dd;
  --field: #f8faf9;
  --brand: #0b3b32;
  --blue: #0a57c9;
  --blue-dark: #073f9a;
  --accent: #b9882d;
  --ok: #0f6f4c;
  --error: #a62e2e;
  font-family: Arial, Helvetica, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background: white;
}

.shell {
  width: min(820px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0;
}

.panel {
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 20px 55px rgba(21, 35, 55, 0.14);
}

.form-panel {
  position: relative;
  padding: 30px;
  overflow: hidden;
}

.top-banner {
  display: block;
  width: calc(100% + 60px);
  max-width: none;
  margin: -30px -30px 24px;
  aspect-ratio: 1776 / 919;
  object-fit: cover;
}

.brand {
  color: var(--brand);
  font-weight: 800;
  letter-spacing: 0;
  margin-bottom: 10px;
}

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

h1 {
  font-size: 32px;
  margin-bottom: 14px;
}

h2 {
  font-size: 20px;
}

h3 {
  font-size: 16px;
}

form {
  display: grid;
  gap: 18px;
}

.intro {
  margin: 0 0 22px;
  color: var(--ink);
  font-size: 17px;
  line-height: 1.55;
}

.intro strong {
  display: block;
  margin-top: 6px;
  color: var(--blue-dark);
}

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

label,
fieldset {
  display: grid;
  gap: 7px;
}

label span,
legend {
  font-weight: 700;
}

small {
  color: var(--muted);
}

input,
textarea {
  width: 100%;
  border: 1px solid #bdcac4;
  border-radius: 6px;
  background: var(--field);
  color: var(--ink);
  font: inherit;
  padding: 11px 12px;
}

input:focus,
textarea:focus {
  outline: 3px solid rgba(11, 59, 50, 0.15);
  border-color: var(--brand);
}

fieldset {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
}

.fieldset-text {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

.choice {
  grid-template-columns: 20px 1fr;
  align-items: start;
  font-weight: 400;
}

.choice input {
  width: auto;
  margin-top: 2px;
}

.section-head,
.participant-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.participants {
  display: grid;
  gap: 12px;
}

#participant-list {
  display: grid;
  gap: 12px;
}

.participant-card,
.request-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  display: grid;
  gap: 14px;
  background: #fbfcfb;
}

.primary,
.secondary,
.icon-button {
  border: 0;
  border-radius: 6px;
  cursor: pointer;
  font: inherit;
  text-decoration: none;
}

.primary {
  background: var(--blue);
  color: white;
  padding: 13px 18px;
  font-weight: 800;
}

.primary:hover {
  background: var(--blue-dark);
}

.secondary {
  background: #edf3ef;
  color: var(--brand);
  padding: 10px 12px;
  font-weight: 700;
}

.secondary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.icon-button {
  width: 32px;
  height: 32px;
  background: #f0e5e5;
  color: var(--error);
  font-size: 24px;
  line-height: 1;
}

.message {
  color: var(--muted);
}

.message.success {
  position: absolute;
  inset: 0;
  z-index: 10;
  display: grid;
  align-items: center;
  padding: 24px;
  background: rgba(255, 255, 255, 0.88);
  color: var(--blue-dark);
}

.message-card {
  display: grid;
  grid-template-columns: 170px 1fr;
  align-items: center;
  gap: 20px;
  width: min(650px, 100%);
  margin: 0 auto;
  padding: 20px;
  border: 1px solid #bfd3ff;
  border-radius: 8px;
  background: #edf4ff;
  box-shadow: 0 18px 50px rgba(10, 87, 201, 0.18);
}

.message-card img {
  display: block;
  width: 100%;
  border-radius: 6px;
}

.message-card p {
  margin: 0;
  line-height: 1.45;
}

.message-title {
  font-size: 19px;
  font-weight: 800;
}

.message-card p + p {
  margin-top: 10px;
}

.message-card a {
  color: var(--blue-dark);
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.message.error {
  color: var(--error);
  font-weight: 700;
}

[hidden] {
  display: none !important;
}

@media (max-width: 640px) {
  .shell {
    width: min(100% - 20px, 1180px);
    padding: 10px 0;
  }

  .form-panel {
    padding: 18px;
  }

  .top-banner {
    width: calc(100% + 36px);
    margin: -18px -18px 18px;
  }

  .grid.two {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: 25px;
  }

  .section-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .message-card {
    grid-template-columns: 1fr;
  }

  .message-card img {
    max-height: 160px;
    object-fit: cover;
  }
}
