:root {
	--bg: #f6f7f9;
	--surface: #ffffff;
	--surface-2: #f0f2f5;
	--text: #16191d;
	--muted: #5d6670;
	--border: #e1e5ea;
	--accent: #2456d6;
	--accent-soft: rgba(36, 86, 214, 0.1);
	--good: #0f8a4b;
	--warn: #b86a00;
	--bad: #c2352b;
	--company: #2456d6;
	--guest: #8a4fd0;
	--radius: 10px;
	--mono: ui-monospace, SFMono-Regular, Menlo, monospace;
	color-scheme: light;
}

@media (prefers-color-scheme: dark) {
	:root {
		--bg: #111317;
		--surface: #191c21;
		--surface-2: #20242a;
		--text: #e8eaed;
		--muted: #98a1ab;
		--border: #2c3138;
		--accent: #7aa2ff;
		--accent-soft: rgba(122, 162, 255, 0.14);
		--good: #43c785;
		--warn: #f0a33a;
		--bad: #f07167;
		--company: #7aa2ff;
		--guest: #c39bff;
		color-scheme: dark;
	}
}

* { box-sizing: border-box; }

html, body {
	margin: 0;
	height: 100%;
	background: var(--bg);
	color: var(--text);
	font: 14px/1.45 -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, sans-serif;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

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

button {
	cursor: pointer;
	padding: 6px 12px;
	border: 1px solid var(--border);
	border-radius: 8px;
	background: var(--surface);
}
button:hover { border-color: var(--accent); }
button:disabled { opacity: 0.5; cursor: default; }

.nt-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.nt-danger { color: var(--bad); }

input, select, textarea {
	padding: 6px 8px;
	border: 1px solid var(--border);
	border-radius: 8px;
	background: var(--surface);
	min-width: 0;
}
textarea { width: 100%; resize: vertical; }

.nt-app { display: flex; flex-direction: column; min-height: 100%; }

.nt-top {
	position: sticky;
	top: 0;
	z-index: 2;
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 10px 16px;
	border-bottom: 1px solid var(--border);
	background: var(--surface);
}
.nt-brand { font-weight: 700; letter-spacing: 0.01em; }
.nt-nav { display: flex; gap: 4px; }
.nt-nav a { padding: 4px 10px; border-radius: 999px; color: var(--muted); }
.nt-nav a.on { background: var(--accent-soft); color: var(--accent); text-decoration: none; }
.nt-spacer { flex: 1; }

.nt-main { padding: 16px; max-width: 1400px; width: 100%; margin: 0 auto; }

.nt-card {
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--radius);
	padding: 14px;
}
.nt-card + .nt-card { margin-top: 12px; }
.nt-card h2, .nt-card h3 { margin: 0 0 8px; font-size: 13px; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted); }

.nt-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.nt-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 8px; }
.nt-field { display: flex; flex-direction: column; gap: 4px; }
.nt-field span { font-size: 12px; color: var(--muted); }
.nt-muted { color: var(--muted); }
.nt-small { font-size: 12px; }
.nt-empty { color: var(--muted); padding: 8px 0; }
.nt-error { color: var(--bad); }

.nt-pill {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 2px 8px;
	border-radius: 999px;
	background: var(--surface-2);
	color: var(--muted);
	font-size: 12px;
	white-space: nowrap;
}
.nt-pill.good { color: var(--good); }
.nt-pill.warn { color: var(--warn); }
.nt-pill.bad { color: var(--bad); }
.nt-pill.accent { color: var(--accent); background: var(--accent-soft); }
.nt-dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.nt-live .nt-dot { animation: nt-pulse 1.4s ease-in-out infinite; }
@keyframes nt-pulse { 50% { opacity: 0.3; } }

.nt-seg { display: inline-flex; padding: 2px; border-radius: 999px; background: var(--surface-2); }
.nt-seg button { border: 0; border-radius: 999px; background: transparent; color: var(--muted); padding: 3px 12px; }
.nt-seg button.on { background: var(--surface); color: var(--text); box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12); }

.nt-list { display: flex; flex-direction: column; }
.nt-list-head { margin: 16px 0 6px; font-size: 12px; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted); }
.nt-item {
	display: grid;
	grid-template-columns: 1fr auto auto auto;
	gap: 12px;
	align-items: center;
	padding: 10px 12px;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	background: var(--surface);
	color: inherit;
}
.nt-item + .nt-item { margin-top: 6px; }
.nt-item:hover { border-color: var(--accent); text-decoration: none; }
.nt-item strong { display: block; }

.nt-meeting { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.nt-head { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 12px; }
.nt-head h1 { margin: 0; font-size: 20px; }

.nt-transcript { max-height: calc(100vh - 170px); overflow-y: auto; padding-right: 4px; }
.nt-line { display: grid; grid-template-columns: 48px 1fr; gap: 8px; padding: 5px 0; }
.nt-line time { font-family: var(--mono); font-size: 11px; color: var(--muted); padding-top: 2px; }
.nt-line b { font-weight: 600; margin-right: 6px; }
.nt-line.company b { color: var(--company); }
.nt-line.guest b { color: var(--guest); }
.nt-line.command { background: var(--accent-soft); border-radius: 6px; }
.nt-line.partial { opacity: 0.55; font-style: italic; }

.nt-side { display: flex; flex-direction: column; gap: 12px; position: sticky; top: 64px; max-height: calc(100vh - 80px); overflow-y: auto; }
.nt-side .nt-card + .nt-card { margin-top: 0; }

.nt-meter { height: 8px; border-radius: 999px; background: var(--surface-2); overflow: hidden; position: relative; }
.nt-meter i { position: absolute; top: 0; bottom: 0; left: 50%; border-radius: 999px; }
.nt-split { display: flex; height: 8px; border-radius: 999px; overflow: hidden; background: var(--surface-2); }
.nt-split i:first-child { background: var(--company); }
.nt-split i:last-child { background: var(--guest); }

.nt-bullets { margin: 0; padding-left: 18px; }
.nt-bullets li + li { margin-top: 4px; }

.nt-move { border-left: 3px solid var(--accent); padding: 6px 10px; background: var(--surface-2); border-radius: 0 8px 8px 0; }
.nt-move + .nt-move { margin-top: 8px; }
.nt-move.now { border-color: var(--bad); }
.nt-move.soon { border-color: var(--warn); }
.nt-move q { display: block; margin-top: 4px; font-style: italic; }

.nt-reaction { padding: 6px 0; border-bottom: 1px dashed var(--border); }
.nt-reaction:last-child { border-bottom: 0; }

.nt-facts { display: grid; grid-template-columns: 110px 1fr; gap: 4px 10px; margin: 0; }
.nt-facts dt { color: var(--muted); }
.nt-facts dd { margin: 0; }

.nt-table { width: 100%; border-collapse: collapse; }
.nt-table th { text-align: left; font-weight: 500; font-size: 12px; color: var(--muted); padding: 4px 6px; }
.nt-table td { padding: 4px 6px; border-top: 1px solid var(--border); vertical-align: top; }
.nt-table input[type=text], .nt-table select, .nt-table input[type=date] { width: 100%; }
.nt-table tr.off td { opacity: 0.45; }

.nt-sinks { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 8px; }
.nt-sink { border: 1px solid var(--border); border-radius: 8px; padding: 10px; display: flex; flex-direction: column; gap: 6px; }

.nt-tabs { display: flex; gap: 4px; margin-bottom: 12px; }

.nt-pre { white-space: pre-wrap; font-family: inherit; margin: 0; }
.nt-mail { border: 1px solid var(--border); border-radius: 8px; padding: 12px; display: flex; flex-direction: column; gap: 8px; background: var(--bg); }
.nt-mail-subject { font-weight: 600; }
.nt-grow { flex: 1 1 220px; }

.nt-login { min-height: 100%; display: grid; place-items: center; padding: 16px; }
.nt-login form { width: min(360px, 100%); display: flex; flex-direction: column; gap: 10px; }
.nt-login h1 { margin: 0 0 6px; font-size: 20px; }

.nt-toast { position: fixed; bottom: 16px; left: 50%; transform: translateX(-50%); background: var(--text); color: var(--bg); padding: 8px 14px; border-radius: 8px; z-index: 5; }

@media (max-width: 900px) {
	.nt-meeting { grid-template-columns: 1fr; }
	.nt-side { position: static; max-height: none; }
	.nt-transcript { max-height: 50vh; }
	.nt-item { grid-template-columns: 1fr auto; }
	.nt-item .nt-hide-narrow { display: none; }
}

.nt-knowledge { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 16px; align-items: start; margin-top: 12px; }
.nt-knowledge > .nt-card { margin-top: 0; }
.nt-filters { margin-top: 10px; }
.nt-hit { display: block; padding: 10px 12px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); color: inherit; }
.nt-hit + .nt-hit { margin-top: 6px; }
.nt-hit:hover { border-color: var(--accent); text-decoration: none; }
.nt-snippet { margin-top: 4px; color: var(--muted); }
.nt-snippet mark { background: var(--accent-soft); color: var(--text); border-radius: 3px; padding: 0 1px; }
.nt-answer { margin-top: 10px; }
.nt-answer p { margin: 6px 0 0; }
.nt-cite { font-size: 11px; vertical-align: super; margin-left: 1px; }
.nt-cites { margin: 8px 0 6px; padding-left: 20px; font-size: 12px; }
.nt-cites li + li { margin-top: 4px; }
.nt-cites q { color: var(--muted); }
.nt-line.nt-hit-line { background: var(--accent-soft); border-radius: 6px; }

@media (max-width: 900px) {
	.nt-knowledge { grid-template-columns: 1fr; }
}

.nt-project { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.nt-board { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 8px; }
.nt-board-col { display: flex; flex-direction: column; gap: 6px; padding: 8px; border-radius: 8px; background: var(--surface-2); min-height: 64px; }
.nt-board-head { display: flex; align-items: center; justify-content: space-between; }
.nt-req { display: flex; flex-direction: column; gap: 4px; padding: 8px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); font-size: 13px; }
.nt-req select { font-size: 12px; padding: 2px 6px; }

@media (max-width: 900px) {
	.nt-project { grid-template-columns: 1fr; }
}

.nt-qual { padding: 6px 0; border-bottom: 1px dashed var(--border); }
.nt-qual:last-of-type { border-bottom: 0; }
.nt-qual .nt-small { margin-top: 2px; }
.nt-qual-outcome { margin: 8px 0 0; font-size: 12px; }
.nt-transcript .nt-line { position: relative; }
.nt-pin { position: absolute; top: 3px; right: 0; padding: 0 6px; font-size: 11px; opacity: 0; }
.nt-line:hover .nt-pin, .nt-pin:focus, .nt-pin.on { opacity: 1; }
.nt-pin.on { color: var(--accent); border-color: var(--accent); }
.nt-line.nt-pinned { background: var(--surface-2); border-radius: 6px; }
.nt-pin-note { width: 100%; margin-top: 4px; font-size: 12px; }

.nt-settings { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 12px; align-items: start; margin-bottom: 12px; }
.nt-settings > .nt-card { margin-top: 0; }
.nt-settings .nt-facts { grid-template-columns: 130px 1fr; }
.nt-settings .nt-facts dd { display: flex; flex-wrap: wrap; gap: 4px; }
.nt-flags { margin-top: 10px; }
.nt-totals { margin: 10px 0 14px; }
.nt-stat { font-size: 20px; font-weight: 600; }
.nt-bars { display: flex; align-items: flex-end; gap: 2px; height: 96px; border-bottom: 1px solid var(--border); }
.nt-bar { flex: 1 1 0; min-width: 3px; height: 100%; display: flex; align-items: flex-end; }
.nt-bar i { display: block; width: 100%; background: var(--accent); border-radius: 2px 2px 0 0; }
.nt-bar.zero i { background: var(--border); }
.nt-bar-axis { display: flex; justify-content: space-between; margin: 4px 0 12px; font-size: 11px; color: var(--muted); }
.nt-share { width: 80px; height: 6px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
.nt-share i { display: block; height: 100%; background: var(--accent); }
.nt-subhead { margin: 14px 0 6px; font-size: 12px; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted); }
.nt-failure { padding: 8px 0; border-top: 1px solid var(--border); display: flex; flex-direction: column; gap: 2px; }
.nt-failure:first-child { border-top: 0; }
.nt-failure.off { opacity: 0.55; }
.nt-check { display: grid; grid-template-columns: 76px 1fr; gap: 8px; padding: 6px 0; border-top: 1px solid var(--border); }

.nt-banner { flex-basis: 100%; padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface-2); }
.nt-banner.bad { border-color: var(--bad); }
.nt-danger.on { background: var(--bad); border-color: var(--bad); color: #fff; }
