/* Shared primitives. Load after theme.css; all rules are scoped to .ors-theme.
   Existing class names are the component contract; no app-specific IDs or grid. */
.ors-theme {
  font-family: var(--ors-font-family);
  font-size: var(--ors-font-base);
  font-synthesis: none;
  line-height: var(--ors-line-body);
  color: var(--ors-color-text);
  background: var(--ors-color-canvas);
}
.ors-theme *, .ors-theme *::before, .ors-theme *::after { box-sizing: border-box; }
.ors-theme body { margin: 0; }
.ors-theme [hidden] { display: none !important; }
.ors-theme a { color: inherit; text-decoration: none; }
.ors-theme :is(a, button, input, select, summary, [tabindex]):focus-visible {
  outline: var(--ors-focus-width) solid var(--ors-color-focus);
  outline-offset: var(--ors-focus-offset);
}
.ors-theme .panel {
  padding: var(--ors-space-5) var(--ors-space-6);
  background: var(--ors-color-surface);
  border: var(--ors-border-width) solid var(--ors-color-border);
  border-radius: var(--ors-radius-lg);
  box-shadow: var(--ors-shadow-surface);
}
.ors-theme .button {
  min-height: var(--ors-control-height);
  padding: var(--ors-space-2) var(--ors-space-4);
  border: var(--ors-border-width) solid transparent;
  border-radius: var(--ors-radius-md);
  font: inherit;
  font-size: var(--ors-font-sm);
  font-weight: var(--ors-weight-medium);
  line-height: var(--ors-line-tight);
  cursor: pointer;
}
.ors-theme .primary { color: var(--ors-color-on-accent); background: var(--ors-color-action); box-shadow: var(--ors-shadow-action); }
.ors-theme .primary:hover { background: var(--ors-color-action-hover); }
.ors-theme .primary:active { background: var(--ors-color-action-active); }
.ors-theme .secondary { color: var(--ors-color-text); background: var(--ors-color-surface); border-color: var(--ors-color-control-border); }
.ors-theme .secondary:hover { color: var(--ors-color-accent); background: var(--ors-color-surface-hover); }
.ors-theme .secondary:active { background: var(--ors-color-surface-selected); }
.ors-theme .button:disabled { color: var(--ors-color-disabled-text); background: var(--ors-color-disabled-bg); border-color: var(--ors-color-border); box-shadow: none; cursor: default; }
.ors-theme :is(input, select) {
  min-height: var(--ors-control-height);
  max-width: 100%;
  padding: var(--ors-space-2) var(--ors-space-3);
  border: var(--ors-border-width) solid var(--ors-color-control-border);
  border-radius: var(--ors-radius-md);
  font: inherit;
  font-size: var(--ors-font-md);
  color: var(--ors-color-text);
  background: var(--ors-color-input-bg);
}
.ors-theme :is(input, select):hover { border-color: var(--ors-color-accent); }
.ors-theme input::placeholder { color: var(--ors-color-muted); opacity: 1; }
.ors-theme .badge { display: inline-block; padding: var(--ors-space-1) var(--ors-space-2); color: var(--ors-color-muted); background: var(--ors-color-surface-subtle); border: var(--ors-border-width) solid var(--ors-color-border); border-radius: var(--ors-radius-pill); font-size: var(--ors-font-xs); }
.ors-theme :is(.notice, .warning) { margin: var(--ors-space-3) 0; padding: var(--ors-space-3) var(--ors-space-4); border: var(--ors-border-width) solid; border-radius: var(--ors-radius-md); font-size: var(--ors-font-sm); line-height: var(--ors-line-relaxed); overflow-wrap: anywhere; }
.ors-theme .notice { color: var(--ors-color-danger-text); background: var(--ors-color-danger-bg); border-color: var(--ors-color-danger-border); }
.ors-theme .warning { color: var(--ors-color-warning-text); background: var(--ors-color-warning-bg); border-color: var(--ors-color-warning-border); }
.ors-theme .product-link { color: var(--ors-color-accent); text-decoration: underline; text-underline-offset: 3px; }
.ors-theme .product-link:hover { color: var(--ors-color-accent-hover); }
.ors-theme .table-wrap { max-width: 100%; overflow-x: auto; }
@media (forced-colors: active) {
  .ors-theme .button, .ors-theme :is(input, select) { border-color: ButtonText; }
  .ors-theme :is(a, button, input, select, summary, [tabindex]):focus-visible { outline-color: Highlight; }
}
