/* app.css — layout for the campaign workspace, on top of the shared tokens
   in torrens.css. No colours are invented here (§12): everything inherits
   the canonical variables. */

.campaign-bar .bar-row {
  display: flex;
  flex-wrap: wrap;
  gap: .6rem;
  align-items: center;
}

.campaign-bar select,
.campaign-bar button,
.import-label {
  font: inherit;
}

.import-label {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
}

.candidate-form {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
  gap: .8rem 1rem;
  align-items: end;
  margin-top: 1.2rem;
}

.candidate-form button[type="submit"] {
  justify-self: start;
}

.assumption-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
  gap: .8rem 1rem;
}

.app-footer {
  margin-top: 2.5rem;
}

/* ---- Plain print/save (CBD-08). On screen the report container does not
   exist visually; in print it is the ONLY thing that renders, on a white
   page (the screen theme is dark-only; printing dark panels is hostile).
   The figures are the same computed values the screen shows. */
.print-only { display: none; }

@media print {
  main > :not(#print-report) { display: none !important; }
  #print-report { display: block; }
  body {
    background: #ffffff;
    color: #000000;
  }
  #print-report h1, #print-report h2 { color: #000000; }
  #print-report .hint { color: #333333; }
  #print-report table {
    width: 100%;
    border-collapse: collapse;
    margin: 0.8rem 0;
  }
  #print-report th, #print-report td {
    border: 1px solid #999999;
    padding: 0.25rem 0.45rem;
    color: #000000;
    text-align: left;
  }
  #print-report td.num { text-align: right; }
  #print-report .pro-candidate {
    break-inside: avoid;
    page-break-inside: avoid;
    margin-top: 1.2rem;
  }
  #print-report .pro-candidate h2 {
    border-top: 1px solid #999999;
    padding-top: 0.8rem;
  }
}

/* Every pointer target in the app meets the WCAG 2.2 24×24 minimum
   (a11y: target-size) — buttons, selects, and the import file input. */
main button,
main select,
main input[type="file"] {
  min-height: 24px;
  min-width: 24px;
}

#candidate-table .reset-button {
  padding: .25rem .55rem;
  margin-right: .35rem;
}
