/* ==========================================================================
   Emily Rose Jewellery — feuille de style complémentaire
   Design system : ad.quiet-luxury · Plume Prune (prune / or / sable / creme)
   Règles : rayons 0–2 px, filets d'1 px à 12–18 %, profondeur plate,
   une seule ombre réservée aux surfaces superposées.
   ========================================================================== */

:root {
  --prune: #6b3a5a;
  --prune-clair: #8e5a78;
  --prune-fonce: #4a2740;
  --or: #a98c58;
  --or-clair: #c8ac7c;
  --or-fonce: #8a6f3e;
  --sable: #e8d7c7;
  --sable-clair: #f5ede4;
  --sable-ligne: #d8c4ae;
  --creme: #fbf7f2;
  --ardoise: #33222e;
  --ardoise-clair: #4a3742;
  --rayon: 2px;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  background-color: var(--creme);
  color: var(--ardoise);
  font-feature-settings: "kern", "liga";
}

/* --- Titres ------------------------------------------------------------ */

.font-display {
  font-family: "Gloock", Georgia, serif;
  letter-spacing: -0.01em;
}

.display-1 {
  font-family: "Gloock", Georgia, serif;
  font-weight: 400;
  font-size: clamp(2.75rem, 7vw, 5.5rem);
  line-height: 1;
  letter-spacing: -0.02em;
}

.display-2 {
  font-family: "Gloock", Georgia, serif;
  font-weight: 400;
  font-size: clamp(1.95rem, 3.6vw, 3.1rem);
  line-height: 1.08;
  letter-spacing: -0.015em;
}

.display-3 {
  font-family: "Gloock", Georgia, serif;
  font-weight: 400;
  font-size: clamp(1.3rem, 1.9vw, 1.7rem);
  line-height: 1.24;
}

/* --- Micro-titres ------------------------------------------------------ */

.micro {
  font-size: 0.6875rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 500;
}

.micro-or {
  color: var(--or-fonce);
}

/* --- Filets ------------------------------------------------------------ */

.rule {
  border: 0;
  border-top: 1px solid rgba(51, 34, 46, 0.14);
}

.rule-nuit {
  border: 0;
  border-top: 1px solid rgba(251, 247, 242, 0.14);
}

/* --- Lien actif -------------------------------------------------------- */

[aria-current="page"] {
  color: var(--or-fonce);
}

.on-ardoise [aria-current="page"] {
  color: var(--or-clair);
}

/* Lien de navigation : filet or qui s'étend au survol */
.nav-link {
  position: relative;
  display: inline-block;
  padding-bottom: 2px;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  height: 1px;
  width: 100%;
  background: var(--or);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.28s ease;
}

.nav-link:hover::after,
.nav-link:focus-visible::after,
[aria-current="page"].nav-link::after {
  transform: scaleX(1);
}

/* Lien de pied de page */
.foot-link {
  color: rgba(251, 247, 242, 0.68);
  transition: color 0.2s ease;
}

.foot-link:hover,
.foot-link:focus-visible {
  color: var(--or-clair);
}

/* --- Focus visible ----------------------------------------------------- */

:focus-visible {
  outline: 2px solid var(--or);
  outline-offset: 3px;
}

.on-creme :focus-visible {
  outline-color: var(--or-fonce);
}

.on-ardoise :focus-visible {
  outline-color: var(--or-clair);
}

/* --- Révélation au scroll (un seul driver de scroll) ------------------- */

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  html {
    scroll-behavior: auto;
  }
}

/* --- Séquence d'entrée du hero ----------------------------------------- */

.hero-enter > * {
  opacity: 0;
  transform: translateY(16px);
  animation: hero-in 0.85s cubic-bezier(0.2, 0.6, 0.25, 1) forwards;
}

.hero-enter > *:nth-child(1) { animation-delay: 0.05s; }
.hero-enter > *:nth-child(2) { animation-delay: 0.17s; }
.hero-enter > *:nth-child(3) { animation-delay: 0.29s; }
.hero-enter > *:nth-child(4) { animation-delay: 0.41s; }
.hero-enter > *:nth-child(5) { animation-delay: 0.53s; }

@keyframes hero-in {
  to {
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-enter > * {
    opacity: 1;
    transform: none;
    animation: none;
  }
}

/* --- Fiche produit ----------------------------------------------------- */

.produit {
  display: block;
}

.produit-media {
  overflow: hidden;
  background: var(--sable-clair);
}

.produit-media img {
  transition: transform 0.6s cubic-bezier(0.2, 0.6, 0.25, 1);
}

.produit:hover .produit-media img {
  transform: translateY(-4px) scale(1.015);
}

.produit-titre {
  position: relative;
  display: inline-block;
  padding-bottom: 3px;
}

.produit-titre::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  height: 1px;
  width: 100%;
  background: var(--or);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}

.produit:hover .produit-titre::after,
.produit:focus-visible .produit-titre::after {
  transform: scaleX(1);
}

/* --- Accordeons (details / summary) ------------------------------------ */

details.accordeon {
  border-top: 1px solid rgba(51, 34, 46, 0.14);
}

details.accordeon[open] {
  border-bottom: 1px solid rgba(51, 34, 46, 0.14);
}

details.accordeon > summary {
  cursor: pointer;
  list-style: none;
  padding: 1.15rem 0;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1.5rem;
}

details.accordeon > summary::-webkit-details-marker {
  display: none;
}

details.accordeon > summary::after {
  content: "+";
  font-family: "Jost", system-ui, sans-serif;
  font-size: 1.25rem;
  line-height: 1;
  color: var(--or-fonce);
  flex: none;
}

details.accordeon[open] > summary::after {
  content: "–";
}

/* --- Formulaires ------------------------------------------------------- */

.champ {
  width: 100%;
  background: transparent;
  border: 1px solid rgba(51, 34, 46, 0.24);
  border-radius: var(--rayon);
  padding: 0.7rem 0.85rem;
  font-size: 0.95rem;
  color: var(--ardoise);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.champ::placeholder {
  color: rgba(51, 34, 46, 0.42);
}

.champ:focus {
  outline: none;
  border-color: var(--or);
  box-shadow: 0 0 0 3px rgba(169, 140, 88, 0.18);
}

.champ-nuit {
  border-color: rgba(251, 247, 242, 0.25);
  color: var(--creme);
}

.champ-nuit::placeholder {
  color: rgba(251, 247, 242, 0.45);
}

.champ-nuit:focus {
  box-shadow: 0 0 0 3px rgba(200, 172, 124, 0.18);
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  border-radius: var(--rayon);
  font-size: 0.8125rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 500;
  padding: 0.95rem 1.75rem;
  border: 1px solid transparent;
  transition: background-color 0.22s ease, color 0.22s ease, border-color 0.22s ease;
  cursor: pointer;
}

.btn-or {
  background: var(--or-fonce);
  color: var(--creme);
}

.btn-or:hover,
.btn-or:focus-visible {
  background: var(--or);
}

.btn-prune {
  background: var(--prune);
  color: var(--creme);
}

.btn-prune:hover,
.btn-prune:focus-visible {
  background: var(--prune-fonce);
}

.btn-fantome {
  background: transparent;
  color: var(--ardoise);
  border-color: rgba(169, 140, 88, 0.55);
}

.btn-fantome:hover,
.btn-fantome:focus-visible {
  border-color: var(--or);
  background: rgba(169, 140, 88, 0.08);
}

.btn-fantome-clair {
  background: transparent;
  color: var(--creme);
  border-color: rgba(251, 247, 242, 0.35);
}

.btn-fantome-clair:hover,
.btn-fantome-clair:focus-visible {
  border-color: var(--or-clair);
  background: rgba(200, 172, 124, 0.12);
}

.btn-clair {
  background: var(--creme);
  color: var(--ardoise);
}

.btn-clair:hover,
.btn-clair:focus-visible {
  background: var(--or-clair);
}

/* --- Navigation desktop : dropdown au survol et au focus ---------------- */

.drop {
  visibility: hidden;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s;
}

.group:hover > .drop,
.group:focus-within > .drop {
  visibility: visible;
  opacity: 1;
  transform: none;
}

/* --- Menu mobile ------------------------------------------------------- */

#menu-mobile {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
}

#menu-mobile.ouvert {
  max-height: 78vh;
  overflow-y: auto;
}

/* --- Lien de langue ---------------------------------------------------- */

.lang-link {
  font-size: 0.6875rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(251, 247, 242, 0.75);
  border: 1px solid rgba(251, 247, 242, 0.28);
  padding: 0.15rem 0.5rem;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.lang-link:hover,
.lang-link:focus-visible {
  color: var(--or-clair);
  border-color: var(--or-clair);
}

/* --- Prix -------------------------------------------------------------- */

.prix {
  font-variant-numeric: tabular-nums;
}

/* --- Image de couverture : voile pour la lisibilité du texte ----------- */

.voile {
  background: linear-gradient(100deg, rgba(32, 18, 28, 0.86) 0%, rgba(32, 18, 28, 0.62) 40%, rgba(32, 18, 28, 0.18) 72%, rgba(32, 18, 28, 0.06) 100%);
}

.voile-doux {
  background: linear-gradient(180deg, rgba(32, 18, 28, 0.55) 0%, rgba(32, 18, 28, 0.08) 42%, rgba(32, 18, 28, 0.72) 100%);
}

/* --- Grain fin --------------------------------------------------------- */

.grain::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.4;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)' opacity='0.05'/%3E%3C/svg%3E");
}

/* --- Utilitaires -------------------------------------------------------- */

.mesure {
  max-width: 68ch;
}

.saut {
  scroll-margin-top: 6.5rem;
}
