:root {
    --cses-primary: #2c3e50;
    --cses-success: #27ae60;
    --cses-danger: #e74c3c;
    --cses-info: #3498db;
    --cses-warning: #f39c12;
}

/* Custom tab navigation styles (not available in Bootstrap) */
.nav-tabs-custom {
    border-bottom: none;
    display: flex;
    flex-wrap: nowrap;
    min-height: 50px;
    align-items: flex-end;
}

.nav-link-custom {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    color: #6c757d;
    font-weight: 500;
    font-size: 0.9rem;
    text-decoration: none;
    transition: all 0.2s ease;
    white-space: nowrap;
    margin-bottom: -1px;
    border-radius: 0.5rem 0.5rem 0 0;
    cursor: pointer;
}

.nav-link-custom:hover {
    color: var(--cses-info);
    background-color: rgba(52, 152, 219, 0.05);
    border-bottom-color: rgba(52, 152, 219, 0.3);
    text-decoration: none;
}

.nav-link-custom.active {
    background: white;
    color: var(--cses-info);
    border-bottom-color: var(--cses-info);
    box-shadow: 0 -2px 8px rgba(0,0,0,0.1);
    z-index: 1;
}

.nav-link-custom.active .badge {
    background-color: var(--cses-info);
}

/* Tab scroll wrapper */
.tab-nav-wrapper {
    background: white;
    border-bottom: 1px solid #dee2e6;
}

.tab-nav-scroll {
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    -ms-overflow-style: none;
    scroll-behavior: smooth;
}

.tab-nav-scroll::-webkit-scrollbar {
    display: none;
}

/* Tab navigation gradients */
.tab-nav-gradient {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 20px;
    pointer-events: none;
    z-index: 10;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.tab-nav-gradient-left {
    left: 0;
    background: linear-gradient(90deg, white, transparent);
}

.tab-nav-gradient-right {
    right: 0;
    background: linear-gradient(270deg, white, transparent);
}

.tab-nav-wrapper.show-left .tab-nav-gradient-left,
.tab-nav-wrapper.show-right .tab-nav-gradient-right {
    opacity: 1;
}

/* Custom progress bar styling */
.progress-bar-custom {
    background: linear-gradient(90deg, var(--cses-success), #20c997);
}

/* Custom status indicators */
.status-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    flex-shrink: 0;
}

.status-solved {
    background-color: var(--cses-success);
}

.status-unsolved {
    background-color: var(--cses-danger);
}

/* GitHub button styling */
.github-btn {
    border-color: rgba(255, 255, 255, 0.25);
    color: rgba(255, 255, 255, 0.9);
    transition: all 0.2s ease;
}

.github-btn:hover {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.5);
    color: white;
}

/* Hide default Bootstrap tab styles for custom implementation */
.nav-tabs .nav-link,
.nav-tabs .nav-link.active {
    display: none;
}

/* Mobile responsive adjustments */
@media (max-width: 768px) {
    .nav-tabs-custom {
        padding: 0 0.5rem;
        min-height: 45px;
    }

    .nav-link-custom {
        padding: 0.625rem 1rem;
        font-size: 0.85rem;
    }

    .tab-nav-gradient {
        width: 15px;
    }

    .github-btn .github-text {
        display: none;
    }

    .github-btn {
        padding: 0.375rem 0.5rem;
        min-width: 44px;
    }
}

@media (max-width: 480px) {
    .nav-link-custom .tab-text {
        display: none;
    }

    .nav-link-custom {
        padding: 0.5rem 0.625rem;
        min-width: 40px;
        justify-content: center;
    }

    .nav-link-custom .badge {
        position: absolute;
        top: 0.25rem;
        right: 0.25rem;
        margin: 0;
        font-size: 0.6rem;
        min-width: 16px;
        height: 16px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
}

/* Touch-friendly improvements */
@media (hover: none) and (pointer: coarse) {
    .status-indicator {
        width: 16px;
        height: 16px;
    }
}
