/* Sdílený vizuální systém přehledů objednávek a poptávek. */
.documents-page.page-container.mobile-page {
    box-sizing: border-box;
    display: block !important;
    width: 100%;
    height: 100% !important;
    min-height: 0;
    margin: 0 !important;
    padding: 12px 14px 28px;
    overflow: hidden;
    color: #2e4c43;
    background: linear-gradient(180deg, #f7faf9 0, #ffffff 250px);
}

.documents-page .documents-shell {
    display: flex;
    width: min(100%, 1180px);
    height: 100%;
    min-width: 0;
    min-height: 0;
    margin-inline: auto;
    flex-direction: column;
    gap: 10px;
}

.documents-page .documents-toolbar {
    display: grid;
    flex: 0 0 auto;
    grid-template-columns: minmax(250px, 1fr) auto;
    align-items: end;
    gap: 14px;
    margin: 0 !important;
    padding: 12px 14px;
    background: #ffffff;
    border: 1px solid #d6e4df;
    border-radius: 14px;
    box-shadow: 0 2px 9px rgba(18, 66, 54, .05);
}

.documents-page .documents-search {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 5px;
}

.documents-page .documents-search label {
    color: #526c64;
    font-size: .68rem;
    font-weight: 750;
    line-height: 1.35;
}

.documents-page .documents-search__control {
    position: relative;
    display: flex;
    min-width: 0;
    align-items: center;
}

.documents-page .documents-search__control > i {
    position: absolute;
    left: 12px;
    z-index: 2;
    color: #71847e;
    font-size: .78rem;
    pointer-events: none;
}

.documents-page .documents-search__control .e-input-group,
.documents-page .documents-search__control .e-input-group.e-control-wrapper {
    min-height: 42px;
    padding-left: 30px;
    color: #24483e;
    background: #fbfcfc;
    border: 1px solid #cbdcd6 !important;
    border-radius: 10px !important;
}

.documents-page .documents-search__control .e-input-group.e-input-focus,
.documents-page .documents-search__control .e-input-group.e-control-wrapper.e-input-focus {
    border-color: #08745b !important;
    box-shadow: 0 0 0 3px rgba(8, 116, 91, .14) !important;
}

.documents-page .documents-toolbar__actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 7px;
}

.documents-page .documents-icon-button {
    display: grid;
    width: 42px;
    min-width: 42px;
    height: 42px;
    padding: 0;
    place-items: center;
    color: #526c64;
    background: #ffffff;
    border: 1px solid #cbdcd6;
    border-radius: 10px;
    font-size: .78rem;
}

.documents-page .documents-icon-button > i {
    color: currentColor;
}

.documents-page .documents-icon-button:not(:disabled):hover,
.documents-page .documents-icon-button:not(:disabled):focus-visible {
    color: #075642;
    background: #eaf5f1;
    border-color: #79aa99;
}

.documents-page .documents-refresh-button {
    color: #ffffff;
    background: #08745b;
    border-color: #08745b;
    box-shadow: 0 4px 11px rgba(8, 116, 91, .15);
}

.documents-page .documents-refresh-button:not(:disabled):hover,
.documents-page .documents-refresh-button:not(:disabled):focus-visible {
    color: #ffffff;
    background: #075642;
    border-color: #075642;
}

.documents-page .documents-icon-button:disabled {
    color: #7c8e88;
    background: #eef2f1;
    border-color: #d8e2df;
    box-shadow: none;
}

.documents-page .documents-icon-button:focus-visible {
    outline: 3px solid rgba(8, 116, 91, .26);
    outline-offset: 2px;
}

.documents-page .documents-content.content {
    position: relative;
    display: flex !important;
    min-width: 0;
    min-height: 0 !important;
    height: auto !important;
    flex: 1 1 auto;
    flex-direction: column;
    margin: 0 !important;
    overflow: hidden;
    background: #ffffff;
    border: 1px solid #d6e4df;
    border-radius: 14px;
    box-shadow: 0 2px 9px rgba(18, 66, 54, .05);
}

.documents-page .documents-grid.grid-wrapper {
    display: flex !important;
    min-width: 0;
    min-height: 0 !important;
    height: 100% !important;
    flex: 1 1 auto;
    flex-direction: column;
    margin: 0 !important;
    overflow: hidden !important;
}

.documents-page .documents-grid > .e-grid {
    display: flex;
    min-width: 0;
    min-height: 0;
    flex: 1 1 auto;
    flex-direction: column;
    color: #435d55;
    border: 0 !important;
    font-size: .78rem;
}

.documents-page .documents-grid > .e-grid > .e-gridheader {
    flex: 0 0 auto;
    color: #526c64;
    background: #f4f8f6;
    border-color: #dce7e3;
}

.documents-page .documents-grid > .e-grid > .e-gridheader .e-headercell {
    height: 44px;
    padding: 7px 9px;
    background: #f4f8f6;
    border-color: #dce7e3;
}

.documents-page .documents-grid > .e-grid > .e-gridheader .e-headertext {
    color: #526c64;
    font-size: .68rem;
    font-weight: 800;
    letter-spacing: .015em;
}

.documents-page .documents-grid > .e-grid > .e-gridcontent,
.documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content {
    min-height: 0;
    flex: 1 1 auto;
    overflow: auto !important;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: #aec2bb transparent;
}

.documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content::-webkit-scrollbar {
    width: 7px;
    height: 7px;
}

.documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content::-webkit-scrollbar-thumb {
    border-radius: 999px;
    background: #aec2bb;
}

.documents-page .documents-grid > .e-grid .e-row {
    height: 58px;
}

.documents-page .documents-grid > .e-grid .e-rowcell {
    padding: 8px 9px;
    color: #435d55;
    background: #ffffff;
    border-color: #e4ebe9;
    vertical-align: middle;
}

.documents-page .documents-grid > .e-grid .e-row:hover > .e-rowcell,
.documents-page .documents-grid > .e-grid .e-row.e-hover > .e-rowcell {
    color: #24483e !important;
    background: #f7fbf9 !important;
}

.documents-page .documents-grid > .e-grid .e-selectionbackground,
.documents-page .documents-grid > .e-grid .e-selectionbackground .e-rowcell,
.documents-page .documents-grid > .e-grid .e-row[aria-selected="true"] .e-rowcell {
    color: #24483e !important;
    background: #eaf5f1 !important;
}

.documents-page .documents-grid > .e-grid .e-detailrowcollapse,
.documents-page .documents-grid > .e-grid .e-detailrowexpand {
    color: #08745b !important;
    background: #ffffff;
}

.documents-page .documents-grid > .e-grid .e-detailrowcollapse:hover,
.documents-page .documents-grid > .e-grid .e-detailrowexpand:hover {
    color: #075642 !important;
    background: #eaf5f1;
}

.documents-page .document-number {
    color: #173f35;
    font-size: .8rem;
    font-weight: 800;
}

.documents-page .document-date,
.documents-page .document-reference,
.documents-page .document-amount {
    color: #435d55;
    font-variant-numeric: tabular-nums;
}

.documents-page .document-reference {
    font-weight: 650;
}

.documents-page .document-amount {
    white-space: nowrap;
    font-weight: 800;
}

.documents-page .novum-badge {
    display: inline-flex !important;
    min-height: 30px;
    max-width: 100%;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 4px 9px;
    border: 1px solid;
    border-radius: 999px;
    font-size: .67rem !important;
    font-weight: 800;
    line-height: 1.1;
    text-align: center;
    white-space: normal;
}

.documents-page .novum-badge .badge-icon {
    flex: 0 0 auto;
    color: currentColor;
}

.documents-page .state-kvyjadreni {
    color: #9a6700 !important;
    background: #fffaeb !important;
    border-color: #fedf89 !important;
}

.documents-page .state-bezvyjadreni,
.documents-page .state-processing {
    color: #475467 !important;
    background: #f2f4f7 !important;
    border-color: #d0d5dd !important;
}

.documents-page .state-odmitnuto {
    color: #b42318 !important;
    background: #fef3f2 !important;
    border-color: #fecdca !important;
}

.documents-page .state-objednano,
.documents-page .state-odeslano {
    color: #067647 !important;
    background: #ecfdf3 !important;
    border-color: #abefc6 !important;
}

.documents-page .state-neznamy {
    color: #475467 !important;
    background: #f9fafb !important;
    border-color: #d0d5dd !important;
}

.documents-page .documents-grid .center-items {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

.documents-page .documents-grid .center-items .e-btn,
.documents-page .documents-grid .icon-only-button.e-btn {
    display: inline-grid !important;
    width: 32px;
    min-width: 32px !important;
    height: 32px;
    padding: 0 !important;
    place-items: center;
    color: #08745b !important;
    background: #eef7f4 !important;
    border: 1px solid #b9d7cd !important;
    border-radius: 9px !important;
    box-shadow: none !important;
}

.documents-page .documents-grid .center-items .e-btn:hover,
.documents-page .documents-grid .center-items .e-btn:focus-visible,
.documents-page .documents-grid .icon-only-button.e-btn:hover,
.documents-page .documents-grid .icon-only-button.e-btn:focus-visible {
    color: #ffffff !important;
    background: #08745b !important;
    border-color: #08745b !important;
}

.documents-page .documents-grid .e-btn:has(.fa-thumbs-down),
.documents-page .documents-grid .e-btn:has(.fa-times) {
    color: #b42318 !important;
    background: #fef3f2 !important;
    border-color: #fda29b !important;
}

.documents-page .documents-grid .e-btn:has(.fa-thumbs-down):hover,
.documents-page .documents-grid .e-btn:has(.fa-thumbs-down):focus-visible,
.documents-page .documents-grid .e-btn:has(.fa-times):hover,
.documents-page .documents-grid .e-btn:has(.fa-times):focus-visible {
    color: #ffffff !important;
    background: #b42318 !important;
    border-color: #b42318 !important;
}

.documents-page .documents-grid .e-btn:focus-visible {
    outline: 3px solid rgba(8, 116, 91, .22);
    outline-offset: 2px;
}

.documents-page .detail-container {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 10px;
    padding: 12px !important;
    color: #435d55;
    background: #f7faf9 !important;
    border-top: 1px solid #d6e4df;
    border-bottom: 1px solid #d6e4df;
}

.documents-page .detail-info-compact {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 7px 14px;
    margin: 0 !important;
    padding: 11px 12px !important;
    background: #ffffff;
    border: 1px solid #dce7e3;
    border-radius: 11px;
}

.documents-page .detail-info-compact h3 {
    grid-column: 1 / -1;
    margin: 0 0 3px;
    color: #173f35;
    font-size: .9rem;
    font-weight: 800;
}

.documents-page .detail-info-compact p {
    min-width: 0;
    margin: 0 !important;
    color: #526c64;
    font-size: .72rem;
    line-height: 1.45;
    overflow-wrap: anywhere;
}

.documents-page .detail-info-compact p strong {
    color: #29483f;
    font-weight: 750;
}

.documents-page .detail-grid-wrapper {
    min-width: 0;
    overflow: hidden;
    background: #ffffff;
    border: 1px solid #dce7e3;
    border-radius: 11px;
}

.documents-page .detail-grid-wrapper .e-grid {
    border: 0 !important;
    font-size: .72rem;
}

.documents-page .detail-grid-wrapper .e-headercell {
    background: #f4f8f6 !important;
    border-color: #dce7e3 !important;
}

.documents-page .detail-grid-wrapper .e-rowcell {
    border-color: #e4ebe9 !important;
}

.documents-page .documents-skeleton {
    display: flex;
    flex-direction: column;
    gap: 1px;
    padding: 8px;
}

.documents-page .documents-skeleton > div {
    display: grid;
    min-height: 56px;
    grid-template-columns: 130px 1fr 1fr 120px;
    align-items: center;
    gap: 20px;
    padding: 0 14px;
    background: #ffffff;
    border-bottom: 1px solid #e8eeec;
}

.documents-page .documents-skeleton span {
    display: block;
    height: 12px;
    overflow: hidden;
    background: #e8efed;
    border-radius: 999px;
}

.documents-page .documents-skeleton span::after {
    display: block;
    width: 45%;
    height: 100%;
    content: "";
    background: linear-gradient(90deg, transparent, rgba(255,255,255,.78), transparent);
    animation: documents-skeleton 1.25s ease-in-out infinite;
}

.documents-page .documents-sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    clip-path: inset(50%);
}

@keyframes documents-skeleton {
    from {
        transform: translateX(-120%);
    }

    to {
        transform: translateX(280%);
    }
}

@media (prefers-reduced-motion: reduce) {
    .documents-page .documents-skeleton span::after {
        animation: none;
    }
}

@media (max-width: 1268px) {
    .documents-page.page-container.mobile-page {
        padding: 10px 10px 22px;
    }
}

@media (max-width: 767.98px) {
    .documents-page.page-container.mobile-page {
        padding: 8px 8px 18px;
    }

    .documents-page .documents-shell {
        gap: 8px;
    }

    .documents-page .documents-toolbar {
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 9px;
        padding: 10px;
        border-radius: 12px;
    }

    .documents-page .documents-search label {
        font-size: .65rem;
    }

    .documents-page .documents-toolbar__actions {
        gap: 5px;
    }

    .documents-page .documents-content.content {
        overflow: auto;
        background: #f6f9f8;
        border-radius: 12px;
    }

    .documents-page .documents-grid.grid-wrapper {
        overflow: visible !important;
    }

    .documents-page .documents-grid > .e-grid {
        display: block;
        height: auto !important;
        overflow: visible;
        background: transparent;
    }

    .documents-page .documents-grid > .e-grid > .e-gridheader {
        display: none !important;
    }

    .documents-page .documents-grid > .e-grid > .e-gridcontent,
    .documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content {
        height: auto !important;
        max-height: none !important;
        overflow: visible !important;
        background: transparent;
    }

    .documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content > .e-table,
    .documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content > .e-table > tbody {
        display: block;
        width: 100% !important;
        min-width: 0 !important;
    }

    .documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content > .e-table > colgroup {
        display: none;
    }

    .documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content > .e-table > tbody {
        box-sizing: border-box;
        padding: 10px;
    }

    .documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content > .e-table > tbody > tr.e-row {
        box-sizing: border-box;
        display: flex !important;
        width: 100%;
        height: auto !important;
        min-height: 0;
        flex-wrap: wrap;
        align-items: center;
        gap: 0;
        margin: 0 0 10px;
        overflow: hidden;
        background: #ffffff;
        border: 1px solid #dce7e3;
        border-radius: 13px;
        box-shadow: 0 2px 8px rgba(18, 66, 54, .05);
    }

    .documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content > .e-table > tbody > tr.e-row > td {
        box-sizing: border-box;
        display: flex !important;
        width: auto !important;
        min-width: 0 !important;
        height: auto !important;
        min-height: 48px;
        flex: 1 1 105px;
        align-items: center;
        padding: 8px 9px !important;
        background: #ffffff !important;
        border: 0 !important;
    }

    .documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content > .e-table > tbody > tr.e-row > td.e-hide {
        display: none !important;
    }

    .documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content > .e-table > tbody > tr.e-row > td.e-detailrowcollapse,
    .documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content > .e-table > tbody > tr.e-row > td.e-detailrowexpand {
        min-height: 48px;
        flex: 0 0 36px;
        justify-content: center;
        padding-inline: 6px !important;
    }

    .documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content > .e-table > tbody > tr.e-row > td:has(.novum-badge) {
        flex: 1 1 130px;
    }

    .documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content > .e-table > tbody > tr.e-row > td:has(.document-number) {
        flex: 0 1 105px;
        justify-content: flex-end;
    }

    .documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content > .e-table > tbody > tr.e-row > td:has(.document-amount) {
        flex: 1 1 120px;
        justify-content: flex-end;
        border-top: 1px solid #e4ebe9 !important;
    }

    .documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content > .e-table > tbody > tr.e-row > td:has(.center-items),
    .documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content > .e-table > tbody > tr.e-row > td:has(.icon-only-button) {
        min-height: 46px;
        flex: 1 1 auto;
        justify-content: flex-end;
        border-top: 1px solid #e4ebe9 !important;
    }

    .documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content > .e-table > tbody > tr.e-detailrow {
        display: block !important;
        width: 100%;
        margin: -6px 0 10px;
    }

    .documents-page .documents-grid > .e-grid > .e-gridcontent > .e-content > .e-table > tbody > tr.e-detailrow > td.e-detailcell {
        display: block !important;
        width: 100% !important;
        padding: 0 !important;
        border: 0 !important;
    }

    .documents-page .detail-container {
        padding: 9px !important;
        border: 1px solid #d6e4df;
        border-radius: 12px;
        box-shadow: 0 5px 16px rgba(18, 66, 54, .08);
    }

    .documents-page .detail-info-compact {
        grid-template-columns: 1fr;
    }

    .documents-page .detail-grid-wrapper {
        overflow-x: auto;
    }

    .documents-page .detail-grid-wrapper .e-grid {
        min-width: 720px;
    }

    .documents-page .documents-skeleton {
        gap: 10px;
        padding: 10px;
    }

    .documents-page .documents-skeleton > div {
        min-height: 130px;
        grid-template-columns: 1fr 100px;
        align-content: center;
        gap: 18px;
        border: 1px solid #dce7e3;
        border-radius: 13px;
    }
}

@media (max-width: 420px) {
    .documents-page .documents-search__control .e-input-group,
    .documents-page .documents-search__control .e-input-group.e-control-wrapper {
        font-size: .78rem;
    }

    .documents-page .documents-icon-button {
        width: 40px;
        min-width: 40px;
    }
}

@media print {
    .documents-page .documents-toolbar,
    .documents-page .novum-info-note {
        display: none !important;
    }

    .documents-page.page-container.mobile-page,
    .documents-page .documents-content.content {
        height: auto !important;
        overflow: visible !important;
        background: #ffffff;
        border: 0;
        box-shadow: none;
    }
}
