/* ==========================================================================
   YOPROFX / 02 — BASE
   Reset, document, and the raw typographic registers. No components here.
   ========================================================================== */

*,
*::before,
*::after { box-sizing: border-box; }

* { margin: 0; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  /* The wordmark paints its glow outside its own box by design. `clip`
     rather than `hidden`: hidden on the root element turns it into a
     scroll container and breaks position:sticky further down the page. */
  overflow-x: clip;
  scroll-padding-top: calc(var(--chrome-h) + var(--sp-lg));
  tab-size: 2;
}

@media (prefers-reduced-motion: no-preference) {
  html:focus-within { scroll-behavior: smooth; }
}

body {
  background: var(--c-vault);
  color: var(--c-bone);
  font-family: var(--font-structure);
  font-size: var(--t-body);
  line-height: var(--lh-body);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
  overflow-x: hidden;
}

/* --- MEDIA ---------------------------------------------------------------
   Media is never decorative filler. It arrives desaturated and slightly
   dimmed — lit only on interaction, like an object in a vitrine. */
img,
picture,
video,
canvas,
svg,
iframe {
  display: block;
  max-width: 100%;
}

img,
video {
  height: auto;
  background: var(--c-vitrine);
  filter: saturate(0.82) contrast(1.04) brightness(0.9);
  transition: filter var(--dur-slow) var(--ease-dimmer);
}

a:hover img,
a:focus-visible img,
.is-lit img,
.is-lit video { filter: saturate(1) contrast(1.06) brightness(1); }

svg { fill: currentColor; }

/* --- FORM ELEMENTS ------------------------------------------------------- */
button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
  letter-spacing: inherit;
}

button {
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}

/* --- LINKS ---------------------------------------------------------------
   The house link: no colour, no underline slide, no ornament. It brightens
   and its rule ignites. That is the entire vocabulary. */
a {
  color: inherit;
  text-decoration: none;
  transition: color var(--dur-fast) var(--ease-dimmer),
              border-color var(--dur-fast) var(--ease-dimmer),
              opacity var(--dur-fast) var(--ease-dimmer);
}

.prose a,
a.link {
  color: var(--c-bone);
  border-bottom: var(--hair) solid var(--c-line-lit);
  padding-bottom: 0.08em;
}

.prose a:hover,
a.link:hover { border-bottom-color: var(--territory); }

/* --- FOCUS ---------------------------------------------------------------
   The focus ring is the SPOTLIGHT effect. Accessibility and aesthetic are
   the same object here, so it is never removed — only made handsome. */
:focus { outline: none; }

:focus-visible {
  outline: var(--hair) solid var(--c-bone);
  outline-offset: 3px;
  border-radius: var(--r-sm);
}

@supports selector(:focus-visible) {
  :focus-visible {
    box-shadow: 0 0 0 5px rgba(239, 234, 225, 0.06),
                0 0 24px -4px var(--territory);
  }
}

::selection {
  background: var(--c-bone);
  color: var(--c-vault);
}

/* --- SCROLLBAR ----------------------------------------------------------- */
@supports selector(::-webkit-scrollbar) {
  ::-webkit-scrollbar { width: 10px; height: 10px; }
  ::-webkit-scrollbar-track { background: var(--c-vault); }
  ::-webkit-scrollbar-thumb {
    background: #2a2a30;
    border: 3px solid var(--c-vault);
  }
  ::-webkit-scrollbar-thumb:hover { background: var(--c-graphite); }
}

html { scrollbar-color: #2a2a30 var(--c-vault); scrollbar-width: thin; }

/* ==========================================================================
   TYPOGRAPHIC REGISTERS
   Two languages on one page, and the contrast between them is the point.

   EDITORIAL   .u-hero .u-display .u-lede .prose      — serif, the story
   SIGNAGE     .u-signage .u-title                    — sans, the structure
   LABORATORY  .u-label .u-meta .u-annot              — mono, the record
   ========================================================================== */

/* --- EDITORIAL ----------------------------------------------------------- */
.u-hero,
.u-display {
  font-family: var(--font-display);
  font-weight: 400;
  color: var(--c-bone);
  text-wrap: balance;
}

.u-hero {
  font-size: var(--t-hero);
  line-height: var(--lh-tight);
  letter-spacing: var(--ls-hero);
}

.u-display {
  font-size: var(--t-display);
  line-height: var(--lh-display);
  letter-spacing: var(--ls-display);
}

.u-lede {
  font-family: var(--font-display);
  font-size: var(--t-lede);
  line-height: 1.5;
  color: var(--c-chalk);
  max-width: 44ch;
  text-wrap: pretty;
}

.prose {
  max-width: var(--w-text);
  font-family: var(--font-display);
  font-size: var(--t-lede);
  line-height: 1.62;
  color: #cfcac1;
  text-wrap: pretty;
}

.prose > * + * { margin-top: 1.1em; }
.prose strong { color: var(--c-bone); font-weight: 600; }
.prose em { font-style: italic; }

/* --- SIGNAGE -------------------------------------------------------------
   Museum stanchion lettering: sans, uppercase, wide tracking, tight leading.
   Stretched when the platform offers a wider width axis. */
.u-signage,
.u-title {
  font-family: var(--font-structure);
  font-weight: 600;
  font-stretch: 112%;
  text-transform: uppercase;
  color: var(--c-bone);
}

.u-signage {
  font-size: var(--t-signage);
  line-height: 1;
  letter-spacing: var(--ls-signage);
}

.u-title {
  font-size: var(--t-title);
  line-height: var(--lh-title);
  letter-spacing: 0.045em;
}

/* --- LABORATORY ----------------------------------------------------------
   Every ID, date, duration, dimension and coordinate on the site. This is
   the connective tissue: it appears on literally every screen. */
.u-label,
.u-meta,
.u-annot {
  font-family: var(--font-mono);
  font-weight: 500;
  text-transform: uppercase;
  font-variant-numeric: tabular-nums;
  line-height: var(--lh-mono);
}

.u-label {
  font-size: var(--t-label);
  letter-spacing: var(--ls-label);
  color: var(--c-graphite);
}

.u-meta {
  font-size: var(--t-meta);
  letter-spacing: var(--ls-meta);
  color: var(--c-graphite);
}

.u-annot {
  font-size: var(--t-meta);
  letter-spacing: var(--ls-meta);
  color: var(--c-graphite);
  text-transform: none;
}

.u-lit { color: var(--territory); }

/* --- THE REGISTER MARK ---------------------------------------------------
   The X is identity, not punctuation. It appears exactly three times per
   page — the masthead wordmark, the footer wordmark, and the terminator on
   the calibration strip — and nowhere else. It was briefly the site's list
   bullet, its CTA glyph and its separator, at which point it stopped
   meaning anything at all. A mark used forty times a page is wallpaper.
   ------------------------------------------------------------------------- */

/* --- UTILITIES ----------------------------------------------------------- */
.u-visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.u-skip {
  position: absolute;
  top: var(--sp-2xs);
  left: var(--sp-2xs);
  z-index: var(--z-skip);
  padding: var(--sp-2xs) var(--sp-sm);
  background: var(--c-bone);
  color: var(--c-vault);
  font-family: var(--font-mono);
  font-size: var(--t-meta);
  letter-spacing: var(--ls-meta);
  text-transform: uppercase;
  transform: translateY(-200%);
  transition: transform var(--dur-fast) var(--ease-dimmer);
}

.u-skip:focus-visible { transform: translateY(0); }

/* Escape hatch for brand terms that must keep their own casing inside the
   all-caps signage register, e.g. ePRODUCTS. */
.u-nocaps { text-transform: none; }

