:root {
  color: #172a36;
  background: #f3f6f8;
  font-family: Helvetica, Arial, sans-serif;
  line-height: 1.5;
}
* { box-sizing: border-box; }
body { margin: 0; }
header { padding: 1rem; text-align: center; }
main { width: min(100% - 2rem, 46rem); margin-inline: auto; }
#channel-logo { max-width: min(320px, 100%); height: auto; vertical-align: middle; }
main { padding-block: 1.5rem 3rem; }
.channel-page { padding-block: 0rem 3rem; }
h1 { font-size: 20px; line-height: 1.2; text-align: center; }
main:not(.legal-page) > h1 { font-size: 25px; }
.channel-intro { margin-top: calc(1em + 15px); font-size: 18px; text-align: justify; margin-bottom: 30px; }
.channel-intro > :first-child { margin-top: 0; }
.channel-intro > :last-child { margin-bottom: 0; }
.info-card { border: 1px solid #b7c9d3; border-radius: .5rem; font-size: 16px; }
.info-tabs:not([hidden]) { display: grid; grid-template-columns: repeat(auto-fit, minmax(7rem, 1fr)); gap: .25rem; padding: .5rem; border-bottom: 1px solid #b7c9d3; }
.info-tabs button { padding: .4rem; color: inherit; background: transparent; font-size: 13px; line-height: 1.25; }
.info-tabs button[aria-selected="true"] { color: #204d66; background: #dce9f0; box-shadow: inset 0 -2px #305e79; }
.info-panel { padding: .75rem clamp(.75rem, 3vw, 1.25rem); }
#info-panel-4 a[href="https://www.proteccioninformante.gob.es/"] { color: navy; }
.info-panel h2 { font-size: 1em; }
.info-panel > :first-child, .info-panel > h2[hidden] + * { margin-top: 0; }
.info-panel > :last-child { margin-bottom: 0; }
details, form { background: white; padding: clamp(1rem, 4vw, 2rem); border: 1px solid #ccd8df; border-radius: .5rem; }
details { margin-bottom: 1rem; }
summary { cursor: pointer; font-weight: bold; }
fieldset { margin: 0 0 1rem; padding: .75rem; border: 1px solid #ccd8df; }
legend, label { display: block; }
input:not([type=radio]):not([type=checkbox]), textarea { display: block; width: 100%; margin: .25rem 0 1rem; padding: .6rem; border: 1px solid #607d8d; border-radius: .25rem; font: inherit; }
textarea { resize: vertical; }
.validation-row { display: grid; grid-template-columns: minmax(0, 1fr) 5.75rem; gap: .5rem; align-items: center; margin: .25rem 0 1rem; }
.validation-row input:not([type=radio]):not([type=checkbox]) { grid-area: 1 / 1; min-width: 0; margin: 0; }
.validation-row button { grid-area: 1 / 2; padding-inline: .5rem; white-space: nowrap; }
.validation-row input[readonly] + button { background: #5b4670; }
.identity-fields:not([hidden]) { display: grid; gap: 0 1rem; }
@media (min-width: 560px) {
  .identity-fields:not([hidden]) { grid-template-columns: minmax(0, 3fr) minmax(13rem, 2fr); }
}
#facts { background-color: #f2a64d24; }
.form-actions:not([hidden]) { display: grid; gap: 1.5rem; margin-top: 1.5rem; }
.submission-row:not([hidden]) { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 1rem; }
.submission-row button:disabled { opacity: .65; cursor: default; }
.report-submitted { background: #2b97ff1a; }
.report-submitted #result { margin: 0; font-size: 1.375rem; font-weight: bold; text-align: center; }
.report-submitted #receipt-download { margin: 1rem 0 0; text-align: center; }
#receipt-download button { background: transparent; color: navy; padding: 0; font-weight: normal; text-decoration: none; }
#receipt-download span { display: block; font-size: 3rem; }
.form-confirmations { display: grid; gap: .5rem; font-size: 16px; }
.form-confirmations label:not([hidden]) { display: flex; align-items: baseline; gap: .35rem; }
#good-faith-step:not([hidden]) { margin-bottom: 1rem; }
label[hidden] { display: none; }
button { padding: .7rem 1rem; font: inherit; font-weight: bold; color: white; background: #305e79; border: 0; border-radius: .25rem; cursor: pointer; }
:focus-visible { outline: 3px solid #3e7799; outline-offset: 3px; }

form legend, label[for="facts"] { font-weight: bold; }
.channel-footer { font-size: 16px; display: flex; flex-wrap: wrap; justify-content: center; gap: .25rem .5rem; margin-top: 1.25rem; text-align: center; }
.legal-page { overflow-wrap: anywhere; }
.legal-page table { width: 100%; border-collapse: collapse; }
.legal-page td { border: 1px solid #ccd8df; padding: .35rem; }

.report-data dt { font-weight: bold; }
.report-data dd { margin: 0 0 .75rem; white-space: pre-wrap; overflow-wrap: anywhere; }

@media (min-width: 641px) {
  .login-form { width: 300px; margin-inline: auto; padding: 1rem; }
}

.login-actions { display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
#reset-status { margin-bottom: 0; }

main:has(> .login-form > .login-actions) > h1 {
  width: min(100%, 300px);
  margin-inline: auto;
  font-size: 20px;
  overflow-wrap: anywhere;
}

.totp-login-form { text-align: center; }
.totp-login-form button { display: block; margin-inline: auto; }
.totp-login-form > p { text-align: center; }

#verification-result:not(:empty) { margin-top: 1rem; }
.verification-history { margin: .35rem 0 0; padding: 0; list-style: none; font-weight: 700; }

.submission-wait-dialog { width:min(36rem,calc(100% - 2rem)); padding:1.5rem; border:1px solid #3e7799; border-radius:.55rem; color:#172a36; }
.submission-wait-dialog h2 { margin-top:0; }
.submission-wait-dialog::backdrop { background:rgb(24 44 57 / .4); }

.report-steps { container-type:inline-size; display:grid; grid-template-columns:repeat(6,minmax(0,1fr)); gap:12px; list-style:none; padding:0; margin:30px 0; }
.report-steps[hidden] { display:none; }
.report-steps li { position:relative; text-align:center; font-size:clamp(.5rem,1.48cqi,.75rem); font-weight:bold; color:#014cbb; white-space:nowrap; }
.report-steps li:not(:last-child)::after { content:"→"; position:absolute; right:-18px; bottom:7px; width:24px; color:#6a8595; font-size:24px; }
.step-number { display:grid; place-items:center; width:38px; height:38px; margin:9px auto 0; border:2px solid #9fb7c5; border-radius:50%; background:white; font-size:1rem; }
.report-steps .step-complete .step-number { background:#dce9ef; border-color:#6a8595; }
.report-steps [aria-current="step"] .step-number { background:#2d5971; color:white; border-color:#2d5971; outline:3px solid #c9dfe9; outline-offset:2px; }
.legal-dialog { width:min(880px,calc(100% - 2rem)); max-height:85vh; overflow:auto; border:1px solid #bdcfd9; border-radius:10px; padding:1.25rem; color:inherit; }
.legal-dialog::backdrop { background:#152a3880; }
.legal-dialog header { display:flex; align-items:center; justify-content:space-between; gap:1rem; }
.legal-dialog header h2 { margin:0; font-size:1.1rem; }
.legal-dialog header button { flex:none; min-width:2.5rem; margin:0; }
.legal-dialog-content { font-size:1rem; line-height:1.5; }
@media (max-width:680px) {
  .report-steps { grid-template-columns:repeat(3,minmax(0,1fr)); row-gap:20px; }
  .report-steps li:nth-child(3)::after { display:none; }
  .report-steps li { font-size:clamp(.55rem,2.25vw,.7rem); }
}
.report-steps li { display:flex; flex-direction:column; align-items:center; }
.step-number { margin-top:auto; }
.report-steps li { row-gap:9px; }


.channel-page { -webkit-user-select:none; user-select:none; }
.channel-page :is(input, textarea) { -webkit-user-select:text; user-select:text; }
