/* ── Fifty Five and Five design tokens ──────────────────────
   Source of truth mirrors assets/css/main.css in the
   fifty-five-and-five-hugo production repo.
   ──────────────────────────────────────────────────────────── */
:root {
  /* Creams */
  --cream-50:  #faf9f4;
  --cream-100: #f5f2e2;
  --cream-200: #ebe7d3;
  --off-white: #f7f6f2;

  /* Charcoals */
  --charcoal:       #1a1c20;
  --charcoal-light: #2a2c30;

  /* Accents */
  --orange:       #ff5200;
  --orange-hover: #e64a00;
  --tan:          #f3c892;
  --grey:         #e5e5e5;

  /* Radii */
  --r-sm:   12px;
  --r-md:   16px;
  --r-lg:   20px;
  --r-xl:   28px;
  --r-pill: 9999px;

  /* Spacing */
  --section:        120px;
  --section-mobile: 64px;

  /* Brand-site chrome. The site sits on cream with charcoal type. */
  --bg:      var(--cream-100);
  --bg2:     var(--cream-50);
  --accent:  var(--orange);
  --fg:      var(--charcoal);
  --muted:   rgba(26,28,32,0.58);
  --border:  rgba(26,28,32,0.12);

  --max-w:     1152px;
  --font-b:    'PP Neue Montreal', ui-sans-serif, system-ui, sans-serif;
  --font-a:    'PP Gosha Sans', ui-sans-serif, system-ui, sans-serif;
  --font-mono: 'SF Mono', 'Fira Code', Consolas, monospace;
  --radius:    var(--r-md);
  --tr:        0.18s ease;
}

/* ── Fonts ──────────────────────────────────────────────────── */
@font-face {
  font-family: 'PP Neue Montreal';
  src: url('/fonts/PPNeueMontreal-Book.woff2') format('woff2');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: 'PP Neue Montreal';
  src: url('/fonts/PPNeueMontreal-Medium.woff2') format('woff2');
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: 'PP Gosha Sans';
  src: url('/fonts/PPGoshaSans-Regular.woff2') format('woff2');
  font-weight: 400;
  font-display: swap;
}

/* ── Reset ──────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  min-height: 100%;
  overscroll-behavior-y: none;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-b);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

button { font: inherit; cursor: pointer; }

code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  background: rgba(26,28,32,0.06);
  border-radius: 4px;
  padding: 2px 6px;
}

/* ── Layout ─────────────────────────────────────────────────── */
.layout { min-height: 60vh; }
.layout > * { min-width: 0; }

/* ── Header ─────────────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 52px 32px 18px;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  color: var(--charcoal);
  text-decoration: none;
  flex-shrink: 0;
}

.header-brand:hover { text-decoration: none; }

.header-brand svg {
  width: 152px;
  height: auto;
  display: block;
}

.header-label {
  font-family: var(--font-a);
  font-size: 12px;
  letter-spacing: 0.02em;
  color: var(--charcoal);
  white-space: nowrap;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 32px;
  min-width: 0;
}

/* Matches the production site: an underline that scales out from the
   centre, tan on hover, orange when active. */
.header-nav a {
  position: relative;
  padding-bottom: 8px;
  font-family: var(--font-a);
  font-size: 18px;
  color: var(--charcoal);
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.2s;
}

.header-nav a:hover {
  color: rgba(26, 28, 32, 0.7);
  text-decoration: none;
}

.header-nav a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  border-radius: var(--r-pill);
  background: var(--tan);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.2s;
}

.header-nav a:hover::after { transform: scaleX(1); }

.header-nav a.active::after {
  background: var(--orange);
  transform: scaleX(1);
}

@media (prefers-reduced-motion: reduce) {
  .header-nav a::after { transition: none; }
}

/* ── Home nav peek ──────────────────────────────────────────── */
/* Three assets spring up above a nav item on hover, and cascade back
   down in reverse when the cursor leaves. Home page only. */
.nav-peek {
  position: absolute;
  bottom: 100%;
  left: 50%;
  margin-bottom: 16px;
  display: flex;
  gap: 8px;
  transform: translateX(-50%);
  pointer-events: none;
}

.peek-item {
  display: block;
  opacity: 0;
  transform: translateY(20px) scale(0.4);
  transition:
    transform 440ms cubic-bezier(0.34, 1.56, 0.64, 1),
    opacity 200ms ease;
}

/* Reverse cascade on the way out. */
.peek-item:nth-child(1) { transition-delay: 100ms, 100ms; }
.peek-item:nth-child(2) { transition-delay: 50ms, 50ms; }
.peek-item:nth-child(3) { transition-delay: 0ms, 0ms; }

.header-nav a:hover .peek-item,
.header-nav a:focus-visible .peek-item {
  opacity: 1;
  transform: translateY(calc(var(--peek-lift, 0px) * -1)) scale(1) rotate(var(--peek-rot, 0deg));
}

.header-nav a:hover .peek-item:nth-child(1),
.header-nav a:focus-visible .peek-item:nth-child(1) { transition-delay: 0ms, 0ms; }
.header-nav a:hover .peek-item:nth-child(2),
.header-nav a:focus-visible .peek-item:nth-child(2) { transition-delay: 60ms, 60ms; }
.header-nav a:hover .peek-item:nth-child(3),
.header-nav a:focus-visible .peek-item:nth-child(3) { transition-delay: 120ms, 120ms; }

/* A slight fan, uneven sizes and a nudged baseline so it reads as a
   handful of things rather than a row. */
.nav-peek { align-items: flex-end; }

.peek-item:nth-child(1) { --peek-rot: -9deg;  --peek-size: 42px; --peek-lift: 0;    }
.peek-item:nth-child(2) { --peek-rot: 3deg;   --peek-size: 31px; --peek-lift: 14px; }
.peek-item:nth-child(3) { --peek-rot: 11deg;  --peek-size: 37px; --peek-lift: 3px;  }

.header-nav a:nth-child(2) .peek-item:nth-child(1) { --peek-size: 33px; --peek-lift: 2px; }
.header-nav a:nth-child(2) .peek-item:nth-child(2) { --peek-size: 41px; --peek-lift: 7px; }
.header-nav a:nth-child(2) .peek-item:nth-child(3) { --peek-size: 30px; --peek-lift: 0;   }

.header-nav a:nth-child(3) .peek-item:nth-child(1) { --peek-size: 36px; --peek-lift: 0;    }
.header-nav a:nth-child(3) .peek-item:nth-child(2) { --peek-size: 44px; --peek-lift: 12px; }
.header-nav a:nth-child(3) .peek-item:nth-child(3) { --peek-size: 31px; --peek-lift: 4px;  }

.header-nav a:nth-child(4) .peek-item:nth-child(1) { --peek-size: 30px; --peek-lift: 3px;  }
.header-nav a:nth-child(4) .peek-item:nth-child(2) { --peek-size: 39px; --peek-lift: 10px; }
.header-nav a:nth-child(4) .peek-item:nth-child(3) { --peek-size: 34px; --peek-lift: 0;    }

.header-nav a:nth-child(5) .peek-item:nth-child(1) { --peek-size: 32px; --peek-lift: 2px;  }
.header-nav a:nth-child(5) .peek-item:nth-child(2) { --peek-size: 40px; --peek-lift: 11px; }
.header-nav a:nth-child(5) .peek-item:nth-child(3) { --peek-size: 30px; --peek-lift: 4px;  }

.header-nav a:nth-child(6) .peek-item:nth-child(1) { --peek-size: 38px; --peek-lift: 3px;  }
.header-nav a:nth-child(6) .peek-item:nth-child(2) { --peek-size: 30px; --peek-lift: 12px; }
.header-nav a:nth-child(6) .peek-item:nth-child(3) { --peek-size: 35px; --peek-lift: 5px;  }

/* Lucide marks in the peek need a stroke that reads at tile size. */
.peek-lucide { color: var(--charcoal); }
.peek-lucide .icon { width: 82%; height: 82%; }

.peek-tile {
  width: var(--peek-size, 42px);
  height: var(--peek-size, 42px);
  border-radius: 12px;
  background: var(--cream-50);
  border: 1px solid rgba(26, 28, 32, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.peek-tile--flat   { border-color: rgba(26, 28, 32, 0.12); }
.peek-tile--dark   { background: var(--charcoal); border-color: var(--charcoal); }
.peek-tile--orange { background: var(--orange); border-color: var(--orange); }

/* Miniature product fragments for the UI peek. */
.peek-tile--prompt {
  border-color: var(--orange);
  align-items: center;
  justify-content: flex-start;
  padding-left: 22%;
}

.peek-caret {
  width: 1px;
  height: 38%;
  background: var(--charcoal);
}

.peek-tile--stack {
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 16%;
  padding: 0 18%;
}

.peek-bar {
  width: 100%;
  height: 2px;
  border-radius: 2px;
  background: rgba(26, 28, 32, 0.22);
}

.peek-bar--short { width: 62%; }

.peek-arrow { display: flex; color: var(--orange); }
.peek-arrow .icon { width: 45%; height: auto; min-width: 12px; }

/* Artwork that reads on its own, with no tile behind it. */
.peek-tile--bare {
  background: none;
  border: none;
  border-radius: 0;
  overflow: visible;
}

.peek-tile img { display: block; width: 66%; height: 66%; }
.peek-tile--bare img { width: 100%; height: 100%; }

.peek-glyph {
  font-family: var(--font-b);
  font-weight: 500;
  font-size: calc(var(--peek-size, 42px) * 0.62);
  letter-spacing: -0.02em;
  color: var(--charcoal);
  line-height: 1;
}

.peek-glyph--accent {
  font-family: var(--font-a);
  font-weight: 400;
  font-size: calc(var(--peek-size, 42px) * 0.58);
}

@media (prefers-reduced-motion: reduce) {
  .peek-item {
    transition: opacity 120ms ease;
    transform: none;
  }
  .header-nav a:hover .peek-item,
  .header-nav a:focus-visible .peek-item { transform: none; }
}

/* Once the container stops being centred there is no margin to spill into,
   so nudge the last fan back inside rather than letting it force a scrollbar. */
@media (max-width: 1152px) {
  .header-nav a:last-child .nav-peek,
  .header-nav a:nth-last-child(2) .nav-peek {
    left: auto;
    right: -6px;
    transform: none;
  }
}

/* No room for it once the header stacks. */
@media (max-width: 900px) {
  .nav-peek { display: none; }
}

/* ── Main content ───────────────────────────────────────────── */
.main {
  position: relative;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 24px 32px 64px;
  min-width: 0;
}

.copy-md-btn {
  position: absolute;
  top: 24px;
  right: 32px;
  z-index: 5;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-a);
  font-size: 11.5px;
  letter-spacing: 0.04em;
  color: var(--fg);
  background: transparent;
  border: 1px solid var(--border);
  padding: 7px 14px;
  border-radius: var(--r-pill);
  transition: color var(--tr), border-color var(--tr), background var(--tr);
}

.copy-md-btn:hover {
  background: var(--charcoal);
  border-color: var(--charcoal);
  color: var(--cream-100);
}

.copy-md-btn .icon { width: 11px; height: 11px; }

.page-header {
  margin-bottom: 36px;
}

.page-header h1 {
  font-size: clamp(26px, 2.8vw, 34px);
  font-weight: 500;
  letter-spacing: -0.025em;
  line-height: 1.1;
}

.section-title {
  font-size: 22px;
  font-weight: 500;
  letter-spacing: -0.02em;
  margin-top: 52px;
  margin-bottom: 6px;
}

.section-title:first-of-type { margin-top: 0; }

.section-note {
  font-size: 13.5px;
  color: var(--muted);
  margin-bottom: 24px;
  line-height: 1.55;
  max-width: 640px;
}

/* ── Buttons ────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: var(--font-a);
  font-size: 13px;
  padding: 9px 18px;
  border-radius: var(--r-pill);
  border: 1px solid transparent;
  text-decoration: none;
  transition: opacity var(--tr), border-color var(--tr), color var(--tr), background var(--tr);
  line-height: 1;
}

.btn:hover { text-decoration: none; }

.btn-primary { background: var(--orange); color: #fff; }
.btn-primary:hover { background: var(--orange-hover); }

.btn-ghost { background: transparent; color: var(--fg); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--fg); }

.icon { flex-shrink: 0; }
.btn .icon { width: 13px; height: 13px; }

/* ── Home hero ──────────────────────────────────────────────── */
body.is-home .layout { display: none; }

body.is-home .site-header {
  position: static;
  min-height: 100svh;
  display: flex;
  align-items: center;
}

body.is-home .header-inner { width: 100%; }

/* ── Page transitions ───────────────────────────────────────── */
@view-transition { navigation: auto; }

.header-inner { view-transition-name: brandbar; }

::view-transition-group(brandbar) {
  animation-duration: 560ms;
  animation-timing-function: cubic-bezier(0.65, 0, 0.35, 1);
}

/* Only the destination bar is painted. Both states are the same width and
   height, so the group is a straight vertical slide; painting the outgoing
   snapshot as well would ghost it against the incoming active nav pill. */
::view-transition-old(brandbar) {
  animation: none;
  opacity: 0;
}

::view-transition-new(brandbar) {
  animation: none;
  opacity: 1;
  height: 100%;
}

/* The content is named separately so it can settle after the bar has
   finished moving, rather than cross-fading with it. */
.layout { view-transition-name: content; }

::view-transition-old(content) {
  animation: content-out 180ms cubic-bezier(0.4, 0, 1, 1) both;
}

::view-transition-new(content) {
  animation: content-in 720ms cubic-bezier(0.16, 1, 0.3, 1) 300ms both;
}

@keyframes content-out {
  to { opacity: 0; }
}

@keyframes content-in {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: none; }
}

/* Everything else is the page ground, which should not fade at all. */
::view-transition-old(root),
::view-transition-new(root) {
  animation: none;
  mix-blend-mode: normal;
}

@media (prefers-reduced-motion: reduce) {
  ::view-transition-group(*),
  ::view-transition-old(*),
  ::view-transition-new(*) { animation-duration: 1ms !important; animation-delay: 0ms !important; }
}


/* ── Swatches ───────────────────────────────────────────────── */
.swatches {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 14px;
  margin-bottom: 40px;
}

.swatch {
  border-radius: var(--r-md);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--bg2);
  display: flex;
  flex-direction: column;
}

.swatch-preview { height: 96px; flex-shrink: 0; }

.swatch-info { padding: 12px 14px 14px; }

.swatch-name { font-size: 13px; font-weight: 500; margin-bottom: 3px; }

.swatch-hex {
  font-size: 12px;
  color: var(--fg);
  font-family: var(--font-mono);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: none;
  border: none;
  padding: 0;
  transition: color var(--tr);
}

.swatch-hex:hover { color: var(--accent); }
.swatch-hex .icon { width: 12px; height: 12px; }

.swatch-usage { font-size: 11.5px; color: var(--muted); margin-top: 6px; line-height: 1.45; }
.swatch-usage code { font-size: 11px; padding: 1px 5px; }

/* ── Pairings ───────────────────────────────────────────────── */
.pairings {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 14px;
  margin-bottom: 40px;
}

.pairing {
  border-radius: var(--r-md);
  border: 1px solid var(--border);
  padding: 26px 24px 22px;
  min-height: 150px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
}

.pairing-sample { font-size: 19px; font-weight: 500; letter-spacing: -0.02em; line-height: 1.25; }

.pairing-meta {
  font-family: var(--font-mono);
  font-size: 11px;
  opacity: 0.75;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
}

.pairing-meta span:first-child { flex: 1; min-width: 0; }
.pairing-meta span:last-child { white-space: nowrap; }

/* ── Typography page ────────────────────────────────────────── */
.type-specimen {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 28px 32px 32px;
  margin-bottom: 14px;
}

.type-specimen-meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 22px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
  gap: 16px;
}

.type-specimen-name { font-family: var(--font-a); font-size: 11px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.type-specimen-detail { font-size: 12px; color: var(--muted); font-family: var(--font-mono); text-align: right; }

.specimen-display {
  font-size: clamp(30px, 4.6vw, 58px);
  font-weight: 500;
  letter-spacing: -0.035em;
  line-height: 1.05;
}

.specimen-display--accent {
  font-family: var(--font-a);
  font-weight: 400;
  font-size: clamp(30px, 7.4vw, 96px);
  letter-spacing: -0.02em;
  line-height: 1.15;
  white-space: nowrap;
}

.specimen-body { font-size: 16px; line-height: 1.65; }
.specimen-body p span { font-family: var(--font-mono); font-size: 11px; color: var(--muted); }

.glyph-row {
  font-size: clamp(18px, 2.2vw, 26px);
  line-height: 1.7;
  word-spacing: 0.1em;
  color: var(--fg);
}

.type-scale { width: 100%; border-collapse: collapse; margin-top: 8px; }

.type-scale th {
  text-align: left;
  padding: 10px 14px;
  font-family: var(--font-a);
  font-size: 10.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  border-bottom: 1px solid var(--border);
}

.type-scale td { padding: 14px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.type-scale td:nth-child(1),
.type-scale td:nth-child(2),
.type-scale td:nth-child(3) { font-family: var(--font-mono); font-size: 12px; color: var(--muted); }
.type-scale td:nth-child(1) { width: 96px; white-space: nowrap; }
.type-scale .specimen-text { font-weight: 500; letter-spacing: -0.025em; line-height: 1.1; }

.type-scale-wrap { overflow-x: auto; }

.font-links { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 20px; }

/* ── Logos page ─────────────────────────────────────────────── */
.logo-panels {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 32px;
}

.logo-panel {
  border-radius: var(--r-lg);
  padding: 48px 40px 28px;
  display: flex;
  flex-direction: column;
  gap: 28px;
  align-items: flex-start;
  border: 1px solid transparent;
}

.logo-panel svg, .logo-panel img { max-width: 210px; width: 100%; height: auto; display: block; cursor: zoom-in; }

.logo-panel--cream    { background: var(--cream-100); border-color: var(--border); color: var(--charcoal); }
.logo-panel--charcoal { background: var(--charcoal); color: var(--cream-100); }
.logo-panel--orange   { background: var(--orange); color: #fff; }
.logo-panel--tan      { background: var(--tan); color: var(--charcoal); }

.logo-panel-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  margin-top: auto;
}

.logo-panel-label { font-family: var(--font-a); font-size: 11px; letter-spacing: 0.04em; opacity: 0.7; }

.logo-panel--charcoal .btn-ghost,
.logo-panel--orange .btn-ghost { color: var(--cream-100); border-color: rgba(245,242,226,0.3); }
.logo-panel--charcoal .btn-ghost:hover,
.logo-panel--orange .btn-ghost:hover { border-color: var(--cream-100); }

.mark-panels {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-bottom: 24px;
}

.mark-panels .logo-panel {
  padding: 32px 28px 22px;
  gap: 24px;
  align-items: center;
}

.mark-panels .logo-panel img {
  width: 96px;
  height: 96px;
  max-width: 100%;
  cursor: default;
}

/* Clear space diagram */
.clearspace {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 32px;
  margin-bottom: 16px;
  display: flex;
  justify-content: center;
}

.clearspace-svg {
  width: min(560px, 100%);
  height: auto;
  display: block;
  color: var(--charcoal);
}

.cs-guide-f { opacity: 0.22; }

.cs-box {
  fill: none;
  stroke: rgba(26,28,32,0.28);
  stroke-width: 0.7;
}

.cs-bounds {
  fill: none;
  stroke: var(--orange);
  stroke-width: 0.7;
  stroke-dasharray: 3 2.5;
}

.clearspace-caption { font-size: 12px; color: var(--muted); margin-bottom: 32px; }

/* Favicons */
.favicon-row {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 14px;
  margin-bottom: 32px;
}

.favicon-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 20px 22px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.favicon-preview { flex-shrink: 0; width: 48px; height: 48px; border-radius: var(--r-sm); overflow: hidden; }
.favicon-preview img { display: block; width: 48px; height: 48px; cursor: zoom-in; }
.favicon-meta { flex: 1; min-width: 0; }
.favicon-name { font-family: var(--font-mono); font-size: 12.5px; margin-bottom: 2px; }
.favicon-format { font-size: 11px; color: var(--muted); line-height: 1.35; }

/* Do / Don't */
.guidelines {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 28px;
}

.guideline-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 22px 24px;
}

.guideline-card h4 {
  font-family: var(--font-a);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 400;
  margin-bottom: 16px;
}

.guideline-card--do h4   { color: var(--orange); }
.guideline-card--dont h4 { color: var(--muted); }

.guideline-card ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }

.guideline-card li {
  font-size: 13.5px;
  padding-left: 22px;
  position: relative;
  line-height: 1.45;
}

.guideline-card li .icon {
  position: absolute;
  left: 0;
  top: 4px;
  width: 13px;
  height: 13px;
}

.guideline-card--do li .icon   { color: var(--orange); }
.guideline-card--dont li .icon { color: var(--muted); }

/* ── Pictograms ────────────────────────────────────────────── */
.icon-anatomy {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 14px;
  margin-bottom: 24px;
}

.anatomy-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.anatomy-card img { width: 120px; height: 120px; display: block; }
.anatomy-meta { text-align: center; }
.anatomy-name { font-family: var(--font-mono); font-size: 12.5px; }
.anatomy-note { font-size: 11px; color: var(--muted); margin-top: 2px; }

.anatomy-swatches {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 24px 26px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 14px;
}

.anatomy-row {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13.5px;
  line-height: 1.4;
}

.anatomy-row strong { font-weight: 500; }
.anatomy-row code { font-size: 11.5px; }

.anatomy-dot {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  flex-shrink: 0;
}

.icon-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(132px, 1fr));
  gap: 12px;
  margin-bottom: 40px;
}

.icon-tile {
  position: relative;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 20px 12px 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  transition: border-color var(--tr);
}

.icon-tile:hover { border-color: rgba(26,28,32,0.3); }

.icon-chip img { width: 72px; height: 72px; display: block; }

.icon-name {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--muted);
  text-align: center;
  line-height: 1.35;
  word-break: break-word;
}

.icon-dl {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 26px;
  height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: var(--charcoal);
  opacity: 0;
  transition: opacity var(--tr), background var(--tr);
}

.icon-dl:hover { background: rgba(26,28,32,0.08); text-decoration: none; }
.icon-tile:hover .icon-dl,
.icon-dl:focus-visible { opacity: 1; }
.icon-dl .icon { width: 13px; height: 13px; }

@media (hover: none) {
  .icon-dl { opacity: 1; }
}

.section-subtitle {
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.01em;
  margin-top: 40px;
  margin-bottom: 6px;
}

.motion-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 14px;
  margin-bottom: 8px;
}

.motion-item {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 16px 16px 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.motion-frame {
  background: #fff;
  border-radius: var(--r-sm);
  padding: 8px;
  width: 100%;
  display: flex;
  justify-content: center;
}

.motion-frame img {
  width: 160px;
  height: 160px;
  max-width: 100%;
  display: block;
}

.motion-meta {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 8px;
  width: 100%;
  flex-wrap: wrap;
}

.motion-label {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--fg);
  word-break: break-word;
  text-align: center;
}

.motion-dur {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--muted);
}

.motion-item .btn {
  font-size: 11.5px;
  padding: 7px 13px;
}

/* ── Missing-asset callout ──────────────────────────────────── */
.gap-note {
  border: 1px dashed rgba(255,82,0,0.5);
  border-radius: var(--r-md);
  padding: 16px 20px;
  margin-bottom: 28px;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--fg);
  background: rgba(255,82,0,0.05);
}

.gap-note strong { font-weight: 500; }

/* ── Toast ──────────────────────────────────────────────────── */
.copy-toast {
  position: fixed;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%) translateY(12px);
  background: var(--charcoal);
  color: var(--cream-100);
  font-size: 13px;
  padding: 10px 20px;
  border-radius: var(--r-pill);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s, transform 0.2s;
  z-index: 9999;
  white-space: nowrap;
}

.copy-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ── Lightbox ───────────────────────────────────────────────── */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(26,28,32,0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  cursor: zoom-out;
  opacity: 0;
  transition: opacity 0.18s ease;
}

.lightbox.show { display: flex; opacity: 1; }

.lightbox-stage {
  max-width: min(92vw, 1400px);
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  cursor: default;
}

.lightbox-stage img {
  max-width: 100%;
  max-height: calc(92vh - 60px);
  display: block;
  border-radius: var(--r-sm);
  background: var(--cream-100);
}

.lightbox-caption { font-family: var(--font-mono); font-size: 12.5px; color: var(--cream-100); opacity: 0.75; }

.lightbox-close {
  position: absolute;
  top: 24px;
  right: 28px;
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(245,242,226,0.1);
  border: 1px solid rgba(245,242,226,0.18);
  color: var(--cream-100);
  border-radius: 50%;
  transition: background var(--tr), color var(--tr), transform var(--tr);
}

.lightbox-close:hover { background: var(--orange); border-color: var(--orange); transform: scale(1.05); }
.lightbox-close .icon { width: 18px; height: 18px; }

/* ── Icons page ─────────────────────────────────────────────── */
.lu-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(116px, 1fr));
  gap: 10px;
  margin-bottom: 32px;
}

.lu-tile {
  position: relative;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 20px 8px 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  transition: border-color var(--tr);
}

.lu-tile:hover { border-color: rgba(26, 28, 32, 0.3); }

.lu-chip { color: var(--fg); display: flex; }
.lu-chip .icon { width: 26px; height: 26px; }

.lu-name {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--muted);
  text-align: center;
  line-height: 1.3;
  word-break: break-word;
}

.lu-dl {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: none;
  border-radius: 50%;
  color: var(--fg);
  opacity: 0;
  transition: opacity var(--tr), background var(--tr);
}

.lu-dl:hover { background: rgba(26, 28, 32, 0.08); }
.lu-tile:hover .lu-dl,
.lu-dl:focus-visible { opacity: 1; }
.lu-dl .icon { width: 12px; height: 12px; }

@media (hover: none) {
  .lu-dl { opacity: 1; }
}

/* ── UI page ────────────────────────────────────────────────── */
/* Roles and palette list */
.ui-roles {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 10px 20px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 22px 26px;
  margin-bottom: 40px;
}

.ui-role {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13.5px;
  line-height: 1.4;
}

.ui-role strong { font-weight: 500; }
.ui-role code { font-size: 11.5px; }

.ui-role-chip {
  width: 20px;
  height: 20px;
  border-radius: 6px;
  border: 1px solid rgba(26, 28, 32, 0.12);
  flex-shrink: 0;
}

/* ── The product mock ───────────────────────────────────────── */
/* Self-contained token set. Declared on .ui-app, never on :root, so the
   product values cannot reach the surrounding page. */
.ui-frame {
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
  margin-bottom: 24px;
}

.ui-app {
  --ui-bg:      #f7f6f2;
  --ui-panel:   #f1efea;
  --ui-card:    #ffffff;
  --ui-border:  rgba(26, 28, 32, 0.09);
  --ui-text:    #1a1c20;
  --ui-text-2:  rgba(26, 28, 32, 0.56);
  --ui-text-3:  rgba(26, 28, 32, 0.36);
  --ui-accent:  #ff5200;
  --ui-select:  #f3c892;
  --ui-fill:    #eeece6;   /* chips, tags */
  --ui-idle:    #e8e6e0;   /* send button at rest */
  --ui-art:     #f5f3ee;   /* pictogram plate */
  --ui-r-sm:    6px;
  --ui-r-md:    8px;
  --ui-r-lg:    12px;

  background: var(--ui-bg);
  color: var(--ui-text);
  font-family: var(--font-b);
  font-size: 13px;
  line-height: 1.45;
}

/* Dark is derived from the brand palette rather than designed: charcoal
   grounds, cream text, orange and tan unchanged. The pictogram plate stays
   light because the pictograms have no reversed colourway. */
.ui-app[data-theme="dark"] {
  --ui-bg:      #14161a;
  --ui-panel:   #1a1c20;
  --ui-card:    #23262b;
  --ui-border:  rgba(245, 242, 226, 0.11);
  --ui-text:    #f5f2e2;
  --ui-text-2:  rgba(245, 242, 226, 0.58);
  --ui-text-3:  rgba(245, 242, 226, 0.36);
  --ui-fill:    rgba(245, 242, 226, 0.09);
  --ui-idle:    rgba(245, 242, 226, 0.1);
  --ui-art:     #f5f3ee;
}

.ui-app .icon { width: 14px; height: 14px; }

/* The mark has no single colourway that works on both grounds. */
.ui-app .ui-mark--dark { display: none; }
.ui-app[data-theme="dark"] .ui-mark--light { display: none; }
.ui-app[data-theme="dark"] .ui-mark--dark { display: block; }

/* Preview control, styled as site chrome rather than part of the mock. */
.ui-preview-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.ui-preview-label {
  font-family: var(--font-a);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.ui-switch {
  display: inline-flex;
  gap: 2px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-pill);
  padding: 2px;
}

.ui-switch button {
  font-family: var(--font-a);
  font-size: 12px;
  padding: 5px 14px;
  border: none;
  border-radius: var(--r-pill);
  background: none;
  color: var(--muted);
  transition: background var(--tr), color var(--tr);
}

.ui-switch button:hover { color: var(--fg); }

.ui-switch button[aria-pressed="true"] {
  background: var(--charcoal);
  color: var(--cream-100);
}

/* App bar */
.ui-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--ui-border);
}

.ui-bar-left, .ui-bar-right { display: flex; align-items: center; gap: 14px; }

.ui-launcher { color: var(--ui-text); display: flex; }
.ui-launcher .icon { width: 17px; height: 17px; }

.ui-brand { display: flex; align-items: center; }
.ui-brand img { display: block; }


.ui-user-name { font-size: 13px; color: var(--ui-text); }

.ui-avatar {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-a);
  font-size: 8.5px;
  letter-spacing: 0.02em;
  /* Fixed, not themed: the background is a brand colour either way. */
  color: #1a1c20;
  flex-shrink: 0;
}

.ui-avatar--lg { width: 30px; height: 30px; font-size: 10.5px; }

/* Body split */
.ui-body {
  display: grid;
  grid-template-columns: 52fr 48fr;
  gap: 24px;
  padding: 24px 20px 26px;
  align-items: stretch;
}

/* Left: start panel */
.ui-start {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 34px 8px 0;
  min-width: 0;
}

.ui-start-mark { display: block; margin-bottom: 22px; }

.ui-start-title {
  font-size: clamp(20px, 2.1vw, 28px);
  font-weight: 400;
  letter-spacing: -0.03em;
  line-height: 1.1;
  text-align: center;
  margin-bottom: 26px;
  color: var(--ui-text);
}

.ui-prompt {
  width: 100%;
  background: var(--ui-card);
  border: 1px solid var(--ui-accent);
  border-radius: var(--ui-r-md);
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 10px 0 16px;
  margin-bottom: 14px;
}

.ui-prompt-caret {
  width: 1px;
  height: 17px;
  background: var(--ui-text);
}

.ui-prompt-actions { display: flex; align-items: center; gap: 8px; }

.ui-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  flex-shrink: 0;
}

.ui-icon-btn--quiet { width: 24px; height: 24px; color: var(--ui-text-2); }

.ui-icon-btn--dark {
  width: 28px;
  height: 28px;
  background: var(--ui-text);
  color: var(--ui-bg);
}

.ui-icon-btn--send {
  width: 28px;
  height: 28px;
  border-radius: var(--ui-r-sm);
  background: var(--ui-idle);
  color: var(--ui-text-3);
}

.ui-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  width: 100%;
  margin-bottom: 30px;
}

.ui-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: var(--ui-fill);
  border-radius: var(--ui-r-sm);
  padding: 7px 11px;
  font-size: 11px;
  color: var(--ui-text);
  line-height: 1.2;
}

.ui-chip .icon { width: 11px; height: 11px; color: var(--ui-accent); }

.ui-version {
  font-family: var(--font-a);
  font-size: 10.5px;
  color: var(--ui-text-3);
  margin-bottom: 30px;
}

.ui-cta {
  width: 100%;
  margin-top: auto;
  background: var(--ui-text);
  color: var(--ui-bg);
  border-radius: var(--ui-r-md);
  padding: 17px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-a);
  font-size: 14px;
}

.ui-cta .icon { color: var(--ui-accent); width: 15px; height: 15px; }

/* Right rail */
.ui-rail { display: flex; flex-direction: column; gap: 16px; min-width: 0; }

.ui-panel {
  background: var(--ui-panel);
  border-radius: var(--ui-r-lg);
  padding: 16px;
  min-width: 0;
}

.ui-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.ui-panel-head h4 {
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.01em;
  margin: 0;
}

.ui-panel-nav { display: flex; gap: 6px; }

.ui-step {
  width: 22px;
  height: 22px;
  border-radius: var(--ui-r-sm);
  background: var(--ui-card);
  color: var(--ui-text-2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.ui-step .icon { width: 11px; height: 11px; }

.ui-viewall {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11.5px;
  color: var(--ui-text);
}

.ui-viewall .icon { width: 11px; height: 11px; color: var(--ui-accent); }

/* Apps row, deliberately clipped to imply horizontal paging */
/* Deliberately overflows so the last card is cut by the panel edge, which
   is what implies there is more to page through. */
.ui-apps {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 29%);
  gap: 10px;
  overflow: hidden;
}

.ui-app-card {
  background: var(--ui-card);
  border-radius: var(--ui-r-md);
  padding: 10px 10px 12px;
  min-width: 0;
}

.ui-app-art {
  background: var(--ui-art);
  border-radius: var(--ui-r-sm);
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 10px;
}

.ui-app-art img { display: block; width: 48px; height: 48px; }

.ui-app-name {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 12.5px;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ui-app-name .icon { width: 11px; height: 11px; color: var(--ui-accent); flex-shrink: 0; }

.ui-app-sub {
  font-size: 10.5px;
  color: var(--ui-text-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ui-rail-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  min-width: 0;
}

.ui-stack { display: flex; flex-direction: column; gap: 10px; }

.ui-card {
  background: var(--ui-card);
  border-radius: var(--ui-r-md);
  padding: 12px 12px 12px 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.ui-card-body { flex: 1; min-width: 0; }

.ui-card-title {
  font-size: 13px;
  letter-spacing: -0.01em;
  margin-bottom: 4px;
}

.ui-card-desc {
  font-size: 11px;
  line-height: 1.45;
  color: var(--ui-text-2);
  margin-bottom: 10px;
}

.ui-card-row { display: flex; align-items: center; gap: 8px; }

.ui-meta { font-size: 10.5px; color: var(--ui-text-2); }
.ui-meta strong { font-weight: 500; color: var(--ui-text); }

.ui-live {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--ui-accent);
  font-weight: 500;
}

.ui-live-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--ui-accent);
}

.ui-tag {
  font-size: 9.5px;
  background: var(--ui-fill);
  border-radius: 4px;
  padding: 3px 7px;
  color: var(--ui-text);
  white-space: nowrap;
}

.ui-avatars { display: flex; }

.ui-avatars .ui-avatar {
  width: 19px;
  height: 19px;
  font-size: 7.5px;
  border: 1.5px solid var(--ui-card);
  margin-left: -5px;
}

.ui-avatars .ui-avatar:first-child { margin-left: 0; }

.ui-chevron { color: var(--ui-text-3); display: flex; flex-shrink: 0; }
.ui-chevron .icon { width: 13px; height: 13px; }

/* ── Mock interactivity ─────────────────────────────────────── */
/* Anything that would be clickable in the real product gets a pointer and a
   hover state, so the preview shows the interaction design too. */
.ui-launcher,
.ui-icon-btn,
.ui-chip,
.ui-cta,
.ui-step,
.ui-viewall,
.ui-card,
.ui-app-card { cursor: pointer; }

.ui-launcher,
.ui-icon-btn,
.ui-chip,
.ui-cta,
.ui-step,
.ui-card,
.ui-app-card {
  transition: background 0.15s ease, color 0.15s ease, opacity 0.15s ease;
}

.ui-launcher { color: var(--ui-text-2); }
.ui-launcher:hover { color: var(--ui-text); }

.ui-icon-btn--quiet:hover { background: var(--ui-fill); color: var(--ui-text); }
.ui-icon-btn--dark:hover { opacity: 0.85; }
.ui-icon-btn--send:hover { background: var(--ui-accent); color: #fff; }

.ui-chip:hover { background: var(--ui-select); color: #1a1c20; }
.ui-cta:hover { opacity: 0.88; }
.ui-step:hover { background: var(--ui-text); color: var(--ui-bg); }
.ui-viewall:hover { color: var(--ui-accent); }

/* Cards sit on a panel, so they lift by tinting rather than moving. */
.ui-card:hover,
.ui-app-card:hover { background: var(--ui-card-hover); }

.ui-app { --ui-card-hover: #fbfaf7; }
.ui-app[data-theme="dark"] { --ui-card-hover: #2b2f35; }

/* Tooltips, scoped to the mock. The frame clips, so anything near the top
   edge opens downward instead. */
.ui-tt { position: relative; }

.ui-tt::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) translateY(3px);
  background: var(--ui-text);
  color: var(--ui-bg);
  font-family: var(--font-b);
  font-size: 11px;
  line-height: 1;
  padding: 6px 9px;
  border-radius: var(--ui-r-sm);
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s ease, transform 0.15s ease;
  z-index: 5;
}

.ui-tt:hover::after {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.ui-tt--below::after {
  bottom: auto;
  top: calc(100% + 8px);
  transform: translateX(-50%) translateY(-3px);
}

.ui-tt--below:hover::after { transform: translateX(-50%) translateY(0); }

@media (prefers-reduced-motion: reduce) {
  .ui-launcher, .ui-icon-btn, .ui-chip, .ui-cta,
  .ui-step, .ui-card, .ui-app-card, .ui-tt::after { transition: none; }
}

@media (max-width: 1000px) {
  .ui-body { grid-template-columns: 1fr; gap: 28px; }
  .ui-cta { margin-top: 8px; }
}

@media (max-width: 620px) {
  .ui-rail-split { grid-template-columns: 1fr; }
  .ui-apps { grid-auto-columns: minmax(0, 58%); }
  .ui-body { padding: 18px 14px 20px; }
  .ui-bar { padding: 12px 14px; }
  .ui-user-name { display: none; }
}

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 980px) {
  .header-inner { padding: 40px 24px 16px; }
  .main { padding: 20px 24px 56px; }
  .copy-md-btn { top: 20px; right: 24px; }
  .mark-panels { grid-template-columns: repeat(2, 1fr); }
  .icon-anatomy { grid-template-columns: 1fr; }
}

/* Six nav items plus the wordmark need about 840px on one row, so the header
   has to stack well before the rest of the page does. */
@media (max-width: 900px) {
  .header-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
    padding: 28px 20px 14px;
  }

  .header-brand svg { width: 124px; }

  .header-nav {
    width: 100%;
    gap: 20px;
    overflow-x: auto;
    scrollbar-width: none;
    padding-bottom: 2px;
  }

  .header-nav::-webkit-scrollbar { display: none; }
  .header-nav a { font-size: 15px; }
}

@media (max-width: 768px) {
  .main { padding: 28px 20px 48px; }

  .copy-md-btn {
    position: static;
    margin-bottom: 20px;
  }

  .logo-panels,
  .guidelines { grid-template-columns: 1fr; }

  .mark-panels { grid-template-columns: repeat(2, 1fr); }
}

