.wheel-tool { padding: 28px; }
.wheel-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 4px 0 18px; flex-wrap: wrap; }
.wheel-views.segments { margin: 0; }
.wheel-toolbar .actions { gap: 4px; }
.wheel-status { font-size: 12px; color: var(--muted); overflow-wrap: anywhere; }
.wheel-status:empty, .wheel-tool > .error:empty { display: none; }
.wheel-status:not(:empty), .wheel-tool > .error:not(:empty) { margin: 0 0 16px; padding: 10px 14px; background: var(--elevated); border-radius: 12px; }
.wheel-play-layout { display: grid; grid-template-columns: minmax(0, 1fr) 225px; gap: 28px; align-items: start; }
.wheel-stage { text-align: center; min-width: 0; padding: 15px 2px 0; }
.wheel-question { display: inline-flex; align-items: center; gap: 9px; max-width: 100%; color: var(--accent); }
.wheel-question h3 { font-size: 14px; font-weight: 600; overflow-wrap: anywhere; }
.wheel-symbol { display: inline-grid; place-items: center; width: 32px; height: 32px; flex: none; background: var(--accent-soft); border-radius: 10px; }
.wheel-symbol .icon { width: 18px; height: 18px; }
.wheel-result-card { padding: 14px 4px 32px; min-height: 110px; }
#wheel-result { display: block; font-size: clamp(25px, 2.6vw, 34px); line-height: 1.2; font-weight: 650; letter-spacing: -1px; overflow-wrap: anywhere; }
#wheel-result-card[data-winner=true] #wheel-result { color: var(--accent); }
#wheel-result-detail { font-size: 12px; color: var(--muted); margin-top: 8px; overflow-wrap: anywhere; }
.wheel-disc { position: relative; width: min(100% - 20px, 440px); aspect-ratio: 1; margin: 0 auto; border-radius: 50%; background: var(--elevated); box-shadow: 0 0 0 7px var(--elevated), 0 0 0 8px var(--border), 0 18px 36px var(--shadow); }
#wheel-canvas { display: block; width: 100%; height: 100%; border-radius: 50%; cursor: pointer; }
.wheel-stage[data-spinning=true] #wheel-canvas { will-change: transform; cursor: default; }
.wheel-pointer { position: absolute; left: calc(50% - 13px); top: -12px; width: 26px; height: 35px; clip-path: polygon(0 0, 100% 0, 50% 100%); background: #f3d589; filter: drop-shadow(0 2px 2px #1b132c); pointer-events: none; }
.wheel-pointer::before { content: ''; position: absolute; inset: 3px 5px 9px; clip-path: polygon(0 0, 100% 0, 50% 100%); background: #60418a; }
.wheel-hub { position: absolute; inset: 38%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; padding: 0; border-radius: 50%; color: #f9dfa4; background: linear-gradient(145deg,#714598,#442465); border: 3px solid #e3c176; box-shadow: 0 4px 20px #110b234d, inset 0 1px 0 #ffffff38; min-width: 0; transition: filter .2s; }
.wheel-hub:hover:not(:disabled) { filter: brightness(1.12); }
.wheel-hub:active:not(:disabled) { filter: brightness(.95); }
.wheel-hub:disabled { opacity: 1; color: #d6c3dd; border-color: #917a9a; background: #483451; }
.wheel-hub svg { width: 29%; height: 29%; fill: currentColor; stroke-width: 0; }
.wheel-hub span { font-size: clamp(10px, 1.1vw, 13px); font-weight: 600; }
#wheel-empty { position: absolute; inset: 0; padding: 22% 15% 15%; border-radius: 50%; background: var(--elevated); color: var(--muted); font-size: 13px; }
.wheel-under-disc { min-height: 63px; padding-top: 23px; }
.wheel-under-disc .hint { margin: 0; font-size: 11px; }
#wheel-finish { margin-top: 12px; }
.wheel-round-actions { justify-content: center; gap: 4px; }
#wheel-motion-note { font-size: 11px; margin: 14px auto 0; max-width: 280px; }
.wheel-choice-panel { min-width: 0; background: var(--elevated); border: 1px solid var(--border); border-radius: 20px; padding: 17px 14px 9px; margin-top: 18px; }
.wheel-section-heading { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.wheel-section-heading h3 { font-size: 14px; }
.wheel-section-heading > span { color: var(--muted); font-size: 10px; white-space: nowrap; }
.wheel-choice-panel > .hint { font-size: 10px; margin: 5px 0 12px; }
.wheel-choices { max-height: 400px; overflow: auto; scrollbar-width: thin; margin: 0 -5px; padding: 3px 5px; }
.wheel-choice { display: flex; width: 100%; min-height: 44px; align-items: center; text-align: left; gap: 9px; padding: 10px 2px; border: 0; border-bottom: 1px solid var(--border); background: transparent; border-radius: 0; }
.wheel-choice:hover:not(:disabled) { background: var(--surface); border-radius: 9px; }
.wheel-swatch { height: 10px; width: 10px; border-radius: 50%; flex: none; border: 1px solid #ffffff60; }
.wheel-choice-name { font-size: 12px; overflow-wrap: anywhere; min-width: 0; flex: 1; line-height: 1.4; }
.wheel-choice small { font: 10px var(--mono); color: var(--muted); flex: none; }
.wheel-choice[aria-pressed=false] .wheel-choice-name { text-decoration: line-through; color: var(--muted); }
.wheel-choice[aria-pressed=false] .wheel-swatch { opacity: .5; }
#wheel-edit { margin: 7px 0 0; width: 100%; }
.wheel-history-details { border-top: 1px solid var(--border); padding-top: 11px; margin-top: 8px; font-size: 12px; }
.wheel-history-details summary, .wheel-bulk-details summary { cursor: pointer; padding: 8px 0; color: var(--muted); }
#wheel-history-count:not(:empty) { padding: 1px 5px; border-radius: 5px; background: var(--accent-soft); margin-left: 5px; font-size: 10px; }
.wheel-history { padding: 0; margin: 8px 0; list-style: none; max-height: 260px; overflow: auto; scrollbar-width: thin; }
.wheel-history li { display: grid; grid-template-columns: 23px minmax(0,1fr); column-gap: 7px; padding: 9px 0; border-bottom: 1px solid var(--border); }
.wheel-history-name { overflow-wrap: anywhere; }
.wheel-history-number, .wheel-history small { font-size: 10px; color: var(--muted); }
.wheel-history small { grid-column: 2; margin-top: 3px; }
.wheel-history-details .button { font-size: 10px; padding: 7px 4px; }
.wheel-history-details .hint { font-size: 10px; }
.wheel-editor, .wheel-settings { border: 0; padding: 0; margin: 0; min-width: 0; }
.wheel-meta-grid { display: grid; grid-template-columns: minmax(0,1fr) 125px; gap: 14px; }
.wheel-options-heading { margin-top: 28px; }
.wheel-options-heading + .hint { margin: 6px 0 16px; }
.wheel-entries { padding: 4px; margin: -4px; max-height: 520px; overflow: auto; scrollbar-width: thin; }
.wheel-entry { display: grid; grid-template-columns: 32px 32px minmax(0,1fr) 58px 34px; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--border); }
.wheel-editor[data-weighted=true] .wheel-entry { grid-template-columns: 32px 32px minmax(0,1fr) 66px 58px 34px; }
.wheel-entry input:not([type=checkbox]) { min-height: 40px; padding: 8px 10px; font-size: 13px; }
.wheel-entry .wheel-weight { text-align: center; padding-inline: 4px !important; appearance: textfield; }
.wheel-weight-field { margin: 0; min-width: 0; }
.wheel-weight-field > span { display: block; color: var(--muted); font-size: 9px; text-align: center; margin-bottom: 3px; }
.wheel-weight::-webkit-inner-spin-button, .wheel-weight::-webkit-outer-spin-button { appearance: none; }
.wheel-entry input.wheel-color { width: 32px; min-height: 36px; padding: 3px; cursor: pointer; border-radius: 50%; border: 0; background: transparent; }
.wheel-color::-webkit-color-swatch-wrapper { padding: 0; }
.wheel-color::-webkit-color-swatch { border-radius: 50%; border: 1px solid var(--strong-border); }
.wheel-color::-moz-color-swatch { border-radius: 50%; border: 1px solid var(--strong-border); }
.wheel-enable, .wheel-delete { width: 32px; min-height: 40px; border: 0; padding: 0; border-radius: 10px; background: transparent; color: var(--muted); font-size: 19px; }
.wheel-enable[aria-pressed=true] { color: var(--accent); }
.wheel-enable:hover, .wheel-delete:hover { background: var(--elevated); }
.wheel-delete:hover { color: var(--error); }
.wheel-chance { font: 10px var(--mono); text-align: right; color: var(--muted); }
.wheel-entry[data-paused=true] .wheel-name { color: var(--muted); text-decoration: line-through; }
.wheel-list-actions { margin-top: 16px; gap: 6px; }
.wheel-list-actions #wheel-add { margin-right: auto; }
.wheel-bulk-details { margin-top: 20px; font-size: 13px; }
.wheel-bulk-details label { margin-top: 12px; }
.wheel-bulk-details .button { margin-top: 12px; }
.wheel-editor-footer { margin-top: 25px; padding-top: 22px; border-top: 1px solid var(--border); }
.wheel-editor-footer .primary { margin-right: auto; min-width: 100px; }
.wheel-settings > h3 { margin: 26px 5px 10px; font-size: 12px; }
.wheel-settings > h3:first-of-type { margin-top: 6px; }
.wheel-settings > h3 > span { font-weight: 400; margin-left: 7px; font-size: 11px; }
.settings-group { background: var(--elevated); border: 1px solid var(--border); border-radius: 18px; overflow: hidden; }
.switch-row, .setting-row { display: flex; align-items: center; gap: 18px; min-height: 68px; padding: 14px 20px; margin: 0; font-size: 13px; }
.settings-group > * + * { border-top: 1px solid var(--border); }
.switch-row > span { flex: 1; }
.switch-row small, .setting-row label small { display: block; font-size: 11px; font-weight: 400; color: var(--muted); margin-top: 4px; line-height: 1.5; }
.switch-row input[type=checkbox] { appearance: none; position: relative; width: 39px; height: 24px; min-width: 39px; margin: 0; border-radius: 20px; border: 1px solid var(--strong-border); background: var(--surface); cursor: pointer; }
.switch-row input::before { content: ''; position: absolute; width: 16px; height: 16px; top: 3px; left: 3px; background: var(--muted); border-radius: 50%; transition: transform .16s; }
.switch-row input:checked { background: var(--accent); border-color: var(--accent); }
.switch-row input:checked::before { transform: translateX(15px); background: var(--on-accent); }
.switch-row input:disabled { opacity: .45; cursor: default; }
.setting-row > label { flex: 1; margin: 0; font-size: 13px; }
.setting-row select { width: 155px; }
.setting-row input[type=range] { width: 140px; margin: 0; }
#wheel-volume-value { color: var(--muted); font: 10px var(--mono); margin-left: 8px; }
.wheel-stepper { display: flex; align-items: center; gap: 6px; }
.wheel-stepper input { width: 44px; min-height: 36px; padding: 5px 0; text-align: center; border: 0; background: transparent; appearance: textfield; }
.wheel-stepper input::-webkit-inner-spin-button { appearance: none; }
.wheel-stepper button { width: 34px; min-height: 34px; border-radius: 10px; border: 1px solid var(--border); background: var(--surface); color: var(--accent); font-size: 20px; padding: 0; }
.wheel-stepper > span { font-size: 12px; color: var(--muted); }
.wheel-library-dialog { width: min(650px, calc(100% - 28px)); max-width: 650px; }
.wheel-library-filters { display: grid; grid-template-columns: minmax(0,1fr) 150px; gap: 10px; margin: 22px 0 12px; }
.wheel-tag-filters { display: flex; flex-wrap: wrap; gap: 6px; }
.wheel-tag { font-size: 11px; padding: 6px 12px; min-height: 32px; border: 1px solid var(--border); border-radius: 20px; background: var(--elevated); }
.wheel-tag[aria-pressed=true] { background: var(--accent-soft); color: var(--accent); border-color: var(--checked-border); }
#wheel-library-note { font-size: 11px; margin: 14px 0; }
.wheel-library-list { margin: 8px 0 20px; display: grid; gap: 10px; }
.wheel-library-card { position: relative; display: flex; align-items: center; background: var(--elevated); border: 1px solid var(--border); border-radius: 18px; min-width: 0; }
.wheel-card-open { min-width: 0; flex: 1; display: flex; align-items: center; gap: 15px; padding: 17px; background: transparent; border: 0; text-align: left; border-radius: 18px; }
.wheel-card-open:hover { background: var(--accent-soft); }
.wheel-card-symbol { display: grid; place-items: center; width: 43px; height: 43px; border-radius: 14px; background: var(--accent-soft); color: var(--accent); flex: none; }
.wheel-card-open > span:last-child { min-width: 0; }
.wheel-card-open strong { display: block; font-weight: 600; font-size: 14px; overflow-wrap: anywhere; }
.wheel-card-open small { display: block; font-size: 11px; color: var(--muted); margin-top: 4px; overflow-wrap: anywhere; }
.wheel-card-menu { margin-right: 9px; }
.wheel-card-menu summary { list-style: none; width: 40px; min-height: 40px; display: grid; place-items: center; cursor: pointer; color: var(--muted); border-radius: 50%; }
.wheel-card-menu summary::-webkit-details-marker { display: none; }
.wheel-card-menu summary:hover, .wheel-card-menu[open] summary { background: var(--surface); }
.wheel-card-actions { position: absolute; right: 14px; top: 64px; z-index: 2; display: grid; min-width: 140px; border: 1px solid var(--strong-border); background: var(--surface); padding: 5px; border-radius: 13px; box-shadow: 0 10px 25px var(--shadow); }
.wheel-card-actions button { padding: 10px 12px; font-size: 12px; border: 0; background: transparent; text-align: left; border-radius: 8px; }
.wheel-card-actions button:hover { background: var(--accent-soft); }
.wheel-card-actions button:last-child { color: var(--error); }
.wheel-library-empty { padding: 22px 10px; font-size: 13px; color: var(--muted); text-align: center; }
.wheel-templates-heading { margin: 30px 0 14px; }
.wheel-templates { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.wheel-template { display: flex; align-items: center; text-align: left; gap: 12px; padding: 16px; border: 1px solid var(--border); border-radius: 15px; background: var(--elevated); font-size: 12px; }
.wheel-template .icon { color: var(--accent); }
.wheel-template:hover { background: var(--accent-soft); }
#wheel-import-data { font-size: 12px; }
#wheel-file { padding: 8px; font-size: 12px; }
#wheel-confirm-dialog .actions { justify-content: flex-end; margin-top: 25px; }
.wheel-tool .method-note { margin-top: 28px; }
@media (max-width: 1100px) { .wheel-play-layout { grid-template-columns: minmax(0,1fr); gap: 18px; } .wheel-stage { max-width: 500px; width: 100%; margin-inline: auto; } .wheel-choice-panel { margin-top: 10px; } .wheel-choices { display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; max-height: 280px; } }
@media (max-width: 760px) { .wheel-tool { padding: 24px; } .wheel-toolbar .actions { margin-left: auto; } .wheel-tool .tool-heading { flex-wrap: nowrap; } .wheel-tool .tool-heading h2 { font-size: 24px; } .wheel-tool .eyebrow { font-size: 8px; letter-spacing: 1.2px; } }
@media (max-width: 440px) {
  .wheel-tool { padding: 20px 15px; }
  .wheel-tool .tool-heading { gap: 10px; align-items: center; }
  .wheel-tool .tool-heading h2 { font-size: 22px; }
  .wheel-tool .tool-heading .eyebrow { display: none; }
  #wheel-library-open { font-size: 11px; padding: 8px 10px; gap: 7px; }
  .wheel-toolbar { gap: 10px; }
  .wheel-views.segments { width: 100%; }
  .wheel-toolbar .actions { width: 100%; justify-content: space-between; }
  .wheel-toolbar .actions .button { padding-inline: 10px; font-size: 11px; }
  .wheel-stage { padding-top: 5px; }
  .wheel-result-card { padding-bottom: 28px; min-height: 105px; }
  .wheel-question h3 { font-size: 13px; }
  #wheel-result { font-size: 28px; }
  .wheel-choice-panel { padding-inline: 13px; }
  .wheel-choices { grid-template-columns: 1fr; }
  .wheel-choice-name { font-size: 13px; }
  .wheel-meta-grid { grid-template-columns: minmax(0,1fr) 95px; gap: 8px; }
  .wheel-entry, .wheel-editor[data-weighted=true] .wheel-entry { grid-template-columns: 30px 28px minmax(0,1fr) 30px; gap: 6px; }
  .wheel-entry .wheel-name { grid-column: 3; }
  .wheel-entry .wheel-color { width: 28px; }
  .wheel-entry .wheel-weight-field { grid-column: 3; grid-row: 2; max-width: 102px; display: flex; align-items: center; gap: 6px; }
  .wheel-weight-field > span { margin: 0; }
  .wheel-entry .wheel-weight { width: 55px; min-height: 34px !important; }
  .wheel-entry .wheel-chance { grid-column: 3; grid-row: 2; justify-self: end; }
  .wheel-entry .wheel-delete { grid-column: 4; grid-row: 1; }
  .wheel-entry .wheel-enable, .wheel-entry .wheel-delete { width: 30px; }
  .wheel-list-actions { gap: 2px; }
  .wheel-list-actions .button { font-size: 10px; padding-inline: 8px; }
  .switch-row, .setting-row { padding: 14px; gap: 12px; }
  .setting-row select { width: 110px; }
  .setting-row input[type=range] { width: 78px; }
  #wheel-volume-value { display: block; margin-left: 0; }
  .setting-row .button { padding-inline: 0; font-size: 11px; }
  .wheel-library-dialog { padding: 22px 16px; }
  .wheel-library-filters { grid-template-columns: minmax(0,1fr); }
  .wheel-library-filters select { padding-left: 8px; font-size: 11px; }
  .wheel-card-open { gap: 10px; padding: 13px 10px; }
  .wheel-card-symbol { width: 34px; height: 34px; border-radius: 11px; }
  .wheel-templates { gap: 8px; }
  .wheel-template { padding: 12px; gap: 8px; font-size: 11px; }
  #wheel-confirm-dialog .actions { flex-wrap: wrap; }
}
@media (forced-colors: active) { #wheel-canvas, .wheel-pointer, .wheel-hub, .wheel-swatch { forced-color-adjust: none; } .switch-row input { appearance: auto; } .switch-row input::before { display: none; } .wheel-choice[aria-pressed=false] { border: 1px dashed GrayText; } }
