.btn-secondary {
    @apply bg-gray-600 text-white font-semibold py-2 px-4 rounded-lg shadow-md hover:bg-gray-700 transition duration-150 ease-in-out;
}

/* Transition for the scroll-to-top button */
#scrollToTopBtn {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: bottom right;
}

/* Ensure the body enables smooth scrolling for the button */
html {
    scroll-behavior: smooth;
}

.chart-container {
    position: relative;
    height: 320px;
    min-height: 250px;
    width: 100%;
}
/* Custom card styling using Tailwind properties */
.card {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s;
}

.card:hover {
    transform: translateY(-2px);
}

.table th, .table td {
    padding: 0.75rem;
    vertical-align: top;
    border-top: 1px solid #dee2e6;
}

.table-striped tbody tr:nth-of-type(odd) {
    background-color: rgba(0, 0, 0, 0.05);
}

.table-bordered th, .table-bordered td {
    border: 1px solid #dee2e6;
}

.thead-dark th {
    color: #fff;
    background-color: #212529;
    border-color: #32383e;
}

/* Quali H2H Mobile: Side-by-side Time Delta & Percent Delta stats boxes */
@media (max-width: 767px) {
    #quali-stats-summary .grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 0.75rem !important;
    }
    #quali-stats-summary .grid > div.col-span-full {
        grid-column: 1 / -1 !important;
    }
    #quali-stats-summary .grid > div:not(.col-span-full) {
        grid-column: span 1 / span 1 !important;
        padding: 0.75rem 0.5rem !important;
    }
    #quali-stats-summary .grid > div:not(.col-span-full) h6 {
        font-size: 0.875rem !important;
        line-height: 1.25rem !important;
        margin-bottom: 0.25rem !important;
    }
    #quali-stats-summary .grid > div:not(.col-span-full) p {
        font-size: 0.75rem !important;
        line-height: 1.15rem !important;
    }
}

/* Quali H2H PC: Sortable column header hover in light mode stays light */
#results-table th.cursor-pointer:hover {
    background-color: #e2e8f0 !important;
    color: #0f172a !important;
}

html.dark #results-table th.cursor-pointer:hover,
body.dark-mode #results-table th.cursor-pointer:hover {
    background-color: #334155 !important;
    color: #ffffff !important;
}