:root {
    --pk-bg: #081d33;
    --pk-bg-deep: #0a2540;
    --pk-surface: #0e2e4d;
    --pk-surface-strong: #103a5e;
    --pk-inset: #0a2540;
    --pk-ink: #e8f1f8;
    --pk-muted: #7fa8c9;
    --pk-faint: #5b86a8;
    --pk-line: rgba(56, 189, 248, 0.16);
    --pk-line-strong: rgba(56, 189, 248, 0.34);
    --pk-brand: #38bdf8;
    --pk-brand-deep: #0ea5e9;
    --pk-brand-soft: rgba(56, 189, 248, 0.12);
    --pk-accent: #f5a524;
    --pk-accent-soft: rgba(245, 165, 36, 0.14);
    --pk-success: #5dcaa5;
    --pk-success-soft: rgba(93, 202, 165, 0.14);
    --pk-danger: #f09595;
    --pk-danger-soft: rgba(226, 75, 74, 0.16);
    --pk-grid: rgba(56, 189, 248, 0.06);
    --pk-grid-major: rgba(56, 189, 248, 0.10);
    --pk-shadow: 0 22px 60px rgba(2, 10, 22, 0.55);
    --pk-shadow-soft: 0 14px 34px rgba(2, 10, 22, 0.4);
    --pk-radius-xl: 16px;
    --pk-radius-lg: 12px;
    --pk-radius-md: 9px;
    --pk-header-height: 84px;
    --pk-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, "SF Mono", Consolas, "Liberation Mono", Menlo, monospace;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body.paper-kilo-body {
    min-height: 100vh;
    margin: 0;
    color: var(--pk-ink);
    font-family: "Manrope", "Segoe UI", sans-serif;
    background-color: var(--pk-bg);
    background-image:
        linear-gradient(var(--pk-grid) 1px, transparent 1px),
        linear-gradient(90deg, var(--pk-grid) 1px, transparent 1px),
        linear-gradient(var(--pk-grid-major) 1px, transparent 1px),
        linear-gradient(90deg, var(--pk-grid-major) 1px, transparent 1px);
    background-size: 28px 28px, 28px 28px, 140px 140px, 140px 140px;
    background-position: -1px -1px;
}

a {
    color: inherit;
}

button,
input,
select,
textarea {
    font: inherit;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid var(--pk-brand);
    outline-offset: 2px;
}

.workspace-header {
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(16px);
    background: rgba(8, 24, 42, 0.82);
    border-bottom: 1px solid var(--pk-line);
}

.workspace-header-inner {
    width: min(1440px, calc(100% - 32px));
    min-height: var(--pk-header-height);
    margin: 0 auto;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 24px;
}

.site-brand,
.site-nav,
.site-actions,
.site-badges,
.site-user {
    display: flex;
    align-items: center;
}

.site-brand {
    gap: 14px;
    text-decoration: none;
}

.site-brand-mark {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    color: var(--pk-bg-deep);
    font-weight: 800;
    letter-spacing: 0.08em;
    background: var(--pk-brand);
    box-shadow: 0 10px 24px rgba(56, 189, 248, 0.28);
}

.site-brand-copy {
    display: grid;
    line-height: 1.1;
}

.site-brand-copy strong,
.brand-title,
.section-title,
.topbar-title h1,
.hero-band h2 {
    font-family: "Space Grotesk", "Segoe UI", sans-serif;
}

.site-brand-copy span:last-child {
    margin-top: 4px;
    color: var(--pk-muted);
    font-size: 0.84rem;
}

.site-nav {
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

.site-nav a {
    padding: 10px 14px;
    border-radius: 999px;
    text-decoration: none;
    color: var(--pk-muted);
    font-weight: 700;
}

.site-nav a:hover {
    color: var(--pk-ink);
    background: var(--pk-brand-soft);
}

.site-nav a.is-active {
    color: var(--pk-bg-deep);
    background: var(--pk-brand);
}

.site-actions {
    gap: 12px;
    justify-self: end;
    flex-wrap: wrap;
}

.site-badges {
    gap: 8px;
}

.workspace-badge,
.workspace-chip,
.status-pill,
.role-pill,
.ui-banner,
.table-status {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 14px;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
    line-height: 1;
}

.workspace-badge {
    background: var(--pk-brand-soft);
    border: 1px solid var(--pk-line);
    color: var(--pk-brand);
}

.workspace-badge-muted {
    background: rgba(127, 168, 201, 0.1);
    border-color: var(--pk-line);
    color: var(--pk-muted);
}

.site-action-link,
.site-action-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 0 16px;
    border-radius: var(--pk-radius-md);
    border: 1px solid var(--pk-line-strong);
    background: var(--pk-surface-strong);
    color: var(--pk-ink);
    text-decoration: none;
    font-weight: 700;
}

.site-action-button {
    cursor: pointer;
}

.site-user {
    min-height: 42px;
    padding: 0 14px;
    border-radius: var(--pk-radius-md);
    border: 1px solid var(--pk-line);
    background: rgba(56, 189, 248, 0.06);
    color: var(--pk-ink);
    font-size: 0.92rem;
}

.paper-kilo-shell {
    width: min(1440px, calc(100% - 32px));
    margin: 24px auto 40px;
    display: grid;
    grid-template-columns: 310px minmax(0, 1fr);
    gap: 24px;
    align-items: start;
}

.shell-sidebar,
.surface-card,
.input-cluster,
.metric-card,
.detail-card,
.admin-card,
.summary-item,
.info-card,
.sidebar-panel,
.sidebar-foot {
    border: 1px solid var(--pk-line);
    background: var(--pk-surface);
    box-shadow: var(--pk-shadow-soft);
}

.shell-sidebar {
    position: sticky;
    top: calc(var(--pk-header-height) + 24px);
    padding: 18px;
    border-radius: var(--pk-radius-xl);
    display: grid;
    gap: 16px;
    background: var(--pk-bg-deep);
    border-color: var(--pk-line-strong);
    color: var(--pk-ink);
    box-shadow: var(--pk-shadow);
}

.sidebar-panel,
.sidebar-foot {
    padding: 18px;
    border-radius: var(--pk-radius-lg);
    background: rgba(56, 189, 248, 0.05);
    border-color: var(--pk-line);
}

.brand-kicker,
.section-kicker,
.nav-eyebrow,
.sidebar-note-label,
.metric-label,
.summary-item strong,
.info-card-label {
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    font-size: 0.72rem;
    font-weight: 800;
}

.section-kicker,
.brand-kicker,
.nav-eyebrow {
    color: var(--pk-brand);
}

.section-kicker {
    display: inline-flex;
    align-items: center;
    gap: 9px;
}

.section-kicker::before {
    content: "";
    flex: none;
    width: 18px;
    height: 2px;
    background: var(--pk-brand);
}

.sidebar-note-label,
.metric-label,
.summary-item strong,
.info-card-label {
    color: var(--pk-muted);
}

.brand-title {
    margin: 8px 0 10px;
    font-size: 2rem;
    line-height: 1.02;
}

.brand-copy,
.sidebar-foot p,
.sidebar-list,
.nav-title,
.hero-band p,
.metric-footnote,
.section-copy,
.detail-row,
.timeline-item span,
.audit-note,
.cluster-header p,
.list-toolbar-copy span,
.info-card span {
    color: var(--pk-muted);
    line-height: 1.65;
}

.nav-title {
    color: var(--pk-ink);
}

.workspace-chip {
    width: fit-content;
    background: var(--pk-brand-soft);
    color: var(--pk-brand);
}

.shell-nav {
    display: grid;
    gap: 10px;
}

.shell-nav a {
    padding: 14px 16px;
    border-radius: var(--pk-radius-lg);
    text-decoration: none;
    background: rgba(56, 189, 248, 0.04);
    border: 1px solid var(--pk-line);
    transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.shell-nav a:hover,
.shell-nav a.is-active {
    transform: translateX(4px);
    background: var(--pk-brand-soft);
    border-color: var(--pk-line-strong);
}

.admin-only[data-admin-enabled="false"] {
    opacity: 0.72;
}

.admin-only[data-admin-enabled="false"] .nav-title::after {
    content: " view only";
    margin-left: 6px;
    color: var(--pk-faint);
    font-size: 0.82em;
}

.sidebar-list {
    margin: 10px 0 0;
    padding-left: 18px;
}

.btn-sidebar,
.btn-shell,
.btn-shell-secondary,
.btn-shell-outline {
    min-height: 48px;
    padding: 0 18px;
    border-radius: var(--pk-radius-md);
    border: 1px solid transparent;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-shell {
    color: var(--pk-bg-deep);
    background: var(--pk-brand);
    box-shadow: 0 14px 30px rgba(56, 189, 248, 0.22);
}

.btn-shell-secondary {
    color: var(--pk-ink);
    background: var(--pk-surface-strong);
    border-color: var(--pk-line-strong);
}

.btn-shell-outline,
.btn-sidebar {
    color: var(--pk-brand);
    border-color: var(--pk-line-strong);
    background: transparent;
}

.btn-sidebar {
    width: 100%;
    color: var(--pk-ink);
    border-color: var(--pk-line-strong);
}

.btn-shell:hover,
.btn-shell-secondary:hover,
.btn-shell-outline:hover,
.btn-sidebar:hover {
    transform: translateY(-1px);
}

.btn-shell:disabled,
.btn-shell-secondary:disabled,
.btn-shell-outline:disabled,
.btn-sidebar:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.shell-main,
.workspace-column,
.summary-column,
.cluster-stack,
.summary-stack,
.detail-list,
.timeline {
    display: grid;
    gap: 24px;
}

.topbar,
.section-head,
.hero-actions,
.topbar-meta,
.action-row,
.list-toolbar,
.detail-row {
    display: flex;
    gap: 16px;
}

.topbar {
    align-items: end;
    justify-content: space-between;
}

.topbar-meta {
    flex-wrap: wrap;
    justify-content: flex-end;
}

.topbar-title h1,
.hero-band h2 {
    margin: 0;
    font-size: clamp(2rem, 2.8vw, 3.2rem);
    line-height: 1.05;
}

.topbar-title p,
.section-head p {
    margin: 8px 0 0;
}

.status-pill,
.role-pill {
    background: rgba(56, 189, 248, 0.08);
    border: 1px solid var(--pk-line);
    color: var(--pk-muted);
}

.role-pill {
    color: var(--pk-brand);
    background: var(--pk-brand-soft);
}

.panel-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) minmax(300px, 0.82fr);
    gap: 24px;
    align-items: start;
}

.summary-column {
    position: sticky;
    top: calc(var(--pk-header-height) + 24px);
}

.surface-card {
    overflow: hidden;
    border-radius: var(--pk-radius-xl);
    box-shadow: var(--pk-shadow);
}

.surface-card.padded,
.padded {
    padding: 24px;
}

.overview-layout,
.calculator-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) minmax(280px, 0.9fr);
}

.hero-band {
    position: relative;
    padding: 32px;
    color: var(--pk-ink);
    background-color: #071f37;
    background-image:
        linear-gradient(rgba(56, 189, 248, 0.06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(56, 189, 248, 0.06) 1px, transparent 1px);
    background-size: 22px 22px;
    border-right: 1px solid var(--pk-line);
}

.hero-band::before,
.hero-band::after {
    content: "";
    position: absolute;
    width: 16px;
    height: 16px;
    border: 2px solid var(--pk-brand);
    opacity: 0.65;
    pointer-events: none;
}

.hero-band::before {
    top: 14px;
    left: 14px;
    border-right: 0;
    border-bottom: 0;
}

.hero-band::after {
    right: 14px;
    bottom: 14px;
    border-left: 0;
    border-top: 0;
}

.hero-band p,
.hero-band .section-kicker {
    color: var(--pk-muted);
}

.ui-banner {
    align-items: flex-start;
    border-radius: var(--pk-radius-md);
    line-height: 1.35;
    background: var(--pk-brand-soft);
    border: 1px solid var(--pk-line-strong);
    color: var(--pk-brand);
}

.overview-side {
    padding: 24px;
    display: grid;
    gap: 16px;
    background: rgba(56, 189, 248, 0.04);
}

.info-card {
    padding: 18px;
    border-radius: var(--pk-radius-lg);
}

.info-card strong {
    display: block;
    color: var(--pk-ink);
    margin: 10px 0 6px;
    font-size: 1.08rem;
}

.info-card-accent {
    background: var(--pk-accent-soft);
    border-color: rgba(245, 165, 36, 0.3);
}

.metric-grid,
.field-grid,
.toolbar-grid,
.detail-grid,
.admin-grid {
    display: grid;
    gap: 16px;
}

.metric-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.metric-card,
.input-cluster,
.detail-card,
.admin-card,
.summary-item {
    padding: 20px;
    border-radius: var(--pk-radius-lg);
}

.metric-value {
    display: block;
    color: var(--pk-ink);
    margin-top: 10px;
    font-family: var(--pk-mono);
    font-size: clamp(1.7rem, 2vw, 2.4rem);
    font-weight: 600;
    letter-spacing: -0.01em;
    font-variant-numeric: tabular-nums;
}

.metric-value-small {
    font-size: clamp(1.05rem, 1.5vw, 1.45rem);
    line-height: 1.25;
}

.section-head {
    align-items: end;
    justify-content: space-between;
    margin-bottom: 20px;
}

.section-title {
    margin: 0;
    font-size: clamp(1.45rem, 2vw, 2rem);
}

.calculator-grid {
    gap: 20px;
    align-items: start;
}

.cluster-header {
    margin-bottom: 16px;
}

.cluster-header p,
.cluster-title,
.detail-card h3,
.admin-card h3,
.step h3 {
    margin: 0;
}

.cluster-title,
.detail-card h3,
.admin-card h3 {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: 1rem;
    font-weight: 800;
    color: var(--pk-ink);
}

.cluster-title::before,
.detail-card h3::before,
.admin-card h3::before {
    content: "";
    flex: none;
    width: 3px;
    height: 14px;
    border-radius: 2px;
    background: var(--pk-brand);
}

.field-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.field-grid.single {
    grid-template-columns: 1fr;
}

.toolbar-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    margin-bottom: 18px;
}

.field {
    display: grid;
    gap: 8px;
}

.field label {
    font-size: 0.88rem;
    font-weight: 800;
    color: var(--pk-ink);
}

.field input,
.field select,
.field textarea {
    width: 100%;
    min-height: 48px;
    padding: 12px 14px;
    color: var(--pk-ink);
    background: var(--pk-inset);
    border: 1px solid var(--pk-line);
    border-radius: var(--pk-radius-md);
}

.field input,
.field select {
    font-family: var(--pk-mono);
    font-size: 0.95rem;
    letter-spacing: -0.01em;
    font-variant-numeric: tabular-nums;
}

.field input::placeholder,
.field textarea::placeholder {
    color: var(--pk-faint);
}

.field input:focus,
.field select:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--pk-brand);
    box-shadow: 0 0 0 3px var(--pk-brand-soft);
}

.field select option {
    color: var(--pk-ink);
    background: var(--pk-bg-deep);
}

.field textarea {
    min-height: 110px;
    resize: vertical;
}

.field small {
    color: var(--pk-muted);
}

.field input[readonly] {
    background: var(--pk-brand-soft);
    border-color: var(--pk-line);
    color: var(--pk-brand);
    font-weight: 600;
}

.field input.is-invalid,
.field select.is-invalid,
.field textarea.is-invalid {
    border-color: var(--pk-danger);
    box-shadow: 0 0 0 3px var(--pk-danger-soft);
}

.mini-callout,
.feedback-banner,
.editing-banner,
.admin-selected,
.admin-access-note,
.list-toolbar {
    padding: 16px 18px;
    border-radius: var(--pk-radius-lg);
    border: 1px solid transparent;
}

.mini-callout {
    background: var(--pk-accent-soft);
    border-color: rgba(245, 165, 36, 0.28);
    color: var(--pk-accent);
}

.feedback-banner.is-success {
    color: var(--pk-success);
    background: var(--pk-success-soft);
    border-color: rgba(93, 202, 165, 0.3);
}

.feedback-banner.is-error,
.warning-callout {
    color: var(--pk-danger);
    background: var(--pk-danger-soft);
    border-color: rgba(226, 75, 74, 0.32);
}

.feedback-banner.is-info,
.editing-banner,
.admin-selected,
.admin-access-note,
.list-toolbar {
    color: var(--pk-brand);
    background: var(--pk-brand-soft);
    border-color: var(--pk-line);
}

.action-row {
    flex-wrap: wrap;
}

.summary-stack {
    gap: 14px;
}

.summary-stack.compact {
    gap: 12px;
}

.summary-item span {
    display: block;
    margin-top: 8px;
    font-family: var(--pk-mono);
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--pk-ink);
    font-variant-numeric: tabular-nums;
}

.summary-total {
    color: var(--pk-accent);
    background: var(--pk-accent-soft);
    border-color: rgba(245, 165, 36, 0.34);
}

.summary-total strong {
    color: var(--pk-accent);
}

.summary-total span {
    color: var(--pk-accent);
}

.summary-column .summary-total span {
    font-size: 1.5rem;
}

.table-wrap {
    overflow-x: auto;
    border-radius: var(--pk-radius-lg);
    border: 1px solid var(--pk-line);
}

.pk-table {
    width: 100%;
    border-collapse: collapse;
    background: transparent;
}

.pk-table th,
.pk-table td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--pk-line);
    text-align: left;
    white-space: nowrap;
}

.pk-table td {
    font-family: var(--pk-mono);
    font-size: 0.9rem;
    color: var(--pk-ink);
    font-variant-numeric: tabular-nums;
}

.pk-table th {
    background: rgba(56, 189, 248, 0.06);
    color: var(--pk-muted);
    font-weight: 700;
    letter-spacing: 0.04em;
}

.pk-table tbody tr:nth-child(even) {
    background: rgba(56, 189, 248, 0.025);
}

.pk-table tbody tr[data-job-id] {
    cursor: pointer;
    transition: background 0.2s ease;
}

.pk-table tbody tr[data-job-id]:hover,
.pk-table tbody tr[data-job-id]:focus-visible {
    background: var(--pk-brand-soft);
}

.pk-table tbody tr[data-job-id]:focus-visible {
    outline: none;
    box-shadow: inset 0 0 0 2px var(--pk-line-strong);
}

.pk-table tbody tr.is-selected td {
    background: rgba(56, 189, 248, 0.12);
}

.pk-table tbody tr.is-selected td:first-child {
    box-shadow: inset 3px 0 0 var(--pk-brand);
}

.table-status {
    padding: 7px 12px;
    font-family: "Manrope", sans-serif;
}

.table-status.draft {
    color: var(--pk-muted);
    background: rgba(127, 168, 201, 0.12);
}

.table-status.submitted {
    color: var(--pk-brand);
    background: var(--pk-brand-soft);
}

.table-status.in-review,
.table-status.review {
    color: var(--pk-accent);
    background: var(--pk-accent-soft);
}

.table-status.approved {
    color: var(--pk-success);
    background: var(--pk-success-soft);
}

.pk-table td.table-empty {
    padding: 28px 16px;
    text-align: center;
    color: var(--pk-muted);
    font-family: "Manrope", sans-serif;
    font-variant-numeric: normal;
    white-space: normal;
}

.detail-grid,
.admin-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.detail-row,
.list-toolbar {
    justify-content: space-between;
    align-items: center;
}

.detail-row strong {
    font-family: var(--pk-mono);
    color: var(--pk-ink);
    font-weight: 600;
}

.detail-list {
    gap: 0;
}

.detail-list .detail-row {
    padding: 9px 0;
    border-bottom: 1px dashed var(--pk-line);
}

.detail-list .detail-row:first-child {
    padding-top: 0;
}

.detail-list .detail-row:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.list-toolbar-copy {
    display: grid;
    gap: 4px;
}

.list-toolbar-copy strong {
    color: var(--pk-ink);
}

.timeline-item {
    padding: 16px;
    border-left: 3px solid var(--pk-brand);
    border-radius: 0 var(--pk-radius-md) var(--pk-radius-md) 0;
    background: var(--pk-brand-soft);
}

.timeline-item strong {
    display: block;
    margin-bottom: 4px;
    color: var(--pk-ink);
}

.step-list {
    display: grid;
    gap: 14px;
}

.step {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 14px;
    align-items: start;
}

.step h3 {
    color: var(--pk-ink);
}

.step-marker {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--pk-brand-soft);
    border: 1px solid var(--pk-line-strong);
    color: var(--pk-brand);
    font-family: var(--pk-mono);
    font-weight: 700;
}

.danger-outline {
    color: var(--pk-danger);
    border-color: rgba(226, 75, 74, 0.34);
}

.result-cluster {
    background: rgba(56, 189, 248, 0.06);
    border-color: var(--pk-line-strong);
}

.audit-note {
    display: flex;
    align-items: center;
    gap: 9px;
}

.audit-note::before {
    content: "";
    flex: none;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--pk-brand);
    box-shadow: 0 0 0 4px var(--pk-brand-soft);
    animation: pk-live-pulse 2.4s ease-in-out infinite;
}

@keyframes pk-live-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.35; }
}

@media (prefers-reduced-motion: reduce) {
    .audit-note::before {
        animation: none;
    }
}

section[id] {
    scroll-margin-top: calc(var(--pk-header-height) + 24px);
}

.hidden {
    display: none !important;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: absolute;
    top: -64px;
    left: 16px;
    z-index: 100;
    padding: 12px 18px;
    border-radius: var(--pk-radius-md);
    background: var(--pk-brand);
    color: var(--pk-bg-deep);
    font-weight: 800;
    text-decoration: none;
    transition: top 0.2s ease;
}

.skip-link:focus {
    top: 16px;
}

.skeleton-row td {
    padding: 14px 16px;
}

.skeleton-bar {
    display: block;
    height: 12px;
    border-radius: 6px;
    background-color: rgba(56, 189, 248, 0.1);
    background-image: linear-gradient(90deg, rgba(56, 189, 248, 0) 0%, rgba(56, 189, 248, 0.2) 50%, rgba(56, 189, 248, 0) 100%);
    background-size: 200% 100%;
    background-repeat: no-repeat;
    animation: pk-shimmer 1.4s ease-in-out infinite;
}

@keyframes pk-shimmer {
    0% { background-position: 180% 0; }
    100% { background-position: -80% 0; }
}

@media (prefers-reduced-motion: reduce) {
    .skeleton-bar {
        animation: none;
    }
}

@media (max-width: 1260px) {
    .workspace-header-inner,
    .paper-kilo-shell {
        width: min(100%, calc(100% - 24px));
    }

    .paper-kilo-shell,
    .panel-grid,
    .overview-layout,
    .calculator-grid {
        grid-template-columns: 1fr;
    }

    .summary-column,
    .shell-sidebar {
        position: static;
    }

    .hero-band {
        border-right: 0;
        border-bottom: 1px solid var(--pk-line);
    }
}

@media (max-width: 960px) {
    .workspace-header-inner {
        grid-template-columns: 1fr;
        padding: 14px 0;
    }

    .site-nav,
    .site-actions {
        justify-content: flex-start;
    }

    .metric-grid,
    .toolbar-grid,
    .detail-grid,
    .admin-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    :root {
        --pk-header-height: 72px;
    }

    .paper-kilo-shell {
        margin-top: 16px;
        width: min(100%, calc(100% - 16px));
    }

    .topbar,
    .section-head,
    .list-toolbar,
    .detail-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .surface-card.padded,
    .padded,
    .hero-band,
    .overview-side,
    .shell-sidebar {
        padding: 20px;
    }

    .metric-grid,
    .field-grid,
    .toolbar-grid,
    .detail-grid,
    .admin-grid {
        grid-template-columns: 1fr;
    }

    .site-badges {
        display: none;
    }
}
