:root {
  color-scheme: light;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 14px;
  color: #283a37;
  background: #f4f3ef;
  --ink: #283a37;
  --muted: #68746e;
  --accent: #276358;
  --line: #e0e3dc;
  --paper: #fcfcf9;
}
* { box-sizing: border-box; }
body { margin: 0; height: 100vh; height: 100dvh; display: flex; flex-direction: column; overflow: hidden; }
button, input, select { font: inherit; color: inherit; }
button, select, summary, input[type="checkbox"] { cursor: pointer; }
button { border: 0; }
button, select, input, summary { -webkit-tap-highlight-color: transparent; }
button:focus-visible, select:focus-visible, input:focus-visible, summary:focus-visible, #paneA:focus-visible, a:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
[hidden] { display: none !important; }
h1, h2, h3, p { margin: 0; }
.app-header { min-height: 90px; padding: 20px 30px; display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-shrink: 0; }
.identity { display: flex; gap: 14px; align-items: center; }
.brand-mark { width: 44px; height: 44px; display: flex; justify-content: center; align-items: center; font-size: 28px; font-weight: 500; letter-spacing: -3px; border: 1px solid #9cad9e; border-radius: 50%; color: var(--accent); }
.brand-mark span { font-size: 17px; margin-top: -9px; }
h1 { font-size: 19px; font-weight: 600; letter-spacing: -.5px; }
.identity p { font-size: 12px; color: var(--muted); margin-top: 4px; }
.quiet-button { display: inline-flex; align-items: center; justify-content: center; gap: 10px; border: 1px solid transparent; background: transparent; padding: 9px 12px; border-radius: 7px; font-size: 12px; white-space: nowrap; min-height: 36px; }
.quiet-button:hover { border-color: #cdd4ca; background: #e9ece4; }
.quiet-button span { font-size: 20px; line-height: 16px; }
.workspace { flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(0,1fr) 354px; margin: 0 22px 22px; border: 1px solid #d6dcd2; border-radius: 12px; overflow: hidden; background: var(--paper); box-shadow: 0 4px 20px #253b3010; }
.viewer { display: flex; min-width: 0; min-height: 0; flex-direction: column; background: #e9ede5; position: relative; }
.viewbar { display: flex; gap: 12px; align-items: center; justify-content: space-between; padding: 18px 20px 0; z-index: 1; }
.segmented { display: inline-flex; align-items: center; padding: 3px; background: #dde3d9; border: 1px solid #d1dacd; border-radius: 8px; }
.segmented button { min-height: 32px; border-radius: 5px; padding: 7px 15px; background: transparent; font-size: 12px; color: #53614f; }
.segmented button:hover { color: #193f34; background: #e8ece3; }
.segmented button[aria-pressed="true"] { background: #fcfcf9; box-shadow: 0 1px 3px #273e3220; color: #284936; }
.viewport { flex: 1; min-height: 0; position: relative; overflow: hidden; background: radial-gradient(ellipse at 55% 50%, #fafbf6 0%, #e9ede500 68%); }
#c3d, #paneA { position: absolute; inset: 0; width: 100%; height: 100%; }
#c3d { display: block; }
#paneA { touch-action: none; cursor: grab; outline-offset: -4px; }
#paneA:active { cursor: grabbing; }
#loading { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; padding: 40px; background: #e9ede5e8; color: var(--muted); z-index: 2; }
.model-readout { padding: 21px 25px 8px; display: flex; flex-direction: column; gap: 6px; }
.eyebrow { text-transform: uppercase; font-size: 10px; font-weight: 600; letter-spacing: 1.6px; color: #5c7564; }
#lblA { font-variant-numeric: tabular-nums; font-size: 16px; letter-spacing: -.3px; }
.model-readout small { font-size: 10px; color: #697669; }
.viewer-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 16px 12px 24px; min-height: 54px; }
.viewer-footer p { color: #5b6c5b; font-size: 11px; line-height: 1.7; }
.viewer-footer p > span:first-child { font-size: 17px; margin-right: 6px; }
.keyboard-help { display: none; }
#btnBlur[aria-pressed="true"] { background: #d3dfd1; border-color: #b8c8b4; }
.controls { overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: #bdc7b9 transparent; border-left: 1px solid var(--line); }
.panel-heading { padding: 27px 24px 22px; border-bottom: 1px solid var(--line); }
h2 { font-size: 20px; font-weight: 500; letter-spacing: -.6px; margin-top: 6px; }
.control-section { padding: 21px 24px; border-bottom: 1px solid var(--line); }
h3, summary { font-size: 13px; font-weight: 600; }
h3 { margin-bottom: 18px; }
.control + .control { margin-top: 19px; }
.control label { font-size: 12px; }
.control-label { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 24px; }
.control output { font-size: 11px; color: var(--accent); font-variant-numeric: tabular-nums; }
.number-field { display: flex; align-items: center; gap: 5px; padding: 3px 8px; background: #fff; border: 1px solid #d8ded4; border-radius: 6px; }
.number-field input { width: 42px; border: 0; background: transparent; font-variant-numeric: tabular-nums; font-size: 13px; text-align: right; padding: 3px 0; appearance: textfield; -moz-appearance: textfield; }
.number-field input::-webkit-inner-spin-button, .number-field input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.number-field span { font-size: 11px; color: var(--muted); }
input[type="range"] { -webkit-appearance: none; appearance: none; display: block; width: 100%; background: transparent; height: 24px; margin: 6px 0 0; cursor: pointer; accent-color: var(--accent); }
input[type="range"]::-webkit-slider-runnable-track { height: 3px; background: #d6ded1; border-radius: 4px; }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; height: 14px; width: 14px; border-radius: 50%; background: var(--accent); border: 2px solid var(--paper); margin-top: -5.5px; box-shadow: 0 0 0 1px var(--accent); }
input[type="range"]::-moz-range-track { height: 3px; background: #d6ded1; border-radius: 4px; }
input[type="range"]::-moz-range-thumb { height: 11px; width: 11px; border-radius: 50%; background: var(--accent); border: 2px solid var(--paper); box-shadow: 0 0 0 1px var(--accent); }
.range-ends { display: flex; justify-content: space-between; gap: 8px; color: #788173; font-size: 10px; }
.hint { color: var(--muted); font-size: 11px; line-height: 1.6; margin-top: 13px; }
.hint:empty { display: none; }
.pose-row { display: flex; gap: 12px; align-items: center; justify-content: space-between; }
.pose-row .segmented button { padding-inline: 14px; }
.text-button { background: transparent; font-size: 11px; color: var(--accent); padding: 6px 0; line-height: 1.5; text-align: right; }
.text-button:hover { text-decoration: underline; }
.checkbox-row { display: flex; align-items: center; gap: 8px; margin-top: 16px; font-size: 11px; color: var(--muted); }
input[type="checkbox"] { accent-color: var(--accent); width: 14px; height: 14px; margin: 0; }
.section-heading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 17px; gap: 6px; }
.section-heading h3 { margin: 0; }
.section-heading > span { font-size: 11px; color: var(--muted); }
.tones { display: flex; justify-content: space-between; gap: 9px; margin: 0 2px 22px; }
.tone { position: relative; width: 28px; height: 28px; border-radius: 50%; flex-shrink: 0; background: var(--tone); border: 1px solid #00000014; }
.tone:hover { box-shadow: 0 0 0 3px #dce3d8; }
.tone[aria-pressed="true"] { outline: 1.5px solid var(--accent); outline-offset: 3px; }
.tone[aria-pressed="true"]::after { content: ""; position: absolute; top: 8px; left: 10px; width: 5px; height: 9px; border: solid #fff; border-width: 0 1.5px 1.5px 0; transform: rotate(45deg); filter: drop-shadow(0 1px 2px #382b23); }
.select-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.select-row label { font-size: 12px; }
select { padding: 8px 28px 8px 10px; border: 1px solid #d6ded1; background: #fff; border-radius: 6px; font-size: 12px; max-width: 100%; min-height: 35px; }
.full-width { width: 100%; }
summary { display: flex; align-items: center; justify-content: space-between; list-style: none; min-height: 22px; }
summary::-webkit-details-marker { display: none; }
.summary-icon { font-size: 19px; font-weight: 300; color: var(--muted); }
details[open] .summary-icon { transform: rotate(45deg); }
.detail-controls { margin-top: 23px; }
.detail-value { display: block; margin: 5px 0; }
.panel-footer { padding: 23px 24px 26px; color: #7a8276; font-size: 11px; line-height: 1.7; }
.panel-footer small { display: block; margin-top: 13px; font-size: 10px; }
a { color: inherit; text-underline-offset: 3px; }
.sr-only { position: absolute; height: 1px; width: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.no-script { position: fixed; bottom: 20px; left: 20px; padding: 16px; background: white; z-index: 5; }
.age-gate { border: 1px solid #d6dcd2; border-radius: 14px; padding: 32px; max-width: 410px; width: calc(100% - 32px); background: var(--paper); color: var(--ink); box-shadow: 0 12px 60px #1a332329; }
.age-gate::backdrop { background: #e9ede5; }
.age-gate h2 { margin-top: 10px; margin-bottom: 14px; font-size: 24px; }
.age-gate p { color: var(--muted); line-height: 1.7; font-size: 13px; }
.age-gate .primary-button { display: block; width: 100%; padding: 12px; margin-top: 24px; color: white; border-radius: 7px; background: var(--accent); }
.age-gate .quiet-button { margin-top: 10px; width: 100%; }
@media(min-width: 1500px) { .workspace { grid-template-columns: minmax(0,1fr) 380px; } .keyboard-help { display: inline; } }
@media(max-width: 1000px) { .app-header { padding: 18px 20px; min-height: 80px; } .workspace { margin: 0 12px 12px; grid-template-columns: minmax(0,1fr) 320px; } .control-section, .panel-heading, .panel-footer { padding-left: 20px; padding-right: 20px; } .viewbar { padding: 14px 12px 0; gap: 6px; } .viewbar .segmented button { padding-inline: 10px; } .viewer-footer { padding-left: 16px; } .viewer-footer p { max-width: 215px; } .tones { gap: 7px; } }
@media(max-width: 740px) {
  body { height: auto; overflow: auto; }
  .app-header { padding: 17px 16px; min-height: 78px; }
  h1 { font-size: 16px; }.identity { gap: 10px; }.identity p { font-size: 11px; }.brand-mark { width: 36px; height: 36px; font-size: 24px; }
  #btnReset { font-size: 11px; padding: 8px 0; gap: 5px; } #btnReset span { font-size: 18px; }
  .workspace { display: flex; flex-direction: column; overflow: visible; margin: 0; border-radius: 0; border: 0; box-shadow: none; }
  .viewer { height: 52svh; min-height: 310px; max-height: 560px; flex-shrink: 0; position: sticky; top: 0; z-index: 3; border-top: 1px solid #d6dcd2; border-bottom: 1px solid #d6dcd2; box-shadow: 0 3px 12px #273f3010; }
  .viewbar { padding: 12px 16px 0; }.viewbar .segmented button { min-height: 30px; padding: 6px 13px; }
  .model-readout { padding: 13px 19px 5px; gap: 4px; } #lblA { font-size: 14px; }.model-readout small { font-size: 9px; }
  .viewer-footer { padding: 4px 12px 6px 17px; min-height: 44px; }.viewer-footer p { font-size: 10px; max-width: none; }.viewer-footer p > span:first-child { display: none; }.viewer-footer .quiet-button { padding: 8px; font-size: 11px; }
  .controls { overflow: visible; border-left: 0; }.panel-heading { padding: 23px 24px; } .control-section { padding: 22px 24px; } .panel-footer { padding: 24px; }
  .tones { justify-content: flex-start; gap: 16px; }.tone { width: 29px; height: 29px; }.pose-row { justify-content: flex-start; gap: 20px; }
  .select-row select { min-width: 112px; }
}
@media(max-width: 370px) { .brand-mark { display: none; }.tones { gap: 12px; }.viewbar .segmented button { padding-inline: 10px; } }
@media(max-height: 500px) and (max-width: 740px) { .viewer { position: relative; min-height: 330px; } }
