/* Artist drawer (UV / regions / decals / dress / shot). Reuses the .matstudio chrome; tokens only. */

.artist { z-index: 13; width: min(440px, 94vw); }
.ar-tab { gap: var(--space-2); }

/* ---- UV ---- */
.ar-stage { position: relative; align-self: center; width: 100%; max-width: 400px; aspect-ratio: 1; background: var(--color-bg-sunken); border: 1px solid var(--color-border); border-radius: var(--radius-md); overflow: hidden; }
.ar-uvimg { display: block; width: 100%; height: 100%; object-fit: contain; image-rendering: auto; cursor: crosshair; user-select: none; }
.ar-uvimg.busy { opacity: 0.5; }
.ar-marker { position: absolute; width: 12px; height: 12px; margin: -6px 0 0 -6px; border: 2px solid var(--color-accent); border-radius: 50%; pointer-events: none; box-shadow: 0 0 0 1px var(--color-bg-base); }
.ar-legend { display: flex; flex-wrap: wrap; gap: var(--space-1); }
.ar-chip { display: inline-flex; align-items: center; gap: 4px; padding: 1px var(--space-2); background: var(--color-bg-raised); border: 1px solid var(--color-border); border-radius: var(--radius-sm); font-size: var(--text-xs); color: var(--color-text-secondary); }
.ar-chip i, .ar-dot { display: inline-block; width: 10px; height: 10px; border-radius: 2px; border: 1px solid var(--color-border-strong); flex: 0 0 auto; }
.ar-pick { user-select: text; min-height: 1.4em; }
.ar-islands { max-height: 180px; overflow-y: auto; }
.ar-island { flex-direction: row; align-items: center; gap: var(--space-2); text-align: left; padding: 2px var(--space-2); }
.ar-island b { font-weight: var(--weight-medium); color: var(--color-text-primary); text-transform: none; }
.ar-island .ms-hint { flex: 1; text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---- problems / reports ---- */
.ar-summary { display: flex; align-items: center; gap: var(--space-2); flex-wrap: wrap; margin-bottom: var(--space-1); }
.ar-badge { display: inline-block; padding: 0 var(--space-2); border-radius: var(--radius-sm); font-size: var(--text-xs); text-transform: uppercase; letter-spacing: var(--tracking-wide); border: 1px solid var(--color-border-strong); color: var(--color-text-secondary); flex: 0 0 auto; }
.ar-badge.error { color: var(--color-danger); border-color: var(--color-danger); }
.ar-badge.warning { color: var(--color-warning); border-color: var(--color-warning); }
.ar-badge.info { color: var(--color-text-secondary); }
.ar-problem { display: flex; align-items: flex-start; gap: var(--space-2); padding: var(--space-1) 0; border-top: 1px solid var(--color-border); }
.ar-ptext { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; font-size: var(--text-xs); }
.ar-ptext b { text-transform: capitalize; color: var(--color-text-primary); }
.ar-ptext span { color: var(--color-text-secondary); overflow-wrap: anywhere; }
.ar-fixbtn { flex: 0 0 auto; }
.ar-score { display: inline-flex; align-items: center; justify-content: center; min-width: 34px; height: 24px; padding: 0 var(--space-2); border-radius: var(--radius-sm); font-weight: var(--weight-semibold); background: var(--color-bg-raised); border: 1px solid var(--color-border-strong); }
.ar-score.good { color: var(--color-success); border-color: var(--color-success); }
.ar-score.mid { color: var(--color-warning); border-color: var(--color-warning); }
.ar-score.poor { color: var(--color-danger); border-color: var(--color-danger); }
.ar-fixout { user-select: text; }

/* ---- regions / decals ---- */
.ar-part, .ar-region { text-align: left; }
.ar-part { flex-direction: row; align-items: center; justify-content: space-between; gap: var(--space-2); padding: 2px var(--space-2); }
.ar-part b { font-weight: var(--weight-medium); color: var(--color-text-primary); }
.ar-parts { max-height: 160px; overflow-y: auto; }
.ar-info { margin: 0; padding: var(--space-2); background: var(--color-bg-sunken); border: 1px solid var(--color-border); border-radius: var(--radius-sm); font-family: var(--font-mono); font-size: var(--text-xs); white-space: pre-wrap; overflow-wrap: anywhere; max-height: 160px; overflow-y: auto; user-select: text; }
.ar-explain .ms-hint { margin-bottom: var(--space-1); }
.ar-gallery { max-height: 220px; overflow-y: auto; }
.ar-armed, #viewport.ar-armed { cursor: crosshair; }
.matstudio button.active { background: var(--color-accent-muted); color: var(--color-text-primary); }

/* ---- dress ---- */
.ar-swatch { width: 22px; height: 22px; padding: 0; border-radius: var(--radius-sm); border: 1px solid var(--color-border-strong); }
.ar-palette { flex: 1; min-width: 0; align-items: center; }
.ar-step.off { opacity: 0.5; }
.ar-why { font-style: italic; }
.ar-variants { grid-template-columns: repeat(2, 1fr); }
.ar-variant { text-align: left; align-items: stretch; }
.ar-variant b { color: var(--color-text-primary); }
.ar-variant .ms-doc { white-space: normal; text-transform: none; }
.ar-palrow { display: flex; gap: 2px; }
.ar-palrow i { flex: 1; height: 8px; border-radius: 2px; }

/* ---- shot ---- */
.ar-shotimg { width: 100%; border: 1px solid var(--color-border); border-radius: var(--radius-md); background: var(--color-bg-sunken); }
.artist .name-flex { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.artist .ms-grid input[type='text'] { width: 100%; }
.artist .ms-field > select { min-width: 0; }

.ar-part .ms-hint, .ar-island .ms-hint, .ar-region .ms-hint { text-transform: none; }
.artist .ms-field.ms-col textarea.ms-json { min-height: 0; height: 30px; }
.artist .ar-step textarea.ms-json, .artist .ms-json[aria-label="intent"] { height: auto; min-height: 36px; }

/* U13: draggable title bar and the one-line tab explanation */
.ms-head.ar-drag { cursor: move; }
.ar-tab-help { margin: 0; padding: var(--space-2) var(--space-3); font-size: 11px; line-height: 1.35; color: var(--color-text-muted); border-bottom: 1px solid var(--color-border); user-select: none; }
