/* Lumen Catalogue — styles isolés sous .lc-catalogue et .lc-fiche */

.lc-catalogue,
.lc-fiche {
  --lc-ink: #123747;
  --lc-ink-soft: #365d6c;
  --lc-muted: #607e89;
  --lc-line: #c9e2e9;
  --lc-line-strong: #87becd;
  --lc-mist: #f3fafc;
  --lc-water: #dff5fa;
  --lc-cyan-dark: #0a6f91;
  --lc-deep: #0c4054;
  --lc-focus: #f1a646;
  --lc-physique: #EA604E;
  --lc-physique-ink: #CC4A34;
  --lc-emotionnel: #009CE4;
  --lc-emotionnel-ink: #037AB0;
  color: var(--lc-ink);
  font-family: Aptos, "Segoe UI", system-ui, -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

.lc-catalogue *,
.lc-catalogue *::before,
.lc-catalogue *::after,
.lc-fiche *,
.lc-fiche *::before,
.lc-fiche *::after { box-sizing: border-box; }

.lc-catalogue button { font: inherit; color: inherit; }
.lc-catalogue :focus-visible,
.lc-fiche :focus-visible { outline: 3px solid var(--lc-focus); outline-offset: 3px; }
.lc-catalogue ::selection,
.lc-fiche ::selection { color: #fff; background: var(--lc-cyan-dark); }

/* ---------- En-tête ---------- */

.lc-catalogue .lc-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  padding-bottom: 18px;
  border-bottom: 1px solid #e1e5e7;
}

.lc-catalogue .lc-universes {
  flex: 0 0 50%;
  display: flex;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--lc-line);
  border-radius: 12px;
  background: var(--lc-mist);
}

.lc-catalogue .lc-universe {
  flex: 1 1 0;
  min-width: 0;
  min-height: 46px;
  padding: 7px 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--lc-ink-soft);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: background .18s ease, color .18s ease, box-shadow .18s ease;
}

.lc-catalogue .lc-universe small { color: var(--lc-muted); font-size: 12px; }
.lc-catalogue .lc-universe:hover { background: rgba(255, 255, 255, .7); }
.lc-catalogue .lc-universe[data-lc-universe="physique"][aria-pressed="true"] {
  background: var(--lc-physique-ink); color: #fff; box-shadow: 0 6px 18px rgba(234, 96, 78, .3);
}
.lc-catalogue .lc-universe[data-lc-universe="emotionnel"][aria-pressed="true"] {
  background: var(--lc-emotionnel-ink); color: #fff; box-shadow: 0 6px 18px rgba(0, 156, 228, .28);
}
.lc-catalogue .lc-universe[aria-pressed="true"] small { color: rgba(255, 255, 255, .8); }

/* ---------- Filtres ---------- */

.lc-catalogue .lc-filters {
  position: sticky;
  top: 0;
  z-index: 20;
  margin-top: 4px;
  padding: 15px 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 264px;
  align-items: start;
  gap: 28px;
  border-bottom: 1px solid #d6dcdf;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(10px);
}

.lc-catalogue .lc-filter-stack { display: grid; gap: 8px; }

.lc-catalogue .lc-filter-row {
  min-width: 0;
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
}

.lc-catalogue .lc-filter-row[hidden] { display: none; }

.lc-catalogue .lc-filter-label {
  color: #5d6970;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .045em;
  text-transform: uppercase;
}

.lc-catalogue .lc-tabs { display: flex; flex-wrap: wrap; gap: 7px; }

.lc-catalogue .lc-tabs button {
  min-height: 34px;
  padding: 5px 13px;
  border: 1px solid var(--lc-line);
  border-radius: 999px;
  background: #fff;
  color: var(--lc-ink-soft);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.lc-catalogue .lc-tabs button[hidden] { display: none; }
.lc-catalogue .lc-tabs button span { margin-left: 4px; color: var(--lc-muted); font-variant-numeric: tabular-nums; }
.lc-catalogue .lc-tabs button[aria-selected="true"] {
  border-color: var(--lc-physique-ink);
  background: var(--lc-physique-ink);
  color: #fff;
}
.lc-catalogue[data-lc-univers="emotionnel"] .lc-tabs button[aria-selected="true"] {
  border-color: var(--lc-emotionnel-ink);
  background: var(--lc-emotionnel-ink);
}
.lc-catalogue .lc-tabs button[aria-selected="true"] span { color: rgba(255, 255, 255, .8); }

.lc-catalogue .lc-search {
  position: relative;
  margin-top: 1px;
  height: 36px;
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  align-items: center;
  gap: 9px;
  padding: 0 16px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: #f5f6f6;
}

.lc-catalogue .lc-search .screen-reader-text {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.lc-catalogue .lc-search:focus-within {
  border-color: var(--lc-line-strong);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(30, 156, 193, .12);
}

.lc-catalogue .lc-search svg { width: 20px; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.lc-catalogue .lc-search input {
  width: 100%;
  height: 100%;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  box-shadow: none;
  color: var(--lc-ink);
  font: inherit;
  font-size: 15px;
  line-height: 1.2;
  caret-color: var(--lc-cyan-dark);
  appearance: none;
}

.lc-catalogue .lc-search input::-webkit-search-decoration,
.lc-catalogue .lc-search input::-webkit-search-cancel-button { appearance: none; }
.lc-catalogue .lc-search input::placeholder { color: #708d97; opacity: 1; }

.lc-catalogue .lc-chips { display: flex; flex-wrap: wrap; gap: 7px; }
.lc-catalogue .lc-chips[hidden] { display: none; }

.lc-catalogue .lc-chip {
  --lc-family: #717984;
  --lc-family-ink: #4a5560;
  --lc-family-bg: #f0f1f2;
  min-height: 34px;
  padding: 5px 10px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid #d7dcdf;
  border-radius: 999px;
  background: #fff;
  color: var(--lc-ink-soft);
  font-size: 13px;
  font-weight: 650;
  cursor: pointer;
}

.lc-catalogue .lc-chip[data-lc-family]:not([data-lc-family=""])::before {
  content: "";
  width: 8px;
  height: 8px;
  flex: none;
  border-radius: 50%;
  background: var(--lc-family);
}

.lc-catalogue .lc-chip span { color: var(--lc-muted); font-variant-numeric: tabular-nums; }
.lc-catalogue .lc-chip:hover { border-color: var(--lc-family); }
.lc-catalogue .lc-chip[aria-pressed="true"] { border-color: var(--lc-family); background: var(--lc-family-bg); color: var(--lc-ink); }
.lc-catalogue .lc-chip[aria-pressed="true"] span { color: var(--lc-family-ink); }

/* Couleurs des rubriques, reprises du catalogue A5 */
.lc-catalogue .lc-chip[data-lc-family="Alimentaire"], .lc-catalogue .lc-card[data-lc-family="Alimentaire"] { --lc-family: #EA604E; --lc-family-ink: #A83E2C; --lc-family-bg: #FDEFED; }
.lc-catalogue .lc-chip[data-lc-family="Environnemental"], .lc-catalogue .lc-card[data-lc-family="Environnemental"] { --lc-family: #009642; --lc-family-ink: #04703E; --lc-family-bg: #E6F4EC; }
.lc-catalogue .lc-chip[data-lc-family="Pharmaceutique"], .lc-catalogue .lc-card[data-lc-family="Pharmaceutique"] { --lc-family: #2A3684; --lc-family-ink: #1F3269; --lc-family-bg: #EAEBF3; }
.lc-catalogue .lc-chip[data-lc-family="Micronutriments"], .lc-catalogue .lc-card[data-lc-family="Micronutriments"] { --lc-family: #CC1818; --lc-family-ink: #881E22; --lc-family-bg: #FAE8E8; }
.lc-catalogue .lc-chip[data-lc-family="Organique"], .lc-catalogue .lc-card[data-lc-family="Organique"] { --lc-family: #0F7A6B; --lc-family-ink: #0E5E58; --lc-family-bg: #E7F2F0; }
.lc-catalogue .lc-chip[data-lc-family="Pathogène"], .lc-catalogue .lc-card[data-lc-family="Pathogène"] { --lc-family: #CC1818; --lc-family-ink: #881E22; --lc-family-bg: #FAE8E8; }
.lc-catalogue .lc-chip[data-lc-family="Composant Cellulaire"], .lc-catalogue .lc-card[data-lc-family="Composant Cellulaire"] { --lc-family: #7A4E8C; --lc-family-ink: #53416E; --lc-family-bg: #F2EDF4; }
.lc-catalogue .lc-chip[data-lc-family="Sens"], .lc-catalogue .lc-card[data-lc-family="Sens"] { --lc-family: #B07C1E; --lc-family-ink: #765F26; --lc-family-bg: #F7F2E8; }
.lc-catalogue .lc-chip[data-lc-family="Emotions"], .lc-catalogue .lc-card[data-lc-family="Emotions"] { --lc-family: #009CE4; --lc-family-ink: #0474A7; --lc-family-bg: #E6F5FC; }
.lc-catalogue .lc-chip[data-lc-family="Fleurs"], .lc-catalogue .lc-card[data-lc-family="Fleurs"] { --lc-family: #009642; --lc-family-ink: #04703E; --lc-family-bg: #E6F4EC; }
.lc-catalogue .lc-chip[data-lc-family="Cristaux"], .lc-catalogue .lc-card[data-lc-family="Cristaux"] { --lc-family: #2A3684; --lc-family-ink: #1F3269; --lc-family-bg: #EAEBF3; }
.lc-catalogue .lc-card[data-lc-family="Melanges"] { --lc-family: #009CE4; --lc-family-ink: #0474A7; --lc-family-bg: #E6F5FC; }

/* ---------- Compteur ---------- */

.lc-catalogue .lc-meta {
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: var(--lc-muted);
  font-size: 13px;
}

.lc-catalogue .lc-meta p { margin: 0; }
.lc-catalogue .lc-meta strong { color: var(--lc-ink); font-variant-numeric: tabular-nums; }
.lc-catalogue .lc-meta button {
  padding: 5px 0;
  border: 0;
  border-bottom: 1px solid currentColor;
  background: none;
  color: var(--lc-cyan-dark);
  cursor: pointer;
}

/* ---------- Grille et cartes ---------- */

.lc-catalogue .lc-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.lc-catalogue .lc-grid[hidden] { display: none; }

.lc-catalogue .lc-card {
  --lc-family: #717984;
  --lc-family-ink: #4a5560;
  --lc-family-bg: #f4f5f5;
  min-width: 0;
  min-height: 240px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  border: 1px solid #d7dde0;
  border-radius: 13px;
  background: linear-gradient(145deg, #fff 0%, var(--lc-family-bg) 165%);
  box-shadow: inset 0 3px 0 var(--lc-family);
  color: var(--lc-ink);
  text-decoration: none;
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}

.lc-catalogue .lc-card:hover {
  border-color: color-mix(in srgb, var(--lc-family), #d7dde0 45%);
  box-shadow: inset 0 3px 0 var(--lc-family), 0 15px 35px rgba(20, 70, 86, .1);
  transform: translateY(-2px);
}

.lc-catalogue .lc-card[hidden] { display: none; }

.lc-catalogue .lc-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--lc-muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .025em;
  text-transform: uppercase;
}

.lc-catalogue .lc-card-family { color: var(--lc-family-ink); font-weight: 750; }
.lc-catalogue .lc-card code {
  color: var(--lc-cyan-dark);
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: .92em;
  letter-spacing: 0;
  text-transform: none;
  background: none;
  padding: 0;
}

.lc-catalogue .lc-card-title {
  margin-top: 22px;
  color: var(--lc-ink);
  font-size: clamp(1.2rem, 2.1vw, 1.55rem);
  font-weight: 720;
  line-height: 1.12;
  letter-spacing: -.025em;
  text-wrap: balance;
}

.lc-catalogue .lc-card-body {
  margin-top: 12px;
  color: var(--lc-ink-soft);
  font-size: 14px;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.lc-catalogue .lc-composition { display: flex; flex-wrap: wrap; gap: 5px; -webkit-line-clamp: unset; }
.lc-catalogue .lc-composition span {
  padding: 3px 8px;
  border: 1px solid color-mix(in srgb, var(--lc-family), #fff 72%);
  border-radius: 999px;
  background: rgba(255, 255, 255, .7);
  color: var(--lc-ink-soft);
  font-size: 12px;
}

.lc-catalogue .lc-card-foot {
  margin-top: auto;
  padding-top: 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  color: var(--lc-cyan-dark);
  font-size: 14px;
  font-weight: 720;
}

.lc-catalogue .lc-card-foot svg { width: 20px; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; transition: transform .2s ease; }
.lc-catalogue .lc-card:hover .lc-card-foot svg { transform: translateX(4px); }

.lc-catalogue .lc-empty { max-width: 520px; margin: 60px auto; padding: 44px 24px; text-align: center; }
.lc-catalogue .lc-empty[hidden] { display: none; }
.lc-catalogue .lc-empty h3 { margin: 0 0 8px; font-size: 1.4rem; }
.lc-catalogue .lc-empty p { margin: 0; color: var(--lc-muted); }
.lc-catalogue .lc-empty button { margin-top: 20px; padding: 10px 14px; border: 1px solid var(--lc-line-strong); border-radius: 9px; background: #fff; cursor: pointer; font-weight: 700; }

/* ---------- Contexte des fiches ---------- */

.lc-fiche .lc-context { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0 0 10px; color: var(--lc-muted); font-size: 13px; }
.lc-fiche .lc-context a { color: var(--lc-cyan-dark); font-weight: 650; text-decoration: none; border-bottom: 1px solid transparent; }
.lc-fiche .lc-context a:hover { border-bottom-color: currentColor; }

.lc-more { margin-top: 56px; padding-top: 26px; border-top: 1px solid var(--lc-line); }
.lc-more h2 { margin: 0 0 10px; font-size: 1.15rem; letter-spacing: -.01em; }
.lc-more-text { max-width: 68ch; margin: 0 0 18px; color: var(--lc-ink-soft); font-size: 14px; line-height: 1.65; }
.lc-more-links { margin: 0; padding: 0; list-style: none; display: grid; gap: 9px; }
.lc-more-links a { color: var(--lc-ink); text-decoration: none; border-bottom: 1px solid var(--lc-line-strong); font-size: 14px; }
.lc-more-links a:hover { color: var(--lc-cyan-dark); border-bottom-color: currentColor; }

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

.lc-fiche { max-width: 820px; margin: 0 auto; padding: 40px 20px 80px; }
.lc-fiche-main { padding: 0 0 40px; }
.lc-fiche .lc-fiche-meta { margin: 26px 0 6px; color: var(--lc-muted); font-size: 13px; font-weight: 650; }
.lc-fiche h1 { margin: 0 0 18px; color: var(--lc-ink); font-size: clamp(2rem, 5vw, 2.4rem); line-height: 1.04; letter-spacing: -.04em; }
.lc-fiche .lc-lead { margin: 0 0 24px; color: var(--lc-ink-soft); font-size: 17px; }
.lc-fiche h2 { margin: 38px 0 14px; color: var(--lc-ink); font-size: 1.3rem; letter-spacing: -.02em; }
.lc-fiche .lc-actions { margin: 0 0 8px; }
.lc-fiche .lc-button {
  display: inline-flex;
  align-items: center;
  min-height: 46px;
  padding: 10px 18px;
  border-radius: 9px;
  background: var(--lc-deep);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
}
.lc-fiche .lc-button:hover { background: var(--lc-cyan-dark); }
.lc-fiche .lc-linked { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--lc-line); }
.lc-fiche .lc-linked li { padding: 12px 0; border-bottom: 1px solid var(--lc-line); color: var(--lc-ink-soft); }
.lc-fiche .lc-linked a { color: var(--lc-ink); text-decoration: none; }
.lc-fiche .lc-linked a:hover { color: var(--lc-cyan-dark); }
.lc-fiche .lc-linked code { margin-right: 8px; color: var(--lc-cyan-dark); font-family: "SFMono-Regular", Consolas, monospace; font-size: .9em; }
.lc-fiche .lc-tag { margin-left: 8px; padding: 2px 7px; border-radius: 999px; background: var(--lc-mist); color: var(--lc-muted); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; }
.lc-fiche .lc-composition-block { margin: 0; padding: 16px 18px; border: 1px solid var(--lc-line); border-radius: 10px; background: var(--lc-mist); color: var(--lc-ink-soft); font-size: 14px; line-height: 1.7; }
.lc-fiche .lc-rich { color: var(--lc-ink-soft); font-size: 15px; line-height: 1.7; }
.lc-fiche .lc-rich table { width: 100%; border-collapse: collapse; font-size: 14px; }
.lc-fiche .lc-rich th,
.lc-fiche .lc-rich td { padding: 10px; border: 1px solid var(--lc-line); text-align: left; vertical-align: top; }
.lc-fiche .lc-rich th { background: var(--lc-mist); color: var(--lc-ink); }
.lc-catalogue .lc-error { padding: 16px; border: 1px solid #e0b4b4; border-radius: 8px; background: #fdf2f2; color: #7a2b2b; }

/* ---------- Responsive ---------- */

@media (max-width: 1080px) {
  .lc-catalogue .lc-head { flex-direction: column; align-items: stretch; gap: 16px; }
  .lc-catalogue .lc-universes { flex: 1 1 auto; width: 100%; }
  .lc-catalogue .lc-filters { grid-template-columns: 1fr; }
  .lc-catalogue .lc-search { width: min(100%, 360px); grid-row: 1; }
  .lc-catalogue .lc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 640px) {
  .lc-catalogue .lc-filters { position: static; backdrop-filter: none; gap: 13px; }
  .lc-catalogue .lc-search { width: 100%; }
  .lc-catalogue .lc-filter-row { grid-template-columns: 1fr; gap: 7px; }
  .lc-catalogue .lc-chips { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 3px; scrollbar-width: none; }
  .lc-catalogue .lc-chips::-webkit-scrollbar { display: none; }
  .lc-catalogue .lc-chip { flex: none; }
  .lc-catalogue .lc-grid { grid-template-columns: 1fr; }
  .lc-catalogue .lc-card { min-height: 210px; }
  .lc-fiche { padding: 28px 16px 64px; }
}

@media (prefers-reduced-motion: reduce) {
  .lc-catalogue *,
  .lc-fiche * { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
