/* Independent tablet/accessibility corrections; original model styling retained. */
[hidden] { display: none !important; }
.ctl { min-width: 52px; min-height: 52px; }
.panel-close { width: 52px; height: 52px; flex: 0 0 52px; }
#games-link { min-height: 50px; font-size: 15px; }
.sc-stats, .sc-note, .sc-tag, .statrow .sl, .statrow .delta, .act small { font-size: 14px; }
.statrow { font-size: 15px; }
.statrow { grid-template-columns: 110px minmax(0,1fr) auto; }
.statrow .sl { font-size: 15px; letter-spacing: 0; text-transform: none; }
.help-cols p, .help-cols li, .ht-desc { font-size: 15px; }
.overlay-card { max-height: 680px; overflow-y: auto; overscroll-behavior: contain; }

#panel {
  box-sizing: border-box;
  width: 420px;
  max-height: 646px;
  padding: 8px;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: #10261ef5;
}
#panel .panel-head {
  min-height: 52px;
  margin: 0;
  gap: 8px;
}
#panel .panel-title { min-width: 0; line-height: 20px; }
#panel .panel-title small { display: block; font-size: 14px; line-height: 17px; }
#panel .panel-sub {
  margin: 2px 0 6px;
  font-size: 14px;
  line-height: 20px;
}

.shop-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
  margin: 0;
}
.shop-card {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 2px;
  min-width: 0;
  min-height: 0;
  padding: 5px;
  overflow: visible;
  cursor: default;
}
.shop-card .sc-name {
  display: block;
  min-width: 0;
  font-size: 17px;
  line-height: 20px;
  white-space: normal;
}
.shop-card .sc-tag {
  min-width: 0;
  font-size: 14px;
  line-height: 17px;
  text-transform: none;
  white-space: normal;
}
.shop-card .sc-stats {
  min-width: 0;
  font-size: 14px;
  line-height: 17px;
  white-space: normal;
}
.shop-card details { display: none; }
.shop-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 52px;
  gap: 6px;
  width: 100%;
  margin-top: 2px;
}
.shop-actions button {
  min-width: 0;
  min-height: 52px;
  padding: 5px 6px;
  font: 600 15px/18px var(--sans);
  border: 1px solid #967b42;
  border-radius: 8px;
  cursor: pointer;
  white-space: normal;
}
.build-choice { color: #09160e; background: #dcb66b; }
.build-choice:disabled { opacity: .4; cursor: not-allowed; }
.preview-btn { width: 52px; background: #193c2e; color: #c1f4e1; }

.shop-note {
  margin-top: 6px;
  font-size: 14px;
  line-height: 19px;
}
.shop-note summary {
  min-height: 36px;
  display: flex;
  align-items: center;
  color: #ace3ca;
  cursor: pointer;
}
.shop-note-body { display: grid; gap: 4px; padding: 3px 0 8px; }
.shop-note-body p { margin: 0; white-space: normal; }

#panel .tower-head, #panel .statrows { min-width: 0; }
#panel .statrow {
  min-width: 0;
  min-height: 38px;
  gap: 7px;
  align-items: center;
}
#panel .statrow > * { min-width: 0; white-space: normal; }
#panel .panel-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 8px;
}
#panel .panel-actions button {
  min-width: 0;
  min-height: 52px;
  padding: 6px 8px;
  font: 600 15px/18px var(--sans);
  white-space: normal;
}
button:focus-visible, a:focus-visible { outline: 3px solid #60eccb; outline-offset: 3px; }
@media(prefers-reduced-motion:reduce) { *, *::before, *::after { animation:none!important; transition:none!important; } }
