:root {
    --termino-radius: 1rem;
}

body {
    min-height: 100vh;
}

.card,
.btn,
.form-control,
.form-select,
.alert {
    border-radius: var(--termino-radius);
}

.navbar-brand {
    letter-spacing: -0.02em;
}

.hero-card {
    background: linear-gradient(135deg, rgba(13, 110, 253, 0.12), rgba(25, 135, 84, 0.08));
}

.status-card {
    transition: transform .15s ease, box-shadow .15s ease;
}

.status-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 .75rem 1.75rem rgba(0, 0, 0, .08);
}

.term-mobile-card {
    border-left: .35rem solid rgba(13, 110, 253, .35) !important;
}

.text-truncate-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.termino-template-btn.active,
.termino-template-btn:active {
    color: #fff;
    background-color: #0d6efd;
    border-color: #0d6efd;
}

.termino-template-btn.active .text-muted,
.termino-template-btn:active .text-muted {
    color: rgba(255, 255, 255, .8) !important;
}

.category-dot {
    display: inline-block;
    width: .75rem;
    height: .75rem;
    border-radius: 50%;
    margin-right: .4rem;
    vertical-align: middle;
}

@media (max-width: 575.98px) {
    .btn-lg {
        width: 100%;
    }

    .card-body.p-5 {
        padding: 2rem !important;
    }
}

.code-box {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: .75rem;
    padding: .85rem 1rem;
}

/* Etap 10 — public UX */
.py-lg-6 {
    padding-top: 5rem !important;
    padding-bottom: 5rem !important;
}

.public-navbar .nav-link {
    border-radius: .75rem;
    padding-left: .85rem !important;
    padding-right: .85rem !important;
}

.public-navbar .nav-link.active {
    color: #0d6efd;
    background: rgba(13, 110, 253, .08);
}

.public-hero {
    background: radial-gradient(circle at top left, rgba(13, 110, 253, .08), transparent 34rem), #fff;
}

.public-step-card {
    transition: transform .15s ease, box-shadow .15s ease;
}

.public-step-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 1rem 2rem rgba(0,0,0,.08) !important;
}

.step-number {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: #0d6efd;
    background: rgba(13, 110, 253, .12);
    margin-bottom: 1rem;
}

.public-check-list li {
    position: relative;
    padding-left: 1.75rem;
    margin-bottom: .75rem;
}

.public-check-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    top: 0;
    color: #198754;
    font-weight: 700;
}

.legal-card h2 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-top: 1.75rem;
    margin-bottom: .75rem;
}

.legal-card h2:first-child {
    margin-top: 0;
}

.text-white-75 {
    color: rgba(255,255,255,.78);
}

.mobile-floating-add {
    display: none;
}

.panel-navbar .nav-link.active {
    font-weight: 700;
}

@media (max-width: 991.98px) {
    .public-cta {
        width: 100%;
        margin-top: .35rem;
    }

    .panel-user-box {
        align-items: stretch !important;
        padding-top: .75rem;
        border-top: 1px solid rgba(255,255,255,.2);
        margin-top: .5rem;
    }

    .mobile-floating-add {
        display: inline-flex;
        position: fixed;
        right: 1rem;
        bottom: 1rem;
        z-index: 1030;
        width: 3.25rem;
        height: 3.25rem;
        border-radius: 999px;
        align-items: center;
        justify-content: center;
        font-size: 1.75rem;
        line-height: 1;
    }
}

@media (max-width: 575.98px) {
    .display-5 {
        font-size: 2.25rem;
    }

    .display-6 {
        font-size: 2rem;
    }

    .public-hero .lead,
    .lead {
        font-size: 1.05rem;
    }

    footer .d-flex {
        gap: .5rem !important;
    }
}

/* Etap 11 — PWA i wygoda mobilna */
.offline-banner {
    position: sticky;
    top: 0;
    z-index: 2000;
    background: #212529;
    color: #fff;
    text-align: center;
    padding: .55rem .75rem;
    font-size: .9rem;
}

.public-pwa-strip {
    background: linear-gradient(135deg, rgba(13, 110, 253, .06), rgba(25, 135, 84, .05));
}

.mobile-action-hub {
    border-left: .35rem solid rgba(13, 110, 253, .4) !important;
}

.quick-actions-inline .btn,
.quick-actions-inline .badge {
    min-height: 2rem;
    display: inline-flex;
    align-items: center;
}

.term-mobile-card .btn,
.mobile-action-hub .btn {
    min-height: 2.65rem;
}

@media (display-mode: standalone) {
    .public-navbar,
    .panel-navbar {
        padding-top: calc(.5rem + env(safe-area-inset-top));
    }

    .mobile-floating-add {
        bottom: calc(1rem + env(safe-area-inset-bottom));
    }
}

@media (max-width: 767.98px) {
    .mobile-action-hub .d-sm-flex,
    .term-mobile-card .d-grid {
        gap: .65rem !important;
    }

    .term-stat-card .card-body,
    .status-card .card-body {
        padding: 1rem !important;
    }

    .panel-page main.py-4 {
        padding-top: 1rem !important;
        padding-bottom: 5.25rem !important;
    }

    .mobile-floating-add {
        width: 3.65rem;
        height: 3.65rem;
        font-size: 2rem;
    }
}

@media (max-width: 420px) {
    .navbar-brand {
        max-width: 9.5rem;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .mobile-action-hub .btn,
    .term-mobile-card .btn {
        width: 100%;
    }
}

/* Etap 14 — Historia zdarzeń */
.event-description {
    white-space: normal;
    word-break: break-word;
}

.event-mobile-card .btn {
    min-height: 2.5rem;
}

@media (max-width: 767.98px) {
    .event-mobile-card .card-body {
        padding: 1rem !important;
    }
}

/* v1.2.0 — Moje rzeczy */
.item-card .badge,
.item-mini-card .badge {
    white-space: normal;
    text-align: left;
}
.item-mini-card {
    transition: transform .15s ease, box-shadow .15s ease;
}
.item-mini-card:hover {
    transform: translateY(-1px);
    box-shadow: 0 .35rem 1rem rgba(0,0,0,.08);
}
@media (max-width: 575.98px) {
    .item-card .card-body {
        padding: 1rem;
    }
}

/* v1.5.0 — Centrum działań i kalendarz */
.action-hero {
    position: relative;
    overflow: hidden;
    padding: clamp(1.5rem, 4vw, 3rem);
    border: 1px solid rgba(13, 110, 253, .12);
    border-radius: 1.5rem;
    background:
        radial-gradient(circle at 90% 10%, rgba(13, 110, 253, .16), transparent 18rem),
        linear-gradient(135deg, #fff, #f5f9ff);
    box-shadow: 0 1rem 2.5rem rgba(25, 45, 80, .06);
}

.action-eyebrow {
    display: inline-block;
    margin-bottom: .5rem;
    color: #0d6efd;
    font-size: .75rem;
    font-weight: 800;
    letter-spacing: .09em;
    text-transform: uppercase;
}

.action-summary-card {
    display: flex;
    min-height: 9.25rem;
    height: 100%;
    flex-direction: column;
    justify-content: space-between;
    padding: 1.25rem;
    border: 1px solid transparent;
    border-radius: 1.25rem;
    text-decoration: none;
    transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}

.action-summary-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 .85rem 2rem rgba(26, 45, 72, .1);
}

.action-summary-card strong {
    color: #172033;
    font-size: 2.35rem;
    line-height: 1;
}

.action-summary-card small,
.action-summary-label {
    color: #667085;
}

.action-summary-label {
    font-size: .86rem;
    font-weight: 700;
}

.action-summary-danger {
    border-color: rgba(220, 53, 69, .16);
    background: rgba(220, 53, 69, .055);
}

.action-summary-warning {
    border-color: rgba(255, 193, 7, .24);
    background: rgba(255, 193, 7, .08);
}

.action-summary-primary {
    border-color: rgba(13, 110, 253, .18);
    background: rgba(13, 110, 253, .06);
}

.action-summary-neutral {
    border-color: rgba(108, 117, 125, .16);
    background: rgba(108, 117, 125, .055);
}

.action-priority-card {
    border-top: .3rem solid rgba(13, 110, 253, .75) !important;
}

.action-term-row {
    display: flex;
    gap: 1rem;
    align-items: center;
    justify-content: space-between;
    padding: 1rem;
    border: 1px solid #e9edf3;
    border-radius: 1rem;
    background: #fff;
}

.action-term-main {
    min-width: 0;
}

.action-term-actions {
    display: flex;
    flex: 0 0 auto;
    gap: .45rem;
    align-items: center;
}

.action-term-actions form {
    margin: 0;
}

.action-empty-mark {
    display: inline-flex;
    width: 3.5rem;
    height: 3.5rem;
    margin-bottom: 1rem;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #198754;
    background: rgba(25, 135, 84, .1);
    font-size: 1.65rem;
    font-weight: 800;
}

.calendar-month-summary {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: .75rem;
}

.calendar-month-summary div {
    padding: .85rem .5rem;
    border-radius: .9rem;
    background: #f7f9fc;
    text-align: center;
}

.calendar-month-summary strong,
.calendar-month-summary span {
    display: block;
}

.calendar-month-summary strong {
    color: #172033;
    font-size: 1.4rem;
}

.calendar-month-summary span {
    color: #667085;
    font-size: .72rem;
}

.action-mini-card {
    display: flex;
    height: 100%;
    min-height: 7.5rem;
    flex-direction: column;
    gap: .35rem;
    padding: 1rem;
    border: 1px solid #e9edf3;
    border-radius: 1rem;
    color: #172033;
    background: #fff;
    text-decoration: none;
    transition: transform .15s ease, box-shadow .15s ease;
}

.action-mini-card:hover {
    color: #172033;
    transform: translateY(-1px);
    box-shadow: 0 .5rem 1.2rem rgba(26, 45, 72, .08);
}

.action-mini-card span {
    color: #667085;
    font-size: .8rem;
}

.action-mini-card .badge {
    align-self: flex-start;
    margin-top: auto;
}

.calendar-shell {
    overflow-x: auto;
}

.calendar-grid {
    display: grid;
    min-width: 860px;
    grid-template-columns: repeat(7, minmax(0, 1fr));
}

.calendar-weekdays {
    border-bottom: 1px solid #e9edf3;
    background: #f7f9fc;
}

.calendar-weekdays div {
    padding: .8rem;
    color: #667085;
    font-size: .78rem;
    font-weight: 800;
    text-align: center;
    text-transform: uppercase;
}

.calendar-day {
    min-height: 9.5rem;
    padding: .65rem;
    border-right: 1px solid #edf0f4;
    border-bottom: 1px solid #edf0f4;
    background: #fff;
}

.calendar-day:nth-child(7n) {
    border-right: 0;
}

.calendar-day-muted {
    background: #fafbfc;
}

.calendar-day-today {
    box-shadow: inset 0 0 0 2px rgba(13, 110, 253, .65);
    background: rgba(13, 110, 253, .035);
}

.calendar-day-number {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: .5rem;
    font-weight: 800;
}

.calendar-day-number small {
    display: inline-flex;
    min-width: 1.45rem;
    height: 1.45rem;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #0d6efd;
    background: rgba(13, 110, 253, .1);
    font-size: .7rem;
}

.calendar-day-terms {
    display: flex;
    flex-direction: column;
    gap: .35rem;
}

.calendar-term {
    display: flex;
    min-width: 0;
    gap: .4rem;
    align-items: center;
    padding: .38rem .45rem;
    border-radius: .55rem;
    color: #263247;
    background: #f7f9fc;
    font-size: .75rem;
    text-decoration: none;
}

.calendar-term:hover {
    color: #0d6efd;
    background: rgba(13, 110, 253, .08);
}

.calendar-term > span:last-child {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.calendar-term-dot {
    width: .48rem;
    height: .48rem;
    flex: 0 0 auto;
    border-radius: 999px;
}

.calendar-term-done {
    opacity: .55;
    text-decoration: line-through;
}

.calendar-more {
    color: #667085;
    font-size: .72rem;
    text-decoration: none;
}

.dropdown-menu form .dropdown-item {
    width: 100%;
    border: 0;
    background: transparent;
    text-align: left;
}

@media (max-width: 767.98px) {
    .action-hero {
        padding: 1.25rem;
        border-radius: 1.15rem;
    }

    .action-summary-card {
        min-height: 8.25rem;
        padding: 1rem;
    }

    .action-summary-card strong {
        font-size: 2rem;
    }

    .action-term-row {
        align-items: stretch;
        flex-direction: column;
    }

    .action-term-actions {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .action-term-actions .btn,
    .action-term-actions form,
    .action-term-actions form .btn,
    .action-term-actions .dropdown,
    .action-term-actions .dropdown > .btn {
        width: 100%;
    }
}

/* v1.5.0.1 — poprawka wizualna kalendarza i odświeżanie zasobów */
.calendar-page-heading .display-6 {
    color: #172033;
    font-size: clamp(2rem, 3.5vw, 3rem);
    letter-spacing: -.035em;
}

.calendar-heading-actions .btn {
    min-height: 2.75rem;
    padding-inline: 1.15rem;
}

.calendar-toolbar-card {
    display: grid;
    grid-template-columns: minmax(9rem, 1fr) minmax(18rem, 2fr) minmax(9rem, 1fr);
    gap: 1rem;
    align-items: center;
    padding: 1rem;
    border: 1px solid rgba(23, 32, 51, .08);
    border-radius: 1.35rem;
    background:
        radial-gradient(circle at 50% -80%, rgba(13, 110, 253, .16), transparent 18rem),
        #fff;
    box-shadow: 0 .75rem 2rem rgba(30, 50, 80, .07);
}

.calendar-nav-button {
    display: inline-flex;
    min-height: 3rem;
    gap: .55rem;
    align-items: center;
    justify-content: center;
    padding: .75rem 1rem;
    border: 1px solid #d7dde7;
    border-radius: .9rem;
    color: #344054;
    background: rgba(255, 255, 255, .86);
    font-weight: 700;
    text-decoration: none;
    transition: transform .15s ease, border-color .15s ease, color .15s ease, box-shadow .15s ease;
}

.calendar-nav-button:hover {
    color: #0d6efd;
    border-color: rgba(13, 110, 253, .35);
    box-shadow: 0 .45rem 1rem rgba(30, 50, 80, .08);
    transform: translateY(-1px);
}

.calendar-nav-button-next {
    justify-self: end;
}

.calendar-toolbar-center {
    text-align: center;
}

.calendar-current-month {
    color: #172033;
    font-size: clamp(1.35rem, 2.1vw, 2rem);
    font-weight: 800;
    letter-spacing: -.025em;
}

.calendar-toolbar-stats {
    display: flex;
    gap: .5rem 1rem;
    align-items: center;
    justify-content: center;
    margin-top: .3rem;
    color: #667085;
    font-size: .82rem;
}

.calendar-toolbar-stats span {
    display: inline-flex;
    gap: .25rem;
    align-items: center;
}

.calendar-toolbar-stats strong {
    color: #172033;
}

.calendar-today-link {
    display: inline-flex;
    margin-top: .55rem;
    font-size: .78rem;
    font-weight: 700;
    text-decoration: none;
}

.calendar-shell {
    overflow: hidden;
    border: 1px solid rgba(23, 32, 51, .09);
    border-radius: 1.35rem;
    background: #fff;
    box-shadow: 0 .75rem 2rem rgba(30, 50, 80, .065);
}

.calendar-scroll {
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scrollbar-color: rgba(102, 112, 133, .45) transparent;
    scrollbar-width: thin;
}

.calendar-scroll:focus-visible {
    outline: 3px solid rgba(13, 110, 253, .22);
    outline-offset: -3px;
}

.calendar-grid {
    min-width: 980px;
}

.calendar-weekdays {
    position: sticky;
    top: 0;
    z-index: 2;
    border-bottom: 1px solid #e6eaf0;
    background: #f7f9fc;
}

.calendar-weekdays div {
    padding: .9rem .75rem;
    border-right: 1px solid #edf0f4;
    color: #667085;
    font-size: .74rem;
    letter-spacing: .055em;
}

.calendar-weekdays div:last-child {
    border-right: 0;
}

.calendar-weekdays .calendar-weekend-heading {
    color: #b54708;
    background: rgba(255, 193, 7, .055);
}

.calendar-day {
    position: relative;
    min-height: 10.25rem;
    padding: .72rem;
    transition: background-color .15s ease, box-shadow .15s ease;
}

.calendar-day:hover {
    z-index: 1;
    background: #fbfdff;
    box-shadow: inset 0 0 0 1px rgba(13, 110, 253, .12);
}

.calendar-day-weekend {
    background: rgba(255, 193, 7, .025);
}

.calendar-day-muted {
    background:
        repeating-linear-gradient(135deg, transparent, transparent 8px, rgba(23, 32, 51, .018) 8px, rgba(23, 32, 51, .018) 16px),
        #fafbfc;
}

.calendar-day-today {
    z-index: 1;
    background: linear-gradient(180deg, rgba(13, 110, 253, .07), rgba(13, 110, 253, .025));
    box-shadow: inset 0 0 0 2px rgba(13, 110, 253, .62);
}

.calendar-day-has-terms:not(.calendar-day-today) {
    background-color: #fff;
}

.calendar-day-number {
    min-height: 1.75rem;
    gap: .4rem;
}

.calendar-day-number-value {
    display: inline-flex;
    width: 1.8rem;
    height: 1.8rem;
    align-items: center;
    justify-content: center;
    border-radius: .6rem;
    color: #344054;
    font-size: .84rem;
    font-weight: 800;
}

.calendar-day-today .calendar-day-number-value {
    color: #fff;
    background: #0d6efd;
    box-shadow: 0 .25rem .7rem rgba(13, 110, 253, .26);
}

.calendar-day-number small {
    margin-left: auto;
    color: #344054;
    background: #eef2f7;
    font-weight: 800;
}

.calendar-today-badge {
    color: #0d6efd;
    font-size: .65rem;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.calendar-day-terms {
    gap: .42rem;
}

.calendar-term {
    position: relative;
    min-height: 2rem;
    padding: .45rem .52rem;
    border: 1px solid transparent;
    border-radius: .65rem;
    color: #263247;
    background: #f6f8fb;
    font-size: .75rem;
    font-weight: 650;
    transition: transform .12s ease, border-color .12s ease, background-color .12s ease, box-shadow .12s ease;
}

.calendar-term:hover {
    color: #172033;
    border-color: rgba(13, 110, 253, .2);
    background: #fff;
    box-shadow: 0 .35rem .85rem rgba(30, 50, 80, .09);
    transform: translateY(-1px);
}

.calendar-term-dot {
    width: .55rem;
    height: .55rem;
    box-shadow: 0 0 0 3px rgba(13, 110, 253, .08);
}

.calendar-term-title {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.calendar-term-important .calendar-term-dot,
.calendar-legend-important {
    background: #0d6efd;
}

.calendar-term-upcoming .calendar-term-dot,
.calendar-legend-upcoming {
    background: #f0ad00;
}

.calendar-term-urgent .calendar-term-dot,
.calendar-legend-urgent {
    background: #dc3545;
}

.calendar-term-overdue .calendar-term-dot,
.calendar-legend-overdue {
    background: #212529;
}

.calendar-term-done .calendar-term-dot,
.calendar-legend-done {
    background: #198754;
}

.calendar-term-urgent {
    background: rgba(220, 53, 69, .055);
}

.calendar-term-overdue {
    background: rgba(33, 37, 41, .06);
}

.calendar-term-upcoming {
    background: rgba(255, 193, 7, .075);
}

.calendar-term-done {
    opacity: .62;
}

.calendar-more {
    display: inline-flex;
    padding: .2rem .35rem;
    color: #0d6efd;
    font-weight: 700;
}

.calendar-legend {
    display: flex;
    gap: .65rem 1.2rem;
    align-items: center;
    flex-wrap: wrap;
    padding: .85rem 1rem;
    border-top: 1px solid #e9edf3;
    color: #667085;
    background: #fbfcfe;
    font-size: .72rem;
}

.calendar-legend span {
    display: inline-flex;
    gap: .4rem;
    align-items: center;
    white-space: nowrap;
}

.calendar-legend-dot {
    display: inline-block;
    width: .55rem;
    height: .55rem;
    border-radius: 999px;
}

.calendar-month-list-card {
    overflow: hidden;
    border-radius: 1.35rem;
}

.calendar-count-badge {
    display: inline-flex;
    min-width: 2.4rem;
    height: 2.4rem;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(13, 110, 253, .14);
    border-radius: .8rem;
    color: #0d6efd;
    background: rgba(13, 110, 253, .07);
    font-weight: 800;
}

.calendar-term-date {
    display: inline-flex;
    padding: .2rem .45rem;
    border-radius: .45rem;
    color: #475467;
    background: #f2f4f7;
    font-size: .72rem;
    font-weight: 700;
}

.action-term-row {
    position: relative;
    overflow: hidden;
    padding: 1.15rem 1.15rem 1.15rem 1.35rem;
    box-shadow: 0 .25rem .8rem rgba(30, 50, 80, .035);
    transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}

.action-term-row:hover {
    border-color: #dce3ed;
    box-shadow: 0 .65rem 1.35rem rgba(30, 50, 80, .075);
    transform: translateY(-1px);
}

.action-term-status-strip {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: .3rem;
    background: #0d6efd;
}

.action-term-row-upcoming .action-term-status-strip {
    background: #f0ad00;
}

.action-term-row-urgent .action-term-status-strip {
    background: #dc3545;
}

.action-term-row-overdue .action-term-status-strip {
    background: #212529;
}

.action-term-row-done .action-term-status-strip {
    background: #198754;
}

@media (max-width: 991.98px) {
    .calendar-toolbar-card {
        grid-template-columns: minmax(7rem, 1fr) minmax(15rem, 2fr) minmax(7rem, 1fr);
    }

    .calendar-grid {
        min-width: 860px;
    }
}

@media (max-width: 767.98px) {
    .calendar-page-heading .display-6 {
        font-size: 2rem;
    }

    .calendar-toolbar-card {
        grid-template-columns: 1fr minmax(10rem, 2fr) 1fr;
        gap: .55rem;
        padding: .75rem;
        border-radius: 1.05rem;
    }

    .calendar-nav-button {
        min-width: 0;
        padding: .65rem .6rem;
    }

    .calendar-nav-button span:not([aria-hidden="true"]) {
        display: none;
    }

    .calendar-nav-button-next {
        justify-self: stretch;
    }

    .calendar-current-month {
        font-size: 1.18rem;
    }

    .calendar-toolbar-stats {
        gap: .25rem .55rem;
        font-size: .7rem;
    }

    .calendar-today-link {
        margin-top: .35rem;
        font-size: .7rem;
    }

    .calendar-shell,
    .calendar-month-list-card {
        border-radius: 1.05rem;
    }

    .calendar-grid {
        min-width: 760px;
    }

    .calendar-day {
        min-height: 8.5rem;
        padding: .55rem;
    }

    .calendar-legend {
        overflow-x: auto;
        flex-wrap: nowrap;
    }

    .action-term-row {
        padding: 1rem 1rem 1rem 1.25rem;
    }
}

@media (max-width: 575.98px) {
    .calendar-heading-actions .btn {
        width: 100%;
    }

    .calendar-toolbar-stats span {
        display: block;
    }

    .calendar-weekdays div {
        padding: .7rem .5rem;
    }
}

/* Termino 1.5.1 — generator paczek dla AI */
.cursor-pointer { cursor: pointer; }
.ai-scope-option {
    transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.ai-scope-option:hover {
    border-color: rgba(13, 110, 253, .55) !important;
    box-shadow: 0 .35rem 1rem rgba(15, 23, 42, .08);
    transform: translateY(-1px);
}
.ai-scope-option:has(.form-check-input:checked) {
    border-color: var(--bs-primary) !important;
    background: rgba(13, 110, 253, .045);
    box-shadow: 0 0 0 .2rem rgba(13, 110, 253, .08);
}

/* Termino 1.5.3 — wiele przypomnień */
.reminder-picker {
    padding: 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 1rem;
    background: linear-gradient(180deg, #fbfdff 0%, #f8fafc 100%);
}

.reminder-picker-summary {
    white-space: nowrap;
    color: #0d6efd !important;
    background: #fff !important;
}

.reminder-profile-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: .65rem;
}

.reminder-profile-button {
    display: flex;
    min-height: 4.3rem;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    padding: .7rem .8rem;
    border: 1px solid #d9e1ec;
    border-radius: .8rem;
    color: #344054;
    background: #fff;
    text-align: left;
    transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease, background .15s ease;
}

.reminder-profile-button:hover,
.reminder-profile-button:focus-visible {
    border-color: rgba(13, 110, 253, .55);
    box-shadow: 0 .35rem .85rem rgba(30, 64, 175, .08);
    transform: translateY(-1px);
}

.reminder-profile-button.is-active {
    border-color: #0d6efd;
    color: #084298;
    background: rgba(13, 110, 253, .06);
    box-shadow: 0 0 0 .18rem rgba(13, 110, 253, .08);
}

.reminder-profile-title {
    font-weight: 750;
}

.reminder-profile-description {
    margin-top: .15rem;
    color: #667085;
    font-size: .72rem;
    line-height: 1.25;
}

.reminder-options-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .65rem;
}

.reminder-option {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: .7rem;
    align-items: flex-start;
    padding: .8rem;
    border: 1px solid #e2e8f0;
    border-radius: .8rem;
    background: #fff;
    cursor: pointer;
    transition: border-color .15s ease, background .15s ease, box-shadow .15s ease;
}

.reminder-option:hover {
    border-color: #b8c6da;
}

.reminder-option:has(.form-check-input:checked) {
    border-color: rgba(13, 110, 253, .55);
    background: rgba(13, 110, 253, .045);
    box-shadow: 0 .25rem .7rem rgba(13, 110, 253, .06);
}

.reminder-option .form-check-input {
    margin-top: .18rem;
}

.reminder-option-title {
    display: block;
    color: #1d2939;
    font-size: .9rem;
    font-weight: 700;
}

.reminder-option-date {
    display: block;
    margin-top: .15rem;
    color: #667085;
    font-size: .72rem;
    line-height: 1.25;
}

@media (max-width: 767.98px) {
    .reminder-profile-grid,
    .reminder-options-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 479.98px) {
    .reminder-profile-grid,
    .reminder-options-grid {
        grid-template-columns: 1fr;
    }
}

/* Termino 1.5.4 — import, eksport i kanał ICS */
.calendar-tools-icon {
    display: inline-grid;
    width: 2.75rem;
    height: 2.75rem;
    place-items: center;
    flex: 0 0 auto;
    border-radius: .9rem;
    color: #0d6efd;
    background: rgba(13, 110, 253, .09);
    font-size: 1.45rem;
    font-weight: 800;
}

.calendar-feed-card {
    overflow: hidden;
    border-top: .25rem solid #0d6efd !important;
}

.calendar-feed-card .font-monospace {
    font-size: .78rem;
}

.calendar-import-preview {
    border-top: .25rem solid #198754 !important;
}

.calendar-import-table th {
    color: #667085;
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .025em;
    text-transform: uppercase;
    white-space: nowrap;
}

.calendar-import-table td {
    min-width: 8rem;
}

.calendar-import-table td:nth-child(2) {
    min-width: 17rem;
}

@media (max-width: 767.98px) {
    .calendar-import-preview .card-body,
    .calendar-feed-card .card-body {
        padding: 1.15rem !important;
    }

    .calendar-feed-card .input-group {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
    }
}

/* Termino 1.5.5 — załączniki i dokumenty */
.min-w-0 { min-width: 0; }
.attachment-section {
    overflow: hidden;
    border-top: .25rem solid #0d6efd !important;
}
.attachment-section-icon {
    display: inline-grid;
    width: 2.25rem;
    height: 2.25rem;
    place-items: center;
    border-radius: .75rem;
    background: rgba(13, 110, 253, .09);
    font-size: 1.2rem;
}
.attachment-upload-box {
    padding: 1rem;
    border: 1px dashed #b9c6d8;
    border-radius: 1rem;
    background: linear-gradient(180deg, #fbfdff 0%, #f7faff 100%);
}
.attachment-empty {
    border: 1px dashed #d4dce8;
    border-radius: 1rem;
    background: #fbfcfe;
}
.attachment-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}
.attachment-card {
    display: grid;
    grid-template-columns: 7.5rem minmax(0, 1fr);
    overflow: hidden;
    border: 1px solid #e3e8ef;
    border-radius: 1rem;
    background: #fff;
    transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.attachment-card:hover {
    transform: translateY(-1px);
    border-color: #c7d2e2;
    box-shadow: 0 .55rem 1.35rem rgba(15, 23, 42, .08);
}
.attachment-preview,
.attachment-library-preview {
    display: grid;
    place-items: center;
    overflow: hidden;
    color: #344054;
    background: linear-gradient(145deg, #eef4ff 0%, #f8fafc 100%);
    font-size: 2.35rem;
}
.attachment-preview img,
.attachment-library-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.attachment-card-body { padding: 1rem; }
.attachment-name {
    overflow: hidden;
    color: #1d2939;
    font-size: .95rem;
    font-weight: 750;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.attachment-description {
    display: -webkit-box;
    overflow: hidden;
    margin-top: .65rem;
    color: #475467;
    font-size: .84rem;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}
.attachment-details { position: relative; }
.attachment-details > summary { list-style: none; }
.attachment-details > summary::-webkit-details-marker { display: none; }
.attachment-description-form {
    position: absolute;
    z-index: 20;
    top: calc(100% + .4rem);
    left: 0;
    display: grid;
    width: min(19rem, 75vw);
    gap: .5rem;
    padding: .75rem;
    border: 1px solid #dce3ed;
    border-radius: .8rem;
    background: #fff;
    box-shadow: 0 .8rem 2rem rgba(15, 23, 42, .14);
}
.document-usage-card {
    min-width: min(20rem, 100%);
    padding: .8rem 1rem;
    border: 1px solid #e3e8ef;
    border-radius: .9rem;
    background: #fff;
}
.document-usage-card .progress { height: .42rem; }
.attachment-library-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}
.attachment-library-card { overflow: hidden; }
.attachment-library-preview { height: 9rem; }

@media (max-width: 1199.98px) {
    .attachment-grid { grid-template-columns: 1fr; }
    .attachment-library-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 767.98px) {
    .attachment-section .card-body { padding: 1.15rem !important; }
    .attachment-card { grid-template-columns: 5.25rem minmax(0, 1fr); }
    .attachment-preview { font-size: 1.8rem; }
    .attachment-library-grid { grid-template-columns: 1fr; }
    .attachment-description-form { left: auto; right: 0; }
}
@media (max-width: 479.98px) {
    .attachment-card { display: block; }
    .attachment-preview { height: 7rem; }
    .attachment-card .btn,
    .attachment-card form { flex: 1 1 auto; }
    .attachment-card form .btn { width: 100%; }
}

/* Termino 1.5.6 — Centrum powiadomień */
.panel-notification-badge {
    min-width: 1.55rem;
    padding: .27rem .42rem;
    font-size: .7rem;
    line-height: 1;
}
.notification-hero {
    padding: 1.5rem;
    border: 1px solid #dbe7ff;
    border-radius: 1.15rem;
    background:
        radial-gradient(circle at 92% 18%, rgba(13, 110, 253, .12), transparent 28%),
        linear-gradient(135deg, #ffffff 0%, #f4f8ff 100%);
    box-shadow: 0 .55rem 1.45rem rgba(15, 23, 42, .06);
}
.notification-hero-count {
    display: flex;
    min-width: 11rem;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: .9rem 1.25rem;
    border: 1px solid rgba(13, 110, 253, .16);
    border-radius: 1rem;
    background: rgba(255, 255, 255, .82);
}
.notification-hero-count strong {
    color: #0d6efd;
    font-size: 2.1rem;
    line-height: 1;
}
.notification-hero-count span {
    margin-top: .35rem;
    color: #667085;
    font-size: .78rem;
    text-align: center;
}
.notification-tabs {
    gap: .45rem;
    padding: .4rem;
    border: 1px solid #e4e9f1;
    border-radius: .9rem;
    background: #fff;
    box-shadow: 0 .25rem .9rem rgba(15, 23, 42, .04);
}
.notification-tabs .nav-link {
    border-radius: .65rem;
    color: #475467;
    font-weight: 650;
}
.notification-tabs .nav-link.active { color: #fff; }
.notification-filter .badge { color: #344054 !important; }
.notification-list {
    display: grid;
    gap: .8rem;
}
.notification-card {
    position: relative;
    display: grid;
    grid-template-columns: 2.75rem minmax(0, 1fr) auto;
    gap: 1rem;
    align-items: center;
    padding: 1.1rem 1.2rem;
    overflow: hidden;
    border: 1px solid #e1e7ef;
    border-radius: 1rem;
    background: #fff;
    box-shadow: 0 .25rem .8rem rgba(15, 23, 42, .04);
    transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.notification-card::before {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: .28rem;
    background: #0d6efd;
    content: "";
}
.notification-card:hover {
    transform: translateY(-1px);
    border-color: #cbd6e5;
    box-shadow: 0 .55rem 1.2rem rgba(15, 23, 42, .08);
}
.notification-card.is-unread {
    border-color: #bad0f5;
    background: linear-gradient(90deg, #f5f9ff 0%, #fff 42%);
}
.notification-severity-success::before { background: #198754; }
.notification-severity-warning::before { background: #f59f00; }
.notification-severity-danger::before { background: #dc3545; }
.notification-icon {
    display: grid;
    width: 2.55rem;
    height: 2.55rem;
    place-items: center;
    border-radius: .8rem;
    color: #0d6efd;
    background: #eaf2ff;
    font-size: 1.1rem;
    font-weight: 900;
}
.notification-severity-success .notification-icon { color: #157347; background: #e8f6ee; }
.notification-severity-warning .notification-icon { color: #9a6700; background: #fff4d6; }
.notification-severity-danger .notification-icon { color: #b02a37; background: #fdecef; }
.notification-content { min-width: 0; }
.notification-new-dot {
    display: inline-flex;
    align-items: center;
    gap: .25rem;
    color: #0d6efd;
    font-size: .73rem;
    font-weight: 750;
}
.notification-new-dot::before {
    width: .45rem;
    height: .45rem;
    border-radius: 999px;
    background: #0d6efd;
    content: "";
}
.notification-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: .45rem;
}
.notification-actions form { margin: 0; }
.notification-empty-icon {
    display: grid;
    width: 4rem;
    height: 4rem;
    margin: 0 auto 1rem;
    place-items: center;
    border-radius: 50%;
    color: #157347;
    background: #e8f6ee;
    font-size: 1.8rem;
    font-weight: 900;
}
.notification-preferences {
    display: grid;
    gap: .75rem;
}
.notification-preference-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding: 1rem;
    border: 1px solid #e1e7ef;
    border-radius: .85rem;
    background: #fbfcfe;
    cursor: pointer;
}
.notification-preference-row:hover { border-color: #b9cae4; background: #f7faff; }
.notification-preference-row strong,
.notification-preference-row small { display: block; }
.notification-preference-row small { margin-top: .2rem; color: #667085; }
.dashboard-notification-list {
    display: grid;
    gap: .7rem;
}
.dashboard-notification-item {
    display: grid;
    grid-template-columns: .65rem minmax(0, 1fr);
    gap: .65rem;
    align-items: start;
}
.dashboard-notification-item strong,
.dashboard-notification-item small { display: block; }
.dashboard-notification-item strong { color: #344054; font-size: .88rem; line-height: 1.25; }
.dashboard-notification-item small { margin-top: .2rem; color: #98a2b3; font-size: .72rem; }
.dashboard-notification-dot {
    width: .55rem;
    height: .55rem;
    margin-top: .25rem;
    border-radius: 999px;
    background: #0d6efd;
}
.notification-dot-success { background: #198754; }
.notification-dot-warning { background: #f59f00; }
.notification-dot-danger { background: #dc3545; }

@media (max-width: 767.98px) {
    .notification-hero { padding: 1.15rem; }
    .notification-hero-count { width: 100%; }
    .notification-tabs { overflow-x: auto; flex-wrap: nowrap; }
    .notification-tabs .nav-link { white-space: nowrap; }
    .notification-filter { width: 100%; }
    .notification-filter .btn { flex: 1 1 auto; }
    .notification-card {
        grid-template-columns: 2.4rem minmax(0, 1fr);
        padding: 1rem;
    }
    .notification-icon { width: 2.25rem; height: 2.25rem; }
    .notification-actions {
        grid-column: 1 / -1;
        justify-content: stretch;
        padding-left: 3.05rem;
    }
    .notification-actions form { flex: 1 1 auto; }
    .notification-actions .btn { width: 100%; }
    .notification-preference-row { align-items: flex-start; gap: .8rem; }
}

@media (max-width: 479.98px) {
    .notification-card { grid-template-columns: 1fr; }
    .notification-icon { display: none; }
    .notification-actions { padding-left: 0; }
}

/* Termino 1.5.7 — Web Push */
.push-status-box {
    border: 1px solid #d8e1ee;
    border-radius: 1rem;
    background: #f7f9fc;
    padding: 1rem 1.1rem;
    color: #526176;
    font-weight: 600;
}
.push-status-box.is-active {
    border-color: #9bd5b0;
    background: #ecfbf1;
    color: #16733a;
}
.push-device-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    border: 1px solid #e4e9f1;
    border-radius: 1rem;
    padding: 1rem;
    background: #fff;
}
.push-device-card .action-eyebrow {
    display: inline-block;
    margin-bottom: .35rem;
}
@media (max-width: 767.98px) {
    .push-device-row {
        flex-direction: column;
    }
}

/* Termino 1.5.8 — wspólne gospodarstwa */
.household-card {
    transition: transform .18s ease, box-shadow .18s ease;
    overflow: hidden;
}
.household-card:hover,
.household-card:focus-visible {
    transform: translateY(-3px);
    box-shadow: 0 .8rem 2rem rgba(18, 38, 63, .13) !important;
}
.household-card-icon,
.household-empty-icon,
.household-stat-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 1rem;
    background: rgba(13, 110, 253, .1);
    color: #0d6efd;
    font-size: 1.4rem;
    font-weight: 700;
}
.household-empty-icon {
    width: 4.25rem;
    height: 4.25rem;
    border-radius: 1.35rem;
    font-size: 2rem;
}
.household-stat-icon {
    flex: 0 0 auto;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: .85rem;
    font-size: 1.15rem;
}
.household-card-stats strong,
.household-card-stats span {
    display: block;
}
.household-card-stats strong {
    font-size: 1.15rem;
    line-height: 1.2;
}
.household-card-stats span {
    color: #667085;
    font-size: .73rem;
    margin-top: .15rem;
}
.household-create-card {
    background: linear-gradient(135deg, #ffffff 0%, #f3f7ff 100%);
}
.household-invitation-card {
    background: linear-gradient(135deg, #ffffff 0%, #f5f8ff 100%);
}
.household-member-row {
    padding-bottom: .85rem;
    border-bottom: 1px solid #e9edf4;
}
.household-member-row:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}
.shared-term-card {
    position: relative;
    overflow: hidden;
}
.shared-term-card::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: .3rem;
    background: #6c757d;
}
.shared-term-card.is-overdue::before { background: #dc3545; }
.shared-term-card.is-today::before { background: #ffc107; }
.shared-term-card.is-upcoming::before { background: #0d6efd; }
.shared-term-card.is-done::before { background: #198754; }
.shared-term-card.is-done { opacity: .82; }
.shared-term-note {
    padding: .7rem .85rem;
    border-left: .2rem solid #0d6efd;
    border-radius: .45rem;
    background: #f4f7fc;
    color: #344054;
}
.shared-term-actions {
    min-width: 8.5rem;
}
.gap-x-3 { column-gap: 1rem; }
.min-w-0 { min-width: 0; }

@media (max-width: 767.98px) {
    .shared-term-actions {
        min-width: 0;
        width: 100%;
    }
    .shared-term-actions form,
    .shared-term-actions button {
        flex: 1 1 auto;
    }
    .household-card-stats span {
        font-size: .67rem;
    }
}

/* Termino 1.5.9 — inteligentne kreatory */
.wizard-hero {
    padding: clamp(1.4rem, 3vw, 2.5rem);
    border-radius: 1.35rem;
    background: linear-gradient(135deg, rgba(13,110,253,.10), rgba(111,66,193,.08));
    border: 1px solid rgba(13,110,253,.12);
}
.wizard-pack-card {
    display: flex;
    flex-direction: column;
    gap: .65rem;
    padding: 1.45rem;
    border-radius: 1.2rem;
    background: #fff;
    color: inherit;
    text-decoration: none;
    border: 1px solid rgba(33,37,41,.08);
    box-shadow: 0 .45rem 1.4rem rgba(33,37,41,.07);
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.wizard-pack-card:hover {
    color: inherit;
    transform: translateY(-3px);
    box-shadow: 0 .8rem 2rem rgba(33,37,41,.12);
    border-color: rgba(13,110,253,.3);
}
.wizard-pack-card strong { font-size: 1.2rem; }
.wizard-pack-card > span:not(.wizard-pack-icon):not(.action-eyebrow) { color: #6c757d; line-height: 1.55; }
.wizard-pack-card small { margin-top: auto; color: #0d6efd; font-weight: 700; }
.wizard-pack-icon,
.wizard-title-icon {
    display: inline-grid;
    place-items: center;
    width: 3.4rem;
    height: 3.4rem;
    border-radius: 1rem;
    font-size: 1.75rem;
    background: rgba(13,110,253,.09);
}
.wizard-title-icon { flex: 0 0 auto; width: 4rem; height: 4rem; font-size: 2rem; }
.wizard-step-heading { display: flex; gap: 1rem; align-items: flex-start; }
.wizard-step-heading > span {
    display: inline-grid;
    place-items: center;
    flex: 0 0 auto;
    width: 2.6rem;
    height: 2.6rem;
    border-radius: .85rem;
    background: #0d6efd;
    color: #fff;
    font-weight: 800;
}
.wizard-term-card {
    padding: 1rem;
    border: 1px solid rgba(33,37,41,.12);
    border-radius: 1rem;
    background: #f8f9fa;
    transition: border-color .18s ease, background .18s ease, box-shadow .18s ease;
}
.wizard-term-card.is-selected {
    background: #fff;
    border-color: rgba(13,110,253,.38);
    box-shadow: 0 .35rem 1rem rgba(13,110,253,.08);
}
.wizard-term-toggle { display: flex; align-items: flex-start; gap: .8rem; }
.wizard-term-toggle .form-check-input { margin-top: .25rem; width: 1.25rem; height: 1.25rem; }
.wizard-term-toggle label { display: flex; flex-direction: column; gap: .2rem; cursor: pointer; }
.wizard-term-toggle label strong { font-size: 1.03rem; }
.wizard-term-toggle label span { color: #6c757d; font-size: .9rem; }
.wizard-term-fields { margin-top: 1rem; opacity: .55; pointer-events: none; }
.wizard-term-card.is-selected .wizard-term-fields { opacity: 1; pointer-events: auto; }
.wizard-submit-bar {
    position: sticky;
    bottom: 1rem;
    z-index: 20;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.2rem;
    border: 1px solid rgba(33,37,41,.10);
    border-radius: 1rem;
    background: rgba(255,255,255,.96);
    backdrop-filter: blur(10px);
}
.wizard-submit-bar > div:first-child { display: flex; flex-direction: column; }
.wizard-submit-bar span { color: #6c757d; font-size: .86rem; }
@media (max-width: 767.98px) {
    .wizard-submit-bar { position: static; flex-direction: column; align-items: stretch; }
    .wizard-submit-bar > div:last-child { display: grid !important; grid-template-columns: 1fr 1fr; }
    .wizard-title-icon { width: 3.3rem; height: 3.3rem; font-size: 1.7rem; }
}

/* Termino 1.6.0 — organizacje i obowiązki firmowe */
.organization-empty-icon {
    font-size: 3.25rem;
    line-height: 1;
    margin-bottom: 1rem;
}
.organization-card {
    color: inherit;
    transition: transform .18s ease, box-shadow .18s ease;
    overflow: hidden;
}
.organization-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 1rem 2rem rgba(20, 45, 90, .12) !important;
}
.organization-card-arrow {
    display: grid;
    place-items: center;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 50%;
    background: rgba(13, 110, 253, .1);
    color: #0d6efd;
    font-weight: 800;
}
.organization-card-stats,
.organization-summary-grid {
    display: grid;
}
.organization-card-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: .65rem;
}
.organization-card-stats > div {
    padding: .75rem .5rem;
    border-radius: .85rem;
    background: #f6f8fb;
    text-align: center;
}
.organization-card-stats strong,
.organization-card-stats span {
    display: block;
}
.organization-card-stats strong {
    font-size: 1.3rem;
    color: #172033;
}
.organization-card-stats span {
    font-size: .72rem;
    color: #6c757d;
}
.organization-summary-card {
    height: 100%;
    padding: 1rem 1.15rem;
    border: 1px solid rgba(18, 38, 63, .08);
    border-radius: 1rem;
    background: #fff;
    box-shadow: 0 .35rem 1.15rem rgba(20, 45, 90, .06);
}
.organization-summary-card span,
.organization-summary-card strong {
    display: block;
}
.organization-summary-card span {
    color: #6c757d;
    font-size: .78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .04em;
}
.organization-summary-card strong {
    margin-top: .15rem;
    font-size: 1.85rem;
    color: #172033;
}
.organization-summary-card.is-danger {
    border-color: rgba(220, 53, 69, .2);
    background: linear-gradient(135deg, #fff, #fff4f5);
}
.organization-summary-card.is-danger strong { color: #bb2d3b; }
.organization-summary-card.is-success {
    border-color: rgba(25, 135, 84, .18);
    background: linear-gradient(135deg, #fff, #f1fbf6);
}
.organization-summary-card.is-success strong { color: #157347; }
.organization-task-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.1rem;
    border: 1px solid rgba(18, 38, 63, .09);
    border-left: .32rem solid #0d6efd;
    border-radius: 1rem;
    background: #fff;
}
.organization-task-card.is-overdue { border-left-color: #dc3545; background: #fffafb; }
.organization-task-card.is-today { border-left-color: #ffc107; background: #fffdf6; }
.organization-task-card.is-progress { border-left-color: #0dcaf0; }
.organization-task-card.is-completed { border-left-color: #198754; opacity: .88; }
.organization-task-main { min-width: 0; flex: 1; }
.organization-task-actions { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.organization-task-details > div {
    padding: .85rem;
    border-radius: .85rem;
    background: #f7f9fc;
}
.organization-task-details span,
.organization-task-details strong { display: block; }
.organization-task-details span { font-size: .75rem; color: #6c757d; text-transform: uppercase; font-weight: 700; letter-spacing: .035em; }
.organization-task-details strong { margin-top: .25rem; color: #172033; }
.organization-task-description { line-height: 1.7; }
.organization-completion-card { border-top: .25rem solid #198754 !important; }
.organization-activity-list { position: relative; }
.organization-activity-item {
    display: grid;
    grid-template-columns: 1rem minmax(0, 1fr);
    gap: .75rem;
    padding: .75rem 0;
    border-bottom: 1px solid rgba(18, 38, 63, .08);
}
.organization-activity-item:last-child { border-bottom: 0; }
.organization-activity-dot {
    width: .65rem;
    height: .65rem;
    margin-top: .35rem;
    border-radius: 50%;
    background: #0d6efd;
    box-shadow: 0 0 0 .25rem rgba(13, 110, 253, .12);
}
.dashboard-organization-card { border-left: .3rem solid #6f42c1 !important; }
.organization-report-table th { white-space: nowrap; }

@media (max-width: 767.98px) {
    .organization-task-card { align-items: flex-start; flex-direction: column; }
    .organization-task-actions { width: 100%; }
    .organization-task-actions .btn,
    .organization-task-actions form { flex: 1; }
    .organization-task-actions form .btn { width: 100%; }
    .organization-card-stats { gap: .35rem; }
}

@media print {
    .organization-report .card { box-shadow: none !important; border: 1px solid #ddd !important; }
    .organization-report .organization-summary-card { box-shadow: none; }
    .organization-report-table { font-size: 10px; }
    .panel-navbar, .mobile-floating-add, .offline-banner, .no-print { display: none !important; }
    main { padding: 0 !important; }
    body { background: #fff !important; }
}

/* v1.6.0.1 — porządkowanie nawigacji i pulpitu */
.panel-navbar {
    min-height: 4.25rem;
    padding-block: .55rem;
    box-shadow: 0 .35rem 1.25rem rgba(13, 58, 130, .16);
}

.panel-navbar-inner {
    min-width: 0;
}

.panel-navbar .navbar-brand {
    flex: 0 0 auto;
    font-size: 1.08rem;
    white-space: nowrap;
}

.panel-primary-nav {
    min-width: 0;
    align-items: center;
    gap: .15rem;
}

.panel-primary-nav .nav-link {
    border-radius: .72rem;
    padding: .58rem .72rem !important;
    color: rgba(255,255,255,.72);
    font-size: .88rem;
    font-weight: 600;
    white-space: nowrap;
    transition: color .15s ease, background-color .15s ease;
}

.panel-primary-nav .nav-link:hover,
.panel-primary-nav .nav-link:focus,
.panel-primary-nav .nav-link.active {
    color: #fff;
    background: rgba(255,255,255,.13);
}

.panel-primary-nav button.nav-link {
    border: 0;
    background-color: transparent;
}

.panel-menu-dropdown {
    width: 18rem;
    padding: .55rem;
    border: 1px solid rgba(18, 38, 63, .09);
    border-radius: 1rem;
}

.panel-menu-dropdown .dropdown-item {
    display: flex;
    flex-direction: column;
    gap: .05rem;
    padding: .65rem .75rem;
    border-radius: .7rem;
}

.panel-menu-dropdown .dropdown-item span {
    font-weight: 700;
}

.panel-menu-dropdown .dropdown-item small {
    color: #7b879a;
    font-size: .72rem;
}

.panel-menu-dropdown .dropdown-item.active small {
    color: rgba(255,255,255,.78);
}

.panel-navbar-actions {
    flex: 0 0 auto;
}

.panel-add-button {
    min-height: 2.45rem;
    align-items: center;
    padding-inline: .9rem;
    border-radius: .75rem;
    font-weight: 700;
    white-space: nowrap;
}

.panel-notification-button {
    position: relative;
    display: inline-flex;
    min-width: 2.5rem;
    height: 2.5rem;
    gap: .45rem;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255,255,255,.24);
    border-radius: .8rem;
    color: #fff;
    background: rgba(255,255,255,.09);
    text-decoration: none;
}

.panel-notification-button:hover,
.panel-notification-button.active {
    color: #fff;
    background: rgba(255,255,255,.18);
}

.panel-notification-button svg {
    width: 1.2rem;
    height: 1.2rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.panel-notification-button b {
    position: absolute;
    top: -.42rem;
    right: -.42rem;
    display: inline-flex;
    min-width: 1.3rem;
    height: 1.3rem;
    align-items: center;
    justify-content: center;
    padding: 0 .28rem;
    border: 2px solid #0d6efd;
    border-radius: 999px;
    color: #fff;
    background: #dc3545;
    font-size: .62rem;
}

.panel-account-button {
    display: inline-flex;
    min-width: 0;
    height: 2.5rem;
    gap: .55rem;
    align-items: center;
    padding: .25rem .65rem .25rem .3rem;
    border: 1px solid rgba(255,255,255,.24);
    border-radius: .85rem;
    color: #fff;
    background: rgba(255,255,255,.09);
    text-align: left;
}

.panel-account-button:hover,
.panel-account-button[aria-expanded="true"] {
    background: rgba(255,255,255,.18);
}

.panel-account-avatar {
    display: inline-flex;
    width: 1.95rem;
    height: 1.95rem;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    border-radius: .65rem;
    color: #0d6efd;
    background: #fff;
    font-size: .82rem;
    font-weight: 800;
}

.panel-account-avatar-lg {
    width: 2.55rem;
    height: 2.55rem;
    border: 1px solid rgba(13,110,253,.12);
    color: #0d6efd;
    background: #edf5ff;
    font-size: 1rem;
}

.panel-account-copy {
    min-width: 0;
    max-width: 11rem;
    flex-direction: column;
    line-height: 1.15;
}

.panel-account-copy strong,
.panel-account-copy small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.panel-account-copy strong {
    font-size: .8rem;
}

.panel-account-copy small {
    margin-top: .15rem;
    color: rgba(255,255,255,.65);
    font-size: .65rem;
}

.panel-account-menu {
    width: min(20rem, calc(100vw - 2rem));
    padding: .55rem;
    border: 1px solid rgba(18,38,63,.09);
    border-radius: 1rem;
}

.panel-account-menu-head {
    display: flex;
    min-width: 0;
    gap: .7rem;
    align-items: center;
    padding: .45rem;
}

.panel-account-menu-head > div {
    min-width: 0;
}

.panel-account-menu-head strong,
.panel-account-menu-head small {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.panel-account-menu-head small {
    color: #7b879a;
    font-size: .74rem;
}

.panel-account-menu .dropdown-item {
    border-radius: .65rem;
    padding: .62rem .7rem;
}

.panel-mobile-notification {
    position: relative;
    display: inline-flex;
    width: 2.25rem;
    height: 2.25rem;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255,255,255,.28);
    border-radius: .7rem;
    color: #fff;
    text-decoration: none;
}

.panel-mobile-notification > span {
    font-size: .5rem;
}

.panel-mobile-notification b {
    position: absolute;
    top: -.42rem;
    right: -.42rem;
    min-width: 1.2rem;
    padding: .1rem .25rem;
    border-radius: 999px;
    color: #fff;
    background: #dc3545;
    font-size: .58rem;
    text-align: center;
}

.panel-main-container {
    max-width: 1320px;
}

.dashboard-hero {
    padding: clamp(1.4rem, 3vw, 2.35rem);
}

.dashboard-quick-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .65rem;
}

.dashboard-quick-action {
    display: flex;
    min-width: 0;
    min-height: 4.35rem;
    gap: .7rem;
    align-items: center;
    padding: .72rem;
    border: 1px solid rgba(18,38,63,.1);
    border-radius: 1rem;
    color: #263247;
    background: rgba(255,255,255,.88);
    text-decoration: none;
    transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease;
}

.dashboard-quick-action:hover {
    color: #0d6efd;
    border-color: rgba(13,110,253,.3);
    transform: translateY(-1px);
    box-shadow: 0 .55rem 1.25rem rgba(23,55,105,.08);
}

.dashboard-quick-action-primary {
    color: #fff;
    border-color: #0d6efd;
    background: linear-gradient(135deg, #0d6efd, #2d7ff9);
}

.dashboard-quick-action-primary:hover {
    color: #fff;
    border-color: #0a58ca;
}

.dashboard-quick-action-icon {
    display: inline-flex;
    width: 2.35rem;
    height: 2.35rem;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    border-radius: .8rem;
    color: #0d6efd;
    background: rgba(13,110,253,.1);
    font-size: .88rem;
    font-weight: 800;
}

.dashboard-quick-action-primary .dashboard-quick-action-icon {
    color: #fff;
    background: rgba(255,255,255,.18);
}

.dashboard-quick-action > span:last-child {
    min-width: 0;
}

.dashboard-quick-action strong,
.dashboard-quick-action small {
    display: block;
}

.dashboard-quick-action strong {
    font-size: .86rem;
    line-height: 1.2;
}

.dashboard-quick-action small {
    margin-top: .18rem;
    overflow: hidden;
    color: #7b879a;
    font-size: .67rem;
    line-height: 1.2;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dashboard-quick-action-primary small {
    color: rgba(255,255,255,.78);
}

.action-summary-card {
    min-height: 7.75rem;
    padding: 1.05rem 1.15rem;
}

.action-summary-card strong {
    font-size: 2rem;
}

.action-priority-card {
    min-height: 0;
}

.action-term-row {
    transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease;
}

.action-term-row:hover {
    border-color: rgba(13,110,253,.2);
    transform: translateY(-1px);
    box-shadow: 0 .45rem 1rem rgba(23,55,105,.055);
}

@media (min-width: 1200px) and (max-width: 1399.98px) {
    .panel-primary-nav .nav-link {
        padding-inline: .55rem !important;
        font-size: .82rem;
    }

    .panel-add-button {
        display: none !important;
    }
}

@media (max-width: 1199.98px) {
    .panel-navbar {
        min-height: 3.75rem;
        padding-block: .45rem;
    }

    .panel-navbar .navbar-collapse {
        max-height: calc(100vh - 4.5rem);
        overflow-y: auto;
        margin-top: .65rem;
        padding: .75rem;
        border-radius: 1rem;
        background: rgba(0,51,153,.3);
        backdrop-filter: blur(12px);
    }

    .panel-primary-nav {
        align-items: stretch;
    }

    .panel-primary-nav .nav-link {
        padding: .72rem .8rem !important;
    }

    .panel-menu-dropdown {
        width: 100%;
        border: 0;
        box-shadow: none !important;
    }

    .panel-notification-button,
    .panel-account-button {
        width: 100%;
        height: auto;
        min-height: 2.75rem;
        justify-content: flex-start;
        padding: .45rem .65rem;
    }

    .panel-notification-button b {
        position: static;
        margin-left: auto;
        border: 0;
    }

    .panel-account-dropdown,
    .panel-account-menu {
        width: 100%;
    }

    .panel-account-menu {
        max-width: none;
    }
}

@media (max-width: 767.98px) {
    .dashboard-quick-actions {
        grid-template-columns: 1fr;
    }

    .dashboard-quick-action {
        min-height: 3.9rem;
    }

    .action-summary-card {
        min-height: 7rem;
    }
}

@media (max-width: 420px) {
    .panel-mobile-add {
        display: none;
    }
}

/* Termino 1.6.1 — Raporty PRO */
.report-pro-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding: 1.6rem 1.75rem;
    border: 1px solid #dbe7ff;
    border-radius: 1.25rem;
    background: linear-gradient(135deg, #ffffff 0%, #eef5ff 100%);
    box-shadow: 0 14px 35px rgba(31, 80, 150, .08);
}
.report-pro-eyebrow {
    margin-bottom: .35rem;
    color: #0d6efd;
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .09em;
    text-transform: uppercase;
}
.report-pro-actions { display: flex; flex-wrap: wrap; gap: .65rem; }
.report-filter-card { overflow: hidden; }
.report-kpi-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: .9rem;
}
.report-kpi-card {
    min-width: 0;
    padding: 1rem 1.05rem;
    border: 1px solid #e3e8f0;
    border-top: 3px solid #6c757d;
    border-radius: 1rem;
    background: #fff;
    box-shadow: 0 7px 20px rgba(31, 42, 68, .05);
}
.report-kpi-card span,
.report-kpi-card small { display: block; color: #667085; }
.report-kpi-card span { min-height: 2.2em; font-size: .75rem; font-weight: 700; }
.report-kpi-card strong { display: block; margin: .3rem 0; font-size: clamp(1.35rem, 2vw, 2rem); line-height: 1; color: #1d2939; }
.report-kpi-card small { font-size: .69rem; line-height: 1.35; }
.report-kpi-card.is-success { border-top-color: #198754; background: linear-gradient(180deg, #fff 0%, #f2fbf6 100%); }
.report-kpi-card.is-danger { border-top-color: #dc3545; background: linear-gradient(180deg, #fff 0%, #fff4f5 100%); }
.report-kpi-card.is-money { border-top-color: #7c3aed; background: linear-gradient(180deg, #fff 0%, #f8f5ff 100%); }
.report-kpi-card.is-info { border-top-color: #0d6efd; background: linear-gradient(180deg, #fff 0%, #f1f6ff 100%); }
.report-kpi-card.is-business { border-top-color: #d97706; background: linear-gradient(180deg, #fff 0%, #fff8eb 100%); }
.report-chart-card { overflow: hidden; }
.report-chart-legend { display: flex; flex-wrap: wrap; gap: 1rem; font-size: .75rem; color: #667085; }
.report-chart-legend span { display: inline-flex; align-items: center; gap: .35rem; }
.report-chart-legend i { width: .7rem; height: .7rem; border-radius: .2rem; background: #a9c6ff; }
.report-chart-legend i.is-done { background: #198754; }
.report-trend-chart {
    display: grid;
    grid-template-columns: repeat(12, minmax(30px, 1fr));
    align-items: end;
    gap: .45rem;
    min-height: 245px;
    padding: 1rem .25rem .25rem;
    border-bottom: 1px solid #e5eaf1;
    background-image: linear-gradient(to top, rgba(148,163,184,.14) 1px, transparent 1px);
    background-size: 100% 25%;
    overflow-x: auto;
}
.report-trend-column { display: flex; min-width: 34px; height: 220px; flex-direction: column; justify-content: flex-end; align-items: center; gap: .45rem; }
.report-trend-bars { display: flex; align-items: flex-end; justify-content: center; gap: 3px; width: 100%; height: 185px; }
.report-trend-bar { display: block; width: min(14px, 38%); min-height: 3px; border-radius: .35rem .35rem .1rem .1rem; background: #a9c6ff; transition: height .2s ease; }
.report-trend-bar.is-done { background: #198754; }
.report-trend-column small { color: #667085; font-size: .62rem; white-space: nowrap; transform: rotate(-35deg); transform-origin: center; margin-bottom: .35rem; }
.report-ring {
    --value: 0;
    width: 150px;
    aspect-ratio: 1;
    margin: .75rem auto;
    padding: 13px;
    border-radius: 50%;
    background: conic-gradient(#198754 calc(var(--value) * 1%), #e9eef5 0);
}
.report-ring > div { display: flex; width: 100%; height: 100%; flex-direction: column; align-items: center; justify-content: center; border-radius: 50%; background: #fff; box-shadow: inset 0 0 0 1px #edf0f4; }
.report-ring strong { font-size: 1.8rem; line-height: 1; }
.report-ring span { color: #667085; font-size: .7rem; }
.report-mini-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .65rem; }
.report-mini-stats > div { display: flex; align-items: center; justify-content: space-between; gap: .5rem; padding: .7rem .75rem; border: 1px solid #e7ebf1; border-radius: .75rem; background: #f9fafc; }
.report-mini-stats span { color: #667085; font-size: .72rem; }
.report-mini-stats strong { font-size: .9rem; }
.report-category-list { display: grid; gap: .65rem; }
.report-category-row {
    display: grid;
    grid-template-columns: minmax(130px, 1.15fr) minmax(100px, 1fr) minmax(115px, .8fr) minmax(90px, .55fr);
    align-items: center;
    gap: .8rem;
    padding: .75rem .8rem;
    border: 1px solid #e6ebf2;
    border-radius: .85rem;
    background: #fff;
}
.report-category-name { display: flex; align-items: center; gap: .55rem; min-width: 0; }
.report-category-name i { flex: 0 0 auto; width: .72rem; height: .72rem; border-radius: 50%; }
.report-category-name strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .82rem; }
.report-category-progress { height: .48rem; overflow: hidden; border-radius: 1rem; background: #edf1f6; }
.report-category-progress span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #0d6efd, #198754); }
.report-category-numbers strong,
.report-category-numbers small { display: block; }
.report-category-numbers strong { font-size: .82rem; }
.report-category-numbers small { color: #667085; font-size: .65rem; }
.report-category-cost { text-align: right; font-size: .75rem; font-weight: 700; white-space: nowrap; }
.report-area-row { grid-template-columns: minmax(150px, 1.2fr) minmax(100px, 1fr) minmax(150px, .9fr); }
.report-email-form { padding: 1rem; border: 1px solid #e5eaf1; border-radius: .9rem; background: #f9fbfe; }
.report-delivery-history { display: grid; gap: .45rem; }
.report-delivery-history > div { display: flex; justify-content: space-between; align-items: center; padding: .4rem 0; border-bottom: 1px solid #eef1f5; font-size: .75rem; }
.report-pro-table th { color: #667085; font-size: .68rem; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; white-space: nowrap; }
.report-pro-table td { font-size: .78rem; }
.report-overdue-list { display: grid; gap: .55rem; }
.report-overdue-list a { display: block; padding: .65rem .7rem; border: 1px solid #f0d5d9; border-left: 3px solid #dc3545; border-radius: .7rem; color: inherit; text-decoration: none; background: #fffafb; }
.report-overdue-list a:hover { background: #fff3f5; }
.report-overdue-list strong,
.report-overdue-list small { display: block; }
.report-overdue-list strong { font-size: .8rem; }
.report-overdue-list small { margin-top: .15rem; color: #8b4b53; font-size: .66rem; }
.report-workload-list { display: grid; gap: .55rem; }
.report-workload-list article { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .7rem .75rem; border: 1px solid #e6ebf2; border-radius: .75rem; }
.report-workload-list strong,
.report-workload-list small { display: block; }
.report-workload-list strong { font-size: .8rem; }
.report-workload-list small { color: #667085; font-size: .67rem; }
.report-workload-list > article > span { font-size: 1rem; font-weight: 800; }

@media (max-width: 1399.98px) {
    .report-kpi-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 991.98px) {
    .report-pro-hero { align-items: flex-start; flex-direction: column; }
    .report-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .report-category-row { grid-template-columns: minmax(120px, 1fr) minmax(90px, 1fr) minmax(110px, .8fr); }
    .report-category-cost { grid-column: 1 / -1; text-align: left; }
    .report-area-row { grid-template-columns: minmax(130px, 1fr) minmax(90px, 1fr); }
    .report-area-row .report-category-numbers { grid-column: 1 / -1; }
}
@media (max-width: 575.98px) {
    .report-pro-hero { padding: 1.15rem; border-radius: 1rem; }
    .report-pro-actions { width: 100%; }
    .report-pro-actions .btn { flex: 1 1 auto; }
    .report-kpi-grid { gap: .65rem; }
    .report-kpi-card { padding: .85rem; }
    .report-category-row { grid-template-columns: 1fr; gap: .45rem; }
    .report-category-cost { grid-column: auto; }
    .report-trend-chart { grid-template-columns: repeat(12, 38px); }
}
@media print {
    .report-pro-organization .report-kpi-grid { grid-template-columns: repeat(5, 1fr); }
    .report-pro-organization .report-kpi-card { padding: 7px; box-shadow: none; }
    .report-pro-organization .report-kpi-card span { min-height: 0; }
    .report-pro-organization .report-kpi-card strong { font-size: 16px; }
}


/* Termino 1.6.2 — import dokumentów wspomagany przez AI */
.ai-document-source-card { overflow: hidden; }
.ai-document-preview-link { display: block; border-radius: 1rem; overflow: hidden; background: #eef3fb; border: 1px solid rgba(13,110,253,.15); }
.ai-document-preview-image { display: block; width: 100%; max-height: 440px; object-fit: contain; background: #f8fafc; }
.ai-upload-zone { padding: 1.5rem; border: 2px dashed rgba(13,110,253,.3); border-radius: 1rem; background: linear-gradient(145deg, rgba(13,110,253,.04), rgba(111,66,193,.04)); }
.ai-term-suggestion { padding: 1.25rem; border: 1px solid #dde5ef; border-radius: 1rem; background: #fff; box-shadow: 0 .4rem 1.2rem rgba(31,49,74,.05); }
.ai-term-suggestion:has(.form-check-input:not(:checked)) { opacity: .62; background: #f8f9fa; }
@media (max-width: 767.98px) {
  .ai-upload-zone { padding: 1rem; }
  .ai-term-suggestion { padding: 1rem; }
  .ai-document-preview-image { max-height: 320px; }
}

/* Termino 1.6.4 — globalna wyszukiwarka i szybkie działania */
.panel-search-button {
    display: inline-flex;
    min-height: 2.5rem;
    align-items: center;
    justify-content: center;
    gap: .45rem;
    padding: .42rem .62rem;
    border: 1px solid rgba(255,255,255,.24);
    border-radius: .8rem;
    color: #fff;
    background: rgba(255,255,255,.09);
    font-size: .78rem;
    font-weight: 700;
    white-space: nowrap;
}
.panel-search-button:hover,
.panel-search-button.active {
    background: rgba(255,255,255,.18);
}
.panel-search-button > span:first-child { font-size: 1.15rem; line-height: 1; }
.panel-search-button kbd {
    padding: .15rem .32rem;
    border: 1px solid rgba(255,255,255,.22);
    border-radius: .35rem;
    color: rgba(255,255,255,.82);
    background: rgba(0,0,0,.12);
    font-size: .58rem;
    font-weight: 600;
}
.panel-mobile-search {
    display: inline-flex;
    width: 2.2rem;
    height: 2.2rem;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255,255,255,.28);
    border-radius: .7rem;
    color: #fff;
    background: rgba(255,255,255,.1);
    font-size: 1.15rem;
}

body.global-search-open { overflow: hidden; }
.global-search-overlay {
    position: fixed;
    inset: 0;
    z-index: 1085;
    display: grid;
    align-items: start;
    justify-items: center;
    padding: min(10vh, 5rem) 1rem 1rem;
}
.global-search-overlay[hidden] { display: none !important; }
.global-search-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15,23,42,.62);
    backdrop-filter: blur(7px);
}
.global-search-dialog {
    position: relative;
    display: flex;
    width: min(760px, 100%);
    max-height: min(78vh, 720px);
    flex-direction: column;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,.4);
    border-radius: 1.25rem;
    background: #fff;
    box-shadow: 0 30px 90px rgba(2,12,33,.35);
    animation: global-search-enter .16s ease-out;
}
@keyframes global-search-enter {
    from { opacity: 0; transform: translateY(-10px) scale(.985); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
.global-search-header {
    display: grid;
    grid-template-columns: auto minmax(0,1fr) auto;
    align-items: center;
    gap: .75rem;
    padding: .85rem 1rem;
    border-bottom: 1px solid #e8edf4;
}
.global-search-mark {
    display: inline-flex;
    width: 2.35rem;
    height: 2.35rem;
    align-items: center;
    justify-content: center;
    border-radius: .75rem;
    color: #0d6efd;
    background: #edf5ff;
    font-size: 1.25rem;
    font-weight: 800;
}
.global-search-input-wrap input {
    width: 100%;
    border: 0;
    outline: 0;
    color: #172033;
    background: transparent;
    font-size: clamp(1rem, 2vw, 1.2rem);
    font-weight: 600;
}
.global-search-input-wrap input::placeholder { color: #8b97a8; font-weight: 500; }
.global-search-close {
    padding: .35rem .5rem;
    border: 1px solid #d9e0e9;
    border-radius: .5rem;
    color: #667085;
    background: #f8fafc;
    font-size: .68rem;
    font-weight: 700;
}
.global-search-body {
    min-height: 240px;
    overflow-y: auto;
    padding: .65rem;
}
.global-search-status {
    padding: .35rem .55rem .65rem;
    color: #667085;
    font-size: .72rem;
}
.global-search-status.is-loading { color: #0d6efd; }
.global-search-status.is-error { color: #b42318; }
.global-search-results,
.global-search-actions { display: grid; gap: .35rem; }
.global-search-result,
.global-search-action {
    display: grid;
    grid-template-columns: auto minmax(0,1fr) auto;
    align-items: center;
    gap: .75rem;
    padding: .72rem .8rem;
    border: 1px solid transparent;
    border-radius: .85rem;
    color: inherit;
    background: #fff;
    text-decoration: none;
}
.global-search-result:hover,
.global-search-result.is-active,
.global-search-action:hover {
    border-color: #cfe0ff;
    color: inherit;
    background: #f2f7ff;
}
.global-search-result-icon,
.global-search-action > span:first-child {
    display: inline-flex;
    width: 2.15rem;
    height: 2.15rem;
    align-items: center;
    justify-content: center;
    border: 1px solid #e2e8f0;
    border-radius: .7rem;
    color: #0d6efd;
    background: #fff;
    font-size: 1rem;
    font-weight: 800;
}
.global-search-result-main,
.global-search-action > span:nth-child(2) { min-width: 0; }
.global-search-result-top { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; }
.global-search-result-top strong,
.global-search-action strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .84rem; }
.global-search-result-description,
.global-search-result-meta,
.global-search-action small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.global-search-result-description { margin-top: .14rem; color: #526079; font-size: .7rem; }
.global-search-result-meta,
.global-search-action small { margin-top: .12rem; color: #7b8798; font-size: .64rem; }
.global-search-result-arrow { color: #98a2b3; font-size: 1.05rem; }
.global-search-all-results {
    display: block;
    margin-top: .35rem;
    padding: .65rem .8rem;
    border-radius: .75rem;
    color: #0d6efd;
    background: #f6f9ff;
    text-align: center;
    text-decoration: none;
    font-size: .75rem;
    font-weight: 700;
}
.global-search-all-results:hover,
.global-search-all-results.is-active { background: #eaf2ff; }
.global-search-empty {
    display: grid;
    justify-items: center;
    gap: .25rem;
    padding: 2.2rem 1rem;
    color: #667085;
    text-align: center;
}
.global-search-empty strong { color: #344054; }
.global-search-empty span { font-size: .75rem; }
.global-search-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .85rem;
    padding: .65rem 1rem;
    border-top: 1px solid #e8edf4;
    color: #7b8798;
    background: #f8fafc;
    font-size: .62rem;
}
.global-search-footer span { display: inline-flex; align-items: center; gap: .2rem; }
.global-search-footer kbd {
    padding: .1rem .28rem;
    border: 1px solid #d9e0e9;
    border-radius: .3rem;
    color: #526079;
    background: #fff;
    font-size: .56rem;
}
.global-search-footer a { margin-left: auto; color: #0d6efd; font-weight: 700; text-decoration: none; }

.search-page-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding: 1.5rem 1.7rem;
    border: 1px solid #dbe7ff;
    border-radius: 1.25rem;
    background: linear-gradient(135deg, #fff 0%, #edf5ff 100%);
    box-shadow: 0 14px 35px rgba(31,80,150,.07);
}
.search-page-eyebrow {
    margin-bottom: .35rem;
    color: #0d6efd;
    font-size: .7rem;
    font-weight: 800;
    letter-spacing: .09em;
    text-transform: uppercase;
}
.search-page-shortcut { display: flex; align-items: center; gap: .3rem; color: #667085; font-size: .72rem; white-space: nowrap; }
.search-page-shortcut kbd { padding: .35rem .5rem; border: 1px solid #ced8e6; border-bottom-width: 2px; border-radius: .45rem; color: #344054; background: #fff; font-size: .68rem; }
.search-page-form { border-radius: 1rem; }
.search-quick-actions-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: .8rem; }
.search-quick-action-card {
    display: grid;
    grid-template-columns: auto minmax(0,1fr) auto;
    align-items: center;
    gap: .75rem;
    min-height: 5.2rem;
    padding: .9rem 1rem;
    border: 1px solid #e1e7ef;
    border-radius: 1rem;
    color: inherit;
    background: #fff;
    box-shadow: 0 7px 20px rgba(31,42,68,.04);
    text-decoration: none;
    transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.search-quick-action-card:hover { transform: translateY(-2px); border-color: #b9d1ff; color: inherit; box-shadow: 0 12px 28px rgba(31,80,150,.1); }
.search-quick-action-icon {
    display: inline-flex;
    width: 2.55rem;
    height: 2.55rem;
    align-items: center;
    justify-content: center;
    border-radius: .8rem;
    color: #0d6efd;
    background: #edf5ff;
    font-size: 1.1rem;
    font-weight: 800;
}
.search-quick-action-card strong,
.search-quick-action-card small { display: block; }
.search-quick-action-card strong { font-size: .82rem; }
.search-quick-action-card small { margin-top: .15rem; color: #667085; font-size: .67rem; line-height: 1.35; }
.search-quick-action-card > i { color: #98a2b3; font-style: normal; }
.search-empty-icon { margin: 0 auto .75rem; color: #9ebbe8; font-size: 2.5rem; line-height: 1; }
.search-result-group { overflow: hidden; border-radius: 1rem; }
.search-result-row {
    display: grid;
    grid-template-columns: auto minmax(0,1fr) auto auto;
    align-items: center;
    gap: .8rem;
    margin: .15rem 0;
    padding: .8rem .85rem;
}
.search-result-icon {
    display: inline-flex;
    width: 2.35rem;
    height: 2.35rem;
    align-items: center;
    justify-content: center;
    border-radius: .75rem;
    color: #0d6efd;
    background: #edf5ff;
    font-weight: 800;
}
.search-result-main { min-width: 0; }
.search-result-description,
.search-result-meta { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.search-result-description { margin-top: .2rem; color: #526079; font-size: .72rem; }
.search-result-meta { margin-top: .18rem; color: #7b8798; font-size: .66rem; }
.search-result-date { color: #667085; font-size: .7rem; white-space: nowrap; }
.search-result-arrow { color: #98a2b3; }

@media (max-width: 1199.98px) {
    .panel-search-button { width: 100%; justify-content: flex-start; min-height: 2.75rem; }
    .panel-search-button kbd { margin-left: auto; }
    .search-quick-actions-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 767.98px) {
    .global-search-overlay { padding: 0; align-items: stretch; }
    .global-search-dialog { width: 100%; max-height: 100vh; min-height: 100vh; border: 0; border-radius: 0; }
    .global-search-header { padding: .72rem; }
    .global-search-body { flex: 1; }
    .global-search-footer { display: none; }
    .search-page-hero { align-items: flex-start; flex-direction: column; padding: 1.2rem; }
    .search-page-shortcut { display: none; }
    .search-quick-actions-grid { grid-template-columns: 1fr; }
    .search-result-row { grid-template-columns: auto minmax(0,1fr) auto; }
    .search-result-date { grid-column: 2; }
    .search-result-arrow { grid-column: 3; grid-row: 1 / span 2; }
}
@media (max-width: 420px) {
    .panel-mobile-search { width: 2.1rem; height: 2.1rem; }
    .global-search-result { padding: .65rem; gap: .6rem; }
    .global-search-result-description { display: none; }
}

/* Termino 1.6.5 — zapisane widoki, filtry i plan dnia */
.terms-page-hero,
.work-center-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding: 1.5rem 1.65rem;
    border: 1px solid #dce7f8;
    border-radius: 1.2rem;
    background: linear-gradient(135deg, #fff 0%, #f1f6ff 100%);
    box-shadow: 0 14px 34px rgba(31,80,150,.07);
}
.term-view-strip {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: .7rem;
}
.term-view-chip {
    display: grid;
    grid-template-columns: auto minmax(0,1fr);
    align-items: center;
    gap: .65rem;
    min-height: 4.35rem;
    padding: .72rem .8rem;
    border: 1px solid #e0e7f0;
    border-radius: .85rem;
    color: inherit;
    background: #fff;
    text-decoration: none;
    transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.term-view-chip:hover,
.term-view-chip.is-active {
    transform: translateY(-2px);
    border-color: #a9c7ff;
    color: inherit;
    background: #f5f9ff;
    box-shadow: 0 9px 22px rgba(31,80,150,.09);
}
.term-view-chip > b {
    display: inline-flex;
    width: 2.25rem;
    height: 2.25rem;
    align-items: center;
    justify-content: center;
    border-radius: .7rem;
    color: #0d6efd;
    background: #eaf2ff;
    font-size: .95rem;
}
.term-view-chip.is-saved > b { color: #8a5b00; background: #fff4d4; }
.term-view-chip strong,
.term-view-chip small { display: block; }
.term-view-chip strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .8rem; }
.term-view-chip small { margin-top: .12rem; color: #718096; font-size: .64rem; line-height: 1.25; }
.term-filter-card { border-radius: 1rem; }
.term-advanced-table th { color: #667085; font-size: .68rem; text-transform: uppercase; letter-spacing: .035em; white-space: nowrap; }
.term-advanced-table td { padding-top: .85rem; padding-bottom: .85rem; }
.term-row-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: .35rem; }
.term-row-actions form { margin: 0; }
.term-filtered-mobile-card { border-left: 4px solid #0d6efd !important; }
.term-mobile-meta { display: grid; gap: .25rem; color: #667085; font-size: .74rem; }

.work-center-kpis {
    display: grid;
    grid-template-columns: repeat(4, minmax(0,1fr));
    gap: .85rem;
}
.work-center-kpi {
    display: grid;
    gap: .12rem;
    padding: 1rem 1.05rem;
    border: 1px solid #e1e8f0;
    border-radius: 1rem;
    color: inherit;
    background: #fff;
    box-shadow: 0 8px 22px rgba(31,42,68,.05);
    text-decoration: none;
}
.work-center-kpi:hover { color: inherit; border-color: #b9d1ff; transform: translateY(-1px); }
.work-center-kpi span { color: #667085; font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.work-center-kpi strong { font-size: 1.8rem; line-height: 1.05; }
.work-center-kpi small { color: #7b8798; font-size: .66rem; }
.work-center-kpi.is-danger { border-top: 4px solid #dc3545; }
.work-center-kpi.is-warning { border-top: 4px solid #ffc107; }
.work-center-kpi.is-primary { border-top: 4px solid #0d6efd; }
.work-center-section { overflow: hidden; border-top: 4px solid #d8e1ec !important; }
.work-center-danger { border-top-color: #dc3545 !important; }
.work-center-warning { border-top-color: #ffc107 !important; }
.work-center-primary { border-top-color: #0d6efd !important; }
.work-center-term {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .9rem;
    padding: .78rem .82rem;
    border: 1px solid #e7ecf2;
    border-radius: .8rem;
    background: #fff;
}
.work-center-term-main { min-width: 0; }
.work-center-term-main > a { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #172033; font-size: .86rem; font-weight: 700; text-decoration: none; }
.work-center-term-main > a:hover { color: #0d6efd; }
.work-center-term-main > small { display: block; overflow: hidden; margin-top: .15rem; color: #667085; font-size: .67rem; text-overflow: ellipsis; white-space: nowrap; }
.work-center-term-actions { display: flex; flex: 0 0 auto; gap: .35rem; }
.work-center-empty { display: grid; justify-items: center; gap: .25rem; padding: 1.8rem 1rem; color: #667085; text-align: center; }
.work-center-empty > span { display: inline-flex; width: 2.8rem; height: 2.8rem; align-items: center; justify-content: center; border-radius: 50%; color: #198754; background: #e8f7ef; font-size: 1.25rem; font-weight: 800; }
.work-center-empty strong { color: #344054; }
.work-center-empty small { font-size: .72rem; }

@media (max-width: 1199.98px) {
    .work-center-kpis { grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 767.98px) {
    .terms-page-hero,
    .work-center-hero { align-items: flex-start; flex-direction: column; padding: 1.15rem; }
    .term-view-strip { grid-template-columns: 1fr; }
    .work-center-term { align-items: flex-start; flex-direction: column; }
    .work-center-term-actions { width: 100%; }
    .work-center-term-actions > * { flex: 1 1 auto; }
    .work-center-term-actions .btn { width: 100%; }
}
@media (max-width: 479.98px) {
    .work-center-kpis { grid-template-columns: 1fr 1fr; gap: .55rem; }
    .work-center-kpi { padding: .8rem; }
    .work-center-kpi strong { font-size: 1.4rem; }
}

/* Termino 1.6.6 — automatyzacje i reguły */
.automation-stat-grid .card { border-radius: 1rem; }
.automation-empty { min-height: 17rem; }
.automation-empty p { max-width: 34rem; }
.automation-empty-icon {
    display: inline-flex;
    width: 4rem;
    height: 4rem;
    align-items: center;
    justify-content: center;
    border-radius: 1.15rem;
    color: #9a6700;
    background: linear-gradient(135deg, #fff6d9, #ffe29a);
    font-size: 1.9rem;
    box-shadow: 0 12px 30px rgba(154,103,0,.12);
}
.automation-rule-card {
    background: #fff;
    transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.automation-rule-card:hover {
    transform: translateY(-1px);
    border-color: #bfd4f8 !important;
    box-shadow: 0 12px 28px rgba(31,80,150,.07);
}
.automation-flow {
    display: flex;
    align-items: stretch;
    gap: .7rem;
}
.automation-flow > span {
    display: grid;
    min-width: 0;
    padding: .65rem .8rem;
    border: 1px solid #e1e8f2;
    border-radius: .8rem;
    color: #25304a;
    background: #f8faff;
    font-size: .82rem;
    font-weight: 700;
}
.automation-flow > span small {
    margin-bottom: .15rem;
    color: #667085;
    font-size: .58rem;
    font-weight: 800;
    letter-spacing: .07em;
}
.automation-flow > b { align-self: center; color: #0d6efd; font-size: 1.2rem; }
.automation-run-item { padding-bottom: .85rem; border-bottom: 1px solid #edf0f4; }
.automation-run-item:last-child { padding-bottom: 0; border-bottom: 0; }
.automation-step-label {
    display: flex;
    align-items: center;
    gap: .7rem;
    margin-bottom: 1.35rem;
    color: #26334d;
    font-size: .82rem;
    font-weight: 800;
    letter-spacing: .02em;
    text-transform: uppercase;
}
.automation-step-label > span {
    display: inline-flex;
    width: 2rem;
    height: 2rem;
    align-items: center;
    justify-content: center;
    border-radius: .65rem;
    color: #fff;
    background: #0d6efd;
}
.automation-step-label small { color: #8993a4; font-size: .62rem; text-transform: none; }
.automation-action-panel {
    padding: 1.1rem;
    border: 1px solid #dfe7f2;
    border-radius: 1rem;
    background: linear-gradient(180deg, #fbfdff 0%, #f6f9ff 100%);
}
.automation-action-panel[hidden], [data-trigger-days][hidden] { display: none !important; }
.automation-reminder-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: .6rem;
}
.automation-check {
    display: flex;
    align-items: center;
    gap: .55rem;
    padding: .7rem .75rem;
    border: 1px solid #dfe7f2;
    border-radius: .75rem;
    background: #fff;
    cursor: pointer;
}
.automation-check:hover { border-color: #a9c7ff; }
.automation-check input { width: 1rem; height: 1rem; }
.automation-check span { font-size: .76rem; font-weight: 650; }
.automation-save-card { position: sticky; top: 6.3rem; border-radius: 1rem; }

@media (max-width: 767.98px) {
    .automation-flow { flex-direction: column; }
    .automation-flow > b { align-self: flex-start; transform: rotate(90deg); margin-left: 1rem; }
    .automation-reminder-grid { grid-template-columns: 1fr 1fr; }
    .automation-save-card { position: static; }
}
@media (max-width: 420px) {
    .automation-reminder-grid { grid-template-columns: 1fr; }
}

/* Termino 1.6.7 — checklisty i procedury */
.checklist-card { overflow: visible; }
.checklist-progress-summary { display:flex; align-items:baseline; gap:.45rem; white-space:nowrap; }
.checklist-progress-summary strong { font-size:1.35rem; color:#172033; }
.checklist-progress-summary span { color:#667085; font-size:.85rem; font-weight:700; }
.checklist-progress { height:.55rem; background:#e9eef5; border-radius:999px; }
.checklist-progress .progress-bar { border-radius:999px; background:linear-gradient(90deg,#0d6efd,#20c997); }
.checklist-empty { display:flex; align-items:center; gap:.9rem; border:1px dashed #cbd5e1; background:#f8fafc; padding:1rem; border-radius:1rem; }
.checklist-empty > span { width:2.25rem; height:2.25rem; border-radius:50%; display:grid; place-items:center; background:#e8f5ee; color:#198754; font-weight:900; }
.checklist-empty strong,.checklist-empty small { display:block; }
.checklist-empty small { color:#667085; }
.checklist-list { display:grid; gap:.65rem; }
.checklist-item { position:relative; display:grid; grid-template-columns:auto minmax(0,1fr) auto; align-items:center; gap:.75rem; padding:.8rem .9rem; border:1px solid #e2e8f0; border-radius:.9rem; background:#fff; transition:border-color .18s ease,box-shadow .18s ease,background .18s ease; }
.checklist-item:hover { border-color:#b9c9df; box-shadow:0 .3rem 1rem rgba(23,32,51,.06); }
.checklist-item.is-completed { background:#f6fbf8; border-color:#cce9d8; }
.checklist-item.is-completed .checklist-item-copy strong { color:#667085; text-decoration:line-through; }
.checklist-toggle-form { margin:0; }
.checklist-check { width:2rem; height:2rem; padding:0; border-radius:.65rem; border:2px solid #9aa9bc; background:#fff; color:#fff; font-weight:900; display:grid; place-items:center; }
.checklist-item.is-completed .checklist-check { border-color:#198754; background:#198754; }
.checklist-check:disabled { opacity:.45; cursor:not-allowed; }
.checklist-item-copy { min-width:0; }
.checklist-item-copy strong { overflow-wrap:anywhere; }
.checklist-item-actions { display:flex; align-items:center; gap:.35rem; }
.checklist-item-actions form { margin:0; }
.checklist-edit-details { position:relative; }
.checklist-edit-details > summary { list-style:none; cursor:pointer; }
.checklist-edit-details > summary::-webkit-details-marker { display:none; }
.checklist-edit-popover { position:absolute; z-index:20; right:0; top:calc(100% + .45rem); width:min(20rem,80vw); padding:.85rem; background:#fff; border:1px solid #dbe3ee; border-radius:.85rem; }
.checklist-add-form { border-top:1px solid #edf1f6; padding-top:1rem; }
.checklist-assignee-select { max-width:15rem; }
@media (max-width: 767.98px) {
  .checklist-item { grid-template-columns:auto minmax(0,1fr); align-items:start; }
  .checklist-item-actions { grid-column:1 / -1; justify-content:flex-end; border-top:1px solid #edf1f6; padding-top:.55rem; }
  .checklist-edit-popover { position:fixed; left:1rem; right:1rem; top:auto; bottom:1rem; width:auto; max-height:70vh; overflow:auto; }
}


/* Termino 1.7.0 — uproszczone centrum działań i nawigacja mobilna */
.attention-signal-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .8rem; }
.attention-signal { display: grid; grid-template-columns: 2.4rem minmax(0,1fr) auto; align-items: center; gap: .7rem; min-height: 5.4rem; padding: .9rem 1rem; border: 1px solid #e4e7ec; border-radius: 1rem; color: #172033; background: #fff; text-decoration: none; box-shadow: 0 .35rem 1rem rgba(16,24,40,.045); transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease; }
.attention-signal:hover { transform: translateY(-2px); border-color: #b8c7e6; color: #172033; box-shadow: 0 .65rem 1.5rem rgba(16,24,40,.08); }
.attention-signal-icon { display: inline-flex; width: 2.4rem; height: 2.4rem; align-items: center; justify-content: center; border-radius: .75rem; color: #175cd3; background: #eff4ff; font-weight: 800; }
.attention-signal-copy { min-width: 0; }
.attention-signal-copy strong, .attention-signal-copy small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.attention-signal-copy strong { font-size: .88rem; }
.attention-signal-copy small { margin-top: .15rem; color: #667085; font-size: .7rem; }
.attention-signal > b { min-width: 2rem; font-size: 1.35rem; text-align: right; }
.attention-signal-danger .attention-signal-icon { color: #b42318; background: #fef3f2; }
.attention-signal-warning .attention-signal-icon { color: #b54708; background: #fffaeb; }

.dashboard-onboarding { padding: 1.2rem; border: 1px solid #d6e4ff; border-radius: 1.15rem; background: linear-gradient(135deg, #f8fbff, #fff); box-shadow: 0 .55rem 1.5rem rgba(13,110,253,.065); }
.dashboard-onboarding-head { display: flex; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }
.dashboard-onboarding-steps { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: .8rem; }
.dashboard-onboarding-steps > a { display: flex; align-items: center; gap: .75rem; padding: .9rem; border: 1px solid #e4e7ec; border-radius: .95rem; color: #172033; background: #fff; text-decoration: none; }
.dashboard-onboarding-steps > a:hover { border-color: #84adff; color: #0d6efd; }
.dashboard-onboarding-steps b { display: inline-flex; width: 2rem; height: 2rem; flex: 0 0 auto; align-items: center; justify-content: center; border-radius: 50%; color: #fff; background: #0d6efd; }
.dashboard-onboarding-steps strong, .dashboard-onboarding-steps small { display: block; }
.dashboard-onboarding-steps small { margin-top: .15rem; color: #667085; font-size: .72rem; }
.dashboard-attention-rail { display: flex; gap: .65rem; overflow-x: auto; padding: .15rem .05rem .45rem; scrollbar-width: thin; }
.dashboard-attention-rail > a { display: grid; grid-template-columns: auto auto; grid-template-areas: "label count" "small count"; min-width: 12rem; padding: .75rem .9rem; border: 1px solid #e4e7ec; border-radius: .9rem; color: #172033; background: #fff; text-decoration: none; }
.dashboard-attention-rail span { grid-area: label; font-size: .74rem; font-weight: 700; }
.dashboard-attention-rail strong { grid-area: count; align-self: center; margin-left: .8rem; color: #175cd3; font-size: 1.4rem; }
.dashboard-attention-rail small { grid-area: small; color: #667085; font-size: .65rem; }
.dashboard-attention-rail > a.is-danger strong { color: #d92d20; }

.panel-bottom-nav { position: fixed; z-index: 1040; right: .65rem; bottom: .55rem; left: .65rem; display: grid; grid-template-columns: 1fr 1fr 1.12fr 1fr 1fr; align-items: end; min-height: 4rem; padding: .35rem .4rem calc(.35rem + env(safe-area-inset-bottom)); border: 1px solid rgba(208,213,221,.9); border-radius: 1.15rem; background: rgba(255,255,255,.96); box-shadow: 0 .85rem 2rem rgba(16,24,40,.18); backdrop-filter: blur(14px); }
.panel-bottom-link, .panel-bottom-add { display: flex; min-width: 0; min-height: 3.2rem; align-items: center; justify-content: center; flex-direction: column; gap: .12rem; border: 0; border-radius: .8rem; color: #667085; background: transparent; font: inherit; text-decoration: none; }
.panel-bottom-link > span { font-size: 1.08rem; line-height: 1; font-weight: 800; }
.panel-bottom-link small, .panel-bottom-add small { overflow: hidden; max-width: 100%; font-size: .61rem; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.panel-bottom-link.active { color: #0d6efd; background: #eff4ff; }
.panel-bottom-add { position: relative; min-height: 3.75rem; margin-top: -.85rem; color: #fff; background: #0d6efd; box-shadow: 0 .55rem 1.25rem rgba(13,110,253,.34); }
.panel-bottom-add > span { font-size: 1.75rem; line-height: .9; }
.panel-bottom-add:hover { color: #fff; background: #0b5ed7; }

@media (max-width: 1199.98px) {
    .panel-page { padding-bottom: 5.6rem; }
    .panel-navbar { position: sticky; }
    .panel-navbar .navbar-collapse { max-height: calc(100vh - 9rem); overflow-y: auto; }
}
@media (max-width: 991.98px) {
    .attention-signal-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
    .dashboard-onboarding-steps { grid-template-columns: 1fr; }
}
@media (max-width: 575.98px) {
    .attention-signal-grid { grid-template-columns: 1fr; }
    .attention-signal { min-height: 4.8rem; }
    .panel-bottom-nav { right: .35rem; bottom: .35rem; left: .35rem; }
    .dashboard-onboarding { padding: 1rem; }
    .work-center-hero .lead, .dashboard-hero .lead { font-size: .95rem; }
}

/* Termino 1.7.1 — inteligentna wyszukiwarka i karta priorytetu */
.global-search-context {
    display: grid;
    gap: .35rem;
    margin-bottom: .65rem;
    padding-bottom: .65rem;
    border-bottom: 1px solid #e7ecf2;
}
.global-search-context[hidden] { display: none !important; }
.global-search-context-label {
    padding: .1rem .3rem .25rem;
    color: #667085;
    font-size: .66rem;
    font-weight: 800;
    letter-spacing: .05em;
    text-transform: uppercase;
}
.global-search-command {
    display: grid;
    grid-template-columns: 2.15rem minmax(0,1fr) auto;
    gap: .65rem;
    align-items: center;
    padding: .62rem .7rem;
    border: 1px solid #dce7f7;
    border-radius: .75rem;
    color: #172033;
    background: #f7faff;
    text-decoration: none;
}
.global-search-command:hover,
.global-search-command.is-active { color: #0d6efd; border-color: #b9d1ff; background: #eaf2ff; }
.global-search-command-icon {
    display: inline-flex;
    width: 2.15rem;
    height: 2.15rem;
    align-items: center;
    justify-content: center;
    border-radius: .65rem;
    color: #0d6efd;
    background: #fff;
    box-shadow: inset 0 0 0 1px #dce7f7;
    font-weight: 800;
}
.global-search-command strong,
.global-search-command small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.global-search-command strong { font-size: .82rem; }
.global-search-command small { margin-top: .08rem; color: #667085; font-size: .68rem; }
.global-search-command i { color: #98a2b3; font-style: normal; }
.search-scope-chips { display: flex; flex-wrap: wrap; gap: .42rem; }
.search-scope-chip {
    display: inline-flex;
    align-items: center;
    min-height: 2rem;
    padding: .35rem .68rem;
    border: 1px solid #d8e1ec;
    border-radius: 999px;
    color: #526079;
    background: #fff;
    font-size: .72rem;
    font-weight: 700;
    text-decoration: none;
}
.search-scope-chip:hover,
.search-scope-chip.active { color: #0d6efd; border-color: #9fc0ff; background: #edf4ff; }
.search-command-card { overflow: hidden; border-top: 4px solid #0d6efd !important; }
.search-command-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: .65rem; }
.search-command-action {
    display: grid;
    grid-template-columns: 2.35rem minmax(0,1fr) auto;
    gap: .7rem;
    align-items: center;
    padding: .72rem;
    border: 1px solid #e1e7ef;
    border-radius: .85rem;
    color: #172033;
    background: #fff;
    text-decoration: none;
}
.search-command-action:hover { color: #0d6efd; border-color: #b9d1ff; background: #f7faff; }
.search-command-action > span:first-child { display: inline-flex; width: 2.35rem; height: 2.35rem; align-items: center; justify-content: center; border-radius: .7rem; color: #0d6efd; background: #edf4ff; font-weight: 800; }
.search-command-action strong,
.search-command-action small { display: block; }
.search-command-action small { margin-top: .12rem; color: #667085; font-size: .7rem; }
.search-command-action i { color: #98a2b3; font-style: normal; }
.work-focus-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.25rem;
    padding: 1.2rem 1.3rem;
    border: 1px solid #d8e1ec;
    border-left: 5px solid #0d6efd;
    border-radius: 1rem;
    background: #fff;
    box-shadow: 0 .55rem 1.35rem rgba(16,24,40,.06);
}
.work-focus-danger { border-left-color: #dc3545; background: linear-gradient(110deg,rgba(220,53,69,.055),#fff 45%); }
.work-focus-warning { border-left-color: #ffc107; background: linear-gradient(110deg,rgba(255,193,7,.075),#fff 45%); }
.work-focus-primary { border-left-color: #0d6efd; background: linear-gradient(110deg,rgba(13,110,253,.055),#fff 45%); }
.work-focus-success { border-left-color: #198754; background: linear-gradient(110deg,rgba(25,135,84,.055),#fff 45%); }
.work-focus-copy { min-width: 0; }
.work-focus-eyebrow { display: block; margin-bottom: .45rem; color: #667085; font-size: .68rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.work-focus-card h2 a { color: #172033; text-decoration: none; }
.work-focus-card h2 a:hover { color: #0d6efd; }
.work-focus-actions { display: flex; flex: 0 0 auto; gap: .55rem; }
.work-focus-actions form { margin: 0; }
@media (max-width: 767.98px) {
    .search-command-grid { grid-template-columns: 1fr; }
    .work-focus-card { align-items: stretch; flex-direction: column; }
    .work-focus-actions { width: 100%; }
    .work-focus-actions > *, .work-focus-actions .btn { flex: 1 1 auto; width: 100%; }
}


/* 1.7.2 — szybkie dodawanie terminów */
.quick-capture-card {
  overflow: hidden;
  background:
    radial-gradient(circle at 100% 0, rgba(13, 110, 253, .16), transparent 42%),
    linear-gradient(145deg, #ffffff, #f6f9ff);
}

.quick-capture-form textarea {
  min-height: 94px;
  resize: vertical;
}

.quick-capture-examples,
.work-quick-examples {
  display: flex;
  flex-wrap: wrap;
  gap: .45rem;
}

.quick-example,
.work-quick-examples button {
  appearance: none;
  border: 1px solid rgba(13, 110, 253, .2);
  background: rgba(255, 255, 255, .82);
  color: #31527b;
  border-radius: 999px;
  padding: .35rem .65rem;
  font-size: .76rem;
  line-height: 1.3;
  text-align: left;
  transition: border-color .15s ease, background-color .15s ease, transform .15s ease;
}

.quick-example:hover,
.work-quick-examples button:hover {
  border-color: rgba(13, 110, 253, .55);
  background: #fff;
  transform: translateY(-1px);
}

.template-search-wrap {
  position: sticky;
  top: .5rem;
  z-index: 3;
  padding: .25rem 0 .5rem;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(8px);
}

.template-search-wrap small {
  display: block;
  min-height: 1.2rem;
  margin-top: .25rem;
}

.termino-template-btn[hidden],
[data-template-group][hidden] {
  display: none !important;
}

.template-search-empty {
  padding: 1rem;
  margin-top: .75rem;
  border: 1px dashed #cbd5e1;
  border-radius: .85rem;
  color: #64748b;
  font-size: .9rem;
  text-align: center;
}

.quick-parse-result {
  padding: 1rem 1.1rem;
  border: 1px solid rgba(13, 110, 253, .2);
  border-radius: 1rem;
  background: linear-gradient(135deg, rgba(13, 110, 253, .065), rgba(25, 135, 84, .045));
}

.quick-parse-result strong {
  display: block;
  color: #1e293b;
  overflow-wrap: anywhere;
}

.quick-parse-label {
  display: block;
  margin-bottom: .2rem;
  color: #5b6b82;
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.quick-parse-chips {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
}

.quick-parse-chip {
  display: inline-flex;
  flex-direction: column;
  min-width: 130px;
  padding: .5rem .7rem;
  border: 1px solid rgba(15, 23, 42, .08);
  border-radius: .75rem;
  background: rgba(255, 255, 255, .88);
  color: #1e293b;
  font-size: .83rem;
  font-weight: 700;
}

.quick-parse-chip small {
  color: #64748b;
  font-size: .66rem;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.work-quick-capture {
  display: grid;
  grid-template-columns: minmax(230px, .8fr) minmax(320px, 1.4fr);
  gap: 1rem 1.25rem;
  align-items: center;
  padding: 1.15rem;
  border: 1px solid rgba(13, 110, 253, .16);
  border-radius: 1rem;
  background:
    radial-gradient(circle at 0 100%, rgba(13, 110, 253, .09), transparent 38%),
    #fff;
  box-shadow: 0 .35rem 1.2rem rgba(15, 23, 42, .055);
}

.work-quick-capture-copy {
  display: flex;
  align-items: center;
  gap: .85rem;
}

.work-quick-capture-copy > span {
  display: grid;
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  place-items: center;
  border-radius: .8rem;
  background: #0d6efd;
  color: #fff;
  font-size: 1.5rem;
  line-height: 1;
}

.work-quick-capture-form {
  display: flex;
  gap: .6rem;
}

.work-quick-capture-form .form-control {
  min-width: 0;
}

.work-quick-examples {
  grid-column: 1 / -1;
  padding-left: calc(44px + .85rem);
}

@media (max-width: 991.98px) {
  .work-quick-capture {
    grid-template-columns: 1fr;
  }

  .work-quick-examples {
    grid-column: auto;
    padding-left: 0;
  }
}

@media (max-width: 575.98px) {
  .work-quick-capture-form {
    flex-direction: column;
  }

  .quick-parse-chip {
    min-width: calc(50% - .25rem);
    flex: 1 1 calc(50% - .25rem);
  }
}
