.cdt-download-browser {
    --cdt-border: #e1e6ec;
    --cdt-muted: #667085;
    --cdt-surface: #ffffff;
    --cdt-surface-soft: #b39b7c;
    --cdt-accent: #b39b7c;
    --cdt-accent-soft: #b39b7c1c;
    width: 100%;
    overflow: hidden;
    border: 1px solid var(--cdt-border);
    border-radius: 14px;
    background: var(--cdt-surface);
    box-shadow: 0 10px 30px rgba(16, 24, 40, 0.06);
    color: #1d2939;
}

.cdt-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 22px 24px;
    border-bottom: 1px solid var(--cdt-border);
    background: linear-gradient(135deg, #ffffff 0%, var(--cdt-surface-soft) 100%);
}

.cdt-title {
    margin: 0;
    font-size: 1.35rem;
    line-height: 1.25;
}

.cdt-subtitle {
    margin: 5px 0 0;
    color: var(--cdt-muted);
    font-size: 0.94rem;
}

.cdt-expand-all {
    flex: 0 0 auto;
    border: 1px solid var(--cdt-border);
    border-radius: 8px;
    padding: 9px 13px;
    background: #fff;
    color: #344054;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}

.cdt-expand-all:hover,
.cdt-expand-all:focus-visible {
    border-color: var(--cdt-accent);
    color: var(--cdt-accent);
    outline: none;
}

.cdt-tree {
    padding: 12px;
}

.cdt-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.cdt-list .cdt-list {
    margin-left: 18px;
    padding-left: 16px;
    border-left: 1px dashed #d0d5dd;
}

.cdt-item {
    margin: 3px 0;
}

.cdt-folder-toggle,
.cdt-file-link {
    display: flex;
    width: 100%;
    min-height: 48px;
    align-items: center;
    gap: 11px;
    border: 0;
    border-radius: 9px;
    padding: 9px 12px;
    background: transparent;
    color: inherit;
    text-align: left;
    text-decoration: none;
    font: inherit;
}

.cdt-folder-toggle {
    cursor: pointer;
}

.cdt-folder-toggle:hover,
.cdt-folder-toggle:focus-visible,
.cdt-file-link:hover,
.cdt-file-link:focus-visible {
    background: var(--cdt-accent-soft);
    outline: none;
}

.cdt-chevron {
    width: 8px;
    height: 8px;
    flex: 0 0 8px;
    border-right: 2px solid #667085;
    border-bottom: 2px solid #667085;
    transform: rotate(-45deg);
    transition: transform 0.18s ease;
}

.cdt-folder[aria-expanded="true"] > .cdt-folder-toggle .cdt-chevron {
    transform: rotate(45deg) translateY(-2px);
}

.cdt-icon {
    position: relative;
    display: inline-block;
    width: 22px;
    height: 22px;
    flex: 0 0 22px;
}

.cdt-icon--folder::before {
    content: '';
    position: absolute;
    inset: 5px 1px 2px;
    border-radius: 3px;
    background: #f6b94b;
}

.cdt-icon--folder::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 10px;
    height: 6px;
    border-radius: 3px 3px 0 0;
    background: #f6b94b;
}

.cdt-icon--file::before {
    content: '';
    position: absolute;
    inset: 1px 3px;
    border: 1.5px solid #98a2b3;
    border-radius: 3px;
    background: #fff;
}

.cdt-icon--file::after {
    content: '';
    position: absolute;
    top: 6px;
    left: 7px;
    width: 8px;
    height: 1.5px;
    background: #98a2b3;
    box-shadow: 0 4px 0 #98a2b3, 0 8px 0 #98a2b3;
}

.cdt-folder-name,
.cdt-file-name {
    font-weight: 600;
}

.cdt-count {
    display: inline-flex;
    min-width: 24px;
    height: 24px;
    align-items: center;
    justify-content: center;
    margin-left: auto;
    border-radius: 999px;
    background: #eef2f6;
    color: #475467;
    font-size: 0.78rem;
    font-weight: 700;
}

.cdt-file-main {
    display: flex;
    min-width: 0;
    flex: 1;
    flex-direction: column;
}

.cdt-file-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cdt-file-meta {
    margin-top: 2px;
    color: var(--cdt-muted);
    font-size: 0.78rem;
}

.cdt-download-label {
    flex: 0 0 auto;
    color: var(--cdt-accent);
    font-size: 0.86rem;
    font-weight: 700;
}

.cdt-empty,
.cdt-message {
    padding: 18px;
    border-radius: 9px;
    background: var(--cdt-surface-soft);
    color: var(--cdt-muted);
}

.cdt-message--error {
    background: #fef3f2;
    color: #b42318;
}

.cdt-message--warning {
    background: #fffaeb;
    color: #b54708;
}

@media (max-width: 600px) {
    .cdt-header {
        align-items: flex-start;
        flex-direction: column;
        gap: 14px;
        padding: 18px;
    }

    .cdt-tree {
        padding: 8px;
    }

    .cdt-list .cdt-list {
        margin-left: 9px;
        padding-left: 9px;
    }

    .cdt-download-label {
        display: none;
    }
}
