/* Breadcrumb */
.breadcrumb {
    margin: 1rem 0 2rem 0;
    overflow: hidden;
}

.breadcrumb-list {
    display: flex;
    align-items: center;
    list-style: none;
    margin: 0;
    padding: 0;
    font-size: 0.9rem;
    flex-wrap: wrap;
    gap: 0.25rem;
}

.breadcrumb-item {
    display: flex;
    align-items: center;
    max-width: 200px;
    overflow: hidden;
}

/* Don't truncate the last breadcrumb; allow it to grow and wrap */
.breadcrumb-item:last-child {
    max-width: none;
    flex: 1 1 auto;
}

.breadcrumb-item:not(:last-child)::after {
    content: "›";
    margin: 0 0.5rem;
    color: var(--text-tertiary);
    font-weight: bold;
    flex-shrink: 0;
}

.breadcrumb-link {
    color: var(--primary-color);
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
    max-width: 100%;
}

.breadcrumb-link:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

.breadcrumb-current {
    color: var(--text-secondary);
    font-weight: 500;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    overflow-wrap: anywhere;
}

/* Responsive breadcrumbs */
@media (max-width: 768px) {
    .breadcrumb-list {
        font-size: 0.8rem;
    }
    
    .breadcrumb-item {
        max-width: 120px;
    }
    
    /* Keep last item unrestricted on mobile too */
    .breadcrumb-item:last-child {
        max-width: none;
    }
    
    .breadcrumb-item:not(:last-child)::after {
        margin: 0 0.25rem;
    }
}

@media (max-width: 480px) {
    .breadcrumb-item {
        max-width: 80px;
    }
    
    .breadcrumb-list {
        font-size: 0.75rem;
    }
}