@font-face {
  font-family: Manrope;
  src: url("/fonts/manrope-variable.woff2") format("woff2");
  font-display: swap;
  font-weight: 400 800;
}

.nip-portal {
  --p-ink: #152019;
  --p-copy: #344137;
  --p-muted: #4f5d50;
  --p-paper: #f4f2e9;
  --p-surface: #fffdf5;
  --p-panel: #e6e8db;
  --p-rule: #aeb9a3;
  --p-border: #ced3bf;
  --p-blue: #2349d6;
  --p-blue-dark: #1839ad;
  --p-alert: #8b3126;
  --p-gutter: clamp(16px, 4vw, 64px);
  --p-round: 2px;
  --p-display: Manrope, system-ui, -apple-system, sans-serif;
  --p-label: ui-monospace, "SF Mono", monospace;
  min-height: 100vh;
  margin: 0;
  color: var(--p-ink);
  background: var(--p-paper);
  font: 400 1rem/1.5 var(--p-display);
  overflow-wrap: anywhere;
}
.nip-portal *, .nip-portal *::before, .nip-portal *::after { box-sizing: border-box; }
.nip-portal h1, .nip-portal h2, .nip-portal h3, .nip-portal p, .nip-portal dl, .nip-portal dd, .nip-portal form { margin: 0; }
.nip-portal :is(input, textarea, select, button) { font: inherit; }
.nip-portal a { color: inherit; text-underline-offset: .19em; }
.nip-portal :focus-visible { outline: 3px solid var(--p-blue); outline-offset: 4px; }
.nip-portal :is(a, button, summary) { touch-action: manipulation; }
.nip-portal .p-button:active { filter: brightness(.94); }
.nip-portal .p-shell { width: min(100% - var(--p-gutter) * 2, 1320px); margin-inline: auto; }
.p-skip { position: fixed; top: 8px; left: 8px; z-index: 3; padding: 12px; background: var(--p-surface); clip-path: inset(50%); }
.p-skip:focus { clip-path: none; }
.p-top { background: var(--p-paper); border-bottom: 1px solid var(--p-rule); }
.p-top-row { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; min-height: 70px; gap: 8px 16px; padding-block: 8px; }
.p-brand { display: inline-flex; min-height: 48px; gap: 8px; align-items: center; text-decoration: none; font-size: .88rem; font-weight: 800; letter-spacing: .075em; }
.p-logo { display: grid; place-items: center; inline-size: 52px; block-size: 42px; color: var(--p-surface); background: var(--p-ink); font-size: 1.3rem; font-weight: 800; letter-spacing: -.08em; }
.p-back { display: inline-flex; gap: .4rem; align-items: center; min-height: 48px; font-size: .9rem; font-weight: 750; text-decoration: none; }
.p-back:hover { color: var(--p-blue-dark); text-decoration: underline; }

.p-login { display: grid; gap: clamp(24px, 5vw, 80px); align-items: center; padding-block: clamp(40px, 9vh, 100px); }
.p-login-form { min-width: 0; }
.nip-portal h1 { font-size: clamp(2.3rem, 5vw, 5.6rem); font-weight: 800; letter-spacing: -.075em; line-height: .98; text-wrap: balance; }
.nip-portal .p-intro { margin-top: 14px; max-width: 43ch; color: var(--p-copy); font-size: clamp(.96rem, 1.3vw, 1.2rem); }
.nip-portal .p-credentials { display: grid; gap: 16px; max-width: 31rem; margin-top: 24px; }
.p-credentials .p-button { width: 100%; }
.p-login-alternatives { display: flex; flex-wrap: wrap; gap: 0 20px; max-width: 31rem; border-top: 1px solid var(--p-border); margin-top: 24px; }
.p-login-alternatives a { display: inline-flex; align-items: center; min-height: 48px; gap: 6px; color: var(--p-blue-dark); font-size: .9rem; font-weight: 750; }
.p-login-figure { position: relative; display: grid; min-width: 0; margin: 0; isolation: isolate; overflow: hidden; background: var(--p-panel); }
.p-login-figure img { display: block; width: 100%; height: 100%; aspect-ratio: 1.25; min-height: 220px; object-fit: cover; object-position: 62% center; }
.p-login-figure-note { position: absolute; inset: auto 0 0; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 4px 18px; padding: 12px 16px; background: var(--p-ink); color: var(--p-surface); }
.p-login-figure-note strong { font-size: 1rem; font-weight: 800; }
.p-login-figure-note span { font: 600 .72rem/1.45 var(--p-label); }

.p-intro-band { background: var(--p-panel); border-bottom: 1px solid var(--p-rule); padding-block: clamp(24px, 4vw, 56px); }
.nip-portal .p-role { display: inline-block; margin-bottom: 13px; color: var(--p-muted); font: 700 .72rem/1.4 var(--p-label); letter-spacing: .065em; text-transform: uppercase; }
.p-role::before { display: inline-block; width: 8px; height: 8px; margin-right: .6rem; background: var(--p-blue); content: ""; }
.p-intro-content { display: flex; justify-content: space-between; align-items: end; flex-wrap: wrap; gap: 18px 24px; }
.p-intro-content > div { min-width: 0; }
.p-user { color: var(--p-muted); font-size: .9rem; }
.p-user strong { color: var(--p-ink); font-weight: 800; }
.p-workspace { display: grid; gap: clamp(20px, 4vw, 56px); align-items: start; padding-block: 20px clamp(36px, 7vw, 72px); }
.p-content { display: grid; min-width: 0; gap: clamp(28px, 4vw, 56px); }
.p-section-nav { min-width: 0; }
.p-section-nav ul { display: flex; flex-wrap: wrap; gap: 4px 8px; margin: 0; padding: 0; list-style: none; }
.p-section-nav a { display: flex; min-height: 48px; align-items: center; padding: 2px 10px; border-bottom: 1px solid var(--p-border); text-decoration: none; font-size: .875rem; font-weight: 800; }
.p-section-nav a:hover { background: var(--p-panel); color: var(--p-blue-dark); }
.p-section { display: grid; gap: 14px; min-width: 0; scroll-margin-block-start: 16px; }
.p-section-heading { min-width: 0; }
.p-section-heading h2 { font-size: clamp(1.6rem, 3.15vw, 3.05rem); font-weight: 800; line-height: 1.06; letter-spacing: -.065em; }
.p-section-heading p { max-width: 55ch; margin-top: 5px; color: var(--p-copy); font-size: .94rem; }
.p-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 33rem), 1fr)); gap: 14px; min-width: 0; align-items: start; }
.p-card { display: grid; gap: 14px; min-width: 0; padding: clamp(14px, 2.35vw, 24px); background: var(--p-surface); border: 1px solid var(--p-rule); border-radius: var(--p-round); }
.p-card-heading { display: flex; flex-wrap: wrap; align-items: start; justify-content: space-between; gap: 8px 14px; }
.p-card-heading > div { min-width: 0; flex: 1 1 12rem; }
.p-card-heading h3, .p-subhead { font-size: clamp(1.2rem, 2vw, 1.48rem); line-height: 1.12; letter-spacing: -.045em; font-weight: 800; }
.p-card-heading p { margin-top: 4px; color: var(--p-muted); font-size: .9rem; }
.p-badge { display: inline-flex; max-width: 100%; align-items: center; padding: 4px 8px; border: 1px solid var(--p-border); background: var(--p-panel); color: var(--p-ink); font-size: .76rem; font-weight: 800; }
.p-badge.success { background: #e0eee0; color: #1e532d; border-color: #a7baa5; }
.p-badge.problem { background: #f9e7dd; color: var(--p-alert); border-color: #d5a996; }
.p-badge.planning { background: #e4ebfb; color: #203873; border-color: #a4b6dc; }
.p-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 145px), 1fr)); gap: 10px 14px; }
.p-facts > div, .p-metrics > div { min-width: 0; }
.p-facts dt, .p-metrics dt { color: var(--p-muted); font-size: .78rem; font-weight: 700; }
.p-facts dd { font-weight: 700; font-size: .93rem; }
.p-documents { border-top: 1px solid var(--p-border); }
.p-document { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 12px; align-items: center; padding-block: 8px; border-bottom: 1px solid var(--p-border); }
.p-document p { font-size: .84rem; color: var(--p-muted); }
.p-document-value { display: flex; justify-content: end; align-items: center; flex-wrap: wrap; gap: 4px 8px; text-align: right; }
.p-document-value strong { font-variant-numeric: tabular-nums; }
.p-document .p-document-link { justify-self: start; grid-column: 1 / -1; color: var(--p-blue-dark); min-height: 44px; display: inline-flex; align-items: center; font-weight: 760; font-size: .9rem; }
.p-work-note, .p-empty { color: var(--p-copy); font-size: .93rem; }
.p-empty { border: 1px dashed var(--p-rule); padding: 16px; }
.p-actions { display: flex; align-items: start; flex-wrap: wrap; gap: 8px; }
.p-card-controls { display: grid; justify-items: start; gap: 8px; min-width: 0; }
.p-card-controls .p-disclosure { width: 100%; }
.p-records { list-style: none; margin: 0; padding: 0; border: 1px solid var(--p-rule); background: var(--p-surface); }
.p-records li { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; align-items: start; padding: 12px 14px; }
.p-records li + li { border-top: 1px solid var(--p-border); }
.p-records p { color: var(--p-muted); font-size: .87rem; }
.p-metrics { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 155px), 1fr)); gap: 8px; }
.p-metrics > div { display: flex; flex-direction: column-reverse; padding: 12px; background: var(--p-surface); border: 1px solid var(--p-rule); }
.p-metrics dd { font-size: clamp(1.2rem, 2.15vw, 1.9rem); font-weight: 800; letter-spacing: -.05em; font-variant-numeric: tabular-nums; }

.p-disclosure { min-width: 0; border: 1px solid var(--p-rule); border-radius: var(--p-round); background: var(--p-surface); }
.p-disclosure summary { min-height: 48px; padding: 11px 14px; cursor: pointer; font-weight: 800; }
.p-disclosure summary:hover { color: var(--p-blue-dark); background: var(--p-panel); }
.p-disclosure[open] summary { border-bottom: 1px solid var(--p-border); }
.p-disclosure-body { padding: clamp(12px, 2.15vw, 20px); }
.p-form { display: grid; min-width: 0; gap: 14px; justify-items: start; }
.p-form.p-inline { display: block; }
.p-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 225px), 1fr)); gap: 12px; width: 100%; min-width: 0; }
.p-field { display: grid; width: 100%; gap: 4px; min-width: 0; font-size: .91rem; font-weight: 750; }
.p-field.p-wide { grid-column: 1 / -1; }
.p-field :is(input, select, textarea) { display: block; width: 100%; min-width: 0; min-height: 48px; padding: 8px 10px; color: var(--p-ink); background: white; border: 1px solid #899780; border-radius: var(--p-round); font-size: 1rem; font-weight: 550; }
.p-field textarea { resize: vertical; }
.nip-portal .p-button { display: inline-flex; justify-content: center; align-items: center; max-width: 100%; min-height: 48px; padding: 9px 14px; color: white; background: var(--p-blue); border: 1px solid var(--p-blue); border-radius: var(--p-round); cursor: pointer; text-decoration: none; font-size: .9rem; font-weight: 800; text-align: center; }
.nip-portal .p-button:hover { background: var(--p-blue-dark); }
.nip-portal .p-button.p-button-quiet { color: var(--p-ink); background: transparent; border-color: #899780; }
.nip-portal .p-button.p-button-quiet:hover { color: var(--p-blue-dark); background: var(--p-panel); border-color: var(--p-blue-dark); }
.p-notice { width: 100%; padding: 11px 14px; border-left: 4px solid var(--p-blue); background: #e4ebfb; color: #203873; font-weight: 750; }
.p-notice.p-demo { background: #eee4d7; border-color: #985939; color: #603c2b; }
.p-notice.p-alert { background: #f9e7dd; border-color: var(--p-alert); color: var(--p-alert); }

@media (min-width: 48rem) {
  .p-login { grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr); }
  .p-workspace { grid-template-columns: minmax(140px, 205px) minmax(0, 1fr); padding-top: 28px; }
  .p-section-nav { position: sticky; top: 16px; max-height: calc(100dvh - 32px); overflow-y: auto; padding: 4px; }
  .p-section-nav ul { display: grid; gap: 2px; }
}
@media (max-width: 26rem) {
  .p-credentials { justify-items: stretch; }
  .p-document { grid-template-columns: minmax(0, 1fr); }
  .p-document-value { justify-content: start; text-align: left; }
  .p-user { font-size: .8rem; }
}

.p-shell.p-document { padding-block: clamp(24px, 7vw, 96px); max-width: 840px; }
.p-shell.p-document > .p-back { display: inline-flex; margin-bottom: 18px; }
.p-shell.p-document dl > div { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,2fr); gap: 16px; padding-block: 11px; border-bottom: 1px solid #dde3dc; }
.p-shell.p-document dd { margin: 0; overflow-wrap: anywhere; }
.p-contract { white-space: pre-wrap; overflow-wrap: anywhere; font: inherit; margin-block: 24px; }
@media print {
  .p-shell.p-document { max-width: none; padding: 0; }
  .p-shell.p-document > .p-back { display: none; }
  .p-shell.p-document .p-card { box-shadow: none; }
}
