/* Let scores occupy their own row instead of covering question controls. */
/* Perks follow the question, with one compact group per team. */
html body #question #qPerks {
  display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;
  gap:12px!important;padding:15px 0!important;margin:0!important;
  border-top:1px solid var(--ink-4);flex-shrink:0;
}
html body #question #qPerks .qa-perk-panel {
  display:flex!important;align-items:center;gap:12px!important;min-width:0;
  padding:0!important;border:0!important;border-radius:0!important;
  background:none!important;box-shadow:none!important;
}
html body #question #qPerks .qa-perk-name {
  min-width:0!important;max-width:120px;font-size:12px!important;line-height:1.5;
  letter-spacing:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
}
html body #question #qPerks .qa-perk-row {flex:0 1 auto;min-width:0;flex-wrap:wrap!important;gap:6px!important;}
html body #question #qPerks .perk-pip {
  display:inline-flex!important;align-items:center!important;justify-content:center!important;
  width:44px!important;height:44px!important;min-width:44px!important;min-height:44px!important;
  flex:0 0 44px!important;padding:0!important;border-radius:50%!important;
}
html body #question #qPerks .kt-perk-name {
  position:absolute!important;width:1px!important;height:1px!important;padding:0!important;
  margin:-1px!important;overflow:hidden!important;clip-path:inset(50%);white-space:nowrap;
}
html body #question #qPerks .kti {width:26px!important;height:26px!important;}
@media(max-width:700px) {
  html body #question #qPerks {grid-template-columns:1fr!important;gap:10px!important;padding:12px 0!important;}
  html body #question #qPerks .qa-perk-panel {justify-content:space-between;}
}
html body :is(#question,#answer) .qa-stage {
  display:flex;flex-direction:column;gap:12px;
}
html body :is(#question,#answer) .qa-stage > #kt-miniboard {
  position:static!important;transform:none!important;max-width:100%!important;
  width:100%;margin:0;gap:12px!important;flex-shrink:0;z-index:auto;
}
html body :is(#question,#answer) #kt-miniboard .kt-mini-team {
  display:flex;flex-direction:row;align-items:center;justify-content:space-between;gap:12px;
  flex:1;min-width:0!important;width:auto!important;padding:8px 14px!important;
  border-radius:10px!important;
}
html body :is(#question,#answer) #kt-miniboard .kt-mini-name {
  font-size:14px!important;line-height:1.4!important;min-width:0;max-width:80%;
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
}
html body :is(#question,#answer) #kt-miniboard .kt-mini-score {
  font-size:24px!important;line-height:1.1!important;margin:0;flex-shrink:0;
}
@media(min-width:1101px) {
  html body :is(#question,#answer) > .stage-bg {padding-bottom:28px!important;}
  html body :is(#question,#answer) .qa-stage {min-height:calc(100svh - 56px);}
  html body :is(#question,#answer):has(.visual-image) .qa-content {padding-block:16px;}
}
@media(max-width:1100px) and (min-height:601px) {
  html body :is(#question,#answer) > .stage-bg {
    padding:16px max(12px,env(safe-area-inset-right)) max(16px,env(safe-area-inset-bottom)) max(12px,env(safe-area-inset-left))!important;
  }
  html body :is(#question,#answer) .qa-stage {padding:0!important;}
  html body :is(#question,#answer) .qa-card {padding:22px 24px;border-radius:12px;}
}
@media(max-width:600px) and (min-height:601px) {
  html body :is(#question,#answer) .qa-card {padding:18px 14px;}
  html body :is(#question,#answer) .qa-content {padding:22px 0;}
  html body :is(#question,#answer) .qa-topbar {gap:8px;margin-bottom:12px;}
  html body :is(#question,#answer) :is(.qa-actions,.award-buttons) .btn {min-height:44px;}
  html body :is(#question,#answer) .visual-image {max-height:min(28svh,240px);object-fit:contain;}
}
@media(orientation:landscape) and (max-height:600px) {
  html body.handoff :is(#question,#answer) > .stage-bg {padding-bottom:max(6px,env(safe-area-inset-bottom))!important;}
  html body :is(#question,#answer) #kt-miniboard .kt-mini-team {padding:3px 10px!important;}
  html body :is(#question,#answer) #kt-miniboard .kt-mini-name {font-size:12px!important;}
  html body :is(#question,#answer) #kt-miniboard .kt-mini-score {font-size:20px!important;}
}
/* Category density follows available width, including landscape phones. */
@media(min-width:801px) and (max-width:1100px) {
  html.ar-preview body #categorySelect #catPool {grid-template-columns:repeat(3,minmax(0,1fr))!important;}
}
@media(min-width:601px) and (max-width:800px) {
  html.ar-preview body #categorySelect #catPool {grid-template-columns:repeat(3,minmax(0,1fr))!important;}
}
@media(max-width:600px) {
  html.ar-preview body #categorySelect #catPool {grid-template-columns:repeat(2,minmax(0,1fr))!important;}
}
