@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@300;400;600&family=DM+Sans:wght@300;400;500&display=swap');

/* ===== BASE ===== */
body {
  margin: 0;
  padding: 0;
  background-color: #080808;
  color: #F2F4F3;
  font-family: 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
  min-height: 100vh;
}

main {
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem 1rem 4rem;
}

/* ===== CONTAINER ===== */
.options-container {
  max-width: 560px;
  margin: 60px auto;
  padding: 48px 44px;
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(198, 172, 142, 0.15);
  border-radius: 24px;
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.03) inset,
    0 40px 80px rgba(0,0,0,0.6),
    0 0 60px rgba(198,172,142,0.04);
  position: relative;
}

/* Reflet haut */
.options-container::before {
  content: '';
  position: absolute;
  top: 0; left: 10%; right: 10%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(198,172,142,0.5), transparent);
}

/* ===== TITRE ===== */
.options-container h2 {
  font-family: 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
  font-weight: 500;
  font-size: 1.5rem;
  letter-spacing: 0.05em;
  color: #F2F4F3;
  margin: 0 0 36px;
  padding-bottom: 20px;
  border-bottom: 1px solid rgba(198, 172, 142, 0.12);
  display: flex;
  align-items: center;
  gap: 10px;
}

/* ===== GROUPES D'OPTIONS ===== */
.option-group {
  margin-bottom: 32px;
}

.option-group label {
  display: block;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(198, 172, 142, 0.8);
  margin-bottom: 14px;
}

/* ===== AVATAR ===== */
.avatar-preview {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  border: 1px solid rgba(198, 172, 142, 0.3);
  object-fit: cover;
  display: block;
  margin: 0 auto 20px;
  background-color: #111;
  box-shadow: 0 0 0 4px rgba(198, 172, 142, 0.06);
}

/* ===== INPUT FILE ===== */
input[type="file"] {
  width: 100%;
  margin-bottom: 14px;
  color: rgba(242, 244, 243, 0.5);
  font-family: 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
  font-size: 0.85rem;
  cursor: pointer;
}

input[type="file"]::file-selector-button {
  background: rgba(198, 172, 142, 0.08);
  border: 1px solid rgba(198, 172, 142, 0.2);
  color: #C6AC8E;
  padding: 8px 14px;
  border-radius: 8px;
  font-family: 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
  font-size: 0.85rem;
  cursor: pointer;
  margin-right: 12px;
  transition: background 0.2s ease;
}

input[type="file"]::file-selector-button:hover {
  background: rgba(198, 172, 142, 0.14);
}

/* ===== BOUTONS ===== */
button.save-btn {
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, #C6AC8E 0%, #e8d5b8 50%, #C6AC8E 100%);
  background-size: 200% 200%;
  border: none;
  border-radius: 12px;
  font-family: 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: 0.05em;
  color: #1a1410;
  cursor: pointer;
  transition: background-position 0.4s ease, transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 4px 20px rgba(198,172,142,0.2);
}

button.save-btn:hover {
  background-position: 100% 100%;
  transform: translateY(-1px);
  box-shadow: 0 8px 30px rgba(198,172,142,0.3);
}

button.save-btn:active {
  transform: translateY(0);
}

button.btn-warning {
  background: rgba(198, 172, 142, 0.08);
  background-image: none;
  border: 1px solid rgba(198, 172, 142, 0.25);
  color: #C6AC8E;
  box-shadow: none;
}

button.btn-warning:hover {
  background: rgba(198, 172, 142, 0.14);
  background-position: unset;
  box-shadow: none;
  transform: translateY(-1px);
}

/* ===== LIEN RETOUR ===== */
.back-link {
  display: block;
  text-align: center;
  margin-top: 24px;
  color: rgba(242, 244, 243, 0.35);
  text-decoration: none;
  font-size: 0.85rem;
  letter-spacing: 0.03em;
  transition: color 0.2s ease;
}

.back-link:hover {
  color: rgba(198, 172, 142, 0.8);
}

/* ===== QR CODE CONTAINER ===== */
#qrCodeContainer {
  margin-top: 20px;
  padding: 24px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(198, 172, 142, 0.12);
  border-radius: 14px;
  text-align: center;
  color: #F2F4F3;
  font-size: 0.9rem;
  line-height: 1.6;
}

#qrCodeContainer input[type="text"] {
  padding: 10px 14px;
  width: 120px;
  text-align: center;
  color: #F2F4F3;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(198,172,142,0.2);
  border-radius: 8px;
  font-family: 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
  font-size: 1.1rem;
  letter-spacing: 4px;
  outline: none;
  margin: 8px 0;
}

#qrCodeContainer button {
  padding: 10px 20px;
  background: rgba(198, 172, 142, 0.1);
  border: 1px solid rgba(198, 172, 142, 0.25);
  color: #C6AC8E;
  border-radius: 8px;
  font-family: 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
  font-weight: 500;
  cursor: pointer;
  margin-left: 8px;
  transition: background 0.2s ease;
}

#qrCodeContainer button:hover {
  background: rgba(198, 172, 142, 0.18);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 600px) {
  .options-container {
    margin: 30px auto;
    padding: 36px 24px;
    border-radius: 18px;
  }
}
/* ===== TOAST NOTIFICATIONS ===== */
#toast-container {
  position: fixed;
  bottom: 28px;
  right: 28px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.toast {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  border-radius: 14px;
  background: rgba(18, 18, 18, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.07);
  box-shadow: 0 16px 48px rgba(0,0,0,0.55), 0 0 0 1px rgba(255,255,255,0.03) inset;
  font-size: 0.88rem;
  color: #F2F4F3;
  font-family: 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
  letter-spacing: 0.02em;
  min-width: 240px;
  max-width: 340px;
  pointer-events: all;
  transform: translateX(120%);
  opacity: 0;
  transition: transform 380ms cubic-bezier(0.22, 1, 0.36, 1), opacity 320ms ease;
  position: relative;
  overflow: hidden;
}

.toast.show {
  transform: translateX(0);
  opacity: 1;
}

.toast.hide {
  transform: translateX(120%);
  opacity: 0;
}

/* Barre de progression en bas */
.toast::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  height: 2px;
  width: 100%;
  transform-origin: left;
  animation: toast-progress 3s linear forwards;
}

@keyframes toast-progress {
  from { transform: scaleX(1); }
  to   { transform: scaleX(0); }
}

/* Icône */
.toast-icon {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 1rem;
}

.toast-text {
  flex: 1;
  line-height: 1.45;
}

.toast-title {
  font-weight: 600;
  font-size: 0.85rem;
  margin-bottom: 2px;
}

.toast-msg {
  font-size: 0.8rem;
  opacity: 0.72;
}

/* ── Variantes ── */
.toast.success .toast-icon {
  background: rgba(134, 193, 118, 0.15);
  color: #86c176;
}
.toast.success::after {
  background: linear-gradient(90deg, #86c176, #a8d89a);
}
.toast.success {
  border-color: rgba(134, 193, 118, 0.18);
}

.toast.error .toast-icon {
  background: rgba(220, 80, 80, 0.15);
  color: #e07070;
}
.toast.error::after {
  background: linear-gradient(90deg, #e07070, #f09090);
}
.toast.error {
  border-color: rgba(220, 80, 80, 0.18);
}

.toast.info .toast-icon {
  background: rgba(198, 172, 142, 0.12);
  color: #C6AC8E;
}
.toast.info::after {
  background: linear-gradient(90deg, #C6AC8E, #e8d5b8);
}
.toast.info {
  border-color: rgba(198, 172, 142, 0.2);
}

@media (max-width: 600px) {
  #toast-container {
    bottom: 16px;
    right: 12px;
    left: 12px;
  }
  .toast {
    max-width: 100%;
    min-width: unset;
  }
}