:root {
  --ink: #0a0a0a;
  --body: #525252;
  --muted: #737373;
  --line: #e7e7e7;
  --soft: #f5f5f5;
  --softer: #fafafa;
  --blue: #2563eb;
  --blue-hover: #1d4ed8;
  --blue-tint: #eff6ff;
  --light-blue: #93c5fd;
  --deep-blue: #1e40af;
  --ok: #dcfce7;
  --ok-ink: #166534;
  --warn: #fef3c7;
  --warn-ink: #92400e;
  --pink: #fce7f3;
  --violet: #f3e8ff;
  --bg: #fff;
  --surface: #fff;
  --heading: #000;
  --topbar: rgba(255,255,255,.92);
  --cta-line: #dbeafe;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font: 450 15px/1.5 Inter, system-ui, -apple-system, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
  background: var(--bg);
  color: var(--ink);
  color-scheme: light;
  scrollbar-color: #bbb var(--soft);
}
* { box-sizing: border-box; }
html { scroll-padding-top: 76px; }
body, h1, h2, h3, p, ol, ul { margin: 0; }
body { background: var(--bg); }
ol, ul { padding: 0; list-style: none; }
a { color: inherit; text-underline-offset: 4px; }
button, input, textarea, select, code { font: inherit; color: inherit; }
button, summary { cursor: pointer; }
button {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  min-height: 40px; padding: 0 14px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 8px;
  font-weight: 550; font-size: 14px; white-space: nowrap;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
button:disabled { opacity: .45; cursor: default; }
button:active:not(:disabled) { transform: translateY(1px); }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; }
::selection { color: var(--heading); background: var(--light-blue); }
input, textarea { caret-color: var(--blue); }
[hidden] { display: none !important; }
code { font-family: var(--mono); font-size: .92em; font-variant-numeric: tabular-nums; }
.frame { width: min(100%, 1240px); padding-inline: clamp(16px, 3vw, 32px); margin-inline: auto; }
.skip { position: absolute; top: -80px; left: 16px; }
.skip:focus { top: 8px; z-index: 30; padding: 10px; background: var(--surface); }
.sr, .clipboard-helper { position: absolute; width: 1px; height: 1px; clip-path: inset(50%); overflow: hidden; }

/* Dark theme */
:root[data-theme=dark] {
  --bg: #0b0b0c;
  --surface: #151517;
  --heading: #fafafa;
  --ink: #ededed;
  --body: #b4b4b8;
  --muted: #8d8d93;
  --line: #2a2a2e;
  --soft: #202024;
  --softer: #111113;
  --blue: #3b82f6;
  --blue-hover: #2563eb;
  --blue-tint: #172036;
  --deep-blue: #93c5fd;
  --ok: #12321f;
  --ok-ink: #86efac;
  --warn: #3a2a0c;
  --warn-ink: #fcd34d;
  --pink: #3b1a2c;
  --violet: #2a1d3a;
  --topbar: rgba(11,11,12,.88);
  --cta-line: #1e2a44;
  color-scheme: dark;
  scrollbar-color: #444 var(--softer);
}
:root[data-theme=dark] .workspace, :root[data-theme=dark] .cphero { box-shadow: 0 1px 2px rgba(0,0,0,.4), 0 12px 32px -12px rgba(0,0,0,.6); }
:root[data-theme=dark] .nohits { border-color: #3a3a3f; }
:root[data-theme=dark] .pill:hover { border-color: #4a4a50; }
:root[data-theme=dark] .btn-ghost[aria-pressed=true] { border-color: #9d3b6e; }

/* Theme toggle */
.mast-end { display: flex; align-items: center; gap: 6px; margin-left: 4px; }
.mast nav { margin-left: auto; }
.themebtn { width: 38px; min-height: 38px; padding: 0; border-radius: 9px; background: transparent; color: var(--body); }
.themebtn:hover { background: var(--soft); color: var(--ink); }
.themebtn .i-sun { display: none; }
:root[data-theme=dark] .themebtn .i-sun { display: block; }
:root[data-theme=dark] .themebtn .i-moon { display: none; }

/* Top bar */
.top { position: sticky; top: 0; z-index: 20; background: var(--topbar); backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--line); }
.mast { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 60px; }
.wordmark { display: inline-flex; align-items: center; gap: 8px; font-size: 17px; font-weight: 750; letter-spacing: -.02em; text-decoration: none; }
.wordmark svg { color: var(--blue); flex: none; }
.mast nav { display: flex; align-items: center; gap: 4px; }
.mast nav a { padding: 7px 11px; border-radius: 8px; font-size: 14px; font-weight: 550; color: var(--body); text-decoration: none; }
.mast nav a:hover { color: var(--ink); background: var(--soft); }

/* Tool header */
.apphead { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; flex-wrap: wrap; padding: 28px 0 18px; }
.apptitle { max-width: 720px; }
.apphead h1 { font-size: clamp(26px, 3.2vw, 34px); font-weight: 800; line-height: 1.12; letter-spacing: -.03em; color: var(--heading); }
.apphead p { margin-top: 8px; color: var(--body); font-size: 15.5px; line-height: 1.5; }
.badges { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.badges li { padding: 3px 10px; border-radius: 999px; background: var(--soft); color: var(--body); font-size: 12.5px; font-weight: 550; }
.badges li:first-child { background: var(--blue-tint); color: var(--deep-blue); }
.appactions { display: flex; align-items: center; gap: 8px; }
.btn-ghost { background: var(--surface); }
.btn-ghost:hover { background: var(--soft); }
.btn-ghost[aria-pressed=true] { background: var(--pink); border-color: #f9a8d4; }
.btn-ghost[aria-pressed=true] svg { fill: currentColor; }
.sharemsg:not(:empty) { font-size: 13px; color: var(--ok-ink); }

/* Workspace */
.workspace {
  display: grid; grid-template-columns: 330px minmax(0, 1fr);
  border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: var(--surface);
  box-shadow: 0 1px 2px rgba(0,0,0,.04), 0 12px 32px -12px rgba(0,0,0,.10);
}
.browse { display: flex; flex-direction: column; gap: 12px; padding: 16px; background: var(--softer); border-right: 1px solid var(--line); min-width: 0; }
.search { display: flex; align-items: center; gap: 9px; height: 42px; padding: 0 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; }
.search:focus-within { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(37,99,235,.15); }
.search svg { flex: none; color: var(--muted); }
.search input { flex: 1; min-width: 0; height: 100%; border: 0; outline: none; background: transparent; font-size: 14.5px; }
.filters { display: flex; flex-wrap: wrap; gap: 6px; }
.pill { min-height: 30px; padding: 0 10px; gap: 6px; border-radius: 999px; font-size: 13px; font-weight: 550; color: var(--body); }
.pill i { width: 9px; height: 9px; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(0,0,0,.12); }
.pill:hover { border-color: #cfcfcf; color: var(--ink); }
.pill[aria-pressed=true] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.listhead { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 13px; color: var(--muted); font-weight: 550; }
.btn-sm { min-height: 32px; padding: 0 11px; font-size: 13px; border-radius: 8px; background: var(--blue); border-color: var(--blue); color: #fff; }
.btn-sm:hover:not(:disabled) { background: var(--blue-hover); border-color: var(--blue-hover); }
.btn-sm.ghost { background: var(--surface); border-color: var(--line); color: var(--ink); }
.btn-sm.ghost:hover:not(:disabled) { background: var(--soft); border-color: var(--line); }
.hint { padding: 8px 10px; border-radius: 8px; background: var(--blue-tint); color: var(--deep-blue); font-size: 13px; line-height: 1.4; }
.library { display: grid; gap: 2px; max-height: 452px; overflow-y: auto; margin: 0 -6px; padding: 0 6px 2px; overscroll-behavior: contain; }
.chip { justify-content: flex-start; gap: 10px; width: 100%; min-height: 40px; padding: 5px 8px; border: 0; border-radius: 8px; background: transparent; font-weight: 500; }
.chip:hover { background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.chip[aria-pressed=true] { background: var(--surface); box-shadow: inset 0 0 0 1.5px var(--blue); }
.paint { width: 24px; height: 24px; flex: none; border-radius: 6px; box-shadow: inset 0 0 0 1px rgba(0,0,0,.1); }
.cname { flex: 1; min-width: 0; text-align: left; overflow: hidden; text-overflow: ellipsis; }
.chex { font-family: var(--mono); font-size: 12px; color: var(--muted); }
.nohits { padding: 14px; border-radius: 10px; background: var(--surface); border: 1px dashed #d4d4d4; font-size: 14px; color: var(--body); }
.nohits p { margin-bottom: 10px; }

.inspect { display: flex; flex-direction: column; min-width: 0; scroll-margin-top: 72px; }
.preview { position: relative; display: flex; flex-direction: column; justify-content: flex-end; min-height: 230px; padding: 18px 24px; background: var(--sample); transition: background-color .2s ease; }
.ptag { position: absolute; top: 14px; left: 24px; font-size: 11.5px; font-weight: 650; letter-spacing: .08em; text-transform: uppercase; opacity: .62; }
.pmain { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.pname { font-size: clamp(34px, 4.4vw, 52px); font-weight: 800; letter-spacing: -.035em; line-height: 1; overflow-wrap: anywhere; }
.phex { font-family: var(--mono); font-size: 15px; font-weight: 600; opacity: .8; }
.details { padding: 20px 24px 24px; }
.titlerow { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.preview .fam { display: block; margin-bottom: 4px; font-size: 13px; font-weight: 600; opacity: .72; }
h2.pname { margin: 0; }
.copyrow { display: flex; gap: 8px; flex-wrap: wrap; }
.primary { background: var(--blue); border-color: var(--blue); color: #fff; }
.primary:hover:not(:disabled) { background: var(--blue-hover); border-color: var(--blue-hover); }
.secondary:hover { background: var(--soft); }
.desc { flex: 1 1 280px; max-width: 64ch; color: var(--body); font-size: 15px; }
.notice { min-height: 22px; margin-top: 6px; font-size: 13px; }
.notice:not(:empty) { display: inline-block; padding: 1px 9px; border-radius: 6px; background: var(--ok); color: var(--ok-ink); font-weight: 550; }
.values { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 8px; }
.val { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 4px 4px 4px 12px; border: 1px solid var(--line); border-radius: 10px; min-width: 0; }
.val .k { width: 62px; flex: none; font-size: 11px; font-weight: 650; letter-spacing: .07em; text-transform: uppercase; color: var(--muted); }
.val code { flex: 1; min-width: 0; font-size: 13.5px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.icon { width: 34px; min-height: 34px; padding: 0; border: 0; border-radius: 7px; background: transparent; color: var(--muted); }
.icon:hover { background: var(--soft); color: var(--ink); }
.val.wide { grid-column: 1 / -1; }
.val.contrast { grid-column: 1 / -1; flex-wrap: wrap; row-gap: 4px; padding-block: 8px; }
.cv { display: inline-flex; align-items: center; gap: 6px; margin-right: 18px; font-size: 13.5px; color: var(--body); }
.cv b { color: var(--ink); font-variant-numeric: tabular-nums; }
.cv em { font-style: normal; font-size: 11px; font-weight: 700; padding: 1px 7px; border-radius: 999px; background: var(--warn); color: var(--warn-ink); }
.cv em.pass { background: var(--ok); color: var(--ok-ink); }
.label { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; margin: 20px 0 8px; font-size: 11.5px; font-weight: 650; letter-spacing: .07em; text-transform: uppercase; color: var(--muted); }
.label span { text-transform: none; letter-spacing: 0; font-weight: 500; font-size: 12px; color: #a3a3a3; }
.ramp { display: grid; grid-template-columns: repeat(9, minmax(0, 1fr)); gap: 4px; }
.step { min-height: 40px; padding: 0; border: 0; border-radius: 6px; box-shadow: inset 0 0 0 1px rgba(0,0,0,.08); transition: transform .12s ease; }
.step:hover { transform: translateY(-2px); }
.step[aria-current=true] { box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px var(--ink); }
.near { display: flex; flex-wrap: wrap; gap: 6px; }
.nearchip { min-height: 34px; padding: 0 12px 0 6px; gap: 7px; border-radius: 999px; font-size: 13.5px; font-weight: 550; }
.nearchip .paint { width: 22px; height: 22px; border-radius: 50%; }
.nearchip:hover { background: var(--soft); }
.nojs { padding: 12px 16px; color: var(--body); }

/* Content blocks */
.block { padding: 56px 0 0; }
.sec-head { margin-bottom: 20px; }
.sec-head h2 { font-size: 24px; font-weight: 800; letter-spacing: -.025em; line-height: 1.2; color: var(--heading); }
.sec-head p { margin-top: 6px; max-width: 68ch; color: var(--body); }
.card { border: 1px solid var(--line); border-radius: 14px; padding: 20px; background: var(--surface); }
.card h3 { font-size: 16px; font-weight: 700; letter-spacing: -.01em; margin-bottom: 6px; }
.card p { color: var(--body); font-size: 14.5px; line-height: 1.6; }
.steps3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.num { display: inline-grid; place-items: center; width: 28px; height: 28px; margin-bottom: 12px; border-radius: 8px; background: var(--blue-tint); color: var(--blue); font-size: 13px; font-weight: 750; }
.tablewrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; }
table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
thead th { padding: 11px 16px; background: var(--softer); border-bottom: 1px solid var(--line); text-align: left; font-size: 11.5px; font-weight: 650; letter-spacing: .07em; text-transform: uppercase; color: var(--muted); }
tbody th, tbody td { padding: 12px 16px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
tbody tr:last-child th, tbody tr:last-child td { border-bottom: 0; }
tbody th { font-weight: 650; white-space: nowrap; }
tbody td:last-child { color: var(--body); }
.names { display: flex; flex-wrap: wrap; gap: 6px 14px; }
.tname { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.tname i { width: 12px; height: 12px; border-radius: 4px; box-shadow: inset 0 0 0 1px rgba(0,0,0,.1); }
.tips { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.tips .card { background: var(--softer); }
.faqgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 32px; align-items: start; }
details { border-bottom: 1px solid var(--line); }
summary { display: flex; justify-content: space-between; gap: 16px; padding: 15px 0; font-weight: 600; list-style: none; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; flex: none; color: var(--blue); font-size: 20px; line-height: 1; font-weight: 500; }
details[open] summary::after { content: "−"; }
details p { padding-bottom: 16px; color: var(--body); line-height: 1.6; max-width: 70ch; }

/* Discussion */
.discussion { max-width: 760px; padding-bottom: 64px; }
.discussion h2 span { font-size: 15px; font-weight: 600; color: var(--muted); letter-spacing: 0; }
.discussion form label { display: grid; gap: 6px; font-size: 14px; font-weight: 550; }
.discussion textarea, .discussion input { padding: 10px 12px; background: var(--softer); border: 1px solid var(--line); border-radius: 8px; font-size: 14.5px; }
.discussion textarea:focus, .discussion input:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(37,99,235,.15); }
.discussion textarea { width: 100%; min-height: 96px; resize: vertical; }
.postrow { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; margin-top: 10px; }
.replyto:not(:empty) { font-size: 13px; color: var(--muted); }
[data-gf-comment-msg] { margin-top: 8px; font-size: 13.5px; color: var(--body); }
[data-gf-comments] { margin-top: 16px; }
[data-gf-comments] li { padding: 14px 0; border-bottom: 1px solid var(--line); }
[data-gf-comments] li p { margin: 4px 0 8px; color: var(--body); }
[data-gf-c-replies] { margin-left: 18px; border-left: 2px solid var(--line); padding-left: 14px; }
.cmeta time { font-size: 12.5px; color: var(--muted); }
.ownertag { font-size: 11px; font-weight: 700; padding: 1px 7px; border-radius: 999px; background: var(--blue-tint); color: var(--deep-blue); }
[data-gf-owner] { background: var(--violet); border-radius: 10px; padding-inline: 12px; }
[data-gf-comments][data-gf-empty]::after { content: "No notes yet. Which shade should join the collection?"; display: block; padding: 14px 0; color: var(--muted); }

/* Footer */
.bottom { margin-top: 24px; background: var(--softer); border-top: 1px solid var(--line); }
.foot { display: flex; justify-content: space-between; align-items: flex-start; gap: 24px; flex-wrap: wrap; padding-block: 28px 18px; }
.fbrand p { margin-top: 6px; color: var(--body); font-size: 14px; }
.foot nav { display: flex; gap: 20px; flex-wrap: wrap; }
.foot nav a { font-size: 14px; font-weight: 550; color: var(--body); text-decoration: none; }
.foot nav a:hover { color: var(--ink); text-decoration: underline; }
.fbase { padding-block: 14px 24px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }

/* Legal */
.legal { max-width: 72ch; margin: 36px auto 64px; }
.legal .back { font-size: 14px; font-weight: 550; color: var(--blue); text-decoration: none; }
.legal .back:hover { text-decoration: underline; }
.legal h1 { margin: 16px 0 10px; font-size: clamp(28px, 4vw, 36px); font-weight: 800; letter-spacing: -.03em; line-height: 1.15; }
.legal .lead { font-size: 16px; }
.legal h2 { margin: 30px 0 8px; font-size: 18px; font-weight: 700; letter-spacing: -.01em; }
.legal p { color: var(--body); line-height: 1.65; margin-bottom: 10px; }

@media (max-width: 960px) {
  .workspace { grid-template-columns: 1fr; }
  .browse { border-right: 0; border-bottom: 1px solid var(--line); }
  .library { grid-template-columns: repeat(2, minmax(0, 1fr)); max-height: 296px; }
  .steps3 { grid-template-columns: 1fr 1fr; }
  .faqgrid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .mast { height: 56px; }
  .hide-sm { display: none; }
  .mast nav a { padding: 6px 9px; font-size: 13.5px; }
  .apphead { padding: 20px 0 14px; gap: 12px; }
  .appactions { width: 100%; }
  .browse { padding: 12px; }
  .chex { display: none; }
  .preview { min-height: 170px; padding: 14px 16px; }
  .ptag { left: 16px; top: 12px; }
  .details { padding: 16px; }
  .copyrow { width: 100%; }
  .copyrow button { flex: 1; }
  .values { grid-template-columns: 1fr; }
  .ramp { gap: 3px; }
  .step { min-height: 34px; border-radius: 5px; }
  .block { padding-top: 40px; }
  .steps3, .tips { grid-template-columns: 1fr; }
  .sec-head h2 { font-size: 21px; }
  tbody th, tbody td, thead th { padding: 10px 12px; }
  .postrow label { width: 100%; }
}
@media (max-width: 360px) {
  .library { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}

/* Color pages */
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; padding-top: 22px; font-size: 13px; color: var(--muted); }
.crumbs a { color: var(--blue); text-decoration: none; font-weight: 550; }
.crumbs a:hover { text-decoration: underline; }
.crumbs [aria-current] { color: var(--ink); font-weight: 550; }
.cphead { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding: 10px 0 18px; }
.cphead h1 { font-size: clamp(28px, 3.6vw, 38px); font-weight: 800; letter-spacing: -.03em; line-height: 1.1; }
.cphead .lead { margin-top: 8px; max-width: 70ch; color: var(--body); font-size: 15.5px; }
.cphero { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.3fr); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; box-shadow: 0 1px 2px rgba(0,0,0,.04), 0 12px 32px -12px rgba(0,0,0,.10); }
.cpswatch { position: relative; display: flex; align-items: flex-end; min-height: 300px; padding: 20px 24px; }
.cpswatch > div { display: flex; flex-direction: column; gap: 4px; }
.cpname { font-size: clamp(40px, 5vw, 60px); font-weight: 800; letter-spacing: -.035em; line-height: 1; }
.cpvalues { padding: 20px 24px 22px; }
.cpvalues h2 { font-size: 13px; font-weight: 650; letter-spacing: .07em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.cpvalues .values { margin-top: 8px; }
.cpvalues .val:nth-child(5) { grid-column: 1 / -1; }
.guide { display: inline-block; margin-top: 14px; font-size: 14px; font-weight: 600; color: var(--blue); text-decoration: none; }
.guide:hover { text-decoration: underline; }
.cpramp { display: grid; grid-template-columns: repeat(9, minmax(0, 1fr)); gap: 6px; }
.cpstep { flex-direction: column; align-items: flex-start; justify-content: flex-end; gap: 2px; min-height: 104px; padding: 10px; border: 0; border-radius: 10px; box-shadow: inset 0 0 0 1px rgba(0,0,0,.08); text-align: left; transition: transform .12s ease; }
.cpstep:hover { transform: translateY(-2px); }
.cpstep b { font-family: var(--mono); font-size: 12.5px; font-weight: 650; }
.cpstep span { font-size: 11.5px; font-weight: 500; opacity: .8; white-space: normal; }
.cpstep.is-base { box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px var(--ink); }
.palgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.pal { padding: 0; overflow: hidden; }
.pal h3, .pal p { padding-inline: 18px; }
.pal h3 { margin-top: 14px; }
.pal p { padding-bottom: 16px; }
.palbar { display: flex; height: 112px; }
.palbar button { flex: 1; flex-direction: column; align-items: flex-start; justify-content: flex-end; gap: 1px; min-width: 0; height: 100%; padding: 10px; border: 0; border-radius: 0; text-align: left; transition: flex-grow .2s ease; }
.palbar button:hover { flex-grow: 1.35; }
.palbar span { font-size: 12px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.palbar b { font-family: var(--mono); font-size: 11.5px; font-weight: 600; opacity: .85; }
.palbar.sm { height: 64px; border-radius: 10px; overflow: hidden; box-shadow: inset 0 0 0 1px rgba(0,0,0,.06); }
.harm { margin-top: 16px; background: var(--softer); }
.harm > p { margin-bottom: 14px; }
.harmrows { display: grid; gap: 10px; }
.harmrow { display: grid; grid-template-columns: 130px minmax(0, 1fr); align-items: center; gap: 12px; }
.hlabel { font-size: 13px; font-weight: 650; color: var(--body); }
.hexbtn { min-height: 28px; padding: 0 8px; border-radius: 6px; font-family: var(--mono); font-size: 12.5px; font-weight: 600; background: var(--soft); border-color: transparent; }
.hexbtn:hover { border-color: var(--line); background: var(--surface); }
.cmpgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.pair { display: flex; height: 64px; margin-bottom: 14px; border-radius: 10px; overflow: hidden; box-shadow: inset 0 0 0 1px rgba(0,0,0,.06); }
.pair span { flex: 1; }
.cmp .meta { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-bottom: 6px; font-size: 13px; color: var(--muted); }
.prose { max-width: 760px; }
.prose h2 { font-size: 24px; font-weight: 800; letter-spacing: -.025em; line-height: 1.2; margin: 36px 0 12px; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { font-size: 17px; font-weight: 700; margin: 22px 0 8px; }
.prose p { color: var(--body); line-height: 1.7; margin-bottom: 14px; font-size: 15.5px; }
.prose img { display: block; width: 100%; height: auto; margin: 18px 0 20px; border-radius: 14px; border: 1px solid var(--line); }
.prose code { padding: 1px 6px; border-radius: 5px; background: var(--soft); color: var(--ink); }
.cta { padding-bottom: 56px; }
.ctacard { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; padding: 24px; background: var(--blue-tint); border-color: var(--cta-line); }
.ctacard h2 { font-size: 20px; font-weight: 800; letter-spacing: -.02em; }
.ctacard p { margin-top: 4px; color: var(--body); }
.ctabtn { display: inline-flex; align-items: center; min-height: 44px; padding: 0 18px; border-radius: 8px; background: var(--blue); color: #fff; font-weight: 600; text-decoration: none; }
.ctabtn:hover { background: var(--blue-hover); }
.toast { position: fixed; left: 50%; bottom: 24px; z-index: 40; transform: translateX(-50%); padding: 9px 16px; border-radius: 10px; background: var(--ink); color: var(--bg); font-size: 14px; font-weight: 550; box-shadow: 0 10px 30px rgba(0,0,0,.2); }
.tname a { color: inherit; text-decoration: underline; text-decoration-color: #c4b5fd; text-underline-offset: 3px; }
.tname a:hover { color: var(--blue); }
.guide-link { display: inline-block; margin-top: 10px; font-size: 13.5px; font-weight: 600; color: var(--blue); text-decoration: none; }
.guide-link:hover { text-decoration: underline; }
@media (max-width: 960px) {
  .cphero { grid-template-columns: 1fr; }
  .cpswatch { min-height: 190px; }
  .cpramp { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .palgrid, .cmpgrid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .cpswatch { min-height: 160px; padding: 14px 16px; }
  .cpvalues { padding: 16px; }
  .cpstep { min-height: 76px; }
  .palbar { height: 96px; }
  .palbar button { padding: 8px 6px; }
  .palbar span { font-size: 11px; }
  .palbar b { font-size: 10.5px; }
  .harmrow { grid-template-columns: 1fr; gap: 6px; }
  .prose h2 { font-size: 21px; }
}

/* Language switch and Chinese */
.langbtn { display: inline-flex; align-items: center; gap: 5px; height: 34px; padding: 0 10px; border: 1px solid var(--line); border-radius: 9px; font-size: 13px; font-weight: 600; color: var(--body); text-decoration: none; }
.langbtn:hover { color: var(--ink); background: var(--soft); }
.cname small, .tname small { font-size: .86em; font-weight: 500; color: var(--muted); margin-left: 2px; }
.chip[aria-pressed=true] .cname small { color: var(--body); }
.pzh { display: block; margin-top: 6px; font-size: 18px; font-weight: 600; opacity: .8; }
:lang(zh) h1, :lang(zh) h2, :lang(zh) h3, :lang(zh) .pzh { letter-spacing: 0; }
:lang(zh) .val .k { letter-spacing: .02em; }
:lang(zh) .apphead p, :lang(zh) .card p, :lang(zh) details p { line-height: 1.75; }
:lang(zh) [data-gf-comments][data-gf-empty]::after { content: "还没有留言。你觉得哪个英文颜色单词应该加进来？"; }
@media (max-width: 640px) { .langbtn span { display: none; } .langbtn { width: 34px; padding: 0; justify-content: center; } }

/* Language menu */
.langmenu { position: relative; }
.langmenu summary { display: inline-flex; align-items: center; gap: 5px; height: 34px; padding: 0 10px; border: 1px solid var(--line); border-radius: 9px; font-size: 13px; font-weight: 600; color: var(--body); list-style: none; cursor: pointer; user-select: none; }
.langmenu summary::-webkit-details-marker { display: none; }
.langmenu summary::after { content: ""; width: 6px; height: 6px; margin-left: 2px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg) translateY(-2px); }
.langmenu summary:hover, .langmenu[open] summary { color: var(--ink); background: var(--soft); }
.langmenu ul { position: absolute; right: 0; top: calc(100% + 6px); z-index: 30; min-width: 150px; padding: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 12px 32px -8px rgba(0,0,0,.18); }
.langmenu a { display: block; padding: 8px 10px; border-radius: 7px; font-size: 14px; font-weight: 550; color: var(--body); text-decoration: none; }
.langmenu a:hover { background: var(--soft); color: var(--ink); }
.langmenu a[aria-current] { color: var(--blue); }
.langmenu a[aria-current]::after { content: " ✓"; }
:lang(fr) [data-gf-comments][data-gf-empty]::after { content: "Pas encore de note. Quelle nuance mériterait sa place ici ?"; }
@media (max-width: 640px) { .langmenu summary span { display: none; } .langmenu summary { padding: 0 8px; } }

.wordmark, .mast nav a { white-space: nowrap; }
@media (max-width: 640px) { .mast { gap: 8px; } .mast nav { gap: 0; } .mast nav a { padding: 6px 7px; } .wordmark { font-size: 16px; } .wordmark svg { width: 24px; height: 24px; } }
@media (max-width: 370px) { .wordmark span { display: none; } }

.val.contrast .k { width: auto; min-width: 62px; margin-right: 6px; }
.mixer{padding:clamp(16px,3vw,32px)}.mix-controls,.mix-colors{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,155px),1fr));gap:16px;margin-bottom:24px}.mix-controls label,.mix-colors span,.mix-colors code{display:block}.mix-controls input,.mix-controls select{display:block;width:100%;min-height:44px}.mix-controls output{float:right}.mix-colors i{display:block;height:72px;border-radius:8px;border:1px solid #0002;margin-bottom:8px}.mixer button{min-height:44px}

/* color pages: token scale, related links, footer columns */
.tokscale { grid-template-columns: repeat(11, minmax(0, 1fr)); }
.tokscale .cpstep b { font-family: inherit; font-size: 13px; }
.tokscale .cpstep span { font-family: var(--mono); font-size: 11px; }
.tokscale .cpstep .okl { font-size: 10px; opacity: .7; }
.relgrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.relgrid.big { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.rel { display: flex; align-items: center; gap: 14px; padding: 16px; text-decoration: none; color: inherit; transition: border-color .12s ease, transform .12s ease; }
.rel:hover { border-color: var(--blue); transform: translateY(-1px); }
.rel i { flex: none; width: 44px; height: 44px; border-radius: 10px; box-shadow: inset 0 0 0 1px rgba(0,0,0,.1); }
.rel b { display: block; font-size: 15px; font-weight: 700; color: var(--heading); }
.rel small { display: block; margin-top: 2px; font-size: 13px; color: var(--body); }
.rel + .guide, .relgrid + .guide { margin-top: 14px; }
.foot .fcols { flex-direction: column; gap: 8px; }
.foot .fhead { font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
@media (max-width: 960px) { .tokscale { grid-template-columns: repeat(6, minmax(0, 1fr)); } .relgrid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .tokscale { grid-template-columns: repeat(3, minmax(0, 1fr)); } .relgrid, .relgrid.big { grid-template-columns: 1fr; } }

.homehero { margin-top: 4px; }
.homehero .cpswatch { min-height: 260px; }
.heroctas { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-top: 16px; }
.heroctas .guide { margin-top: 0; }
.finderhead { padding-bottom: 0; }
.finderhead .sec-head { margin-bottom: 16px; }
.tnote { margin-top: 10px; font-size: 13px; line-height: 1.55; color: var(--muted); }
#compare-mauves td, #compare-mauves th { white-space: nowrap; }
#compare-mauves td:last-child { white-space: normal; min-width: 220px; }
