#fursona-color-preview {
  --hy-bg: var(--color-background);
  --hy-paper: var(--color-surface);
  --hy-soft: var(--color-surface-soft);
  --hy-ink: var(--color-primary-dark);
  --hy-purple: var(--color-primary-fill);
  --hy-text: var(--color-text);
  --hy-muted: var(--color-text-muted);
  --hy-line: var(--color-border);
  --hy-on: var(--color-on-primary);
  --hy-stage-height: 700px;
  --hy-scale: 1;
  min-width: 0;
  padding: 26px;
  border: 1px solid var(--hy-line);
  border-radius: 20px;
  color: var(--hy-text);
  background: var(--hy-bg);
}

#fursona-color-preview [hidden] { display: none !important; }
#fursona-color-preview :is(button, input, summary) { font: inherit; }
#fursona-color-preview button { cursor: pointer; }
#fursona-color-preview :is(button, input):disabled { opacity: .5; cursor: default; }
#fursona-color-preview fieldset:disabled :is(button, input) { cursor: wait; }
#fursona-color-preview :is(button, input, summary, a):focus-visible { outline: 3px solid var(--color-focus); outline-offset: 3px; }
#fursona-color-preview :is(button, a) { -webkit-tap-highlight-color: transparent; }

#fursona-color-preview .hy-path { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; color: var(--hy-muted); font-size: calc(13px / var(--hy-scale)); line-height: 1.5; }
#fursona-color-preview .hy-path a { color: var(--hy-ink); font-weight: 650; }
#fursona-color-preview .hy-path :is(svg, i) { width: 13px; height: 13px; flex: 0 0 auto; }
#fursona-color-preview .hy-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 18px 0 23px; }
#fursona-color-preview .hy-heading > div:first-child { min-width: 0; }
#fursona-color-preview .hy-heading h2 { margin: 0; color: var(--hy-ink); font-size: calc(29px / var(--hy-scale)); font-weight: 850; letter-spacing: -.7px; line-height: 1.3; }
#fursona-color-preview .hy-subtitle { margin: 7px 0 0; color: var(--hy-muted); font-size: calc(14px / var(--hy-scale)); font-weight: 500; line-height: 1.7; }
#fursona-color-preview .hy-toc-trigger { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto; min-height: calc(44px / var(--hy-scale)); padding: 0 15px; border: 1px solid var(--hy-line); border-radius: 999px; color: var(--hy-ink); background: var(--hy-paper); font-size: calc(13px / var(--hy-scale)); font-weight: 650; line-height: 1.5; text-align: center; white-space: nowrap; }
#fursona-color-preview .hy-desktop-toc { flex: 0 0 auto; margin-left: auto; }
#fursona-color-preview .hy-toc { min-width: 0; }
#fursona-color-preview .hy-toc summary { min-height: 44px; color: var(--hy-ink); font-size: calc(13px / var(--hy-scale)); font-weight: 650; line-height: 1.6; cursor: pointer; }
#fursona-color-preview .hy-toc nav { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px 20px; padding: 0 0 20px; font-size: calc(13px / var(--hy-scale)); line-height: 1.7; }
#fursona-color-preview .hy-toc nav a { display: flex; align-items: center; min-height: calc(44px / var(--hy-scale)); padding: 10px 0; color: var(--hy-ink); text-underline-offset: 3px; }
#fursona-color-preview .hy-toc nav a:hover { text-decoration: underline; }

#fursona-color-preview .hy-workspace { display: grid; grid-template-columns: minmax(0, 1fr) 340px; align-items: start; gap: 0; margin: 0; overflow: hidden; border: 1px solid var(--hy-line); border-radius: 17px; background: var(--hy-paper); }
#fursona-color-preview .hy-visual { display: block; min-width: 0; }
#fursona-color-preview .hy-figure { min-width: 0; margin: 0; }
#fursona-color-preview .hy-stage { display: flex; align-items: flex-end; justify-content: center; height: var(--hy-stage-height); overflow: hidden; background: #fff; }
#fursona-color-preview .fursona-color-preview-art { position: relative; flex: 0 0 auto; width: min(calc((var(--hy-stage-height) - 12px) * .7467), 100%); aspect-ratio: 2 / 3; background: #fff; }
#fursona-color-preview .fursona-color-preview-art :is(canvas, img) { display: block; width: 100%; height: auto; aspect-ratio: 2 / 3; }
#fursona-color-preview .fursona-color-preview-brush-cursor { position: absolute; aspect-ratio: 1; border: 1px solid #fff; border-radius: 50%; box-shadow: 0 0 0 1px #3d334d; transform: translate(-50%, -50%); pointer-events: none; }
#fursona-color-preview .is-highlighting canvas { cursor: crosshair; touch-action: none; }
#fursona-color-preview canvas:focus-visible { outline: 3px solid var(--color-focus); outline-offset: -3px; }
#fursona-color-preview .hy-figure figcaption { margin: 0; padding: 12px 20px; border-top: 1px solid var(--hy-line); color: var(--hy-muted); font-size: calc(12px / var(--hy-scale)); line-height: 1.7; overflow-wrap: anywhere; }

#fursona-color-preview .hy-tools { min-width: 0; padding: 24px 22px; border-left: 1px solid var(--hy-line); }
#fursona-color-preview fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }
#fursona-color-preview :is(legend, h3) { max-width: 100%; margin: 0; padding: 0; color: var(--hy-ink); font-size: calc(15px / var(--hy-scale)); font-weight: 800; line-height: 1.5; }
#fursona-color-preview .hy-tool-panel { min-width: 0; }
#fursona-color-preview .hy-sample-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px 7px; margin-top: 14px; }
#fursona-color-preview .hy-sample { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 9px; width: 100%; min-width: 0; min-height: 64px; height: auto; margin: 0; padding: 4px 3px; border: 0; border-radius: 7px; color: var(--hy-muted); background: transparent; font-size: calc(12px / var(--hy-scale)); font-weight: 600; line-height: 1.4; text-align: center; white-space: normal; }
#fursona-color-preview .hy-sample[aria-pressed="true"] { color: var(--hy-ink); background: transparent; font-weight: 800; }
#fursona-color-preview .hy-chip { display: grid; flex: 0 0 auto; grid-template-columns: 3fr 1fr; grid-template-rows: 1fr 1fr; gap: 0; width: 41px; height: 32px; overflow: hidden; border-radius: 8px; box-shadow: 0 0 0 1px color-mix(in srgb, var(--hy-text) 12%, transparent); }
#fursona-color-preview .hy-chip i { width: auto; height: auto; border-radius: 0; box-shadow: none; }
#fursona-color-preview .hy-chip i:first-child { grid-row: 1 / 3; background: var(--preview-primary); }
#fursona-color-preview .hy-chip i:nth-child(2) { background: var(--preview-secondary); }
#fursona-color-preview .hy-chip i:nth-child(3) { background: var(--preview-eyes); }
#fursona-color-preview .hy-sample[aria-pressed="true"] .hy-chip { outline: 2px solid var(--hy-purple); outline-offset: 3px; }

#fursona-color-preview .hy-controls { margin-top: 19px; padding-top: 18px; border-top: 1px solid var(--hy-line); }
#fursona-color-preview .hy-controls > legend { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
#fursona-color-preview .hy-color-title { margin-bottom: 12px; }
#fursona-color-preview .hy-colors-panel > h3 { margin-bottom: 12px; }
#fursona-color-preview .hy-color-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; }
#fursona-color-preview .hy-color-field { display: grid; grid-template-columns: minmax(0, 1fr); justify-items: center; gap: 8px; min-width: 0; padding: 10px 7px; border: 1px solid var(--hy-line); border-radius: 9px; }
#fursona-color-preview .hy-color-field label { color: var(--hy-ink); font-size: calc(13px / var(--hy-scale)); font-weight: 700; line-height: 1.5; }
#fursona-color-preview input[type="color"] { display: block; width: 100%; min-width: 0; min-height: calc(44px / var(--hy-scale)); height: calc(44px / var(--hy-scale)); padding: 0; border: 0; border-radius: 5px; background: transparent; cursor: pointer; }
#fursona-color-preview input[type="color"]::-webkit-color-swatch-wrapper { padding: 0; }
#fursona-color-preview input[type="color"]::-webkit-color-swatch { border: 1px solid var(--hy-line); border-radius: 5px; }
#fursona-color-preview input[type="color"]::-moz-color-swatch { border: 1px solid var(--hy-line); border-radius: 5px; }
#fursona-color-preview .hy-color-field output { color: var(--hy-ink); font-family: Consolas, "Courier New", monospace; font-size: calc(14px / var(--hy-scale)); font-weight: 600; line-height: 1.4; letter-spacing: -.2px; white-space: nowrap; }
#fursona-color-preview output code { padding: 0; border: 0; color: inherit; background: transparent; font: inherit; }
#fursona-color-preview .hy-secondary { display: flex; align-items: center; gap: 7px; min-height: calc(44px / var(--hy-scale)); color: var(--hy-muted); font-size: calc(12px / var(--hy-scale)); line-height: 1.6; cursor: pointer; }
#fursona-color-preview input[type="checkbox"] { flex: 0 0 auto; width: 18px; height: 18px; margin: 0; accent-color: var(--hy-purple); cursor: pointer; }

#fursona-color-preview .hy-brush { margin-top: 10px; padding-top: 16px; border-top: 1px solid var(--hy-line); }
#fursona-color-preview .hy-brush-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
#fursona-color-preview .hy-brush-toggle { display: flex; align-items: center; justify-content: center; width: auto; min-width: 0; min-height: calc(44px / var(--hy-scale)); height: auto; margin: 0; padding: 6px 11px; border: 0; border-radius: 999px; color: var(--hy-ink); background: var(--hy-soft); font-size: calc(12px / var(--hy-scale)); font-weight: 700; line-height: 1.5; white-space: normal; text-align: center; }
#fursona-color-preview .hy-brush-toggle[aria-pressed="true"] { color: var(--hy-on); background: var(--hy-purple); }
#fursona-color-preview .hy-brush-short { margin: 9px 0 12px; color: var(--hy-muted); font-size: calc(12px / var(--hy-scale)); font-weight: 500; line-height: 1.7; }
#fursona-color-preview .hy-brush-hint { display: none; }
#fursona-color-preview .hy-sliders { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 15px; margin-top: 0; }
#fursona-color-preview .hy-sliders label { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 4px; color: var(--hy-ink); font-size: calc(12px / var(--hy-scale)); font-weight: 650; line-height: 1.5; }
#fursona-color-preview .hy-sliders output { color: var(--hy-muted); font: inherit; font-weight: 500; white-space: nowrap; }
#fursona-color-preview input[type="range"] { display: block; width: 100%; min-width: 0; min-height: calc(44px / var(--hy-scale)); height: calc(44px / var(--hy-scale)); margin: 0; accent-color: var(--hy-purple); cursor: pointer; }
#fursona-color-preview .hy-brush-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; margin-top: 6px; }
#fursona-color-preview .hy-brush-actions button { width: 100%; min-width: 0; min-height: calc(44px / var(--hy-scale)); height: auto; margin: 0; padding: 5px 6px; border: 0; border-radius: 8px; color: var(--hy-ink); background: var(--hy-soft); font-size: calc(12px / var(--hy-scale)); font-weight: 650; line-height: 1.5; white-space: normal; }
#fursona-color-preview .hy-final-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 20px; }
#fursona-color-preview .hy-final-actions button { width: 100%; min-width: 0; min-height: calc(44px / var(--hy-scale)); height: auto; margin: 0; padding: 7px; border: 1px solid var(--hy-line); border-radius: 999px; color: var(--hy-ink); background: transparent; font-size: calc(13px / var(--hy-scale)); font-weight: 750; line-height: 1.5; white-space: normal; }
#fursona-color-preview .hy-final-actions button:last-child { border-color: var(--hy-purple); color: var(--hy-on); background: var(--hy-purple); }
#fursona-color-preview .hy-header-actions { display: none; }
#fursona-color-preview .hy-action-short { display: none; }
#fursona-color-preview .hy-bottom-bar { display: none; }

#fursona-color-preview .hy-status { min-height: 1.7em; margin: 12px 0 0; color: var(--hy-muted); font-size: calc(12px / var(--hy-scale)); font-weight: 500; line-height: 1.7; overflow-wrap: anywhere; }
#fursona-color-preview .hy-guide { margin-top: 17px; border-bottom: 1px solid var(--hy-line); }
#fursona-color-preview .hy-guide > summary { display: flex; align-items: center; gap: 7px; min-height: 48px; color: var(--hy-ink); font-size: calc(13px / var(--hy-scale)); font-weight: 650; line-height: 1.7; list-style: none; cursor: pointer; }
#fursona-color-preview .hy-guide > summary::-webkit-details-marker { display: none; }
#fursona-color-preview .hy-guide > summary :is(svg, i) { flex: 0 0 auto; width: 16px; height: 16px; }
#fursona-color-preview .hy-guide > summary :last-child { margin-left: auto; }
#fursona-color-preview .hy-guide[open] > summary :last-child { transform: rotate(180deg); }
#fursona-color-preview .hy-help-body { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; padding: 14px 0 24px; }
#fursona-color-preview .hy-help-body h3 { margin: 0 0 8px; font-size: calc(14px / var(--hy-scale)); }
#fursona-color-preview .hy-help-body p { margin: 0 0 14px; color: var(--hy-muted); font-size: calc(13px / var(--hy-scale)); font-weight: 500; line-height: 1.85; word-break: keep-all; overflow-wrap: anywhere; }
#fursona-color-preview .hy-note { margin: 15px 0 0; color: var(--hy-muted); font-size: calc(12px / var(--hy-scale)); font-weight: 500; line-height: 1.8; word-break: keep-all; }
#fursona-color-preview .hy-note a { color: var(--hy-ink); text-decoration: underline; text-underline-offset: 3px; }
#fursona-color-preview .hy-note.legal-note { padding: 0; border: 0; background: transparent; }
#fursona-color-preview .hy-sr { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }

@media (min-width: 1201px) and (max-width: 1535px) {
  #fursona-color-preview { --hy-scale: var(--page-scale, 1); }
}

@media (min-width: 768px) and (max-width: 1100px) {
  #fursona-color-preview .hy-workspace { grid-template-columns: minmax(0, 1fr) 300px; }
  #fursona-color-preview .hy-tools { padding: 23px 17px; }
  #fursona-color-preview .hy-heading h2 { font-size: 26px; }
}

@media (max-width: 767px) {
  #fursona-color-preview { --hy-stage-height: 430px; padding: 12px 10px; border-radius: 18px; }
  #fursona-color-preview .hy-path { gap: 5px; font-size: 12px; line-height: 1.5; }
  #fursona-color-preview .hy-path :is(svg, i) { width: 12px; height: 12px; }
  #fursona-color-preview .hy-heading { align-items: center; gap: 8px; margin: 11px 0 13px; flex-wrap: wrap; }
  #fursona-color-preview .hy-heading h2 { font-size: 22px; letter-spacing: -.5px; white-space: nowrap; }
  #fursona-color-preview .hy-subtitle { display: none; }
  #fursona-color-preview .hy-heading > .hy-toc-trigger { order: 3; min-height: 44px; margin-left: auto; padding: 0 10px; border: 0; background: transparent; font-size: 12px; }
  #fursona-color-preview .hy-header-actions { display: flex; align-items: center; gap: 4px; margin: 0 0 0 auto; }
  #fursona-color-preview .hy-header-actions .hy-final-actions { display: flex; gap: 4px; margin: 0; }
  #fursona-color-preview .hy-header-actions button { width: auto; min-height: 44px; padding: 0 10px; border: 0; border-radius: 999px; color: var(--hy-ink); background: transparent; font-size: 12px; font-weight: 700; line-height: 1.5; white-space: nowrap; }
  #fursona-color-preview .hy-header-actions button:last-child { padding: 0 15px; color: var(--hy-on); background: var(--hy-purple); }
  #fursona-color-preview .hy-action-full { display: none; }
  #fursona-color-preview .hy-action-short { display: inline; }
  #fursona-color-preview .hy-desktop-toc { display: none; }
  #fursona-color-preview .hy-workspace { display: block; border-radius: 14px; }
  #fursona-color-preview .fursona-color-preview-art { width: min(calc((var(--hy-stage-height) - 12px) * .7467), 110%); }
  #fursona-color-preview .hy-figure figcaption { display: none; }
  #fursona-color-preview .hy-tools { padding: 0; border-top: 1px solid var(--hy-line); border-left: 0; }
  #fursona-color-preview .hy-brush-hint { display: flex; align-items: flex-start; gap: 7px; margin: 0; padding: 11px 15px 12px; border-bottom: 1px solid var(--hy-line); color: var(--hy-muted); font-size: 12px; font-weight: 500; line-height: 1.65; }
  #fursona-color-preview .hy-brush-hint :is(svg, i) { flex: 0 0 auto; width: 15px; height: 15px; margin-top: 2px; color: var(--hy-ink); }
  #fursona-color-preview .hy-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; padding: 0 10px; border-bottom: 1px solid var(--hy-line); }
  #fursona-color-preview .hy-tab { min-width: 0; min-height: 46px; margin: 0 0 -1px; padding: 0 4px; border: 0; border-bottom: 2px solid transparent; color: var(--hy-muted); background: transparent; font-size: 13px; font-weight: 650; line-height: 1.5; }
  #fursona-color-preview .hy-tab[aria-selected="true"] { border-bottom-color: var(--hy-purple); color: var(--hy-ink); font-weight: 800; }
  #fursona-color-preview .hy-tool-panel { min-height: 184px; padding: 14px 16px; }
  #fursona-color-preview .hy-controls { display: contents; margin: 0; padding: 0; border: 0; }
  #fursona-color-preview [data-color-preview-sample-controls] > legend,
  #fursona-color-preview .hy-colors-panel > h3,
  #fursona-color-preview .hy-color-title { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  #fursona-color-preview .hy-sample-grid { gap: 8px 5px; margin: 0; }
  #fursona-color-preview .hy-sample { gap: 9px; min-height: 74px; padding: 7px 3px; font-size: 12px; }
  #fursona-color-preview .hy-chip { width: 39px; height: 29px; border-radius: 7px; }
  #fursona-color-preview .hy-color-grid { gap: 8px; }
  #fursona-color-preview .hy-color-field { gap: 6px; padding: 8px 7px; }
  #fursona-color-preview .hy-color-field label { font-size: 12px; }
  #fursona-color-preview .hy-secondary { min-height: 44px; margin-top: 3px; font-size: 12px; }
  #fursona-color-preview .hy-brush { margin: 0; padding: 0; border: 0; }
  #fursona-color-preview .hy-brush-row h3 { font-size: 13px; }
  #fursona-color-preview .hy-brush-toggle { max-width: 190px; min-height: 44px; padding: 6px 11px; font-size: 12px; line-height: 1.45; }
  #fursona-color-preview .hy-brush-short { margin: 3px 0 9px; font-size: 12px; line-height: 1.5; }
  #fursona-color-preview .hy-sliders { gap: 18px; }
  #fursona-color-preview .hy-brush-actions { margin-top: 2px; }
  #fursona-color-preview .hy-status { min-height: 18px; margin: 9px 5px 0; font-size: 12px; }
  #fursona-color-preview .hy-bottom-bar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 2px 12px; margin: 3px 4px 0; }
  #fursona-color-preview [data-color-preview-mobile-toc] { min-width: 0; }
  #fursona-color-preview [data-color-preview-mobile-toc]:has(details[open]) { flex-basis: 100%; width: 100%; }
  #fursona-color-preview .hy-bottom-bar .hy-note { flex: 1; margin: 0; text-align: right; line-height: 1.6; }
  #fursona-color-preview .hy-toc-trigger { min-height: 44px; padding: 0 4px; border: 0; border-radius: 0; background: transparent; font-size: 12px; }
  #fursona-color-preview .hy-toc nav { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 14px; padding: 8px 0 15px; border-bottom: 1px solid var(--hy-line); font-size: 12px; }
  #fursona-color-preview .hy-toc nav a { min-height: 44px; padding: 6px 0; }
  #fursona-color-preview .hy-guide { margin: 10px 4px 0; }
  #fursona-color-preview .hy-guide > summary { min-height: 44px; font-size: 12px; }
  #fursona-color-preview .hy-help-body { grid-template-columns: minmax(0, 1fr); gap: 8px; padding: 10px 0 18px; }
  #fursona-color-preview .hy-help-body h3 { font-size: 13px; }
  #fursona-color-preview .hy-help-body p { font-size: 12px; }
  #fursona-color-preview .hy-note { margin: 13px 4px 0; font-size: 12px; }
}

@media (max-width: 380px) {
  #fursona-color-preview { padding: 11px 8px; }
  #fursona-color-preview .hy-heading h2 { font-size: 20px; }
  #fursona-color-preview .hy-header-actions button { padding: 0 7px; }
  #fursona-color-preview .hy-header-actions button:last-child { padding: 0 12px; }
  #fursona-color-preview .hy-tool-panel { padding: 13px 10px; }
  #fursona-color-preview .hy-tab { font-size: 12px; }
  #fursona-color-preview .hy-color-grid { gap: 6px; }
  #fursona-color-preview .hy-color-field { padding-inline: 3px; }
}

@media print {
  #fursona-color-preview :is(.hy-tools, .hy-header-actions, .hy-toc-trigger, .hy-guide, .fursona-color-preview-brush-cursor) { display: none !important; }
  #fursona-color-preview .hy-workspace { display: block; max-width: 300px; border: 0; }
  #fursona-color-preview .hy-stage { height: auto; }
  #fursona-color-preview .fursona-color-preview-art { width: 100%; }
}

/* Return to the artwork at its coloring invitation, preserving the same-tab draft. */
#fursona-color-preview .art-color-navigation {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 4px 18px;
}
#fursona-color-preview .art-color-return {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: calc(44px / var(--hy-scale));
  color: var(--hy-ink);
  font-size: calc(14px / var(--hy-scale));
  font-weight: 750;
  line-height: 1.5;
  text-decoration: none;
}
#fursona-color-preview .art-color-return svg { flex: 0 0 auto; }
#fursona-color-preview .art-color-return:focus-visible {
  outline: 3px solid var(--hy-purple);
  outline-offset: 4px;
}
@media (max-width: 767px) {
  #fursona-color-preview .art-color-navigation { gap: 0 12px; }
  #fursona-color-preview .art-color-return { min-height: 44px; font-size: 13px; }
}
@media print {
  #fursona-color-preview .art-color-navigation { display: none !important; }
}

/* Always-visible artwork coloring follows the complete artwork description. */
.art-color-anchor { min-width: 0; scroll-margin-top: 16px; }
#fursona-color-preview.art-inline-coloring { margin: 0; scroll-margin-top: 16px; }
#fursona-color-preview.art-inline-coloring .hy-heading { margin-top: 0; }
