/* Additions to the prototype stylesheet (hcdc.css) for the server-rendered build. Keep this small. */

/* Server-side validation uses ASP.NET's classes; map them onto the prototype's states. */
.field:has(.field-validation-error) .field__error,
.field.is-invalid .field__error { display: flex; }
.field__error:empty, .field__error.field-validation-valid { display: none !important; }
.input.input-validation-error, .select.input-validation-error, .textarea.input-validation-error { border-color: var(--red-700); background: #FFFBFB; }
.blind-warning { display: none; }
.blind-warning.is-visible { display: flex; }

.inline-form { display: inline; margin: 0; }
.govbar__btn { color: inherit; font: inherit; text-decoration: none; }
.govbar__btn:hover { text-decoration: underline; }

/* Abstract sections: six boxes share one live word counter. */
.abstract-sections { display: grid; gap: 18px; }
.abstract-sections .textarea { min-height: 120px; }

/* Admin and review areas */
.app-nav { display: flex; flex-wrap: wrap; gap: 4px; padding: 10px 0; border-bottom: 1px solid var(--line); background: #fff; }
.app-nav a { padding: 8px 12px; border-radius: 8px; font-size: 14.5px; font-weight: 600; color: var(--ink-2); text-decoration: none; }
.app-nav a:hover { background: var(--surface-2); }
.app-nav a[aria-current="page"] { background: var(--navy-100); color: var(--navy-900); }
.app-nav__group { display: flex; gap: 4px; align-items: center; padding-right: 10px; margin-right: 6px; border-right: 1px solid var(--line-2); }
.app-nav__group:last-child { border-right: 0; }
.filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: end; margin-bottom: 18px; }
.filters .field { min-width: 180px; }
.pager { display: flex; gap: 8px; align-items: center; justify-content: flex-end; margin-top: 16px; font-size: 14px; color: var(--subtle); }
.actions-cell { white-space: nowrap; text-align: right; }
.actions-cell form { display: inline; }
.table td .text-subtle { font-size: 13px; }
.settings-group + .settings-group { margin-top: 32px; }
.switch-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line-2); }
.switch-row:last-child { border-bottom: 0; }
.dl-grid { display: grid; grid-template-columns: max-content 1fr; gap: 8px 18px; font-size: 15px; }
.dl-grid dt { color: var(--subtle); }
.dl-grid dd { margin: 0; }
.score-input { width: 84px; }
.qr-box { display: inline-block; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.qr-box img { display: block; width: 180px; height: 180px; }
.scanner video { width: 100%; max-width: 420px; border-radius: 12px; background: #000; }
.check-result { padding: 18px; border-radius: 12px; margin-top: 16px; }
.check-result--ok { background: var(--green-100); color: var(--green-700); }
.check-result--bad { background: var(--red-100); color: var(--red-700); }
.logo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 18px; align-items: center; }
.logo-grid img { max-width: 100%; max-height: 72px; object-fit: contain; margin: 0 auto; display: block; }
.video-frame { position: relative; padding-top: 56.25%; border-radius: 12px; overflow: hidden; background: #000; }
.video-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.programme-day + .programme-day { margin-top: 40px; }
.session-row { display: grid; grid-template-columns: 110px 1fr auto; gap: 18px; padding: 16px 0; border-bottom: 1px solid var(--line-2); }
.halls { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
@media (max-width: 760px) {
  .halls { grid-template-columns: 1fr; }
  .session-row { grid-template-columns: 1fr; gap: 6px; }
}
@media print {
  .govbar, .site-header, .site-footer, .consent, .toasts, .no-print { display: none !important; }
}

/* Without JavaScript every step and every animated block stays visible. */
html:not(.js) .step-panel { display: block; }
html:not(.js) .step-panel + .step-panel { margin-top: 32px; }
html:not(.js) .reveal { opacity: 1; transform: none; }

/* Icons default to the size of the text around them; component rules (.btn svg, .link-card__icon svg ...) still win. */
svg.icon { width: 1.15em; height: 1.15em; flex: none; vertical-align: -0.2em; }

/* Uploaded files use the template's .upload-file row; the template sizes its icon inline, here it is a class. */
.file-list { display: grid; gap: 10px; }
.upload-file { flex-wrap: wrap; }
.upload-file__icon { display: inline-flex; color: var(--navy-700); }
.upload-file__icon svg { width: 18px; height: 18px; }

/* Document preview uses the template's drawer; PDFs sit in the same frame as its email preview. */
.preview-img { display: block; max-width: 100%; margin: 0 auto; border-radius: 12px; border: 1px solid var(--line); }

/* QR images inside the template ticket and badge. */
.ticket__qr img, .badge-card__qr img { width: 100%; height: 100%; display: block; }
