/* Staff CRM layout on top of /shared/ui.css */

/* Rootline's look (copied from boecia-rootline/rootline/app/estilos.css, 5 Nov 2026, Valentin): Day (paper with
   a silk light and honey pollen) and Night (ink with honey). tema.js sets data-tema on <html> before paint; "auto"
   follows the computer. These :root rules come after ui.css, so they also beat its own dark-mode block.
   Rootline's sizes are kept only where they don't cost rows: tables, cards and buttons stay CRM-dense. */
:root {
  color-scheme: light;
  --paper: #FBFAF6; --bone: #EFF1EC;
  --bg: var(--paper); --surface: #ffffff; --surface-2: var(--bone);
  --hover: rgb(21 36 31 / .055); --border: rgb(21 36 31 / .08); --border-strong: rgb(21 36 31 / .15);
  --text: var(--ink); --text-2: rgb(21 36 31 / .8); --muted: rgb(21 36 31 / .68);
  --accent: #E9B44C; --accent-strong: #B98422; --accent-soft: rgb(233 180 76 / .18); --accent-text: var(--honey-deep);
  --blue: #2a78d6; --blue-soft: #e6effb; --blue-text: #1c5cab;
  --green: #2f6b4f; --green-soft: rgb(47 107 79 / .1); --green-text: #2f6b4f;
  --red: #a8402c; --red-soft: rgb(168 64 44 / .09); --red-text: #a8402c;
  --violet-soft: #eeeafc; --violet-text: #4a3aa7;
  --glass: rgb(255 255 255 / .66); --glass-strong: rgb(255 255 255 / .9); --bar: rgb(251 250 246 / .86);
  --honey-grad: linear-gradient(180deg, #f1c461 0%, #e9b44c 55%, #e0a83c 100%);
  --primary-bg: var(--ink); --primary-text: var(--paper); --primary-hover: #1f342d;
  --primary-shadow: inset 0 1px 0 rgb(255 255 255 / .12), 0 10px 24px -12px rgb(21 36 31 / .6);
  --edge: inset 0 0 0 1px rgb(255 255 255 / .92), 0 0 0 1px rgb(21 36 31 / .055);
  --shadow-sm: var(--edge);
  --shadow: var(--edge), 0 10px 20px -15px rgb(21 36 31 / .38);
  --shadow-lg: var(--edge), 0 26px 44px -30px rgb(21 36 31 / .42);
  --sunken: inset 0 1px 3px rgb(21 36 31 / .09), inset 0 0 0 1px rgb(21 36 31 / .06);
  --ring: 0 0 0 3px rgb(233 180 76 / .5);
  --luz: radial-gradient(70% 45% at 0% 0%, rgb(233 180 76 / .16), transparent 60%), radial-gradient(60% 50% at 100% 100%, rgb(203 216 201 / .5), transparent 65%);
  --polen-a: rgb(233 180 76 / .85); --polen-halo: rgb(233 180 76 / .18);
  --radius: 22px; --radius-md: 14px; --radius-sm: 12px;
}
:root[data-tema="night"] {
  color-scheme: dark;
  --bg: var(--ink); --surface: #1b2d27; --surface-2: rgb(244 238 223 / .04);
  --hover: rgb(244 238 223 / .06); --border: rgb(244 238 223 / .08); --border-strong: rgb(244 238 223 / .16);
  --text: var(--cream); --text-2: rgb(244 238 223 / .84); --muted: rgb(244 238 223 / .68);
  --accent: #E9B44C; --accent-strong: #f1c461; --accent-soft: rgb(233 180 76 / .14); --accent-text: var(--honey);
  --blue: #3987e5; --blue-soft: #16263b; --blue-text: #8fbdf2;
  --green: #8ec5a4; --green-soft: rgb(142 197 164 / .1); --green-text: #8ec5a4;
  --red: #ee8f78; --red-soft: rgb(238 143 120 / .11); --red-text: #ee8f78;
  --violet-soft: #221d3b; --violet-text: #b3aaf2;
  --glass: rgb(244 238 223 / .055); --glass-strong: rgb(244 238 223 / .11); --bar: rgb(21 36 31 / .86);
  --primary-bg: var(--honey-grad); --primary-text: var(--ink); --primary-hover: var(--honey-grad);
  --primary-shadow: inset 0 1px 0 rgb(255 255 255 / .45), inset 0 -2px 0 rgb(138 91 18 / .2), 0 10px 24px -12px rgb(233 180 76 / .5);
  --edge: inset 0 1px 0 rgb(255 255 255 / .06), 0 0 0 1px rgb(244 238 223 / .075);
  --shadow: var(--edge), 0 12px 22px -15px rgb(0 0 0 / .7);
  --shadow-lg: var(--edge), 0 28px 46px -26px rgb(0 0 0 / .75);
  --sunken: inset 0 1px 3px rgb(0 0 0 / .45), inset 0 0 0 1px rgb(244 238 223 / .06);
  --ring: 0 0 0 3px rgb(233 180 76 / .42);
  --luz: radial-gradient(70% 45% at 0% 0%, rgb(233 180 76 / .1), transparent 60%), radial-gradient(60% 50% at 100% 100%, rgb(233 180 76 / .05), transparent 65%);
  --polen-a: rgb(241 198 107 / .95); --polen-halo: rgb(233 180 76 / .3);
}
body {
  background:
    radial-gradient(circle at 8px 38%, var(--polen-a) 0 1.6px, transparent 2.6px),
    radial-gradient(circle at 8px 38%, var(--polen-halo) 0 3px, transparent 8px),
    radial-gradient(circle at calc(100% - 9px) 71%, var(--polen-a) 0 1.3px, transparent 2.3px),
    radial-gradient(circle at calc(100% - 9px) 71%, var(--polen-halo) 0 2.5px, transparent 8px),
    radial-gradient(circle at 63% calc(100% - 7px), var(--polen-a) 0 1.1px, transparent 2.1px),
    var(--luz), var(--bg);
  background-attachment: fixed;
}
::selection { background: rgb(233 180 76 / .35); }
:focus-visible { outline: none; box-shadow: var(--ring); border-radius: 8px; }
[tabindex="-1"]:focus-visible { box-shadow: none; } /* the page area gets focus after each navigation: no ring there */

/* Page titles: Schibsted 500, tight, with Rootline's short honey line under them. */
h1 { font-weight: 500; letter-spacing: -0.04em; }
.page-head h1 { font-size: clamp(24px, 2.6vw, 30px); line-height: 1.08; }
.page-head h1::after { content: ''; display: block; width: 44px; height: 3px; margin-top: 10px; border-radius: 3px; background: var(--honey); }

/* Buttons: pills on glass; the main one in ink (Day) or honey (Night). Same height as before. */
.btn { border-radius: 999px; border-color: transparent; background: var(--glass-strong); box-shadow: var(--shadow); font-weight: 600; transition: transform .16s cubic-bezier(.23, 1, .32, 1), background-color .16s, box-shadow .16s; }
.btn:hover { background: var(--surface); }
.btn:active { transform: scale(.97); }
.btn.primary { background: var(--primary-bg); border-color: transparent; color: var(--primary-text); box-shadow: var(--primary-shadow); }
.btn.primary:hover { background: var(--primary-hover); border-color: transparent; }
.btn.ghost { background: transparent; box-shadow: none; color: var(--muted); }
.btn.ghost:hover { background: var(--hover); color: var(--text); }
.btn.danger { background: var(--red-soft); box-shadow: inset 0 0 0 1px rgb(168 64 44 / .25); }
.count-dot { min-width: 22px; height: 22px; padding: 0 7px; border-radius: 999px; background: var(--honey-grad); color: var(--ink); font: 600 11.5px/22px var(--font-display); }

/* Fields: sunken, like Rootline's. */
input:not([type=checkbox]):not([type=radio]):not([type=file]), select, textarea { border-color: transparent; border-radius: 12px; background-color: var(--hover); box-shadow: var(--sunken); }
input:focus, select:focus, textarea:focus { border-color: transparent; background-color: var(--surface); box-shadow: var(--sunken), var(--ring); }
input[type=checkbox] { accent-color: var(--ink); }
:root[data-tema="night"] input[type=checkbox] { accent-color: var(--honey); }

/* Cards and tables: white, big corners, Rootline's soft edge. Row padding unchanged. */
.badge { font-weight: 600; }
.badge.green { background: var(--green-soft); color: var(--green-text); }
.table-wrap, .card, .panel { box-shadow: var(--shadow-lg); }
.table th { font-size: 11.5px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; border-bottom-color: var(--border-strong); background: transparent; }
.table-wrap .table { background: var(--surface); }
.tab[aria-selected="true"] { border-bottom-color: var(--honey); }
.modal { border-radius: var(--radius); }

/* Filter chips: glass pills, the chosen one in honey (Rootline's b-vista). Board/Table: a sunken segmented control. */
.filter-chip { border: 0; background: var(--glass-strong); box-shadow: var(--shadow); color: var(--text-2); font-weight: 600; transition: background-color .16s, color .16s, transform .14s; }
.filter-chip:hover { background: var(--surface); color: var(--text); }
.filter-chip:active { transform: scale(.97); }
.filter-chip[aria-pressed="true"], .filter-chip[aria-pressed="true"]:hover { background: var(--honey-grad); color: var(--ink); box-shadow: inset 0 1px 0 rgb(255 255 255 / .45), 0 8px 18px -12px rgb(201 148 54 / .9); }
.filter-chip[aria-pressed="true"] .n { color: var(--ink); opacity: .75; }
.seg { padding: 4px; border-radius: 999px; background: var(--hover); box-shadow: var(--sunken); }
.seg button { border-radius: 999px; font-weight: 600; }
.seg button[aria-pressed="true"] { background: var(--surface); color: var(--text); box-shadow: var(--shadow); }
/* Switches and notices, Rootline's way. */
.switch span { background: var(--hover); box-shadow: var(--sunken); }
.switch input:checked + span { background: var(--honey); }
.notice { border-radius: var(--radius-md); background: rgb(233 180 76 / .16); color: var(--text); box-shadow: inset 0 0 0 1px rgb(233 180 76 / .5); }
:root[data-tema="night"] .notice { background: rgb(233 180 76 / .1); box-shadow: inset 0 0 0 1px rgb(233 180 76 / .36); }

/* Rootline's live background (fondo.js) sits behind everything. */
#fondo { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
.layout, .signin { position: relative; z-index: 1; }

/* Drawer, dialog, toast, loading: Rootline's (cajon, dialogo, toast, cargando). */
.scrim { background: rgb(21 36 31 / .28); }
.drawer { background: var(--bg); box-shadow: -30px 0 60px -30px rgb(21 36 31 / .45); transition: transform .22s cubic-bezier(.32, .72, 0, 1), visibility 0s linear .22s; }
.drawer.open { box-shadow: -30px 0 60px -30px rgb(21 36 31 / .45); transition: transform .38s cubic-bezier(.32, .72, 0, 1), visibility 0s; }
.drawer-head { border-bottom-color: var(--border); }
.drawer-head h2 { font-weight: 500; font-size: 22px; letter-spacing: -0.035em; }
.modal { box-shadow: var(--shadow-lg), 0 40px 80px -30px rgb(21 36 31 / .5); }
.modal h2 { font-weight: 600; letter-spacing: -0.025em; }
.toast { background: var(--ink); color: var(--cream); border-radius: var(--radius-md); box-shadow: 0 20px 40px -20px rgb(0 0 0 / .6); font-size: 13.5px; }
:root[data-tema="night"] .toast { background: var(--cream); color: var(--ink); }
.toast.error { background: var(--red); color: #fff; }
:root[data-tema="night"] .toast.error { background: #a8402c; }
.loading { display: flex; align-items: center; justify-content: center; gap: 10px; }
.loading::before { content: ''; width: 16px; height: 16px; border-radius: 50%; border: 2px solid var(--border-strong); border-top-color: var(--honey); animation: gira .6s linear infinite; }
@keyframes gira { to { transform: rotate(360deg); } }

/* Each page rises in softly when you arrive (Rootline's "entrada"), once, never on redraws. */
@keyframes entrar { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.main.entering > * { animation: entrar .28s cubic-bezier(.23, 1, .32, 1) both; }
.main.entering > :nth-child(2) { animation-delay: 40ms; }
.main.entering > :nth-child(3) { animation-delay: 80ms; }
.main.entering > :nth-child(4) { animation-delay: 120ms; }
.main.entering > :nth-child(n+5) { animation-delay: 160ms; }
.signin-logo { animation: entrar .36s cubic-bezier(.23, 1, .32, 1) both; }
.signin-card { animation: entrar .36s 60ms cubic-bezier(.23, 1, .32, 1) both; }
.signin-card h1::after { content: ''; display: block; width: 40px; height: 3px; margin-top: 12px; border-radius: 3px; background: var(--honey); }
@media (prefers-reduced-motion: reduce) {
  .main.entering > *, .signin-logo, .signin-card { animation-name: none; }
  .btn:active { transform: none; }
  .drawer, .drawer.open { transition-duration: 0s; }
}

/* The full wordmark: ink in Day, cream in Night. */
.logo-dark { display: none !important; }
:root[data-tema="night"] .logo-light { display: none !important; }
:root[data-tema="night"] .logo-dark { display: block !important; }

/* Sign-in: paper, dark logo, white card, ink button. */
.signin { min-height: 100vh; display: grid; place-items: center; align-content: center; gap: 22px; padding: 24px 16px; }
.signin-logo img { width: 160px; height: auto; }
.signin-card { width: min(420px, 100%); background: var(--surface); border-radius: 20px; box-shadow: 0 1px 2px rgb(21 36 31 / .04), 0 24px 48px -28px rgb(21 36 31 / .28); padding: 32px 28px; display: grid; gap: 14px; }
.signin-card h1 { font-size: 26px; }
.layout { display: grid; grid-template-columns: var(--sidebar) minmax(0, 1fr); min-height: 100vh; }
/* Sidebar in frosted glass, like Rootline's. */
.sidebar {
  position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; gap: 22px;
  padding: 22px 14px 14px; background: var(--glass); color: var(--text); border-right: 1px solid var(--border);
  -webkit-backdrop-filter: blur(16px) saturate(1.2); backdrop-filter: blur(16px) saturate(1.2);
}
.sidebar .brand { padding: 0 10px; }
.sidebar .logo, .topbar .logo { height: 36px; width: auto; display: block; }
nav { display: grid; gap: 2px; }
.nav-link {
  display: flex; align-items: center; gap: 11px; min-height: 40px; padding: 0 10px 0 12px; border-radius: 12px;
  color: var(--text-2); font-weight: 600; text-decoration: none; transition: background-color .18s, color .18s;
}
.nav-link svg { width: 18px; height: 18px; flex: none; opacity: .75; }
.nav-link:hover { background: var(--hover); color: var(--text); text-decoration: none; }
/* Current page: a white card that floats, its icon in honey. */
.nav-link[aria-current="page"], .nav-link[aria-current="page"]:hover { background: var(--surface); color: var(--text); box-shadow: var(--shadow); }
.nav-link[aria-current="page"] svg { opacity: 1; color: var(--accent-text); }
.nav-link .count-dot { margin-left: auto; }
/* Day / Night switch, next to Sign out. */
.theme-btn svg { width: 17px; height: 17px; }

/* Recruiting · Sales · Admin: the staff sites (ats., crm., admin.), as tabs in a glass bar with Rootline's honey underline. */
.top-sticky { position: sticky; top: 0; z-index: 30; background: var(--bar); border-bottom: 1px solid var(--border); -webkit-backdrop-filter: blur(16px) saturate(1.2); backdrop-filter: blur(16px) saturate(1.2); }
.sitebar { display: flex; height: 56px; padding: 0 22px; }
.site-switch { display: flex; gap: 2px; }
.site-link {
  position: relative; display: flex; align-items: center; justify-content: center; gap: 8px; padding: 0 16px;
  font-size: 14px; font-weight: 600; color: var(--text-2); text-decoration: none; white-space: nowrap; transition: color .15s;
}
.site-link svg { width: 17px; height: 17px; flex: none; }
.site-link::after {
  content: ''; position: absolute; left: 12px; right: 12px; bottom: 0; height: 3px; border-radius: 3px 3px 0 0;
  background: var(--honey); transform: scaleX(0); transition: transform .22s cubic-bezier(.16, 1, .3, 1);
}
.site-link:hover { color: var(--text); text-decoration: none; }
.site-link:hover::after { transform: scaleX(.35); opacity: .5; }
.site-link[aria-current="page"] { color: var(--text); }
.site-link[aria-current="page"] svg { color: var(--accent-text); }
.site-link[aria-current="page"]::after { transform: none; opacity: 1; }
.site-link:focus-visible { outline: 2px solid var(--honey); outline-offset: -6px; border-radius: 10px; }
@media (prefers-reduced-motion: reduce) { .site-link, .site-link::after { transition: none; } }
/* Four tabs on a small phone: names only, so they always fit. */
@media (max-width: 420px) { .site-link svg { display: none; } }
.sidebar-foot { margin-top: auto; display: flex; align-items: center; gap: 8px; padding: 10px 6px 0; border-top: 1px solid var(--border); }
.me { display: flex; align-items: center; gap: 10px; min-width: 0; flex: 1; }
.me-text { display: grid; min-width: 0; }
.me-text b { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.avatar {
  width: 30px; height: 30px; border-radius: 50%; flex: none; display: inline-flex; align-items: center; justify-content: center;
  background: var(--accent-soft); color: var(--accent-text); font-weight: 650; font-size: 12px;
}
.sidebar .avatar { background: var(--honey); color: var(--ink); }
.avatar.lg { width: 44px; height: 44px; font-size: 15px; }

.main-col { min-width: 0; }
.topbar { display: none; }
.main { padding: 28px 32px 48px; max-width: 1280px; outline: none; }

.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px 16px; flex-wrap: wrap; margin-bottom: 20px; }
.page-head .titles { display: grid; gap: 4px; min-width: 0; }
.page-head .actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.crumb { font-size: 13px; color: var(--muted); }
.crumb a { color: var(--muted); }

.toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
.search { position: relative; flex: 1; min-width: 200px; max-width: 360px; }
.search svg { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; color: var(--muted); }
.search input { padding-left: 34px !important; }
.filter-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.filter-chip { height: 30px; padding: 0 12px; border-radius: 999px; font-size: 13px; cursor: pointer; } /* colours: Rootline block at the top */
.filter-chip .n { color: var(--muted); margin-left: 4px; }

.bulkbar { display: flex; align-items: center; gap: 10px; padding: 10px 14px; margin-bottom: 12px; border-radius: var(--radius); background: var(--accent-soft); color: var(--accent-text); font-weight: 500; }

/* dashboard */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 14px; margin-bottom: 22px; }
.stat { background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px 18px; display: grid; gap: 4px; text-decoration: none; color: var(--text); border-top: 3px solid transparent; transition: border-color .15s, box-shadow .15s; }
a.stat:hover { text-decoration: none; box-shadow: var(--shadow-lg); border-top-color: var(--honey); }
.stat-label { color: var(--muted); font-size: 13px; font-weight: 600; }
.stat-value { font-family: var(--font-display); font-size: 32px; font-weight: 500; letter-spacing: -0.02em; line-height: 1.15; }
.stat-note { font-size: 12.5px; color: var(--muted); }
.list { display: grid; }
.list-item { display: flex; align-items: center; gap: 12px; padding: 12px 4px; border-bottom: 1px solid var(--border); text-decoration: none; color: var(--text); }
.list-item:last-child { border-bottom: 0; }
a.list-item:hover { background: var(--hover); text-decoration: none; border-radius: 8px; }
.list-item .grow { flex: 1; min-width: 0; display: grid; gap: 1px; }
.list-item .title { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.list-item .meta { color: var(--muted); font-size: 12.5px; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); flex: none; }
.dot.off { background: transparent; }

/* pipeline board */
.board { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 8px; align-items: flex-start; }
.col { flex: 0 0 248px; background: var(--surface-2); border-radius: var(--radius); padding: 10px; border: 2px solid transparent; }
.col.is-empty { flex-basis: 150px; }
.col.drop { border-color: var(--accent); background: var(--accent-soft); }
.col-head { display: flex; justify-content: space-between; align-items: center; padding: 2px 4px 10px; font-size: 12.5px; font-weight: 600; color: var(--text-2); }
.col-head .n { color: var(--muted); font-weight: 500; }
.col-cards { display: grid; gap: 8px; min-height: 36px; }
.pcard { background: var(--surface); border-radius: 10px; box-shadow: var(--shadow-sm); padding: 11px 12px; cursor: grab; border: 1px solid transparent; display: grid; gap: 4px; }
.pcard:hover { border-color: var(--border-strong); }
.pcard.dragging { opacity: .45; }
.pcard .name { font-weight: 600; }
.pcard .meta { color: var(--muted); font-size: 12.5px; }
.pcard .meta.late { color: var(--accent-text); font-weight: 600; } /* past the stage's guide days */
.reasons { display: grid; gap: 8px; }
.pipe-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; margin-bottom: 18px; }
.pipe-stats .big { font-size: 28px; font-weight: 700; line-height: 1.1; }
.pipe-stats > .panel { margin: 0; }
.pipe-filter { width: auto; max-width: 260px; }
.pipe-stats ul { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 4px; }
.pipe-stats li { display: flex; gap: 6px; } .pipe-stats li b { margin-left: auto; }
.pcard .row { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-top: 4px; }
.pcard select { height: 28px; font-size: 12.5px; padding: 0 6px; width: auto; max-width: 140px; }
.col-empty { color: var(--muted); font-size: 12px; text-align: center; padding: 8px 0; }

/* candidate picker */
.picker-list { max-height: 340px; overflow-y: auto; border: 1px solid var(--border); border-radius: var(--radius-sm); margin-top: 10px; }
.picker-row { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-bottom: 1px solid var(--border); cursor: pointer; }
.picker-row:last-child { border-bottom: 0; }
.picker-row:hover { background: var(--hover); }

/* activity */
.feed { display: grid; }
.feed-item { display: grid; grid-template-columns: 28px 1fr; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--border); }
.feed-item:last-child { border-bottom: 0; }
.feed-item .who { font-weight: 600; }
.feed-item.client { background: linear-gradient(90deg, var(--accent-soft), transparent 70%); border-radius: 8px; padding-left: 6px; }

.share-item { border: 1px solid var(--border); border-radius: var(--radius); padding: 14px; display: grid; gap: 10px; align-content: start; }
.share-item pre { margin: 0; white-space: pre-wrap; font: 13px/1.5 'Manrope', system-ui, sans-serif; background: var(--surface-2); padding: 10px 12px; border-radius: 8px; max-height: 104px; overflow-y: auto; }
.share-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px; }

.perm-list { display: grid; gap: 10px; }

@media (max-width: 960px) {
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .layout { grid-template-columns: 1fr; }
  .sidebar { position: fixed; z-index: 45; left: 0; width: 260px; transform: translateX(-100%); transition: transform .2s; box-shadow: var(--shadow-lg); background: var(--bg); }
  .sidebar.open { transform: none; }
  .topbar { display: flex; align-items: center; gap: 8px; padding: 10px 16px 4px; }
  .sitebar { height: 46px; padding: 0 8px; }
  .site-switch { display: grid; width: 100%; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); }
  .site-link { padding: 0 4px; font-size: 13px; gap: 6px; }
  .topbar .logo { height: 28px; }
  .main { padding: 18px 16px 40px; }
  .page-head { align-items: flex-start; }
  .search { max-width: none; }
  .col { flex-basis: 78vw; }
  .table .hide-sm { display: none; }
}

/* small helpers used by leads / employees / settings */
.text-danger { color: var(--red-text); font-weight: 500; }
.push-right { margin-right: auto; }
.clamp { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; max-width: 520px; }
.perm-row { display: flex; gap: 12px; align-items: flex-start; padding: 10px 12px; border-radius: var(--radius-sm, 8px); background: var(--surface-2); cursor: pointer; }
.perm-row input { margin-top: 3px; }
.perm-row .perm-key { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 11.5px; color: var(--muted); }
.file-drop { display: flex; flex-direction: column; gap: 8px; padding: 14px; border: 1px dashed var(--border); border-radius: var(--radius); }
.link-list { display: grid; }
.link-list .row { justify-content: space-between; flex-wrap: nowrap; padding: 10px 0; border-top: 1px solid var(--border); }
.link-list .row:first-child { border-top: 0; }
.link-list .row > span { min-width: 0; }
.link-list code { font-size: 12.5px; word-break: break-all; }

/* job distribution */
.dot.on { background: var(--green); }
.dot.idle { background: transparent; box-shadow: inset 0 0 0 1.5px var(--border-strong); }
.share-item.done { background: var(--surface-2); }
.share-item.done pre { display: none; }
.push-left { margin-left: auto; }
.ml-4 { margin-left: 4px; }
button.list-item.as-button { width: 100%; background: none; border: 0; border-bottom: 1px solid var(--border); font: inherit; color: inherit; text-align: left; cursor: pointer; }
button.list-item.as-button:hover { background: var(--hover); border-radius: 8px; }
.as-link { border: 0; cursor: pointer; font: inherit; font-size: 12px; justify-self: start; }
.picker-row .grow { flex: 1; display: grid; gap: 3px; min-width: 0; }
.picker-list .picker-row:has(.chips) { align-items: flex-start; }
.dot.bad { background: var(--red); }

/* documents */
.doc-layout { display: grid; grid-template-columns: minmax(300px, 380px) minmax(0, 1fr); gap: 18px; align-items: start; }
.doc-form { position: sticky; top: 16px; max-height: calc(100vh - 32px); overflow-y: auto; }
.doc-form .form { gap: 12px; }
.doc-actions { margin-bottom: 12px; }
.doc-paper { background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 44px 52px; line-height: 1.6; font-size: 14.5px; max-width: 860px; }
.doc-paper h1 { font-size: 22px; margin-bottom: 14px; }
.doc-paper h2 { font-size: 16px; margin: 22px 0 8px; }
.doc-paper h3 { font-size: 14.5px; margin: 16px 0 6px; }
.doc-paper p, .doc-paper ul, .doc-paper ol { margin: 0 0 10px; }
.doc-paper ul, .doc-paper ol { padding-left: 22px; }
.doc-paper table { width: 100%; border-collapse: collapse; margin: 10px 0 14px; font-size: 13.5px; }
.doc-paper th, .doc-paper td { border: 1px solid var(--border); padding: 7px 10px; text-align: left; vertical-align: top; }
.doc-paper blockquote { margin: 10px 0; padding: 8px 12px; border-left: 3px solid var(--accent); background: var(--accent-soft); font-size: 13px; }
.doc-paper hr { border: 0; border-top: 1px solid var(--border); margin: 22px 0; }
.doc-fill { background: var(--accent-soft); border-radius: 3px; padding: 0 2px; }
.doc-missing { background: #fff2a8; color: #6b5300; border-radius: 3px; padding: 0 3px; font-weight: 600; }
@media (max-width: 960px) {
  .doc-layout { grid-template-columns: 1fr; }
  .doc-form { position: static; max-height: none; }
  .doc-paper { padding: 24px 20px; }
}
.notice.ok { background: var(--green-soft); color: var(--green-text); }
.doc-form label.is-missing input, .doc-form label.is-missing textarea { border-color: var(--accent); background: var(--accent-soft); }
.doc-actions .push { flex: 1; }
.status-grid { display: grid; gap: 10px; }
.status-row { display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; gap: 4px 12px; align-items: start; padding: 12px 14px; border-radius: var(--radius-sm); background: var(--surface-2); }
.status-row .dot { width: 12px; height: 12px; border-radius: 50%; margin-top: 4px; background: var(--muted); }
.status-row.ok .dot { background: var(--green); }
.status-row.warn .dot { background: var(--accent); }
.status-row.bad .dot { background: var(--red); }
.status-row .what { font-weight: 600; }
.status-row .detail { grid-column: 2 / 4; font-size: 12.5px; color: var(--text-2); }
.status-row .detail b { color: var(--text); font-weight: 600; }
.meter { height: 8px; border-radius: 4px; background: var(--border); overflow: hidden; }
.meter > span { display: block; height: 100%; background: var(--green); }
.meter.warn > span { background: var(--accent); }
.meter.bad > span { background: var(--red); }
@media print {
  .sidebar, .topbar, .sitebar, .page-head, .doc-form, .doc-actions, .toast, .scrim { display: none !important; }
  .layout { display: block; }
  .main { padding: 0; max-width: none; }
  .doc-layout { display: block; }
  body { background: #fff; }
  .doc-paper { box-shadow: none; padding: 0; max-width: none; color: #000; background: #fff; font-size: 11.5pt; }
  .doc-fill { background: none; padding: 0; }
  .doc-missing { background: none; color: #000; }
  .doc-paper blockquote { background: none; }
}

/* ---------- newsletter ---------- */
.nl-compose { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px; align-items: start; }
@media (max-width: 1100px) { .nl-compose { grid-template-columns: minmax(0, 1fr); } }
.nl-compose .form { min-width: 0; }
.nl-label { font-weight: 600; font-size: 13.5px; }
.nl-toolbar { display: flex; flex-wrap: wrap; gap: 6px; }
#nl-body { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 13.5px; line-height: 1.6; min-height: 320px; }
.nl-preview { position: sticky; top: 16px; min-width: 0; }
.nl-frame-wrap { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius); padding: 10px; display: flex; justify-content: center; }
.nl-frame-wrap iframe { width: 100%; height: 640px; border: 0; border-radius: 8px; background: #EFF1EC; transition: width .2s; }
.nl-frame-wrap.phone iframe { width: 380px; max-width: 100%; }
#modal .nl-frame-wrap iframe { height: 70vh; }
.nl-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 8px; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--border); }
.nl-timeline { list-style: none; padding: 0; margin: 6px 0 14px; display: grid; gap: 10px; }
.nl-timeline li { border-left: 3px solid var(--honey); padding: 2px 0 2px 12px; }

/* ---------- screening scorecard ---------- */
.score-list { display: grid; gap: 8px; margin-bottom: 14px; }
.score-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface-2); }
.score-pick { display: inline-flex; gap: 4px; }
.score-pick label { position: relative; }
.score-pick input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.score-pick span { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 8px; border: 1px solid var(--border-strong); background: var(--surface); font-weight: 600; font-size: 13.5px; color: var(--text-2); }
.score-pick input:checked + span { background: var(--accent); color: #15241F; border-color: var(--accent-strong); }
.score-pick input:focus-visible + span { outline: 2px solid var(--focus); outline-offset: 2px; }
.score-pick input:disabled + span { opacity: .6; }
@media (max-width: 520px) { .score-row { grid-template-columns: minmax(0, 1fr); } }

/* ---------- prospects ---------- */
.pr-list { display: grid; gap: 12px; }
.pr-card { background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px 18px; display: grid; gap: 6px; }
.pr-who { display: grid; gap: 2px; min-width: 0; }
.pr-who a.primary-cell { color: var(--text); text-decoration: none; }
.pr-who a.primary-cell:hover { text-decoration: underline; }
.pr-who a.primary-cell svg { width: 13px; height: 13px; vertical-align: -1px; opacity: .6; }
.pr-next { margin: 2px 0 4px; font-size: 14px; }
.pr-actions { flex-wrap: wrap; gap: 6px; }
.pr-templates details { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 8px 12px; margin-bottom: 8px; }
.pr-templates summary { cursor: pointer; font-weight: 600; font-size: 13.5px; }
.pr-templates pre { white-space: pre-wrap; margin: 8px 0; }
#pr-prio { height: 36px; border-radius: 8px; }

/* Prospects, All tab: one header row per category */
.table tr.pr-group th { text-align: left; font-size: .8125rem; font-weight: 600; letter-spacing: .02em; padding-top: 1.1rem; background: transparent; cursor: default; }
.pr-filters { display: flex; flex-wrap: wrap; gap: .5rem; }
.pr-filters select { width: auto; min-width: 11rem; flex: 0 1 auto; }

.form fieldset { border: 0; padding: 0; margin: 0; display: grid; gap: 8px; }
.form legend { font-weight: 600; margin-bottom: 6px; padding: 0; }

/* ---------- Admin → Automated emails ---------- */
.me[role="button"] { cursor: pointer; border-radius: 8px; padding: 4px; margin: -4px; }
.me[role="button"]:hover { background: var(--hover); }
.me[role="button"]:focus-visible { outline: 2px solid var(--honey); outline-offset: 2px; }
.table-wrap.flat { box-shadow: none; border-radius: 0; }
.em-table td { vertical-align: top; }
.em-steps { margin: 8px 0 14px; padding-left: 20px; display: grid; gap: 6px; }
.em-conds, .em-when { border: 0; padding: 0; margin: 0; display: grid; gap: 8px; }
.em-when { padding: 12px 14px; border-radius: var(--radius-sm); background: var(--surface-2); }
.em-wait { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.em-when .em-wait input[type="number"] { width: 76px; } /* beats the shared full-width input rule */
.em-when .em-wait select { width: auto; }
.em-when .em-wait .check { margin-left: 6px; }
.em-when .check { display: flex; gap: 8px; align-items: center; font-weight: 500; }
#ed-when-hint { font-weight: 600; color: var(--text); }
.em-conds .check { display: flex; gap: 8px; align-items: flex-start; font-weight: 400; }
/* On/off switch: a real checkbox, drawn as a pill. */
.switch { position: relative; display: inline-flex; width: 38px; height: 22px; flex: none; cursor: pointer; }
.switch input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.switch span { position: absolute; inset: 0; border-radius: 999px; background: var(--border-strong); transition: background .15s; pointer-events: none; }
.switch span::after { content: ''; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: var(--shadow-sm); transition: transform .15s; }
.switch input:checked + span { background: var(--green); }
.switch input:checked + span::after { transform: translateX(16px); }
.switch input:focus-visible + span { outline: 2px solid var(--honey); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { .switch span, .switch span::after { transition: none; } }

/* Recruiting → Skill words */
.skill-row select { width: auto; min-width: 200px; }
.sk-add { align-items: flex-end; }
.sk-add label { flex: 1 1 200px; }


/* "More" menu in a page header (Prospects): the rarely used buttons, out of the way */
.more-menu { position: relative; }
.more-menu > summary { list-style: none; }
.more-menu > summary::-webkit-details-marker { display: none; }
.more-pop { position: absolute; right: 0; top: calc(100% + 6px); z-index: 20; display: grid; gap: 2px; min-width: 230px; padding: 6px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); box-shadow: var(--shadow); }
.more-pop .btn { justify-content: flex-start; width: 100%; }

/* LinkedIn site → People (22 Oct 2026): the step row, then one line per person */
.step-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 4px 0 6px; }
.step-row .step-arrow { color: var(--muted); }
.step-row .step-ends { display: flex; gap: 6px; margin-left: auto; }
.step-row .small-chip { height: 26px; padding: 0 10px; font-size: 12px; }
.step-hint { margin: 0 0 12px; }
.people-list { display: grid; gap: 8px; }
.person-line { display: grid; gap: 4px; width: 100%; text-align: left; background: var(--surface); border: 1px solid transparent; border-radius: var(--radius); box-shadow: var(--shadow); padding: 12px 16px; color: var(--text); font: inherit; cursor: pointer; }
.person-line:hover, .person-line:focus-visible { border-color: var(--honey); }
.person-line .pl-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.person-line .who { font-weight: 600; color: var(--green); }
.person-line .who.you { color: var(--honey-dark, var(--text)); }
/* tasks (Teamtailor study phase 3) */
.task-list { display: grid; gap: 8px; }
.task { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border: 1px solid var(--border-strong); border-radius: var(--radius-sm); }
.task.done b { text-decoration: line-through; color: var(--muted); }
.task .grow { flex: 1; min-width: 0; }
.list-item input[type=checkbox] { flex: none; width: 18px; height: 18px; margin: 0 4px; }
.saved-filter { display: inline-flex; align-items: center; }
#more-filters { flex-wrap: wrap; gap: 8px; }
/* Admin → Task templates (phase 4) */
.tt-list { display: grid; gap: 10px; margin-top: 10px; }
.tt-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; }
.tt-row .grow { flex: 1 1 240px; }
.tt-row .tt-days { width: 120px; }
.tt-row .check { margin-bottom: 8px; }
.tt-new { margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--border-strong); }
