/* Consolidated responsive behavior for the embedded application. */
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
html body {
  min-width: 0;
  overflow-wrap: anywhere;
}
html body button,
html body input {
  min-width: 0;
  max-width: 100%;
}
html body button {
  min-height: 44px;
  white-space: normal;
  line-height: 1.35;
  touch-action: manipulation;
}
html body button:focus-visible,
html body input:focus-visible {
  outline: 3px solid #9b7600;
  outline-offset: 3px;
}
html body img {
  max-width: 100%;
  height: auto;
}
html body .home,
html body .hero,
html body .layout {
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
}
html body .hero,
html body .side,
html body .content,
html body .quizcontent,
html body .opts {
  min-width: 0;
}
html body .nav {
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}
html body .nav > div {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  min-width: 0;
}
html body .nav button {
  margin: 0;
}
html body .opt {
  width: 100%;
  overflow-wrap: anywhere;
  line-height: 1.45 !important;
}
html body .qimg,
html body .ref {
  width: auto;
  height: auto;
  max-width: 100% !important;
  object-fit: contain;
}
html body .feedback,
html body .fb {
  overflow-wrap: anywhere;
}
@media (max-width: 820px) {
  html body .home,
  html body #home.card.hero {
    grid-template-columns: minmax(0, 1fr) !important;
    min-height: 0 !important;
  }
  html body .hero,
  html body .side,
  html body #home.hero > div:first-child,
  html body #home .yellow {
    padding: 28px 22px !important;
  }
  html body .hero h1,
  html body #home h1 {
    font-size: clamp(32px, 7vw, 52px) !important;
    line-height: 1.08 !important;
  }
}
@media (max-width: 480px) {
  html body .nav > div {
    flex: 1 1 100%;
  }
  html body .nav button {
    flex: 1 1 130px;
  }
  html body .hero,
  html body .side,
  html body #home.hero > div:first-child,
  html body #home .yellow {
    padding: 24px 18px !important;
  }
  html body .opt,
  html body #opts .opt {
    font-size: 16px !important;
    padding: 14px 14px 14px 48px !important;
  }
  html body .opt:before {
    left: 16px !important;
  }
}
@media (prefers-reduced-motion: reduce) {
  html body *,
  html body *:before {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}

html body .wrap {
  width: 100%;
  margin: 24px auto !important;
  padding: 0 14px !important;
}
html body #quiz.card {
  padding: 22px !important;
}
html body .meta {
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}
html body .category-badge {
  max-width: 100%;
  line-height: 1.4;
}
html body .category-badge:before {
  flex-shrink: 0;
}
html body .tap-actions {
  flex-wrap: wrap !important;
}
html body .tap-action {
  max-width: 100%;
  white-space: normal !important;
  min-width: 0 !important;
}
html body .tap-review {
  overflow-x: auto !important;
}
html body .tap-review-table {
  min-width: 560px !important;
}
html body .tap-review-table th:nth-child(1),
html body .tap-review-table td:nth-child(1) {
  width: 42% !important;
}
html body .tap-review-table th:nth-child(2),
html body .tap-review-table td:nth-child(2) {
  width: 18% !important;
}
html body .tap-review-table th:nth-child(3),
html body .tap-review-table td:nth-child(3) {
  display: table-cell !important;
  width: 40% !important;
}
html body #tapUnifiedReviewLauncher .tap-answer-review-btn {
  white-space: normal;
  max-width: 100%;
}
html body .tap-ur-row {
  min-width: 0;
}
html body .tap-ur-question-link {
  min-width: 0;
  overflow-wrap: anywhere;
}
html body #tapBackFinal {
  max-width: 100% !important;
  white-space: normal !important;
}
@media (max-width: 700px) {
  html body #quiz.card {
    padding: 18px 12px !important;
  }
  html body .quizcontent {
    padding: 0 !important;
  }
  html body #qt {
    font-size: 22px !important;
    line-height: 1.35 !important;
  }
  html body .tap-ur-row {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 10px !important;
  }
  html body .tap-ur-status {
    grid-column: auto !important;
    justify-self: start;
  }
  html body .tap-ur-qmeta {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
  }
  html body .tap-ur-question {
    padding: 14px;
  }
  html body .tap-actions .tap-action {
    flex: 1 1 180px !important;
  }
  html body .tap-review-aligned-row {
    flex-wrap: wrap !important;
  }
}
@media (max-width: 480px) {
  html body .wrap {
    margin: 12px auto !important;
    padding: 0 10px !important;
  }
  html body #home p {
    font-size: 16px !important;
  }
  html body .rule {
    padding: 18px !important;
  }
  html body .tap-gauge {
    max-width: 100%;
  }
  html body .tap-actions .tap-action {
    flex-basis: 100% !important;
  }
  html body .tap-review-aligned-row button {
    flex: 1 1 100% !important;
  }
}

@media print {
  html body .reviewDialog {
    max-height: none;
    overflow: visible;
  }
  html body .tap-review {
    overflow: visible !important;
  }
  html body .tap-review-table {
    min-width: 0 !important;
  }
}
