/* SidPin OS · SIDPIN Digital brand: white, royal blue, bold geometric type, spaced blue labels, rounded cards */
:root {
  --bg: #F5F6FA; --panel: #FFFFFF; --ink: #10132A; --body: #3E4357; --muted: #767B90; --faint: #A4A9BA;
  --line: #E5E7EF; --line2: #EEF0F5; --blue: #3D55E0; --blue-d: #2E44C4; --blue-soft: #EEF1FD; --blue-soft2: #DCE3FC;
  --green: #18936A; --green-soft: #E5F5EE; --amber: #B87A0E; --amber-soft: #FCF3E1; --red: #D14343; --red-soft: #FBEAEA;
  --violet: #7349D6; --violet-soft: #F0EBFC; --teal: #0E8E8A; --teal-soft: #E2F4F3; --grey-soft: #F0F1F5;
  --r: 16px; --r-sm: 10px;
  --shadow: 0 1px 2px rgba(16,19,42,.04), 0 8px 28px rgba(16,19,42,.05);
  --shadow-lg: 0 24px 70px rgba(16,19,42,.18), 0 2px 8px rgba(16,19,42,.06);
  --side: 244px;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body { font-family: 'Manrope', -apple-system, 'Segoe UI', Arial, sans-serif; font-size: 13.5px; line-height: 1.45; color: var(--body); background: var(--bg); -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--blue); text-decoration: none; cursor: pointer; }
h1, h2, h3, h4 { color: var(--ink); margin: 0; letter-spacing: -.015em; }
code { background: var(--grey-soft); padding: 2px 6px; border-radius: 6px; font-size: 12px; word-break: break-all; }
[hidden] { display: none !important; }
.muted { color: var(--muted); } .faint { color: var(--faint); } .small { font-size: 12px; } .ink { color: var(--ink); } .b { font-weight: 700; }
.nowrap { white-space: nowrap; } .ellipsis { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.row { display: flex; align-items: center; gap: 10px; } .row.wrap { flex-wrap: wrap; } .row.top { align-items: flex-start; } .grow { flex: 1; min-width: 0; } .sp { margin-left: auto; }
.stack > * + * { margin-top: 14px; } .gap-s > * + * { margin-top: 8px; }

/* ---------- brand mark ---------- */
.mark { width: 30px; height: 30px; border-radius: 8px; background: var(--blue); position: relative; display: inline-block; flex: none; box-shadow: 0 4px 12px rgba(61,85,224,.28); }
.mark i { position: absolute; top: 4px; right: 4px; width: 9px; height: 9px; background: var(--ink); border-radius: 2px; }
.boot { height: 100vh; display: grid; place-items: center; }
.boot .mark { animation: pulse 1.2s ease-in-out infinite; }
@keyframes pulse { 50% { transform: scale(.86); opacity: .7; } }

/* ---------- layout ---------- */
.app { display: grid; grid-template-columns: var(--side) 1fr; min-height: 100vh; }
.side { position: sticky; top: 0; height: 100vh; background: var(--panel); border-right: 1px solid var(--line); display: flex; flex-direction: column; padding: 20px 14px 14px; overflow-y: auto; z-index: 30; }
.brand { display: flex; align-items: center; gap: 11px; padding: 0 8px 20px; }
.brand b { display: block; color: var(--ink); font-weight: 800; font-size: 15px; letter-spacing: .06em; line-height: 1; }
.brand span { display: block; color: var(--blue); font-weight: 700; font-size: 8.5px; letter-spacing: .36em; margin-top: 5px; }
.side .quick { margin: 0 2px 16px; }
.side .quick .btn { width: 100%; justify-content: center; }
.nav-lbl { color: var(--faint); font-size: 9.5px; font-weight: 800; letter-spacing: .26em; text-transform: uppercase; padding: 14px 12px 6px; }
.nav a { display: flex; align-items: center; gap: 11px; padding: 8px 12px; border-radius: 10px; color: var(--body); font-weight: 650; margin-bottom: 1px; }
svg { width: 16px; height: 16px; flex: none; vertical-align: -3px; }
.nav a svg { width: 18px; height: 18px; color: var(--faint); flex: none; }
.nav a:hover { background: var(--bg); }
.nav a.on { background: var(--blue-soft); color: var(--blue); }
.nav a.on svg { color: var(--blue); }
.nav a .count { margin-left: auto; font-size: 10.5px; font-weight: 800; color: #fff; background: var(--red); border-radius: 20px; padding: 1px 7px; min-width: 20px; text-align: center; }
.nav a .count.soft { background: var(--grey-soft); color: var(--muted); }
.side .me { margin-top: auto; padding: 10px; border-radius: 12px; background: var(--bg); display: flex; align-items: center; gap: 10px; cursor: pointer; }
.side .me:hover { background: var(--blue-soft); }
.side .me b { display: block; color: var(--ink); font-size: 12.5px; line-height: 1.2; }
.side .me span { font-size: 11px; color: var(--muted); }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar { position: sticky; top: 0; z-index: 20; height: 60px; display: flex; align-items: center; gap: 12px; padding: 0 28px; background: rgba(245,246,250,.88); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
.topbar .burger { display: none; }
.searchbox { flex: 0 1 420px; height: 38px; border: 1px solid var(--line); background: #fff; border-radius: 11px; display: flex; align-items: center; gap: 9px; padding: 0 12px; color: var(--faint); cursor: text; }
.searchbox svg { width: 16px; height: 16px; }
.searchbox span { flex: 1; font-weight: 600; font-size: 13px; }
.kbd { font-size: 10.5px; font-weight: 800; color: var(--muted); background: var(--grey-soft); border-radius: 6px; padding: 2px 6px; border: 1px solid var(--line); }
.topbar .right { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.iconbtn { width: 38px; height: 38px; border-radius: 11px; border: 1px solid var(--line); background: #fff; display: grid; place-items: center; cursor: pointer; position: relative; color: var(--body); }
.iconbtn:hover { border-color: #CDD2E0; }
.iconbtn svg { width: 18px; height: 18px; }
.iconbtn .dot { position: absolute; top: -4px; right: -4px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 10px; background: var(--red); color: #fff; font-size: 10px; font-weight: 800; display: grid; place-items: center; border: 2px solid var(--bg); }
.avail { height: 38px; border-radius: 11px; border: 1px solid var(--line); background: #fff; display: flex; align-items: center; gap: 8px; padding: 0 12px; cursor: pointer; font-weight: 700; font-size: 12.5px; color: var(--ink); }
.adot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex: none; }
.a-working { background: var(--green); } .a-on_break { background: var(--amber); } .a-on_leave { background: var(--violet); } .a-unavailable { background: var(--faint); }
.page { padding: 6px 28px 70px; width: 100%; max-width: 1360px; margin: 0 auto; }

.head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin: 6px 0 22px; flex-wrap: wrap; }
.eyebrow { color: var(--blue); font-size: 10.5px; font-weight: 800; letter-spacing: .26em; text-transform: uppercase; margin-bottom: 7px; display: flex; align-items: center; gap: 10px; }
.eyebrow::after { content: ''; width: 34px; height: 1px; background: var(--blue-soft2); }
.head h1 { font-size: 27px; font-weight: 800; }
.head .sub { color: var(--muted); margin-top: 4px; }
.head .actions { display: flex; gap: 8px; flex-wrap: wrap; }
.crumb { color: var(--muted); font-weight: 700; display: inline-flex; align-items: center; gap: 6px; margin-bottom: 8px; font-size: 12.5px; }
.crumb:hover { color: var(--blue); }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 14px; border-radius: 10px; border: 1px solid var(--line); background: #fff; color: var(--ink); font-weight: 700; font-size: 13px; cursor: pointer; white-space: nowrap; transition: background .12s, border-color .12s, box-shadow .12s, transform .06s; text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn svg { width: 16px; height: 16px; flex: none; }
.btn:hover { border-color: #CBD0DF; background: #FBFBFD; }
.btn.primary { background: var(--blue); border-color: var(--blue); color: #fff; box-shadow: 0 3px 10px rgba(61,85,224,.26); }
.btn.primary:hover { background: var(--blue-d); }
.btn.soft { background: var(--blue-soft); border-color: transparent; color: var(--blue); }
.btn.soft:hover { background: var(--blue-soft2); }
.btn.ghost { border-color: transparent; background: transparent; color: var(--muted); }
.btn.ghost:hover { background: var(--grey-soft); color: var(--ink); }
.btn.good { background: var(--green); border-color: var(--green); color: #fff; }
.btn.good:hover { filter: brightness(.95); }
.btn.warn { background: var(--amber-soft); border-color: transparent; color: var(--amber); }
.btn.danger { color: var(--red); }
.btn.danger:hover { background: var(--red-soft); border-color: #F1C6C6; }
.btn.sm { height: 30px; padding: 0 10px; font-size: 12px; border-radius: 8px; }
.btn.xs { height: 26px; padding: 0 8px; font-size: 11.5px; border-radius: 7px; gap: 5px; }
.btn.xs svg { width: 13px; height: 13px; }
.btn.big { height: 46px; padding: 0 22px; font-size: 14px; border-radius: 12px; width: 100%; justify-content: center; }
.btn.icon { width: 36px; padding: 0; justify-content: center; }
.btn.sm.icon { width: 30px; }
.btn:disabled { opacity: .5; cursor: default; }

/* ---------- cards ---------- */
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); min-width: 0; }
.card-h { display: flex; align-items: center; gap: 10px; padding: 15px 20px; border-bottom: 1px solid var(--line2); }
.card-h h3 { font-size: 14.5px; font-weight: 800; }
.card-h .lbl + h3 { margin-left: 0; }
.card-h .sp { display: flex; gap: 6px; align-items: center; }
.card-b { padding: 18px 20px; }
.card-b.flush { padding: 0; }
.card + .card { margin-top: 18px; }
.lbl { color: var(--blue); font-size: 10px; font-weight: 800; letter-spacing: .24em; text-transform: uppercase; }
.lbl.grey { color: var(--faint); }
.grid { display: grid; gap: 18px; }
.g2 { grid-template-columns: 1fr 1fr; } .g3 { grid-template-columns: repeat(3, 1fr); } .g4 { grid-template-columns: repeat(4, 1fr); }
.g21 { grid-template-columns: 1.6fr 1fr; } .g12 { grid-template-columns: 1fr 1.6fr; }
.grid > .card + .card { margin-top: 0; }

/* ---------- hero ("What should I do today?") ---------- */
.hero { background: linear-gradient(135deg, #3D55E0 0%, #2E44C4 100%); color: #fff; border-radius: 20px; padding: 26px 28px; position: relative; overflow: hidden; margin-bottom: 18px; box-shadow: 0 14px 40px rgba(61,85,224,.25); }
.hero::after { content: ''; position: absolute; right: -40px; top: -40px; width: 220px; height: 220px; border-radius: 40px; background: rgba(255,255,255,.07); transform: rotate(18deg); }
.hero::before { content: ''; position: absolute; right: 70px; top: 26px; width: 26px; height: 26px; border-radius: 6px; background: var(--ink); opacity: .9; }
.hero .eyebrow { color: rgba(255,255,255,.75); } .hero .eyebrow::after { background: rgba(255,255,255,.3); }
.hero h1 { color: #fff; font-size: 28px; font-weight: 800; }
.hero p { margin: 6px 0 0; color: rgba(255,255,255,.85); font-size: 14px; max-width: 640px; }
.hero .hero-stats { display: flex; gap: 26px; margin-top: 20px; flex-wrap: wrap; position: relative; z-index: 1; }
.hero .hero-stats div b { display: block; font-size: 24px; font-weight: 800; color: #fff; line-height: 1.1; }
.hero .hero-stats div span { font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: rgba(255,255,255,.7); }
.hero .hero-actions { display: flex; gap: 8px; margin-top: 20px; position: relative; z-index: 1; flex-wrap: wrap; }
.hero .btn { background: rgba(255,255,255,.14); border-color: rgba(255,255,255,.22); color: #fff; }
.hero .btn:hover { background: rgba(255,255,255,.24); }
.hero .btn.white { background: #fff; color: var(--blue); border-color: #fff; }

/* ---------- stats ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; margin-bottom: 18px; }
.stat { padding: 16px 18px; cursor: default; }
.stat.link { cursor: pointer; } .stat.link:hover { border-color: var(--blue-soft2); }
.stat .k { color: var(--muted); font-weight: 700; font-size: 12px; display: flex; align-items: center; gap: 8px; }
.stat .k i { width: 8px; height: 8px; border-radius: 3px; display: inline-block; }
.stat .v { color: var(--ink); font-size: 26px; font-weight: 800; letter-spacing: -.02em; margin-top: 6px; line-height: 1.1; }
.stat .s { color: var(--muted); font-size: 11.5px; margin-top: 3px; }
.stat.alert .v { color: var(--red); }

/* ---------- task rows ---------- */
.tlist { list-style: none; margin: 0; padding: 0; }
.trow { display: flex; align-items: center; gap: 12px; padding: 11px 20px; border-bottom: 1px solid var(--line2); cursor: pointer; transition: background .1s; min-width: 0; }
.trow:last-child { border-bottom: 0; }
.trow:hover { background: #FAFBFE; }
.trow .tt { flex: 1; min-width: 0; }
.trow .tt b { display: block; color: var(--ink); font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.trow .tt span { display: block; color: var(--muted); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-top: 1px; }
.trow .acts { display: flex; gap: 6px; flex: none; }
.pdot { width: 9px; height: 9px; border-radius: 50%; flex: none; }
.p-urgent { background: var(--red); box-shadow: 0 0 0 3px var(--red-soft); } .p-high { background: #E8833A; } .p-medium { background: var(--blue); opacity: .55; } .p-low { background: var(--faint); opacity: .6; }
.due { font-size: 12px; font-weight: 700; color: var(--muted); white-space: nowrap; }
.due.late { color: var(--red); } .due.today { color: var(--amber); }
.tag { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 8px; border-radius: 6px; font-size: 11px; font-weight: 700; background: var(--grey-soft); color: var(--muted); white-space: nowrap; }
.tag i { width: 7px; height: 7px; border-radius: 2px; display: inline-block; }
.tag.blue { background: var(--blue-soft); color: var(--blue); } .tag.red { background: var(--red-soft); color: var(--red); } .tag.green { background: var(--green-soft); color: var(--green); } .tag.amber { background: var(--amber-soft); color: var(--amber); } .tag.violet { background: var(--violet-soft); color: var(--violet); }

/* ---------- status badges ---------- */
.st { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 10px; border-radius: 20px; font-size: 11.5px; font-weight: 750; white-space: nowrap; }
.st::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.s-backlog { background: var(--grey-soft); color: #7D8297; } .s-todo { background: #EEF0F7; color: #4A5170; }
.s-in_progress { background: var(--blue-soft); color: var(--blue); } .s-in_review { background: var(--violet-soft); color: var(--violet); }
.s-changes_requested { background: var(--amber-soft); color: var(--amber); } .s-approved { background: var(--teal-soft); color: var(--teal); }
.s-completed { background: var(--green-soft); color: var(--green); } .s-blocked { background: var(--red-soft); color: var(--red); } .s-cancelled { background: var(--grey-soft); color: var(--faint); text-decoration: line-through; }
.st.click { cursor: pointer; }
.ds-planned { background: #EEF0F7; color: #4A5170; } .ds-started { background: var(--blue-soft); color: var(--blue); } .ds-completed { background: var(--green-soft); color: var(--green); } .ds-submitted { background: var(--violet-soft); color: var(--violet); } .ds-blocked { background: var(--red-soft); color: var(--red); }

/* ---------- avatars ---------- */
.av { width: 30px; height: 30px; border-radius: 50%; background: var(--blue-soft); color: var(--blue); display: inline-grid; place-items: center; font-size: 11px; font-weight: 800; flex: none; overflow: hidden; letter-spacing: .02em; }
.av img { width: 100%; height: 100%; object-fit: cover; }
.av.sm { width: 24px; height: 24px; font-size: 9.5px; } .av.lg { width: 56px; height: 56px; font-size: 18px; } .av.xl { width: 84px; height: 84px; font-size: 26px; }
.avs { display: flex; } .avs .av { border: 2px solid #fff; margin-left: -7px; } .avs .av:first-child { margin-left: 0; }

/* ---------- progress ---------- */
.bar { height: 7px; border-radius: 10px; background: var(--grey-soft); overflow: hidden; flex: 1; min-width: 50px; }
.bar i { display: block; height: 100%; background: var(--blue); border-radius: 10px; transition: width .3s; }
.bar.green i { background: var(--green); } .bar.red i { background: var(--red); } .bar.amber i { background: var(--amber); }
.pct { font-weight: 800; color: var(--ink); font-size: 12px; min-width: 34px; text-align: right; }

/* ---------- tables ---------- */
.toolbar { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-bottom: 1px solid var(--line2); flex-wrap: wrap; }
.toolbar .right { margin-left: auto; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.chips { display: flex; gap: 4px; flex-wrap: wrap; }
.chip { height: 30px; padding: 0 12px; border-radius: 20px; border: 1px solid transparent; background: transparent; color: var(--muted); font-weight: 700; font-size: 12px; cursor: pointer; white-space: nowrap; }
.chip:hover { background: var(--grey-soft); }
.chip.on { background: var(--ink); color: #fff; }
.chip .n { opacity: .6; margin-left: 4px; }
.tablewrap { overflow-x: auto; }
table.list { width: 100%; border-collapse: collapse; }
.list th { text-align: left; color: var(--muted); font-size: 10px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; padding: 10px 14px; border-bottom: 1px solid var(--line2); background: #FBFBFD; white-space: nowrap; }
.list td { padding: 11px 14px; border-bottom: 1px solid var(--line2); vertical-align: middle; }
.list tr:last-child td { border-bottom: 0; }
.list tbody tr.click { cursor: pointer; }
.list tbody tr.click:hover { background: #FAFBFE; }
.list .r { text-align: right; } .list .c { text-align: center; }
.list .strong { color: var(--ink); font-weight: 700; }
.list .num { color: var(--ink); font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.list .sm { color: var(--muted); font-size: 12px; }
.list .group td { background: #FBFBFD; color: var(--ink); font-weight: 800; font-size: 12px; padding: 8px 14px; }
.empty { text-align: center; padding: 44px 20px; color: var(--muted); }
.empty .ill { width: 50px; height: 50px; border-radius: 15px; background: var(--blue-soft); color: var(--blue); display: grid; place-items: center; margin: 0 auto 12px; }
.empty .ill svg { width: 24px; height: 24px; }
.empty h3 { font-size: 15px; margin-bottom: 4px; }
.empty .btn { margin-top: 14px; }
.empty.sm { padding: 22px 16px; }

/* ---------- forms ---------- */
.input, select.input, textarea.input { width: 100%; height: 38px; padding: 0 12px; border: 1px solid #DCE0EB; border-radius: var(--r-sm); background: #fff; outline: none; transition: border-color .12s, box-shadow .12s; color: var(--ink); }
textarea.input { height: auto; min-height: 80px; padding: 10px 12px; resize: vertical; line-height: 1.5; }
select.input { appearance: none; -webkit-appearance: none; padding-right: 30px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%237A7F93' stroke-width='2.5' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 11px center; }
select.input[multiple] { height: auto; min-height: 110px; padding: 6px; background-image: none; }
.input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(61,85,224,.14); }
.input::placeholder { color: var(--faint); }
.input.sm { height: 32px; font-size: 12.5px; border-radius: 8px; }
.input.bare { border-color: transparent; background: transparent; padding-left: 0; }
.input.bare:hover { background: var(--bg); padding-left: 8px; }
.input.bare:focus { background: #fff; border-color: var(--blue); padding-left: 12px; }
.input.title { font-size: 20px; font-weight: 800; height: 46px; letter-spacing: -.01em; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > label, .flabel { font-size: 11.5px; font-weight: 750; color: var(--ink); }
.field > label em { font-style: normal; color: var(--faint); font-weight: 600; }
.field .hint, .hint { font-size: 11.5px; color: var(--muted); }
.fgrid { display: grid; gap: 14px 16px; }
.c2 { grid-template-columns: 1fr 1fr; } .c3 { grid-template-columns: repeat(3, 1fr); } .c4 { grid-template-columns: repeat(4, 1fr); }
.span2 { grid-column: span 2; } .full { grid-column: 1 / -1; }
.seg { display: inline-flex; background: var(--grey-soft); border-radius: 10px; padding: 3px; flex-wrap: wrap; }
.seg button { border: 0; background: transparent; height: 30px; padding: 0 12px; border-radius: 8px; font-weight: 750; color: var(--muted); cursor: pointer; font-size: 12.5px; display: inline-flex; align-items: center; gap: 6px; }
.seg button svg { width: 15px; height: 15px; }
.seg button.on { background: #fff; color: var(--ink); box-shadow: 0 1px 3px rgba(16,19,42,.1); }
.check { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-weight: 650; color: var(--ink); }
.check input { width: 16px; height: 16px; accent-color: var(--blue); flex: none; }
.switch { position: relative; width: 38px; height: 22px; flex: none; display: inline-block; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch span { position: absolute; inset: 0; border-radius: 20px; background: #D5D9E5; transition: .15s; cursor: pointer; }
.switch span::after { content: ''; position: absolute; width: 16px; height: 16px; left: 3px; top: 3px; border-radius: 50%; background: #fff; transition: .15s; box-shadow: 0 1px 3px rgba(0,0,0,.15); }
.switch input:checked + span { background: var(--blue); }
.switch input:checked + span::after { transform: translateX(16px); }
.alert { padding: 12px 14px; border-radius: 12px; font-weight: 600; font-size: 12.5px; margin: 10px 0; line-height: 1.5; }
.alert.bad { background: var(--red-soft); color: #A33030; } .alert.good { background: var(--green-soft); color: #136F50; } .alert.info { background: var(--blue-soft); color: var(--blue-d); } .alert.warn { background: var(--amber-soft); color: #8A5B07; }
.steps { counter-reset: s; list-style: none; padding: 0; margin: 0; }
.steps li { counter-increment: s; position: relative; padding: 0 0 14px 38px; line-height: 1.55; }
.steps li::before { content: counter(s); position: absolute; left: 0; top: -2px; width: 26px; height: 26px; border-radius: 8px; background: var(--blue-soft); color: var(--blue); font-weight: 800; display: grid; place-items: center; font-size: 12px; }

/* ---------- kanban ---------- */
.board { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(260px, 1fr); gap: 14px; overflow-x: auto; padding-bottom: 12px; align-items: start; }
.col { background: #EDEFF5; border-radius: 14px; padding: 10px; min-height: 120px; }
.col.drop { background: var(--blue-soft2); }
.col-h { display: flex; align-items: center; gap: 8px; padding: 4px 6px 10px; }
.col-h b { color: var(--ink); font-size: 12.5px; }
.col-h .n { margin-left: auto; font-size: 11px; font-weight: 800; color: var(--muted); background: #fff; border-radius: 20px; padding: 1px 8px; }
.kcard { background: #fff; border-radius: 11px; padding: 11px 12px; border: 1px solid var(--line); box-shadow: 0 1px 2px rgba(16,19,42,.04); cursor: grab; margin-bottom: 8px; }
.kcard:hover { border-color: #CDD3E4; }
.kcard.dragging { opacity: .5; }
.kcard b { display: block; color: var(--ink); font-weight: 700; font-size: 13px; line-height: 1.35; margin-bottom: 8px; }
.kcard .meta { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.kcard .meta .sp { margin-left: auto; }

/* ---------- drawer & modal ---------- */
.scrim { position: fixed; inset: 0; background: rgba(16,19,42,.32); z-index: 80; animation: fade .15s; }
@keyframes fade { from { opacity: 0; } }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(760px, 100vw); background: var(--bg); z-index: 90; box-shadow: var(--shadow-lg); display: flex; flex-direction: column; animation: slide .2s cubic-bezier(.2,.8,.2,1); }
@keyframes slide { from { transform: translateX(40px); opacity: 0; } }
.drawer-h { display: flex; align-items: center; gap: 10px; padding: 14px 20px; background: #fff; border-bottom: 1px solid var(--line); }
.drawer-b { flex: 1; overflow-y: auto; padding: 20px; }
.modal-wrap { position: fixed; inset: 0; z-index: 100; display: grid; place-items: start center; padding: 8vh 16px 16px; overflow-y: auto; }
.modal { background: #fff; border-radius: 18px; box-shadow: var(--shadow-lg); width: min(560px, 100%); animation: pop .16s cubic-bezier(.2,.8,.2,1); }
.modal.wide { width: min(780px, 100%); }
@keyframes pop { from { transform: translateY(10px) scale(.98); opacity: 0; } }
.modal-h { padding: 20px 22px 0; }
.modal-h h2 { font-size: 19px; font-weight: 800; }
.modal-h p { margin: 4px 0 0; color: var(--muted); }
.modal-b { padding: 18px 22px; }
.modal-f { padding: 14px 22px; border-top: 1px solid var(--line2); display: flex; justify-content: flex-end; gap: 8px; flex-wrap: wrap; }
.toasts { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.toast { background: var(--ink); color: #fff; padding: 11px 18px; border-radius: 12px; font-weight: 650; box-shadow: var(--shadow-lg); animation: pop .2s; max-width: 90vw; pointer-events: auto; }
.toast.bad { background: var(--red); }
.menu { position: fixed; z-index: 150; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); padding: 6px; min-width: 200px; animation: pop .12s; max-height: 70vh; overflow-y: auto; }
.menu button, .menu a { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; padding: 9px 11px; border: 0; background: transparent; border-radius: 8px; cursor: pointer; color: var(--ink); font-weight: 650; font-size: 13px; }
.menu button:hover, .menu a:hover, .menu .on { background: var(--bg); }
.menu svg { width: 16px; height: 16px; color: var(--muted); }
.menu hr { border: 0; border-top: 1px solid var(--line2); margin: 5px 0; }

/* ---------- command palette ---------- */
.palette { width: min(620px, 100%); background: #fff; border-radius: 18px; box-shadow: var(--shadow-lg); overflow: hidden; animation: pop .14s; }
.palette input { width: 100%; border: 0; outline: 0; padding: 18px 20px; font-size: 16px; font-weight: 600; color: var(--ink); border-bottom: 1px solid var(--line2); }
.palette .res { max-height: 420px; overflow-y: auto; padding: 6px; }
.palette .it { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 10px; cursor: pointer; }
.palette .it.on, .palette .it:hover { background: var(--blue-soft); }
.palette .it .ic { width: 30px; height: 30px; border-radius: 9px; background: var(--grey-soft); display: grid; place-items: center; color: var(--muted); flex: none; }
.palette .it .ic svg { width: 16px; height: 16px; }
.palette .it b { color: var(--ink); font-weight: 700; display: block; }
.palette .it span { font-size: 12px; color: var(--muted); }
.palette .hd { font-size: 10px; font-weight: 800; letter-spacing: .2em; text-transform: uppercase; color: var(--faint); padding: 10px 14px 4px; }

/* ---------- task detail ---------- */
.tdetail .actbar { display: flex; gap: 8px; flex-wrap: wrap; margin: 12px 0 16px; }
.props { display: grid; grid-template-columns: 130px 1fr; gap: 6px 14px; align-items: center; }
.props > .k { color: var(--muted); font-weight: 700; font-size: 12px; }
.props > .v { min-width: 0; }
.props .input { height: 34px; }
.depline { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 10px; background: var(--bg); margin-bottom: 6px; }
.chk { display: flex; align-items: center; gap: 10px; padding: 6px 4px; border-radius: 8px; }
.chk:hover { background: var(--bg); }
.chk.done span { text-decoration: line-through; color: var(--faint); }
.chk .x { margin-left: auto; opacity: 0; }
.chk:hover .x { opacity: 1; }
.comments { display: flex; flex-direction: column; gap: 14px; }
.cmt { display: flex; gap: 10px; }
.cmt .bubble { flex: 1; background: #fff; border: 1px solid var(--line); border-radius: 4px 14px 14px 14px; padding: 10px 13px; min-width: 0; }
.cmt .bubble .who { display: flex; gap: 8px; align-items: center; font-size: 12px; margin-bottom: 3px; }
.cmt .bubble .who b { color: var(--ink); }
.cmt .bubble .txt { white-space: pre-wrap; word-wrap: break-word; color: var(--body); }
.cmt.reply { margin-left: 38px; }
.cmt.k-blocker .bubble { border-color: #F2C8C8; background: #FFF8F8; }
.cmt.k-feedback .bubble { border-color: #E2D8F8; background: #FBF9FF; }
.cmt.k-question .bubble, .cmt.k-clarification .bubble { border-color: #F3E1B8; background: #FFFCF4; }
.cmt.k-extension .bubble { border-color: var(--blue-soft2); background: #F8F9FF; }
.cmt.k-system .bubble { background: var(--bg); border-style: dashed; }
.mention { color: var(--blue); font-weight: 700; background: var(--blue-soft); border-radius: 5px; padding: 0 4px; }
.composer { position: relative; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 8px; }
.composer textarea { border: 0; outline: 0; width: 100%; resize: vertical; min-height: 60px; padding: 4px 6px; }
.composer .bar2 { display: flex; gap: 6px; align-items: center; }
.mpick { position: absolute; left: 10px; bottom: calc(100% + 4px); background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); padding: 5px; min-width: 220px; z-index: 5; }
.mpick div { padding: 7px 10px; border-radius: 8px; cursor: pointer; display: flex; gap: 8px; align-items: center; font-weight: 650; color: var(--ink); }
.mpick div.on, .mpick div:hover { background: var(--blue-soft); }
.feed { list-style: none; margin: 0; padding: 0; }
.feed li { display: flex; gap: 10px; padding: 8px 0; border-bottom: 1px dashed var(--line); font-size: 12.5px; align-items: flex-start; }
.feed li:last-child { border-bottom: 0; }
.feed li .when { margin-left: auto; color: var(--faint); font-size: 11px; white-space: nowrap; padding-left: 8px; }
.file { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--line); background: #fff; margin-bottom: 8px; }
.file .thumb { width: 42px; height: 42px; border-radius: 9px; background: var(--grey-soft); display: grid; place-items: center; overflow: hidden; flex: none; color: var(--muted); font-size: 10px; font-weight: 800; text-transform: uppercase; }
.file .thumb img { width: 100%; height: 100%; object-fit: cover; }
.drop-zone { border: 1.5px dashed #C9CFE0; border-radius: 12px; padding: 14px; text-align: center; color: var(--muted); cursor: pointer; font-weight: 650; }
.drop-zone:hover, .drop-zone.on { border-color: var(--blue); color: var(--blue); background: var(--blue-soft); }

/* ---------- my work ---------- */
.daysteps { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin-bottom: 18px; }
.daysteps > div { background: #fff; border: 1px solid var(--line); border-radius: 13px; padding: 12px 14px; display: flex; gap: 10px; align-items: center; }
.daysteps > div i { width: 26px; height: 26px; border-radius: 8px; background: var(--grey-soft); color: var(--muted); display: grid; place-items: center; font-style: normal; font-weight: 800; font-size: 12px; flex: none; }
.daysteps > div.done i { background: var(--green); color: #fff; }
.daysteps > div.now { border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-soft); }
.daysteps > div.now i { background: var(--blue); color: #fff; }
.daysteps b { color: var(--ink); font-size: 12.5px; display: block; line-height: 1.2; }
.daysteps span { font-size: 11px; color: var(--muted); }
.plan-card { border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; background: #fff; margin-bottom: 10px; }
.plan-card.st-started { border-color: var(--blue-soft2); box-shadow: inset 3px 0 0 var(--blue); }
.plan-card.st-completed, .plan-card.st-submitted { background: #FBFDFC; }
.plan-card.st-completed b.t { text-decoration: line-through; color: var(--muted); }
.plan-card .top { display: flex; gap: 10px; align-items: center; }
.plan-card .top b.t { color: var(--ink); font-weight: 750; flex: 1; min-width: 0; cursor: pointer; }
.plan-card .out { margin-top: 8px; }
.timer { font-variant-numeric: tabular-nums; font-weight: 800; color: var(--blue); }
.qa { display: grid; gap: 14px; }
.qa .q { font-weight: 750; color: var(--ink); font-size: 13px; margin-bottom: 5px; }
.auto-note { display: flex; gap: 8px; align-items: center; font-size: 11.5px; color: var(--green); font-weight: 700; margin-bottom: 4px; }

/* ---------- calendar ---------- */
.cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); border-top: 1px solid var(--line2); }
.cal .dow { padding: 8px 10px; font-size: 10px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--faint); border-bottom: 1px solid var(--line2); }
.cal .day { min-height: 112px; border-right: 1px solid var(--line2); border-bottom: 1px solid var(--line2); padding: 6px; min-width: 0; }
.cal .day:nth-child(7n) { border-right: 0; }
.cal .day.out { background: #FBFBFD; } .cal .day.out .dn { color: var(--faint); }
.cal .day.today .dn { background: var(--blue); color: #fff; }
.cal .dn { display: inline-grid; place-items: center; min-width: 24px; height: 24px; border-radius: 8px; font-weight: 800; font-size: 12px; color: var(--ink); margin-bottom: 4px; }
.cal .ev { display: block; font-size: 11px; font-weight: 700; padding: 3px 6px; border-radius: 6px; margin-bottom: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; cursor: pointer; background: var(--blue-soft); color: var(--blue-d); border-left: 3px solid var(--blue); }
.cal .ev.t-project { background: var(--ink); color: #fff; border-left-color: var(--ink); }
.cal .ev.t-milestone { background: var(--violet-soft); color: var(--violet); border-left-color: var(--violet); }
.cal .ev.t-followup { background: var(--amber-soft); color: var(--amber); border-left-color: var(--amber); }
.cal .ev.t-leave { background: var(--grey-soft); color: var(--muted); border-left-color: var(--faint); }
.cal .ev.t-holiday { background: var(--green-soft); color: var(--green); border-left-color: var(--green); }
.cal .ev.done { opacity: .5; text-decoration: line-through; }
.cal .ev.late { background: var(--red-soft); color: var(--red); border-left-color: var(--red); }
.cal .more { font-size: 11px; color: var(--muted); font-weight: 700; padding: 0 6px; cursor: pointer; }

/* ---------- timeline (gantt) ---------- */
.gantt { overflow-x: auto; }
.gantt .grow-row { display: grid; grid-template-columns: 240px 1fr; border-bottom: 1px solid var(--line2); min-height: 38px; align-items: center; }
.gantt .gl { padding: 6px 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 650; color: var(--ink); cursor: pointer; }
.gantt .gt { position: relative; height: 38px; }
.gantt .gb { position: absolute; top: 10px; height: 18px; border-radius: 6px; background: var(--blue); opacity: .85; min-width: 6px; cursor: pointer; }
.gantt .gb.done { background: var(--green); } .gantt .gb.late { background: var(--red); } .gantt .gb.blocked { background: var(--red); opacity: .6; }
.gantt .ghead { display: grid; grid-template-columns: 240px 1fr; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: #fff; }
.gantt .gticks { position: relative; height: 30px; }
.gantt .gticks span { position: absolute; top: 8px; font-size: 10px; font-weight: 800; color: var(--faint); transform: translateX(-50%); white-space: nowrap; }
.gantt .gtoday { position: absolute; top: 0; bottom: 0; width: 2px; background: var(--red); opacity: .5; }

/* ---------- people ---------- */
.pcard { padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.pcard .top { display: flex; gap: 12px; align-items: center; cursor: pointer; }
.pcard .top b { color: var(--ink); display: block; font-weight: 800; }
.pcard .top span { font-size: 12px; color: var(--muted); }
.pcard .nums { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.pcard .nums div { background: var(--bg); border-radius: 10px; padding: 8px; text-align: center; }
.pcard .nums b { display: block; color: var(--ink); font-size: 17px; font-weight: 800; line-height: 1.1; }
.pcard .nums span { font-size: 10px; color: var(--muted); font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.pcard .nums .bad b { color: var(--red); }
.warnline { background: var(--amber-soft); color: #8A5B07; border-radius: 10px; padding: 8px 10px; font-size: 12px; font-weight: 700; }
.perm-grid { width: 100%; border-collapse: collapse; }
.perm-grid th, .perm-grid td { padding: 8px 10px; border-bottom: 1px solid var(--line2); }
.perm-grid th { font-size: 10px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); text-align: center; vertical-align: bottom; }
.perm-grid td:not(:first-child) { text-align: center; }
.perm-grid .grp td { background: #FBFBFD; color: var(--blue); font-size: 10px; font-weight: 800; letter-spacing: .2em; text-transform: uppercase; }

/* ---------- report bars ---------- */
.hbar { display: grid; grid-template-columns: 160px 1fr 50px; gap: 10px; align-items: center; padding: 6px 0; }
.hbar .n { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 650; color: var(--ink); }
.stackbar { display: flex; height: 10px; border-radius: 6px; overflow: hidden; background: var(--grey-soft); }
.stackbar i { display: block; height: 100%; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 11.5px; color: var(--muted); font-weight: 650; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 9px; height: 9px; border-radius: 3px; display: inline-block; }

/* ---------- settings ---------- */
.settings { display: grid; grid-template-columns: 220px 1fr; gap: 20px; align-items: start; }
.subnav { position: sticky; top: 72px; display: flex; flex-direction: column; gap: 2px; }
.subnav a { padding: 9px 12px; border-radius: 10px; color: var(--body); font-weight: 650; }
.subnav a:hover { background: #fff; }
.subnav a.on { background: #fff; color: var(--blue); box-shadow: var(--shadow); }
.rule { display: flex; gap: 14px; align-items: flex-start; padding: 14px 20px; border-bottom: 1px solid var(--line2); }
.rule:last-child { border-bottom: 0; }
.rule .rt { flex: 1; min-width: 0; }
.rule .rt b { color: var(--ink); display: block; }
.rule .when { font-size: 10.5px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--blue); }

/* ---------- auth ---------- */
.auth-body { min-height: 100vh; background: radial-gradient(1200px 600px at 100% -10%, #E4E9FD 0%, transparent 60%), var(--bg); }
.auth-wrap { max-width: 440px; margin: 0 auto; padding: 8vh 18px 40px; }
.auth-wrap.wide { max-width: 640px; }
.auth-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 22px; }
.auth-brand .mark { width: 38px; height: 38px; border-radius: 10px; }
.auth-brand .mark i { width: 11px; height: 11px; top: 5px; right: 5px; }
.auth-brand b { display: block; color: var(--ink); font-weight: 800; font-size: 17px; letter-spacing: .08em; line-height: 1; }
.auth-brand span { display: block; color: var(--blue); font-weight: 700; font-size: 9px; letter-spacing: .36em; margin-top: 6px; }
.auth-card { background: #fff; border: 1px solid var(--line); border-radius: 20px; padding: 28px; box-shadow: var(--shadow); }
.auth-card h1 { font-size: 23px; font-weight: 800; margin-bottom: 6px; }
.auth-card .eyebrow { margin-top: 18px; } .auth-card .eyebrow:first-child { margin-top: 0; }
.auth-card label { display: flex; flex-direction: column; gap: 6px; font-size: 12px; font-weight: 750; color: var(--ink); margin: 12px 0; }
.auth-card label input, .auth-card label textarea { width: 100%; height: 42px; padding: 0 13px; border: 1px solid #DCE0EB; border-radius: 11px; outline: none; font-weight: 600; }
.auth-card label textarea { height: auto; padding: 10px 13px; }
.auth-card label input:focus, .auth-card label textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(61,85,224,.14); }
.auth-card .grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.auth-card .btn.big { margin-top: 14px; }
.auth-card.good { border-color: #BFE6D5; }
.auth-links { display: flex; justify-content: space-between; margin-top: 16px; font-weight: 650; font-size: 12.5px; }
.checks { list-style: none; padding: 0; margin: 12px 0; display: grid; grid-template-columns: 1fr 1fr; gap: 4px 14px; font-size: 12px; font-weight: 650; }
.checks .ok { color: var(--green); } .checks .bad { color: var(--red); }
.task-peek { background: var(--bg); border-radius: 12px; padding: 12px 14px; margin: 14px 0; }
.task-peek b { display: block; color: var(--ink); } .task-peek span { font-size: 12px; color: var(--muted); }

/* ---------- mobile ---------- */
.mnav { display: none; }
@media (max-width: 1100px) {
  .g4 { grid-template-columns: 1fr 1fr; } .g3 { grid-template-columns: 1fr 1fr; }
  .g21, .g12 { grid-template-columns: 1fr; }
  .daysteps { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 900px) {
  .app { grid-template-columns: 1fr; }
  .side { position: fixed; left: 0; top: 0; bottom: 0; width: 270px; transform: translateX(-100%); transition: transform .2s; box-shadow: var(--shadow-lg); }
  .app.nav-open .side { transform: none; }
  .app.nav-open::after { content: ''; position: fixed; inset: 0; background: rgba(16,19,42,.3); z-index: 25; }
  .topbar { padding: 0 16px; }
  .topbar .burger { display: grid; }
  .searchbox .kbd, .avail .lab { display: none; }
  .page { padding: 4px 16px 90px; }
  .settings { grid-template-columns: 1fr; }
  .subnav { position: static; flex-direction: row; overflow-x: auto; }
  .subnav a { white-space: nowrap; }
  .mnav { display: flex; position: fixed; bottom: 0; left: 0; right: 0; background: #fff; border-top: 1px solid var(--line); z-index: 40; padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); }
  .mnav a { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 10px; font-weight: 750; color: var(--muted); padding: 4px; }
  .mnav a svg { width: 20px; height: 20px; }
  .mnav a.on { color: var(--blue); }
  .mnav .plus { width: 44px; height: 44px; border-radius: 14px; background: var(--blue); color: #fff; display: grid; place-items: center; margin-top: -2px; box-shadow: 0 6px 16px rgba(61,85,224,.35); flex: none; }
}
@media (max-width: 680px) {
  .g2, .g3, .g4, .c2, .c3, .c4, .auth-card .grid2 { grid-template-columns: 1fr; }
  .span2 { grid-column: auto; }
  .head h1 { font-size: 23px; } .hero h1 { font-size: 23px; } .hero { padding: 22px; }
  .daysteps { grid-template-columns: 1fr 1fr; }
  .trow { padding: 11px 14px; flex-wrap: wrap; } .trow .acts { width: 100%; justify-content: flex-end; }
  .props { grid-template-columns: 1fr; gap: 2px; } .props > .k { margin-top: 8px; }
  .cal .day { min-height: 70px; padding: 3px; } .cal .ev { font-size: 9.5px; padding: 2px 4px; }
  .gantt .grow-row, .gantt .ghead { grid-template-columns: 130px 1fr; }
  .hbar { grid-template-columns: 100px 1fr 40px; }
  .drawer-b { padding: 14px; }
  .modal-wrap { padding-top: 3vh; }
  .checks { grid-template-columns: 1fr; }
  .card-h { padding: 13px 14px; } .card-b { padding: 14px; }
}
@media print { .side, .topbar, .mnav, .actions, .toolbar .right { display: none !important; } .app { display: block; } .card { box-shadow: none; } }

/* ---------- small fixes ---------- */
.stats > .card + .card, .board .card + .card { margin-top: 0; }
.chip svg { width: 14px; height: 14px; margin-right: 6px; }
.chips.scroll { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
