/* Кодировка банковской выписки — layout как у upd-pdf-xml */

.bse-shell {
    width: 100%;
    max-width: none;
}

.bse-shell .hidden {
    display: none !important;
}

.bse-dropzone {
    min-height: 220px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 2px dashed #cbd5e1;
    border-radius: 0.75rem;
    padding: 2rem 1.5rem;
    text-align: center;
    transition: border-color 0.2s ease, background 0.2s ease;
    cursor: pointer;
}

.bse-dropzone:hover,
.bse-dropzone.is-drag-over {
    border-color: #34d3a8;
    background: #f0fdf9;
}

.bse-btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.625rem 1.25rem;
    border-radius: 0.75rem;
    border: none;
    background: #059669;
    color: #fff;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s ease;
}

.bse-btn-primary:hover:not(:disabled) {
    background: #047857;
}

.bse-btn-primary:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.bse-btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    border-radius: 0.75rem;
    border: 1px solid #cbd5e1;
    background: #fff;
    color: #334155;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease;
}

.bse-btn-secondary:hover:not(:disabled) {
    border-color: #94a3b8;
    background: #f8fafc;
}

.bse-presets .bse-btn-secondary.is-active {
    border-color: #059669;
    background: #ecfdf5;
    color: #047857;
    box-shadow: inset 0 0 0 1px #059669;
}

.bse-presets .bse-btn-secondary.is-active:hover:not(:disabled) {
    border-color: #047857;
    background: #d1fae5;
}

.bse-btn-download {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.875rem 1.5rem;
    border-radius: 0.75rem;
    border: none;
    background: #059669;
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.15s ease;
}

.bse-btn-download:hover:not(:disabled) {
    background: #047857;
}

.bse-btn-download:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.bse-file-meta {
    margin-top: 1.25rem;
    padding: 0.875rem 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 0.75rem;
    background: #f8fafc;
}

.bse-file-meta__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.bse-file-meta__name {
    font-size: 0.9375rem;
    font-weight: 600;
    color: #0f172a;
    word-break: break-all;
}

.bse-detect-status {
    margin: 0.625rem 0 0;
    font-size: 0.875rem;
    color: #64748b;
    line-height: 1.4;
}

.bse-detect-status.is-ready {
    color: #047857;
    font-weight: 600;
}

.bse-detect-status.is-error {
    color: #b91c1c;
}

.bse-form {
    margin-top: 1.5rem;
}

.bse-form__grid {
    display: grid;
    gap: 1rem;
}

@media (min-width: 640px) {
    .bse-form__grid {
        grid-template-columns: 1fr 1fr;
    }
}

.bse-label {
    display: block;
    margin-bottom: 0.375rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #334155;
}

.bse-select {
    display: block;
    width: 100%;
    padding: 0.625rem 0.875rem;
    border: 1px solid #cbd5e1;
    border-radius: 0.75rem;
    background: #fff;
    color: #0f172a;
    font-size: 0.9375rem;
}

.bse-select:focus {
    outline: none;
    border-color: #34d3a8;
    box-shadow: 0 0 0 3px rgba(52, 211, 168, 0.2);
}

.bse-presets {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.bse-actions {
    margin-top: 1.5rem;
}

.bse-processing {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    min-height: 220px;
    color: #047857;
    font-weight: 500;
}

.bse-processing__text {
    margin: 0;
}

.bse-spinner {
    width: 2rem;
    height: 2rem;
    animation: bse-spin 0.8s linear infinite;
}

.bse-spinner__track {
    opacity: 0.25;
}

.bse-spinner__head {
    opacity: 0.75;
}

@keyframes bse-spin {
    to { transform: rotate(360deg); }
}

.bse-notice {
    margin-top: 1rem;
    padding: 0.75rem 1rem;
    border-radius: 0.75rem;
    font-size: 0.875rem;
    border: 1px solid #a7f3d0;
    background: #ecfdf5;
    color: #065f46;
}

.bse-notice.is-error {
    border-color: #fecaca;
    background: #fef2f2;
    color: #991b1b;
}

.bse-notice.is-success {
    border-color: #a7f3d0;
    background: #ecfdf5;
    color: #065f46;
}

.bse-help {
    margin-top: 1.5rem;
    font-size: 0.9375rem;
    color: #64748b;
    line-height: 1.55;
}

.bse-help p {
    margin: 0;
}
