html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}

.form-shell { max-width: 960px; margin: 0 auto; padding: 2rem 1rem; }
.registration-shell { max-width: 1140px; }
input, select, textarea, button { font: inherit; }
.registration-shell,
.registration-shell *,
.registration-shell *::before,
.registration-shell *::after { box-sizing: border-box; }
.registration-shell input,
.registration-shell select,
.registration-shell textarea { width: 100%; min-width: 0; border: 1px solid #9b9b9b; border-radius: 4px; padding: .6rem .7rem; background: #fff; color: #171717; }
.registration-shell input:focus,
.registration-shell select:focus,
.registration-shell textarea:focus { border-color: #171717; outline: 3px solid rgb(189 30 45 / 22%); outline-offset: 1px; }
.registration-shell label { display: grid; min-width: 0; gap: .35rem; margin: 0; font-weight: 650; overflow-wrap: anywhere; }
.registration-shell small { color: #555; font-weight: 400; line-height: 1.35; }
.registration-title-row { display: flex; align-items: start; justify-content: space-between; gap: 1.5rem; padding-bottom: 1.25rem; border-bottom: 1px solid #252525; }
.registration-title-row h1 { margin: 0; font-size: 2rem; letter-spacing: 0; }
.registration-title-row img { width: 5.5rem; height: 4.5rem; object-fit: contain; }
.registration-kicker { margin: 0 0 .35rem; color: #971321; font-size: .78rem; font-weight: 700; text-transform: uppercase; }
.required-hint { margin: .5rem 0 0; color: #555; }
.required-marker { color: #971321; }
.field-label { display: inline-flex; width: fit-content; align-items: baseline; gap: .2rem; }
.wizard-progress { margin-block: 1.5rem 2rem; }
.wizard-progress ol { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); margin: 0; padding: 0; list-style: none; }
.wizard-progress li { position: relative; min-width: 0; padding: .65rem .45rem .75rem; border-bottom: 3px solid #c8c8c8; color: #555; text-align: center; }
.wizard-progress li[aria-current="step"] { border-color: #bd1e2d; color: #171717; font-weight: 700; }
.wizard-progress span { display: block; overflow-wrap: anywhere; }
.wizard-step { margin: 0; padding: 0; border: 0; background: transparent; }
.wizard-step h2 { margin: 0 0 1.25rem; font-size: 1.45rem; }
.field-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem 1.25rem; }
.field-wide { grid-column: 1 / -1; }
.section-heading,
.entry-heading { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.section-heading { margin-bottom: 1rem; }
.section-heading h2,
.entry-heading h3 { margin: 0; }
.entry-list { display: grid; gap: 1rem; }
.entry { min-width: 0; padding: 1rem; border: 1px solid #d0d0d0; border-radius: 6px; background: #fff; }
.entry-heading { padding-bottom: .8rem; border-bottom: 1px solid #e3e3e3; }
.entry-heading h3 { font-size: 1.05rem; }
.participant-fields,
.team-fields { margin-top: 1rem; }
.participant-fields { display: grid; gap: 1rem; }
.participant-name-row,
.participant-identity-row,
.participant-competition-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem 1.25rem; min-width: 0; }
.participant-identity-row { grid-template-columns: minmax(15rem, .8fr) minmax(0, 1.35fr); align-items: stretch; }
.participant-competition-row { align-items: stretch; }
.participant-competition-row.bogu-hidden { grid-template-columns: minmax(0, 1fr); }
.id-card-field,
.rank-exam-card,
.bogu-field { min-width: 0; }
.rank-exam-card { display: grid; align-content: start; gap: .75rem; }
.age-category-row { display: grid; align-items: end; gap: .75rem; }
.age-source-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .35rem .75rem; }
.age-source-field { padding: .5rem; border-left: 3px solid transparent; border-radius: 3px; transition: background-color .15s ease, opacity .15s ease; }
.age-source-field.age-source-active { border-left-color: #bd1e2d; background: #fff7f7; }
.age-source-field.age-source-inactive { border-left-color: #aaa; background: #ededed; color: #666; cursor: pointer; }
.age-source-inactive input[readonly] { background: #dedede; color: #666; cursor: pointer; }
.age-source-status { font-weight: 650 !important; }
.age-source-active .age-source-status { color: #971321; }
.age-source-inactive .age-source-status { color: #555; }
.age-source-hint { grid-column: 1 / -1; color: #555; }
.calculated-category-row { display: grid; gap: .35rem; margin: 0; padding: .6rem .7rem; border-left: 3px solid #bd1e2d; background: #f4f4f4; }
.calculated-category-row span { color: #555; font-size: .78rem; }
.team-type-fieldset { display: flex; min-width: 0; align-items: center; gap: 1rem; margin: 0; padding: .65rem .75rem; border: 1px solid #b8b8b8; border-radius: 4px; }
.team-type-fieldset legend { width: auto; margin: 0 .5rem 0 0; padding: 0; float: left; font-size: 1rem; font-weight: 650; }
.team-type-fieldset label { display: flex; align-items: center; gap: .4rem; white-space: nowrap; }
.team-type-fieldset input,
.without-bogu-row input { width: 1.1rem; height: 1.1rem; flex: 0 0 1.1rem; margin: 0; }
.without-bogu-row { display: flex !important; align-items: center; align-self: center; gap: .6rem !important; min-height: 2.75rem; padding: .6rem .75rem; border-left: 3px solid #bd1e2d; background: #f4f4f4; }
.kyu-exam-row { display: flex !important; align-items: center; gap: .6rem !important; min-height: 2.75rem; padding: .6rem .75rem; border-left: 3px solid #bd1e2d; background: #f4f4f4; }
.kyu-exam-row[hidden] { display: none !important; }
.kyu-exam-row input { width: 1.1rem; height: 1.1rem; flex: 0 0 1.1rem; margin: 0; }
.without-bogu-only { align-self: center; margin: 0; padding: .7rem .75rem; border-left: 3px solid #bd1e2d; background: #f4f4f4; font-weight: 650; }
.bogu-category-options { display: grid; min-width: 0; }
.bogu-category-options:empty { display: none; }
.participant-notes { width: 100%; }
.confirmation-dialog { width: min(32rem, calc(100% - 2rem)); padding: 0; border: 1px solid #252525; border-radius: 6px; color: #171717; background: #fff; box-shadow: 0 1rem 3rem rgb(0 0 0 / 28%); }
.confirmation-dialog::backdrop { background: rgb(0 0 0 / 48%); }
.confirmation-dialog form { display: grid; gap: 1rem; padding: 1.25rem; }
.confirmation-dialog h2,
.confirmation-dialog p { margin: 0; }
.confirmation-dialog h2 { font-size: 1.2rem; }
.confirmation-dialog-actions { display: flex; justify-content: flex-end; gap: .75rem; }
.team-step-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(17rem, .34fr); align-items: start; gap: 1.25rem; }
.remaining-team-card { position: sticky; top: 1rem; min-width: 0; max-height: calc(100vh - 2rem); padding: 1rem; overflow: auto; border: 1px solid #b8b8b8; border-radius: 6px; background: #fafafa; }
.remaining-team-card h3 { margin: 0 0 .75rem; font-size: 1rem; overflow-wrap: anywhere; }
.remaining-team-list { display: grid; gap: .65rem; margin: 0; padding: 0; list-style: none; }
.remaining-team-list li { min-width: 0; padding-bottom: .65rem; border-bottom: 1px solid #d8d8d8; overflow-wrap: anywhere; }
.remaining-team-list li:last-child { padding-bottom: 0; border-bottom: 0; }
.remaining-team-list strong,
.remaining-team-list small { display: block; }
.remaining-team-empty { margin: 0; overflow-wrap: anywhere; }
.team-fields { display: grid; gap: 1rem; }
.team-type-fieldset { min-block-size: 3.85rem; }
.team-name-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; min-block-size: 4.25rem; gap: .75rem; }
.team-members { display: grid; grid-template-rows: repeat(3, minmax(7rem, 7rem)); gap: .65rem; }
.team-member-row { display: grid; grid-template-columns: minmax(7.5rem, .32fr) minmax(0, 1fr); align-items: end; block-size: 7rem; min-block-size: 7rem; gap: 1rem; padding: .7rem .75rem; border: 1px solid #dedede; border-radius: 4px; background: #fafafa; }
.team-member-row > div { min-width: 0; }
.team-member-row label { display: block; }
.team-member-row small { display: -webkit-box; min-block-size: 4.05em; max-block-size: 4.05em; margin-top: .35rem; overflow: hidden; overflow-wrap: anywhere; -webkit-box-orient: vertical; -webkit-line-clamp: 3; }
.team-rule-hint[tabindex] { cursor: pointer; touch-action: pan-y; }
.team-rule-hint[tabindex]:focus,
.team-rule-hint[tabindex]:active { display: block; overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain; -webkit-line-clamp: unset; outline: 2px solid rgb(189 30 45 / 70%); outline-offset: 1px; }
.segmented-choice { display: inline-flex; min-width: 0; overflow: hidden; border: 1px solid #252525; border-radius: 4px; }
.segmented-choice input { position: absolute; inline-size: 1px; block-size: 1px; clip-path: inset(50%); }
.segmented-choice label { display: block; min-height: 2.5rem; padding: .55rem .8rem; border-right: 1px solid #252525; background: #fff; color: #171717; cursor: pointer; }
.segmented-choice label:last-child { border-right: 0; }
.segmented-choice input:checked + label { background: #171717; color: #fff; }
.segmented-choice input:focus-visible + label { outline: 3px solid rgb(189 30 45 / 35%); outline-offset: -3px; }
.registration-review { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem; }
.review-block { min-width: 0; padding-bottom: 1rem; border-bottom: 1px solid #d8d8d8; }
.review-wide { grid-column: 1 / -1; }
.review-block h3 { margin: 0 0 .55rem; font-size: 1rem; }
.review-block p,
.review-block ul { margin: 0; padding-left: 1.1rem; overflow-wrap: anywhere; }
.review-block p { padding-left: 0; }
.review-block li { margin-bottom: .45rem; }
.review-block li span { display: block; color: #555; }
.review-details,
.review-entry dl,
.confirmation-details,
.team-position-list { display: grid; gap: .45rem; margin: 0; }
.review-details > div,
.review-entry dl > div,
.confirmation-details > div,
.team-position-list > div { display: grid; grid-template-columns: minmax(8rem, .42fr) minmax(0, 1fr); gap: .75rem; }
.review-details dt,
.review-entry dt,
.confirmation-details dt,
.team-position-list dt { min-width: 0; color: #555; font-weight: 500; overflow-wrap: anywhere; }
.review-details dd,
.review-entry dd,
.confirmation-details dd,
.team-position-list dd { min-width: 0; margin: 0; overflow-wrap: anywhere; }
.review-entry-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; }
.review-entry { min-width: 0; padding: .8rem; border: 1px solid #dedede; border-radius: 4px; }
.review-entry h4 { margin: 0 0 .65rem; font-size: 1rem; }
.review-entry h4 span { display: block; margin-top: .2rem; color: #555; font-size: .82rem; font-weight: 500; }
.registration-warning { padding: .8rem 1rem; border-left: 3px solid #bd1e2d; background: #fff1f2; }
.review-payment { border-bottom: 0; }
.notice { margin: 1rem 0; padding: .8rem 1rem; border-left: 3px solid #bd1e2d; background: #f4f4f4; }
.wizard-nav { display: flex; min-height: 2.75rem; gap: .75rem; justify-content: flex-end; margin-top: 1.5rem; }
.primary-command,
.secondary-command,
.remove-command,
.icon-text-command { min-height: 2.65rem; padding: .55rem .85rem; border-radius: 4px; font-weight: 700; }
.icon-command { display: inline-grid; width: 2.65rem; min-width: 2.65rem; height: 2.65rem; padding: 0; place-items: center; border: 1px solid #252525; border-radius: 4px; background: #fff; color: #171717; font-size: 1.25rem; font-weight: 700; line-height: 1; }
.icon-command:hover,
.icon-command:focus { border-color: #971321; color: #971321; }
.primary-command { border: 1px solid #bd1e2d; background: #bd1e2d; color: #fff; }
.primary-command:hover,
.primary-command:focus { border-color: #971321; background: #971321; }
.secondary-command,
.icon-text-command { border: 1px solid #252525; background: #fff; color: #171717; }
.remove-command { display: inline-grid; min-height: 2.25rem; height: 2.25rem; min-width: 2.25rem; width: 2.25rem; padding: 0; place-items: center; border-color: #a6a6a6; color: #72141d; line-height: 1; }
.inline-error,
.validation { margin-bottom: 1rem; color: #8d1420; font-weight: 650; }
.inline-error { padding: .65rem .75rem; border-left: 3px solid #bd1e2d; background: #fff1f2; }
.honeypot { position: absolute; left: -9999px; }

.confirmation-shell,
.confirmation-shell *,
.confirmation-shell *::before,
.confirmation-shell *::after { box-sizing: border-box; }
.confirmation-shell { color: #171717; }
.confirmation-title-row { display: flex; align-items: start; justify-content: space-between; gap: 1rem; padding-bottom: 1rem; border-bottom: 1px solid #252525; }
.confirmation-title-row h1 { margin: 0; font-size: 2rem; }
.confirmation-title-row p:last-child { margin: .4rem 0 0; }
.private-link-warning { margin: 1rem 0 1.5rem; padding: 1rem; border: 2px solid #72141d; border-radius: 4px; background: #fff1f2; }
.private-link-warning h2 { margin: 0 0 .5rem; font-size: 1.15rem; }
.private-link-warning p { margin: .4rem 0; }
.private-link-warning strong::before { content: "! "; }
.private-registration-url { display: block; margin-top: .4rem; font-weight: 700; overflow-wrap: anywhere; word-break: break-word; }
.confirmation-overview { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem; }
.confirmation-section { min-width: 0; margin-top: 1.75rem; }
.confirmation-section h2 { margin: 0 0 .85rem; padding-bottom: .45rem; border-bottom: 2px solid #bd1e2d; font-size: 1.25rem; }
.confirmation-entry-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .8rem; }
.confirmation-entry { min-width: 0; padding: .85rem; border: 1px solid #d8d8d8; border-radius: 4px; }
.confirmation-entry h3 { margin: 0 0 .65rem; font-size: 1.05rem; }
.team-confirmation h3 span { display: block; margin-top: .2rem; color: #555; font-size: .82rem; font-weight: 500; }
.payment-confirmation { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: start; gap: 1.5rem; }
.payment-confirmation h2 { grid-column: auto; }
.payment-qr { display: block; width: 11rem; height: 11rem; max-width: 100%; object-fit: contain; }

.landing-page {
  margin-inline: calc(50% - 50vw);
  overflow: hidden;
}

.landing-hero {
  position: relative;
  height: 62svh;
  min-height: 26rem;
  max-height: 42rem;
  color: #fff;
  background: #161616;
  isolation: isolate;
}

.landing-hero::after {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: rgb(0 0 0 / 54%);
  content: "";
}

.landing-hero-photo {
  position: absolute;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.landing-hero-content,
.landing-announcement,
.landing-gallery {
  width: min(100% - 2rem, 72rem);
  margin-inline: auto;
}

.landing-hero-content {
  position: relative;
  height: 100%;
  padding-block: 1.25rem 2.5rem;
}

.landing-logo {
  display: block;
  width: clamp(4.5rem, 12vw, 7rem);
  max-height: 5rem;
  margin-left: auto;
  object-fit: contain;
}

.landing-event-copy {
  position: absolute;
  bottom: 2.5rem;
  max-width: 44rem;
}

.landing-event-meta,
.landing-section-kicker {
  margin: 0 0 .65rem;
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

.landing-event-copy h1 {
  max-width: 15ch;
  margin: 0;
  font-size: 4.5rem;
  line-height: .98;
  letter-spacing: 0;
}

.landing-register {
  display: inline-block;
  margin-top: 1.5rem;
  padding: .8rem 1.25rem;
  border: 1px solid #bd1e2d;
  border-radius: 0;
  background: #bd1e2d;
  color: #fff;
  font-weight: 700;
  text-decoration: none;
}

.landing-register:focus,
.landing-register:hover {
  background: #971321;
  color: #fff;
}

.landing-announcement {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1.5rem;
  padding-block: 2.5rem;
  border-bottom: 1px solid #252525;
}

.landing-section-kicker {
  color: #bd1e2d;
}

.landing-announcement h2 {
  margin: 0;
  color: #171717;
  font-size: 1.55rem;
}

.landing-pdf-actions {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
}

.landing-pdf-actions a {
  display: grid;
  width: 3.25rem;
  height: 2.75rem;
  place-items: center;
  border: 1px solid #252525;
  color: #171717;
  font-weight: 700;
  text-decoration: none;
}

.landing-pdf-actions a:focus,
.landing-pdf-actions a:hover {
  border-color: #bd1e2d;
  background: #bd1e2d;
  color: #fff;
}

.landing-gallery {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: .5rem;
  padding-block: 2.5rem;
}

.landing-cup-photo {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.landing-validation {
  width: min(100% - 2rem, 72rem);
  margin: 1rem auto;
  color: #971321;
}

@media (max-width: 767px) {
  .participant-name-row,
  .participant-identity-row,
  .participant-competition-row,
  .team-step-layout,
  .age-category-row { grid-template-columns: minmax(0, 1fr); }

  .remaining-team-card { position: static; top: auto; max-height: none; }

}

@media (max-width: 575px) {
  .registration-shell { padding-inline: 0; }

  .registration-title-row h1 { font-size: 1.55rem; }

  .registration-title-row img { width: 4rem; height: 3.5rem; }

  .wizard-progress ol { display: flex; align-items: stretch; gap: .35rem; }

  .wizard-progress li { flex: 0 0 .7rem; padding: .55rem 0; border-bottom-width: 4px; }

  .wizard-progress li:not([aria-current="step"]) span { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

  .wizard-progress li[aria-current="step"] { flex: 1 1 auto; padding-inline: .35rem; }

  .field-grid,
  .participant-name-row,
  .participant-identity-row,
  .participant-competition-row,
  .team-step-layout,
  .registration-review,
  .team-name-row,
  .review-entry-list,
  .confirmation-overview,
  .confirmation-entry-list,
  .payment-confirmation { grid-template-columns: minmax(0, 1fr); }

  .review-details > div,
  .review-entry dl > div,
  .confirmation-details > div,
  .team-position-list > div { grid-template-columns: minmax(6.5rem, .42fr) minmax(0, 1fr); }

  .confirmation-title-row { align-items: stretch; flex-direction: column; }

  .print-command { align-self: start; }

  .team-type-fieldset { min-block-size: 6.65rem; }

  .team-name-row { min-block-size: 4.6rem; }

  .team-members { grid-template-rows: repeat(3, minmax(9.75rem, 9.75rem)); }

  .team-member-row { grid-template-columns: minmax(0, 1fr); block-size: 9.75rem; min-block-size: 9.75rem; gap: .35rem; }

  .team-member-row small { min-block-size: 4.05em; }

  .age-category-row { grid-template-columns: minmax(0, 1fr); }

  .remaining-team-card { position: static; top: auto; max-height: none; }

  .team-type-fieldset { align-items: flex-start; flex-wrap: wrap; }

  .team-type-fieldset legend { width: 100%; margin-bottom: .25rem; }

  .section-heading { align-items: start; }

  .section-heading .secondary-command { max-width: 9.5rem; }

  .icon-text-command { width: 100%; }

  .landing-hero {
    min-height: 24rem;
  }

  .landing-hero-content {
    padding-bottom: 1.5rem;
  }

  .landing-event-copy {
    right: 0;
    bottom: 1.5rem;
    left: 0;
  }

  .landing-event-copy h1 {
    font-size: 2.4rem;
  }

  .landing-announcement {
    align-items: start;
    flex-direction: column;
  }

  .landing-gallery {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@page { size: A4; margin: 12mm; }

@media print {
  html,
  body { width: 100%; margin: 0 !important; padding: 0 !important; overflow: visible; background: #fff !important; color: #000 !important; }

  body > header,
  body > footer,
  nav,
  button,
  .wizard-nav,
  .language-switch { display: none !important; }

  body > .container,
  main,
  .confirmation-shell { width: 100% !important; max-width: none !important; margin: 0 !important; padding: 0 !important; }

  .confirmation-shell,
  .confirmation-shell * { color: #000 !important; background: #fff !important; box-shadow: none !important; }

  .private-link-warning { display: block !important; border: 1.5pt solid #000 !important; break-inside: avoid; page-break-inside: avoid; }

  .private-registration-url { color: #000 !important; text-decoration: underline !important; }

  .confirmation-overview,
  .confirmation-entry-list { gap: 4mm; }

  .confirmation-section { margin-top: 5mm; }

  .confirmation-section h2 { margin-bottom: 2mm; break-after: avoid; page-break-after: avoid; }

  [aria-labelledby="confirmation-teams"] { break-inside: avoid; page-break-inside: avoid; }

  html:not([lang="fr"]) [aria-labelledby="confirmation-teams"] { break-before: page; page-break-before: always; }

  .confirmation-entry { break-inside: avoid; page-break-inside: avoid; padding: 2.5mm; border-color: #777; }

  .payment-confirmation { break-inside: avoid; page-break-inside: avoid; }

  .payment-qr { width: 35mm; height: 35mm; max-width: 35mm; }

  .print-url::after { content: " (" attr(href) ")"; overflow-wrap: anywhere; }

  html[lang="fr"] .confirmation-overview,
  html[lang="fr"] .confirmation-entry-list { grid-template-columns: minmax(0, 1fr); }
}
