/**
 * GilGamez Studio Platform — Design System & Token Architecture
 * Strictly conforms to DEVELOPMENT_RULES.md (Rule #12 Enterprise Tokens & Rule #18 6px Gold Scrollbars).
 */

:root {
  /* Surface Elevation & Depths */
  --store-surface-0: #09090b;         /* App canvas background */
  --store-bg-base: #09090b;
  --store-surface-1: #121215;         /* Primary cards, headers, decks */
  --store-surface-2: #18181b;         /* Elevated modals, drawers, popovers */
  --store-surface-inset: #0d0d10;     /* Inset panels, input backgrounds */
  --store-surface-hover: #1f1f24;     /* Card/row hover state */

  /* Borders & Dividers */
  --store-border-subtle: rgba(255, 255, 255, 0.08);
  --store-border-medium: rgba(255, 255, 255, 0.14);
  --store-border-focus: #c5a059;
  --store-border-active: #d4af37;

  /* Enterprise Gold Accents */
  --store-accent-primary: #c5a059;
  --store-accent-hover: #d4af37;
  --store-accent-glow: rgba(197, 160, 89, 0.25);
  --store-accent-subtle: rgba(197, 160, 89, 0.08);
  --cc-solid-accent: #c5a059;
  --cc-solid-accent-hover: #d4af37;

  /* Typography Colors */
  --store-text-primary: #f4f4f5;
  --store-text-secondary: #a1a1aa;
  --store-text-muted: #71717a;
  --store-text-gold: #e5c07b;

  /* Semantic Status Colors */
  --store-status-success: #10b981;
  --store-status-warning: #f59e0b;
  --store-status-danger: #ef4444;
  --store-status-info: #06b6d4;
  --store-status-neutral: #64748b;

  /* Shadows & Elevation */
  --store-shadow-card: 0 4px 16px rgba(0, 0, 0, 0.35);
  --store-shadow-drawer: -4px 0 24px rgba(0, 0, 0, 0.5);
  --store-shadow-modal: 0 12px 36px rgba(0, 0, 0, 0.65);
  --store-shadow-focus: 0 0 0 2px var(--store-accent-glow);

  /* Sizing & Radius */
  --store-radius-sm: 6px;
  --store-radius-md: 10px;
  --store-radius-lg: 14px;
  --store-radius-full: 9999px;
  --store-control-height: 44px;
  --store-font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --store-font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

/* Universal Mandatory 6px Gold Custom Scrollbars (Rule #18) */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--cc-solid-accent, #c5a059) transparent;
}

::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: var(--cc-solid-accent, #c5a059);
  border-radius: 9999px;
  transition: background-color 0.2s ease;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--cc-solid-accent-hover, #d4af37);
}
::-webkit-scrollbar-corner {
  background: transparent;
}

/* Accessible Toast Container */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 380px;
}

.toast-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  border-radius: var(--store-radius-sm, 6px);
  background: var(--store-surface-2, #18181b);
  border: 1px solid var(--store-border-medium, rgba(255, 255, 255, 0.14));
  border-left: 4px solid var(--store-accent-primary, #c5a059);
  color: var(--store-text-primary, #f4f4f5);
  box-shadow: var(--store-shadow-card);
  font-size: 13px;
  font-weight: 600;
}

.toast-card.toast-success { border-left-color: var(--store-status-success, #10b981); }
.toast-card.toast-error { border-left-color: var(--store-status-danger, #ef4444); }
.toast-card.toast-warning { border-left-color: var(--store-status-warning, #f59e0b); }

.toast-close-btn {
  background: transparent;
  border: none;
  color: var(--store-text-secondary, #a1a1aa);
  font-size: 18px;
  cursor: pointer;
  padding: 0 4px;
}
