.riento-documents-row-mobile {
    display: none;
}

.riento-document-table-actions,
.riento-document-preview__actions {
    display: flex;
    align-items: center;
    gap: var(--r-space-2);
    flex-wrap: wrap;
}

.riento-document-detail {
    position: relative;
    min-width: 0;
}

.riento-document-header-actions {
    position: relative;
}

.riento-document-overview {
    min-width: 0;
}

.riento-document-overview--preview-only {
    display: flex;
    flex-direction: column;
    gap: var(--r-space-4);
}

.riento-document-overview__main,
.riento-document-files-tab,
.riento-document-history-tab,
.riento-document-qc-panel,
.riento-document-tab-stack {
    display: grid;
    gap: var(--r-space-4);
    min-width: 0;
}

.riento-document-overview__preview {
    min-width: 0;
}

.riento-document-overview-root {
    display: grid;
    gap: var(--r-space-4);
    min-width: 0;
}

.riento-document-preview__surface {
    min-height: 320px;
    border: 1px dashed var(--r-color-border);
    border-radius: var(--r-radius-md);
    background: color-mix(in srgb, var(--r-color-surface) 86%, transparent);
    overflow: hidden;
}

.riento-document-preview__placeholder {
    min-height: 320px;
    display: grid;
    place-items: center;
    gap: var(--r-space-3);
    padding: var(--r-space-5);
    text-align: center;
    color: var(--r-color-text-muted);
}

.riento-document-preview__placeholder h4 {
    margin: 0 0 var(--r-space-1);
    color: var(--r-color-text);
}

.riento-document-preview__placeholder p {
    margin: 0;
    max-width: 34rem;
}

.riento-document-preview__image,
.riento-document-preview__frame {
    width: 100%;
    min-height: 320px;
    border: 0;
    object-fit: contain;
}

.riento-document-preview__meta {
    display: flex;
    gap: var(--r-space-3);
    margin-top: var(--r-space-2);
    color: var(--r-color-text-muted);
    font-size: var(--r-font-size-sm);
}

.riento-document-preview__actions {
    margin-top: var(--r-space-3);
}

.riento-document-qc-panel__step {
    color: var(--r-color-text-muted);
}

.riento-document-released-files-list {
    display: grid;
    gap: var(--r-space-2);
}

.riento-document-released-file-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: var(--r-space-3);
    padding: var(--r-space-3);
    border: 1px solid var(--r-border-subtle);
    border-radius: var(--r-radius-md);
    background: var(--r-bg-surface-2);
}

.riento-document-released-file-row__main {
    min-width: 0;
}

.riento-document-released-file-row__name {
    min-width: 0;
    overflow: hidden;
    color: var(--r-text-primary);
    font-weight: var(--r-font-weight-semibold);
    text-overflow: ellipsis;
    white-space: nowrap;
}

.riento-document-sharepoint-link-row {
    display: flex;
    margin-top: var(--r-space-4);
}

@media (max-width: 959px) {
    .riento-documents-row-desktop {
        display: none;
    }

    .riento-documents-row-mobile {
        display: block;
    }

    .riento-tab-panel {
        padding: var(--r-space-3);
    }

    .riento-tab-panel__header {
        flex-direction: column;
        gap: var(--r-space-2);
    }

    .riento-document-overview__preview {
        width: 100%;
    }

    .riento-document-preview-panel__empty,
    .riento-document-preview-card__pdf {
        min-height: 220px;
        height: auto;
    }

    .riento-document-preview-card__pdf {
        min-height: 64vh;
    }

    .riento-document-preview-card__title {
        white-space: normal;
        overflow-wrap: anywhere;
    }

    .riento-document-focused-preview__header {
        align-items: flex-start;
        flex-wrap: wrap;
    }

    .riento-document-focused-preview__title {
        white-space: normal;
        overflow-wrap: anywhere;
    }

    .riento-document-focused-preview__image {
        max-height: none;
    }

    .riento-document-released-file-row {
        align-items: start;
    }

    .riento-document-released-file-row__main {
        min-width: 0;
    }

    .riento-document-released-file-row__name {
        white-space: normal;
        overflow-wrap: anywhere;
    }

    .riento-document-sharepoint-link-row .riento-button {
        width: 100%;
        justify-content: center;
    }

    .riento-mobile-document-detail__body,
    .riento-document-detail {
        min-width: 0;
        overflow-x: hidden;
    }

    .riento-mobile-document-detail .riento-mobile-entity-hero__content {
        min-width: 0;
    }

    .riento-mobile-document-detail .riento-mobile-entity-hero__title,
    .riento-mobile-document-detail .riento-mobile-entity-hero__primary {
        white-space: normal;
        overflow-wrap: anywhere;
    }
}
