/* Tab container styles */
.code-tabs {
    margin-bottom: 1rem;
}

/* Tab button styles */
.tab-buttons {
    display: flex;
    margin-bottom: -1px;
    /* Overlap with content border */
}

.tab-button {
    padding: 8px 16px;
    background-color: #f0f0f0;
    border: 1px solid #ddd;
    border-bottom: none;
    border-radius: 4px 4px 0 0;
    cursor: pointer;
    margin-right: 4px;
    font-size: 14px;
    font-weight: 500;
    opacity: 0.7;
    transition: all 0.2s ease;
}

.tab-button:hover {
    background-color: #e8e8e8;
    opacity: 0.9;
}

.tab-button.active {
    background-color: #ffffff;
    border-bottom: 1px solid #ffffff;
    opacity: 1;
    font-weight: 700;
    box-shadow: 0 -2px 0 #1e88e5;
    color: #1e88e5;
}

/* Tab content styles */
.tab-content {
    display: none;
    border: 1px solid #ddd;
    padding: 0;
    border-radius: 0 0 4px 4px;
}

.tab-content.active {
    display: block;
}

/* Keep code blocks in tabs clean */
.tab-content pre {
    margin: 0;
}

/* Handle dark theme */
.ayu .tab-button,
.coal .tab-button,
.navy .tab-button {
    background-color: #2c2c2c;
    border-color: #444;
    color: #ddd;
}

.ayu .tab-button.active,
.coal .tab-button.active,
.navy .tab-button.active {
    background-color: #333;
    border-bottom-color: #333;
    color: #4d9cf0;
    box-shadow: 0 -2px 0 #4d9cf0;
}

.ayu .tab-content,
.coal .tab-content,
.navy .tab-content {
    border-color: #444;
    background-color: #333;
}
