/* ====== LAYOUT ====== */
.eci-tz { font-family: Arial, sans-serif; font-size: 11px; }

.eci-tz-row {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.eci-tz-block {
    flex: 1;
    background: #fff;
    border: 1px solid #d7dde5;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 4px rgba(0,0,0,.05);
}

.eci-tz-block-full { width: 100%; }

.eci-tz-block-head {
    font-size: 11.5px;
    font-weight: 700;
    color: #fff;
    background: #2b2f36;
    padding: 6px 12px;
    letter-spacing: .2px;
}

.eci-tz-block-body { padding: 8px 10px; }

.eci-tz-combined-form {
    display: block;
}

.eci-tz-upload-rows {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.eci-tz-upload-row {
    display: grid;
    grid-template-columns: minmax(0, 1.55fr) minmax(190px, 0.9fr) minmax(170px, 0.7fr);
    gap: 10px;
    align-items: end;
}

.eci-tz-field {
    min-width: 0;
}

/* ====== DIRECTORIO ====== */
.eci-tz-dir {
    font-family: 'Courier New', monospace;
    font-size: 9.5px;
    color: #6b7280;
    background: #f3f4f6;
    padding: 3px 6px;
    border-radius: 4px;
    margin-bottom: 6px;
    word-break: break-all;
}

/* ====== INPUTS ====== */
.eci-tz-file-input {
    display: block;
    width: 100%;
    font-size: 11px;
    color: #111827;
    padding: 5px 6px;
    border: 1px solid #d1d5db;
    border-radius: 5px;
    background: #f9fafb;
    cursor: pointer;
    margin-bottom: 4px;
}
.eci-tz-file-input:hover { border-color: #9ca3af; }

.eci-tz-text-input {
    box-sizing: border-box;
    display: block;
    font-size: 11px;
    color: #111827;
    padding: 5px 8px;
    border: 1px solid #d1d5db;
    border-radius: 5px;
    background: #f9fafb;
    width: 100%;
}

.eci-tz-label {
    display: block;
    font-size: 11px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 5px;
}

.eci-tz-inline {
    display: flex;
    gap: 6px;
    align-items: center;
}

.eci-tz-help {
    font-size: 9px;
    color: #6b7280;
    line-height: 1.22;
    margin-top: 4px;
}

.eci-tz-help-block {
    margin-top: 6px;
    margin-bottom: 2px;
}

.eci-tz-submit-row {
    margin-top: 4px;
}

/* ====== PROGRESS BAR ====== */
.eci-tz-progress {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 8px;
}
.eci-tz-progress-track {
    flex: 1;
    height: 12px;
    background: #e5e7eb;
    border-radius: 6px;
    overflow: hidden;
}
.eci-tz-progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #2563eb, #3b82f6);
    border-radius: 6px;
    transition: width .2s;
}
.eci-tz-progress-pct {
    font-size: 10.5px;
    font-weight: 700;
    color: #1f2937;
    min-width: 30px;
    text-align: right;
}

/* ====== BUTTONS ====== */
.eci-tz-btn {
    font-size: 11px;
    font-weight: 600;
    color: #fff;
    background: #2b2f36;
    border: none;
    border-radius: 5px;
    padding: 5px 14px;
    cursor: pointer;
}
.eci-tz-btn:hover { background: #3b4049; }
.eci-tz-btn:disabled { background: #9ca3af; cursor: not-allowed; }
.eci-tz-btn-blue { background: #2563eb; }
.eci-tz-btn-blue:hover { background: #1d4ed8; }

/* ====== MESSAGES ====== */
.eci-tz-msg {
    font-size: 10.5px;
    padding: 5px 8px;
    border-radius: 5px;
    margin-bottom: 8px;
}
.eci-tz-msg-ok { background: #ecfdf5; color: #065f46; border: 1px solid #a7f3d0; }
.eci-tz-msg-err { background: #fef2f2; color: #991b1b; border: 1px solid #fca5a5; }

/* ====== TX RESULT ====== */
.eci-tz-tx-info {
    font-size: 11px;
    color: #374151;
    margin: 8px 0 6px;
    line-height: 1.4;
}
.eci-tz-tx-info strong { color: #1f2937; }

.eci-tz-tx-pre-wrap {
    max-height: 180px;
    overflow: auto;
    border: 1px solid #d1d5db;
    border-radius: 5px;
    background: #f9fafb;
    margin-top: 6px;
}
.eci-tz-tx-pre {
    font-family: 'Courier New', monospace;
    font-size: 9.5px;
    color: #111827;
    margin: 0;
    padding: 6px 8px;
    white-space: pre;
    line-height: 1.35;
}

/* ====== TABLE ====== */
.eci-tz-table-wrap {
    max-height: 180px;
    overflow-y: auto;
    overflow-x: hidden;
}

#eci_tz_uploaded_block {
    scroll-margin-top: 8px;
}

.eci-tz-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 10.5px;
}

.eci-tz-table thead th {
    padding: 5px 8px;
    font-size: 10px;
    color: #9ca3af;
    background: #f9fafb;
    text-align: left;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .3px;
    position: sticky;
    top: 0;
    z-index: 2;
    border-bottom: 1px solid #e5e7eb;
}

.eci-tz-table thead th:nth-child(1) { width: 19%; }
.eci-tz-table thead th:nth-child(2) { width: 12%; }
.eci-tz-table thead th:nth-child(3) { width: 28%; }
.eci-tz-table thead th:nth-child(4) { width: 13%; }
.eci-tz-table thead th:nth-child(5) { width: 12%; }
.eci-tz-table thead th:nth-child(6) { width: 16%; }

.eci-tz-table tbody td {
    padding: 4px 8px;
    color: #111827;
    vertical-align: top;
    border-top: 1px solid #f0f0f0;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.eci-tz-table tbody tr:nth-child(even) td { background: #fafbfc; }
.eci-tz-table tbody tr:hover td { background: #eef5ff; }

.eci-tz-empty-row td {
    text-align: center;
    color: #9ca3af;
    padding: 14px 8px;
    font-style: italic;
}

.eci-tz-action-cell {
    white-space: nowrap;
}

.eci-tz-delete-btn {
    width: 18px;
    height: 18px;
    border: 1px solid #fecaca;
    border-radius: 999px;
    background: #fef2f2;
    color: #b91c1c;
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    padding: 0;
    margin-left: 8px;
    opacity: .9;
    vertical-align: middle;
}

.eci-tz-delete-all-btn {
    margin-left: 6px;
}

.eci-tz-delete-btn:hover {
    opacity: 1;
    background: #fee2e2;
    border-color: #fca5a5;
}

.eci-tz-delete-btn:disabled {
    opacity: .35;
    cursor: wait;
}

/* ====== COMMON ====== */
.eci-tz-mono {
    font-family: 'Courier New', monospace;
    font-size: 9.5px;
    color: #6b7280;
}

.eci-tz-link {
    color: #2563eb;
    text-decoration: none;
    font-weight: 600;
    font-size: 10.5px;
}
.eci-tz-link:hover { text-decoration: underline; color: #1d4ed8; }

@media (max-width: 700px) {
    .eci-tz-row { flex-direction: column; }
}

@media (max-width: 820px) {
    .eci-tz-upload-row {
        grid-template-columns: 1fr;
    }
}
