/* ════════════════════════════════════════════════════════════════
   AICRAM STUDIO — TWEAKS PANEL (styles)
   Hidden until the host enables Tweaks.
   ════════════════════════════════════════════════════════════════ */
#tweaksRoot { display: none; }
#tweaksRoot.on { display: block; }

.tw-panel {
  position: fixed; top: 16px; right: 16px; z-index: 9500;
  width: 296px; max-height: calc(100vh - 32px); overflow-y: auto;
  background: var(--c-surface); color: var(--c-text-1);
  border: 1px solid var(--c-border); border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg); font-family: var(--f-sans);
  animation: twIn 0.3s var(--ease-spring);
}
@keyframes twIn { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
.tw-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; border-bottom: 1px solid var(--c-border); cursor: grab; }
.tw-head b { font-family: var(--f-serif); font-size: 18px; }
.tw-head .x { width: 28px; height: 28px; border-radius: var(--r-sm); background: var(--c-bg); border: 1px solid var(--c-border); color: var(--c-text-2); display: flex; align-items: center; justify-content: center; }
.tw-head .x:hover { background: var(--c-error); border-color: var(--c-error); color: #fff; }
.tw-body { padding: 14px 16px 18px; }
.tw-sec { font-size: 10px; letter-spacing: 1.6px; text-transform: uppercase; color: var(--c-text-3); margin: 16px 0 8px; }
.tw-sec:first-child { margin-top: 0; }
.tw-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.tw-row .lbl { font-size: 13px; color: var(--c-text-2); }
.tw-swatches { display: flex; gap: 8px; }
.tw-swatch { width: 30px; height: 30px; border-radius: 50%; border: 2px solid transparent; cursor: pointer; transition: transform 0.2s; }
.tw-swatch:hover { transform: scale(1.1); }
.tw-swatch.sel { border-color: var(--c-text-1); box-shadow: 0 0 0 2px var(--c-surface) inset; }
.tw-seg { display: inline-flex; background: var(--c-bg-2); border-radius: var(--r-md); padding: 3px; gap: 3px; width: 100%; }
.tw-seg button { flex: 1; padding: 7px 8px; font-size: 12px; border-radius: calc(var(--r-md) - 3px); color: var(--c-text-2); transition: all 0.2s; }
.tw-seg button.active { background: var(--c-surface); color: var(--c-dark); box-shadow: var(--shadow-sm); }
.tw-switch { width: 44px; height: 26px; border-radius: 100px; background: var(--c-bg-2); border: 1px solid var(--c-border); position: relative; transition: background 0.25s; flex-shrink: 0; }
.tw-switch::after { content: ''; position: absolute; top: 2px; left: 2px; width: 20px; height: 20px; border-radius: 50%; background: var(--c-surface); box-shadow: var(--shadow-sm); transition: transform 0.25s var(--ease-spring); }
.tw-switch.on { background: var(--c-accent); }
.tw-switch.on::after { transform: translateX(18px); }
.tw-note { font-size: 11px; color: var(--c-text-3); line-height: 1.5; margin-top: 4px; }
.tw-net-tag { display: inline-block; font-size: 10px; letter-spacing: 1px; text-transform: uppercase; color: var(--c-warning); margin-top: 6px; }
@media (max-width: 540px) { .tw-panel { width: calc(100vw - 24px); right: 12px; top: 12px; } }
