/* 01. Brand colours and base styles */
:root {
  color-scheme: light;
  --ink: #132c44;
  --muted: #5b7184;
  --line: #dce5eb;
  --green: #137965;
  --blue: #2158c5;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: #f6f8fa;
  color: var(--ink);
  font:
    16px/1.6 system-ui,
    -apple-system,
    Segoe UI,
    sans-serif;
}
a {
  color: inherit;
}
button,
input,
textarea {
  font: inherit;
}
button,
a,
input,
textarea {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: not-allowed;
  opacity: 0.6;
}
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 3px solid #478ada;
  outline-offset: 4px;
}
[hidden] {
  display: none !important;
}
/* 02. Header and navigation */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 22px max(24px, calc((100% - 1240px) / 2));
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.brand {
  display: flex;
  gap: 12px;
  align-items: center;
  text-decoration: none;
  font-size: 23px;
  font-weight: 750;
}
.brand img {
  object-fit: contain;
}
.brand small {
  display: block;
  font-size: 9px;
  letter-spacing: 0.16em;
  color: var(--muted);
}
.back-link {
  text-decoration: none;
  font-size: 13px;
  font-weight: 650;
}
.back-link span {
  margin-left: 8px;
}
/* 03. Introduction and layout */
main {
  max-width: 1240px;
  margin: auto;
  padding: 60px 24px;
}
.intro {
  max-width: 830px;
  margin-bottom: 48px;
}
.eyebrow {
  font-size: 11px;
  letter-spacing: 0.13em;
  font-weight: 750;
  color: var(--green);
}
.eyebrow > span {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
  margin-right: 7px;
}
h1 {
  font-size: clamp(38px, 4.4vw, 62px);
  line-height: 1.08;
  letter-spacing: -0.045em;
  margin: 20px 0;
}
h2,
h3 {
  line-height: 1.25;
}
h2 {
  letter-spacing: -0.025em;
}
.intro > p {
  font-size: 18px;
  max-width: 650px;
  color: var(--muted);
}
.principles {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  margin-top: 24px;
  font-size: 12px;
  color: var(--green);
  font-weight: 650;
}
.principles span:before {
  content: "✓";
  margin-right: 7px;
}
.layout {
  display: grid;
  grid-template-columns: minmax(240px, 0.8fr) minmax(0, 1.45fr);
  gap: 52px;
  align-items: start;
}
/* 04. Review category panel */
.context {
  padding: 18px 0;
}
.context h2 {
  font-size: 28px;
  max-width: 320px;
}
.categories {
  list-style: none;
  padding: 12px 0;
  margin: 0;
}
.categories li {
  display: flex;
  gap: 18px;
  padding: 20px 16px;
  border-bottom: 1px solid var(--line);
  border-left: 3px solid transparent;
}
.categories li.active {
  background: #eaf4f0;
  border-left-color: var(--green);
  border-radius: 0 9px 9px 0;
}
.categories li > span {
  font-size: 12px;
  color: var(--green);
  font-weight: 750;
  margin-top: 3px;
}
.categories strong {
  font-size: 15px;
}
.categories p {
  margin: 4px 0 0;
  font-size: 13px;
  color: var(--muted);
}
.privacy-note {
  padding: 22px 16px;
  margin-top: 20px;
}
.privacy-note h3 {
  font-size: 15px;
}
.privacy-note p {
  font-size: 13px;
  color: var(--muted);
}
/* 05. Survey card and invitation status */
.survey-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 34px;
  box-shadow: 0 14px 40px #132c4408;
  border-top: 4px solid var(--green);
}
.card-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.pill {
  font-size: 11px;
  font-weight: 700;
  background: #eaf4f0;
  color: var(--green);
  border: 1px solid #c6e3d8;
  border-radius: 99px;
  padding: 5px 12px;
}
.duration {
  font-size: 12px;
  color: var(--muted);
}
.survey-card h2 {
  font-size: 30px;
  margin: 22px 0 8px;
}
.muted {
  color: var(--muted);
  font-size: 14px;
  margin-top: 0;
}
#status {
  font-size: 14px;
  line-height: 1.55;
  padding: 14px 16px;
  border: 1px solid #d8e6f2;
  background: #f4f8fc;
  border-radius: 9px;
  margin: 20px 0;
}
/* 06. Rating controls */
fieldset {
  border: 0;
  padding: 0;
  margin: 26px 0;
}
legend {
  font-size: 18px;
  font-weight: 650;
  margin-bottom: 16px;
}
.ratings {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 9px;
}
.ratings label {
  position: relative;
  cursor: pointer;
}
.ratings input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}
.ratings span {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  border: 1px solid #cddbe4;
  border-radius: 11px;
  padding: 14px 3px;
  background: #fff;
}
.ratings b {
  font-size: 25px;
  font-weight: 650;
}
.ratings input:checked + span {
  background: #e9f5ef;
  color: #12604f;
  border-color: var(--green);
  box-shadow: inset 0 0 0 1px var(--green);
}
.ratings input:focus-visible + span {
  outline: 3px solid #478ada;
  outline-offset: 3px;
}
.check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  cursor: pointer;
}
.check input {
  flex-shrink: 0;
  margin: 4px 0 0;
  accent-color: var(--green);
  width: 16px;
  height: 16px;
}
.not-used {
  margin-top: 18px;
  color: var(--muted);
}
/* 07. Comment field and sharing consent */
.field-label {
  display: block;
  font-size: 14px;
  font-weight: 650;
  margin-bottom: 10px;
}
.field-label > span {
  font-weight: 400;
  color: var(--muted);
  font-size: 12px;
}
textarea {
  width: 100%;
  padding: 14px;
  border: 1px solid #cddbe4;
  border-radius: 10px;
  resize: vertical;
  min-height: 120px;
  font-size: 14px;
  line-height: 1.6;
}
textarea::placeholder {
  color: #718293;
}
.character-count {
  text-align: right;
  font-size: 11px;
  color: var(--muted);
  margin: 4px 0 18px;
}
.consent {
  background: #f6f9fa;
  border: 1px solid #e6ecef;
  border-radius: 12px;
  padding: 20px;
  margin: 24px 0;
}
.consent h3 {
  font-size: 14px;
  margin: 0 0 16px;
}
.consent label {
  margin: 14px 0;
}
.consent p,
.fine-print {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.7;
}
.consent p {
  margin: 16px 0 0;
}
/* 08. Buttons */
.primary,
.secondary {
  border: 0;
  border-radius: 9px;
  padding: 14px 20px;
  font-size: 14px;
  font-weight: 650;
}
.primary {
  background: var(--green);
  color: white;
  width: 100%;
  display: flex;
  justify-content: space-between;
}
.secondary {
  background: #edf3f8;
  color: var(--ink);
  border: 1px solid #d6e1e9;
}
.fine-print {
  margin-bottom: 0;
}
/* 09. Explanation and footer */
.how {
  border-top: 1px solid var(--line);
  margin-top: 64px;
  padding-top: 28px;
}
.how h2 {
  font-size: 23px;
}
.how > div {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin-top: 28px;
}
.how b {
  font-size: 14px;
}
.how p {
  font-size: 13px;
  color: var(--muted);
}
footer {
  background: #102740;
  color: #c7d4df;
  padding: 30px max(24px, calc((100% - 1192px) / 2));
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px 32px;
  font-size: 12px;
}
footer img {
  object-fit: contain;
  display: block;
}
footer p {
  flex: 1;
}
footer nav {
  display: flex;
  gap: 20px;
}
footer a {
  text-decoration: none;
}
/* 10. Tablet layout */
@media (max-width: 850px) {
  .layout {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .context {
    order: 2;
  }
  .context h2 {
    max-width: none;
  }
  .categories {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
  .intro {
    margin-bottom: 30px;
  }
  main {
    padding-top: 38px;
  }
  .how > div {
    gap: 16px;
  }
  .privacy-note {
    padding-left: 0;
  }
}
/* 11. Mobile layout */
@media (max-width: 520px) {
  .site-header {
    padding: 16px;
  }
  .brand {
    font-size: 20px;
  }
  .brand img {
    width: 40px;
    height: 40px;
  }
  .back-link {
    font-size: 11px;
  }
  main {
    padding: 30px 16px;
  }
  .survey-card {
    padding: 22px 18px;
    border-radius: 14px;
  }
  .ratings {
    gap: 5px;
  }
  .ratings span {
    font-size: 10px;
  }
  .categories,
  .how > div {
    grid-template-columns: 1fr;
  }
  .how {
    margin-top: 34px;
  }
  .survey-card h2 {
    font-size: 26px;
  }
  .principles {
    gap: 10px 14px;
  }
  footer {
    padding: 24px 16px;
  }
  footer p {
    flex-basis: 60%;
  }
}

.public-reviews {
  margin: 64px 0;
  padding: clamp(20px, 4vw, 42px);
  background: #fff;
  border: 1px solid #d4e3e5;
  border-radius: 22px;
}
.public-reviews-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  flex-wrap: wrap;
}
.public-reviews h2 {
  font-size: clamp(26px, 3vw, 38px);
  line-height: 1.2;
  margin: 8px 0;
}
.public-category-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 24px 0;
}
.public-category {
  display: grid;
  gap: 12px;
  text-align: left;
  border: 1px solid #c4d9df;
  background: #f6fafb;
  color: #193e4c;
  padding: 20px;
  border-radius: 14px;
  cursor: pointer;
}
.public-category.active {
  border: 2px solid #147c7b;
  background: #eefaf6;
}
.public-category strong {
  font-size: 24px;
}
.public-review-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.public-review {
  min-width: 0;
  padding: 24px;
  border: 1px solid #d9e3e8;
  border-radius: 14px;
}
.public-review header {
  display: flex;
  gap: 16px;
  justify-content: space-between;
}
.public-review p {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
#preview-category {
  max-width: 100%;
  padding: 10px;
  margin: 10px 12px 12px 0;
  background: #fff;
  color: #193e4c;
  border: 1px solid #beced5;
  border-radius: 8px;
}
#survey-retry {
  margin: 12px 0;
}
[hidden] {
  display: none !important;
}
@media (max-width: 800px) {
  .public-category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 520px) {
  .public-review-list,
  .public-category-grid {
    grid-template-columns: 1fr;
  }
}
