body {
    /*font-family: 'Montserrat', sans-serif;*/
    background-color: #f0f2f5;
}

.user-menu {
    border: 1px solid rgba(0, 0, 0, 0.07);
    border-radius: 10px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.10);
    padding: 0.35rem;
    margin-top: 0.3rem;
}

.user-menu .dropdown-item {
    border-radius: 6px;
    font-size: 0.855rem;
    color: #374151;
    padding: 0.45rem 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.55rem;
    transition: background 0.12s ease;
}

.user-menu .dropdown-item:hover {
    background: #f3f4f6;
    color: #111827;
}

.floating-platform {
    position: fixed;
    bottom: 16px;
    right: 16px;
    z-index: 1050;
    display: flex;
    align-items: center;
    gap: 8px;
}

.floating-platform-trigger {
    background: rgba(255, 255, 255, 0.92);
    color: #6b7280;
    border: 1px solid #e9eaec;
    width: 34px;
    height: 34px;
    border-radius: 999px;
    font-size: 1rem;
    box-shadow: 0 1px 8px rgba(0, 0, 0, 0.07);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    user-select: none;
    transition: background 0.15s ease, color 0.15s ease;
}

.floating-platform-trigger:hover {
    background: #f3f4f6;
    color: #374151;
}


/* ─── Navbar ─── */
.navbar-geraton {
    background: #ffffff;
    margin: 10px 16px 0;
    border-radius: 12px;
    border: 1px solid #e9eaec;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 4px 16px rgba(0, 0, 0, 0.06);
    padding: 0.35rem 0.75rem;
}

.navbar-geraton .nav-link {
    color: #6b7280;
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: 0.01em;
    padding: 0.32rem 0.85rem;
    border-radius: 999px;
    border: 1px solid transparent;
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.navbar-geraton .nav-link:hover,
.navbar-geraton .nav-link:focus {
    color: #374151;
    background: #f3f4f6;
    border-color: #e9eaec;
}

.navbar-geraton .nav-link.show {
    color: #374151;
    background: #f3f4f6;
    border-color: #e9eaec;
}

.navbar-geraton .dropdown-menu {
    border: 1px solid rgba(0, 0, 0, 0.07);
    border-radius: 10px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.10);
    padding: 0.35rem;
    margin-top: 0.3rem;
    min-width: 170px;
}

.navbar-geraton .dropdown-item {
    border-radius: 6px;
    font-size: 0.855rem;
    color: #374151;
    padding: 0.45rem 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.55rem;
    transition: background 0.12s ease;
}

.navbar-geraton .dropdown-item:hover,
.navbar-geraton .dropdown-item:focus {
    background: #f3f4f6;
    color: #111827;
}

.nav-logo {
    margin-right: 2rem;
    margin-left: 0.75rem;
}

.navbar-geraton .nav-action {
    background: transparent;
    border: 1px solid #e9eaec;
    border-radius: 999px;
    color: #6b7280;
    font-size: 0.8rem;
    font-weight: 500;
    padding: 0.32rem 0.85rem;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
    white-space: nowrap;
    line-height: 1.4;
}

.navbar-geraton .nav-action:hover {
    background: #f3f4f6;
    color: #374151;
    border-color: #d1d5db;
}


.card-metric {
    border-radius: 12px;
    background-color: #ffffff;
    border: 1px solid #e9eaec;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 4px 16px rgba(0, 0, 0, 0.06);
    padding: 1.5rem;
}

.metric-label {
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: #6b7280;
}

.metric-icon-wrap {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: #f3f4f6;
    border: 1px solid #e9eaec;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6b7280;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.metric-value {
    font-size: 2.25rem;
    font-weight: 700;
    color: #111827;
    letter-spacing: -0.02em;
    line-height: 1.1;
}

.metric-change {
    display: inline-flex;
    align-items: center;
    font-size: 0.76rem;
    font-weight: 500;
    border-radius: 999px;
    padding: 0.2rem 0.65rem;
}

.positive {
    color: #157347;
    background: rgba(25, 135, 84, 0.08);
    border: 1px solid rgba(25, 135, 84, 0.2);
}

.negative {
    color: #dc3545;
    background: rgba(220, 53, 69, 0.07);
    border: 1px solid rgba(220, 53, 69, 0.2);
}

/* ─── Buttons ─── */
.btn {
    --bs-btn-border-radius: 999px;
    font-weight: 500;
    font-size: 0.855rem;
    letter-spacing: 0.01em;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

/* Primary → soft blue tint */
.btn-outline-primary {
    background: rgba(13, 110, 253, 0.08);
    color: #0d6efd;
    border-color: rgba(13, 110, 253, 0.25);
}
.btn-outline-primary:hover,
.btn-outline-primary:focus {
    background: rgba(13, 110, 253, 0.15);
    border-color: rgba(13, 110, 253, 0.45);
    color: #0b5ed7;
}
.btn-outline-primary:active,
.btn-outline-primary.active {
    background: rgba(13, 110, 253, 0.22) !important;
    border-color: #0d6efd !important;
    color: #0a58ca !important;
}

/* Success → soft green tint */
.btn-outline-success {
    background: rgba(25, 135, 84, 0.08);
    color: #198754;
    border-color: rgba(25, 135, 84, 0.25);
}
.btn-outline-success:hover,
.btn-outline-success:focus {
    background: rgba(25, 135, 84, 0.15);
    border-color: rgba(25, 135, 84, 0.45);
    color: #157347;
}
.btn-outline-success:active,
.btn-outline-success.active {
    background: rgba(25, 135, 84, 0.22) !important;
    border-color: #198754 !important;
    color: #146c43 !important;
}

/* Secondary → outline pill */
.btn-outline-secondary {
    --bs-btn-color: #6c757d;
    --bs-btn-border-color: rgba(108, 117, 125, 0.35);
}
.btn-outline-secondary:hover,
.btn-outline-secondary:focus {
    background-color: rgba(108, 117, 125, 0.08);
    border-color: rgba(108, 117, 125, 0.6);
    color: #495057;
}
.btn-outline-secondary:active,
.btn-outline-secondary.active {
    background-color: rgba(108, 117, 125, 0.18) !important;
    border-color: #6c757d !important;
    color: #343a40 !important;
}

/* Warning → outline pill (Edytuj) */
.btn-outline-warning {
    --bs-btn-color: #92400e;
    --bs-btn-border-color: rgba(146, 64, 14, 0.3);
}
.btn-outline-warning:hover,
.btn-outline-warning:focus {
    background-color: rgba(251, 191, 36, 0.1);
    border-color: rgba(146, 64, 14, 0.5);
    color: #92400e;
}
.btn-outline-warning:active,
.btn-outline-warning.active {
    background-color: rgba(251, 191, 36, 0.2) !important;
    border-color: #92400e !important;
    color: #92400e !important;
}

/* Danger → outline pill (Usuń) */
.btn-outline-danger {
    --bs-btn-color: #dc3545;
    --bs-btn-border-color: rgba(220, 53, 69, 0.3);
}
.btn-outline-danger:hover,
.btn-outline-danger:focus {
    background-color: rgba(220, 53, 69, 0.08);
    border-color: rgba(220, 53, 69, 0.55);
    color: #dc3545;
}
.btn-outline-danger:active,
.btn-outline-danger.active {
    background-color: rgba(220, 53, 69, 0.15) !important;
    border-color: #dc3545 !important;
    color: #dc3545 !important;
}

.btn-row {
    width: 30px;
    height: 30px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.bottom-tab {
    position: fixed;
    bottom: 16px;
    left: 16px;

    background: rgba(255, 255, 255, 0.92);
    color: #6b7280;
    border: 1px solid #e9eaec;
    padding: 0.4rem 1rem;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 500;
    letter-spacing: 0.02em;
    white-space: nowrap;
    box-shadow: 0 1px 8px rgba(0, 0, 0, 0.07);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    user-select: none;
}

/* ─── Modals ─── */
.modal-content {
    border-radius: 14px;
    border: 1px solid #e9eaec;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.12);
}

.modal-header {
    border-bottom: 1px solid #f0f1f3;
    padding: 1.1rem 1.5rem 0.9rem;
}

.modal-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: #374151;
}

.modal-body {
    padding: 1.1rem 1.5rem;
    font-size: 0.855rem;
    color: #374151;
}

.modal-footer {
    border-top: 1px solid #f0f1f3;
    padding: 0.75rem 1.5rem;
    gap: 0.5rem;
}

/* ─── Alerts ─── */
.alert {
    border-radius: 8px;
    font-size: 0.835rem;
}

.alert-warning {
    background: rgba(251, 191, 36, 0.08);
    border-color: rgba(251, 191, 36, 0.35);
    color: #92400e;
}

/* ─── Counter badge on table buttons ─── */
.table-counter-badge {
    background-color: #fff;
    border: 1px solid #e9eaec !important;
    color: #6b7280 !important;
}

/* ─── Updates page ─── */
.version-badge {
    display: inline-block;
    background: #f3f4f6;
    border: 1px solid #e9eaec;
    border-radius: 6px;
    padding: 0.15rem 0.55rem;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    color: #374151;
    font-family: ui-monospace, monospace;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    border-radius: 999px;
    padding: 0.2rem 0.7rem;
    font-size: 0.76rem;
    font-weight: 500;
}

.status-badge-done {
    background: rgba(25, 135, 84, 0.08);
    color: #157347;
    border: 1px solid rgba(25, 135, 84, 0.25);
}

.status-badge-pending {
    background: rgba(108, 117, 125, 0.08);
    color: #6c757d;
    border: 1px solid rgba(108, 117, 125, 0.25);
}

.change-row td {
    background: #fafafa !important;
    border-top: none !important;
    padding-top: 0.4rem !important;
    padding-bottom: 0.4rem !important;
}

.change-type-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    border-radius: 5px;
    padding: 0.1rem 0.5rem;
    font-size: 0.72rem;
    font-weight: 500;
}

.change-type-feature {
    background: rgba(25, 135, 84, 0.08);
    color: #157347;
    border: 1px solid rgba(25, 135, 84, 0.2);
}

.change-type-bug {
    background: rgba(220, 53, 69, 0.07);
    color: #dc3545;
    border: 1px solid rgba(220, 53, 69, 0.2);
}

.change-type-tech {
    background: rgba(251, 191, 36, 0.1);
    color: #92400e;
    border: 1px solid rgba(251, 191, 36, 0.3);
}

/* ─── Login tag ─── */
.login-tag {
    display: inline-block;
    font-size: 0.63rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.09em;
    color: #b0b7c3;
    background: #f7f8fa;
    border: 1px solid #e9eaec;
    border-radius: 999px;
    padding: 0.2rem 0.8rem;
}

/* ─── Form card ─── */
.form-card {
    border-radius: 12px;
    background-color: #ffffff;
    border: 1px solid #e9eaec;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 4px 16px rgba(0, 0, 0, 0.06);
    padding: 1.5rem 2rem;
    margin-bottom: 1.25rem;
}

.form-card fieldset {
    border: none;
    padding: 0;
    margin: 0;
}

.form-card legend {
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: #6b7280;
    margin-bottom: 1.25rem;
    padding: 0;
    float: none;
    width: auto;
}

/* ─── Settings layout ─── */
.settings-layout {
    display: flex;
    gap: 1.25rem;
    align-items: flex-start;
}

.settings-nav-col {
    flex: 0 0 20%;
    max-width: 20%;
    position: sticky;
    top: 1rem;
}

.settings-content-col {
    flex: 1 1 80%;
    min-width: 0;
}

.settings-nav .nav-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-align: left;
    color: #374151;
    border-radius: 8px;
    padding: 0.55rem 0.75rem;
    font-size: 0.9rem;
    margin-bottom: 0.15rem;
}

.settings-nav .nav-link:hover {
    background-color: #f3f4f6;
}

.settings-nav .nav-link.active {
    background-color: #eef0f3;
    color: #111827;
    font-weight: 600;
    box-shadow: inset 3px 0 0 #6b7280;
}

@media (max-width: 767.98px) {
    .settings-layout {
        flex-direction: column;
    }

    .settings-nav-col {
        flex: 1 1 100%;
        max-width: 100%;
        position: static;
    }

    .settings-nav {
        flex-direction: row !important;
        flex-wrap: wrap;
    }
}

/* ─── System docs (System > Dokumentacja) ─── */
.sys-docs-card {
    padding: 0 0 1.5rem;
    min-height: 60vh;
}

.sys-docs-tabs {
    padding: 0.75rem 1.25rem 0;
    border-bottom-color: #e9eaec;
}

.sys-docs-tabs .nav-link {
    color: #6b7280;
    font-size: 0.88rem;
}

.sys-docs-tabs .nav-link.active {
    color: #111827;
    font-weight: 600;
}

.sys-docs-content {
    padding: 1.5rem 2rem 0;
    color: #374151;
    line-height: 1.6;
}

.sys-docs-content h1 { font-size: 1.5rem; margin-bottom: 1rem; }
.sys-docs-content h2 { font-size: 1.2rem; margin-top: 1.75rem; }
.sys-docs-content h3 { font-size: 1.05rem; margin-top: 1.25rem; }

.sys-docs-content pre {
    background: #f6f7f9;
    border: 1px solid #e9eaec;
    border-radius: 8px;
    padding: 0.75rem 1rem;
}

.sys-docs-content :not(pre) > code {
    background: #f3f4f6;
    border-radius: 4px;
    padding: 0.1rem 0.3rem;
    color: #b4235a;
}

.sys-docs-content table {
    border-collapse: collapse;
    margin-bottom: 1rem;
}

.sys-docs-content th,
.sys-docs-content td {
    border: 1px solid #e9eaec;
    padding: 0.4rem 0.75rem;
}

.sys-docs-content th { background: #f6f7f9; }

.sys-docs-content blockquote {
    border-left: 3px solid #d1d5db;
    padding-left: 1rem;
    color: #6b7280;
}

.sys-docs-empty {
    text-align: center;
    color: #9ca3af;
    padding: 4rem 1rem;
}

.sys-docs-empty i { font-size: 2.5rem; }

/* ─── Docs editor layout ─── */
.docs-layout {
    display: flex;
    gap: 1.25rem;
    align-items: flex-start;
}

.docs-tree-col {
    flex: 0 0 30%;
    max-width: 30%;
    position: sticky;
    top: 1rem;
}

.docs-editor-col {
    flex: 1 1 70%;
    min-width: 0;
}

.docs-tree-card {
    max-height: calc(100vh - 8rem);
    overflow-y: auto;
}

.docs-tree-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: #6b7280;
    padding: 0.4rem 0.5rem 0.6rem;
}

.docs-tree-header-actions {
    display: flex;
    align-items: center;
    gap: 0.15rem;
}

.docs-tree-header-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    padding: 0;
    border: none;
    background: transparent;
    color: #9ca3af;
    font-size: 0.85rem;
    border-radius: 4px;
    cursor: pointer;
}

.docs-tree-header-btn:hover {
    background-color: #f3f4f6;
    color: #374151;
}

.docs-tree, .docs-tree-children {
    list-style: none;
    margin: 0;
    padding-left: 0;
}

.docs-tree-children {
    padding-left: 1.1rem;
}

.docs-tree-item {
    margin: 0.05rem 0;
}

.docs-tree-row {
    display: flex;
    align-items: center;
    gap: 0.15rem;
}

.docs-tree-row > a,
.docs-tree-row > .docs-tree-folder {
    flex: 1 1 auto;
    min-width: 0;
}

.docs-tree-toggle {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    padding: 0;
    border: none;
    background: transparent;
    color: #9ca3af;
    font-size: 0.7rem;
    border-radius: 4px;
    cursor: pointer;
}

.docs-tree-toggle:hover {
    background-color: #f3f4f6;
    color: #374151;
}

.docs-tree-toggle i {
    transition: transform 0.15s ease;
}

.docs-tree-toggle:not(.collapsed) i {
    transform: rotate(90deg);
}

.docs-tree-toggle-spacer {
    flex: 0 0 auto;
    width: 20px;
    height: 20px;
}

.docs-tree-folder {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.5rem;
    font-size: 0.86rem;
    font-weight: 600;
    color: #374151;
}

.docs-tree-file {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.5rem;
    border-radius: 8px;
    font-size: 0.86rem;
    color: #374151;
    text-decoration: none;
}

.docs-tree-file:hover {
    background-color: #f3f4f6;
    color: #111827;
}

.docs-tree-file.active {
    background-color: #eef0f3;
    color: #111827;
    font-weight: 600;
    box-shadow: inset 3px 0 0 #6b7280;
}

.docs-tree-ref {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.32rem 0.5rem;
    border-radius: 8px;
    font-size: 0.8rem;
    font-style: italic;
    color: #6b7280;
    text-decoration: none;
}

.docs-tree-ref:hover {
    background-color: #f3f4f6;
    color: #111827;
}

.docs-tree-ref.active {
    background-color: #eef0f3;
    color: #111827;
    font-weight: 600;
    box-shadow: inset 3px 0 0 #6b7280;
}

.docs-tree-heading {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.3rem 0.5rem;
    border-radius: 8px;
    font-size: 0.8rem;
    color: #6b7280;
    text-decoration: none;
}

.docs-tree-heading:hover {
    background-color: #f3f4f6;
    color: #111827;
}

.docs-tree-heading.active {
    background-color: #eef0f3;
    color: #111827;
    font-weight: 600;
    box-shadow: inset 3px 0 0 #6b7280;
}

.docs-tree-heading.on-path,
.docs-tree-ref.on-path {
    color: #111827;
    font-weight: 600;
}

.docs-tree-heading.active-heading,
.docs-tree-ref.active-heading {
    background-color: rgba(13, 110, 253, 0.08);
    color: #0d6efd;
    font-weight: 600;
    box-shadow: inset 3px 0 0 #0d6efd;
}

.docs-tree-delete-btn {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    padding: 0;
    border: none;
    background: transparent;
    color: #9ca3af;
    font-size: 0.75rem;
    border-radius: 4px;
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.12s ease, background 0.12s ease, color 0.12s ease;
}

.docs-tree-row:hover .docs-tree-delete-btn {
    opacity: 1;
}

.docs-tree-delete-btn:hover {
    background-color: #fdecea;
    color: #dc3545;
}

.docs-tree-add {
    padding: 0.4rem 0.5rem 0.2rem;
    border-top: 1px solid #e9eaec;
    margin-top: 0.4rem;
}

.docs-tree-add-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.4rem 0.5rem;
    border: none;
    background: transparent;
    border-radius: 8px;
    font-size: 0.86rem;
    color: #6b7280;
    cursor: pointer;
    transition: background 0.12s ease, color 0.12s ease;
}

.docs-tree-add-btn:hover {
    background-color: #f3f4f6;
    color: #111827;
}

.docs-editor-card {
    padding: 1rem 1.25rem;
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 8rem);
}

.docs-editor-placeholder {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #9ca3af;
    gap: 0.5rem;
    font-size: 0.9rem;
}

.docs-editor-placeholder i {
    font-size: 2rem;
}

.docs-editor-form {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.docs-editor-toolbar {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #e9eaec;
    margin-bottom: 0.75rem;
}

.docs-editor-filename {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.86rem;
    font-weight: 600;
    color: #374151;
}

.docs-editor-mode-switch {
    margin-left: auto;
}

.docs-editor-body {
    flex: 1;
    min-height: 420px;
    display: flex;
    gap: 1rem;
}

.docs-editor-highlight-wrap {
    position: relative;
    flex: 1 1 100%;
    min-height: 100%;
}

.docs-editor-highlight,
.docs-editor-textarea {
    position: absolute;
    inset: 0;
    margin: 0;
    width: 100%;
    height: 100%;
    box-sizing: border-box;
    border: 1px solid #e9eaec;
    border-radius: 8px;
    padding: 0.85rem 1rem;
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
    font-size: 0.86rem;
    line-height: 1.55;
    white-space: pre-wrap;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.docs-editor-highlight {
    color: #111827;
    background: transparent;
    overflow: hidden;
    border-color: transparent;
    pointer-events: none;
}

.docs-editor-heading-line {
    font-weight: 700;
    color: #111827;
    background: rgba(107, 114, 128, 0.1);
    border-radius: 4px;
}

.docs-editor-textarea {
    resize: none;
    color: transparent;
    background: transparent;
    caret-color: #111827;
}

.docs-editor-textarea:focus {
    outline: none;
    border-color: #9ca3af;
}

.docs-editor-textarea::selection {
    background: rgba(59, 130, 246, 0.35);
}

/* ─── Docs info modal ─── */
.docs-info-dialog {
    max-width: 640px;
}

.docs-info-body h6 {
    margin-top: 1.1rem;
    margin-bottom: 0.4rem;
    font-size: 0.86rem;
    font-weight: 700;
    color: #374151;
}

.docs-info-body h6:first-child {
    margin-top: 0;
}

.docs-info-body p {
    font-size: 0.86rem;
    color: #374151;
}

.docs-info-code {
    background: #f3f4f6;
    border: 1px solid #e9eaec;
    border-radius: 8px;
    padding: 0.6rem 0.8rem;
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
    font-size: 0.8rem;
    white-space: pre-wrap;
    word-wrap: break-word;
    color: #111827;
}

/* ─── Docs chat (test) modal ─── */
.docs-chat-dialog {
    max-width: 640px;
}

.docs-chat-content {
    height: 78vh;
    border-radius: 12px;
    overflow: hidden;
}

.docs-chat-header {
    padding: 0.9rem 1.25rem;
    background: #ffffff;
    border-bottom: 1px solid #e9eaec;
    font-size: 0.95rem;
    font-weight: 600;
    color: #374151;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
}

.docs-chat-messages {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.docs-chat-msg {
    max-width: 80%;
    padding: 0.55rem 0.8rem;
    border-radius: 12px;
    font-size: 0.875rem;
    line-height: 1.45;
}

.docs-chat-msg p {
    margin: 0 0 0.4rem;
}

.docs-chat-msg p:last-child {
    margin-bottom: 0;
}

.docs-chat-msg ul {
    margin: 0 0 0.4rem;
    padding-left: 1.1rem;
}

.docs-chat-msg.user {
    align-self: flex-end;
    background: #0d6efd;
    color: #ffffff;
    white-space: pre-wrap;
}

.docs-chat-msg.assistant {
    align-self: flex-start;
    background: #f3f4f6;
    color: #111827;
}

.docs-chat-msg.assistant.has-form {
    max-width: 92%;
}

.docs-chat-widget-form {
    margin-top: 0.4rem;
}

.docs-chat-widget-form .form-label {
    font-size: 0.78rem;
    font-weight: 600;
    color: #6b7280;
}

.docs-chat-widget-form .form-control {
    font-size: 0.855rem;
}

.docs-chat-video {
    position: relative;
    width: 360px;
    max-width: 100%;
    aspect-ratio: 16 / 9;
    margin: 0.4rem 0;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
}

.docs-chat-video iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.docs-chat-options {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    align-self: flex-start;
    max-width: 100%;
}

.docs-chat-option-btn {
    border: 1.5px solid #0d6efd;
    background: #ffffff;
    color: #0d6efd;
    border-radius: 999px;
    padding: 0.4rem 0.85rem;
    font-size: 0.82rem;
    cursor: pointer;
    transition: background 0.12s ease, color 0.12s ease;
}

.docs-chat-option-btn:hover {
    background: #0d6efd;
    color: #ffffff;
}

.docs-chat-option-back {
    border-color: #9ca3af;
    color: #6b7280;
}

.docs-chat-option-back:hover {
    background: #6b7280;
    border-color: #6b7280;
    color: #ffffff;
}

/* ─── Table ─── */
.table-wrap {
    border-radius: 12px;
    background-color: #ffffff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 4px 16px rgba(0, 0, 0, 0.06);
    overflow: hidden;
    border: 1px solid #e9eaec;
}

.table-wrap .table {
    margin-bottom: 0;
}

.table {
    font-size: 0.855rem;
    --bs-table-hover-bg: #f9fafb;
    --bs-table-border-color: #f0f1f3;
}

.table thead tr {
    border-bottom: 2px solid #e5e7eb;
}

.table thead th {
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: #6b7280;
    padding: 0.6rem 0.75rem;
    border-top: none;
    white-space: nowrap;
}

.table tbody tr {
    transition: background 0.1s ease;
}

.table tbody tr:hover {
    background: #f9fafb;
}

.table td,
.table tbody th {
    padding: 0.7rem 0.75rem;
    vertical-align: middle;
    color: #374151;
}

.table tbody tr:last-child td,
.table tbody tr:last-child th {
    border-bottom: none;
}

/* ─── Form elements ─── */
.form-control,
.form-select {
    border-color: #e9eaec;
    border-radius: 8px;
    font-size: 0.855rem;
    color: #374151;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-control:focus,
.form-select:focus {
    border-color: #d1d5db;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.05);
    color: #111827;
}

.form-control::placeholder {
    color: #b0b7c3;
}

.form-control.is-invalid,
.form-select.is-invalid {
    border-color: rgba(220, 53, 69, 0.5);
}

.form-control.is-invalid:focus,
.form-select.is-invalid:focus {
    box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.07);
}

.form-label {
    font-size: 0.78rem;
    font-weight: 600;
    color: #6b7280;
    letter-spacing: 0.02em;
    margin-bottom: 0.3rem;
}

.form-text {
    font-size: 0.76rem;
    color: #9ca3af;
}

.form-switch .form-check-input:checked {
    background-color: #374151;
    border-color: #374151;
}

.form-check-input:focus {
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.06);
    border-color: #d1d5db;
}

.form-check-label {
    font-size: 0.855rem;
    color: #374151;
}

.input-group .btn {
    --bs-btn-border-radius: 8px;
}

/* tom select */
.ts-wrapper .clear-button {
    font-size: 20px;
    cursor: pointer;
    margin-right: -20px !important;
    margin-top: -1px;
}

.ts-wrapper .clear-button:hover {

}

/* Bez tego długi tekst opcji przeskakuje do drugiej linii (domyślny flex-wrap: wrap) */
.ts-wrapper.single .ts-control {
    flex-wrap: nowrap;
    overflow: hidden;
}

.ts-wrapper.single .ts-control .item {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}