/* Jarvis Studio — interface documental, mobile-first.
   Uma única folha, sem build. Cores em variáveis: data-theme="ink" | "paper". */

/* Regra global: os painéis abaixo têm display:flex/flex-grid declarado e venceriam
   o atributo hidden do HTML sem esta guarda. */
[hidden] {
  display: none !important;
}

:root,
html[data-theme="ink"] {
  color-scheme: dark;
  --bg: #0d0e10;
  --bg-elev: #111317;
  --panel: #16181d;
  --panel-soft: #1b1e24;
  --panel-hover: #20242b;
  --text: #eae7e1;
  --text-soft: #c7c3ba;
  --muted: #a0a3a0;
  --faint: #949795;
  --line: rgba(255, 255, 255, 0.075);
  --line-strong: rgba(255, 255, 255, 0.14);
  --accent: #d3ad78;
  --accent-soft: rgba(211, 173, 120, 0.13);
  --accent-line: rgba(211, 173, 120, 0.35);
  --accent-text: #f0dcbc;
  --green: #83bf9d;
  --red: #e09282;
  --blue: #93b6d8;
  --paper: #fbfaf6;
  --paper-ink: #22211d;
  --code-bg: #0b0c0e;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
  --shadow-soft: 0 8px 28px rgba(0, 0, 0, 0.25);
  --font-ui: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --font-mono: "JetBrains Mono", "Cascadia Code", Consolas, monospace;
  --chat-width: 790px;
  --rail-w: 272px;
  --viewer-w: 46%;
  --docs-w: 198px;
  --radius: 16px;
  --radius-sm: 11px;
  --ease-spring: cubic-bezier(0.175, 0.885, 0.32, 1.15);
  --ease-smooth: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-out-quint: cubic-bezier(0.22, 1, 0.36, 1);
  --trans-fast: 0.16s var(--ease-smooth);
  --trans-base: 0.24s var(--ease-smooth);
  --trans-spring: 0.32s var(--ease-spring);
}

html {
  transition: background-color 0.4s ease, color 0.4s ease, border-color 0.4s ease;
}

html[data-theme="paper"] {
  color-scheme: light;
  --bg: #f3f0e8;
  --bg-elev: #faf8f2;
  --panel: #fffdf8;
  --panel-soft: #f4f0e6;
  --panel-hover: #ebe5d8;
  --text: #26241f;
  --text-soft: #45413a;
  --muted: #736d61;
  --faint: #979082;
  --line: rgba(35, 30, 20, 0.12);
  --line-strong: rgba(35, 30, 20, 0.22);
  --accent: #9a6b2e;
  --accent-soft: rgba(154, 107, 46, 0.12);
  --accent-line: rgba(154, 107, 46, 0.35);
  --accent-text: #6f4a17;
  --green: #3f7d5c;
  --red: #a94b3c;
  --blue: #3c6c96;
  --paper: #fffefa;
  --paper-ink: #22211d;
  --code-bg: #f0ece2;
  --shadow: 0 24px 70px rgba(60, 48, 25, 0.18);
  --shadow-soft: 0 8px 26px rgba(60, 48, 25, 0.1);
}

* { box-sizing: border-box; }

html,
body {
  height: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-ui);
  font-size: 15px;
  line-height: 1.6;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
}

a {
  color: var(--accent-text);
}

::selection {
  background: var(--accent-soft);
  color: var(--text);
}

::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: var(--line-strong);
  border-radius: 99px;
  border: 3px solid transparent;
  background-clip: padding-box;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

