/* Nexum's own styles: page layout and the board, on the governed design tokens only (no colour literal; the console's
   rule, web/platform/public/assets/console.css). The shell (.shell*), .card, .btn, .badge, .stat, .input, .field,
   .modal, .broadcast, .toast, .spinner and .icon are the design system's (design.css). */

html, body { height: auto; min-height: 100%; }
body { overflow: auto; font-size: var(--text-base); line-height: var(--lh-body); }
h1, h2, h3 { margin: 0; font-weight: var(--weight-bold); line-height: var(--lh-tight); }
h1 { font-size: var(--text-xl); }
h2 { font-size: var(--text-lg); }
h3 { font-size: var(--text-base); }
p { margin: 0; }
button { font: inherit; }
.noscript { padding: var(--space-6); text-align: center; }
[hidden] { display: none !important; }
.muted { color: var(--muted); }
.mono { font-family: var(--mono); overflow-wrap: anywhere; }
.stack { display: flex; flex-direction: column; gap: var(--space-5); }
.row { display: flex; align-items: center; gap: var(--space-3); flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.spacer { flex: 1; }
.btn:hover, a.btn:hover { text-decoration: none; }
a.btn-accent, a.btn-accent:hover { color: var(--on-accent); }

/* Page head: the title in its own card (the reference layout), actions on the right. */
.head { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--space-4); flex-wrap: wrap; }
.head h1 { font-size: var(--text-2xl); }
.head p { color: var(--muted); margin-top: var(--space-2); }

.grid { display: grid; gap: var(--space-5); }
.grid.kpis { grid-template-columns: repeat(auto-fit, minmax(calc(var(--space-12) * 2.5), 1fr)); }
.kpi .stat-n { font-size: var(--text-2xl); line-height: var(--lh-tight); }
.kpi .stat-k { display: block; margin-bottom: var(--space-2); }

.list { display: flex; flex-direction: column; }
.list-row { display: flex; align-items: center; gap: var(--space-4); padding: var(--space-4) 0; border-bottom: 1px solid var(--border); }
.list-row:last-child { border-bottom: 0; }
.list-row .grow { flex: 1; min-width: 0; }
.list-row a { font-weight: var(--weight-bold); }

/* Board: one column per board column, cards stacked; the columns scroll sideways on a narrow screen. */
.board { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(calc(var(--space-12) * 2.6), 1fr); gap: var(--space-5); overflow-x: auto; align-items: start; padding-bottom: var(--space-3); }
.column { display: flex; flex-direction: column; gap: var(--space-4); padding: var(--space-5); background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); }
.column-head { display: flex; align-items: center; gap: var(--space-3); }
.column-head h2 { font-size: var(--text-base); }
.tile { display: flex; flex-direction: column; gap: var(--space-3); padding: var(--space-4); background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.tile .handle { font-family: var(--mono); font-size: var(--text-xs); color: var(--muted); }
.tile .title { font-weight: var(--weight-bold); }
.tile select { width: 100%; }
.empty-col { color: var(--muted); font-size: var(--text-sm); }

/* App mark: the app's one identity (colour + initial); the company's look everywhere else. */
.app-mark { display: inline-grid; place-items: center; inline-size: var(--space-7); block-size: var(--space-7); border-radius: var(--radius-sm); background: var(--app-accent); color: var(--on-accent); font-weight: var(--weight-bold); }
/* Nexum's app colour (provisional, docs/decisions.md A-19): the design system's orange data hue. */
:root { --app-accent: var(--viz-cat-2); }

.form { display: flex; flex-direction: column; gap: var(--space-5); }

/* Sign-in and callback pages (login.html, callback.html): copied from web/platform/public/assets/console.css. */
.auth-page { min-height: 100vh; display: grid; place-items: center; padding: var(--space-5); }
.auth-main { width: min(calc(var(--space-13) * 4.5), 100%); }
.auth-card { display: flex; flex-direction: column; gap: var(--space-5); padding: var(--space-7); }
.auth-card .brand { display: flex; align-items: center; gap: var(--space-3); color: var(--text); font-weight: var(--weight-bold); font-size: var(--text-lg); }
.auth-card .brand img { height: var(--space-7); width: auto; }
.auth-card .btn { justify-content: center; padding: var(--space-3) var(--space-5); }
.shell-brand img { height: var(--space-7); width: auto; }
