/* =========================================================
   Style strony: help-detail
   Wyeksportowane z bloku <style> w pliku help-detail.html
========================================================= */

#sidebar,
#sidebar .sidebar-inner,
#sidebar .h-100 {
    min-height: 100vh;
    height: auto !important;
}

.employee-add-btn {
    background: #3473BA !important;
    color: #fff !important;
    border: none !important;
    border-radius: 14px !important;

    padding: 12px 18px;
    font-weight: 600;
    font-size: 15px;

    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    white-space: nowrap;
    transition: .2s ease;
}

.employee-add-btn:hover {
    background: #2C629D !important;
    transform: translateY(-1px);
}

@media (max-width: 768px) {


    .employee-add-btn {
        width: 100%;
        justify-content: center;
        font-size: 14px;
        padding: 12px;
    }
}

.page-title {
margin: 0;
font-size: 24px;
font-weight: 700;
color: #1f2937;
letter-spacing: -0.5px;
line-height: 1.2;

display: flex;
align-items: center;
gap: 10px;
}



/* mobile */
@media (max-width: 768px) {

.page-title {
    font-size: 20px;
    gap: 8px;
}

.page-title::before {
    font-size: 22px;
}
}


/* ===========================
   WYSZUKIWANIE PLIKÓW POMOCY
=========================== */

.search-box {
    background: #fff;
    border: 1px solid #eef2f7;
    border-radius: 16px;
    box-shadow: 0 4px 14px rgba(15, 23, 42, .05);
    margin-bottom: 20px;
    overflow: hidden;
}

.search-box-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    padding: 14px 22px;
    border-bottom: 1px solid #eef2f7;
    background: #f8fafc;
}

.search-box-header h4 {
    margin: 0;
    font-size: 17px;
    font-weight: 700;
    color: #111827;
}

.search-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* "Wroc do ..." - taki sam jak przycisk "Instrukcja" obok (biale tlo, cienka ramka, niebieski tekst) */
.search-action-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 12px;
    border: 1px solid #e6ecf5;
    border-radius: 10px;
    background: #fff;
    color: #3473BA;
    font-size: .78rem;
    font-weight: 600;
    line-height: 1.1;
    white-space: nowrap;
    text-decoration: none;
    transition: background .18s ease, border-color .18s ease;
}

.search-action-btn:hover,
.search-action-btn:focus {
    background: #f3f8fe;
    border-color: #3473BA;
    color: #3473BA;
}

html[data-bs-theme="dark"] .search-action-btn { background: var(--app-surface); border-color: var(--app-border); color: #8fb5e0; }
html[data-bs-theme="dark"] .search-action-btn:hover,
html[data-bs-theme="dark"] .search-action-btn:focus { background: var(--app-surface-2); border-color: #3473ba; }

.search-action-btn-primary {
    background: #3473BA;
    border-color: #3473BA;
    color: #fff;
}

.search-action-btn-primary:hover {
    background: #2C629D;
    border-color: #2C629D;
}

.search-box-body {
    padding: 20px 22px;
}

.search-filters {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px 20px;
}

.search-filters .form-label {
    margin-bottom: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #6b7280;
}

.search-form-actions {
    display: flex;
    gap: 10px;
    margin-top: 18px;
}

.search-submit-btn {
    min-width: 130px;
    height: 40px;
    border: 1px solid #3473BA;
    border-radius: 10px;
    background: #3473BA;
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    transition: .2s ease;
}

.search-submit-btn:hover {
    background: #2C629D;
    border-color: #2C629D;
}

.search-table-wrap {
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    overflow: auto;
}

.search-table {
    width: 100%;
    min-width: 900px;
    margin: 0;
    border-collapse: collapse;
    font-size: 15px;
    color: #6b7280;
}

.search-table thead th {
    padding: 14px 16px;
    font-weight: 600;
    text-align: left;
    color: #6b7280;
    background: #fff;
    border-bottom: 1px solid #e5e7eb;
    white-space: nowrap;
}

.search-table tbody td {
    padding: 14px 16px;
    border-bottom: 1px solid #e5e7eb;
    vertical-align: middle;
}

.search-table tbody tr:nth-child(odd) {
    background: #f9fafb;
}

.search-table tbody tr:hover {
    background: #eef4fb;
}

.search-table tbody tr:last-child td {
    border-bottom: 0;
}

.search-symbol {
    font-weight: 600;
    color: #111827;
}

.search-status {
    display: inline-flex;
    align-items: center;
    height: 26px;
    padding: 0 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    line-height: 1;
    white-space: nowrap;
}

.search-status-active {
    background: rgba(92, 184, 92, .14);
    color: #3f8f3f;
}

.search-status-inactive {
    background: rgba(107, 114, 128, .14);
    color: #6b7280;
}

.search-status-draft {
    background: rgba(224, 164, 88, .16);
    color: #a8702a;
}

/* "Szczegoly" w wierszu listy - pastelowy niebieski jak na innych listach */
.search-details-btn {
    height: 34px;
    padding: 0 14px;
    border: 1px solid transparent;
    border-radius: 8px;
    background: #dce7fb;
    color: #2f56a6;
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
    transition: .2s ease;
}

.search-details-btn:hover {
    background: #c8d9f8;
    color: #244688;
}

html[data-bs-theme="dark"] .search-details-btn { background: #223454; color: #a9c3f2; }
html[data-bs-theme="dark"] .search-details-btn:hover { background: #2b4169; color: #c3d5f7; }

.search-empty td {
    padding: 26px 16px;
    text-align: center;
    color: #6b7280;
}

.search-summary {
    margin: 14px 2px 0;
    font-size: 13px;
    color: #6b7280;
}

.search-modal-columns {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 4px 28px;
}

.search-modal-columns .form-group {
    margin-bottom: 14px;
}

.search-modal-columns .form-label {
    margin-bottom: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #6b7280;
}

.search-required {
    background: #eef7fa;
    border-color: #cfe3ea;
}

.search-lookup {
    display: flex;
    gap: 6px;
}

.search-lookup .form-control {
    flex: 1 1 auto;
    min-width: 0;
}

.search-lookup-btn {
    flex: 0 0 42px;
    width: 42px;
    height: 38px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: #fff;
    color: #6b7280;
    transition: .2s ease;
}

.search-lookup-btn:hover {
    border-color: #3473BA;
    background: rgba(52, 115, 186, .09);
    color: #3473BA;
}

#helpModal .modal-content {
    border: 0;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 18px 50px rgba(15, 23, 42, .18);
}

#helpModal .modal-header {
    border-bottom: 1px solid #eef2f7;
    padding: 16px 22px;
}

#helpModal .modal-title {
    font-size: 17px;
    font-weight: 700;
    color: #111827;
}

/* formularz jest miedzy .modal-content a .modal-body,
   wiec sam musi byc kolumna flex, zeby tresc dala sie przewijac */
#helpModal .modal-content > form {
    display: flex;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
}

#helpModal .modal-body {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
}

#helpModal .modal-body {
    padding: 20px 22px 6px;
}

#helpModal .modal-footer {
    border-top: 0;
    padding: 6px 22px 20px;
}

.search-save-btn {
    width: 100%;
    height: 46px;
    border: 1px solid #3473BA;
    border-radius: 10px;
    background: #3473BA;
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    transition: .2s ease;
}

.search-save-btn:hover {
    background: #2C629D;
    border-color: #2C629D;
}

.search-modal-error {
    margin-bottom: 12px;
    font-size: 13px;
    font-weight: 600;
    color: #d9534f;
}

@media (max-width: 768px) {

    .search-box-body {
        padding: 16px;
    }

    .search-form-actions {
        flex-direction: column;
    }

    .search-submit-btn {
        width: 100%;
    }
}

#helpModal .search-filters {
    grid-template-columns: 1fr;
}

.help-show-btn {
    min-width: 120px;
    height: 34px;
    padding: 0 16px;
    border: 1px solid #5bc0de;
    border-radius: 8px;
    background: #5bc0de;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    transition: .2s ease;
}

.help-show-btn:hover {
    background: #46b1d1;
    border-color: #46b1d1;
}

.help-name {
    font-weight: 600;
    color: #111827;
}


/* SZCZEGÓŁ POMOCY */

.help-columns {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.help-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin-bottom: 16px;
}

.help-toolbar-right {
    display: flex;
    gap: 8px;
    margin-left: auto;
}

/* przyciski karty pomocy - pastelowe: K1 wyniki, K3 Edytuj, K2 Zapisz, K6 Anuluj, K4 Usun */
.help-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: 1px solid transparent;
    border-radius: 10px;
    padding: 8px 18px;
    font-size: 13px;
    font-weight: 600;
    color: #2f56a6;
    background: #dce7fb;
    text-decoration: none;
    transition: background-color .18s ease, color .18s ease;
}

.help-btn:hover,
.help-btn:focus { background: #c8d9f8; color: #244688; text-decoration: none; }

.help-btn-edit { background: #fde3c4; color: #9a5a0c; }
.help-btn-edit:hover, .help-btn-edit:focus { background: #f9d5a6; color: #7d4906; }

.help-btn-save { background: #d3f2e1; color: #1b6b45; }
.help-btn-save:hover, .help-btn-save:focus { background: #bde9d0; color: #155637; }

.help-btn-delete { background: #fbdada; color: #a52022; }
.help-btn-delete:hover, .help-btn-delete:focus { background: #f7c6c6; color: #8a1a1c; }

.help-btn-cancel { background: #fff; border-color: #cfd8e6; color: #46536b; }
.help-btn-cancel:hover, .help-btn-cancel:focus { background: #f6f8fc; color: #0f2745; }

html[data-bs-theme="dark"] .help-btn { background: #223454; color: #a9c3f2; }
html[data-bs-theme="dark"] .help-btn-edit { background: #4a3416; color: #f6c98d; }
html[data-bs-theme="dark"] .help-btn-save { background: #1a3d2c; color: #9fe0bf; }
html[data-bs-theme="dark"] .help-btn-delete { background: #4a2224; color: #f2a9aa; }
html[data-bs-theme="dark"] .help-btn-cancel { background: var(--app-surface); border-color: var(--app-border); color: var(--app-ink); }

.help-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #eef1f5;
    font-size: 13px;
}

.help-row:last-child {
    border-bottom: 0;
}

.help-row-label {
    flex: 0 0 160px;
    color: #6b7c8f;
    margin: 0;
}

.help-row-value {
    flex: 1 1 240px;
    min-width: 0;
    color: #0f2745;
    font-weight: 600;
    word-break: break-word;
}

.help-go-btn {
    border: 0;
    background: #dce7fb;
    color: #2f56a6;
    border-radius: 8px;
    padding: 6px 16px;
    font-size: 12px;
    font-weight: 600;
}
.help-go-btn:hover, .help-go-btn:focus { background: #c8d9f8; color: #244688; }
html[data-bs-theme="dark"] .help-go-btn { background: #223454; color: #a9c3f2; }

.help-makers {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 16px;
}

.help-maker-btn {
    border: 1px solid #e6ebf1;
    background: #fff;
    color: #2f56a6;
    border-radius: 8px;
    padding: 5px 12px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .02em;
}

/* zakladki producentow: niewybrana - szara ramka, niebieski tekst;
   wybrana - pastelowy niebieski jak "Wyniki wyszukiwania" */
.help-maker-btn:hover {
    border-color: #c8d6ea;
    background: #f4f8fe;
    color: #2f56a6;
}

.help-maker-btn.is-active,
.help-maker-btn.is-active:hover,
.help-maker-btn.is-active:focus {
    background: #dce7fb;
    border-color: #dce7fb;
    color: #2f56a6;
    box-shadow: none;
}

.help-maker-btn:focus-visible {
    outline: 2px solid #3473BA;
    outline-offset: 2px;
    box-shadow: none;
}

.help-models {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 8px;
    max-height: 420px;
    overflow-y: auto;
    padding-right: 4px;
}

.help-model {
    border: 1px solid #e6ebf1;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 12px;
    text-align: center;
    color: #33475b;
    background: #fff;
}

.help-status {
    margin: 0 0 14px;
    font-size: 12px;
    color: #3f8f3f;
}

.help-status.is-error {
    color: #d9534f;
}

.help-models-empty {
    margin: 0;
    padding: 18px;
    text-align: center;
    font-size: 13px;
    color: #6b7c8f;
    background: #fbfcfe;
    border: 1px dashed #e6ebf1;
    border-radius: 12px;
}
