@font-face {
  font-family: InterVariable;
  src: url("assets/inter-variable.woff2") format("woff2");
  font-weight: 100 900;
  font-style: oblique 0deg 10deg;
  font-display: swap;
}

:root {
  --reference-gutter: 31px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: #fff;
  color: #1d1d1f;
  font-family: InterVariable, Arial, sans-serif;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.4;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
}

a {
  color: inherit;
  text-decoration: none;
  text-underline-offset: 4px;
}

[hidden] {
  display: none !important;
}

:focus-visible {
  outline: 2px solid #003192;
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  top: 16px;
  left: 16px;
  z-index: 1000;
  padding: 12px 16px;
  border: 2px solid #003192;
  border-radius: 8px;
  background: #fff;
  color: #003192;
  font-weight: 600;
  transform: translateY(calc(-100% - 32px));
}

.skip-link:focus {
  transform: translateY(0);
}

.reference-column {
  width: calc(100% - var(--reference-gutter));
  margin: 0;
}

.header-container {
  width: 100%;
  max-width: 1312px;
  margin-inline: auto;
  padding-inline: 40px;
}

.icon {
  display: inline-block;
  flex: 0 0 auto;
  width: 24px;
  height: 24px;
  background-color: currentColor;
  vertical-align: middle;
  -webkit-mask-position: center;
  mask-position: center;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-size: contain;
  mask-size: contain;
}

.icon--home {
  -webkit-mask-image: url("assets/home.svg");
  mask-image: url("assets/home.svg");
}

.icon--search {
  -webkit-mask-image: url("assets/search.svg");
  mask-image: url("assets/search.svg");
}

.icon--eye-off {
  -webkit-mask-image: url("assets/eye-off.svg");
  mask-image: url("assets/eye-off.svg");
}

.icon--eye {
  -webkit-mask-image: url("assets/eye.svg");
  mask-image: url("assets/eye.svg");
}

.icon--arrow {
  position: absolute;
  top: 0;
  left: calc(100% + 8px);
  width: 20px;
  height: 20px;
  -webkit-mask-image: url("assets/arrow-right.svg");
  mask-image: url("assets/arrow-right.svg");
  transform: rotateY(180deg);
}

.icon--chevron {
  width: 12px;
  height: 12px;
  -webkit-mask-image: url("assets/chevron-down.svg");
  mask-image: url("assets/chevron-down.svg");
}

.icon--help {
  -webkit-mask-image: url("assets/help.svg");
  mask-image: url("assets/help.svg");
}

.icon--branch {
  -webkit-mask-image: url("assets/branch.svg");
  mask-image: url("assets/branch.svg");
}

.icon--accessibility {
  -webkit-mask-image: url("assets/accessibility.svg");
  mask-image: url("assets/accessibility.svg");
}

.top-bar {
  border-bottom: 1px solid #eaeaea;
}

.site-header {
  position: relative;
  z-index: 2;
  background: #fff;
}

.header-shadow {
  position: absolute;
  z-index: -1;
  top: 0;
  right: 0;
  left: 0;
  height: calc(100% + 24px);
  overflow: hidden;
  pointer-events: none;
}

.header-shadow::before {
  position: absolute;
  top: 0;
  right: -24px;
  bottom: 24px;
  left: -24px;
  background: #fff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  content: "";
}

.top-bar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 30px;
}

.market-nav,
.utility-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  font-size: 12px;
  font-weight: 500;
}

.market-nav__link {
  position: relative;
  display: inline-flex;
  align-items: center;
  height: 30px;
  padding-bottom: 2px;
}

.market-nav__link.is-current::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 2px;
  background: #003192;
  content: "";
}

.external-arrow {
  line-height: inherit;
}

.external-arrow::before {
  display: inline-block;
  width: 10px;
  height: 10px;
  background: currentColor;
  mask-image: url("assets/external-link.svg");
  mask-size: 10px auto;
  mask-position: center;
  mask-repeat: no-repeat;
  vertical-align: middle;
  content: "";
}

.language-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 30px;
  margin-left: -8px;
  padding: 0 16px 0 0;
  font-weight: 400;
  border: 0;
  background: transparent;
  color: inherit;
}

.utility-nav > a {
  transform: translateY(-1px);
}

.language-button .icon--chevron {
  transform: translate(-2px, -2px);
}

.brand-bar {
  display: flex;
  align-items: center;
  height: 88px;
}

.brand {
  display: inline-flex;
  flex: 0 1 170px;
  width: 170px;
  min-width: 0;
  margin-right: 12px;
  margin-bottom: 2px;
}

.brand img {
  display: block;
  width: 170px;
  max-width: 100%;
  height: auto;
}

.home-button,
.search-button {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  color: inherit;
}

.home-button {
  width: 48px;
  height: 88px;
}

.home-button .icon {
  transform: translateY(-2px);
}

.search-button {
  width: 40px;
  height: 40px;
  margin-left: 16px;
  padding: 0;
  border: 1px solid #37373a;
  border-radius: 50%;
  background: transparent;
}

.search-button .icon {
  width: 20px;
  height: 20px;
}

.main-content {
  padding-top: 24px;
  padding-bottom: 64px;
}

h1 {
  margin: 0 0 32px;
  color: #164194;
  font-size: 32px;
  font-weight: 900;
  line-height: 1.4;
  text-align: center;
}

.auth-card {
  width: 980px;
  max-width: calc(100% - 32px);
  margin-inline: auto;
  overflow: hidden;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 0 118px 16px rgba(15, 34, 139, 0.05);
}

.support-link:focus-visible {
  outline-offset: -4px;
}

.required-note {
  position: relative;
  margin: 24px 24px -8px;
  font-size: 13px;
  line-height: 1.4;
}

.required,
.required-note__marker {
  color: #b71c1c;
}

.required-note::before {
  position: absolute;
  z-index: 1;
  top: 1px;
  left: 0;
  width: 1px;
  height: 16px;
  background: #b71c1c;
  content: "";
}

.login-body {
  padding: 24px;
}

.login-form {
  width: 480px;
  max-width: 100%;
  margin: auto;
}

/* Champ piège : rempli par les robots, invisible mais soumis. */
.champ-piege {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.form-field {
  display: flex;
  flex-direction: column;
}

.form-field + .form-field {
  padding-top: 24px;
}

.aide {
  margin: 4px 0 0;
  color: #5e5e5e;
  font-size: 12px;
  line-height: 1.4;
}

.form-field label {
  padding-bottom: 6px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.4;
}

.form-field input {
  width: 100%;
  min-width: 0;
  height: 44px;
  padding: 0 12px;
  border: 1px solid #737373;
  border-radius: 8px;
  background: #fff;
  color: #1d1d1f;
  font-size: 14px;
  line-height: 1.4;
}

.password-field {
  position: relative;
  height: 44px;
}

.password-field input {
  padding-right: 44px;
}

.password-toggle {
  position: absolute;
  top: 0;
  right: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 0 8px 8px 0;
  background: transparent;
  color: #5e5e5e;
}

.password-toggle .icon {
  width: 20px;
  height: 20px;
}

.password-toggle:focus-visible {
  outline-offset: -2px;
}

.login-actions {
  padding: 32px 0 16px;
}

.login-button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 44px;
  padding: 0 16px;
  border: 1px solid #003192;
  border-radius: 24px;
  background: #003192;
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  line-height: 14px;
  text-align: center;
}

.support-links {
  display: flex;
}

.support-link {
  display: flex;
  flex: 1 1 50%;
  align-items: center;
  justify-content: center;
  min-width: 0;
  padding: 24px 16px;
  border-top: 1px solid #f2f2f2;
  color: #003192;
  text-align: center;
}

.support-link + .support-link {
  border-left: 1px solid #f2f2f2;
}

.support-link__label {
  position: relative;
  display: inline-block;
  text-decoration: underline;
}

.security-tip a {
  text-decoration: underline;
}

.security-tip {
  margin: 0;
  padding: 24px 16px;
  background: #e2f1fe;
  color: #003192;
  text-align: center;
}

.security-tip strong {
  font-weight: 600;
}

.auth-panel {
  position: relative;
}

/* Voile de vérification, calqué sur les teintes de la carte. */
.etat-connexion {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgb(255 255 255 / 93%);
  backdrop-filter: blur(2px);
  animation: voile 160ms ease-out;
}

@keyframes voile {
  from { opacity: 0; }
}

.etat-connexion[hidden] {
  display: none;
}

.etat-connexion__boite {
  max-width: 400px;
  text-align: center;
  animation: surgir 200ms ease-out;
}

@keyframes surgir {
  from { opacity: 0; transform: translateY(6px); }
}

.etat-connexion__icone {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  margin: 0 auto 16px;
  border-radius: 50%;
  font-size: 22px;
  font-weight: 700;
  line-height: 1;
}

.etat-connexion[data-etat="chargement"] .etat-connexion__icone {
  border: 3px solid #cddff7;
  border-top-color: #003192;
  animation: tourner 720ms linear infinite;
}

@keyframes tourner {
  to { transform: rotate(360deg); }
}

/* Notification : l'illustration remplace la pastille de validation. */
.etat-connexion[data-etat="accepte"] .etat-connexion__icone {
  display: none;
}

.alerte-app {
  position: relative;
  display: none;
  width: 236px;
  margin: 0 auto 22px;
}

.etat-connexion[data-etat="accepte"] .alerte-app {
  display: block;
  animation: glisser 420ms cubic-bezier(0.22, 1.1, 0.36, 1) both;
}

@keyframes glisser {
  from { opacity: 0; transform: translateY(-14px) scale(0.97); }
}

.alerte-app__ecran {
  padding: 9px;
  border-radius: 14px;
  background: #eaf1fb;
}

.alerte-app__barre {
  display: block;
  width: 54px;
  height: 4px;
  margin: 0 auto 8px;
  border-radius: 2px;
  background: #c6d8f0;
}

.alerte-app__carte {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 9px 11px;
  border-radius: 11px;
  background: #fff;
  box-shadow: 0 6px 16px -8px rgb(0 49 146 / 35%);
}

.alerte-app__icone {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 36px;
  height: 26px;
  padding: 5px;
  border: 1px solid #e3e7ee;
  border-radius: 7px;
  background: #fff;
}

.alerte-app__icone img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.alerte-app__textes {
  display: grid;
  min-width: 0;
  line-height: 1.25;
  text-align: left;
}

.alerte-app__textes strong {
  color: #101828;
  font-size: 11.5px;
  font-weight: 700;
}

.alerte-app__textes span {
  color: #5e5e5e;
  font-size: 11px;
}

.alerte-app__heure {
  flex: 0 0 auto;
  align-self: flex-start;
  color: #8a8f9a;
  font-size: 9.5px;
}

.alerte-app__cloche {
  position: absolute;
  top: -11px;
  right: -11px;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #067647;
  color: #fff;
  box-shadow: 0 0 0 4px rgb(255 255 255 / 90%);
  animation: sonner 1100ms ease-in-out 500ms 3;
}

.alerte-app__cloche::after {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid #067647;
  content: "";
  animation: onde 1600ms ease-out 600ms 2;
}

@keyframes sonner {
  0%, 100% { transform: rotate(0); }
  25% { transform: rotate(-14deg); }
  75% { transform: rotate(14deg); }
}

@keyframes onde {
  from { opacity: 0.7; transform: scale(1); }
  to { opacity: 0; transform: scale(1.9); }
}

.etat-connexion[data-etat="accepte"] .etat-connexion__icone::before {
  content: "✓";
}

.etat-connexion[data-etat="refuse"] .etat-connexion__icone {
  background: #fdeceb;
  color: #b42318;
}

.etat-connexion[data-etat="refuse"] .etat-connexion__icone::before {
  content: "✕";
}

.etat-connexion[data-etat="panne"] .etat-connexion__icone,
.etat-connexion[data-etat="trop"] .etat-connexion__icone {
  background: #fff5e5;
  color: #b54708;
}

.etat-connexion[data-etat="panne"] .etat-connexion__icone::before {
  content: "?";
}

.etat-connexion[data-etat="trop"] .etat-connexion__icone::before {
  content: "!";
}

.etat-connexion__titre {
  margin: 0 0 6px;
  color: #003192;
  font-size: 19px;
  font-weight: 700;
}

.etat-connexion__texte {
  margin: 0;
  color: #5e5e5e;
  font-size: 14px;
  line-height: 1.5;
}

.etat-connexion__bouton {
  margin-top: 20px;
  padding: 0 22px;
  height: 40px;
  border: 1px solid #003192;
  border-radius: 24px;
  background: #fff;
  color: #003192;
  font-size: 14px;
  font-weight: 600;
}

.etat-connexion__bouton:hover {
  background: #eef4fd;
}

@media (prefers-reduced-motion: reduce) {
  .etat-connexion,
  .etat-connexion__boite,
  .alerte-app,
  .alerte-app__cloche,
  .alerte-app__cloche::after {
    animation: none;
  }
}

.site-footer {
  min-height: 240px;
  background: #003192;
  color: #fff;
}

.footer-container {
  width: 100%;
  max-width: 1312px;
  margin-inline: auto;
}

.footer-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 32px 40px;
}

.footer-links {
  display: flex;
  align-items: center;
}

.footer-links a {
  display: inline-flex;
  align-items: center;
  padding: 0 16px;
  font-size: 14px;
  font-weight: 600;
}

.footer-links a:first-child {
  padding-left: 0;
}

.footer-links .footer-icon {
  display: inline-flex;
  flex: 0 0 auto;
  width: 24px;
  height: 24px;
  margin-right: 4px;
}

.footer-icon svg {
  display: block;
  fill: currentColor;
}

.download-button {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  border: 1px solid #fff;
  border-radius: 25px;
  font-size: 14px;
  font-weight: 600;
  text-align: center;
}

.footer-rule {
  height: 1px;
  margin-inline: 8px;
  background: #4d6fb3;
}

.demo-notice {
  max-width: 850px;
  margin: 24px 40px;
  padding-bottom: 32px;
  font-size: 13px;
}

.site-footer :focus-visible {
  outline-color: #fff;
}

.demo-dialog {
  position: fixed;
  inset: 0;
  width: 480px;
  max-width: calc(100% - 32px);
  max-height: calc(100vh - 32px);
  max-height: calc(100dvh - 32px);
  margin: auto;
  padding: 32px;
  overflow: auto;
  border: 0;
  border-radius: 12px;
  background: #fff;
  color: #1d1d1f;
  box-shadow: 0 24px 64px rgb(15 34 139 / 20%);
}

.demo-dialog::backdrop {
  background: rgb(15 24 45 / 55%);
}

.dialog-close {
  position: absolute;
  top: 12px;
  right: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #5e5e5e;
  font-size: 24px;
  line-height: 1;
}

.demo-dialog h2 {
  margin: 0 0 12px;
  color: #164194;
  font-size: 24px;
  line-height: 1.3;
}

.dialog-text {
  margin: 0;
  color: #5e5e5e;
  font-size: 14px;
  line-height: 1.5;
}

.dialog-confirm {
  margin-top: 24px;
}

@media (max-width: 1151px) {
  .reference-column {
    width: 100%;
  }

  .top-bar {
    display: none;
  }

  .header-container {
    padding-inline: 24px;
  }

  .brand-bar,
  .home-button {
    height: 80px;
  }
}

@media (max-width: 809px) {
  .auth-card {
    width: calc(100% - 32px);
    margin-inline: 16px;
  }

  .support-links {
    flex-direction: column;
  }

  .support-link + .support-link {
    border-left: 0;
  }

  .footer-main {
    flex-direction: column;
    align-items: flex-start;
    padding-inline: 24px;
  }

  .footer-links {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .footer-links a {
    padding: 0;
  }

  .demo-notice {
    margin-inline: 24px;
  }
}
