/* Pages connexion/inscription (templates/customer/authentication.tpl,
   registration.tpl) -- meme skin "verre" que le reste du site.
   .auth-form contient les champs rendus par {form_field}, un helper
   Smarty du coeur PrestaShop (pas reecrit ici) : on ne connait pas a
   l'avance sa structure DOM exacte, donc les regles ci-dessous ciblent
   large (label/input/select generiques) plutot que des classes
   precises, pour rester robustes quel que soit le HTML genere. */

/* .auth-page = LE <main> qui contient tout (bulle/nav/header compris) --
   aucune contrainte de largeur ici : elle vivait avant sur ce meme
   element quand il ne contenait QUE le panneau, deplacee sur
   .auth-panel maintenant que la bulle/le header doivent rester
   full-bleed a l'interieur de ce meme bloc. */
.auth-page {
  position: relative;
  z-index: 1;
}

.auth-panel {
  /* max-width fixe (pas 8vw, qui grignotait l'essentiel de la largeur
     du panneau sur grand ecran -- 8vw ~= 133px de CHAQUE cote a 1660px,
     ne laissant qu'environ 294px de contenu reel dans un panneau cense
     faire 560px). width:min(...) plutot qu'un padding lateral separe
     sur le parent : sur petit ecran, ne depasse jamais 100% - 48px
     (24px de marge de chaque cote), sans avoir besoin d'une media query
     dediee. margin vertical : espace fixe sous le header, comme avant. */
  width: min(640px, 100% - 48px);
  margin: clamp(100px, 14vw, 160px) auto 100px;
  padding: clamp(32px, 5vw, 48px);
  border-radius: 32px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-top-color: rgba(255, 255, 255, 0.55);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.14), rgba(255, 255, 255, 0.04));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3), 0 20px 50px -15px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(20px) saturate(1.5);
  -webkit-backdrop-filter: blur(20px) saturate(1.5);
  box-sizing: border-box;
}

.auth-page--wide .auth-panel {
  width: min(760px, 100% - 48px);
}

.auth-panel__title {
  margin: 0 0 28px;
  font-family: "Libre Baskerville", serif;
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 700;
  color: #000000;
}

.auth-panel__intro {
  margin: -16px 0 24px;
  font-size: 14px;
  color: rgba(0, 0, 0, 0.75);
}

.auth-form__hint {
  margin: 6px 0 0;
  font-size: 12px;
  color: rgba(0, 0, 0, 0.55);
}

/* Notifications generiques du coeur (_partials/notifications.tpl),
   utilisees par plusieurs controleurs (ex: GuestTrackingController) qui
   n'assignent pas $errors['' ] comme le fait le formulaire de connexion. */
#notifications {
  margin-bottom: 20px;
}

#notifications .alert {
  padding: 10px 14px;
  margin-bottom: 8px;
  border-radius: 10px;
  color: #000000;
  font-size: 13px;
}

#notifications .alert ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

#notifications .alert-danger {
  background: rgba(200, 60, 60, 0.25);
  border: 1px solid rgba(200, 60, 60, 0.5);
}

#notifications .alert-success {
  background: rgba(60, 160, 90, 0.25);
  border: 1px solid rgba(60, 160, 90, 0.5);
}

#notifications .alert-warning,
#notifications .alert-info {
  background: rgba(200, 160, 60, 0.2);
  border: 1px solid rgba(200, 160, 60, 0.45);
}

/* Le partial core (login-form.tpl/customer-form.tpl) utilise la grille
   Bootstrap (.form-group.row > .col-md-3 label + .col-md-6 champ),
   pensee pour un container pleine largeur -- ecrasee ici en empilement
   simple (label au-dessus, champ pleine largeur), le panneau etant
   volontairement etroit (~560px, voir .auth-panel). Sans ca, les
   colonnes Bootstrap se retrouvaient ecrasees a 25%/50% d'un panneau
   deja etroit -- champs minuscules, labels qui retournent a la ligne
   caractere par caractere. */
.auth-form .form-group.row {
  display: block;
}

.auth-form [class*="col-md-"] {
  flex: none;
  max-width: 100%;
  width: 100%;
  padding-left: 0;
  padding-right: 0;
}

.auth-form label {
  display: block;
  text-align: left;
  margin: 16px 0 6px;
  font-size: 13px;
  font-weight: 600;
  color: rgba(0, 0, 0, 0.85);
}

.auth-form label:first-child {
  margin-top: 0;
}

.auth-form input[type="text"],
.auth-form input[type="email"],
.auth-form input[type="password"],
.auth-form input[type="tel"],
.auth-form input[type="date"],
.auth-form select,
.auth-form .form-control {
  width: 100%;
  box-sizing: border-box;
  padding: 12px 16px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.08);
  color: #000000;
  font-size: 14px;
}

.auth-form input::placeholder {
  color: rgba(0, 0, 0, 0.45);
}

.auth-form input[type="radio"],
.auth-form input[type="checkbox"] {
  margin-right: 8px;
}

.auth-form .radio,
.auth-form .checkbox {
  display: inline-flex;
  align-items: center;
  margin-right: 20px;
  font-size: 13px;
  color: rgba(0, 0, 0, 0.85);
}

.auth-form .help-block {
  margin: 10px 0;
}

.auth-form .help-block ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.auth-form .help-block li,
.auth-form .alert-danger {
  padding: 10px 14px;
  margin-bottom: 8px;
  border-radius: 10px;
  background: rgba(200, 60, 60, 0.25);
  border: 1px solid rgba(200, 60, 60, 0.5);
  color: #000000;
  font-size: 13px;
  list-style: none;
}

.auth-form .forgot-password {
  margin: 14px 0 20px;
  text-align: right;
  font-size: 13px;
}

.auth-form .forgot-password a {
  color: rgba(0, 0, 0, 0.75);
}

/* Le bouton "Enregistrer/Connexion" est celui du partial core, dans
   <footer class="form-footer">. On cible precisement CE bouton -- pas
   ".btn" tout court, qui matchait AUSSI le petit bouton "Montrer" du
   champ mot de passe (voir .input-group plus bas) et lui donnait la
   meme allure de gros bouton pilule, cassant son alignement. */
.auth-form footer.form-footer {
  display: flex;
  justify-content: center;
  margin-top: 10px;
}

.auth-form footer.form-footer .btn,
.auth-form button[type="submit"] {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 32px;
  margin-top: 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-top-color: rgba(255, 255, 255, 0.6);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.04));
  color: #000000;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  float: none !important;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.auth-form footer.form-footer .btn:hover,
.auth-form button[type="submit"]:hover {
  color: #ffffff;
  transform: scale(1.05);
  background: linear-gradient(180deg, rgba(35, 35, 224, 0.75), rgba(35, 35, 224, 0.55));
}

/* Champ mot de passe avec bouton "Montrer/Cacher" accole (markup
   Bootstrap .input-group) : le bouton doit rester petit et aligne a
   la meme hauteur que le champ, pas devenir un gros bouton pilule. */
.auth-form .input-group {
  display: flex;
  align-items: stretch;
}

.auth-form .input-group .form-control {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
  border-right: none;
}

.auth-form .input-group-btn {
  display: flex;
}

.auth-form .input-group-btn .btn {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  padding: 0 16px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-left: none;
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
  border-top-right-radius: 12px;
  border-bottom-right-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  color: rgba(0, 0, 0, 0.75);
  white-space: nowrap;
  cursor: pointer;
}

.auth-form .input-group-btn .btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #000000;
}

.auth-panel__switch {
  margin-top: 24px;
  font-size: 13px;
  color: rgba(0, 0, 0, 0.75);
  text-align: center;
}

.auth-panel__switch a {
  color: #6f7fff;
  font-weight: 600;
}

/* ---------- Page "Mon compte" (templates/customer/my-account.tpl) ---------- */

.account-links {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.account-link {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 20px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.08);
  color: #000000;
  text-decoration: none;
  transition: transform 0.2s ease, background 0.2s ease;
}

.account-link:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.16);
  color: #000000;
}

.account-link__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(35, 35, 224, 0.1);
  color: #2323e0;
}

.account-link__label {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
}

/* Liens injectes par des modules via le hook displayCustomerAccount
   (RGPD, listes de souhaits, alertes...) : markup fige cote module
   (<a class="col-lg-4..."><span class="link-item"><i class=
   "material-icons">icone</i> Libelle</span></a>), pense pour le theme
   parent -- jamais notre police "Material Icons" (pas chargee ici,
   d'ou le nom brut de l'icone affiche en clair). On applique le meme
   habillage .account-link a N'IMPORTE QUEL lien direct de la grille
   (le notre compris, deja stylee ci-dessus via sa propre classe), et
   on masque l'icone Material texte au profit d'un simple point --
   plus robuste que de dependre du nom exact de chaque module. */
.account-links > a {
  /* width/float:none -- neutralise les classes utilitaires Bootstrap
     (col-lg-4 col-md-6...) posees par certains modules sur ce hook,
     pensees pour la grille du theme parent (jamais chargee ici). */
  display: flex;
  align-items: center;
  width: auto;
  float: none;
  gap: 14px;
  padding: 18px 20px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.08);
  color: #000000 !important;
  text-decoration: none !important;
  transition: transform 0.2s ease, background 0.2s ease;
}

.account-links > a:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.16);
}

.account-links > a .link-item {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
}

.account-links > a .link-item i.material-icons {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(35, 35, 224, 0.1);
  /* Masque le nom brut de l'icone (police non chargee) : on affiche a
     la place un simple point centre, coherent avec le reste du site. */
  font-size: 0;
}

.account-links > a .link-item i.material-icons::after {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #2323e0;
}

@media (max-width: 600px) {
  .account-links {
    grid-template-columns: 1fr;
  }
}

/* ---------- Pages "Mes adresses" (addresses.tpl) ---------- */

.address-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
}

/* Markup fige cote coeur (customer/_partials/block-address.tpl) :
   <article class="address"><div class="address-body">...</div>
   <div class="address-footer">...</div></article> -- on l'habille tel
   quel plutot que de dupliquer ce partial. */
.address {
  padding: 20px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.08);
}

.address-body h4 {
  margin: 0 0 8px;
  font-size: 15px;
  font-weight: 700;
  color: #000000;
}

.address-body address {
  margin: 0;
  font-style: normal;
  font-size: 13px;
  line-height: 1.6;
  color: rgba(0, 0, 0, 0.75);
}

.address-footer {
  display: flex;
  gap: 16px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.25);
}

.address-footer a {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: #6f7fff;
}

.address-footer i.material-icons {
  /* Police non chargee ici -- masque le nom brut de l'icone, le
     libelle texte a cote suffit. */
  display: none;
}

/* ---------- Pages "Historique/Avoirs/Bons de reduction/Retours"
   (history.tpl, order-slip.tpl, discount.tpl, order-follow.tpl) ---------- */

.order-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.order-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.08);
}

.order-card__main {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1 1 160px;
}

.order-card__ref {
  font-size: 14px;
  font-weight: 700;
  color: #000000;
}

.order-card__ref a {
  color: #000000;
}

.order-card__date {
  font-size: 12px;
  color: rgba(0, 0, 0, 0.6);
}

.order-card__status {
  flex: 0 0 auto;
}

.order-card__badge {
  display: inline-block;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  color: #ffffff;
}

.order-card__badge--neutral {
  background: #2323e0;
}

.order-card__total {
  flex: 0 0 auto;
  font-size: 14px;
  font-weight: 700;
  color: #000000;
}

.order-card__meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1 1 220px;
  font-size: 12px;
  color: rgba(0, 0, 0, 0.65);
}

.order-card__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  flex: 0 0 auto;
  margin-left: auto;
}

.order-card__actions a {
  font-size: 13px;
  font-weight: 600;
  color: #6f7fff;
}

/* .order-card__main est parfois un lien direct (page "Mes alertes",
   voir ps_emailalerts/mailalerts-account.tpl) plutot qu'un simple div --
   neutralise le style de lien par defaut pour rester identique. */
a.order-card__main {
  text-decoration: none;
  color: inherit;
}

/* Vignette produit (page "Mes alertes") -- meme cadre que les autres
   petites vignettes du site (coins arrondis, fond verre). */
.alert-card__media {
  display: block;
  flex: 0 0 56px;
  width: 56px;
  height: 56px;
  border-radius: 12px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.15);
}

.alert-card__media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ---------- Sections de texte simples (page "Mes donnees
   personnelles", module psgdpr) ---------- */

.account-section {
  margin-bottom: 28px;
}

.account-section:last-of-type {
  margin-bottom: 0;
}

.account-section__title {
  margin: 0 0 10px;
  font-size: 16px;
  font-weight: 700;
  color: #000000;
}

.account-section__text {
  margin: 0 0 16px;
  font-size: 14px;
  line-height: 1.6;
  color: rgba(0, 0, 0, 0.75);
}

.account-section__text a {
  color: #6f7fff;
  font-weight: 600;
}

.account-section__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.auth-form-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-top-color: rgba(255, 255, 255, 0.6);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.04));
  color: #000000;
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.auth-form-btn:hover {
  color: #ffffff;
  transform: scale(1.05);
  background: linear-gradient(180deg, rgba(35, 35, 224, 0.75), rgba(35, 35, 224, 0.55));
}

