/* DRIMS team portal — standalone site shell (loaded after app.css on /portal) */
:root {
  --po-ink: #17153a;
  --po-side: #16143a;
  --po-side-2: #211e52;
  --po-side-text: #c9c6ec;
  --po-brand: #5b3df5;
  --po-brand-2: #7c5cff;
  --po-bg: #f4f3fa;
  --po-line: #e5e3f1;
  --po-side-w: 248px;
}
html.po-html, .po-body { margin: 0; padding: 0; background: var(--po-bg); min-height: 100%; }
.po-body { font-family: "Source Sans 3", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif; color: var(--po-ink); -webkit-font-smoothing: antialiased; }
.po-body * { box-sizing: border-box; }

/* dashboard tokens inside the portal */
.drims-ops--portal {
  --do-bg: #ffffff;
  --do-surface: #f6f5fb;
  --do-border: var(--po-line);
  --do-text: var(--po-ink);
  --do-muted: #6c6a86;
  --do-accent: var(--po-brand);
  max-width: none; margin: 0; padding: 0; background: transparent;
  font-family: "Source Sans 3", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif; font-size: 15px;
}
.drims-ops--portal h1, .drims-ops--portal h2, .drims-ops--portal h3, .po-wordmark, .po-login h1 { font-family: Montserrat, "Source Sans 3", sans-serif; letter-spacing: -0.01em; }
.drims-ops--portal .do-btn { background: var(--po-brand); border-color: var(--po-brand); }
.drims-ops--portal .do-btn:hover { background: #4a2ee0; }
.drims-ops--portal .do-btn--ghost { background: #fff; color: var(--po-ink); border-color: var(--po-line); }
.drims-ops--portal .do-btn--ghost:hover { background: var(--do-surface); }
.drims-ops--portal .do-kpi, .drims-ops--portal .do-tablewrap { background: #fff; }
.drims-ops--portal .do-section { margin-top: 22px; }
.pr-table td.do-nowrap .do-link { margin-left: 8px; }
.drims-ops--portal .drims-ops-loading { padding: 80px 20px; }

/* layout */
.po { display: flex; min-height: 100vh; }
.po-side {
  position: fixed; inset: 0 auto 0 0; width: var(--po-side-w); z-index: 40;
  display: flex; flex-direction: column; gap: 4px; padding: 18px 12px 12px;
  background: linear-gradient(180deg, var(--po-side) 0%, var(--po-side-2) 100%); color: var(--po-side-text);
  overflow-y: auto;
}
.po-side__brand { display: flex; flex-direction: column; gap: 2px; padding: 4px 10px 16px; border-bottom: 1px solid rgba(255,255,255,.08); margin-bottom: 8px; }
.po-side__brand img { max-width: 150px; max-height: 40px; object-fit: contain; object-position: left; filter: brightness(0) invert(1); }
.po-side .po-wordmark { color: #fff; font-weight: 800; font-size: 18px; }
.po-side__tag { font-size: 11px; text-transform: uppercase; letter-spacing: .12em; color: #8f8bc4; }
.po-nav.do-tabs { display: flex; flex-direction: column; gap: 2px; border: 0; margin: 0; overflow: visible; }
.po-nav__group { font-size: 10.5px; text-transform: uppercase; letter-spacing: .12em; color: #7d79b3; padding: 14px 12px 4px; font-weight: 700; }
.po-navitem, .drims-ops .po-navitem.do-tab {
  display: flex; align-items: center; gap: 10px; width: 100%; text-align: left;
  font: 600 14.5px/1.2 "Source Sans 3", sans-serif; color: var(--po-side-text);
  padding: 9px 12px; border: 0; border-radius: 9px; background: transparent; cursor: pointer; text-decoration: none;
}
.drims-ops .po-navitem:hover { background: rgba(255,255,255,.07); color: #fff; text-decoration: none; }
.drims-ops .po-navitem.is-active { background: linear-gradient(90deg, var(--po-brand) 0%, var(--po-brand-2) 100%); color: #fff; border: 0; box-shadow: 0 6px 16px rgba(91,61,245,.35); }
.po-ico { width: 18px; height: 18px; flex: 0 0 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.po-links { display: flex; flex-direction: column; gap: 2px; }
.po-links .po-navitem { font-weight: 400; font-size: 14px; }
.po-user { margin-top: auto; display: flex; align-items: center; gap: 10px; padding: 12px 8px 4px; border-top: 1px solid rgba(255,255,255,.08); }
.po-user__avatar { width: 34px; height: 34px; border-radius: 50%; flex: 0 0 34px; display: grid; place-items: center; background: var(--po-brand); color: #fff; font: 700 14px Montserrat, sans-serif; }
.po-user__info { min-width: 0; flex: 1; }
.po-user__name { color: #fff; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.po-user__role { font-size: 12px; color: #8f8bc4; }
.drims-ops .po-user__btn { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 8px; color: var(--po-side-text); }
.drims-ops .po-user__btn:hover { background: rgba(255,255,255,.1); color: #fff; }

.po-main { flex: 1; min-width: 0; margin-left: var(--po-side-w); display: flex; flex-direction: column; }
.po-top {
  position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  padding: 14px 28px; background: rgba(244,243,250,.9); backdrop-filter: saturate(1.4) blur(8px); border-bottom: 1px solid var(--po-line);
}
.drims-ops .po-title { margin: 0; font-size: 22px; font-weight: 700; flex: 1; min-width: 0; color: var(--po-ink); }
.po-content { padding: 20px 28px 48px; max-width: 1480px; width: 100%; }
.po-burger { display: none; width: 40px; height: 40px; border: 1px solid var(--po-line); border-radius: 10px; background: #fff; cursor: pointer; padding: 11px 10px; flex-direction: column; justify-content: space-between; }
.po-burger span { display: block; height: 2px; border-radius: 2px; background: var(--po-ink); }
.po-scrim { display: none; }

@media (max-width: 960px) {
  .po-side { transform: translateX(-100%); transition: transform .22s ease; box-shadow: none; }
  .po-side-open .po-side { transform: none; box-shadow: 0 0 40px rgba(0,0,0,.35); }
  .po-side-open .po-scrim { display: block; position: fixed; inset: 0; z-index: 35; background: rgba(15,13,40,.45); }
  .po-main { margin-left: 0; }
  .po-burger { display: flex; }
  .po-top { padding: 10px 16px; gap: 10px; }
  .drims-ops .po-title { font-size: 18px; }
  .po-top .do-controls { width: 100%; }
  .po-content { padding: 14px 16px 40px; }
}

/* payroll */
.do-good-text { color: var(--do-good); }
.pr-table td { vertical-align: top; }
.pr-table .do-input.do-num { width: 70px; }
.pr-net { font-size: 15px; white-space: nowrap; }
.pr-adjline { white-space: nowrap; font-size: 13px; line-height: 1.5; }
.pr-adjrow > td { background: var(--do-surface); }
.pr-adjedit { display: flex; flex-direction: column; gap: 8px; padding: 6px 0; }
.pr-adjedit__row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.pr-adjedit__row .do-input { min-width: 0; }
.pr-adjedit__row input[data-adjf="label"] { flex: 1 1 200px; }
.pr-adjedit__row input[data-adjf="amount"] { width: 120px; }
.pr-adjedit__actions { display: flex; gap: 8px; }
.pr-salform { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.pr-salform .do-input { width: auto; }
.pr-salform input[data-salf="monthly_amount"] { width: 120px; }
.pr-hist { margin: 6px 0 0; padding-left: 16px; font-size: 13px; }
.pr-hist li { margin: 2px 0; }
.pr-slip__logo { max-height: 36px; max-width: 160px; display: block; margin-bottom: 8px; }
.pr-slip__net { font-size: 26px; white-space: nowrap; }
.pr-slip__sum { display: flex; flex-wrap: wrap; gap: 10px 28px; justify-content: flex-end; align-items: baseline; padding: 14px 16px; margin: 16px 0; border-radius: 10px; background: var(--do-surface, #f6f5fb); }
.pr-slip__sum strong { margin-left: 6px; }
.pr-slip__netline { font-size: 18px; }
.pr-slip__netline strong { color: var(--do-good, #1f8a4c); }

/* login + message pages */
.po-body--login { min-height: 100vh; background: radial-gradient(1200px 600px at 10% -10%, #3a2aa8 0%, transparent 60%), radial-gradient(900px 600px at 110% 110%, #5b3df5 0%, transparent 55%), var(--po-side); }
.po-login { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px; padding: 24px 16px; }
.po-login__card { width: 100%; max-width: 400px; background: #fff; border-radius: 18px; padding: 32px 28px; box-shadow: 0 30px 80px rgba(8,6,30,.45); }
.po-login__brand { margin-bottom: 18px; }
.po-logo { max-height: 40px; max-width: 180px; display: block; }
.po-wordmark { font-weight: 800; font-size: 20px; color: var(--po-ink); }
.po-login h1 { margin: 0 0 4px; font-size: 24px; color: var(--po-ink); }
.po-login__sub { margin: 0 0 18px; color: #6c6a86; }
.po-alert { padding: 10px 12px; border-radius: 10px; margin-bottom: 14px; font-size: 14px; }
.po-alert--bad { background: #fbe7e5; color: #a02a21; }
.po-alert--good { background: #e6f4ec; color: #17693a; }
.po-form { display: flex; flex-direction: column; gap: 14px; }
.po-form label { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 14px; color: var(--po-ink); }
.po-form input[type="text"], .po-form input[type="password"] { font: 16px "Source Sans 3", sans-serif; padding: 11px 12px; border: 1px solid #d9d6ea; border-radius: 10px; background: #fbfbfe; color: var(--po-ink); }
.po-form input:focus { outline: 2px solid var(--po-brand); outline-offset: 0; border-color: var(--po-brand); background: #fff; }
.po-form .po-check { flex-direction: row; align-items: center; gap: 8px; font-weight: 400; }
.po-btn { display: inline-flex; justify-content: center; align-items: center; font: 700 15px Montserrat, sans-serif; padding: 12px 18px; border-radius: 10px; border: 0; cursor: pointer; background: linear-gradient(90deg, var(--po-brand), var(--po-brand-2)); color: #fff; text-decoration: none; }
.po-btn:hover { filter: brightness(1.06); }
.po-btn--ghost { background: #fff; color: var(--po-ink); border: 1px solid #d9d6ea; }
.po-login__forgot { display: inline-block; margin-top: 14px; font-size: 14px; color: var(--po-brand); text-decoration: none; }
.po-login__home { color: #c9c6ec; font-size: 14px; text-decoration: none; }
.po-login__home:hover, .po-login__forgot:hover { text-decoration: underline; }

@media print {
  .po-side, .po-top, .po-scrim { display: none !important; }
  .po-main { margin: 0 !important; }
}
.drims-ops a.po-navitem { color: var(--po-side-text); }
.drims-ops a.po-navitem:hover { color: #fff; }
.pr-slip .do-report__score small { display: block; }
.pr-slip h3 { margin-top: 14px; }
