/* Portail client — auth Lagoon Continuity (login / register) */
body.client-auth {
  font-family: var(--fb, 'Figtree', sans-serif);
  color: var(--ink, #0c4a6e);
  min-height: 100vh;
  margin: 0;
  background:
    radial-gradient(900px 480px at 0% 0%, var(--line, #bae6fd) 0%, transparent 55%),
    radial-gradient(700px 400px at 100% 10%, var(--sand, #fef3c7) 0%, transparent 45%),
    linear-gradient(180deg, var(--bg-mid, #e0f2fe), var(--bg, #f0f9ff) 40%, var(--bg-wash, #f8fafc));
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
}

body.client-auth a {
  color: var(--deep, #075985);
  font-weight: 600;
  text-decoration: none;
}

body.client-auth a:hover {
  text-decoration: underline;
}

.cl-shell {
  flex: 1;
  display: grid;
  place-items: center;
  padding: clamp(20px, 4vw, 48px) 16px 32px;
}

.cl-panel {
  width: 100%;
  max-width: 420px;
  background: var(--panel, #fff);
  border: 1px solid rgba(var(--accent-rgb, 14, 165, 233), .28);
  border-radius: var(--radius, 22px);
  box-shadow: var(--shadow, 0 16px 40px rgba(14, 165, 233, .12));
  padding: clamp(1.5rem, 3vw, 2rem);
}

.cl-panel--wide {
  max-width: 520px;
}

.cl-brand {
  display: flex;
  align-items: center;
  gap: .75rem;
  margin-bottom: 1.35rem;
}

.cl-brand--logo {
  display: block;
  width: 160px;
  height: 160px;
  margin: 0 auto 1.6rem auto;
  border-radius: 50%;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .18);
}

.cl-brand-logo {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  background: #000;
}

.cl-mark {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--accent, #0ea5e9), var(--deep, #075985));
  display: grid;
  place-items: center;
  color: #fff;
  font-family: var(--fd, 'Literata', serif);
  font-weight: 700;
  font-size: 1.35rem;
  box-shadow: 0 8px 20px rgba(var(--accent-rgb, 14, 165, 233), .28);
  flex-shrink: 0;
}

.cl-brand-name {
  font-family: var(--fd, 'Literata', serif);
  font-weight: 700;
  font-size: 1.35rem;
  color: var(--deep, #075985);
  line-height: 1.15;
}

.cl-brand-tag {
  font-size: .78rem;
  color: var(--soft, #64748b);
  font-weight: 600;
  margin-top: .15rem;
}

.cl-panel h1 {
  font-family: var(--fd, 'Literata', serif);
  font-size: 1.55rem;
  margin: 0 0 .4rem;
  color: var(--deep, #075985);
  letter-spacing: -.02em;
}

.cl-lead {
  margin: 0 0 1.25rem;
  color: var(--soft, #64748b);
  font-size: .95rem;
  line-height: 1.45;
}

.cl-alert {
  display: flex;
  gap: .65rem;
  align-items: flex-start;
  border-radius: 14px;
  padding: .75rem .9rem;
  margin-bottom: 1.1rem;
  font-size: .84rem;
  line-height: 1.4;
}

.cl-alert b {
  display: block;
  margin-bottom: .15rem;
}

.cl-alert--pending {
  background: color-mix(in srgb, var(--sand, #fef3c7) 70%, #fff);
  border: 1px solid #fcd34d;
  color: #92400e;
}

.cl-alert--pending b {
  color: #78350f;
}

.cl-alert--error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #991b1b;
}

.cl-alert--error b {
  color: #7f1d1d;
}

.cl-alert--ok {
  background: color-mix(in srgb, var(--ok, #059669) 12%, #fff);
  border: 1px solid color-mix(in srgb, var(--ok, #059669) 35%, #fff);
  color: #065f46;
}

.cl-alert--ok b {
  color: #064e3b;
}

.cl-field {
  margin-bottom: 1rem;
}

.cl-field label {
  display: block;
  font-size: .82rem;
  font-weight: 700;
  color: var(--muted, #0369a1);
  margin-bottom: .35rem;
}

.cl-field input {
  width: 100%;
  padding: .8rem .95rem;
  border-radius: 14px;
  border: 1px solid var(--line, #bae6fd);
  background: var(--bg-wash, #f8fafc);
  font: inherit;
  font-size: 1rem;
  color: var(--ink, #0c4a6e);
  outline: none;
  transition: border-color .15s, box-shadow .15s;
  box-sizing: border-box;
}

.cl-field input:focus {
  border-color: var(--accent, #0ea5e9);
  box-shadow: 0 0 0 3px rgba(var(--accent-rgb, 14, 165, 233), .18);
  background: #fff;
}

.cl-field input::placeholder {
  color: #94a3b8;
}

.cl-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 1rem;
}

.cl-addr-wrap {
  position: relative;
}

.cl-suggest {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 2px);
  z-index: 30;
  list-style: none;
  margin: 0;
  padding: .35rem 0;
  background: #fff;
  border: 1px solid var(--line, #bae6fd);
  border-radius: 14px;
  box-shadow: 0 12px 28px rgba(var(--accent-rgb, 14, 165, 233), .18);
  max-height: 220px;
  overflow: auto;
}

.cl-suggest li {
  padding: .55rem .9rem;
  font-size: .9rem;
  cursor: pointer;
  color: var(--ink, #0c4a6e);
}

.cl-suggest li:hover,
.cl-suggest li.is-active {
  background: color-mix(in srgb, var(--accent, #0ea5e9) 12%, #fff);
  color: var(--deep, #075985);
}

.cl-field-hint {
  margin: .35rem 0 0;
  font-size: .78rem;
  color: var(--soft, #64748b);
  line-height: 1.35;
}

.cl-field input[readonly] {
  background: color-mix(in srgb, var(--bg-mid, #e0f2fe) 55%, #fff);
  color: var(--deep, #075985);
  cursor: default;
}

.cl-check {
  display: flex;
  align-items: flex-start;
  gap: .65rem;
  margin: .85rem 0 1rem;
  cursor: pointer;
  font-size: .9rem;
  font-weight: 600;
  color: var(--ink, #0c4a6e);
}

.cl-check input {
  width: 17px;
  height: 17px;
  margin-top: 2px;
  accent-color: var(--accent, #0ea5e9);
  flex: 0 0 auto;
}

.cl-check small {
  display: block;
  font-weight: 400;
  color: var(--soft, #64748b);
  font-size: .78rem;
  margin-top: .15rem;
  line-height: 1.35;
}

.cl-delivery-block {
  margin: 0 0 1rem;
  padding: .85rem 1rem 1rem;
  border: 1px solid color-mix(in srgb, var(--accent, #0ea5e9) 22%, #fff);
  border-radius: 16px;
  background: color-mix(in srgb, var(--bg-mid, #e0f2fe) 35%, #fff);
}

.cl-delivery-title {
  margin: 0 0 .65rem;
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .02em;
  text-transform: uppercase;
  color: var(--deep, #075985);
}

.cl-btn {
  width: 100%;
  border: 0;
  cursor: pointer;
  font: inherit;
  font-weight: 700;
  font-size: 1rem;
  padding: .95rem 1.1rem;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, var(--accent, #0ea5e9), var(--deep, #075985));
  box-shadow: 0 10px 24px rgba(var(--accent-rgb, 14, 165, 233), .28);
  transition: transform .15s, filter .15s;
}

.cl-btn:hover {
  filter: brightness(1.05);
  transform: translateY(-1px);
}

.cl-links {
  margin-top: 1.25rem;
  padding-top: 1.1rem;
  border-top: 1px solid rgba(var(--accent-rgb, 14, 165, 233), .15);
  display: flex;
  flex-wrap: wrap;
  gap: .5rem 1rem;
  justify-content: center;
  font-size: .88rem;
  color: var(--soft, #64748b);
}

.cl-links a {
  color: var(--deep, #075985);
}

/* ── Modal choix Gestion / Boutique (hors panneau login) ── */
body.client-auth.is-staff-choice {
  overflow: hidden;
  /* Firefox : body flex + enfant fixed = modal collée en bas */
  display: block;
}
/* Ne pas filtrer le shell : en Firefox, filter sur un ancêtre / voisin flex
   peut casser le centrage de la modal fixed. Le fond sombre suffit. */
body.client-auth.is-staff-choice .cl-shell {
  pointer-events: none;
  user-select: none;
}

.cl-staff-choice {
  /* Firefox : un fixed enfant d’un body flex se retrouve souvent en bas
     si on compte seulement sur inset + grid. Forcer le viewport. */
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  height: 100dvh !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  z-index: 9999 !important;
  box-sizing: border-box !important;
  /* Sortir du layout flex du body */
  flex: none !important;
  align-self: auto !important;
  order: 0 !important;
  display: block !important;
}
.cl-staff-choice__backdrop {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(8, 47, 73, .58);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.cl-staff-choice__dialog {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
  width: min(420px, calc(100vw - 2.5rem));
  max-height: min(90vh, 90dvh);
  overflow: auto;
  background: #fff;
  border-radius: 24px;
  border: 1px solid rgba(14, 165, 233, .22);
  box-shadow:
    0 4px 6px rgba(8, 47, 73, .06),
    0 28px 64px rgba(8, 47, 73, .35);
  padding: 1.65rem 1.4rem 1.4rem;
  text-align: center;
  animation: clStaffChoiceIn .28s ease-out;
}
@keyframes clStaffChoiceIn {
  from { opacity: 0; transform: translate(-50%, calc(-50% + 12px)) scale(.97); }
  to { opacity: 1; transform: translate(-50%, -50%); }
}
.cl-staff-choice__badge {
  display: inline-block;
  margin: 0 0 .65rem;
  padding: .28rem .7rem;
  border-radius: 999px;
  font-size: .7rem;
  font-weight: 800;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: #075985;
  background: #e0f2fe;
}
.cl-staff-choice__title {
  margin: 0;
  font-family: var(--fd, 'Literata', Georgia, serif);
  font-size: clamp(1.35rem, 4vw, 1.6rem);
  font-weight: 700;
  line-height: 1.25;
  color: #0c4a6e;
}
.cl-staff-choice__lead {
  margin: .55rem 0 1.35rem;
  font-size: .95rem;
  line-height: 1.45;
  color: #64748b;
}
.cl-staff-choice__lead strong {
  color: #0c4a6e;
  font-weight: 700;
}
.cl-staff-choice__grid {
  display: grid;
  gap: .75rem;
}
.cl-staff-choice__opt {
  display: flex;
  align-items: center;
  gap: 1rem;
  width: 100%;
  margin: 0;
  padding: 1rem 1.05rem;
  text-align: left;
  border-radius: 16px;
  border: 1.5px solid #e2e8f0;
  background: #f8fafc;
  cursor: pointer;
  font: inherit;
  color: inherit;
  appearance: none;
  -webkit-appearance: none;
  transition: border-color .15s, box-shadow .15s, transform .15s, background .15s;
}
.cl-staff-choice__opt:hover,
.cl-staff-choice__opt:focus-visible {
  outline: none;
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(14, 165, 233, .18);
}
.cl-staff-choice__opt--gestion:hover,
.cl-staff-choice__opt--gestion:focus-visible {
  border-color: #38bdf8;
  background: linear-gradient(135deg, #f0f9ff, #fff);
}
.cl-staff-choice__opt--boutique:hover,
.cl-staff-choice__opt--boutique:focus-visible {
  border-color: #34d399;
  background: linear-gradient(135deg, #ecfdf5, #fff);
}
.cl-staff-choice__opt-ico {
  flex: 0 0 auto;
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: #fff;
}
.cl-staff-choice__opt--gestion .cl-staff-choice__opt-ico {
  background: linear-gradient(145deg, #0ea5e9, #0369a1);
  box-shadow: 0 8px 18px rgba(14, 165, 233, .35);
}
.cl-staff-choice__opt--boutique .cl-staff-choice__opt-ico {
  background: linear-gradient(145deg, #34d399, #059669);
  box-shadow: 0 8px 18px rgba(5, 150, 105, .3);
}
.cl-staff-choice__opt-txt {
  display: grid;
  gap: .2rem;
  min-width: 0;
}
.cl-staff-choice__opt-txt strong {
  display: block;
  font-size: 1.05rem;
  font-weight: 700;
  color: #0c4a6e;
}
.cl-staff-choice__opt-txt span {
  display: block;
  font-size: .82rem;
  line-height: 1.35;
  color: #64748b;
}

@media (max-width: 420px) {
  .cl-panel {
    border-radius: 18px;
    padding: 1.25rem;
  }

  .cl-panel h1 {
    font-size: 1.35rem;
  }

  .cl-grid-2 {
    grid-template-columns: 1fr;
  }

  .cl-staff-choice__dialog {
    padding: 1.35rem 1.1rem 1.15rem;
  }
}
