/* This tool's few additions to the style kit (style-kit/), built from its tokens. */

/* The kit's own AA contrast fix ("If a tool must meet AA, add this after the kit",
   style-kit README, Contrast). This tool is public, so it must. It darkens the
   accent where it carries text, and the muted grey of hints and labels. */
:root { --muted: #676b8a; }                                   /* 5.2 on white, 4.8 on the page */
.btn:not(.btn-quiet):not(.btn-danger), .header-badge { background: #1a7f88; }   /* 4.7 */
.btn:not(.btn-quiet):not(.btn-danger):hover:not(:disabled) { background: #187780; }
.req { color: #1a7f88; }
.tag-info { color: #177078; }                                  /* 5.3 */
.tag-success { color: #2d735c; }                               /* 5.1 */

/* More of the same, from the October 2026 review: the kit's cyan is too faint for
   focus outlines, field edges and ticks (WCAG 1.4.11 asks for 3:1), and for the
   heading's second word (3:1 for large text). */
:focus-visible { outline-color: #1a7f88; }                     /* 4.7 on white, 4.4 on the page */
.input { border-color: #858aa3; }                              /* 3.4 on white, 3.1 on the box */
.input:focus { border-color: #1a7f88; }
.input:focus-visible { outline: 2px solid #1a7f88; outline-offset: 1px; }   /* also shows in Windows High Contrast */
.input::placeholder { color: var(--muted); }                   /* 4.8 on the box */
.check input { accent-color: #1a7f88; }
.hero h1 span { color: #1a7f88; }
.header-logo { color: var(--white); }                          /* the logo's alt text, if the image doesn't load */

/* What the page's script hides stays hidden, whatever the kit sets on the element. */
[hidden] { display: none !important; }

/* Continue while the answers don't let the check go on: greyed out like a disabled
   button, but still reachable by keyboard (js/gate.js sets aria-disabled). */
.btn[aria-disabled="true"] { opacity: .5; cursor: not-allowed; }
.btn[aria-disabled="true"]:hover { transform: none; }
.btn:not(.btn-quiet):not(.btn-danger)[aria-disabled="true"]:hover { background: #1a7f88; }

/* "Step 2 of 4" above the step's title, inside its heading. */
.card-title .step { display: block; }

/* A step sent back with something to correct: the list of problems at the top. */
.error-summary { margin: 0 0 18px; }
.error-summary a { color: inherit; text-decoration: underline; }

/* The result's outcome, as a heading inside its coloured notice. */
.notice-heading { font-size: inherit; font-weight: 700; line-height: inherit; color: inherit; margin: 0; }

/* The anti-spam box on every form: off screen, so people never see it, but still a
   box that bots filling in every box will fill in (display: none would warn them). */
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* "(optional)" after a label. */
.optional { font-weight: 400; color: var(--muted); }

/* Step 4's reminder of the notes about the chosen items. */
.measure-notes { margin: 0 0 16px; }
.measure-notes ul { margin: 0 0 0 18px; padding: 0; }
.measure-notes li + li { margin-top: 6px; }

/* The button at the top right of the header (Help, or Back to the checker on the
   help page): an outlined pill on the blue bar. The translucent whites follow the
   kit's own header (its divider and links). */
.header-button {
  font-size: 12px; font-weight: 700; color: var(--white); text-decoration: none; letter-spacing: .3px;
  padding: 6px 16px; border: 1.5px solid #ffffff73; border-radius: var(--radius-pill); white-space: nowrap;
}
.header-button:hover, .header-button:focus-visible { color: var(--white); background: #ffffff1a; border-color: var(--white); }

/* The "Funded by UK Government" logo in the footer. 40px tall is about 10mm on
   screen, the manual's minimum; the space around it keeps its exclusion zone clear.
   The original artwork, unchanged: never recoloured, stretched or squashed. */
.funded-logo { display: block; height: 40px; width: auto; margin: 8px auto 16px; }

/* The privacy line under "Provided by…": the footer's own small grey text, kept
   to a readable width; the link underlined so it shows as one without colour. */
.footer-privacy { max-width: 70ch; margin: 4px auto 0; line-height: 1.6; }
.footer-privacy a { color: inherit; text-decoration: underline; }

/* Tick boxes and Yes/No answers: at least 40px tall to tap, and the box itself
   never squashed when its label wraps onto two lines. */
.card .check { min-height: 40px; }
.check input { flex: none; }

/* Phones. */
@media (max-width: 820px) {
  .input { font-size: 16px; }                    /* under 16px, iPhones zoom in when a box is tapped */
  .check input { width: 20px; height: 20px; }    /* bigger boxes and buttons to tap */
}
/* Any touch screen, including a phone on its side (wider than 820px). */
@media (pointer: coarse) {
  .input { font-size: 16px; }
}
/* Very narrow screens: the header button may wrap rather than push the page sideways. */
@media (max-width: 400px) {
  .header-button { white-space: normal; text-align: center; }
}

/* Printing a result: no blue header bar or buttons, and the notices keep a border
   when background colours aren't printed. */
@media print {
  .header, .actions { display: none; }
  body, .main { background: #fff; }
  .card { box-shadow: none; border: 1px solid #999; }
  .notice { border: 1px solid #000; }
}
@media (max-width: 640px) {
  .help th, .help td { white-space: normal; }    /* the limits table wraps rather than scrolling sideways */
}

/* The help page. */
.help ul { margin: 0 0 12px 20px; padding: 0; font-size: 14px; }
.help li { margin-bottom: 6px; }
.help p { font-size: 14px; margin-bottom: 12px; }
.help .table-wrap { margin-bottom: 12px; }
.help .installations { columns: 2; column-gap: 24px; font-size: 13px; }
@media (max-width: 640px) { .help .installations { columns: 1; } }

/* One form at a time: wider than a sign-in card, narrower than a table. */
.narrow-md { max-width: 640px; margin-left: auto; margin-right: auto; }

.step { font-size: 12px; font-weight: 600; color: var(--muted); margin-bottom: 6px; }
.hint.lead { margin: -6px 0 18px; }

/* The compliance messages. */
.intro { font-size: 14px; }
.declarations { margin: 12px 0 20px 20px; padding: 0; font-size: 14px; }
.declarations li { margin-bottom: 8px; }

/* Step 3's yellow notes about an item, under the dropdown. */
.measure-note { margin: 16px 0 0; }

/* A Yes/No question. */
.question { border: 0; padding: 0; margin: 0 0 22px; min-width: 0; }
.question legend { font-size: 14px; font-weight: 600; color: var(--dark); padding: 0; margin-bottom: 4px; }
.question .hint { margin: 0 0 8px; }
.choices { display: flex; gap: 24px; margin-top: 4px; }
.question .notice { margin: 10px 0 0; }

/* The MCS question on the start page, with the MCS logo beside it. */
.mcs-question { display: flex; align-items: flex-start; gap: 16px; }
.mcs-question .question { flex: 1; }
.mcs-logo { flex: none; width: auto; height: 64px; }

/* Why a result doesn't qualify, inside its red notice. */
.reasons { margin: 8px 0 0 18px; padding: 0; }
.reasons li { margin-top: 4px; }
.reasons-note { margin-top: 8px; font-size: 12px; }

/* The result's figures, one pair a row. */
.attrs.single { grid-template-columns: max-content 1fr; margin-bottom: 16px; }
