/* ==========================================================================
   Takween Developer Workspace — portal styles
   Brand: Indigo #4338CA · Violet #7C3AED · Cyan #06B6D4 · Navy #0B1229
   Type:  Plus Jakarta Sans (headings) · Inter (body) · JetBrains Mono (codes)
   ========================================================================== */

/* ---------- 1. Tokens ---------- */
:root {
	--tkw-navy: #0b1229;
	--tkw-navy-2: #121b38;
	--tkw-navy-3: #1a2346;
	--tkw-navy-line: #2b3666;
	--tkw-navy-text: #c7cde0;
	--tkw-navy-muted: #8e97b3;

	--tkw-indigo: #4338ca;
	--tkw-indigo-d: #3730a3;
	--tkw-indigo-l: #eeeefd;
	--tkw-violet: #7c3aed;
	--tkw-cyan: #06b6d4;
	--tkw-cyan-l: #67e8f9;
	--tkw-grad: linear-gradient(135deg, #4338ca, #7c3aed);

	--tkw-bg: #f4f5f9;
	--tkw-card: #ffffff;
	--tkw-subtle: #f8f9fc;
	--tkw-line: #e3e6ef;
	--tkw-line-2: #edeff4;
	--tkw-input-line: #d5d9e5;
	--tkw-ink: #0b1229;
	--tkw-text: #1e293b;
	--tkw-soft: #3f4a5e;
	--tkw-muted: #5b6478;

	--tkw-error: #b42318;
	--tkw-error-bg: #fef3f2;
	--tkw-error-line: #f9cbc6;

	--tkw-r-sm: 8px;
	--tkw-r: 10px;
	--tkw-r-lg: 14px;
	--tkw-shadow: 0 1px 2px rgba(11, 18, 41, 0.04);
	--tkw-shadow-lg: 0 18px 48px rgba(11, 18, 41, 0.18);
	--tkw-focus: 0 0 0 3px rgba(67, 56, 202, 0.28);

	--tkw-font: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
	--tkw-head: "Plus Jakarta Sans", "Inter", system-ui, sans-serif;
	--tkw-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

	--tkw-sidebar: 248px;
}

/* Status / tone palette — background, text, border, accent dot */
.tkw-tone-slate { --t-bg: #eef0f4; --t-fg: #3f4a5e; --t-bd: #dadde5; --t-dot: #8c94a8; }
.tkw-tone-indigo { --t-bg: #ecebfd; --t-fg: #3730a3; --t-bd: #d6d4fa; --t-dot: #4338ca; }
.tkw-tone-cyan { --t-bg: #e0f5f9; --t-fg: #0e6178; --t-bd: #bfe8f1; --t-dot: #0e7490; }
.tkw-tone-violet { --t-bg: #f2eafe; --t-fg: #5b21b6; --t-bd: #e0d0fb; --t-dot: #7c3aed; }
.tkw-tone-amber { --t-bg: #fdf1de; --t-fg: #93450a; --t-bd: #f6dab0; --t-dot: #c2410c; }
.tkw-tone-sky { --t-bg: #e2f0fb; --t-fg: #075985; --t-bd: #c3e0f6; --t-dot: #0369a1; }
.tkw-tone-rose { --t-bg: #fce9f2; --t-fg: #9d174d; --t-bd: #f5cce0; --t-dot: #be185d; }
.tkw-tone-green { --t-bg: #e4f5ea; --t-fg: #166534; --t-bd: #c3e6cf; --t-dot: #15803d; }

/* ---------- 2. Base ---------- */
body.tkw {
	margin: 0;
	background: var(--tkw-bg);
	color: var(--tkw-text);
	font-family: var(--tkw-font);
	font-size: 15px;
	line-height: 1.5;
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}
.tkw *, .tkw *::before, .tkw *::after { box-sizing: border-box; }
.tkw a { color: var(--tkw-indigo); text-decoration: none; }
.tkw a:hover { color: var(--tkw-indigo-d); text-decoration: underline; }
.tkw img { max-width: 100%; height: auto; display: block; }
.tkw p { margin: 0; }
.tkw ul, .tkw ol { margin: 0; padding: 0; list-style: none; }
.tkw dl, .tkw dd { margin: 0; }
.tkw button { font: inherit; }
.tkw :focus-visible { outline: none; box-shadow: var(--tkw-focus); border-radius: 6px; }
.tkw [hidden] { display: none !important; }
.tkw-icon { flex: none; display: inline-block; vertical-align: middle; }

.tkw .screen-reader-text {
	position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
	overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.tkw-skip {
	position: absolute; left: 12px; top: -48px; z-index: 100; padding: 10px 14px;
	background: var(--tkw-ink); color: #fff !important; border-radius: var(--tkw-r-sm); transition: top 0.15s;
}
.tkw-skip:focus { top: 12px; }

/* Type */
.tkw-h1 {
	margin: 0; font-family: var(--tkw-head); font-weight: 800; font-size: 30px;
	letter-spacing: -0.02em; line-height: 1.2; color: var(--tkw-ink);
}
.tkw-h1--project { font-size: 26px; line-height: 1.25; overflow-wrap: anywhere; }
.tkw-h2 { margin: 0; font-family: var(--tkw-head); font-weight: 700; font-size: 18px; color: var(--tkw-ink); line-height: 1.3; }
.tkw-h3 { margin: 0; font-family: var(--tkw-head); font-weight: 700; font-size: 15.5px; color: var(--tkw-ink); line-height: 1.35; }
.tkw-h4 {
	display: flex; align-items: center; gap: 8px; margin: 18px 0 10px;
	font-size: 12px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--tkw-muted);
}
.tkw-muted { color: var(--tkw-muted); }
.tkw-small { font-size: 13px; line-height: 1.5; }
.tkw-mono { font-family: var(--tkw-mono); font-size: 12px; font-weight: 600; color: var(--tkw-muted); }
.tkw-nowrap { white-space: nowrap; }
.tkw-mt { margin-top: 24px; }
.tkw-ok { display: inline-flex; align-items: center; gap: 6px; color: #166534; font-weight: 600; }
.tkw-optional { font-family: var(--tkw-font); font-size: 12px; font-weight: 500; color: var(--tkw-muted); margin-left: 4px; }
.tkw-label { display: block; font-size: 12px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--tkw-muted); }
.tkw-clamp { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tkw-prose { font-size: 14.5px; line-height: 1.6; color: var(--tkw-text); overflow-wrap: anywhere; }
.tkw-prose p + p { margin-top: 8px; }
.tkw-stack { display: flex; flex-direction: column; gap: 10px; }
.tkw-stack-lg { display: flex; flex-direction: column; gap: 18px; }
.tkw-btnrow { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: flex-end; }

/* ---------- 3. App shell ---------- */
.tkw-app {
	display: grid;
	grid-template-columns: var(--tkw-sidebar) minmax(0, 1fr);
	min-height: 100vh;
	background: linear-gradient(90deg, var(--tkw-navy) var(--tkw-sidebar), var(--tkw-bg) var(--tkw-sidebar));
}
.tkw-sidebar {
	position: sticky; top: 0; height: 100vh; overflow-y: auto;
	display: flex; flex-direction: column; gap: 28px;
	padding: 24px 16px; background: var(--tkw-navy); color: var(--tkw-navy-text);
}
.tkw-sidebar__head { display: flex; align-items: center; justify-content: space-between; }
.tkw-sidebar .tkw-sidebar__close { display: none; }
.tkw-logo {
	width: 36px; height: 36px; border-radius: 9px; flex: none;
	display: inline-flex; align-items: center; justify-content: center;
	background: var(--tkw-indigo); color: #fff; font-family: var(--tkw-head); font-weight: 800; font-size: 18px;
}
.tkw-brand { display: flex; align-items: center; gap: 12px; padding: 0 8px; color: #fff !important; text-decoration: none !important; }
.tkw-brand__text { display: flex; flex-direction: column; gap: 2px; }
.tkw-brand__text strong { font-family: var(--tkw-head); font-weight: 700; font-size: 15px; color: #fff; }
.tkw-brand__text span { font-size: 12px; color: var(--tkw-navy-muted); letter-spacing: 0.04em; }
.tkw-brand--lg .tkw-logo { width: 40px; height: 40px; font-size: 20px; }
.tkw-brand--lg strong { font-size: 17px; }

.tkw-nav { display: flex; flex-direction: column; gap: 4px; }
.tkw-nav__label { padding: 0 12px 6px; font-size: 11px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: #6e7898; }
.tkw-nav__link {
	display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 10px 12px;
	border-radius: var(--tkw-r-sm); color: var(--tkw-navy-text) !important; font-size: 14px; font-weight: 500;
	text-decoration: none !important; transition: background 0.15s, color 0.15s;
}
.tkw-nav__link:hover { background: var(--tkw-navy-2); color: #fff !important; }
.tkw-nav__link.is-active { background: var(--tkw-navy-3); color: #fff !important; font-weight: 600; box-shadow: inset 3px 0 0 var(--tkw-cyan); }
.tkw-nav__count { margin-left: auto; font-size: 12px; background: var(--tkw-navy-line); color: #dde2f5; padding: 2px 8px; border-radius: 999px; }

.tkw-me {
	margin-top: auto; display: flex; align-items: center; gap: 12px; padding: 12px;
	border-radius: var(--tkw-r); background: var(--tkw-navy-2);
}
.tkw-me__text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.tkw-me__text strong { font-size: 13px; font-weight: 600; color: #fff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tkw-me__text span { font-size: 12px; color: var(--tkw-navy-muted); }
.tkw-me__out { margin-left: auto; color: var(--tkw-navy-muted) !important; }
.tkw-me__out:hover { color: #fff !important; background: var(--tkw-navy-3); }

.tkw-iconbtn {
	width: 44px; height: 44px; flex: none; border: 0; border-radius: var(--tkw-r-sm);
	display: inline-flex; align-items: center; justify-content: center;
	background: transparent; color: inherit; cursor: pointer;
}
.tkw-avatar {
	width: var(--s, 36px); height: var(--s, 36px); flex: none; border-radius: 999px;
	display: inline-flex; align-items: center; justify-content: center;
	color: #fff; font-weight: 600; font-size: calc(var(--s, 36px) * 0.36); letter-spacing: 0.02em;
}
.tkw-avatar--violet { background: #7c3aed; }
.tkw-avatar--cyan { background: #0e7490; }
.tkw-avatar--indigo { background: #4338ca; }
.tkw-avatar--rose { background: #be185d; }
.tkw-avatar--green { background: #15803d; }
.tkw-avatar--amber { background: #b45309; }

.tkw-topbar { display: none; }
.tkw-scrim { position: fixed; inset: 0; background: rgba(11, 18, 41, 0.5); z-index: 55; }

.tkw-main {
	min-width: 0; padding: 30px 40px 64px; outline: none;
	display: flex; flex-direction: column; gap: 22px;
	max-width: 1480px; width: 100%;
}

/* ---------- 4. Page head, crumbs ---------- */
.tkw-pagehead { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; }
.tkw-pagehead__text { display: flex; flex-direction: column; gap: 6px; max-width: 760px; }
.tkw-pagehead__eyebrow { font-size: 13px; color: var(--tkw-muted); font-weight: 500; }
.tkw-crumbs { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--tkw-muted); margin-bottom: -8px; }
.tkw-crumbs a { color: var(--tkw-muted) !important; }
.tkw-crumbs span:last-child { color: var(--tkw-text); font-weight: 500; }

/* ---------- 5. Cards ---------- */
.tkw-card {
	background: var(--tkw-card); border: 1px solid var(--tkw-line); border-radius: var(--tkw-r-lg);
	padding: 20px 22px; box-shadow: var(--tkw-shadow); min-width: 0;
}
.tkw-card--flush { padding: 0; }
.tkw-card__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; }
.tkw-card__head > div { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.tkw-card__head--stack { flex-direction: column; align-items: flex-start; gap: 4px; margin-bottom: 14px; }
.tkw-card__head--line { padding-bottom: 16px; margin-bottom: 18px; border-bottom: 1px solid var(--tkw-line-2); }
.tkw-card > .tkw-card__head--line:last-child { padding-bottom: 0; margin-bottom: 0; border-bottom: 0; }
.tkw-card--flush .tkw-card__head--line, .tkw-card__pad { padding: 20px 22px 16px; margin: 0; }
.tkw-card--flush > .tkw-card__body { padding: 20px 22px; }
.tkw-pill { font-size: 12px; color: var(--tkw-muted); background: var(--tkw-bg); padding: 6px 10px; border-radius: var(--tkw-r-sm); white-space: nowrap; }

/* Split: main + aside */
.tkw-split { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 22px; align-items: start; }
.tkw-split__side { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.tkw-split__side.tkw-card { display: block; }

/* ---------- 6. Buttons ---------- */
.tkw-btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	min-height: 44px; padding: 0 18px; border-radius: var(--tkw-r);
	border: 1px solid transparent; background: var(--tkw-card); color: var(--tkw-text) !important;
	font-size: 14px; font-weight: 600; line-height: 1.2; text-decoration: none !important;
	cursor: pointer; white-space: nowrap; transition: background 0.15s, border-color 0.15s, box-shadow 0.15s, transform 0.05s;
}
.tkw-btn:active { transform: translateY(1px); }
.tkw-btn--primary { background: var(--tkw-grad); color: #fff !important; box-shadow: 0 1px 2px rgba(55, 48, 163, 0.25); }
.tkw-btn--primary:hover { background: linear-gradient(135deg, #3730a3, #6d28d9); }
.tkw-btn--ghost { border-color: var(--tkw-input-line); background: var(--tkw-card); }
.tkw-btn--ghost:hover { border-color: #b9bfd0; background: var(--tkw-subtle); }
.tkw-btn--soft { background: var(--tkw-indigo-l); color: var(--tkw-indigo-d) !important; }
.tkw-btn--soft:hover { background: #e2e1fb; }
.tkw-btn--text { background: transparent; color: var(--tkw-indigo) !important; padding: 0 10px; }
.tkw-btn--cyan { background: var(--tkw-cyan); color: var(--tkw-ink) !important; font-weight: 700; }
.tkw-btn--cyan:hover { background: #22c3df; }
.tkw-btn--success { background: #15803d; color: #fff !important; }
.tkw-btn--success:hover { background: #166534; }
.tkw-btn--onnavy { background: transparent; border-color: var(--tkw-navy-line); color: #fff !important; }
.tkw-btn--sm { min-height: 38px; padding: 0 13px; font-size: 13px; border-radius: var(--tkw-r-sm); }
.tkw-btn--lg { min-height: 50px; font-size: 15px; }
.tkw-btn--block { width: 100%; }
.tkw-btn[disabled], .tkw-btn.is-loading { opacity: 0.75; cursor: progress; pointer-events: none; }
.tkw-btn.is-loading::before {
	content: ""; width: 15px; height: 15px; border-radius: 999px; flex: none;
	border: 2px solid currentColor; border-right-color: transparent; animation: tkw-spin 0.7s linear infinite;
}
.tkw-btn.is-loading .tkw-icon { display: none; }
@keyframes tkw-spin { to { transform: rotate(360deg); } }

/* ---------- 7. Chips, badges, codes ---------- */
.tkw-code {
	display: inline-flex; align-items: center; font-family: var(--tkw-mono); font-size: 12px; font-weight: 600;
	padding: 3px 8px; border-radius: 6px; color: var(--tkw-indigo-d); background: var(--tkw-indigo-l); white-space: nowrap;
}
.tkw-code--bf { color: #0e6178; background: #e0f5f9; }
.tkw-chip {
	display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 500; color: var(--tkw-muted);
	border: 1px solid var(--tkw-input-line); padding: 2px 9px; border-radius: 999px; white-space: nowrap;
}
.tkw-chip--fb { color: var(--tkw-indigo-d); border-color: #d6d4fa; }
.tkw-chip--bf { color: #0e6178; border-color: #bfe8f1; }
.tkw-chip--sample { border-style: dashed; color: var(--tkw-muted); }
.tkw-chip.is-off { color: var(--tkw-muted); border-color: var(--tkw-line); background: repeating-linear-gradient(135deg, #f4f5f9 0 4px, #fff 4px 8px); }
.tkw-row__chips { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; }

.tkw-badge {
	display: inline-flex; align-items: center; gap: 7px; max-width: 100%;
	padding: 5px 11px 5px 9px; border-radius: 999px; font-size: 13px; font-weight: 600; line-height: 1.25;
	background: var(--t-bg); color: var(--t-fg); border: 1px solid var(--t-bd);
}
.tkw-badge--sm { font-size: 12px; padding: 4px 9px 4px 7px; gap: 6px; }
.tkw-tag {
	display: inline-flex; align-items: center; font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
	padding: 3px 8px; border-radius: 6px; color: var(--tkw-muted); background: var(--tkw-bg);
}
.tkw-tag--cyan { color: #0e6178; background: #e0f5f9; }
.tkw-flag { display: inline-flex; align-items: center; gap: 5px; margin-top: 6px; font-size: 12px; font-weight: 600; color: #93450a; }

/* Mini stage bar */
.tkw-stepbar { display: flex; gap: 4px; width: 100%; max-width: 220px; }
.tkw-stepbar__seg { flex: 1; height: 6px; border-radius: 3px; background: var(--tkw-line); display: inline-block; }
.tkw-stepbar__seg.is-done { background: var(--tkw-indigo); }
.tkw-stepbar__seg.is-current { background: var(--tkw-cyan); }
.tkw-stepbar__seg.is-skip { background: repeating-linear-gradient(135deg, #c9cedc 0 2px, #fff 2px 4px); box-shadow: inset 0 0 0 1px #c9cedc; }
.tkw-legend { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 18px; padding: 14px 20px; font-size: 12px; color: var(--tkw-muted); border-top: 1px solid var(--tkw-line-2); }
.tkw-legend strong { color: var(--tkw-soft); font-weight: 600; }
.tkw-legend span { display: inline-flex; align-items: center; gap: 6px; }
.tkw-legend .tkw-stepbar__seg { flex: none; width: 18px; }

/* ---------- 8. Alerts & empty states ---------- */
.tkw-alert {
	display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 12px;
	border: 1px solid; font-size: 14px; line-height: 1.5;
}
.tkw-alert .tkw-icon { margin-top: 1px; }
.tkw-alert--success { background: #ecf8f0; border-color: #c3e6cf; color: #14532d; }
.tkw-alert--error { background: var(--tkw-error-bg); border-color: var(--tkw-error-line); color: #912018; }
.tkw-alert--info { background: #eef9fb; border-color: #bfe8f1; color: #0b3b48; }
.tkw-alert--quiet { font-size: 13.5px; }
.tkw-alert strong { font-weight: 600; }

.tkw-empty {
	display: flex; flex-wrap: wrap; align-items: center; gap: 14px 16px; padding: 20px;
	border: 1.5px dashed #c9cedc; border-radius: 12px; background: #fbfbfd;
}
.tkw-empty__icon {
	width: 44px; height: 44px; flex: none; border-radius: 11px;
	display: inline-flex; align-items: center; justify-content: center; background: var(--tkw-indigo-l); color: var(--tkw-indigo);
}
.tkw-empty__body { flex: 1 1 240px; display: flex; flex-direction: column; gap: 4px; }
.tkw-empty__title { font-weight: 600; color: var(--tkw-ink); font-size: 14.5px; }
.tkw-empty__text { font-size: 13.5px; color: var(--tkw-muted); line-height: 1.5; }
.tkw-empty--lg { flex-direction: column; text-align: center; padding: 44px 24px; border-style: solid; border-color: transparent; background: transparent; }
.tkw-empty--lg .tkw-empty__icon { width: 56px; height: 56px; border-radius: 14px; }
.tkw-empty--lg .tkw-empty__body { flex: none; max-width: 520px; align-items: center; }
.tkw-empty--lg .tkw-empty__title { font-family: var(--tkw-head); font-size: 18px; font-weight: 700; }
.tkw-empty--compact { padding: 14px; border-style: solid; border-color: var(--tkw-line-2); }
.tkw-card > .tkw-empty--lg { padding: 36px 16px; }

/* ---------- 9. Dashboard: tiles, filters, rows ---------- */
.tkw-tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.tkw-tile {
	text-align: left; display: flex; flex-direction: column; gap: 10px; padding: 18px 20px; min-height: 44px;
	background: var(--tkw-card); border: 1px solid var(--tkw-line); border-radius: 12px; color: var(--tkw-text);
	cursor: pointer; transition: border-color 0.15s, box-shadow 0.15s;
}
.tkw-tile:hover { border-color: #c9cedc; }
.tkw-tile.is-alert { box-shadow: 0 0 0 2px #f6dab0; }
.tkw-tile[aria-pressed="true"] { border-color: var(--tkw-indigo); box-shadow: 0 0 0 2px var(--tkw-indigo); }
.tkw-tile__head { display: flex; align-items: center; gap: 10px; }
.tkw-tile__icon {
	width: 30px; height: 30px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center;
	background: var(--t-bg); color: var(--t-fg);
}
.tkw-tile__label { font-size: 13px; font-weight: 600; color: var(--tkw-soft); }
.tkw-tile__value { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.tkw-tile__value strong { font-family: var(--tkw-head); font-weight: 800; font-size: 30px; color: var(--tkw-ink); line-height: 1; }
.tkw-tile__value span { font-size: 12px; color: var(--tkw-muted); }

.tkw-filters { display: flex; flex-wrap: wrap; gap: 10px 12px; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--tkw-line); }
.tkw-search {
	flex: 1 1 240px; display: flex; align-items: center; gap: 10px; height: 44px; padding: 0 14px;
	border: 1px solid var(--tkw-input-line); border-radius: 9px; background: var(--tkw-subtle); color: var(--tkw-muted);
}
.tkw-search:focus-within { border-color: var(--tkw-indigo); box-shadow: var(--tkw-focus); background: #fff; }
.tkw-search input { flex: 1; min-width: 0; border: 0; background: transparent; outline: none; font: inherit; font-size: 14px; color: var(--tkw-text); }
.tkw-search input:focus-visible { box-shadow: none; }
.tkw-seg { display: inline-flex; padding: 3px; gap: 2px; background: #eef0f5; border-radius: 9px; }
.tkw-seg__btn {
	min-height: 38px; padding: 0 14px; border: 0; border-radius: 7px; background: transparent;
	font-size: 13px; font-weight: 500; color: var(--tkw-soft); cursor: pointer;
}
.tkw-seg__btn[aria-pressed="true"] { background: #fff; color: var(--tkw-ink); font-weight: 600; box-shadow: 0 1px 2px rgba(11, 18, 41, 0.1); }
.tkw-inline-field { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--tkw-muted); }

.tkw-rows-head {
	display: flex; gap: 24px; padding: 10px 20px; background: var(--tkw-subtle); border-bottom: 1px solid var(--tkw-line);
	font-size: 11px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--tkw-muted);
}
.tkw-rows-head .c-project, .tkw-row__project { flex: 3 1 250px; }
.tkw-rows-head .c-stage, .tkw-row__stage { flex: 2 1 180px; }
.tkw-rows-head .c-status, .tkw-row__status { flex: 2 1 190px; }
.tkw-rows-head .c-update, .tkw-row__update { flex: 3 1 210px; }
.tkw-rows-head .c-open, .tkw-row__open { flex: 0 0 92px; }
.tkw-row {
	display: flex; flex-wrap: wrap; gap: 14px 24px; align-items: center; padding: 18px 20px;
	border-bottom: 1px solid var(--tkw-line-2); transition: background 0.15s;
}
.tkw-row:hover { background: #fbfbfe; }
.tkw-row.is-closed { opacity: 0.8; }
.tkw-row__project { min-width: 0; display: flex; flex-direction: column; gap: 7px; }
.tkw-row__name { font-family: var(--tkw-head); font-weight: 700; font-size: 15px; color: var(--tkw-ink) !important; line-height: 1.35; overflow-wrap: anywhere; }
.tkw-row__stage { display: flex; flex-direction: column; gap: 8px; font-size: 13px; font-weight: 500; color: var(--tkw-soft); }
.tkw-row__status { display: flex; flex-direction: column; align-items: flex-start; }
.tkw-row__update { min-width: 0; display: flex; flex-direction: column; gap: 4px; font-size: 14px; }

/* Manager pipeline */
.tkw-pipeline .tkw-card__head { margin-bottom: 14px; }
.tkw-pipeline__grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; }
.tkw-pipe {
	text-align: left; display: flex; flex-direction: column; gap: 8px; padding: 14px; min-height: 44px;
	border: 1px solid var(--t-bd); background: color-mix(in srgb, var(--t-bg) 55%, #fff); border-radius: var(--tkw-r);
	color: var(--t-fg); cursor: pointer; transition: box-shadow 0.15s;
}
.tkw-pipe[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--t-dot); }
.tkw-pipe__label { display: flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 600; }
.tkw-pipe__count { font-family: var(--tkw-head); font-weight: 800; font-size: 26px; color: var(--tkw-ink); line-height: 1; }

/* Table */
.tkw-tablewrap { overflow-x: auto; }
.tkw-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.tkw-table th {
	text-align: left; padding: 11px 12px; background: var(--tkw-subtle); border-bottom: 1px solid var(--tkw-line);
	font-size: 11px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--tkw-muted); white-space: nowrap;
}
.tkw-table th:first-child, .tkw-table td:first-child { padding-left: 20px; }
.tkw-table th:last-child, .tkw-table td:last-child { padding-right: 20px; }
.tkw-table .tkw-badge { white-space: nowrap; }
.tkw-table td { padding: 14px 12px; vertical-align: top; border-bottom: 1px solid var(--tkw-line-2); color: var(--tkw-soft); }
.tkw-table td:first-child { max-width: 340px; }
.tkw-table tr.is-closed td { opacity: 0.8; }
.tkw-table tbody tr:hover td { background: #fbfbfe; }
.tkw-table__name { display: block; margin-top: 6px; font-weight: 600; color: var(--tkw-ink) !important; line-height: 1.35; overflow-wrap: anywhere; }
.tkw-person { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; color: var(--tkw-text); }

.tkw-waiting { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.tkw-waiting__item { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; padding: 14px; border: 1px solid var(--tkw-line); border-radius: var(--tkw-r); }
.tkw-waiting__head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.tkw-waiting__head strong { font-size: 13.5px; color: var(--tkw-ink); }

/* ---------- 10. Forms ---------- */
.tkw-form { display: flex; flex-direction: column; gap: 16px; }
.tkw-form--wide { max-width: 980px; padding: 24px; }
.tkw-form__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 18px; }
.tkw-form__grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.tkw-split__side .tkw-form__grid--2 { grid-template-columns: 1fr 1fr; gap: 12px; }
.tkw-form__section { display: flex; flex-direction: column; gap: 14px; padding-top: 18px; border-top: 1px solid var(--tkw-line-2); margin: 0; min-width: 0; }
.tkw-form__section > .tkw-h3 { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px; }
.tkw-form__actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 10px 14px; padding-top: 6px; }
.tkw-form__actions > .tkw-small { margin-right: auto; }
.tkw-form__actions--sticky {
	position: sticky; bottom: 0; z-index: 5; margin: 0 -22px -20px; padding: 14px 22px;
	background: rgba(255, 255, 255, 0.96); border-top: 1px solid var(--tkw-line); border-radius: 0 0 var(--tkw-r-lg) var(--tkw-r-lg);
}

.tkw-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; border: 0; padding: 0; margin: 0; }
.tkw-field__label { font-size: 13px; font-weight: 600; color: var(--tkw-text); padding: 0; }
.tkw-field__help { font-size: 12px; color: var(--tkw-muted); margin-top: -2px; }
.tkw-field__error { display: flex; align-items: flex-start; gap: 6px; color: var(--tkw-error); font-size: 12.5px; font-weight: 500; line-height: 1.4; }
.tkw-field__error .tkw-icon { margin-top: 2px; }

.tkw-input, .tkw-select {
	width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid var(--tkw-input-line); border-radius: 9px;
	background: #fff; font: inherit; font-size: 14px; color: var(--tkw-text); transition: border-color 0.15s, box-shadow 0.15s;
}
.tkw-select {
	appearance: none; padding-right: 36px; cursor: pointer;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%235B6478' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
	background-repeat: no-repeat; background-position: right 12px center;
}
.tkw-inline-field .tkw-select { width: auto; min-width: 150px; }
textarea.tkw-input { resize: vertical; line-height: 1.5; min-height: 64px; }
.tkw-input--short { max-width: 140px; }
.tkw-input:focus, .tkw-select:focus { border-color: var(--tkw-indigo); box-shadow: var(--tkw-focus); outline: none; }
.tkw-input[aria-invalid="true"], .tkw-select[aria-invalid="true"] { border: 1.5px solid #d92d20; background: #fffbfa; }
.tkw-input::placeholder { color: #8b93a7; }
.tkw-input-group { display: flex; align-items: center; border: 1px solid var(--tkw-input-line); border-radius: 9px; background: #fff; padding-right: 2px; }
.tkw-input-group:focus-within { border-color: var(--tkw-indigo); box-shadow: var(--tkw-focus); }
.tkw-input-group .tkw-input { border: 0; box-shadow: none !important; background: transparent; }
.tkw-input-group.is-invalid { border: 1.5px solid #d92d20; background: #fffbfa; }
.tkw-input-group .tkw-iconbtn { color: var(--tkw-muted); width: 40px; height: 40px; }
.tkw-count { align-self: flex-end; font-size: 11.5px; color: var(--tkw-muted); margin-top: -2px; }
.tkw-count.is-near { color: #93450a; }

.tkw-check { display: inline-flex; align-items: flex-start; gap: 10px; min-height: 32px; font-size: 14px; color: var(--tkw-text); cursor: pointer; }
.tkw-check input { width: 18px; height: 18px; margin: 1px 0 0; flex: none; accent-color: var(--tkw-indigo); }
.tkw-check--row { padding: 9px 12px; border: 1px solid var(--tkw-line-2); border-radius: var(--tkw-r-sm); background: var(--tkw-subtle); width: 100%; }
.tkw-check--row:has(input:checked) { background: #f3f3fe; border-color: #d6d4fa; }
.tkw-check--sm { font-size: 12.5px; min-height: 28px; gap: 6px; }
.tkw-check--sm input { width: 16px; height: 16px; }
.tkw-checklist { gap: 8px; }
.tkw-checklist.is-invalid .tkw-check--row:not(:has(input:checked)) { border-color: var(--tkw-error-line); background: #fffbfa; }

/* Choice cards (project type) */
.tkw-choice-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.tkw-choice { position: relative; cursor: pointer; display: block; }
.tkw-choice input { position: absolute; opacity: 0; pointer-events: none; }
.tkw-choice__box {
	display: flex; flex-direction: column; gap: 8px; height: 100%; padding: 16px; border: 1.5px solid var(--tkw-line);
	border-radius: 12px; background: #fff; transition: border-color 0.15s, box-shadow 0.15s;
}
.tkw-choice:hover .tkw-choice__box { border-color: #b9bfd0; }
.tkw-choice input:checked + .tkw-choice__box { border-color: var(--tkw-indigo); box-shadow: 0 0 0 3px rgba(67, 56, 202, 0.15); background: #fafaff; }
.tkw-choice input:focus-visible + .tkw-choice__box { box-shadow: var(--tkw-focus); }
.tkw-choice__top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.tkw-choice__top strong { font-family: var(--tkw-head); font-size: 15px; color: var(--tkw-ink); }
.tkw-choice__steps { display: flex; gap: 6px; margin-top: 2px; }
.tkw-choice__steps span {
	width: 26px; height: 26px; border-radius: 999px; display: inline-flex; align-items: center; justify-content: center;
	font-size: 12px; font-weight: 700; background: var(--tkw-indigo-l); color: var(--tkw-indigo-d);
}
.tkw-choice__steps span.is-skip { background: repeating-linear-gradient(135deg, #eef0f4 0 3px, #fff 3px 6px); color: #8b93a7; text-decoration: line-through; box-shadow: inset 0 0 0 1px #d5d9e5; }
[aria-invalid="true"].tkw-choice-grid .tkw-choice__box { border-color: #f1a9a1; }
.tkw-preview { display: flex; flex-direction: column; gap: 4px; padding: 14px 16px; border-radius: var(--tkw-r); background: var(--tkw-subtle); border: 1px solid var(--tkw-line-2); }
.tkw-preview strong { font-family: var(--tkw-head); font-size: 16px; color: var(--tkw-ink); overflow-wrap: anywhere; }

/* Drop zone */
.tkw-drop { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.tkw-drop__zone {
	position: relative; display: flex; align-items: center; gap: 14px; padding: 16px; min-height: 76px;
	border: 1.5px dashed #c9cedc; border-radius: 12px; background: #fbfbfd; transition: border-color 0.15s, background 0.15s;
}
.tkw-drop__zone:hover, .tkw-drop.is-drag .tkw-drop__zone { border-color: var(--tkw-indigo); background: #f6f6ff; }
.tkw-drop__zone:focus-within { border-color: var(--tkw-indigo); box-shadow: var(--tkw-focus); }
.tkw-drop.is-invalid .tkw-drop__zone { border-color: #e9837a; background: #fffbfa; }
.tkw-drop__icon {
	width: 40px; height: 40px; flex: none; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center;
	background: var(--tkw-indigo-l); color: var(--tkw-indigo);
}
.tkw-drop__text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.tkw-drop__text strong { font-size: 14px; font-weight: 600; color: var(--tkw-ink); }
.tkw-drop__text span { font-size: 12px; color: var(--tkw-muted); }
.tkw-drop__input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.tkw-drop__list { display: flex; flex-direction: column; gap: 4px; }
.tkw-drop__list li { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--tkw-soft); padding: 6px 10px; border-radius: 7px; background: var(--tkw-subtle); overflow-wrap: anywhere; }
.tkw-drop__list li span { margin-left: auto; color: var(--tkw-muted); white-space: nowrap; }

/* Collapsible form panel */
.tkw-formpanel { border: 1px solid var(--tkw-line); border-radius: 12px; background: var(--tkw-subtle); margin-bottom: 4px; }
.tkw-formpanel[open] { background: #fff; }
.tkw-formpanel__toggle {
	display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 12px 16px; cursor: pointer;
	font-weight: 600; font-size: 14.5px; color: var(--tkw-ink); list-style: none; border-radius: 12px;
}
.tkw-formpanel__toggle::-webkit-details-marker { display: none; }
.tkw-formpanel__toggle .tkw-icon:first-child { color: var(--tkw-indigo); }
.tkw-formpanel__chev { margin-left: auto; color: var(--tkw-muted); transition: transform 0.2s; }
.tkw-formpanel[open] .tkw-formpanel__chev { transform: rotate(180deg); }
.tkw-formpanel__body { padding: 4px 16px 18px; }

/* ---------- 11. Project header + stepper ---------- */
.tkw-projhead { display: flex; flex-direction: column; gap: 18px; padding: 24px; }
.tkw-projhead__top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; align-items: flex-start; }
.tkw-projhead__title { display: flex; flex-direction: column; gap: 10px; flex: 1 1 360px; min-width: 0; }
.tkw-projhead__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.tkw-meta { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px 18px; padding-top: 18px; border-top: 1px solid var(--tkw-line-2); }
.tkw-meta > div { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.tkw-meta dt { font-size: 12px; color: var(--tkw-muted); }
.tkw-meta dd { font-size: 14px; font-weight: 600; color: var(--tkw-text); }

.tkw-settings { border-top: 1px solid var(--tkw-line-2); padding-top: 12px; }
.tkw-settings summary {
	display: inline-flex; align-items: center; gap: 8px; min-height: 36px; cursor: pointer; list-style: none;
	font-size: 13px; font-weight: 600; color: var(--tkw-soft);
}
.tkw-settings summary::-webkit-details-marker { display: none; }
.tkw-settings__chev { transition: transform 0.2s; }
.tkw-settings[open] .tkw-settings__chev { transform: rotate(180deg); }
.tkw-settings__form { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 14px 18px; margin-top: 12px; }
.tkw-settings__save { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; }

.tkw-stepper ol { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
.tkw-step {
	display: flex; gap: 12px; align-items: flex-start; height: 100%; padding: 14px 15px; min-height: 44px;
	border-radius: 12px; border: 1px solid var(--tkw-line); background: #fff; color: inherit !important; text-decoration: none !important;
	transition: border-color 0.15s, box-shadow 0.15s;
}
.tkw-step:hover { border-color: #b9bfd0; }
.tkw-step__dot {
	flex: 0 0 30px; height: 30px; border-radius: 999px; display: inline-flex; align-items: center; justify-content: center;
	font-size: 13px; font-weight: 700; background: #fff; color: var(--tkw-muted); border: 1.5px solid #c9cedc;
}
.tkw-step__dot span { font-size: 10px; letter-spacing: 0.02em; }
.tkw-step__text { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.tkw-step__num { font-size: 12px; font-weight: 600; color: var(--tkw-muted); }
.tkw-step__num em { font-style: normal; color: var(--tkw-indigo); }
.tkw-step__name { font-family: var(--tkw-head); font-size: 14px; font-weight: 700; color: var(--tkw-ink); line-height: 1.3; }
.tkw-step__short { display: none; }
.tkw-step__sub { font-size: 12px; font-weight: 500; color: var(--tkw-muted); line-height: 1.35; }
.tkw-step.is-done .tkw-step__dot { background: var(--tkw-indigo); border-color: var(--tkw-indigo); color: #fff; }
.tkw-step.is-done .tkw-step__sub { color: #166534; }
.tkw-step.is-current { background: #f7fdfe; border-color: #a5e3ef; }
.tkw-step.is-current .tkw-step__dot { background: #e0f5f9; border: 2px solid var(--tkw-cyan); color: #0e6178; }
.tkw-step.is-current .tkw-step__sub { color: #0e6178; }
.tkw-step.is-locked { background: var(--tkw-subtle); }
.tkw-step.is-locked .tkw-step__dot { border-style: dashed; border-color: #a7aec1; }
.tkw-step.is-todo .tkw-step__dot { border-style: solid; }
.tkw-step.is-skip { background: repeating-linear-gradient(135deg, #f4f5f9 0 6px, #fff 6px 12px); border: 1px dashed #c9cedc; }
.tkw-step.is-skip .tkw-step__dot { border-style: dashed; border-color: #a7aec1; }
.tkw-step.is-skip .tkw-step__name { color: var(--tkw-muted); text-decoration: line-through; }
.tkw-step.is-selected { box-shadow: 0 0 0 2px var(--tkw-indigo); border-color: var(--tkw-indigo); }
.tkw-stepper__current { display: none; }

/* ---------- 12. "Right now" card ---------- */
.tkw-now { display: flex; flex-direction: column; gap: 12px; padding: 20px; border-radius: var(--tkw-r-lg); background: var(--tkw-navy); color: #dde2f5; }
.tkw-now__eyebrow { font-size: 11px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--tkw-cyan-l); }
.tkw-now__title { font-family: var(--tkw-head); font-size: 17px; font-weight: 700; color: #fff; line-height: 1.4; }
.tkw-now__text { font-size: 13px; line-height: 1.55; color: #b9c1da; }
.tkw-now__facts { display: flex; flex-direction: column; gap: 8px; font-size: 13px; padding: 12px 0 4px; border-top: 1px solid var(--tkw-navy-3); }
.tkw-now__facts > div { display: flex; gap: 10px; }
.tkw-now__facts dt { flex: 0 0 78px; color: var(--tkw-navy-muted); }
.tkw-now__facts dd { color: #fff; min-width: 0; overflow-wrap: anywhere; }
.tkw-now__facts dd.is-blocker { color: #fcd9a8; font-weight: 600; }

/* ---------- 13. Step content ---------- */
/* Brief versions */
.tkw-brief { display: flex; flex-direction: column; gap: 10px; padding: 16px; border-radius: 12px; border: 1px solid var(--tkw-line); }
.tkw-brief.is-current { border-color: #c3e6cf; background: #fbfefc; }
.tkw-brief.is-old { background: var(--tkw-subtle); }
.tkw-brief__head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.tkw-brief__note { font-size: 13.5px; color: var(--tkw-soft); }
.tkw-version { font-family: var(--tkw-head); font-weight: 800; font-size: 15px; color: var(--tkw-ink); background: var(--tkw-indigo-l); border-radius: 7px; padding: 2px 8px; }
.tkw-version.is-old { background: #eef0f4; color: var(--tkw-muted); }

/* File card */
.tkw-file { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 14px; padding: 12px 14px; border: 1px solid var(--tkw-line); border-radius: var(--tkw-r); background: #fff; }
.tkw-file__ext {
	width: 40px; height: 40px; flex: none; border-radius: 9px; display: inline-flex; align-items: center; justify-content: center;
	font-family: var(--tkw-mono); font-size: 10.5px; font-weight: 700; background: #eef0f4; color: var(--tkw-soft);
}
.tkw-file__ext--pdf { background: #fdecec; color: #b42318; }
.tkw-file__ext--doc { background: #e7efff; color: #1d4ed8; }
.tkw-file__ext--xls { background: #e4f5ea; color: #166534; }
.tkw-file__body { display: flex; flex-direction: column; gap: 2px; flex: 1 1 180px; min-width: 0; }
.tkw-file__name { font-size: 14px; font-weight: 600; color: var(--tkw-ink) !important; overflow-wrap: anywhere; }
.tkw-file__meta { font-size: 12px; color: var(--tkw-muted); }

/* Tracker timeline */
.tkw-timeline { padding: 0 2px; }
.tkw-entry { display: flex; gap: 16px; }
.tkw-entry__rail { flex: 0 0 18px; display: flex; flex-direction: column; align-items: center; padding-top: 22px; position: relative; }
.tkw-entry__rail::after { content: ""; flex: 1; width: 2px; margin-top: 8px; background: var(--tkw-line); }
.tkw-entry:last-child .tkw-entry__rail::after { background: linear-gradient(var(--tkw-line), transparent); }
.tkw-entry__dot { width: 12px; height: 12px; border-radius: 999px; background: var(--t-dot); box-shadow: 0 0 0 4px var(--t-bg); }
.tkw-entry__body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 10px; padding: 16px 0 18px; border-bottom: 1px solid var(--tkw-line-2); }
.tkw-entry:last-child .tkw-entry__body { border-bottom: 0; }
.tkw-entry__head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.tkw-entry__stage { font-family: var(--tkw-head); font-size: 15px; font-weight: 700; color: var(--tkw-ink); }
.tkw-entry__badge { margin-left: auto; }
.tkw-entry__update { font-size: 14px; line-height: 1.55; color: var(--tkw-text); overflow-wrap: anywhere; }
.tkw-entry__facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px 20px; font-size: 13px; }
.tkw-entry__facts > div { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.tkw-entry__facts dt { font-size: 12px; color: var(--tkw-muted); }
.tkw-entry__facts dd { color: var(--tkw-text); overflow-wrap: anywhere; }
.tkw-entry__facts dd.tkw-muted { color: var(--tkw-muted); }
.tkw-entry__facts dd.is-blocker { color: #93450a; font-weight: 600; }
.tkw-entry.is-latest .tkw-entry__body { background: linear-gradient(90deg, #f7fdfe, transparent 70%); margin-left: -10px; padding-left: 10px; border-radius: 10px; }

/* Records (submissions / rounds) */
.tkw-record { padding: 0; overflow: hidden; }
.tkw-record__head {
	display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; padding: 16px 22px; list-style: none; cursor: default;
	border-bottom: 1px solid var(--tkw-line-2);
}
details.tkw-record > .tkw-record__head { cursor: pointer; border-bottom: 0; min-height: 56px; }
details.tkw-record[open] > .tkw-record__head { border-bottom: 1px solid var(--tkw-line-2); }
.tkw-record__head::-webkit-details-marker { display: none; }
.tkw-record__title { margin: 0; font-family: var(--tkw-head); font-size: 17px; font-weight: 800; color: var(--tkw-ink); }
.tkw-record__head > .tkw-badge, .tkw-record__head > .tkw-tag { margin-left: auto; }
.tkw-record__chev { color: var(--tkw-muted); transition: transform 0.2s; }
details.tkw-record[open] .tkw-record__chev { transform: rotate(180deg); }
.tkw-record__body { padding: 18px 22px 22px; }
.tkw-record.is-current { box-shadow: 0 0 0 2px var(--t-bd, #c3e0f6); border-color: transparent; }

.tkw-kv { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 24px; }
.tkw-kv > div { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.tkw-kv dt { display: flex; align-items: center; gap: 7px; font-size: 12px; color: var(--tkw-muted); }
.tkw-kv dd { font-size: 14px; overflow-wrap: anywhere; }
.tkw-kv__stack { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.tkw-codeval { font-family: var(--tkw-mono); font-size: 12.5px; background: var(--tkw-subtle); border: 1px solid var(--tkw-line-2); padding: 2px 7px; border-radius: 6px; }
.tkw-extlink { display: inline-flex; align-items: center; gap: 5px; font-weight: 500; overflow-wrap: anywhere; }
.tkw-secret { display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.tkw-secret__value { font-family: var(--tkw-mono); font-size: 13px; padding: 4px 8px; background: var(--tkw-subtle); border: 1px solid var(--tkw-line-2); border-radius: 6px; letter-spacing: 0.06em; }
.tkw-secret.is-revealed .tkw-secret__value { letter-spacing: 0; background: #fffbeb; border-color: #fde68a; }

/* Screenshot grids */
.tkw-shots { display: grid; gap: 14px; }
.tkw-shots--desktop { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.tkw-shots--mobile { grid-template-columns: repeat(auto-fill, minmax(120px, 150px)); }
.tkw-shot { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.tkw-shot__frame { display: block; border-radius: 10px; overflow: hidden; border: 1px solid var(--tkw-line); background: var(--tkw-subtle); }
.tkw-shots--desktop .tkw-shot__frame { aspect-ratio: 16 / 10; }
.tkw-shots--mobile .tkw-shot__frame { aspect-ratio: 9 / 19; border: 5px solid #1e293b; border-radius: 18px; }
.tkw-shot__frame img { width: 100%; height: 100%; object-fit: cover; object-position: top; transition: transform 0.3s; }
.tkw-shot__frame:hover img { transform: scale(1.02); }
.tkw-shot__cap { font-size: 12px; color: var(--tkw-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* QA rounds */
.tkw-round__section { display: flex; flex-direction: column; gap: 10px; }
.tkw-round__section + .tkw-round__section { margin-top: 18px; }
.tkw-round__notes { padding: 12px 14px; border-left: 3px solid var(--tkw-line); background: var(--tkw-subtle); border-radius: 0 8px 8px 0; }
.tkw-resub { padding: 16px; border-radius: 12px; background: var(--tkw-subtle); border: 1px solid var(--tkw-line-2); }
.tkw-resub--form { background: #fff; border-color: #d6d4fa; box-shadow: 0 0 0 3px #f1f0fe; }
.tkw-resub__head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.tkw-resub__head .tkw-ok { margin-left: auto; }
.tkw-linklist { display: flex; flex-direction: column; gap: 6px; font-size: 13.5px; }

.tkw-decide {
	display: flex; flex-wrap: wrap; align-items: center; gap: 14px 18px; padding: 16px; margin-bottom: 14px;
	border-radius: 12px; background: #fcf8fb; border: 1px solid #f5cce0;
}
.tkw-decide__text { display: flex; flex-direction: column; gap: 3px; flex: 1 1 260px; }
.tkw-decide__text strong { font-family: var(--tkw-head); color: var(--tkw-ink); }
.tkw-decide__form { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; flex: 2 1 420px; justify-content: flex-end; }
.tkw-decide__note { flex: 1 1 200px; }

.tkw-history { display: flex; flex-direction: column; gap: 10px; margin-top: 14px; font-size: 13px; }
.tkw-history li { display: flex; gap: 10px; }
.tkw-history time { flex: 0 0 52px; }
.tkw-history li.is-latest { font-weight: 600; color: var(--tkw-ink); }
.tkw-history li.is-latest time { color: var(--tkw-ink); }


/* ---------- 13b. Teams, people and roles ---------- */
.tkw-stack-av { display: inline-flex; align-items: center; padding-left: 6px; }
.tkw-stack-av .tkw-avatar { margin-left: -6px; box-shadow: 0 0 0 2px #fff; }
.tkw-avatar--more { background: #eef0f4; color: var(--tkw-soft); font-size: 11px; }
.tkw-row__project .tkw-stack-av { margin-top: 2px; }
.tkw-role {
	display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: 999px; white-space: nowrap;
	font-size: 12px; font-weight: 600; background: var(--t-bg, #eef0f4); color: var(--t-fg, #3f4a5e); border: 1px solid var(--t-bd, #dadde5);
}
.tkw-personchip { display: inline-flex; align-items: center; gap: 10px; min-width: 0; }
.tkw-personchip > span { display: flex; flex-direction: column; align-items: flex-start; gap: 3px; min-width: 0; }
.tkw-personchip strong { font-size: 14px; color: var(--tkw-ink); font-weight: 600; }
.tkw-personchip .tkw-role { font-size: 11px; padding: 1px 8px; }
.tkw-meta__team { grid-column: 1 / -1; }
.tkw-teamlist { display: flex; flex-wrap: wrap; gap: 12px 22px; margin-top: 2px; }
.tkw-settings__team { grid-column: 1 / -1; }
.tkw-form__grid--1 { grid-template-columns: minmax(0, 1fr); }

.tkw-teampick { gap: 10px; }
.tkw-teampick__groups { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px; }
.tkw-teampick__group { display: flex; flex-direction: column; gap: 6px; padding: 12px; border: 1px solid var(--tkw-line-2); border-radius: 12px; background: var(--tkw-subtle); }
.tkw-teampick__title { margin-bottom: 4px; }
.tkw-teampick__person {
	display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 6px 10px; border-radius: 9px; cursor: pointer;
	background: #fff; border: 1px solid var(--tkw-line); font-size: 14px; transition: border-color 0.15s, background 0.15s;
}
.tkw-teampick__person input { width: 18px; height: 18px; margin: 0; accent-color: var(--tkw-indigo); flex: none; }
.tkw-teampick__person:has(input:checked) { border-color: var(--tkw-indigo); background: #f6f6ff; }
.tkw-teampick__person span:last-child { min-width: 0; overflow-wrap: anywhere; }
.tkw-teampick.is-invalid .tkw-teampick__group { border-color: var(--tkw-error-line); }

.tkw-tabs { display: flex; gap: 4px; padding: 4px; background: #eef0f5; border-radius: 12px; align-self: flex-start; max-width: 100%; overflow-x: auto; }
.tkw-tabs__tab {
	display: inline-flex; align-items: center; gap: 8px; min-height: 42px; padding: 0 16px; border-radius: 9px; white-space: nowrap;
	font-size: 14px; font-weight: 500; color: var(--tkw-soft) !important; text-decoration: none !important;
}
.tkw-tabs__tab.is-active { background: #fff; color: var(--tkw-ink) !important; font-weight: 600; box-shadow: 0 1px 2px rgba(11, 18, 41, 0.1); }

.tkw-people__row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; padding: 14px 22px; border-top: 1px solid var(--tkw-line-2); }
.tkw-people__who { display: flex; align-items: center; gap: 12px; flex: 1 1 260px; min-width: 0; }
.tkw-people__who > span { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.tkw-people__who strong { font-size: 14.5px; color: var(--tkw-ink); }
.tkw-people__who .tkw-small { overflow-wrap: anywhere; }
.tkw-people__count { flex: 0 0 90px; }
.tkw-people__role { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; flex: 0 1 300px; }
.tkw-people__role .tkw-select { flex: 1 1 170px; min-width: 0; }

.tkw-rolegrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 460px), 1fr)); gap: 18px; align-items: start; }
.tkw-rolecard { gap: 14px; }
.tkw-rolecard.is-flashed, .tkw-rolecard:target { box-shadow: 0 0 0 2px var(--tkw-indigo); }
.tkw-rolecard__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
.tkw-rolecard__head .tkw-role { font-size: 13.5px; padding: 5px 12px; }
.tkw-rolecard--new { border-style: dashed; border-width: 1.5px; background: #fcfcfe; }
.tkw-capgrid { display: flex; flex-direction: column; gap: 12px; }
.tkw-capgroup { display: flex; flex-direction: column; gap: 6px; }
.tkw-check--cap { width: 100%; padding: 8px 10px; border-radius: 8px; border: 1px solid var(--tkw-line-2); background: var(--tkw-subtle); }
.tkw-check--cap > span { display: flex; flex-direction: column; gap: 1px; }
.tkw-check--cap strong { font-size: 13.5px; font-weight: 600; }
.tkw-check--cap:has(input:checked) { background: #f3f3fe; border-color: #d6d4fa; }
.tkw-check--cap:has(input:disabled) { cursor: default; opacity: 0.85; }
.tkw-btn--danger { color: #b42318 !important; }

/* Handover */
.tkw-needlist { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 4px; }
.tkw-needlist li { display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 9px; background: var(--tkw-subtle); font-size: 13.5px; color: var(--tkw-soft); }
.tkw-needlist .tkw-icon { color: var(--tkw-indigo); }
.tkw-keepgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; }
.tkw-keepgrid li { display: flex; flex-direction: column; gap: 4px; }
.tkw-keepgrid img { aspect-ratio: 4 / 3; object-fit: cover; object-position: top; border-radius: 8px; border: 1px solid var(--tkw-line); }
.tkw-keepfile { display: flex; flex-direction: column; gap: 4px; }

.tkw-handover { display: flex; flex-direction: column; }
.tkw-handover__banner { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 14px 24px; background: #e4f5ea; color: #14532d; font-size: 14px; border-bottom: 1px solid #c3e6cf; }
.tkw-handover__head { display: flex; flex-direction: column; gap: 16px; padding: 28px 24px 22px; border-bottom: 1px solid var(--tkw-line-2); }
.tkw-handover__title { margin: 0; font-family: var(--tkw-head); font-weight: 800; font-size: 26px; letter-spacing: -0.02em; color: var(--tkw-ink); line-height: 1.2; overflow-wrap: anywhere; }
.tkw-handover__head .tkw-meta { border-top: 0; padding-top: 0; }
.tkw-handover__section { padding: 22px 24px; border-bottom: 1px solid var(--tkw-line-2); }
.tkw-handover__section > .tkw-h3 + .tkw-h4 { margin-top: 12px; }
.tkw-handover__links { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.tkw-handover__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 36px; }
.tkw-handover__grid > div { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.tkw-handover__foot { display: flex; gap: 10px; padding: 16px 24px; background: var(--tkw-subtle); color: var(--tkw-muted); font-size: 13px; border-radius: 0 0 var(--tkw-r-lg) var(--tkw-r-lg); }
.tkw-linkcard { display: flex; gap: 14px; align-items: center; padding: 16px; border: 1px solid var(--tkw-line); border-radius: 12px; }
.tkw-linkcard > span:last-child { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.tkw-linkcard__icon { width: 40px; height: 40px; flex: none; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; background: var(--t-bg); color: var(--t-fg); }
.tkw-rowsdl > div { display: flex; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--tkw-line-2); font-size: 14px; }
.tkw-rowsdl > div:last-child { border-bottom: 0; }
.tkw-rowsdl dt { flex: 0 0 110px; color: var(--tkw-muted); }
.tkw-rowsdl dd { min-width: 0; overflow-wrap: anywhere; }

/* Printable handover page */
.tkw-print { min-height: 100vh; background: #e9ebf2; }
.tkw-print__bar { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; padding: 12px 24px; background: var(--tkw-navy); color: #fff; }
.tkw-print__back { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 10px; color: var(--tkw-navy-text) !important; font-size: 14px; }
.tkw-print__crumb { font-size: 14px; color: var(--tkw-navy-muted); }
.tkw-print__actions { margin-left: auto; display: flex; gap: 10px; }
.tkw-print__warn { max-width: 1040px; margin: 20px auto 0; padding: 0 16px; }
.tkw-print__sheet { max-width: 1040px; margin: 24px auto 56px; background: #fff; border-radius: 16px; box-shadow: 0 1px 3px rgba(11, 18, 41, 0.06), 0 12px 32px rgba(11, 18, 41, 0.06); overflow: hidden; }
.tkw-print__sheet .tkw-handover__banner, .tkw-print__sheet .tkw-handover__head, .tkw-print__sheet .tkw-handover__section, .tkw-print__sheet .tkw-handover__foot { padding-left: 40px; padding-right: 40px; }
.tkw-print__stamp { padding: 12px 40px 20px; font-size: 11.5px; color: var(--tkw-muted); }

/* Guide */
.tkw-guide-types { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.tkw-guide-type { display: flex; flex-direction: column; gap: 8px; padding: 16px; border: 1px solid var(--tkw-line); border-radius: 12px; }
.tkw-guide-steps li { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 16px; align-items: start; padding: 18px 22px; border-top: 1px solid var(--tkw-line-2); }
.tkw-guide-steps li > div { display: flex; flex-direction: column; gap: 4px; font-size: 14px; }
.tkw-guide-steps__n { width: 36px; height: 36px; border-radius: 999px; background: var(--tkw-indigo); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-weight: 700; }
.tkw-guide-steps__apply { display: flex; gap: 6px; flex-wrap: wrap; }
.tkw-guide-roles { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; }
.tkw-guide-roles li { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 12px; align-items: start; }
.tkw-guide-roles .tkw-role { justify-self: start; }
@media (max-width: 600px) { .tkw-guide-roles li { grid-template-columns: minmax(0, 1fr); gap: 4px; } }
.tkw-statuslist { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0; }

/* Standalone (no-access) */
.tkw-standalone { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px 16px; }
.tkw-standalone .tkw-card { max-width: 560px; width: 100%; }

/* ---------- 14. Login ---------- */
.tkw-login { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); background: var(--tkw-navy); }
.tkw-login__brand { display: flex; flex-direction: column; justify-content: space-between; gap: 40px; padding: 48px; color: var(--tkw-navy-text); border-right: 1px solid var(--tkw-navy-3); }
.tkw-login__brand .tkw-brand { padding: 0; }
.tkw-login__pitch { display: flex; flex-direction: column; gap: 18px; max-width: 460px; }
.tkw-eyebrow { font-size: 12px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--tkw-cyan-l); }
.tkw-login__pitch h1 { margin: 0; font-family: var(--tkw-head); font-weight: 800; font-size: 40px; line-height: 1.15; letter-spacing: -0.02em; color: #fff; }
.tkw-login__steps { display: flex; flex-direction: column; gap: 10px; margin-top: 8px; font-size: 14px; }
.tkw-login__steps li { display: flex; align-items: center; gap: 12px; }
.tkw-login__steps span { width: 26px; height: 26px; border-radius: 999px; border: 1px solid var(--tkw-navy-line); display: inline-flex; align-items: center; justify-content: center; font-size: 12px; color: #fff; }
.tkw-login__steps li:last-child span { background: var(--tkw-cyan); border-color: var(--tkw-cyan); color: var(--tkw-navy); font-weight: 700; }
.tkw-login__foot { font-size: 12px; color: #6e7898; }
.tkw-login__panel { display: flex; align-items: center; justify-content: center; padding: 48px 16px; background: var(--tkw-bg); }
.tkw-login__card { width: 100%; max-width: 410px; display: flex; flex-direction: column; gap: 18px; padding: 32px; background: #fff; border: 1px solid var(--tkw-line); border-radius: 16px; box-shadow: 0 10px 30px rgba(11, 18, 41, 0.06); }
.tkw-login__head { display: flex; flex-direction: column; gap: 6px; }
.tkw-login__head h2 { margin: 0; font-family: var(--tkw-head); font-weight: 800; font-size: 24px; color: var(--tkw-ink); }
.tkw-login__head p { font-size: 14px; color: var(--tkw-muted); }
.tkw-login__row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; font-size: 13px; }
.tkw-login__row a { font-weight: 600; }

/* ---------- 15. Dialog ---------- */
.tkw-dialog { border: 0; padding: 0; border-radius: 16px; max-width: min(460px, calc(100vw - 32px)); width: 100%; box-shadow: var(--tkw-shadow-lg); }
.tkw-dialog::backdrop { background: rgba(11, 18, 41, 0.55); }
.tkw-dialog__box { display: flex; flex-direction: column; gap: 10px; padding: 24px; font-family: var(--tkw-font); }
.tkw-dialog__icon { width: 44px; height: 44px; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center; background: #fdf1de; color: #93450a; }
.tkw-dialog__title { margin: 6px 0 0; font-family: var(--tkw-head); font-size: 19px; font-weight: 800; color: var(--tkw-ink); }
.tkw-dialog__text { font-size: 14.5px; line-height: 1.55; color: var(--tkw-soft); }
.tkw-dialog__actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px; margin-top: 12px; }

/* ==========================================================================
   16. Responsive — designed per range, tested at 1440 / 1280 / 1024 / 820 / 768 / 600 / 390 / 360
   ========================================================================== */

/* Large laptop: dashboard rows lose the header strip */
@media (max-width: 1240px) {
	.tkw-rows-head { display: none; }
	.tkw-split { grid-template-columns: minmax(0, 1fr) 300px; }
	.tkw-pipeline__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Tablet landscape and below: off-canvas navigation, single column */
@media (max-width: 1080px) {
	.tkw-app { grid-template-columns: minmax(0, 1fr); background: var(--tkw-bg); }
	.tkw-topbar {
		display: flex; align-items: center; gap: 10px; position: sticky; top: 0; z-index: 50;
		height: 60px; padding: 0 12px 0 4px; background: var(--tkw-navy); color: #fff;
	}
	.tkw-topbar__brand { display: inline-flex; align-items: center; gap: 10px; color: #fff !important; font-family: var(--tkw-head); font-weight: 700; font-size: 15px; text-decoration: none !important; }
	.tkw-topbar__brand .tkw-logo { width: 30px; height: 30px; font-size: 15px; border-radius: 8px; }
	.tkw-topbar .tkw-avatar { margin-left: auto; }
	.tkw-sidebar {
		position: fixed; inset: 0 auto 0 0; z-index: 60; width: min(300px, 86vw); height: 100%;
		transform: translateX(-102%); transition: transform 0.22s ease; box-shadow: var(--tkw-shadow-lg);
	}
	.tkw-sidebar .tkw-sidebar__close { display: inline-flex; color: var(--tkw-navy-text); }
	.tkw-app.is-nav-open .tkw-sidebar { transform: none; }
	.tkw-main { padding: 24px 24px 56px; }
	.tkw-split { grid-template-columns: minmax(0, 1fr); }
	.tkw-split__side { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
	.tkw-split__side > .tkw-form, .tkw-split__side > form { grid-column: 1 / -1; }
	.tkw-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.tkw-meta { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Tablet portrait: compact stepper */
@media (max-width: 900px) {
	.tkw-stepper ol { gap: 6px; }
	.tkw-step { flex-direction: column; align-items: center; text-align: center; gap: 8px; padding: 12px 6px; }
	.tkw-step__num, .tkw-step__sub, .tkw-step__name { display: none; }
	.tkw-step__dot { flex: none; width: 32px; height: 32px; }
	.tkw-step__short { display: block; font-family: var(--tkw-head); font-size: 12.5px; font-weight: 700; color: var(--tkw-ink); line-height: 1.25; }
	.tkw-step.is-skip .tkw-step__short { color: var(--tkw-muted); text-decoration: line-through; }
	.tkw-stepper__current { display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; margin: 10px 2px 0; font-size: 13px; color: var(--tkw-muted); }
	.tkw-stepper__current strong { font-family: var(--tkw-head); color: var(--tkw-ink); font-size: 15px; }
	.tkw-entry__facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.tkw-guide-steps li { grid-template-columns: 40px minmax(0, 1fr); }
	.tkw-guide-steps__apply { grid-column: 2; }
}

/* Tablet and below: overview table becomes stacked cards */
@media (max-width: 960px) {
	.tkw-table thead { display: none; }
	.tkw-table, .tkw-table tbody, .tkw-table tr, .tkw-table td { display: block; width: 100%; }
	.tkw-table tr { padding: 14px 16px; border-bottom: 1px solid var(--tkw-line-2); }
	.tkw-table td, .tkw-table td:first-child, .tkw-table td:last-child { padding: 4px 0; border: 0; max-width: none; }
	.tkw-table td:not(:first-child) { display: flex; gap: 12px; align-items: center; font-size: 13.5px; }
	.tkw-table td:not(:first-child)::before { content: attr(data-label); flex: 0 0 96px; font-size: 12px; color: var(--tkw-muted); }
	.tkw-table td:first-child { padding-bottom: 8px; }
	.tkw-tablewrap { overflow: visible; }
	.tkw-table tbody tr:hover td { background: none; }
}

/* Large phones / small tablets */
@media (max-width: 760px) {
	.tkw-main { padding: 18px 16px 48px; gap: 18px; }
	.tkw-h1 { font-size: 25px; }
	.tkw-h1--project { font-size: 21px; }
	.tkw-card { padding: 18px 16px; }
	.tkw-card--flush { padding: 0; }
	.tkw-card--flush .tkw-card__head--line, .tkw-card__pad { padding: 18px 16px 14px; }
	.tkw-projhead { padding: 18px 16px; }
	.tkw-filters { padding: 14px 16px; }
	.tkw-filters .tkw-inline-field { flex: 1 1 calc(50% - 6px); }
	.tkw-filters .tkw-inline-field .tkw-select { flex: 1; min-width: 0; }
	.tkw-filters .tkw-inline-field > span { display: none; }
	.tkw-seg { flex: 1 1 100%; }
	.tkw-seg__btn { flex: 1; }
	.tkw-row { padding: 16px; gap: 12px; }
	.tkw-row__project, .tkw-row__stage, .tkw-row__status, .tkw-row__update { flex: 1 1 100%; }
	.tkw-row__open { flex: 1 1 100%; }
	.tkw-stepbar { max-width: none; }


	.tkw-split__side { display: flex; align-items: stretch; }
	.tkw-form__grid, .tkw-form__grid--2, .tkw-choice-grid, .tkw-settings__form, .tkw-kv, .tkw-needlist,
	.tkw-handover__links, .tkw-handover__grid, .tkw-guide-types { grid-template-columns: minmax(0, 1fr); }
	.tkw-split__side .tkw-form__grid--2 { grid-template-columns: 1fr 1fr; }
	.tkw-form--wide { padding: 18px 16px; }
	.tkw-form__actions { justify-content: stretch; }
	.tkw-form__actions .tkw-btn { flex: 1 1 auto; }
	.tkw-form__actions > .tkw-small { flex: 1 1 100%; }
	.tkw-form__actions--sticky { margin: 0 -16px -18px; padding: 12px 16px; }
	.tkw-record__head { padding: 14px 16px; }
	.tkw-record__body { padding: 16px; }
	.tkw-record__head > .tkw-badge, .tkw-record__head > .tkw-tag { margin-left: 0; }
	.tkw-decide__form { justify-content: stretch; }
	.tkw-decide__form .tkw-btn { flex: 1 1 auto; }
	.tkw-handover__banner, .tkw-handover__head, .tkw-handover__section, .tkw-handover__foot,
	.tkw-print__sheet .tkw-handover__banner, .tkw-print__sheet .tkw-handover__head, .tkw-print__sheet .tkw-handover__section, .tkw-print__sheet .tkw-handover__foot { padding-left: 16px; padding-right: 16px; }
	.tkw-handover__title { font-size: 21px; }
	.tkw-print__bar { padding: 10px 12px; }
	.tkw-print__crumb { display: none; }
	.tkw-print__sheet { margin: 12px 8px 32px; border-radius: 12px; }
	.tkw-login { grid-template-columns: minmax(0, 1fr); }
	.tkw-login__brand { padding: 28px 20px; gap: 20px; border-right: 0; }
	.tkw-login__pitch h1 { font-size: 26px; }
	.tkw-login__steps, .tkw-login__foot { display: none; }
	.tkw-login__panel { padding: 24px 16px 40px; align-items: flex-start; }
	.tkw-login__card { padding: 24px 20px; }
}

/* Phones */
@media (max-width: 600px) {
	.tkw-tiles { gap: 10px; }
	.tkw-tile { padding: 14px; }
	.tkw-tile__value strong { font-size: 26px; }
	.tkw-tile__value span { display: none; }
	.tkw-pipeline__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.tkw-meta { grid-template-columns: minmax(0, 1fr); gap: 10px; }
	.tkw-meta > div { flex-direction: row; justify-content: space-between; align-items: center; gap: 12px; }
	.tkw-meta dd { text-align: right; }
	.tkw-projhead__actions { width: 100%; }
	.tkw-projhead__actions .tkw-btn { flex: 1 1 auto; }
	.tkw-pagehead > .tkw-btn { width: 100%; }

	.tkw-step { padding: 10px 2px; border-radius: 10px; }
	.tkw-step__short { font-size: 11px; }
	.tkw-entry { gap: 10px; }
	.tkw-entry__facts { grid-template-columns: minmax(0, 1fr); }
	.tkw-entry__badge { margin-left: 0; flex-basis: 100%; }
	.tkw-entry.is-latest .tkw-entry__body { margin-left: 0; padding-left: 0; background: none; }
	.tkw-split__side .tkw-form__grid--2 { grid-template-columns: minmax(0, 1fr); }
	.tkw-shots--desktop { grid-template-columns: minmax(0, 1fr); }
	.tkw-shots--mobile { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.tkw-file .tkw-btn { width: 100%; }
	.tkw-drop__zone { flex-direction: column; align-items: flex-start; }
	.tkw-btnrow { justify-content: stretch; }
	.tkw-btnrow > *, .tkw-btnrow form, .tkw-btnrow .tkw-btn { flex: 1 1 auto; width: 100%; }
	.tkw-print__actions { width: 100%; }
	.tkw-print__actions .tkw-btn { flex: 1; }
	.tkw-rowsdl > div { flex-direction: column; gap: 2px; }
	.tkw-rowsdl dt { flex: none; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
	.tkw *, .tkw *::before, .tkw *::after { transition: none !important; animation-duration: 0.01ms !important; }
}

/* ---------- 17. Print (handover summary + any workspace page) ---------- */
@media print {
	@page { margin: 14mm; }
	body.tkw { background: #fff; font-size: 11.5pt; }
	.tkw-print { background: #fff; }
	.tkw-print__bar, .tkw-print__warn, .tkw-topbar, .tkw-sidebar, .tkw-skip, .tkw-dialog, .tkw-scrim { display: none !important; }
	.tkw-print__sheet { margin: 0; max-width: none; box-shadow: none; border-radius: 0; }
	.tkw-print__sheet .tkw-handover__banner, .tkw-print__sheet .tkw-handover__head, .tkw-print__sheet .tkw-handover__section, .tkw-print__sheet .tkw-handover__foot { padding-left: 0; padding-right: 0; }
	.tkw-handover__banner { background: none; border: 1px solid #c3e6cf; padding: 8px 12px !important; border-radius: 6px; }
	.tkw-handover__section, .tkw-shot, .tkw-linkcard, .tkw-file { break-inside: avoid; }
	.tkw-handover__links, .tkw-handover__grid { grid-template-columns: 1fr 1fr; }
	.tkw-shots--desktop { grid-template-columns: repeat(3, 1fr); }
	.tkw-shots--mobile { grid-template-columns: repeat(5, 1fr); }
	.tkw-file .tkw-btn { display: none; }
	.tkw a { color: #1e293b; }
	.tkw-extlink::after { content: " (" attr(href) ")"; font-size: 9pt; color: #5b6478; }
	.tkw-extlink .tkw-icon { display: none; }
	.tkw-app { display: block; }
	.tkw-main { padding: 0; }
}
@media (max-width: 760px) {
	.tkw-table .tkw-badge { white-space: normal; }
}

@media (max-width: 760px) {
	.tkw-people__row { padding: 14px 16px; }
	.tkw-people__count { flex: 1 1 auto; }
	.tkw-people__role { flex: 1 1 100%; }
	.tkw-meta__team { grid-column: auto; }
	.tkw-meta > .tkw-meta__team { flex-direction: column; align-items: flex-start; }
	.tkw-teamlist { flex-direction: column; gap: 10px; }
}
