.quiz-main [hidden] { display: none !important; }

.quiz-panel { min-width: 0; }
.quiz-panel p { max-width: 72ch; }
.quiz-panel h2:focus,
.quiz-panel legend:focus { outline-offset: .25rem; }
.quiz-form label { font-weight: 700; color: #152c56; }

.quiz-name {
  display: block;
  width: min(100%, 27rem);
  min-height: 44px;
  margin: .4rem 0 .55rem;
  padding: .6rem .7rem;
  border: 1px solid #adc3dc;
  border-radius: 9px;
  background: #fff;
  color: #112557;
  font: inherit;
}

.quiz-form fieldset {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.quiz-form legend {
  margin-bottom: 1rem;
  font: 800 clamp(1.35rem, 3vw, 2rem)/1.2 'Roboto Condensed', Arial, sans-serif;
  color: #112557;
}

.quiz-progress {
  color: #17457f;
  font-weight: 800;
  margin: 0 0 .6rem;
}

.quiz-choices {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .7rem;
}

.quiz-option {
  display: flex;
  gap: .65rem;
  align-items: center;
  min-height: 46px;
  padding: .7rem .8rem;
  border: 1px solid #cad9ee;
  border-radius: 10px;
  overflow-wrap: anywhere;
  cursor: pointer;
}

.quiz-option:has(:checked) {
  background: #edf4ff;
  border-color: #2166b6;
}

.quiz-option input {
  flex: none;
  width: 1.1rem;
  height: 1.1rem;
  margin: 0;
  accent-color: #143e79;
}

.quiz-actions {
  display: flex;
  flex-wrap: wrap;
  gap: .55rem;
  margin-top: 1rem;
}

.quiz-panel button {
  min-height: 44px;
  padding: .55rem .9rem;
  border: 1px solid #a9bedc;
  border-radius: 9px;
  background: white;
  color: #143e79;
  cursor: pointer;
  font: 700 .95rem/1.2 Arial, sans-serif;
}
.quiz-panel .quiz-primary { background: #143e79; border-color: #143e79; color: white; }
.quiz-panel .quiz-primary:hover { background: #102f60; }
.quiz-panel button:disabled { background: #e8edf5; color: #4c6380; cursor: default; }
.quiz-panel :focus-visible { outline: 3px solid #286aca; outline-offset: 3px; }
.quiz-status:empty { display: none; }
.quiz-status { margin: .7rem 0 0; color: #17457f; font-weight: 700; }

.quiz-score-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.quiz-score-list li {
  display: grid;
  grid-template-columns: 2rem minmax(0, 1fr) auto;
  align-items: center;
  gap: .7rem;
  padding: .55rem 0;
  border-top: 1px solid #e3ebf4;
  color: #112557;
}

.quiz-score-rank {
  display: grid;
  width: 2rem;
  height: 2rem;
  place-items: center;
  border-radius: 50%;
  background: #e8f1ff;
  color: #143e79;
  font-weight: 800;
}
.quiz-score-list li:first-child .quiz-score-rank { background: #143e79; color: white; }
.quiz-score-name { overflow-wrap: anywhere; }
.quiz-score-points { color: #17457f; font-weight: 800; font-variant-numeric: tabular-nums; }
@media (max-width: 620px) {
  .quiz-choices { grid-template-columns: minmax(0, 1fr); }
}
