/* ============================================================
   BON DE COMMANDE — LE JOYEUX P'TIT NOËL D'INSTANT ACADÉMIE
   Styles isolés sous .bdc-page--noel. Structure inspirée de la
   page de commande V2 de Yashi : formulaire à gauche, récapitulatif
   collant à droite, encadrés d'options et total dynamique.
   ============================================================ */

.bdc-page--noel {
  --noel-red: #9e1f32;
  --noel-red-light: #c7304a;
  --noel-green: #1f4d3a;
  --noel-green-light: #2d6b4f;
  --noel-gold: #d8a63a;
  --noel-gold-light: #f2d06b;
  --noel-cream: #fffaf0;
  --noel-ink: #2c2e35;
  --noel-muted: #6f6475;
  --noel-border: #eadff1;
  --noel-shadow: 0 14px 36px rgba(77, 39, 51, 0.1);
  --noel-title-gradient: linear-gradient(
    90deg,
    #9e1f32 0%,
    #c7304a 30%,
    #d8a63a 58%,
    #f2d06b 78%,
    #d8a63a 100%
  );
  padding: 1.75rem 0 4rem;
  background:
    radial-gradient(circle at 12% 0%, rgba(242, 208, 107, 0.2), transparent 34%),
    radial-gradient(circle at 88% 8%, rgba(158, 31, 50, 0.09), transparent 32%), #fffaf0;
  color: var(--noel-ink);
}

.bdc-page--noel .container {
  max-width: 1160px;
}

.bdc-page--noel .bdc-grid {
  grid-template-columns: minmax(0, 1fr) 390px;
  gap: 1.35rem;
}

.bdc-page--noel .bdc-card,
.bdc-page--noel .bdc-summary-card {
  background: #ffffff;
  border: 1px solid var(--noel-border);
  border-radius: 20px;
  box-shadow: var(--noel-shadow);
}

.bdc-page--noel .bdc-card {
  padding: clamp(1.1rem, 2.6vw, 1.8rem);
}

.bdc-page--noel .bdc-summary-card {
  position: sticky;
  top: 1rem;
  padding: 1.35rem;
}

/* --- En-tête intégré à la colonne de gauche --- */
.noel-bdc-header {
  display: grid;
  grid-template-columns: 142px minmax(0, 1fr);
  gap: 1rem 1.25rem;
  align-items: center;
  padding-bottom: 1.15rem;
  margin-bottom: 1.15rem;
  border-bottom: 1px solid var(--noel-border);
}

.noel-bdc-header__hat {
  display: flex;
  align-items: center;
  justify-content: center;
}

.noel-bdc-header__hat .noel-hat {
  width: 100%;
  max-width: 142px;
  height: auto;
  display: block;
}

.noel-kicker {
  margin: 0 0 0.35rem;
  color: var(--noel-red);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  line-height: 1.4;
  text-transform: uppercase;
}

.noel-bdc-header h1 {
  margin: 0 0 0.45rem;
  color: var(--noel-red);
  font-size: clamp(1.65rem, 3.3vw, 2.35rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
}

.noel-title-gradient {
  display: inline;
  background: var(--noel-title-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: var(--noel-red);
  text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.35),
    0 6px 18px rgba(158, 31, 50, 0.14);
}

@supports not (-webkit-background-clip: text) {
  .noel-title-gradient {
    -webkit-text-fill-color: currentColor;
    color: var(--noel-red);
  }
}

.noel-bdc-subtitle {
  margin: 0;
  color: var(--noel-muted);
  font-size: 0.92rem;
  line-height: 1.55;
}

/* --- Rappel du chapeau --- */
.noel-hat-note {
  margin: 0 0 1.3rem;
  padding: 0.9rem 1rem;
  background: linear-gradient(135deg, #fffaf0, #fff4d6);
  border: 1px solid rgba(216, 166, 58, 0.45);
  border-left: 5px solid var(--noel-gold);
  border-radius: 14px;
}

.noel-hat-note h2 {
  margin: 0 0 0.3rem;
  color: var(--noel-red);
  font-size: 1.02rem;
  font-weight: 900;
  letter-spacing: 0.01em;
  line-height: 1.35;
}

.noel-hat-note p {
  margin: 0;
  color: #5c4322;
  font-size: 0.9rem;
  line-height: 1.55;
}

.noel-form-title {
  margin: 0 0 1rem;
  color: var(--noel-ink);
  font-size: 1.3rem;
  line-height: 1.25;
}

.bdc-page--noel .form-section {
  margin-bottom: 1.4rem;
  padding-bottom: 1.35rem;
  border-bottom: 1px solid var(--noel-border);
}

.bdc-page--noel .form-section:last-of-type {
  border-bottom: 0;
  padding-bottom: 0;
}

.bdc-page--noel .form-section h3 {
  margin: 0 0 0.9rem;
  color: var(--noel-green);
  font-size: 1rem;
  font-weight: 800;
  line-height: 1.35;
}

.bdc-page--noel .form-group {
  margin-bottom: 0.9rem;
}

.bdc-page--noel .form-group:last-child {
  margin-bottom: 0;
}

.bdc-page--noel .form-group label {
  color: var(--noel-ink);
  font-size: 0.86rem;
  font-weight: 800;
}

.bdc-page--noel .form-group input {
  border: 1px solid #d8cbe2;
  border-radius: 10px;
  background: #fff;
  color: var(--noel-ink);
  font-size: 1rem;
}

.bdc-page--noel .form-group input:focus {
  outline: 3px solid rgba(216, 166, 58, 0.28);
  outline-offset: 1px;
  border-color: var(--noel-gold);
}

.bdc-page--noel .form-group input.input-error {
  border-color: #b42318;
  box-shadow: 0 0 0 3px rgba(180, 35, 24, 0.12);
}

.bdc-page--noel .form-error {
  color: #b00020;
  font-weight: 700;
}

/* --- Cartes de mode et de formule --- */
.noel-choices,
.noel-formulas {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.noel-choice,
.noel-formula {
  display: flex;
  align-items: flex-start;
  gap: 0.8rem;
  padding: 0.95rem 1rem;
  background: #fff;
  border: 2px solid var(--noel-border);
  border-radius: 14px;
  cursor: pointer;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    background 0.2s ease;
}

.noel-choice:hover,
.noel-formula:hover {
  border-color: #c8b7d9;
}

.noel-choice.selected,
.noel-formula.selected {
  border-color: var(--noel-red);
  background: #fcf7fc;
  box-shadow: 0 6px 18px rgba(158, 31, 50, 0.12);
}

.noel-choice input,
.noel-formula input {
  margin-top: 0.3rem;
  flex: 0 0 auto;
  accent-color: var(--noel-red);
}

.noel-choice__body,
.noel-formula__body {
  flex: 1 1 auto;
  min-width: 0;
}

.noel-choice__title {
  display: block;
  color: var(--noel-ink);
  font-size: 0.93rem;
  font-weight: 700;
  line-height: 1.45;
}

.noel-formula__title {
  display: block;
  color: var(--noel-green);
  font-size: 1rem;
  font-weight: 900;
  line-height: 1.35;
  letter-spacing: 0.01em;
}

.noel-formula__desc {
  display: block;
  margin-top: 0.28rem;
  color: var(--noel-muted);
  font-size: 0.88rem;
  line-height: 1.5;
}

.noel-formula__price {
  display: block;
  margin-top: 0.35rem;
  color: var(--noel-red);
  font-size: 1.18rem;
  font-weight: 900;
  line-height: 1.25;
}

.noel-formula--privilege {
  background: linear-gradient(180deg, #fffdf4, #fff8e6);
}

.noel-formula-badge {
  display: inline-block;
  margin-left: 0.35rem;
  padding: 0.12rem 0.5rem;
  background: #fff0d0;
  border: 1px solid rgba(216, 166, 58, 0.55);
  border-radius: 100px;
  color: #7a4f12;
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.03em;
  vertical-align: middle;
  text-transform: uppercase;
}

.noel-support-note {
  margin: 0.85rem 0 0;
  padding: 0.85rem 0.95rem;
  background: #f7f3f9;
  border-left: 4px solid var(--noel-green);
  border-radius: 10px;
  color: var(--noel-green);
  font-size: 0.9rem;
  line-height: 1.55;
}

/* --- Contribution personnalisée --- */
.noel-custom-amount {
  margin-top: 0.85rem;
  padding: 1rem;
  border: 2px solid rgba(216, 166, 58, 0.7);
  border-radius: 14px;
  background: #fffaf0;
}

.noel-custom-amount label {
  color: var(--noel-green);
  font-size: 0.86rem;
  font-weight: 800;
}

.noel-custom-input-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.noel-custom-input-row input {
  flex: 1 1 auto;
  min-width: 0;
}

.noel-custom-input-row .euro-symbol {
  color: var(--noel-green);
  font-size: 1.35rem;
  font-weight: 900;
}

.noel-custom-hint {
  margin: 0.4rem 0 0;
  color: var(--noel-muted);
  font-size: 0.8rem;
  line-height: 1.45;
}

/* --- Cadeau de Noël d'Alexandre --- */
.noel-gift-box {
  margin-top: 0.95rem;
  padding: 1rem;
  border: 2px solid rgba(216, 166, 58, 0.65);
  border-radius: 16px;
  background: linear-gradient(180deg, #fffdf4, #fff7df);
}

.noel-gift-box[hidden] {
  display: none;
}

.noel-gift-box-header {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  margin-bottom: 0.45rem;
}

.noel-gift-box-header .noel-gift {
  width: 58px;
  height: auto;
  flex: 0 0 auto;
}

.noel-gift-box h3 {
  margin: 0;
  color: var(--noel-red);
  font-size: 1.05rem;
  line-height: 1.3;
}

.noel-gift-box p {
  margin: 0.45rem 0;
  color: #5a4321;
  font-size: 0.9rem;
  line-height: 1.55;
}

.noel-highlight {
  color: var(--noel-red);
  font-weight: 800;
}

.noel-price-compare {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  margin: 0.7rem 0;
}

.noel-price-old,
.noel-price-new {
  position: relative;
  display: inline-block;
  font-size: clamp(2.2rem, 7vw, 2.8rem);
  line-height: 1;
  font-weight: 900;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.noel-price-old {
  color: var(--noel-red);
}

.noel-price-old::before,
.noel-price-old::after {
  content: '';
  position: absolute;
  z-index: 1;
  left: -6%;
  top: 50%;
  width: 112%;
  height: 4px;
  background: #4a4a4a;
  border-radius: 2px;
  pointer-events: none;
}

.noel-price-old::before {
  transform: rotate(26deg);
}

.noel-price-old::after {
  transform: rotate(-26deg);
}

.noel-price-new {
  color: var(--noel-green);
}

.noel-saving {
  margin: 0;
  color: var(--noel-green);
  font-size: 0.98rem;
  font-weight: 800;
}

.noel-gift-final {
  margin-top: 0.55rem;
  color: var(--noel-red);
  font-size: 1rem;
  font-weight: 800;
  line-height: 1.45;
}

.noel-gift-small {
  color: #7a6a58;
  font-size: 0.78rem;
  line-height: 1.45;
}

/* --- Bouton et mentions --- */
.noel-submit {
  width: 100%;
  min-height: 56px;
  border: 0;
  border-radius: 12px;
  padding: 0.95rem 1.25rem;
  background: linear-gradient(135deg, #9e1f32, #c7304a);
  color: #fff;
  font-size: 1.02rem;
  font-weight: 900;
  letter-spacing: 0.02em;
  line-height: 1.3;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(158, 31, 50, 0.25);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    background 0.2s ease;
}

.noel-submit:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(158, 31, 50, 0.3);
}

.noel-submit:disabled {
  background: #c9c0cf;
  box-shadow: none;
  cursor: not-allowed;
  opacity: 0.8;
}

.noel-secure {
  margin: 0.55rem 0 0;
  text-align: center;
  color: var(--noel-muted);
  font-size: 0.86rem;
}

.noel-support {
  margin: 0.9rem 0 0;
  color: var(--noel-muted);
  font-size: 0.86rem;
  line-height: 1.55;
  text-align: center;
}

.noel-support a {
  color: var(--noel-red);
  font-weight: 700;
}

/* --- Récapitulatif --- */
.noel-summary-card .product-badge {
  display: inline-block;
  margin-bottom: 0.65rem;
  padding: 0.25rem 0.65rem;
  background: var(--noel-red);
  color: #fff;
  border-radius: 100px;
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.noel-summary-card h2 {
  margin: 0 0 0.35rem;
  color: var(--noel-red);
  font-size: 1.2rem;
  line-height: 1.25;
}

.noel-summary-date {
  margin: 0 0 0.85rem;
  color: var(--noel-muted);
  font-size: 0.86rem;
  line-height: 1.5;
}

.noel-summary-list {
  list-style: none;
  margin: 0 0 0.85rem;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.noel-summary-list li {
  position: relative;
  padding-left: 1.1rem;
  color: var(--noel-ink);
  font-size: 0.9rem;
  line-height: 1.45;
}

.noel-summary-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.5em;
  width: 6px;
  height: 6px;
  background: var(--noel-gold);
  border-radius: 50%;
}

.noel-summary-bonus {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin: 0.9rem 0;
  padding: 0.7rem;
  background: #fff8e6;
  border: 1px solid rgba(216, 166, 58, 0.65);
  border-radius: 12px;
  color: var(--noel-red);
  font-size: 0.86rem;
  font-weight: 900;
  line-height: 1.35;
}

.noel-summary-bonus .noel-gift {
  width: 42px;
  height: auto;
  flex: 0 0 auto;
}

.noel-summary-guide {
  margin: 0 0 0.75rem;
  padding: 0.55rem 0.7rem;
  background: #eef6f1;
  border-radius: 9px;
  color: var(--noel-green);
  font-size: 0.84rem;
  font-weight: 800;
  line-height: 1.4;
}

.noel-summary-guide[hidden] {
  display: none;
}

.noel-summary-line {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.55rem 0;
  border-top: 1px solid #eee;
  color: var(--noel-ink);
  font-size: 0.9rem;
  line-height: 1.4;
}

.noel-summary-line strong {
  color: var(--noel-green);
  font-weight: 800;
  text-align: right;
}

.noel-summary-total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  margin-top: 0.6rem;
  padding-top: 0.8rem;
  border-top: 2px solid var(--noel-border);
  color: var(--noel-green);
  font-size: 0.96rem;
  font-weight: 800;
}

.noel-summary-total__amount {
  color: var(--noel-red);
  font-size: 1.65rem;
  font-weight: 900;
  line-height: 1.1;
}

.noel-summary-note {
  margin: 0.75rem 0 0;
  color: var(--noel-muted);
  font-size: 0.78rem;
  line-height: 1.45;
}

/* --- Téléphone international --- */
.noel-phone .iti {
  width: 100%;
}

.noel-phone .iti__country-list {
  z-index: 40;
}

/* --- Modale de confirmation 500 € --- */
.noel-dialog {
  position: fixed;
  inset: 0;
  width: min(92vw, 540px);
  max-width: 540px;
  max-height: calc(100vh - 2rem);
  margin: auto;
  padding: 0;
  overflow: auto;
  border: 1px solid rgba(216, 166, 58, 0.6);
  border-radius: 20px;
  background: #fff;
  color: var(--noel-ink);
  box-shadow: 0 24px 70px rgba(44, 46, 53, 0.28);
}

.noel-dialog::backdrop {
  background: rgba(44, 46, 53, 0.55);
  backdrop-filter: blur(2px);
}

.noel-dialog__body {
  padding: 1.35rem 1.35rem 1.2rem;
}

.noel-dialog__eyebrow {
  margin: 0 0 0.35rem;
  color: var(--noel-gold);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.noel-dialog h2 {
  margin: 0 0 0.65rem;
  color: var(--noel-red);
  font-size: 1.3rem;
  line-height: 1.3;
}

.noel-dialog p {
  margin: 0;
  color: var(--noel-ink);
  font-size: 0.96rem;
  line-height: 1.6;
}

.noel-dialog__amount {
  color: var(--noel-red);
  font-weight: 900;
}

.noel-dialog__actions {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  padding: 0 1.35rem 1.35rem;
}

.noel-dialog__confirm,
.noel-dialog__cancel {
  width: 100%;
  min-height: 50px;
  border-radius: 11px;
  padding: 0.8rem 1rem;
  font-family: inherit;
  font-size: 0.94rem;
  font-weight: 900;
  line-height: 1.3;
  cursor: pointer;
}

.noel-dialog__confirm {
  border: 0;
  background: linear-gradient(135deg, #9e1f32, #c7304a);
  color: #fff;
  box-shadow: 0 8px 20px rgba(158, 31, 50, 0.24);
}

.noel-dialog__cancel {
  appearance: none;
  border: 2px solid var(--noel-green);
  background: #f2f8f4;
  color: var(--noel-green);
}

.noel-dialog__confirm:focus-visible,
.noel-dialog__cancel:focus-visible {
  outline: 3px solid var(--noel-gold);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  .noel-submit,
  .noel-choice,
  .noel-formula {
    transition: none;
  }
}

@media (max-width: 992px) {
  .bdc-page--noel .bdc-grid {
    grid-template-columns: 1fr;
  }

  .bdc-page--noel .bdc-summary-card {
    position: static;
  }
}

@media (max-width: 640px) {
  .bdc-page--noel {
    padding: 0.75rem 0 2.5rem;
  }

  .bdc-page--noel .bdc-card,
  .bdc-page--noel .bdc-summary-card {
    border-radius: 0;
    border: 0;
    box-shadow: none;
  }

  .noel-bdc-header {
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 0.7rem;
  }

  .noel-bdc-header__hat .noel-hat {
    max-width: 96px;
  }

  .noel-bdc-header h1 {
    font-size: 1.55rem;
  }

  .noel-bdc-subtitle {
    font-size: 0.84rem;
  }

  .noel-price-old,
  .noel-price-new {
    font-size: 2rem;
  }

  .bdc-page--noel .form-row {
    grid-template-columns: 1fr;
    gap: 0;
  }
}
