body.ct-sight-tool { background: #fcfaf6; }
body.ct-sight-tool #top { width: min(68rem, calc(100% - 4rem)); max-width: none; margin-inline: auto; padding-inline: 0; }
body.ct-sight-tool .ct-breadcrumb {
  display: flex; gap: .55rem; align-items: baseline; margin: .95rem 0 0;
  font: .85rem/1.5 system-ui, sans-serif; color: #5d5349;
}
.ct-breadcrumb a { color: #20483e; text-underline-offset: .18em; }
body.ct-sight-tool .discovery-hero { padding-top: .4rem; }
body.ct-sight-tool .discovery-hero h1 {
  color: #20483e;
  font: 650 clamp(1.9rem,4.15vw,3.25rem)/1.18 Georgia,"Songti SC","Noto Serif CJK SC",serif;
  letter-spacing: -.03em;
}
body.ct-sight-tool .discovery-hero .lede { color: #5d5349; max-width: 68ch; }
body.ct-sight-tool.app-loading main { visibility: visible; }
body.ct-sight-tool .ct-loading-panel {
  position: static; inset: auto; place-content: normal; place-items: stretch; z-index: auto; gap: .75rem;
  display: grid; text-align: start; padding: .85rem 0; background: transparent;
  color: #20483e; font: .95rem/1.45 system-ui, sans-serif;
}
body.ct-sight-tool .ct-loading-panel[hidden] { display: none; }
.ct-skeleton { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,13rem),1fr)); gap: .7rem; }
.ct-skeleton span { height: 3rem; border-radius: 5px; background: #e9efea; }
body.ct-sight-tool:is(.app-loading,.ct-boot-failed) .selection-bottom-region,
.ct-sight-tool.ct-boot-failed :is(.ct-skeleton,#discovery-results > .inline-error) { display: none; }
.ct-load-help { margin: 0; padding: .7rem .85rem; border: 1px solid #ded6ca; border-radius: 5px; background: #fcf6e9; }
.ct-load-help a { color: #20483e; text-decoration: underline; }
.ct-load-help button {
  margin-inline-start: .55rem;
  min-height: 44px;
  padding-inline: .65rem;
  border: 1px solid #9bb6a8;
  border-radius: 4px;
  background: #fcfaf6;
  color: #20483e;
  font: inherit;
  cursor: pointer;
}
@media(max-width:65rem) { body.ct-sight-tool #top { width:calc(100% - 3rem); } }
@media(max-width:47rem) { body.ct-sight-tool #top { width:calc(100% - 2rem); } }

body.ct-sight-tool #setup-view.discovery-surface { padding-inline: 0; }

@media (max-width: 700px) {
  /* Russian labels are long enough to collapse the first grid track. Keep both actions tappable. */
  html:lang(ru) body.ct-sight-tool #selected-tray:not(.is-expanded) {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }
  html:lang(ru) body.ct-sight-tool :is(#review-selected,#run-scan) {
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
  }
}
