/* ==========================================================================
   Soirée LC Salaisons · 29 octobre 2026
   Charte inspirée de leon-chaillot.fr : Libre Baskerville et Pacifico,
   or et prune du logo Léon Chaillot, taupe du site.
   ========================================================================== */

/* ---------- Polices (auto-hébergées : aucun appel à un service tiers) ---------- */

@font-face {
  font-family: "Libre Baskerville";
  src: url("../fonts/libre-baskerville-latin.woff2") format("woff2");
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
}

@font-face {
  font-family: "Libre Baskerville";
  src: url("../fonts/libre-baskerville-italic-latin.woff2") format("woff2");
  font-style: italic;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "Pacifico";
  src: url("../fonts/pacifico-latin.woff2") format("woff2");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

/* ---------- Jetons de design ---------- */

:root {
  color-scheme: light;

  --c-paper: #ffffff;
  --c-tint: #f8f5f0;          /* fond de la zone d'inscription */
  --c-ink: #3a2f25;           /* texte principal (contraste 13:1) */
  --c-ink-soft: #665440;      /* texte secondaire (7,2:1) */
  --c-taupe: #816d52;         /* taupe du site leon-chaillot.fr (4,9:1) */
  --c-gold: #c5a55d;          /* or du logo : filets et cadres uniquement */
  --c-gold-soft: #e6dac0;     /* filets discrets */
  --c-gold-deep: #9a7a36;     /* or foncé : grands chiffres uniquement */
  --c-plum: #8a3d74;          /* prune du logo : actions et liens (7:1) */
  --c-plum-dark: #6f2f5d;
  --c-plum-wash: #f6eef3;
  --c-field-border: #9b8a72;  /* contour des champs (3,3:1) */
  --c-error: #b3261e;
  --c-error-wash: #fcf1f0;

  --font-serif: "Libre Baskerville", Baskerville, Georgia, "Times New Roman", serif;
  --font-script: "Pacifico", "Brush Script MT", cursive;

  --radius: 2px;
  --gutter: 20px;
  --container: 1120px;
  --section-space: clamp(56px, 8vw, 104px);
  --shadow-card: 0 28px 56px -32px rgba(58, 47, 37, 0.45);
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

@media (min-width: 640px) {
  :root { --gutter: 32px; }
}

@media (min-width: 1024px) {
  :root { --gutter: 40px; }
}

/* ---------- Base ---------- */

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 16px;
}

body {
  margin: 0;
  background: var(--c-paper);
  color: var(--c-ink);
  font-family: var(--font-serif);
  font-size: 1rem;
  line-height: 1.75;
  font-kerning: normal;
  font-variant-numeric: lining-nums;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img,
picture,
svg {
  display: block;
  max-width: 100%;
}

img {
  height: auto;
}

h1,
h2,
h3 {
  margin: 0;
  font-weight: 400;
  line-height: 1.25;
  text-wrap: balance;
}

p {
  margin: 0 0 1em;
  text-wrap: pretty;
}

p:last-child {
  margin-bottom: 0;
}

a {
  color: var(--c-plum);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}

a:hover {
  color: var(--c-plum-dark);
  text-decoration-thickness: 2px;
}

:focus-visible {
  outline: 3px solid var(--c-plum);
  outline-offset: 3px;
}

[tabindex="-1"]:focus {
  outline: none;
}

sup {
  font-size: 0.65em;
  line-height: 0;
}

.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.icon {
  width: 1.25em;
  height: 1.25em;
  flex: none;
  fill: currentColor;
}

.nowrap {
  white-space: nowrap;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.container {
  width: 100%;
  max-width: calc(var(--container) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.container--form {
  max-width: calc(820px + 2 * var(--gutter));
}

/* ---------- Lien d'évitement ---------- */

.skip-link {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 10;
  padding: 12px 18px;
  background: var(--c-plum);
  color: #fff;
  border-radius: var(--radius);
  text-decoration: none;
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: none;
  color: #fff;
}

/* ---------- En-tête : logos partenaires ---------- */

.masthead {
  padding: 22px var(--gutter) 20px;
  text-align: center;
}

.masthead__logos {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(14px, 4vw, 44px);
}

.masthead__logo img,
img.masthead__logo {
  width: auto;
}

.masthead__logo--lc img {
  height: clamp(78px, 10vw, 112px);
}

.masthead__logo--om img {
  height: clamp(48px, 6vw, 66px);
}

img.masthead__logo--monoprix {
  height: clamp(13px, 1.6vw, 18px);
}

.masthead__rule {
  width: 1px;
  height: clamp(44px, 6vw, 64px);
  background: var(--c-gold);
  flex: none;
}

.masthead__caption {
  margin: 12px 0 0;
  color: var(--c-taupe);
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  line-height: 1.5;
  text-transform: uppercase;
  text-wrap: balance;
}

/* ---------- Invitation (hero) ---------- */

.hero {
  position: relative;
}

.hero__media {
  height: clamp(190px, 28vh, 320px);
  overflow: hidden;
  background: #d9d2c4;
}

.hero__media picture,
.hero__media img {
  width: 100%;
  height: 100%;
}

.hero__media img {
  object-fit: cover;
  object-position: 50% 30%;
}

.hero__card {
  position: relative;
  max-width: 820px;
  margin: -56px 14px 0;
  padding: 34px 20px 30px;
  background: var(--c-paper);
  border: 1px solid var(--c-gold);
  outline: 1px solid var(--c-gold);
  outline-offset: -8px;
  box-shadow: var(--shadow-card);
  text-align: center;
}

.hero__kicker {
  margin: 0 0 6px;
  color: var(--c-plum);
  font-family: var(--font-script);
  font-size: 1.75rem;
  line-height: 1.3;
}

.hero__title {
  margin: 0 auto;
  font-size: clamp(1.6rem, 1.1rem + 1.9vw, 2.4rem);
  line-height: 1.22;
  letter-spacing: -0.005em;
}

.hero__date {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 20px 0 16px;
  color: var(--c-ink);
  font-size: clamp(0.9rem, 0.85rem + 0.3vw, 1.06rem);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.hero__date time {
  white-space: nowrap;
}

.hero__date::before,
.hero__date::after {
  content: "";
  flex: 0 1 56px;
  min-width: 12px;
  height: 1px;
  background: var(--c-gold);
}

.hero__lead {
  max-width: 52ch;
  margin: 0 auto 24px;
  color: var(--c-ink-soft);
}

/* ---------- Sections ---------- */

.section {
  padding-block: var(--section-space);
}

.section__title {
  margin-bottom: 0.8em;
  color: var(--c-ink);
  font-size: clamp(1.55rem, 1.2rem + 1.3vw, 2.15rem);
}

.section__title::before {
  content: "";
  display: block;
  width: 44px;
  height: 1px;
  margin-bottom: 18px;
  background: var(--c-gold);
}

/* La distinction */

.award__grid {
  display: grid;
  gap: 36px;
}

.award__body {
  max-width: 62ch;
}

.award__media {
  margin: 0;
  max-width: 300px;
}

.award__media img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: var(--radius);
}

.award__media figcaption {
  margin-top: 10px;
  color: var(--c-ink-soft);
  font-size: 0.85rem;
  font-style: italic;
}

.figures {
  display: grid;
  margin: 48px 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--c-gold-soft);
}

.figures__item {
  display: grid;
  grid-template-columns: 6.2rem 1fr;
  align-items: baseline;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--c-gold-soft);
}

.figures__value {
  color: var(--c-gold-deep);
  font-size: 1.75rem;
  line-height: 1.2;
  white-space: nowrap;
}

.figures__label {
  color: var(--c-ink-soft);
  font-size: 0.95rem;
  line-height: 1.5;
}

/* Le produit */

.product {
  padding-top: 0;
}

.product__grid {
  display: grid;
  gap: 32px;
  align-items: center;
}

.product__media {
  position: relative;
  margin: 0 12px 12px 0;
}

.product__media::after {
  content: "";
  position: absolute;
  inset: 12px -12px -12px 12px;
  z-index: -1;
  border: 1px solid var(--c-gold);
}

.product__media img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.product__body {
  max-width: 58ch;
}

/* La soirée */

.evening {
  padding-top: 0;
}

.evening__grid {
  display: grid;
  gap: 36px;
}

.evening__body {
  max-width: 60ch;
}

.practical {
  padding: 28px 22px 24px;
  background: var(--c-tint);
  border: 1px solid var(--c-gold);
  border-radius: var(--radius);
  outline: 1px solid var(--c-gold);
  outline-offset: -7px;
}

.practical__title {
  margin-bottom: 10px;
  color: var(--c-ink);
  font-size: 1.3rem;
}

.practical__list {
  margin: 0 0 22px;
}

.practical__item {
  padding: 12px 0;
  border-top: 1px solid var(--c-gold-soft);
}

.practical__item dt {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--c-taupe);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
}

.practical__item dt .icon {
  width: 1.15rem;
  height: 1.15rem;
  color: var(--c-gold-deep);
}

.practical__item dd {
  margin: 2px 0 0 calc(1.15rem + 10px);
  color: var(--c-ink);
  font-size: 1.05rem;
  line-height: 1.5;
}

.practical__route {
  width: 100%;
}

/* ---------- Boutons ---------- */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 50px;
  padding: 12px 26px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font: inherit;
  font-size: 1rem;
  line-height: 1.3;
  letter-spacing: 0.02em;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.18s var(--ease), color 0.18s var(--ease), border-color 0.18s var(--ease),
    transform 0.12s var(--ease);
  -webkit-tap-highlight-color: transparent;
}

.button > span {
  white-space: nowrap;
}

.button:active {
  transform: translateY(1px);
}

.button--primary {
  background: var(--c-plum);
  color: #fff;
}

.button--primary:hover {
  background: var(--c-plum-dark);
  color: #fff;
  text-decoration: none;
}

.button--secondary {
  background: var(--c-paper);
  color: var(--c-plum);
  border-color: var(--c-plum);
}

.button--secondary:hover {
  background: var(--c-plum-wash);
  color: var(--c-plum-dark);
}

.button[disabled],
.button[aria-disabled="true"] {
  cursor: not-allowed;
  opacity: 0.55;
}

.button[disabled]:active {
  transform: none;
}

.button--submit {
  width: 100%;
  min-height: 56px;
  padding-inline: 16px;
  font-size: 1.02rem;
  letter-spacing: 0.01em;
}

.button__spinner {
  display: none;
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.45);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.form[aria-busy="true"] .button__spinner {
  display: inline-block;
}

.form[aria-busy="true"] .button--submit {
  cursor: progress;
  opacity: 0.85;
}

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

/* ---------- Inscription ---------- */

.registration {
  background: var(--c-tint);
  border-top: 1px solid var(--c-gold-soft);
  border-bottom: 1px solid var(--c-gold-soft);
}

.registration__card {
  padding: 32px 20px;
  background: var(--c-paper);
  border: 1px solid var(--c-gold);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
}

.registration__head {
  margin-bottom: 28px;
}

.registration__hint {
  color: var(--c-ink-soft);
  font-size: 0.92rem;
}

.form__group {
  min-width: 0;
  margin: 0 0 36px;
  padding: 0;
  border: 0;
}

.form__legend {
  float: left;
  width: 100%;
  margin: 0 0 18px;
  padding: 0 0 10px;
  border-bottom: 1px solid var(--c-gold-soft);
  color: var(--c-ink);
  font-size: 1.2rem;
}

.form__legend + * {
  clear: both;
}

.form__grid {
  display: grid;
  gap: 20px;
}

.form__help {
  margin-bottom: 18px;
  color: var(--c-ink-soft);
  font-size: 0.92rem;
}

.form__help--limit {
  margin: 14px 0 0;
}

.form__total {
  margin: 0 0 24px;
  padding: 14px 18px;
  background: var(--c-tint);
  border-left: 3px solid var(--c-gold);
  color: var(--c-ink);
}

.form__total strong {
  color: var(--c-plum);
  font-weight: 700;
}

.form__trap {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form__turnstile:not(:empty) {
  margin-bottom: 20px;
}

.form__privacy {
  margin-bottom: 20px;
  color: var(--c-ink-soft);
  font-size: 0.88rem;
  line-height: 1.6;
}

/* Champs */

.field {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.field__label {
  margin-bottom: 8px;
  color: var(--c-ink);
  font-size: 0.95rem;
  line-height: 1.4;
}

.field__optional {
  color: var(--c-ink-soft);
  font-size: 0.85rem;
}

.field__input {
  width: 100%;
  min-height: 50px;
  padding: 11px 14px;
  background: var(--c-paper);
  border: 1px solid var(--c-field-border);
  border-radius: var(--radius);
  color: var(--c-ink);
  font: inherit;
  font-size: 1rem;
  line-height: 1.4;
  transition: border-color 0.15s var(--ease), box-shadow 0.15s var(--ease);
  -webkit-appearance: none;
  appearance: none;
}

.field__input:hover {
  border-color: var(--c-taupe);
}

.field__input:focus {
  outline: 2px solid transparent;
  border-color: var(--c-plum);
  box-shadow: 0 0 0 3px rgba(138, 61, 116, 0.28);
}

/* Les erreurs sont gérées par le formulaire lui-même, pas par le style natif du navigateur. */
.field__input:-moz-ui-invalid {
  box-shadow: none;
}

.field__input[aria-invalid="true"] {
  border-color: var(--c-error);
  box-shadow: inset 0 0 0 1px var(--c-error);
}

.field__input[aria-invalid="true"]:focus {
  box-shadow: inset 0 0 0 1px var(--c-error), 0 0 0 3px rgba(179, 38, 30, 0.22);
}

.field__input:disabled {
  background: #f3f0ea;
  cursor: not-allowed;
}

.field__error {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  margin: 8px 0 0;
  color: var(--c-error);
  font-size: 0.9rem;
  line-height: 1.45;
}

.field__error[hidden] {
  display: none;
}

/* Participants supplémentaires */

.participants {
  display: grid;
  gap: 18px;
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
}

.participants:empty {
  display: none;
}

.participant__fieldset {
  position: relative;
  min-width: 0;
  margin: 0;
  padding: 18px 16px 20px;
  border: 1px solid var(--c-gold-soft);
  border-radius: var(--radius);
  background: #fffdf9;
}

.participant__legend {
  float: left;
  width: 100%;
  margin: 0 0 14px;
  padding: 0 96px 0 0;
  min-height: 44px;
  display: flex;
  align-items: center;
  color: var(--c-ink);
  font-size: 1.02rem;
}

.participant__legend ~ .form__grid {
  clear: both;
}

.participant__remove {
  position: absolute;
  top: 18px;
  right: 10px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  padding: 8px 10px;
  background: none;
  border: 0;
  border-radius: var(--radius);
  color: var(--c-ink-soft);
  font: inherit;
  font-size: 0.9rem;
  cursor: pointer;
}

.participant__remove:hover {
  color: var(--c-error);
  background: var(--c-error-wash);
}

.participant.is-entering {
  animation: enter 0.22s var(--ease);
}

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

.notice {
  display: flex;
  gap: 12px;
  margin: 0 0 18px;
  padding: 14px 16px;
  background: var(--c-tint);
  border-left: 3px solid var(--c-gold);
  color: var(--c-ink-soft);
  font-size: 0.9rem;
  line-height: 1.6;
}

.notice[hidden] {
  display: none;
}

.notice__icon {
  margin-top: 2px;
  color: var(--c-gold-deep);
}

/* Alertes */

.alert {
  display: flex;
  gap: 12px;
  margin: 0 0 24px;
  padding: 16px 18px;
  background: var(--c-error-wash);
  border: 1px solid rgba(179, 38, 30, 0.35);
  border-left: 4px solid var(--c-error);
  border-radius: var(--radius);
  color: var(--c-ink);
  font-size: 0.95rem;
  line-height: 1.6;
}

.alert[hidden] {
  display: none;
}

.alert__icon {
  margin-top: 3px;
  color: var(--c-error);
}

.alert__title {
  margin-bottom: 6px;
  font-size: 1rem;
  font-weight: 700;
}

.alert__list {
  margin: 0;
  padding-left: 1.1em;
}

.alert__list a {
  color: var(--c-error);
}

/* Confirmation */

.success {
  padding: 12px 0 4px;
  text-align: center;
}

.success[hidden] {
  display: none;
}

.success__icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 14px;
  color: var(--c-gold-deep);
}

.success__title {
  margin-bottom: 16px;
  font-size: clamp(1.45rem, 1.2rem + 1vw, 1.9rem);
}

.success__message {
  max-width: 52ch;
  margin-inline: auto;
}

.success__count {
  display: inline-block;
  margin: 22px 0 10px;
  padding: 12px 20px;
  border: 1px solid var(--c-gold);
  border-radius: var(--radius);
}

.success__count strong {
  color: var(--c-plum);
  font-size: 1.25rem;
}

.success__names {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px 18px;
  margin: 8px 0 22px;
  padding: 0;
  list-style: none;
  color: var(--c-ink-soft);
  font-size: 0.92rem;
}

.success__contact {
  color: var(--c-ink-soft);
  font-size: 0.92rem;
}

/* ---------- Confidentialité ---------- */

.privacy {
  font-size: 0.93rem;
}

.privacy .section__title {
  font-size: clamp(1.35rem, 1.1rem + 0.9vw, 1.75rem);
}

.privacy__intro {
  max-width: 62ch;
  color: var(--c-ink-soft);
}

.privacy__list {
  display: grid;
  gap: 0 48px;
  margin: 28px 0 0;
}

.privacy__item {
  padding: 16px 0;
  border-top: 1px solid var(--c-gold-soft);
}

.privacy__item dt {
  margin-bottom: 4px;
  color: var(--c-taupe);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.privacy__item dd {
  margin: 0;
  color: var(--c-ink-soft);
  line-height: 1.7;
}

/* ---------- Pied de page ---------- */

.footer {
  padding: 36px 0 44px;
  border-top: 1px solid var(--c-gold);
  color: var(--c-ink-soft);
  font-size: 0.82rem;
  line-height: 1.65;
  text-align: center;
}

.footer__inner {
  max-width: calc(820px + 2 * var(--gutter));
}

.footer__brand {
  margin-bottom: 8px;
  color: var(--c-ink);
  font-size: 0.9rem;
}

.footer__legal {
  margin-bottom: 8px;
}

/* ---------- Grands écrans ---------- */

@media (min-width: 640px) {
  .hero__media {
    height: clamp(240px, 34vh, 380px);
  }

  .hero__card {
    margin: -96px auto 0;
    padding: 44px 56px 38px;
    outline-offset: -10px;
  }

  .hero__kicker {
    font-size: 2rem;
  }

  .form__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px 24px;
  }

  .registration__card {
    padding: 44px 48px;
  }

  .participant__fieldset {
    padding: 20px 22px 24px;
  }

  .button--submit {
    width: auto;
    min-width: 300px;
  }

  .figures {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    border-bottom: 1px solid var(--c-gold-soft);
  }

  .figures__item {
    grid-template-columns: 1fr;
    gap: 6px;
    padding: 24px 24px 26px;
    border-bottom: 0;
  }

  .figures__item + .figures__item {
    border-left: 1px solid var(--c-gold-soft);
  }

  .figures__item:first-child {
    padding-left: 0;
  }

  .figures__value {
    font-size: 2.1rem;
  }
}

@media (min-width: 900px) {
  .hero__media {
    height: clamp(280px, 40vh, 440px);
  }

  .hero__card {
    margin-top: -120px;
  }

  .award__grid {
    grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
    gap: 64px;
    align-items: center;
  }

  .award__media {
    justify-self: end;
    width: 100%;
  }

  .product__grid {
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
    gap: 72px;
  }

  .evening__grid {
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
    gap: 64px;
    align-items: start;
  }

  .practical {
    padding: 32px 32px 26px;
  }

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

/* Écrans d'ordinateur peu hauts (portables 1366 × 768…) : l'invitation reste entière à l'écran. */
@media (min-width: 900px) and (max-height: 820px) {
  .masthead {
    padding-block: 16px 14px;
  }

  .masthead__logo--lc img {
    height: 92px;
  }

  .masthead__logo--om img {
    height: 56px;
  }

  .masthead__rule {
    height: 52px;
  }

  .masthead__caption {
    margin-top: 8px;
  }

  .hero__media {
    height: 30vh;
  }

  .hero__card {
    margin-top: -90px;
    padding-block: 36px 32px;
  }
}

/* ---------- Préférences d'accessibilité ---------- */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .button__spinner {
    animation: spin 1.6s linear infinite !important;
  }
}

@media (forced-colors: active) {
  .hero__card,
  .registration__card,
  .practical,
  .participant__fieldset {
    border: 1px solid CanvasText;
  }

  .button--primary {
    border: 1px solid ButtonText;
  }
}
