/* Visual universe (Homme / Femme / neutre): entry screen, switch links and text variants.
   Loaded after home.css on every page. Behaviour in univers.js. */

/* ---------- Text variants ---------- */

/* <span data-univers-only="homme femme">: shown only in the listed universes. Without JS
   or before any choice, the page is in neutral mode. */
html:not([data-univers="homme"]):not([data-univers="femme"]) [data-univers-only]:not([data-univers-only~="neutre"]),
html[data-univers="homme"] [data-univers-only]:not([data-univers-only~="homme"]),
html[data-univers="femme"] [data-univers-only]:not([data-univers-only~="femme"]) { display: none; }

/* Slot images get their source from univers.js; without JS the <noscript> copy is used. */
html:not(.js) img[data-univers-slot] { display: none; }

/* ?nmt_debug=1: interim visuals are outlined. */
.univers-debug [data-univers-provisoire] { outline: 3px dashed #f59e0b; outline-offset: -3px; }

/* ---------- Entry screen ---------- */

.univers-gate { display: none; position: fixed; inset: 0; z-index: 1000; overflow-y: auto; padding: 40px 16px;
  place-items: center; color: #e2e8f0; text-align: center;
  background:
    radial-gradient(42% 38% at 50% 34%, rgba(37,99,235,.10), transparent 70%),
    radial-gradient(90% 70% at 50% 110%, rgba(6,14,48,.9), transparent 70%),
    linear-gradient(180deg, #00041f 0%, #010518 55%, #000210 100%);
  transition: opacity .6s ease; }
.univers-gate:focus { outline: none; }
html.univers-gate-open { overflow: hidden; }
html.univers-gate-open .univers-gate { display: grid; }
html.univers-gate-closing .univers-gate { opacity: 0; }

.ug-inner { display: flex; flex-direction: column; align-items: center; max-width: 560px; }

/* Original NMT logo, untouched file and proportions: colours kept and slightly softened,
   a discreet blue halo behind, and a brushed-silver sheen (with a hint of gold) that
   sweeps across now and then, clipped to its round shape. */
.ug-logo { position: relative; isolation: isolate; width: clamp(150px, 26vmin, 220px); aspect-ratio: 1; margin: 0 0 34px; border-radius: 50%; }
.ug-logo img { display: block; width: 100%; height: 100%; border-radius: 50%; filter: saturate(.82) contrast(1.04) brightness(1.03); box-shadow: 0 0 0 1px rgba(226,232,240,.14), 0 24px 60px -24px rgba(0,0,0,.9); }
.ug-logo::before { content: ""; position: absolute; inset: -32%; z-index: -1; border-radius: 50%; background: radial-gradient(circle, rgba(59,130,246,.22), rgba(29,78,216,.07) 45%, transparent 70%); filter: blur(14px); }
.ug-logo::after { content: ""; position: absolute; inset: 0; border-radius: 50%; pointer-events: none; mix-blend-mode: screen;
  background: linear-gradient(115deg, transparent 38%, rgba(203,213,225,.18) 45%, rgba(248,250,252,.42) 50%, rgba(246,226,122,.16) 54%, transparent 62%);
  background-size: 260% 100%; background-position: 130% 0; }
/* Monochrome silver variant, for comparison only: index.html?logo=mono */
.univers-logo-mono .ug-logo img { filter: grayscale(1) contrast(1.18) brightness(1.12); }
.univers-logo-mono .ug-logo::before { background: radial-gradient(circle, rgba(148,163,184,.2), rgba(59,130,246,.06) 45%, transparent 70%); }

.ug-brand { margin: 0 0 14px; padding-left: .42em; font: 600 14px var(--font-text); letter-spacing: .42em; text-transform: uppercase;
  background: linear-gradient(180deg, #f8fafc, #a7b4c7); -webkit-background-clip: text; background-clip: text; color: transparent; }
.ug-brand sup.tm { color: #a7b4c7; -webkit-text-fill-color: #a7b4c7; }
.ug-title { margin: 0 0 36px; font: 500 clamp(24px, 3vw, 32px)/1.2 var(--font-display); letter-spacing: -.01em; color: #f1f5f9; }

.ug-choices { display: flex; flex-wrap: wrap; justify-content: center; gap: 18px; }
/* Each card is lit from behind its symbol in its universe's colour (--glow, as r,g,b):
   ice blue for Homme, cool pinkish mauve for Femme, at the same strength (--glow-a).
   Registered so the strength eases on hover instead of jumping. */
@property --glow-a { syntax: "<number>"; inherits: true; initial-value: .14; }
.ug-choice { --glow: 165,214,247; --glow-a: .14; --sym: #e0f2fe;
  display: flex; flex-direction: column; align-items: center; gap: 14px; width: 168px; padding: 28px 16px 22px; border-radius: 20px; border: 1px solid transparent; cursor: pointer;
  background:
    radial-gradient(60px 48px at 50% 51px, rgba(var(--glow), var(--glow-a)), transparent 75%) padding-box,
    linear-gradient(180deg, rgba(255,255,255,.05), transparent 40%) padding-box,
    linear-gradient(160deg, rgba(22,32,64,.92), rgba(6,12,38,.92)) padding-box,
    linear-gradient(135deg, rgba(241,245,249,.5), rgba(100,116,139,.14) 45%, rgba(226,232,240,.38)) border-box;
  color: #e2e8f0; font: 500 17px var(--font-text); letter-spacing: .08em;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.08), inset 0 -1px 0 rgba(0,0,0,.35), 0 2px 4px -2px rgba(0,0,0,.6), 0 22px 44px -26px rgba(0,0,0,.95);
  transition: transform .25s ease, box-shadow .25s ease, color .25s ease, --glow-a .25s ease; }
.ug-choice[data-univers-choice="femme"] { --glow: 214,186,224; --sym: #f3e8f5; }
/* Symbol: 1px dark edge for relief, tight silver highlight, concentrated glow, soft halo. */
.ug-choice svg { width: 46px; height: 46px; color: var(--sym);
  filter: drop-shadow(0 1px 0 rgba(0,0,0,.55)) drop-shadow(0 0 1.5px rgba(255,255,255,.35)) drop-shadow(0 0 5px rgba(var(--glow), calc(var(--glow-a) * 3))) drop-shadow(0 0 16px rgba(var(--glow), calc(var(--glow-a) * 1.6))); }
.ug-choice:hover, .ug-choice:focus-visible { --glow-a: .22; transform: translateY(-2px); color: #fff;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.12), inset 0 -1px 0 rgba(0,0,0,.35), 0 0 0 1px rgba(var(--glow), .28), 0 4px 8px -4px rgba(0,0,0,.7), 0 26px 50px -24px rgba(var(--glow), .32); }
.ug-choice:focus-visible { outline: 2px solid rgb(var(--glow)); outline-offset: 4px; }
@media (max-width: 400px) { .ug-choices { gap: 12px; } .ug-choice { width: 140px; padding: 24px 12px 20px; } }

.ug-skip { margin-top: 26px; padding: 8px 12px; border: 0; background: none; cursor: pointer; color: #94a3b8; font: 500 14px var(--font-text);
  text-decoration: underline; text-decoration-color: rgba(148,163,184,.4); text-underline-offset: 5px; transition: color .3s; }
.ug-skip:hover, .ug-skip:focus-visible { color: #e2e8f0; }
.ug-skip:focus-visible { outline: 2px solid #7dd3fc; outline-offset: 2px; border-radius: 6px; }

/* Slow, quiet appearance: logo, then halo, then words and choices. */
@media (prefers-reduced-motion: no-preference) {
  .ug-logo { animation: ug-in 1.6s cubic-bezier(.2,.7,.2,1) both; }
  .ug-logo::before { animation: ug-fade 2.4s ease .5s both; }
  .ug-logo::after { animation: ug-sheen 11s ease-in-out 1.6s infinite; }
  .ug-brand { animation: ug-up 1s ease .9s both; }
  .ug-title { animation: ug-up 1s ease 1.1s both; }
  .ug-choices { animation: ug-up 1s ease 1.3s both; }
  .ug-skip { animation: ug-fade 1.2s ease 1.7s both; }
  html.univers-gate-closing .ug-inner { transform: scale(.985); transition: transform .6s ease; }
  @keyframes ug-in { from { opacity: 0; transform: scale(.94); } to { opacity: 1; transform: none; } }
  @keyframes ug-fade { from { opacity: 0; } to { opacity: 1; } }
  @keyframes ug-up { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
  @keyframes ug-sheen { 0% { background-position: 130% 0; } 22%, 100% { background-position: -30% 0; } }
}
@media (prefers-reduced-motion: reduce) {
  .univers-gate, .ug-choice { transition: none; }
  .ug-choice:hover, .ug-choice:focus-visible { transform: none; } /* light only, no movement */
}

/* ---------- "Changer d'univers" ---------- */

.univers-switch { display: none; }
@media (min-width: 641px) {
  .univers-switch { display: inline-grid; place-items: center; width: 40px; height: 40px; flex: none; border-radius: 50%; border: 1px solid rgba(226,232,240,.22); color: #cbd5e1; background: rgba(255,255,255,.03); transition: border-color .3s, color .3s, box-shadow .3s; }
  .univers-switch:hover, .univers-switch:focus-visible { color: #fff; border-color: rgba(147,197,253,.5); box-shadow: 0 0 16px rgba(59,130,246,.3); }
  .univers-switch svg { width: 20px; height: 20px; }
}
.masthead .mnav-panel .menu-cta .univers-menu-link { display: block; width: fit-content; margin-top: 18px; color: #cbd5e1; font-size: 15px; text-underline-offset: 4px; }
.site-foot .univers-foot { margin: 48px 0 0; font-size: 13px; color: var(--muted); }
.site-foot .univers-foot a { color: #cbd5e1; }
.site-foot .univers-foot + .disclaimer { margin-top: 18px; }
