@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Manrope:wght@500;600;700;800&display=swap');

:root {
  --bg: #020d25;
  --bg-deep: #010718;
  --surface: #061633;
  --surface-2: #0a2045;
  --surface-3: #0d2a56;
  --line: #173867;
  --line-soft: rgba(109, 165, 237, .15);
  --text: #f4f8f8;
  --muted: #9dacc5;
  --muted-2: #7084a6;
  --accent: #43c7ff;
  --accent-soft: rgba(67, 199, 255, .13);
  --green: #2e91ff;
  --green-soft: rgba(46, 145, 255, .13);
  --orange: #f2ab4e;
  --orange-soft: rgba(242, 171, 78, .12);
  --red: #ff6b78;
  --red-soft: rgba(255, 107, 120, .12);
  --violet: #a692ff;
  --shadow: 0 22px 60px rgba(0, 0, 0, .24);
  --sidebar: 264px;
}

* { box-sizing: border-box; }
html { background: var(--bg); color-scheme: dark; }
body { margin: 0; min-width: 320px; min-height: 100vh; background: radial-gradient(circle at 80% -10%, rgba(37, 124, 255, .13), transparent 29%), var(--bg); color: var(--text); font-family: 'DM Sans', Arial, sans-serif; -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
button, a, input, select, textarea { -webkit-tap-highlight-color: transparent; }
svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon-sprite { position: fixed; width: 0; height: 0; overflow: hidden; }

.auth-screen { min-height: 100vh; display: grid; place-items: center; padding: 22px; background: radial-gradient(circle at 50% 0, rgba(43,142,244,.2), transparent 38%), var(--bg-deep); }
.auth-card { width: min(430px,100%); padding: 34px; border: 1px solid var(--line); border-radius: 24px; background: linear-gradient(150deg,rgba(11,34,75,.98),rgba(3,18,46,.98)); box-shadow: 0 30px 90px rgba(0,0,0,.45); }
.auth-card > img { display: block; width: min(220px,68%); height: auto; margin: 0 0 28px; object-fit: contain; object-position: left center; }
.auth-card h1 { margin: 12px 0 8px; font: 800 30px/1.08 'Manrope',sans-serif; letter-spacing: -.04em; }
.auth-card > p,.auth-card form > small,#passwordMessage { color: var(--muted); font-size: 11px; line-height: 1.6; }
.auth-card label { display: block; margin-top: 17px; color: var(--muted); font-size: 9px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.auth-card input { width: 100%; margin-top: 7px; padding: 13px; border: 1px solid var(--line); border-radius: 11px; outline: 0; background: var(--bg-deep); color: var(--text); text-transform: none; }
.auth-card input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.auth-card form > button { width: 100%; margin-top: 22px; }
.auth-card form > small { min-height: 20px; display: block; margin-top: 10px; color: var(--red); text-align: center; }
.access-panel { margin-top: 14px; }
.row-actions { display: flex; flex-wrap: wrap; gap: 6px; }
.row-actions button { padding: 6px 9px; border: 1px solid var(--line); border-radius: 8px; background: transparent; color: var(--accent); font-size: 7px; font-weight: 800; }
.status-pill { display: inline-flex; padding: 4px 8px; border-radius: 30px; background: var(--green-soft); color: var(--green); font-size: 7px; font-weight: 800; }
.status-pill.suspended { background: var(--red-soft); color: var(--red); }

.app-shell { min-height: 100vh; }
.sidebar { position: fixed; inset: 0 auto 0 0; z-index: 50; width: var(--sidebar); display: flex; flex-direction: column; border-right: 1px solid var(--line-soft); background: rgba(1, 9, 30, .95); backdrop-filter: blur(20px); }
.brand { height: 82px; display: flex; align-items: center; gap: 12px; padding: 0 20px; border-bottom: 1px solid var(--line-soft); }
.brand .brand-wordmark { width: 111px; height: auto; flex: 0 0 111px; object-fit: contain; object-position: left center; }
.brand div { min-width: 0; }
.brand strong, .brand span { display: block; }
.brand strong { font: 800 15px/1.2 'Manrope', sans-serif; letter-spacing: -.02em; }
.brand span { margin-top: 4px; color: var(--muted-2); font-size: 9px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.sidebar-close { display: none; margin-left: auto; border: 0; background: transparent; color: var(--muted); font-size: 28px; }
.nav { flex: 1; overflow-y: auto; padding: 22px 12px; }
.nav-label { margin: 22px 12px 8px; color: #52686c; font-size: 9px; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; }
.nav-label:first-child { margin-top: 0; }
.nav-item { position: relative; width: 100%; min-height: 44px; display: flex; align-items: center; gap: 12px; padding: 0 12px; border: 1px solid transparent; border-radius: 12px; background: transparent; color: #82969a; font-size: 13px; font-weight: 600; text-align: left; transition: .18s ease; }
.nav-item svg { width: 18px; height: 18px; }
.nav-item:hover { color: var(--text); background: rgba(255,255,255,.025); }
.nav-item.active { border-color: rgba(67,199,255,.16); background: linear-gradient(90deg, rgba(19,101,214,.22), rgba(67,199,255,.09)); color: var(--accent); box-shadow: inset 3px 0 var(--accent); }
.nav-badge { min-width: 20px; margin-left: auto; padding: 2px 6px; border-radius: 20px; background: var(--accent-soft); color: var(--accent); font-size: 9px; font-style: normal; font-weight: 800; text-align: center; }
.nav-badge.warning { background: var(--orange-soft); color: var(--orange); }
.nav-badge.danger { background: var(--red-soft); color: var(--red); }
.nav-badge.owner { background: rgba(166,146,255,.12); color: var(--violet); font-size: 6px; letter-spacing: .08em; }
.sidebar-foot { padding: 10px 12px 14px; border-top: 1px solid var(--line-soft); }
.privacy-seal { display: flex; align-items: center; gap: 10px; margin: 0 3px 10px; padding: 10px 11px; border: 1px solid var(--line-soft); border-radius: 12px; background: rgba(255,255,255,.02); }
.privacy-seal > span { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 5px var(--green-soft); }
.privacy-seal b, .privacy-seal small { display: block; }
.privacy-seal b { font-size: 10px; }
.privacy-seal small { margin-top: 2px; color: var(--muted-2); font-size: 8px; }
.profile-mini { width: 100%; display: flex; align-items: center; gap: 10px; padding: 10px; border: 0; border-radius: 13px; background: transparent; color: var(--text); text-align: left; }
.profile-mini:hover { background: rgba(255,255,255,.03); }
.profile-mini > span:nth-child(2) { min-width: 0; flex: 1; }
.profile-mini b, .profile-mini small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.profile-mini b { font-size: 11px; }
.profile-mini small { margin-top: 2px; color: var(--muted-2); font-size: 9px; }
.profile-mini svg { width: 14px; color: var(--muted-2); }
.avatar { width: 35px; height: 35px; display: grid; place-items: center; border: 1px solid rgba(67,199,255,.28); border-radius: 50%; background: linear-gradient(135deg, #123d7a, #071c43); color: var(--accent); font: 800 11px 'Manrope', sans-serif; }

.main-column { min-height: 100vh; padding-left: var(--sidebar); }
.topbar { position: sticky; top: 0; z-index: 40; height: 82px; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 0 34px; border-bottom: 1px solid var(--line-soft); background: rgba(2, 13, 37, .88); backdrop-filter: blur(20px); }
.topbar-title { display: flex; align-items: center; gap: 12px; }
.topbar-title small, .topbar-title strong { display: block; }
.topbar-title small { color: var(--muted-2); font-size: 8px; font-weight: 800; letter-spacing: .14em; }
.topbar-title strong { margin-top: 4px; font: 700 14px 'Manrope', sans-serif; }
.menu-button { display: none; width: 40px; height: 40px; place-items: center; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--text); }
.topbar-actions { display: flex; align-items: center; gap: 9px; }
.search { width: min(28vw, 320px); height: 42px; display: flex; align-items: center; gap: 9px; padding: 0 12px; border: 1px solid var(--line-soft); border-radius: 12px; background: rgba(8, 28, 66, .74); color: var(--muted); }
.search svg { width: 16px; }
.search input { min-width: 0; flex: 1; border: 0; outline: 0; background: transparent; color: var(--text); font-size: 11px; }
.search input::placeholder { color: #52676b; }
.search kbd { padding: 3px 6px; border: 1px solid var(--line); border-radius: 5px; background: var(--bg-deep); color: var(--muted-2); font-size: 8px; }
.icon-button { position: relative; width: 42px; height: 42px; display: grid; place-items: center; border: 1px solid var(--line-soft); border-radius: 12px; background: var(--surface); color: var(--muted); }
.notification-dot { position: absolute; top: 9px; right: 9px; width: 6px; height: 6px; border: 2px solid var(--surface); border-radius: 50%; background: var(--red); }
.primary-button, .secondary-button, .date-button { min-height: 42px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 0 16px; border-radius: 12px; font-size: 11px; font-weight: 800; }
.primary-button { border: 1px solid var(--accent); background: linear-gradient(135deg, #56d4ff, #258ef2); color: #020d25; box-shadow: 0 9px 24px rgba(43, 142, 244, .22); }
.primary-button:hover { filter: brightness(1.08); transform: translateY(-1px); }
.primary-button svg, .secondary-button svg, .date-button svg { width: 16px; }
.secondary-button, .date-button { border: 1px solid var(--line); background: var(--surface); color: var(--text); }
.secondary-button:hover, .date-button:hover { border-color: rgba(67,199,255,.4); color: var(--accent); }

.content { width: 100%; max-width: 1600px; margin: 0 auto; padding: 34px; }
.view { display: none; animation: viewIn .25s ease; }
.view.active { display: block; }
@keyframes viewIn { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: none; } }
.welcome-row, .page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 24px; }
.eyebrow-pill { display: inline-flex; align-items: center; gap: 7px; color: var(--accent); font-size: 8px; font-weight: 800; letter-spacing: .15em; }
.eyebrow-pill i { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 5px var(--accent-soft); }
.welcome-row h1, .page-heading h1 { margin: 12px 0 6px; font: 800 clamp(27px, 3.1vw, 42px)/1.05 'Manrope', sans-serif; letter-spacing: -.045em; }
.welcome-row p, .page-heading p { max-width: 670px; margin: 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.heading-actions { display: flex; align-items: center; gap: 9px; }
.select { min-height: 42px; padding: 0 38px 0 13px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--text); font-size: 11px; outline: 0; }

.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.metric-card { position: relative; min-height: 138px; overflow: hidden; padding: 19px; border: 1px solid var(--line-soft); border-radius: 17px; background: linear-gradient(150deg, rgba(11,34,75,.92), rgba(3,18,46,.94)); box-shadow: 0 14px 34px rgba(0,0,0,.12); }
.metric-card::after { content: ''; position: absolute; right: -28px; bottom: -35px; width: 100px; height: 100px; border-radius: 50%; background: var(--glow, rgba(67,199,255,.07)); filter: blur(4px); }
.metric-card .metric-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.metric-card span { color: var(--muted); font-size: 10px; font-weight: 600; }
.metric-card .metric-icon { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; background: var(--tone, var(--accent-soft)); color: var(--color, var(--accent)); }
.metric-card .metric-icon svg { width: 16px; }
.metric-card strong { display: block; margin-top: 18px; font: 800 28px/1 'Manrope', sans-serif; letter-spacing: -.04em; }
.metric-card small { display: block; margin-top: 8px; color: var(--muted-2); font-size: 9px; }
.metric-card small b { color: var(--color, var(--accent)); }

.panel { border: 1px solid var(--line-soft); border-radius: 18px; background: linear-gradient(145deg, rgba(7,27,64,.96), rgba(3,17,44,.94)); box-shadow: 0 18px 48px rgba(0,0,0,.14); }
.panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.panel-kicker { display: block; margin-bottom: 7px; color: var(--accent); font-size: 8px; font-weight: 800; letter-spacing: .16em; }
.panel h2 { margin: 0; font: 700 17px 'Manrope', sans-serif; letter-spacing: -.025em; }
.panel-head p { margin: 5px 0 0; color: var(--muted-2); font-size: 10px; }
.home-layout { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(280px, .65fr); gap: 14px; margin-top: 14px; }
.focus-panel, .agenda-card, .portfolio-strip, .chart-panel, .alerts-panel, .traffic-table-panel, .calendar-panel, .day-agenda { padding: 21px; }
.text-button { display: inline-flex; align-items: center; gap: 5px; padding: 7px 0; border: 0; background: transparent; color: var(--accent); font-size: 10px; font-weight: 700; white-space: nowrap; }
.text-button svg { width: 13px; }
.priority-list { margin-top: 17px; }
.priority-item { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; padding: 13px 0; border-top: 1px solid var(--line-soft); }
.priority-check { width: 22px; height: 22px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 7px; background: transparent; color: transparent; }
.priority-check:hover { border-color: var(--green); color: var(--green); }
.priority-item.done { opacity: .5; }
.priority-item.done .priority-check { border-color: var(--green); background: var(--green-soft); color: var(--green); }
.priority-item.done .priority-copy b { text-decoration: line-through; }
.complete-task-button { padding: 6px 9px!important; border: 1px solid rgba(53,210,139,.34)!important; border-radius: 8px; background: rgba(53,210,139,.1)!important; color: var(--green)!important; }
.completion-badge { color: var(--green); font-weight: 900; letter-spacing: .04em; }
.task-card.is-done { border-color: rgba(53,210,139,.3); background: linear-gradient(140deg, rgba(10,66,57,.56), #051f31); }
.task-card.is-done h3 { text-decoration: line-through; text-decoration-color: rgba(53,210,139,.65); }
.priority-copy { min-width: 0; }
.priority-copy b, .priority-copy small { display: block; }
.priority-copy b { overflow: hidden; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.priority-copy small { margin-top: 5px; color: var(--muted-2); font-size: 9px; }
.priority-meta { text-align: right; }
.priority-meta span, .priority-meta small { display: block; }
.priority-meta span { font-size: 9px; font-weight: 700; }
.priority-meta small { margin-top: 4px; color: var(--muted-2); font-size: 8px; }
.priority-meta.overdue span { color: var(--red); }
.priority-meta.today span { color: var(--orange); }
.today-chip { padding: 5px 9px; border: 1px solid rgba(67,199,255,.24); border-radius: 20px; background: var(--accent-soft); color: var(--accent); font-size: 8px; font-weight: 800; }
.agenda-event { position: relative; display: grid; grid-template-columns: 42px 1fr; gap: 12px; padding: 16px 0 16px 13px; border-bottom: 1px solid var(--line-soft); }
.agenda-event::before { content: ''; position: absolute; left: 0; top: 19px; width: 3px; height: 35px; border-radius: 4px; background: var(--event-color, var(--accent)); }
.agenda-event time { color: var(--muted); font-size: 9px; font-weight: 800; }
.agenda-event b, .agenda-event small { display: block; }
.agenda-event b { font-size: 10px; }
.agenda-event small { margin-top: 5px; color: var(--muted-2); font-size: 8px; }
.panel-action { width: 100%; min-height: 40px; margin-top: 16px; border: 1px solid var(--line); border-radius: 11px; background: transparent; color: var(--muted); font-size: 9px; font-weight: 800; }
.panel-action:hover { border-color: var(--accent); color: var(--accent); }
.portfolio-strip { margin-top: 14px; }
.client-health-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 18px; }
.health-card { display: flex; align-items: center; gap: 11px; padding: 13px; border: 1px solid var(--line-soft); border-radius: 13px; background: rgba(255,255,255,.015); }
.health-logo, .client-logo { width: 36px; height: 36px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 11px; background: var(--logo-bg, #102c60); color: var(--logo-color, var(--accent)); font: 800 10px 'Manrope', sans-serif; }
.health-card div:nth-child(2) { min-width: 0; flex: 1; }
.health-card b, .health-card small { display: block; }
.health-card b { overflow: hidden; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.health-card small { margin-top: 4px; color: var(--muted-2); font-size: 8px; }
.health-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); }
.health-dot.attention { background: var(--orange); }

.task-summary { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 16px; }
.summary-card { display: flex; align-items: center; gap: 12px; padding: 15px; border: 1px solid var(--line-soft); border-radius: 14px; background: var(--surface); }
.summary-card i { width: 8px; height: 34px; border-radius: 5px; background: var(--tone); }
.summary-card strong, .summary-card span { display: block; }
.summary-card strong { font: 800 21px 'Manrope', sans-serif; }
.summary-card span { margin-top: 2px; color: var(--muted); font-size: 9px; }
.kanban { display: grid; grid-template-columns: repeat(4, minmax(255px, 1fr)); gap: 12px; overflow-x: auto; padding-bottom: 12px; scroll-snap-type: x proximity; }
.kanban-column { min-height: 480px; padding: 12px; border: 1px solid var(--line-soft); border-radius: 16px; background: rgba(1,10,29,.4); scroll-snap-align: start; }
.kanban-column.drag-over { border-color: var(--accent); background: rgba(67,199,255,.05); }
.kanban-head { display: flex; align-items: center; justify-content: space-between; padding: 4px 4px 13px; }
.kanban-head div { display: flex; align-items: center; gap: 8px; }
.kanban-head i { width: 7px; height: 7px; border-radius: 50%; background: var(--column-color); box-shadow: 0 0 0 5px color-mix(in srgb, var(--column-color) 12%, transparent); }
.kanban-head b { font-size: 10px; }
.kanban-head span { min-width: 21px; padding: 3px 6px; border-radius: 20px; background: rgba(255,255,255,.045); color: var(--muted); font-size: 8px; font-weight: 800; text-align: center; }
.task-card, .client-card { margin-bottom: 9px; padding: 14px; border: 1px solid var(--line-soft); border-radius: 13px; background: linear-gradient(140deg, var(--surface-2), #051736); box-shadow: 0 10px 20px rgba(0,0,0,.1); transition: .18s ease; }
.task-card { cursor: grab; }
.task-card:hover, .client-card:hover { border-color: rgba(67,199,255,.32); transform: translateY(-2px); }
.task-card.dragging, .client-card.dragging { opacity: .35; }
.task-card-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.priority-label { display: inline-flex; align-items: center; gap: 5px; color: var(--priority-color); font-size: 7px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.priority-label::before { content: ''; width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.card-menu { border: 0; background: transparent; color: var(--muted-2); letter-spacing: 2px; }
.task-card h3, .client-card h3 { margin: 11px 0 9px; font: 700 11px/1.45 'Manrope', sans-serif; }
.task-client { display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: 8px; }
.task-client span { width: 20px; height: 20px; display: grid; place-items: center; border-radius: 6px; background: var(--accent-soft); color: var(--accent); font-size: 6px; font-weight: 800; }
.task-card footer { display: flex; align-items: center; justify-content: space-between; gap: 9px; margin-top: 13px; padding-top: 11px; border-top: 1px solid var(--line-soft); color: var(--muted-2); font-size: 8px; }
.due-date { display: flex; align-items: center; gap: 5px; }
.due-date svg { width: 11px; }
.due-date.overdue { color: var(--red); }
.task-card footer button { border: 0; background: transparent; color: var(--accent); font-size: 8px; font-weight: 800; }
.focus-mode .kanban-column:not(:nth-child(2)) { display: none; }
.focus-mode .kanban { grid-template-columns: minmax(280px, 680px); justify-content: center; }

.performance-hero { display: grid; grid-template-columns: 300px minmax(0,1fr); gap: 14px; }
.performance-score { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 300px; padding: 24px; border: 1px solid rgba(67,199,255,.2); border-radius: 18px; background: radial-gradient(circle at 50% 38%, rgba(43,142,244,.2), transparent 38%), linear-gradient(145deg, #0a2552, #03132f); text-align: center; }
.score-ring { position: relative; width: 136px; height: 136px; display: grid; place-items: center; margin: 13px auto 18px; border-radius: 50%; background: conic-gradient(var(--accent) calc(var(--score) * 1%), rgba(255,255,255,.07) 0); }
.score-ring::before { content: ''; position: absolute; inset: 8px; border-radius: 50%; background: #071b3d; box-shadow: inset 0 0 28px rgba(0,0,0,.25); }
.score-ring strong, .score-ring small { position: relative; z-index: 1; }
.score-ring strong { margin-left: 9px; font: 800 37px 'Manrope',sans-serif; }
.score-ring small { position: absolute; left: 85px; top: 68px; color: var(--muted-2); font-size: 8px; }
.performance-score h2 { margin: 0; font: 700 16px 'Manrope',sans-serif; }
.performance-score p { max-width: 235px; margin: 7px auto 0; color: var(--muted); font-size: 9px; line-height: 1.55; }
.performance-metrics { display: grid; grid-template-columns: repeat(2,1fr); gap: 10px; }
.performance-metric { min-height: 145px; padding: 19px; border: 1px solid var(--line-soft); border-radius: 16px; background: linear-gradient(145deg, rgba(10,32,69,.94), rgba(4,19,47,.95)); }
.performance-metric header { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.performance-metric header span { color: var(--muted); font-size: 9px; }
.performance-metric header i { width: 7px; height: 7px; margin-top: 3px; border-radius: 50%; background: var(--metric-color); box-shadow: 0 0 0 5px color-mix(in srgb, var(--metric-color) 13%, transparent); }
.performance-metric strong { display: block; margin-top: 20px; font: 800 26px 'Manrope',sans-serif; }
.performance-metric small { display: block; margin-top: 6px; color: var(--muted-2); font-size: 8px; line-height: 1.4; }
.performance-metric small b { color: var(--metric-color); }
.performance-layout { display: grid; grid-template-columns: minmax(0,1.5fr) minmax(290px,.5fr); gap: 14px; margin-top: 14px; }
.retention-panel, .performance-insights, .portfolio-retention { padding: 21px; }
.retention-chart { height: 220px; display: flex; align-items: flex-end; gap: 8px; margin-top: 30px; padding: 0 7px 24px; border-bottom: 1px solid var(--line); background: repeating-linear-gradient(to bottom, var(--line-soft) 0 1px, transparent 1px 54px); }
.retention-bar { position: relative; flex: 1; min-width: 14px; border-radius: 6px 6px 2px 2px; background: linear-gradient(to top, #155bbb, #4bcaff); box-shadow: 0 0 16px rgba(43,142,244,.12); }
.retention-bar span { position: absolute; left: 50%; bottom: -21px; color: var(--muted-2); font-size: 7px; transform: translateX(-50%); }
.retention-bar b { position: absolute; top: -17px; left: 50%; color: var(--muted); font-size: 7px; transform: translateX(-50%); }
.insight-item { display: grid; grid-template-columns: 31px 1fr; gap: 10px; padding: 14px 0; border-bottom: 1px solid var(--line-soft); }
.insight-item > span { width: 31px; height: 31px; display: grid; place-items: center; border-radius: 9px; background: var(--insight-bg); color: var(--insight-color); }
.insight-item svg { width: 14px; }
.insight-item b { display: block; font-size: 9px; }
.insight-item p { margin: 4px 0 0; color: var(--muted-2); font-size: 8px; line-height: 1.45; }
.portfolio-retention { margin-top: 14px; }

.admin-banner { display: flex; align-items: center; gap: 13px; margin-bottom: 14px; padding: 14px 16px; border: 1px solid rgba(166,146,255,.18); border-radius: 14px; background: rgba(166,146,255,.07); }
.admin-banner svg { flex: 0 0 auto; color: var(--violet); }
.admin-banner b, .admin-banner span { display: block; }
.admin-banner b { font-size: 10px; }
.admin-banner span { margin-top: 4px; color: var(--muted); font-size: 9px; }
.owner-pill { color: var(--violet); }
.owner-pill i { background: var(--violet); box-shadow: 0 0 0 5px rgba(166,146,255,.12); }
.team-metrics { display: grid; grid-template-columns: repeat(4,1fr); gap: 10px; }
.team-metric { padding: 17px; border: 1px solid var(--line-soft); border-radius: 15px; background: var(--surface); }
.team-metric span, .team-metric strong, .team-metric small { display: block; }
.team-metric span { color: var(--muted); font-size: 9px; }
.team-metric strong { margin-top: 13px; font: 800 23px 'Manrope',sans-serif; }
.team-metric small { margin-top: 5px; color: var(--muted-2); font-size: 8px; }
.team-layout { display: grid; grid-template-columns: minmax(0,1.4fr) minmax(300px,.6fr); gap: 14px; margin-top: 14px; }
.team-panel, .onboarding-panel, .admin-task-table { padding: 21px; }
.manager-cards { display: grid; grid-template-columns: repeat(2,1fr); gap: 10px; margin-top: 17px; }
.manager-card { padding: 15px; border: 1px solid var(--line-soft); border-radius: 14px; background: rgba(255,255,255,.018); }
.manager-card header { display: flex; align-items: center; gap: 10px; }
.manager-card header > div { min-width: 0; flex: 1; }
.manager-card header b, .manager-card header small { display: block; }
.manager-card header b { font-size: 10px; }
.manager-card header small { margin-top: 3px; color: var(--muted-2); font-size: 8px; }
.manager-card .manager-status { width: 7px; height: 7px; border-radius: 50%; background: var(--green); }
.manager-stat-row { display: grid; grid-template-columns: repeat(3,1fr); gap: 6px; margin-top: 13px; }
.manager-stat-row div { padding: 8px; border-radius: 9px; background: rgba(255,255,255,.025); }
.manager-stat-row span, .manager-stat-row b { display: block; }
.manager-stat-row span { color: var(--muted-2); font-size: 6px; text-transform: uppercase; }
.manager-stat-row b { margin-top: 4px; font-size: 9px; }
.manager-card footer { display: flex; justify-content: space-between; margin-top: 11px; padding-top: 10px; border-top: 1px solid var(--line-soft); color: var(--muted-2); font-size: 7px; }
.manager-card footer b { color: var(--red); }
.onboarding-admin-item { padding: 13px 0; border-bottom: 1px solid var(--line-soft); }
.onboarding-admin-item header { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.onboarding-admin-item b { font-size: 9px; }
.onboarding-admin-item small { color: var(--muted-2); font-size: 7px; }
.progress-track { height: 5px; margin-top: 9px; overflow: hidden; border-radius: 5px; background: rgba(255,255,255,.05); }
.progress-track i { display: block; height: 100%; border-radius: 5px; background: linear-gradient(90deg,#258ef2,#53ceff); }
.admin-task-table { margin-top: 14px; }

.client-detail-drawer { width: min(680px,100vw); overflow-y: auto; }
.client-drawer-summary { display: flex; align-items: center; gap: 11px; margin: 20px 0 6px; padding: 13px; border: 1px solid var(--line-soft); border-radius: 13px; background: rgba(255,255,255,.018); }
.client-drawer-summary > div { min-width: 0; flex: 1; }
.client-drawer-summary b, .client-drawer-summary small { display: block; }
.client-drawer-summary b { font-size: 10px; }
.client-drawer-summary small { margin-top: 4px; color: var(--muted-2); font-size: 8px; }
.client-tabs { position:sticky; top:-24px; z-index:3; display:grid; grid-template-columns:repeat(3,1fr); gap:6px; margin:14px -2px 18px; padding:9px 2px; background:rgba(2,12,34,.97); backdrop-filter:blur(14px); }
.client-tabs button { min-height:38px; border:1px solid var(--line-soft); border-radius:10px; background:var(--surface); color:var(--muted); font-size:9px; font-weight:800; }
.client-tabs button span { min-width:18px; margin-left:4px; padding:2px 5px; border-radius:20px; background:rgba(255,255,255,.06); }
.client-tabs button.active { border-color:rgba(67,199,255,.5); background:var(--accent-soft); color:var(--accent); }
.client-tab-pane { animation:viewIn .2s ease; }
.drawer-section-head { margin:4px 0 16px; }
.drawer-section-head h3 { margin:5px 0 0; font:700 17px 'Manrope',sans-serif; }
.drawer-section-head p { margin:6px 0 0; color:var(--muted); font-size:9px; line-height:1.55; }
.inline-record-form { margin-bottom:18px; padding:16px; border:1px solid var(--line-soft); border-radius:14px; background:rgba(255,255,255,.018); }
.inline-record-form>label,.inline-record-form .form-grid label { display:block; color:var(--muted); font-size:8px; font-weight:800; letter-spacing:.04em; text-transform:uppercase; }
.inline-record-form input,.inline-record-form select,.inline-record-form textarea { width:100%; margin-top:7px; padding:11px 12px; border:1px solid var(--line); border-radius:10px; outline:0; background:var(--bg); color:var(--text); font-size:10px; text-transform:none; }
.inline-record-form>label { margin-top:13px; }
.full-button { width:100%; margin-top:14px; }
.creative-history,.activity-timeline { display:grid; gap:9px; }
.creative-record { padding:14px; border:1px solid var(--line-soft); border-radius:13px; background:linear-gradient(145deg,rgba(10,34,73,.92),rgba(4,19,47,.94)); }
.creative-record header { display:flex; align-items:center; gap:11px; }
.creative-record header>div { min-width:0; }
.creative-record b,.creative-record small { display:block; }
.creative-record b { font-size:10px; line-height:1.45; }
.creative-record small { margin-top:4px; color:var(--muted-2); font-size:8px; }
.creative-record a { display:inline-block; margin-top:11px; color:var(--accent); font-size:8px; font-weight:800; }
.creative-quantity { width:38px; height:38px; display:grid; place-items:center; flex:0 0 auto; border-radius:11px; background:var(--accent-soft); color:var(--accent); font:800 15px 'Manrope',sans-serif; }
.daily-check-button { width:100%; display:flex; align-items:center; gap:12px; margin-bottom:12px; padding:14px; border:1px solid rgba(53,210,139,.34); border-radius:14px; background:rgba(53,210,139,.09); color:var(--text); text-align:left; }
.daily-check-button>span { width:36px; height:36px; display:grid; place-items:center; flex:0 0 auto; border-radius:50%; background:rgba(53,210,139,.17); color:var(--green); font-size:18px; font-weight:900; }
.daily-check-button b,.daily-check-button small { display:block; }
.daily-check-button b { font-size:10px; }
.daily-check-button small { margin-top:4px; color:var(--muted); font-size:8px; line-height:1.4; }
.daily-check-button.done { border-color:rgba(53,210,139,.58); background:rgba(53,210,139,.16); }
.daily-check-button:disabled { cursor:default; opacity:1; }
.timeline-record { position:relative; display:grid; grid-template-columns:12px 1fr; gap:10px; padding:12px 0; border-bottom:1px solid var(--line-soft); }
.timeline-record>i { width:9px; height:9px; margin-top:3px; border-radius:50%; background:var(--accent); box-shadow:0 0 0 5px var(--accent-soft); }
.timeline-record.daily_check>i { background:var(--green); box-shadow:0 0 0 5px rgba(53,210,139,.1); }
.timeline-record.creative_paused>i { background:var(--red); box-shadow:0 0 0 5px rgba(255,107,120,.1); }
.timeline-record span,.timeline-record b { display:block; }
.timeline-record span { color:var(--muted-2); font-size:7px; font-weight:800; letter-spacing:.08em; }
.timeline-record b { margin-top:5px; font-size:10px; }
.timeline-record p { margin:5px 0 0; color:var(--muted); font-size:9px; line-height:1.5; white-space:pre-wrap; }
.manager-score { width:42px; height:42px; display:grid; place-items:center; flex:0 0 auto; border-radius:50%; background:conic-gradient(var(--green) calc(var(--manager-score)*1%),rgba(255,255,255,.07) 0); color:#fff; font:800 11px 'Manrope',sans-serif; box-shadow:inset 0 0 0 7px #0a224a; }
.client-detail-form > label, .client-detail-form .form-grid label { display: block; margin-top: 14px; color: var(--muted); font-size: 8px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; }
.client-detail-form input, .client-detail-form select, .client-detail-form textarea { width: 100%; margin-top: 7px; padding: 10px 11px; border: 1px solid var(--line); border-radius: 10px; outline: 0; background: var(--bg-deep); color: var(--text); font-size: 10px; text-transform: none; }
.client-detail-form input:focus, .client-detail-form select:focus, .client-detail-form textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.custom-fields-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-top: 22px; padding-top: 17px; border-top: 1px solid var(--line-soft); }
.custom-fields-head b, .custom-fields-head span { display: block; }
.custom-fields-head b { font-size: 10px; }
.custom-fields-head div span { margin-top: 4px; color: var(--muted-2); font-size: 8px; }
.custom-fields-head button { border: 0; background: transparent; color: var(--accent); font-size: 8px; font-weight: 800; }
.custom-field-row { display: grid; grid-template-columns: 150px 1fr auto; gap: 7px; align-items: end; margin-top: 9px; }
.custom-field-row input { margin: 0; }
.custom-field-row button { width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 9px; background: transparent; color: var(--red); }
.onboarding-checklist { margin-top: 20px; }
.onboarding-item { display: flex; align-items: center; gap: 10px; padding: 11px 0; border-bottom: 1px solid var(--line-soft); }
.onboarding-item input { width: 16px; height: 16px; margin: 0; accent-color: var(--accent); }
.onboarding-item div { min-width: 0; flex: 1; }
.onboarding-item b, .onboarding-item small { display: block; }
.onboarding-item b { font-size: 9px; }
.onboarding-item small { margin-top: 3px; color: var(--muted-2); font-size: 7px; }
.new-client-explainer { display: flex; align-items: center; gap: 9px; margin-top: 17px; padding: 11px; border: 1px solid rgba(67,199,255,.18); border-radius: 11px; background: var(--accent-soft); color: var(--muted); font-size: 8px; line-height: 1.45; }
.new-client-explainer svg { flex: 0 0 auto; color: var(--accent); }
.client-modal { width: min(670px,100%); }

.privacy-banner { display: flex; align-items: center; gap: 13px; margin-bottom: 16px; padding: 14px 16px; border: 1px solid rgba(67,199,255,.19); border-radius: 14px; background: var(--accent-soft); }
.privacy-banner svg { flex: 0 0 auto; color: var(--accent); }
.privacy-banner b, .privacy-banner span { display: block; }
.privacy-banner b { font-size: 10px; }
.privacy-banner span { margin-top: 3px; color: #83a4a8; font-size: 9px; line-height: 1.5; }
.client-board { grid-template-columns: repeat(4, minmax(270px, 1fr)); }
.client-card { cursor: grab; }
.client-card-header { display: flex; align-items: center; gap: 10px; }
.client-card-header > div:nth-child(2) { min-width: 0; flex: 1; }
.client-card-header h3 { margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.client-card-header small { display: block; margin-top: 3px; color: var(--muted-2); font-size: 8px; }
.client-status { width: 7px; height: 7px; border-radius: 50%; background: var(--green); }
.client-status.attention { background: var(--orange); }
.client-status.blocked { background: var(--red); }
.client-card-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; margin-top: 14px; }
.client-card-meta div { padding: 9px; border-radius: 9px; background: rgba(255,255,255,.025); }
.client-card-meta span, .client-card-meta b { display: block; }
.client-card-meta span { color: var(--muted-2); font-size: 7px; text-transform: uppercase; }
.client-card-meta b { margin-top: 5px; font-size: 9px; }
.client-next { margin-top: 10px; padding: 9px 10px; border-left: 2px solid var(--accent); border-radius: 0 8px 8px 0; background: rgba(67,199,255,.06); color: var(--muted); font-size: 8px; line-height: 1.5; }

.calendar-layout { display: grid; grid-template-columns: minmax(0, 1fr) 290px; gap: 14px; }
.calendar-toolbar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.calendar-toolbar button { width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 10px; background: transparent; color: var(--text); }
.calendar-toolbar h2 span { color: var(--muted-2); font-weight: 500; }
.calendar-week, .calendar-grid { display: grid; grid-template-columns: repeat(7, 1fr); }
.calendar-week span { padding-bottom: 10px; color: var(--muted-2); font-size: 7px; font-weight: 800; text-align: center; }
.calendar-day { position: relative; min-height: 82px; padding: 9px; border-top: 1px solid var(--line-soft); border-right: 1px solid var(--line-soft); color: var(--muted); font-size: 9px; }
.calendar-day:nth-child(7n) { border-right: 0; }
.calendar-day.outside { color: #3f5559; }
.calendar-day.today { background: rgba(67,199,255,.045); color: var(--accent); }
.calendar-day.today > b { width: 23px; height: 23px; display: grid; place-items: center; border-radius: 50%; background: var(--accent); color: var(--bg); }
.calendar-day .event-dot { display: block; overflow: hidden; margin-top: 7px; padding: 4px 5px; border-radius: 5px; background: var(--event-bg, var(--accent-soft)); color: var(--event-color, var(--accent)); font-size: 6px; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; }
.day-number { display: flex; align-items: center; gap: 10px; padding-bottom: 16px; border-bottom: 1px solid var(--line-soft); }
.day-number strong { font: 800 46px/1 'Manrope', sans-serif; color: var(--accent); }
.day-number span { color: var(--muted); font-size: 9px; font-weight: 800; line-height: 1.5; }
.day-agenda h2 { margin: 18px 0 3px; }
.day-agenda .agenda-event { grid-template-columns: 38px 1fr; }

.meeting-grid, .checkin-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.meeting-card, .checkin-card { padding: 18px; border: 1px solid var(--line-soft); border-radius: 16px; background: var(--surface); }
.meeting-card .meeting-date { width: 44px; height: 48px; display: grid; place-items: center; float: left; margin-right: 12px; border: 1px solid rgba(67,199,255,.24); border-radius: 11px; background: var(--accent-soft); color: var(--accent); }
.meeting-date b, .meeting-date span { display: block; text-align: center; }
.meeting-date b { font: 800 18px 'Manrope', sans-serif; }
.meeting-date span { font-size: 7px; font-weight: 800; }
.meeting-card h3, .checkin-card h3 { margin: 2px 0 5px; font: 700 12px 'Manrope', sans-serif; }
.meeting-card p, .checkin-card p { margin: 0; color: var(--muted); font-size: 9px; line-height: 1.55; }
.meeting-card footer { clear: both; display: flex; justify-content: space-between; margin-top: 22px; padding-top: 13px; border-top: 1px solid var(--line-soft); color: var(--muted-2); font-size: 8px; }
.meeting-card footer button { border: 0; background: transparent; color: var(--accent); font-size: 8px; font-weight: 800; }

.traffic-metrics { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin-bottom: 14px; }
.traffic-metric { padding: 17px; border: 1px solid var(--line-soft); border-radius: 15px; background: var(--surface); }
.traffic-metric span, .traffic-metric strong, .traffic-metric small { display: block; }
.traffic-metric span { color: var(--muted); font-size: 9px; }
.traffic-metric strong { margin-top: 13px; font: 800 22px 'Manrope', sans-serif; }
.traffic-metric small { margin-top: 5px; color: var(--green); font-size: 8px; }
.traffic-layout { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(280px, .55fr); gap: 14px; }
.status-live { display: inline-flex; align-items: center; gap: 6px; color: var(--green); font-size: 8px; font-weight: 800; }
.status-live i { width: 6px; height: 6px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 5px var(--green-soft); }
.bar-chart { height: 260px; display: flex; align-items: flex-end; gap: clamp(8px, 2.2vw, 28px); margin-top: 28px; padding: 15px 8px 0; border-bottom: 1px solid var(--line); background: repeating-linear-gradient(to bottom, var(--line-soft) 0 1px, transparent 1px 64px); }
.bar-group { flex: 1; height: 100%; display: flex; align-items: flex-end; justify-content: center; gap: 4px; position: relative; }
.bar { width: min(18px, 32%); min-height: 8px; border-radius: 5px 5px 0 0; background: linear-gradient(to top, #0950bb, var(--accent)); }
.bar.leads { background: linear-gradient(to top, #103b91, var(--green)); }
.bar-group label { position: absolute; bottom: -24px; color: var(--muted-2); font-size: 7px; }
.bar-chart { margin-bottom: 22px; }
.performance-alert { display: flex; gap: 10px; padding: 13px 0; border-bottom: 1px solid var(--line-soft); }
.performance-alert > span { width: 29px; height: 29px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 9px; background: var(--alert-bg); color: var(--alert-color); }
.performance-alert svg { width: 14px; }
.performance-alert b, .performance-alert p { display: block; }
.performance-alert b { font-size: 9px; }
.performance-alert p { margin: 4px 0 0; color: var(--muted-2); font-size: 8px; line-height: 1.45; }
.traffic-table-panel { margin-top: 14px; }
.table-wrap { overflow-x: auto; margin: 17px -21px -21px; }
table { width: 100%; min-width: 760px; border-collapse: collapse; text-align: left; }
th { padding: 12px 21px; border-bottom: 1px solid var(--line); color: var(--muted-2); font-size: 7px; letter-spacing: .09em; text-transform: uppercase; }
td { padding: 14px 21px; border-bottom: 1px solid var(--line-soft); font-size: 9px; }
td b, td small { display: block; }
td b { font-size: 10px; }
td small { margin-top: 3px; color: var(--muted-2); font-size: 7px; }
.table-status { display: inline-flex; align-items: center; gap: 5px; padding: 4px 7px; border-radius: 20px; background: var(--green-soft); color: var(--green); font-size: 7px; font-weight: 800; }
.table-status.attention { background: var(--orange-soft); color: var(--orange); }

.checkin-card { position: relative; }
.checkin-card.done { opacity: .58; }
.checkin-card .check-icon { width: 36px; height: 36px; display: grid; place-items: center; margin-bottom: 15px; border-radius: 11px; background: var(--accent-soft); color: var(--accent); }
.checkin-card.done .check-icon { background: var(--green-soft); color: var(--green); }
.checkin-card footer { display: flex; align-items: center; justify-content: space-between; margin-top: 17px; padding-top: 12px; border-top: 1px solid var(--line-soft); color: var(--muted-2); font-size: 8px; }
.checkin-card footer button { padding: 6px 9px; border: 1px solid var(--line); border-radius: 8px; background: transparent; color: var(--accent); font-size: 7px; font-weight: 800; }

.drawer { position: fixed; inset: 0 0 0 auto; z-index: 80; width: min(410px, 100vw); padding: 24px; border-left: 1px solid var(--line); background: rgba(2,12,34,.99); box-shadow: -20px 0 60px rgba(0,0,0,.35); transform: translateX(105%); transition: transform .25s ease; }
.drawer.open { transform: translateX(0); }
.drawer-head, .modal-head { display: flex; align-items: flex-start; justify-content: space-between; }
.drawer-head h2, .modal-head h2 { margin: 0; font: 700 20px 'Manrope', sans-serif; }
.drawer-head > button, .modal-head > button { width: 35px; height: 35px; border: 1px solid var(--line); border-radius: 10px; background: transparent; color: var(--muted); font-size: 20px; }
.push-card { display: flex; gap: 12px; margin: 22px 0; padding: 15px; border: 1px solid rgba(67,199,255,.21); border-radius: 14px; background: var(--accent-soft); }
.push-icon { width: 35px; height: 35px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 10px; background: rgba(67,199,255,.14); color: var(--accent); }
.push-card b { font-size: 10px; }
.push-card p { margin: 5px 0 10px; color: #83a4a8; font-size: 8px; line-height: 1.5; }
.push-card button { padding: 7px 10px; border: 0; border-radius: 8px; background: var(--accent); color: var(--bg); font-size: 8px; font-weight: 800; }
.notification-item { width:100%; display: grid; grid-template-columns: 9px 1fr; gap: 10px; padding: 14px 0; border:0; border-bottom: 1px solid var(--line-soft); background:transparent; color:var(--text); text-align:left; cursor:pointer; }
.notification-item:hover { background:rgba(67,199,255,.045); }
.notification-item.urgent:not(.read) { --notification-color:var(--red)!important; }
.notification-item > i { width: 7px; height: 7px; margin-top: 4px; border-radius: 50%; background: var(--notification-color, var(--accent)); }
.notification-item b, .notification-item p, .notification-item small { display: block; }
.notification-item b { font-size: 9px; }
.notification-item p { margin: 5px 0; color: var(--muted); font-size: 8px; line-height: 1.5; }
.notification-item small { color: var(--muted-2); font-size: 7px; }
.toast[data-tone="success"] { border-color:rgba(53,210,139,.45); color:#d8fff0; }
.toast[data-tone="error"] { border-color:rgba(255,107,120,.5); color:#ffe0e3; }

.modal-backdrop { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; padding: 18px; background: rgba(0,8,10,.76); backdrop-filter: blur(7px); opacity: 0; visibility: hidden; transition: .2s ease; }
.modal-backdrop.open { opacity: 1; visibility: visible; }
.modal { width: min(540px, 100%); padding: 23px; border: 1px solid var(--line); border-radius: 19px; background: var(--surface); box-shadow: var(--shadow); transform: translateY(10px); transition: .2s ease; }
.modal-backdrop.open .modal { transform: none; }
.modal > label, .form-grid label { display: block; margin-top: 15px; color: var(--muted); font-size: 8px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; }
.modal input, .modal select, .modal textarea { width: 100%; margin-top: 7px; padding: 11px 12px; border: 1px solid var(--line); border-radius: 10px; outline: 0; background: var(--bg); color: var(--text); font-size: 10px; text-transform: none; }
.modal input:focus, .modal select:focus, .modal textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 9px; margin-top: 22px; }
.toast { position: fixed; z-index: 120; left: 50%; bottom: 25px; min-width: 260px; max-width: calc(100vw - 30px); padding: 12px 16px; border: 1px solid rgba(67,199,255,.24); border-radius: 11px; background: #0b2b5a; color: var(--text); box-shadow: var(--shadow); font-size: 9px; font-weight: 700; text-align: center; opacity: 0; pointer-events: none; transform: translate(-50%, 15px); transition: .22s ease; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.mobile-nav, .mobile-scrim { display: none; }

::-webkit-scrollbar { width: 7px; height: 7px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { border-radius: 10px; background: #244147; }

@media (max-width: 1180px) {
  .metric-grid { grid-template-columns: repeat(2, 1fr); }
  .client-health-row { grid-template-columns: repeat(2, 1fr); }
  .traffic-metrics { grid-template-columns: repeat(3, 1fr); }
  .meeting-grid, .checkin-grid { grid-template-columns: repeat(2, 1fr); }
  .team-metrics { grid-template-columns: repeat(2,1fr); }
  .team-layout, .performance-layout { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  :root { --sidebar: 0px; }
  .sidebar { width: 270px; transform: translateX(-105%); transition: transform .23s ease; }
  .sidebar.open { transform: translateX(0); }
  .sidebar-close, .menu-button { display: grid; }
  .mobile-scrim { position: fixed; inset: 0; z-index: 45; border: 0; background: rgba(0,7,9,.65); backdrop-filter: blur(3px); }
  .mobile-scrim.open { display: block; }
  .topbar { padding: 0 20px; }
  .search { display: none; }
  .home-layout, .traffic-layout, .calendar-layout { grid-template-columns: 1fr; }
  .performance-hero { grid-template-columns: 1fr; }
  .day-agenda { order: -1; }
  .calendar-day { min-height: 70px; }
  .content { padding: 26px 20px 95px; }
}

@media (max-width: 640px) {
  .topbar { height: 68px; padding: 0 14px; }
  .topbar-title small { display: none; }
  .topbar-title strong { margin: 0; font-size: 13px; }
  .topbar-actions .primary-button { width: 42px; padding: 0; }
  .topbar-actions .primary-button span { display: none; }
  .content { padding: 23px 14px 92px; }
  .welcome-row, .page-heading { align-items: flex-start; flex-direction: column; margin-bottom: 20px; }
  .welcome-row h1, .page-heading h1 { font-size: 29px; }
  .date-button { width: 100%; }
  .heading-actions { width: 100%; align-items: stretch; flex-direction: column; }
  .heading-actions > * { width: 100%; }
  .metric-grid { gap: 8px; }
  .metric-card { min-height: 124px; padding: 15px; }
  .metric-card strong { margin-top: 16px; font-size: 24px; }
  .focus-panel, .agenda-card, .portfolio-strip, .chart-panel, .alerts-panel, .traffic-table-panel, .calendar-panel, .day-agenda { padding: 17px; }
  .priority-item { grid-template-columns: auto 1fr; }
  .priority-meta { grid-column: 2; text-align: left; }
  .client-health-row { display: flex; overflow-x: auto; padding-bottom: 5px; }
  .health-card { min-width: 220px; }
  .task-summary { grid-template-columns: repeat(2, 1fr); }
  .summary-card { padding: 12px; }
  .kanban { width: calc(100% + 28px); margin-inline: -14px; padding-inline: 14px; }
  .kanban-column { min-width: 82vw; }
  .traffic-metrics { display: flex; overflow-x: auto; margin-inline: -14px; padding: 0 14px 7px; }
  .traffic-metric { min-width: 150px; }
  .meeting-grid, .checkin-grid { grid-template-columns: 1fr; }
  .performance-metrics, .manager-cards { grid-template-columns: 1fr; }
  .team-metrics { grid-template-columns: repeat(2,1fr); }
  .client-detail-drawer { padding-bottom: 90px; }
  .custom-field-row { grid-template-columns: 1fr 1fr auto; }
  .calendar-week, .calendar-grid { min-width: 560px; }
  .calendar-panel { overflow-x: auto; }
  .calendar-day { min-height: 72px; }
  .form-grid { grid-template-columns: 1fr; gap: 0; }
  .mobile-nav { position: fixed; inset: auto 0 0; z-index: 42; display: grid; grid-template-columns: repeat(5, 1fr); padding: 8px 8px max(8px, env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: rgba(2,12,34,.97); backdrop-filter: blur(18px); }
  .mobile-nav button { display: grid; place-items: center; gap: 4px; padding: 4px 0; border: 0; background: transparent; color: var(--muted-2); font-size: 7px; font-weight: 700; }
  .mobile-nav button svg { width: 18px; }
  .mobile-nav button.active { color: var(--accent); }
  .mobile-nav .mobile-main-action svg { width: 37px; height: 37px; margin-top: -22px; padding: 9px; border: 1px solid var(--accent); border-radius: 13px; background: linear-gradient(135deg, #56d4ff, #258ef2); color: var(--bg); box-shadow: 0 10px 24px rgba(43,142,244,.3); }
  .toast { bottom: 82px; }
}

[hidden]{display:none!important}.prototype-banner{display:flex;justify-content:space-between;align-items:center;gap:18px;padding:16px 20px;margin-bottom:24px;border:1px solid #23569a;border-radius:14px;background:#0b2146}.prototype-banner b,.prototype-banner small{display:block}.prototype-banner small{color:#b2c7e8;font-size:12px;line-height:1.5;margin-top:5px}.prototype-banner label{font-size:11px;min-width:220px}.prototype-banner select{display:block;width:100%;margin-top:5px;padding:9px;border-radius:8px;border:1px solid #3162a0;background:#07182f;color:#e6f1ff}#clientLifecycle{border:1px solid #23569a;border-radius:12px;margin-top:20px;padding:16px}#clientLifecycle legend{font-size:12px;color:#80baff}.card-state-select{max-width:100%;padding:6px;border:1px solid var(--line);border-radius:7px;background:#07182f;color:#c6ddff;font-size:11px}.empty-state{padding:16px;color:#a9bdd9}.manager-card footer{flex-wrap:wrap;gap:8px}.form-grid>*{min-width:0}.client-detail-form input,.client-detail-form select,.client-detail-form textarea{min-width:0;max-width:100%}@media(max-width:600px){.prototype-banner{flex-direction:column;align-items:stretch;padding:14px}.prototype-banner label{min-width:0}.custom-field-row{grid-template-columns:minmax(0,1fr) minmax(0,1fr) auto}.custom-field-row input{min-width:0}.modal-actions{flex-wrap:wrap}.kanban{width:100%;margin:0;padding:0}.kanban-column{min-width:100%}.task-card footer{flex-wrap:wrap;gap:8px}}
