:root {
  --navy: #17233b;
  --navy-2: #22314f;
  --blue: #2f65d9;
  --blue-soft: #e9effd;
  --ink: #182033;
  --muted: #768095;
  --line: #e4e8ef;
  --surface: #ffffff;
  --canvas: #f4f6f9;
  --green: #0f9b80;
  --orange: #df7a32;
  --red: #d85452;
  --sidebar: 226px;
  --people-col: 196px;
  --day-width: 210px;
  --row-height: 100px;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--canvas);
  font-synthesis: none;
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--canvas); }
body { margin: 0; min-height: 100vh; background: var(--canvas); }
body.auth-locked { overflow: hidden; }
body.auth-locked > :not(.login-screen) { visibility: hidden; }
button, input, select { font: inherit; }
button { color: inherit; }
button, select { cursor: pointer; }

.sidebar {
  position: fixed; inset: 0 auto 0 0; z-index: 30; width: var(--sidebar);
  display: flex; flex-direction: column; padding: 25px 17px 18px; color: #d9e0ee;
  background: linear-gradient(165deg, #192743 0%, #121c31 78%);
  box-shadow: 8px 0 34px rgba(12, 24, 48, .08);
}
.brand { display: flex; align-items: center; gap: 12px; margin: 0 8px 42px; color: white; text-decoration: none; }
.brand-mark { display: grid; place-items: center; width: 43px; height: 43px; border-radius: 11px; color: #fff; background: var(--blue); font-size: 13px; font-weight: 850; letter-spacing: -.4px; box-shadow: 0 7px 18px rgba(47, 101, 217, .28); }
.brand-copy { display: grid; line-height: 1.15; }
.brand-copy strong { font-size: 15px; letter-spacing: .2px; }
.brand-copy small { margin-top: 4px; color: #9da9be; font-size: 11px; text-transform: uppercase; letter-spacing: 1.8px; }
.main-nav { display: grid; gap: 7px; }
.nav-item { border: 0; display: flex; align-items: center; gap: 13px; width: 100%; padding: 11px 13px; border-radius: 9px; color: #9eacc1; background: transparent; font-weight: 600; font-size: 13px; text-align: left; transition: .18s ease; }
.nav-item:hover { color: white; background: rgba(255,255,255,.06); }
.nav-item.active { color: white; background: linear-gradient(90deg, #315fba, #2d5ab1); box-shadow: 0 8px 18px rgba(17, 35, 72, .2); }
.nav-icon { display: inline-grid; place-items: center; width: 22px; height: 22px; font-size: 19px; font-weight: 400; }
.sidebar-foot { margin-top: auto; display: grid; gap: 16px; }
.nav-item.subtle { border-bottom: 1px solid rgba(255,255,255,.08); padding-bottom: 17px; border-radius: 0; }
.user-card { display: flex; align-items: center; gap: 10px; padding: 6px; }
.avatar { flex: none; display: grid; place-items: center; width: 35px; height: 35px; border-radius: 50%; color: white; font-size: 11px; font-weight: 800; background: var(--blue); }
.avatar-dark { background: #33425f; }
.user-card > span:nth-child(2) { display: grid; flex: 1; }
.user-card strong { font-size: 12px; color: white; }
.user-card small { color: #8290a7; font-size: 10px; margin-top: 3px; }
.more { display: none; }
.logout-button { border: 1px solid rgba(255,255,255,.12); padding: 5px 7px; border-radius: 6px; color: #9cabc0; background: rgba(255,255,255,.04); font-size: 9px; font-weight: 750; }
.logout-button:hover { color: white; background: rgba(255,255,255,.1); }

.login-screen { position: fixed; z-index: 200; inset: 0; display: grid; place-items: center; padding: 28px; background: radial-gradient(circle at 70% 10%, #29436e 0, transparent 34%), linear-gradient(145deg, #111b2f, #1b2d4c); }
.login-screen[hidden] { display: none; }
.login-brand { position: fixed; top: 30px; left: 34px; display: flex; align-items: center; gap: 12px; color: white; }
.login-brand > span:last-child { display: grid; gap: 3px; }
.login-brand strong { font-size: 15px; }
.login-brand small { color: #9fadc2; font-size: 9px; text-transform: uppercase; letter-spacing: 1.2px; }
.login-card { width: min(410px, 100%); padding: 36px; border: 1px solid rgba(255,255,255,.16); border-radius: 18px; background: rgba(255,255,255,.97); box-shadow: 0 28px 80px rgba(0,0,0,.3); }
.login-card h1 { margin: 6px 0 7px; font-size: 28px; letter-spacing: -.7px; }
.login-card > p { margin: 0 0 25px; color: var(--muted); font-size: 11px; line-height: 1.55; }
.login-card .field { margin-top: 14px; }
.login-eyebrow { color: var(--blue); font-size: 9px; font-weight: 850; letter-spacing: 1.3px; }
.login-submit { width: 100%; margin-top: 20px; padding: 13px; }
.login-card .login-error { margin: 12px 0 0; padding: 9px 11px; border-radius: 7px; color: #9d3734; background: #fdebea; font-size: 10px; }
.login-domain { display: block; margin-top: 18px; color: #939cab; font-size: 9px; text-align: center; }

.app-shell { min-height: 100vh; margin-left: var(--sidebar); padding: 0 26px 116px; }
.topbar { height: 90px; display: flex; align-items: center; gap: 24px; border-bottom: 1px solid var(--line); }
.page-title { flex: 1; }
.page-title p, .section-heading p { margin: 0 0 3px; color: var(--muted); font-size: 11px; font-weight: 650; text-transform: uppercase; letter-spacing: 1.1px; }
.page-title h1 { margin: 0; color: var(--ink); font-size: 21px; letter-spacing: -.45px; }
.top-actions { display: flex; align-items: center; gap: 11px; }
.sync-state { display: flex; align-items: center; gap: 7px; margin-right: 7px; color: #82907f; font-size: 11px; }
.sync-state i { width: 7px; height: 7px; border-radius: 50%; background: #27a687; box-shadow: 0 0 0 3px #e2f4ef; }
.sync-state.saving i { background: #e3a02d; box-shadow: 0 0 0 3px #fff0ce; animation: pulse 1s infinite; }
.sync-state.error i { background: var(--red); box-shadow: 0 0 0 3px #fee9e7; }
.icon-button { position: relative; border: 1px solid var(--line); width: 40px; height: 40px; border-radius: 10px; background: white; font-size: 20px; }
.icon-button:hover, .tool-button:hover, .today-button:hover { border-color: #c5ccda; background: #fafbfc; }
.notification-dot { position: absolute; top: 7px; right: 8px; width: 7px; height: 7px; border-radius: 50%; border: 2px solid white; background: var(--red); }
.primary-button, .secondary-button { border: 0; border-radius: 9px; padding: 11px 16px; font-size: 12px; font-weight: 750; transition: .18s ease; }
.primary-button { color: white; background: var(--blue); box-shadow: 0 7px 16px rgba(47,101,217,.19); }
.primary-button:hover { background: #2457c3; transform: translateY(-1px); }
.secondary-button { border: 1px solid var(--line); background: white; }
.mobile-brand { display: none; }

.summary-grid { display: grid; grid-template-columns: repeat(3, minmax(220px, 1fr)); gap: 14px; margin: 22px 0 16px; }
.summary-card { min-height: 73px; display: flex; align-items: center; gap: 13px; padding: 15px 17px; border: 1px solid #e7eaf0; border-radius: 11px; background: white; box-shadow: 0 2px 6px rgba(23,35,59,.025); }
.summary-icon { flex: none; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 10px; font-size: 20px; font-weight: 700; }
.summary-icon.blue { color: var(--blue); background: #ecf1fd; }
.summary-icon.green { color: var(--green); background: #e7f6f2; }
.summary-icon.orange { color: var(--orange); background: #fff1e6; }
.summary-card > div { display: grid; gap: 3px; }
.summary-card small { color: var(--muted); font-size: 10px; font-weight: 600; }
.summary-card strong { font-size: 17px; letter-spacing: -.3px; }
.summary-card .trend, .summary-card .muted-label { margin-left: auto; align-self: flex-end; padding: 4px 7px; border-radius: 12px; color: var(--green); background: #e9f7f3; font-size: 9px; font-weight: 750; }
.summary-card .muted-label { color: var(--muted); background: #f1f3f6; }
.summary-card.attention { border-color: #f1ddce; }
.summary-card.attention button { margin-left: auto; border: 0; border-bottom: 1px solid #ddb28f; padding: 2px 0; color: #b86428; background: none; font-size: 10px; font-weight: 700; }

.view-panel { display: none; }
.view-panel.active { display: block; }
.planner-card { overflow: hidden; border: 1px solid #e0e4eb; border-radius: 12px; background: white; box-shadow: 0 5px 18px rgba(24,32,51,.04); }
.planner-toolbar { min-height: 62px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 11px 15px; border-bottom: 1px solid var(--line); }
.week-navigation, .planner-tools { display: flex; align-items: center; gap: 7px; }
.icon-button.small { width: 31px; height: 31px; border-radius: 7px; font-size: 20px; }
.week-label { border: 0; padding: 7px 10px; background: none; font-size: 13px; font-weight: 750; }
.week-label span { margin-left: 5px; color: var(--muted); }
.today-button, .tool-button { border: 1px solid var(--line); min-height: 31px; padding: 0 11px; border-radius: 7px; color: #596276; background: white; font-size: 10px; font-weight: 700; }
.segmented { display: flex; padding: 3px; border-radius: 8px; background: #f1f3f6; }
.segmented button { border: 0; padding: 6px 10px; border-radius: 6px; color: var(--muted); background: transparent; font-size: 10px; font-weight: 700; }
.segmented button.active { color: var(--ink); background: white; box-shadow: 0 2px 5px rgba(30,42,65,.1); }
.legend-row { min-height: 42px; display: flex; align-items: center; gap: 20px; padding: 8px 15px; color: var(--muted); background: #fafbfc; border-bottom: 1px solid var(--line); font-size: 9px; }
.legend-row > span { display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.legend-dot { width: 7px; height: 7px; border-radius: 50%; }
.legend-dot.green { background: #43bca3; }.legend-dot.orange { background: #eda15f; }.legend-dot.red { background: #e16765; }.legend-dot.gray { background: #b7bdc8; }
.legend-tip { margin-left: auto; }
.timeline-scroll { overflow: auto; overscroll-behavior-x: contain; scrollbar-width: thin; scrollbar-color: #c7cdd8 transparent; }
.timeline { min-width: calc(var(--people-col) + var(--day-width) * 5); }
.timeline-header { position: sticky; top: 0; z-index: 8; height: 62px; display: grid; grid-template-columns: var(--people-col) repeat(5, var(--day-width)); background: white; border-bottom: 1px solid var(--line); }
.people-heading { position: sticky; left: 0; z-index: 10; display: flex; align-items: center; padding-left: 18px; border-right: 1px solid var(--line); background: white; color: var(--muted); font-size: 9px; font-weight: 750; text-transform: uppercase; letter-spacing: .8px; }
.day-heading { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; border-right: 1px solid var(--line); }
.day-heading strong { font-size: 12px; text-transform: capitalize; }
.day-heading span { color: var(--muted); font-size: 9px; }
.day-heading.today { background: #f0f5ff; }
.day-heading.today strong { color: var(--blue); }
.timeline-row { position: relative; display: grid; grid-template-columns: var(--people-col) calc(var(--day-width) * 5); min-height: var(--row-height); border-bottom: 1px solid var(--line); }
.timeline-row:last-child { border-bottom: 0; }
.person-cell { position: sticky; left: 0; z-index: 7; display: flex; align-items: center; gap: 10px; padding: 13px 17px; border-right: 1px solid var(--line); background: white; }
.person-cell .avatar { width: 33px; height: 33px; }
.person-meta { display: grid; min-width: 0; }
.person-meta strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }
.person-meta small { margin-top: 3px; color: var(--muted); font-size: 9px; }
.row-grid { position: relative; min-height: var(--row-height); background-image: repeating-linear-gradient(to right, transparent 0, transparent calc(var(--day-width) / 2 - 1px), #f1f3f6 calc(var(--day-width) / 2), transparent calc(var(--day-width) / 2 + 1px), transparent calc(var(--day-width) - 1px), #dfe4eb var(--day-width)); background-size: var(--day-width) 100%; }
.capacity-strip { position: absolute; inset: auto 0 0; height: 10px; display: grid; grid-template-columns: repeat(5, var(--day-width)); pointer-events: none; }
.capacity-cell { margin: 0 1px 2px; border-radius: 2px; background: #e6f4ef; }
.capacity-cell.near { background: #fce9d7; }.capacity-cell.over { background: #f9d3d1; }.capacity-cell.unavailable { background: #e9ebef; }
.activity-bar { position: absolute; z-index: 3; top: 13px; height: 35px; min-width: 24px; display: flex; align-items: center; border: 1px solid color-mix(in srgb, var(--bar-color) 76%, #1b2640); border-radius: 6px; color: #fff; background: var(--bar-color); box-shadow: 0 4px 9px color-mix(in srgb, var(--bar-color) 22%, transparent); user-select: none; touch-action: none; cursor: grab; overflow: hidden; transition: box-shadow .15s, transform .15s; }
.activity-bar.track-1 { top: 51px; }
.activity-bar:hover { z-index: 6; transform: translateY(-1px); box-shadow: 0 6px 14px color-mix(in srgb, var(--bar-color) 34%, transparent); }
.activity-bar.dragging { z-index: 20; cursor: grabbing; opacity: .88; box-shadow: 0 10px 20px rgba(17,31,58,.25); transition: none; }
.activity-bar.conflict { background-image: repeating-linear-gradient(135deg, transparent 0 7px, rgba(143,41,30,.22) 7px 13px); outline: 2px solid rgba(211,78,65,.32); }
.bar-content { min-width: 0; flex: 1; padding: 0 13px; pointer-events: none; }
.bar-content strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 10px; }
.bar-content small { display: block; overflow: hidden; margin-top: 2px; color: rgba(255,255,255,.78); text-overflow: ellipsis; white-space: nowrap; font-size: 8px; }
.resize-handle { position: absolute; top: 0; bottom: 0; width: 9px; cursor: ew-resize; }
.resize-handle::after { content: ''; position: absolute; top: 10px; bottom: 10px; width: 2px; border-radius: 1px; background: rgba(255,255,255,.55); }
.resize-handle.left { left: 0; }.resize-handle.left::after { left: 3px; }.resize-handle.right { right: 0; }.resize-handle.right::after { right: 3px; }
.split-link { position: absolute; z-index: 1; top: 30px; height: 0; border-top: 1px dashed var(--bar-color); opacity: .5; pointer-events: none; }
.mobile-swipe-hint { display: none; }
.month-calendar { overflow: auto; background: #fafbfc; }
.month-grid { display: grid; grid-template-columns: repeat(7, minmax(112px, 1fr)); min-width: 790px; }
.month-weekday { padding: 10px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); color: var(--muted); background: #f6f8fa; font-size: 9px; font-weight: 800; text-align: center; text-transform: uppercase; letter-spacing: .7px; }
.month-day { position: relative; min-height: 112px; padding: 8px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: white; }
.month-day.outside { background: #f7f8fa; color: #adb4c1; }.month-day.today { box-shadow: inset 0 0 0 2px #8eabe9; }.month-day.unavailable { background-image: repeating-linear-gradient(135deg, transparent 0 9px, rgba(172,180,194,.08) 9px 14px); }
.month-day-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 7px; }.month-day-head strong { font-size: 10px; }.month-day-head span { color: var(--muted); font-size: 8px; }.month-day.over .month-day-head span { color: var(--red); font-weight: 800; }
.month-events { display: grid; gap: 4px; }.month-event { overflow: hidden; border: 0; border-left: 3px solid var(--event-color); padding: 5px 6px; border-radius: 4px; color: #384359; background: color-mix(in srgb, var(--event-color) 12%, white); font-size: 8px; font-weight: 700; text-align: left; text-overflow: ellipsis; white-space: nowrap; }.month-event:hover { background: color-mix(in srgb, var(--event-color) 20%, white); }

.empty-view { min-height: 520px; padding: 24px; border: 1px solid var(--line); border-radius: 12px; background: white; }
.section-heading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 22px; }
.section-heading h2 { margin: 2px 0 0; font-size: 22px; }
.hours-layout { display: grid; grid-template-columns: 260px 1fr; gap: 18px; }
.hours-total { min-height: 180px; display: grid; align-content: center; justify-items: center; border-radius: 14px; color: white; background: linear-gradient(145deg, #263b63, #17233b); }
.hours-total small { color: #bdc9dc; }.hours-total strong { margin-top: 12px; font-size: 46px; line-height: 1; }.hours-total span { margin-top: 4px; color: #9eacc2; font-size: 12px; }
.entries-card { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.entries-head, .time-entry { display: grid; grid-template-columns: 1fr auto; gap: 20px; padding: 15px 17px; border-bottom: 1px solid var(--line); }
.entries-head span { color: var(--muted); font-size: 10px; }
.time-entry:last-child { border-bottom: 0; }
.time-entry > span { display: grid; gap: 3px; }.time-entry small { color: var(--muted); }.time-entry time { font-weight: 750; }
.empty-state { padding: 45px 20px; color: var(--muted); text-align: center; }
.project-grid, .team-grid, .customer-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.project-card, .team-card, .customer-card { padding: 18px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.project-card .project-color { width: 34px; height: 7px; margin-bottom: 18px; border-radius: 5px; background: var(--project-color); }
.project-card { position: relative; cursor: pointer; transition: .18s ease; }.project-card:hover { border-color: #c9d3e7; transform: translateY(-2px); box-shadow: 0 8px 18px rgba(24,32,51,.06); }.project-card .edit-project { position: absolute; top: 14px; right: 14px; border: 0; color: var(--muted); background: none; font-size: 13px; }.project-customer { display: inline-flex; align-items: center; gap: 5px; margin-top: 7px; padding: 5px 7px; border-radius: 6px; color: #52647b; background: #f1f4f8; font-size: 8px; }
.project-card h3, .team-card h3 { margin: 5px 0; font-size: 15px; }.project-card p, .team-card p { margin: 0; color: var(--muted); font-size: 11px; }.project-card .project-stats { display: flex; justify-content: space-between; margin-top: 22px; padding-top: 13px; border-top: 1px solid var(--line); font-size: 10px; }.project-card .project-stats strong { font-size: 13px; }
.team-card { display: flex; align-items: center; gap: 12px; }.team-card .avatar { width: 45px; height: 45px; }.team-card > div { display: grid; gap: 3px; }

.solo-row { min-height: 112px; }
.solo-row .row-grid { min-height: 112px; }
.solo-label { display: grid; gap: 3px; }
.solo-label strong { font-size: 11px; }
.solo-label small { color: var(--muted); font-size: 9px; }
.capacity-overview { display: grid; grid-template-columns: minmax(300px, .85fr) minmax(420px, 1.5fr); gap: 17px; }
.capacity-ring-card, .capacity-days-card { border: 1px solid var(--line); border-radius: 13px; background: #fff; }
.capacity-ring-card { display: flex; align-items: center; gap: 25px; padding: 24px; background: linear-gradient(135deg, #f8faff, #fff); }
.capacity-ring { --capacity: 75%; position: relative; flex: none; display: grid; place-items: center; width: 124px; height: 124px; border-radius: 50%; background: conic-gradient(var(--blue) var(--capacity), #e8edf5 0); }
.capacity-ring::after { content: ''; position: absolute; inset: 13px; border-radius: 50%; background: white; }
.capacity-ring > span { position: relative; z-index: 1; display: grid; place-items: center; }
.capacity-ring strong { font-size: 26px; letter-spacing: -.8px; }.capacity-ring small { color: var(--muted); font-size: 9px; text-transform: uppercase; letter-spacing: .8px; }
.capacity-ring-card > div:last-child > small { color: var(--blue); font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .8px; }
.capacity-ring-card h3 { margin: 5px 0 6px; font-size: 16px; }.capacity-ring-card p { margin: 0; color: var(--muted); font-size: 10px; line-height: 1.5; }
.capacity-days-card { overflow: hidden; }
.capacity-day { display: grid; grid-template-columns: 72px 1fr 78px; align-items: center; gap: 13px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.capacity-day:last-child { border-bottom: 0; }.capacity-day > strong { font-size: 10px; text-transform: capitalize; }.capacity-day > span:last-child { color: var(--muted); font-size: 9px; text-align: right; }
.capacity-track { height: 8px; overflow: hidden; border-radius: 5px; background: #edf0f4; }.capacity-fill { height: 100%; width: var(--fill); border-radius: inherit; background: var(--green); }.capacity-fill.near { background: var(--orange); }.capacity-fill.over { background: var(--red); }
.capacity-insights { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 17px; }
.insight-card { padding: 16px; border: 1px solid var(--line); border-radius: 11px; background: #fafbfc; }.insight-card span { display: grid; place-items: center; width: 30px; height: 30px; margin-bottom: 12px; border-radius: 8px; color: var(--blue); background: var(--blue-soft); }.insight-card strong { display: block; font-size: 11px; }.insight-card p { margin: 5px 0 0; color: var(--muted); font-size: 9px; line-height: 1.45; }
.customer-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin: -5px 0 18px; }.customer-toolbar label { display: flex; align-items: center; gap: 8px; width: min(390px, 100%); height: 40px; padding: 0 12px; border: 1px solid var(--line); border-radius: 9px; background: #fafbfc; }.customer-toolbar input { flex: 1; border: 0; outline: 0; background: transparent; font-size: 11px; }.customer-toolbar > span { color: var(--muted); font-size: 10px; }
.customer-card { position: relative; overflow: hidden; cursor: pointer; transition: .18s ease; }.customer-card:hover { border-color: #cbd5e8; transform: translateY(-2px); box-shadow: 0 8px 18px rgba(24,32,51,.06); }.customer-card::before { content: ''; position: absolute; inset: 0 auto 0 0; width: 4px; background: var(--customer-color); }.customer-top { display: flex; align-items: flex-start; gap: 11px; }.customer-logo { display: grid; place-items: center; flex: none; width: 39px; height: 39px; border-radius: 10px; color: white; background: var(--customer-color); font-size: 11px; font-weight: 850; }.customer-top h3 { margin: 2px 0 4px; font-size: 14px; }.customer-top p { margin: 0; color: var(--muted); font-size: 9px; }.customer-more { margin-left: auto; border: 0; color: var(--muted); background: none; }.customer-contact { display: grid; gap: 7px; margin: 17px 0; padding: 13px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }.customer-contact span { color: #596276; font-size: 9px; }.customer-contact i { display: inline-block; width: 17px; color: #99a2b2; font-style: normal; }.customer-stats { display: flex; gap: 23px; }.customer-stats span { color: var(--muted); font-size: 8px; }.customer-stats strong { display: block; margin-bottom: 2px; color: var(--ink); font-size: 12px; }.customer-note { margin-top: 12px; padding: 7px 9px; border-radius: 6px; color: #52647b; background: #f1f4f8; font-size: 8px; }
.customer-projects { display: grid; gap: 5px; margin-top: 12px; }.customer-projects > span { overflow: hidden; padding: 6px 8px; border-radius: 5px; color: #4f6077; background: #f5f7fa; font-size: 8px; text-overflow: ellipsis; white-space: nowrap; }.customer-projects button { border: 1px dashed #b9c7df; padding: 6px; border-radius: 6px; color: var(--blue); background: #f8faff; font-size: 8px; font-weight: 750; }
.availability-editor { display: grid; gap: 8px; }.availability-row { display: grid; grid-template-columns: 32px 1fr 100px; align-items: center; gap: 12px; min-height: 49px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 9px; }.availability-row input[type="checkbox"] { width: 17px; height: 17px; accent-color: var(--blue); }.availability-row strong { font-size: 11px; }.availability-row label { position: relative; }.availability-row input[type="number"] { width: 100%; height: 33px; padding: 0 34px 0 9px; border: 1px solid var(--line); border-radius: 7px; font-size: 11px; }.availability-row label span { position: absolute; right: 8px; top: 9px; color: var(--muted); font-size: 9px; }
.project-color-picker { display: flex; gap: 9px; }.project-color-option { width: 30px; height: 30px; border: 3px solid white; border-radius: 50%; background: var(--option-color); box-shadow: 0 0 0 1px #d5dae3; }.project-color-option.active { box-shadow: 0 0 0 2px var(--ink); }
.settings-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; }.settings-card { padding: 20px; border: 1px solid var(--line); border-radius: 12px; background: white; }.settings-card-head { display: flex; gap: 12px; margin-bottom: 20px; padding-bottom: 15px; border-bottom: 1px solid var(--line); }.settings-card-head > span { display: grid; place-items: center; flex: none; width: 32px; height: 32px; border-radius: 8px; color: var(--blue); background: var(--blue-soft); font-size: 9px; font-weight: 850; }.settings-card h3 { margin: 0 0 4px; font-size: 13px; }.settings-card p { margin: 0; color: var(--muted); font-size: 9px; }.settings-data-card { grid-column: 1 / -1; }.data-location { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 4px 20px; padding: 14px; border-radius: 9px; background: #f5f7fa; }.data-location span { font-size: 10px; font-weight: 750; }.data-location strong { font-family: ui-monospace, monospace; font-size: 10px; }.data-location small { grid-column: 1 / -1; color: var(--muted); }.settings-actions { grid-column: 1 / -1; display: flex; justify-content: flex-end; }

.clockbar { position: fixed; z-index: 25; left: calc(var(--sidebar) + 26px); right: 26px; bottom: 18px; min-height: 70px; display: flex; align-items: center; gap: 20px; padding: 10px 12px 10px 17px; border: 1px solid rgba(45,63,96,.2); border-radius: 12px; color: white; background: linear-gradient(105deg, #192943, #233758); box-shadow: 0 14px 35px rgba(16,28,50,.22); }
.clock-project, .clock-person { display: flex; align-items: center; gap: 12px; min-width: 0; }
.clock-project { flex: 1; }
.clock-symbol { display: grid; place-items: center; flex: none; width: 38px; height: 38px; border-radius: 9px; color: #a9c2fa; background: rgba(255,255,255,.08); font-size: 21px; }
.clockbar label { display: grid; min-width: 0; }
.clockbar small { margin-bottom: 3px; color: #99a9c1; font-size: 9px; text-transform: uppercase; letter-spacing: .8px; }
.clockbar select { max-width: 310px; border: 0; padding: 0 25px 0 0; outline: 0; color: white; background: transparent; font-size: 12px; font-weight: 700; }
.clockbar select option { color: var(--ink); background: white; }
.clock-person { padding: 0 20px; border-left: 1px solid rgba(255,255,255,.12); border-right: 1px solid rgba(255,255,255,.12); }
.clock-time { min-width: 92px; font-variant-numeric: tabular-nums; font-size: 20px; font-weight: 750; letter-spacing: .8px; text-align: center; }
.clock-button { min-width: 172px; border: 0; padding: 13px 18px; border-radius: 8px; color: white; font-size: 11px; font-weight: 800; }
.clock-button.start { background: #159578; }.clock-button.stop { background: #d65852; }
.clockbar.running { background: linear-gradient(105deg, #123b38, #18554d); }
.clockbar.running .clock-symbol { animation: pulse 1.4s infinite; }
.mobile-nav { display: none; }

.modal { width: min(680px, calc(100vw - 32px)); max-height: calc(100vh - 32px); padding: 0; border: 0; border-radius: 16px; color: var(--ink); background: white; box-shadow: 0 24px 70px rgba(14,26,49,.28); }
.modal::backdrop { background: rgba(15,25,43,.58); backdrop-filter: blur(3px); }
.modal form { padding: 26px 29px 22px; }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 22px; }
.modal-head h2 { margin: 4px 0 4px; font-size: 22px; letter-spacing: -.4px; }.modal-head p { margin: 0; color: var(--muted); font-size: 11px; }.eyebrow { color: var(--blue); font-size: 9px; font-weight: 850; letter-spacing: 1.2px; }
.modal-close { border: 0; width: 33px; height: 33px; border-radius: 8px; color: var(--muted); background: #f3f5f8; font-size: 21px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }.field { display: grid; gap: 6px; }.field.full { grid-column: 1 / -1; }.field > span, fieldset legend { color: #4c566a; font-size: 10px; font-weight: 750; }.field input, .field select { width: 100%; height: 40px; border: 1px solid #dfe3ea; border-radius: 8px; padding: 0 11px; color: var(--ink); background: #fff; outline: none; font-size: 12px; }.field input:focus, .field select:focus { border-color: #8eabe9; box-shadow: 0 0 0 3px #edf2fd; }
.input-unit { position: relative; }.input-unit input { padding-right: 43px; }.input-unit span { position: absolute; top: 13px; right: 11px; color: var(--muted); font-size: 10px; }
fieldset { padding: 0; border: 0; margin: 19px 0 0; }.choice-field { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; }.choice-field legend { grid-column: 1 / -1; margin-bottom: 7px; }.choice-card { position: relative; display: flex; align-items: center; gap: 8px; min-height: 62px; padding: 9px; border: 1px solid #dfe3ea; border-radius: 9px; cursor: pointer; }.choice-card:has(input:checked) { border-color: #7fa0e6; background: #f4f7fe; }.choice-card input { position: absolute; opacity: 0; }.choice-radio { flex: none; width: 14px; height: 14px; border: 1px solid #abb4c4; border-radius: 50%; }.choice-card input:checked + .choice-radio { border: 4px solid var(--blue); }.choice-card > span:last-child { display: grid; gap: 3px; }.choice-card strong { font-size: 10px; }.choice-card small { color: var(--muted); font-size: 8px; line-height: 1.3; }
.days-field legend { margin-bottom: 9px; }.days-field legend small { color: var(--muted); font-weight: 400; }.days-field > div { display: flex; gap: 7px; }.days-field label { position: relative; }.days-field input { position: absolute; opacity: 0; }.days-field label span { display: grid; place-items: center; width: 40px; height: 34px; border: 1px solid var(--line); border-radius: 7px; color: var(--muted); font-size: 10px; font-weight: 750; }.days-field input:checked + span { border-color: #8aa8e9; color: var(--blue); background: #eef3fe; }
.modal-actions { display: flex; align-items: center; gap: 9px; margin-top: 23px; padding-top: 18px; border-top: 1px solid var(--line); }.modal-spacer { flex: 1; }.danger-link { border: 0; padding: 0; color: var(--red); background: none; font-size: 10px; font-weight: 700; }

.conflict-panel { position: fixed; z-index: 50; top: 0; right: 0; bottom: 0; width: min(390px, 94vw); padding: 20px; background: white; box-shadow: -12px 0 40px rgba(18,31,55,.18); transform: translateX(110%); transition: transform .26s ease; }
.conflict-panel.open { transform: translateX(0); }.conflict-head { display: flex; justify-content: space-between; padding-bottom: 17px; border-bottom: 1px solid var(--line); }.conflict-head > div { display: flex; gap: 10px; }.conflict-head > div > span:last-child { display: grid; gap: 3px; }.conflict-head small { color: var(--muted); }.conflict-head button { border: 0; background: none; color: var(--muted); font-size: 22px; }.warning-badge { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; color: #b85f25; background: #fff0e4; font-weight: 900; }.conflict-item { margin-top: 15px; padding: 14px; border: 1px solid #f1d7c2; border-radius: 10px; background: #fffaf6; }.conflict-item h4 { margin: 0 0 6px; color: #9f4d20; font-size: 12px; }.conflict-item p { margin: 0; color: #6f5c53; font-size: 10px; line-height: 1.5; }.conflict-item button { width: 100%; margin-top: 11px; border: 1px solid #e2c3aa; padding: 8px; border-radius: 7px; color: #9f4d20; background: white; font-size: 10px; font-weight: 750; }.no-conflicts { margin-top: 40px; color: var(--muted); text-align: center; font-size: 12px; }
.toast-stack { position: fixed; z-index: 100; right: 25px; bottom: 105px; display: grid; gap: 8px; }.toast { min-width: 260px; padding: 12px 15px; border-radius: 9px; color: white; background: #1f2f4d; box-shadow: 0 10px 25px rgba(18,30,52,.2); font-size: 11px; animation: toast-in .25s ease; }.toast.warning { background: #a9542d; }.toast.success { background: #13806c; }

@keyframes pulse { 50% { opacity: .5; } }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } }

@media (max-width: 980px) {
  :root { --sidebar: 78px; --people-col: 170px; --day-width: 190px; }
  .sidebar { width: var(--sidebar); align-items: center; padding-inline: 10px; }.brand { margin-inline: 0; }.brand-copy, .nav-item span:last-child, .user-card > span:not(.avatar) { display: none; }.main-nav, .sidebar-foot, .nav-item { width: 100%; }.nav-item { justify-content: center; padding-inline: 0; }.user-card { justify-content: center; }.app-shell { margin-left: var(--sidebar); }.clockbar { left: calc(var(--sidebar) + 20px); }.summary-grid { grid-template-columns: 1fr 1fr; }.summary-card:last-child { grid-column: 1 / -1; }.clock-person { display: none; }
  .capacity-overview { grid-template-columns: 1fr; }
  .settings-layout { grid-template-columns: 1fr; }.settings-data-card, .settings-actions { grid-column: auto; }
}

@media (max-width: 700px) {
  :root { --people-col: 116px; --day-width: 174px; --row-height: 91px; }
  body { padding-bottom: env(safe-area-inset-bottom); }
  .login-screen { align-items: center; padding: 18px; }
  .login-brand { top: 22px; left: 22px; }
  .login-card { padding: 27px 22px; border-radius: 15px; }
  .sidebar { display: none; }
  .app-shell { margin: 0; padding: 0 12px 148px; }
  .topbar { position: sticky; top: 0; z-index: 24; height: 68px; gap: 8px; margin: 0 -12px; padding: 0 12px; background: rgba(244,246,249,.94); backdrop-filter: blur(12px); }
  .mobile-brand { display: flex; align-items: center; gap: 8px; flex: 1; }.mobile-brand .brand-mark { width: 34px; height: 34px; border-radius: 9px; font-size: 10px; }.mobile-brand strong { font-size: 14px; }
  .page-title, .sync-state, .top-actions .primary-button { display: none; }.top-actions { margin-left: auto; }.top-actions .icon-button { display: block; }
  .summary-grid { grid-template-columns: 1fr 1fr; gap: 8px; margin: 13px 0 10px; }.summary-card { min-width: 0; min-height: 63px; padding: 10px; gap: 9px; }.summary-card:nth-child(2) { display: none; }.summary-card:last-child { grid-column: auto; }.summary-icon { width: 34px; height: 34px; }.summary-card strong { font-size: 14px; }.summary-card small { font-size: 8px; }.summary-card .trend, .summary-card .muted-label, .summary-card.attention button { display: none; }
  .planner-card { margin: 0 -12px; border-radius: 0; border-left: 0; border-right: 0; }.planner-toolbar { min-height: 52px; padding: 8px 10px; }.week-label { padding-inline: 5px; font-size: 12px; }.today-button, #zoomButton, #filterButton { display: none; }.tool-button { width: 31px; padding: 0; font-size: 0; }.tool-button:first-letter { font-size: 14px; }
  .legend-row { gap: 11px; overflow: hidden; padding-inline: 10px; }.legend-row span:nth-child(4), .legend-tip { display: none; }.timeline-scroll { max-height: calc(100vh - 285px); }.timeline-header { height: 52px; }.people-heading { padding-left: 10px; }.person-cell { gap: 7px; padding: 10px; }.person-cell .avatar { width: 28px; height: 28px; font-size: 9px; }.person-meta strong { max-width: 60px; font-size: 9px; }.person-meta small { font-size: 7px; }.activity-bar { top: 10px; height: 32px; }.activity-bar.track-1 { top: 47px; }.bar-content { padding-inline: 11px; }.bar-content strong { font-size: 9px; }.bar-content small { font-size: 7px; }.mobile-swipe-hint { display: block; padding: 7px; color: var(--muted); background: #fafbfc; font-size: 8px; text-align: center; }
  .clockbar { left: 10px; right: 10px; bottom: calc(67px + env(safe-area-inset-bottom)); min-height: 62px; gap: 9px; padding: 8px 9px; border-radius: 11px; }.clock-symbol, .clock-person, .clock-project small { display: none; }.clock-project { flex: 1; min-width: 0; }.clockbar select { width: 100%; max-width: none; font-size: 10px; }.clock-time { min-width: 65px; font-size: 14px; }.clock-button { min-width: 48px; width: 48px; height: 45px; padding: 0; font-size: 13px; }.clock-button span { display: none; }
  .mobile-nav { position: fixed; z-index: 28; left: 0; right: 0; bottom: 0; height: calc(61px + env(safe-area-inset-bottom)); display: grid; grid-template-columns: repeat(5, 1fr); padding: 6px 6px env(safe-area-inset-bottom); border-top: 1px solid var(--line); background: rgba(255,255,255,.97); backdrop-filter: blur(12px); box-shadow: 0 -8px 28px rgba(26,37,58,.07); }.mobile-nav button { border: 0; display: grid; place-items: center; align-content: center; gap: 2px; color: #8b94a5; background: transparent; font-size: 8px; font-weight: 700; }.mobile-nav button span { font-size: 18px; }.mobile-nav button.active { color: var(--blue); }.mobile-nav .mobile-add { place-self: center; width: 44px; height: 44px; border-radius: 14px; color: white; background: var(--blue); box-shadow: 0 6px 14px rgba(47,101,217,.28); font-size: 25px; }
  .empty-view { min-height: calc(100vh - 94px); margin: 0 -12px; padding: 17px 12px; border-radius: 0; border-left: 0; border-right: 0; }.section-heading h2 { font-size: 18px; }.section-heading .primary-button { padding: 10px; font-size: 9px; }.hours-layout { grid-template-columns: 1fr; }.hours-total { min-height: 130px; }.project-grid, .team-grid, .customer-grid { grid-template-columns: 1fr; }
  .capacity-overview { grid-template-columns: 1fr; }.capacity-ring-card { padding: 18px; }.capacity-ring { width: 100px; height: 100px; }.capacity-ring strong { font-size: 22px; }.capacity-insights { grid-template-columns: 1fr; }.capacity-day { grid-template-columns: 58px 1fr 65px; gap: 8px; padding-inline: 11px; }.customer-toolbar { align-items: flex-start; flex-direction: column; gap: 8px; }.customer-toolbar label { width: 100%; }
  .month-day { min-height: 94px; }.month-calendar { max-height: calc(100vh - 245px); }.settings-card { padding: 15px; }.data-location { grid-template-columns: 1fr; }.data-location strong, .data-location small { grid-column: auto; }
  .modal { width: 100vw; max-width: none; max-height: 94vh; margin: auto 0 0; border-radius: 19px 19px 0 0; }.modal form { padding: 20px 17px calc(20px + env(safe-area-inset-bottom)); }.modal-head { margin-bottom: 17px; }.modal-head h2 { font-size: 19px; }.form-grid { grid-template-columns: 1fr; gap: 11px; }.field.full { grid-column: auto; }.choice-field { grid-template-columns: 1fr; gap: 6px; }.choice-card { min-height: 52px; }.choice-card small { font-size: 8px; }.modal-actions { position: sticky; bottom: 0; margin-inline: -17px; padding: 13px 17px; background: white; flex-wrap: wrap; }.modal-actions .danger-link { width: 100%; text-align: left; }.modal-actions .primary-button { flex: 1; }
  .toast-stack { right: 10px; bottom: 140px; left: 10px; }.toast { min-width: 0; }
}

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; } }
