/* static/css/player_search_themed.css */
/* Styles specific to player_search.html, adapted for the new theme. */
/* Base styles (body, typography, nav, footer, container) are inherited from best_matchups_redesign.css */

/* === MAIN LAYOUT === */
main {
    flex: 1 0 auto;
    /* padding: 2rem 0; /* Vertical padding only, horizontal handled by .bm-container or specific views */
    /* For initial view, we want full control */
}

.ps-initial-view {
    display: flex;
    flex-direction: column;
    justify-content: center; /* Vertically center content */
    align-items: center; /* Horizontally center content */
    min-height: calc(100vh - 73px); /* Take up full screen minus footer */
    text-align: center;
    padding: 2rem 20px; /* Uniform padding */
    padding-bottom: 35vh; /* Extra spacing so footer isn't visible on load */
    background: #0D1117; /* Slightly darker, clean background */
    /* Optional: Add a subtle gradient for a premium feel */
    /* background: linear-gradient(180deg, #10141a 0%, #0D1117 100%); */
}

/* .title-section styling is largely inherited from best_matchups_redesign.css */
/* Apply to .ps-initial-view__title if the generic .title-section is too broad */
.ps-initial-view .ps-initial-view__title h1 { /* More specific selector */
    font-size: 3.5rem; /* Significantly larger for emphasis */
    color: #E6EDF3; /* Brighter white for title */
    font-weight: 700;
    margin-bottom: 0.75rem; /* Space between title and subtitle */
}
.ps-initial-view .ps-initial-view__title p {  /* More specific selector */
    font-size: 1.25rem; /* Slightly larger subtitle */
    color: #7D8590; /* Softer grey for subtitle */
    max-width: 55ch; /* Control line length for readability */
    margin-bottom: 2.5rem; /* More space before search bar */
}

.ps-initial-search__form-container {
    max-width: 750px; /* Wider search bar */
    width: 100%;
    box-shadow: 0 8px 24px rgba(0,0,0,0.3); /* More pronounced shadow for depth */
    border-radius: 12px; /* Rounded corners for the container if needed, or apply to input directly */
}

.ps-initial-search__form-container .input-group {
    width: 100%;
}

.ps-initial-search__form-container .form-control.typeahead.player-search-input {
    background-color: #1C2128; /* Slightly lighter input background for contrast */
    border: 1px solid #30363D; /* Standard border */
    color: #E6EDF3; /* Bright text color */
    font-size: 1.35rem; /* Significantly larger font size */
    height: auto;
    padding: 1rem 1.5rem; /* Much larger padding for a taller, more clickable input */
    border-radius: 10px; /* More rounded corners for a modern feel */
    transition: background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
    line-height: 1.5; /* Ensure text is vertically centered if padding makes it too tall */
}

.ps-initial-search__form-container .form-control.typeahead.player-search-input:focus {
    border-color: #388BFD; /* Brighter blue focus color */
    background-color: #161B22; /* Darken background on focus */
    box-shadow: 0 0 0 0.25rem rgba(56, 139, 253, 0.35); /* Softer, larger focus ring */
}

.ps-initial-search__form-container .form-control.typeahead.player-search-input::placeholder {
    color: #7D8590; /* Softer placeholder text */
    opacity: 1; /* Ensure placeholder is fully visible */
}

/* === NAVBAR SEARCH (if full_name is present) === */
.nav-search-container {
    flex: 1;
    max-width: 300px;
    min-width: 180px;
    margin-left: 0.5rem; /* Bring search bar closer to logo */
    margin-right: 22rem;
}
.nav-search-container .input-group { /* Targeting Bootstrap's class */
    width: 100%;
}
.nav-search-container .input-group .input-group-text {
    background-color: #161B22;
    border: 1px solid #30363D;
    border-right: none;
    color: #8B949E;
    padding: 0.45rem 0.75rem;
    border-top-left-radius: 6px;
    border-bottom-left-radius: 6px;
    font-size: 0.9rem;
}
.nav-search-container .form-control.typeahead.player-search-input {
    background-color: #161B22;
    border: 1px solid #30363D;
    color: #C9D1D9; /* Theme primary text */
    font-size: 0.9rem;
    height: auto;
    padding: 0.45rem 0.75rem;
    border-radius: 6px;
    transition: background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}
.nav-search-container .form-control.typeahead.player-search-input:focus {
    border-color: #58A6FF; /* Theme accent */
    background-color: #0D1117; /* Darker on focus */
    box-shadow: 0 0 0 0.2rem rgba(88, 166, 255, 0.25); /* Theme focus ring */
}
.nav-search-container .form-control.typeahead.player-search-input::placeholder {
    color: #8B949E;
    opacity: 0.7;
}

/* Ensure Typeahead wrapper stretches full width so menu aligns to input */
.twitter-typeahead {
    width: 100%;
    position: relative;
}

/* Keep hint text visible and prevent it covering input text */
.tt-input {
    position: relative;
    z-index: 1;
}
.tt-hint {
    color: #8B949E;
    z-index: 0;
    /* Ensure hint aligns with the larger input text if Typeahead uses it visibly */
    font-size: 1.35rem; /* Match the main input's font size */
    padding: 1rem 1.5rem; /* Match the main input's padding */
    line-height: 1.5; /* Match the main input's line-height */
}

/* === TYPEAHEAD DROPDOWN (Shared by both search inputs) === */
.tt-menu { /* This is a Typeahead class */
    background-color: #1C2128; /* Match new input background for consistency */
    border: 1px solid #388BFD; /* Use accent color for border, or #30363D for subtle */
    border-top: none; /* Keep this if input has bottom border */
    border-radius: 0 0 10px 10px; /* Match new input's border-radius for bottom */
    box-shadow: 0 8px 24px rgba(0,0,0,0.3); /* Consistent shadow */
    top: 100%;
    margin-top: 1px; /* Align closely under the input */
    width: 100%; /* Ensure it matches input width */
    max-height: 400px; /* Increased max-height for potentially taller items */
    overflow-y: auto;
    z-index: 1050; /* Ensure it's above other content */
}
.tt-suggestion { /* This is a Typeahead class */
    padding: 0.85rem 1.5rem; /* Increased padding for taller rows */
    color: #E6EDF3; /* Match new input text color */
    font-size: 1.1rem; /* Increased font size for suggestion text */
    cursor: pointer;
    border-bottom: 1px solid #30363D; /* Subtle separator */
    transition: background-color 0.15s ease, color 0.15s ease;
    line-height: 1.4; /* Adjust line height for new font size and padding */
}
.tt-suggestion:last-child {
    border-bottom: none;
}
.tt-suggestion:hover,
.tt-suggestion.tt-cursor { /* tt-cursor is Typeahead's class for highlighted/focused item */
    background-color: #388BFD; /* Theme accent blue for hover/selection */
    color: #FFFFFF; /* White text on hover/selection */
}
.tt-dataset .tt-empty-message, /* Ensure specificity for Typeahead classes */
.tt-dataset .tt-pending-message {
    padding: 0.85rem 1.5rem; /* Match suggestion padding */
    color: #7D8590; /* Softer text color */
    font-size: 1rem; /* Adjusted font size */
    text-align: center;
    font-style: italic;
}

/* === TABLES === */
.ps-table-wrapper {
    width: 100%;
    overflow-x: auto;
}
.ps-table-wrapper::-webkit-scrollbar {
    height: 8px;
    background-color: #0D1117;
}
.ps-table-wrapper::-webkit-scrollbar-thumb {
    background-color: #30363D;
    border-radius: 4px;
}
.ps-table-wrapper::-webkit-scrollbar-thumb:hover {
    background-color: #484F58;
}

.ps-table { /* Applied to .performance-table */
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.85rem;
}
.ps-table th,
.ps-table td {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #21262D;
    vertical-align: middle;
    white-space: nowrap; /* Prevent wrapping in table cells by default */
}
.ps-table th {
    font-family: 'Outfit', sans-serif;
    font-weight: 600;
    color: #C9D1D9;
    background-color: rgba(13, 17, 23, 0.5);
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
}
.ps-table tbody tr:hover {
    background-color: rgba(88, 166, 255, 0.03); /* Very subtle hover */
}
.ps-table td {
    color: #C9D1D9;
}
.ps-table td:first-child {
    font-weight: 500;
    color: #F0F6FC;
}

/* Game Logs and legacy tables without the ps-table class */
.performance-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.85rem;
}
.performance-table th,
.performance-table td {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #21262D;
    vertical-align: middle;
    white-space: nowrap;
}
.performance-table thead tr {
    background-color: rgba(13, 17, 23, 0.5);
}
.performance-table th {
    font-family: 'Outfit', sans-serif;
    font-weight: 600;
    color: #C9D1D9;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
}
.performance-table tbody tr:hover {
    background-color: rgba(88, 166, 255, 0.03);
}
.performance-table td {
    color: #C9D1D9;
}
.performance-table td:first-child {
    font-weight: 500;
    color: #F0F6FC; /* Brighter for first column data */
}

/* DataTables specific overrides */
/* These selectors target Bootstrap 5 classes used by DataTables */
.dataTables_wrapper .dataTables_paginate .paginate_button {
    background: #0D1117; /* Darker background for pagination buttons */
    border: 1px solid #30363D; /* Theme border */
    color: #8B949E !important; /* Important to override Bootstrap default */
    border-radius: 4px;
    margin: 0 0.15em; /* Tighter spacing */
    padding: 0.35em 0.7em; /* Smaller padding */
    font-size: 0.8rem;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}
.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
    background: #161B22; /* Slightly lighter on hover */
    border-color: #58A6FF; /* Accent border on hover */
    color: #58A6FF !important;
}
.dataTables_wrapper .dataTables_paginate .paginate_button.current,
.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
    background: #58A6FF; /* Accent blue for current page */
    border-color: #58A6FF;
    color: #FFFFFF !important;
    box-shadow: none;
}
.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_length label, /* For "Show X entries" */
.dataTables_wrapper .dataTables_filter label { /* For "Search:" */
    color: #8B949E; /* Theme secondary text */
    font-size: 0.8rem;
    padding-top: 0.5em; /* Align with pagination */
}
.dataTables_wrapper .dataTables_length select,
.dataTables_wrapper .dataTables_filter input {
    background-color: #0D1117; /* Dark background for inputs */
    border: 1px solid #30363D; /* Theme border */
    color: #C9D1D9; /* Theme primary text */
    border-radius: 4px;
    padding: 0.3rem 0.5rem; /* Smaller padding */
    margin: 0 0.25rem; /* Adjust margin */
    font-size: 0.85rem;
}
.dataTables_wrapper .dataTables_length select:focus,
.dataTables_wrapper .dataTables_filter input:focus {
    border-color: #58A6FF; /* Theme accent on focus */
    box-shadow: 0 0 0 0.2rem rgba(88, 166, 255, 0.25); /* Theme focus ring */
}

/* Load More Button */
.load-more-container {
    display: flex;
    justify-content: center;
    margin-top: 1rem;
}
.load-more-btn { /* Adapting to new button style from best_matchups_redesign.css */
    background-color: #1F6FEB; /* Primary action blue from theme */
    color: #FFFFFF;
    font-family: 'Outfit', sans-serif;
    font-size: 0.9rem;
    font-weight: 500;
    padding: 0.5em 1.5em; /* Wider padding */
    border-radius: 6px;
    border: 1px solid #1F6FEB; /* Matching border */
    text-decoration: none;
    transition: background-color 0.2s ease-in-out, border-color 0.2s ease-in-out;
    cursor: pointer;
}
.load-more-btn:hover {
    background-color: #388BFD; /* Lighter blue on hover */
    border-color: #388BFD;
}

/* === CHARTS AND VISUALIZATIONS === */
.ps-chart-container { /* Generic wrapper for charts */
    padding: 1rem 0; /* Add some padding around charts */
}

/* Percentile Chart (#percentileChart) */
#percentileChart.ps-percentile-chart { /* ID from HTML, class from HTML */
    display: flex;
    justify-content: space-around; /* Distribute bars evenly */
    gap: 1rem; /* Gap between bars */
    flex-wrap: wrap;
    background-color: #161B22; /* Dark background for chart area */
    padding: 1rem;
    border-radius: 6px;
    border: 1px solid #21262D; /* Theme darker border */
}
.stat-bar { /* From original CSS, adapt to theme */
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 40px; /* Slightly wider bars */
}
.percent-label { /* Text above the bar e.g., "85th" */
    font-weight: 600;
    font-size: 0.9rem;
    color: #F0F6FC; /* Theme heading color */
    margin-bottom: 0.35rem;
}
.ordinal-suffix { /* For "th", "st", "nd" */
    font-size: 0.6em;
    vertical-align: super;
    margin-left: 1px;
    color: #8B949E; /* Theme secondary text */
}
.bar-container {
    width: 100%;
    height: 180px; /* Adjust height as needed */
    background-color: #32373f; /* Darker background for bar track */
    border-radius: 4px;
    overflow: hidden;
    position: relative;
}
.bar-fill { /* Colors are set inline via JS based on percentile value */
    width: 100%;
    position: absolute;
    bottom: 0;
    border-radius: 4px 4px 0 0;
    transition: height 0.5s ease-out, background-color 0.3s ease;
}
.stat-bar .stat-label { /* Text below the bar e.g., "1+ Hit" */
    white-space: nowrap;
    margin-top: 0.5rem;
    font-size: 0.75rem;
    color: #8B949E; /* Theme secondary text */
    text-align: center;
    line-height: 1.2;
}

/* Circle Graphs (Last 10 Games Hit Rates) */
.circle-graph-group { /* Class from HTML */
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem; /* Space between circles */
    margin-top: 1rem; /* Space above this section if it's distinct */
    padding-top: 1rem; /* Padding if it has a border-top */
    /* border-top: 1px solid #21262D; /* Optional: Theme separator */
}
.circle-graph-item { /* Class from HTML */
    width: 90px; /* Slightly smaller */
    text-align: center;
}
.circle-graph-item .position-relative { /* Bootstrap class */
    width: 70px; /* Smaller SVG container */
    height: 70px;
    margin: 0 auto 0.25rem auto; /* Adjust margin */
}
.circle-graph-item svg path { stroke-width: 3.5; } /* Adjust stroke width */
.circle-graph-item svg path:first-child { stroke: #21262D; } /* Darker background ring to match theme */
.circle-graph-item .fill-circle {
    stroke: #2d7ff9; /* Theme accent for the fill */
    stroke-dasharray: var(--fill), 100; /* Dynamic fill based on percentage */
    stroke-linecap: round; /* Smoother edges */
    animation: fillCircle 0.8s ease forwards;
}

.circle-graph-item .circle-percent { /* Text inside circle */
    font-size: 0.9rem; /* Smaller percentage text */
    font-weight: 600;
    color: #F0F6FC; /* Theme heading color */
}
.circle-graph-item .hit-rate-summary { /* Text like "7 of 10" */
    font-size: 0.75rem;
    color: #8B949E; /* Theme secondary text */
    margin-top: 0.15rem;
}
.circle-graph-item .circle-graph-label { /* Prop name like "1+ Total Bases" */
    font-size: 0.8rem;
    font-weight: 500;
    color: #C9D1D9; /* Theme primary text */
    margin-bottom: 0.2rem;
    white-space: nowrap;
}

/* Animation for the circle fill */
@keyframes fillCircle {
    from { stroke-dasharray: 0, 100; }
    to { stroke-dasharray: var(--fill), 100; }
}


/* Prop Performance Section */
.ps-filter-box {
    background-color: #14171b;
    border: 1px solid #21262D;
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 1.5rem;
}
.ps-chart-box {
    background-color: #14171b;
    border: 1px solid #21262D;
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 0.5rem;
}

.ps-prop-selector-container { /* Replaces .prop-slider-container */
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem; /* Consistent gap */
}
.ps-prop-selector__control { /* Replaces .prop-control */
    display: flex;
    align-items: center;
    gap: 0.5rem; /* Space between label and select */
}
.ps-prop-selector__control label { /* Targets .form-label */
    color: #8B949E; /* Theme secondary text */
    font-size: 0.85rem;
    font-weight: 500;
    white-space: nowrap;
    margin-bottom: 0; /* Override Bootstrap */
}
.ps-prop-selector__select { /* Targets .form-select */
    background-color: #161B22; /* Theme card-like background for select */
    border: 1px solid #30363D; /* Theme border */
    color: #C9D1D9; /* Theme primary text */
    border-radius: 4px;
    padding: 0.35rem 0.6rem; /* Adjust padding */
    font-size: 0.85rem;
    min-width: 100px; /* Ensure dropdowns have some width */
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%238B949E' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e"); /* Themed dropdown arrow */
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.ps-prop-selector__select:focus {
    border-color: #58A6FF;
    box-shadow: 0 0 0 0.2rem rgba(88, 166, 255, 0.25); /* Theme focus ring */
    outline: none;
}
.ps-prop-selector__slider-control { /* Replaces .slider-control */
    flex: 1 1 100%; /* Take full width on small screens */
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 200px; /* Ensure slider has space */
}
#threshold-slider { /* Keep ID for JS, style with class or ID */
    accent-color: #58A6FF; /* Theme accent for modern browsers */
    flex-grow: 1;
    height: 4px; /* Slimmer slider */
    background: #30363D; /* Track color */
    border-radius: 2px;
    cursor: pointer;
    /* Webkit specific for thumb track */
    -webkit-appearance: none;
}
#threshold-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #58A6FF; /* Theme accent */
    border: 2px solid #161B22; /* Thumb border matching card bg */
    cursor: pointer;
    margin-top: -6px; /* Align thumb with track */
}
#threshold-slider::-moz-range-thumb {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #58A6FF;
    border: 2px solid #161B22;
    cursor: pointer;
}
#threshold-value { /* Text displaying slider value */
    color: #F0F6FC;
    font-weight: 600;
    font-size: 0.9rem;
    background-color: #1F6FEB; /* Blue accent for value */
    padding: 0.15em 0.4em;
    border-radius: 4px;
    min-width: 2em; /* Ensure space for multi-digit numbers */
    text-align: center;
}

/* Prop Pulse Chart Card */
.ps-pulse-chart-card { /* Replaces .pulse-chart-card, which is a .card.mb-4 */
    /* This is a .card from Bootstrap, so we need to override its styles if it's not removed from HTML */
    /* Assuming it's within a .ps-content-block, it might not need much if it's just a Chart.js canvas wrapper */
    background-color: #0D1117; /* Darker background for this specific card */
    border: 1px solid #21262D; /* Darker border */
    border-radius: 6px; /* Consistent radius */
    margin-bottom: 0; /* If it's the last item in a ps-content-block */
}
.ps-pulse-chart-card .card-body { padding: 1rem; } /* Adjust padding */

.prop-history-header { /* From original, adapt to theme */
    display: flex;
    justify-content: space-between; /* Align items */
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1rem;
}
.prop-header-left { flex-grow: 1; }
#prop-player-name.card-title { /* Bootstrap class, make more specific or use new class */
    font-size: 1.2rem;
    color: #F0F6FC; /* Theme heading */
    margin-bottom: 0.15rem;
    border-bottom: none; /* Remove card-title default underline */
    font-weight: 900;
}
#prop-player-name.card-title::after { display: none; } /* Remove card-title default underline */

#prop-history-title.prop-history-title { /* Original class */
    font-size: 1.1rem;
    color: #8B949E; /* Theme secondary text */
    font-weight: 500;
    margin-bottom: 0;
}
#hit-rate.hit-rate-box { /* Original class */
    background: #161B22; /* Theme card-like bg */
    border: 1px solid #30363D; /* Theme border */
    border-radius: 6px;
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    column-gap: 1rem;
    row-gap: 0.25rem;
    text-align: center;
}
#hit-rate .label {
    font-size: 0.75rem;
    color: #8B949E;
    text-transform: uppercase;
}

#hit-rate .value {
    font-size: 0.95rem;
    color: #F0F6FC;
    font-weight: 600;
}

.prop-logo-box img { /* Vynta logo in prop chart */
    width: 35px; height: 35px; opacity: 0.7;
}

#propPulseChart { /* Chart.js canvas */
    height: 250px; /* Adjust height as needed */
    background: transparent; /* Let card background show */
    padding: 0;
    margin-top: 0.5rem;
}

/* Game Log Section */
.ps-game-log__table { /* Targets #gameLogTable, which has .ps-table */
    /* .ps-table styles already apply */
    min-width: 650px; /* Allow horizontal scroll on small screens */
}
.ps-game-log__table tr.selected { /* JS adds 'selected' */
    background-color: rgba(88, 166, 255, 0.1) !important; /* More prominent selection */
}
.ps-game-log__table tr.range-selected {
    background-color: rgba(88, 166, 255, 0.05) !important; /* Subtle range selection */
}

/* Game Range Summary */
#game-range-summary.ps-game-range-summary { /* Targets #game-range-summary */
    position: fixed; /* Keep it sticky */
    bottom: 0; left: 0; right: 0;
    background: #0D1117; /* Dark background, slightly transparent to match theme */
    border-top: 1px solid #58A6FF; /* Accent border */
    padding: 0.75rem 1rem; /* Adjust padding */
    box-shadow: 0 -2px 10px rgba(0,0,0,0.3);
    color: #C9D1D9; /* Theme primary text */
    z-index: 1000; /* Ensure it's above other content */
    display: none; /* Initially hidden by JS */
}
#game-range-summary .summary-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}
#game-range-summary .summary-title {
    font-size: 1rem;
    font-weight: 600;
    color: #F0F6FC; /* Theme heading */
}
#game-range-summary .clear-btn {
    background-color: #484F58; /* Darker grey button */
    border: 1px solid #484F58;
    color: #C9D1D9; /* Theme primary text */
    padding: 0.25em 0.75em;
    font-size: 0.8rem;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
#game-range-summary .clear-btn:hover {
    background-color: #58A6FF; /* Theme accent on hover */
    color: #FFFFFF;
    border-color: #58A6FF;
}
/* Table within summary bar */
#game-range-summary table th,
#game-range-summary table td {
    padding: 0.5rem;
    font-size: 0.8rem;
    color: #C9D1D9;
    white-space: nowrap;
}
#game-range-summary table th {
    background-color: rgba(88, 166, 255, 0.05); /* Very subtle header bg */
    color: #F0F6FC; /* Theme heading */
    font-weight: 500;
}

/* Loading Spinner */
.loading-spinner {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1051;
}
.loading-spinner .spinner-border { /* Bootstrap class */
    border-color: #58A6FF; /* Theme accent */
    border-right-color: transparent;
    width: 3rem;
    height: 3rem;
}

/* === RESPONSIVE ADJUSTMENTS === */
@media (max-width: 992px) { /* Tablet and smaller */
    .ps-player-header {
        flex-direction: column;
        align-items: stretch;
    }
    .ps-player-header__details {
        width: 100%;
    }
    .ps-player-header__l5-box {
        width: 100%;
        margin-top: 0.5rem; /* smaller gap when stacked */
        flex: 0 0 auto;    /* prevent min-height from flex-basis */
    }

    #percentileChart.ps-percentile-chart {
        gap: 0.75rem; /* Smaller gap for percentile bars */
    }
    .stat-bar {
        width: 45px; /* Adjust bar width */
    }
    .bar-container {
        height: 140px; /* Adjust bar height */
    }
}

@media (max-width: 768px) { /* Mobile */
    main { padding: 1rem 10px; } /* Reduce main padding */

    .ps-initial-view .title-section h1 { font-size: 2.2rem; }
    .ps-initial-view .title-section p { font-size: 1rem; }
    .ps-initial-search__form-container { max-width: 100%; padding: 0 10px; }

    .ps-player-header { padding: 1rem; gap: 1rem; margin-bottom: 1.5rem;}
    .ps-player-header__details { gap: 0.75rem; }
    .ps-player-header__name { font-size: 1.6rem; }
    .ps-player-header__meta { font-size: 0.85rem; }
    .ps-player-header__team-badge { font-size: 1rem; padding: 0.35em 0.6em;}

    .ps-player-header__bio { font-size: 0.8rem; }
    .ps-player-header__l5-box { padding: 0.6rem 0.8rem; }
    .ps-player-header__l5-title { font-size: 0.9rem; }
    .ps-player-header__l5-stats { font-size: 0.75rem; }

    .ps-content-block { padding: 1rem; margin-bottom: 1.5rem; }
    .ps-content-block__title { font-size: 1.25rem; }
    .ps-content-block__description { font-size: 0.85rem; }

    .ps-table th, .ps-table td { padding: 0.5rem 0.75rem; font-size: 0.8rem; }
    .ps-table th { font-size: 0.7rem; }

    .dataTables_wrapper .dataTables_paginate .paginate_button { padding: 0.3em 0.6em; font-size: 0.75rem;}
    .dataTables_wrapper .dataTables_info,
    .dataTables_wrapper .dataTables_length label,
    .dataTables_wrapper .dataTables_filter label { font-size: 0.75rem; }
    .dataTables_wrapper .dataTables_length select,
    .dataTables_wrapper .dataTables_filter input { font-size: 0.8rem; padding: 0.25rem 0.4rem;}

    .ps-filter-box {
        padding: 0.75rem;
    }
    .ps-chart-box {
        padding: 0.75rem;
    }

    .ps-prop-selector-container {
        flex-direction: column; /* Stack controls vertically */
        align-items: stretch; /* Make controls full width */
        gap: 0.75rem;
    }
    .ps-prop-selector__control {
        justify-content: space-between; /* Space out label and select */
    }
    .ps-prop-selector__select {
        flex-grow: 1; /* Allow select to take available space */
    }

    #percentileChart.ps-percentile-chart {
        gap: 0.5rem; /* Smaller gap for percentile bars */
        padding: 0.5rem;
    }
    .stat-bar { width: 40px; } /* Adjust bar width */
    .bar-container { height: 120px; } /* Adjust bar height */
    .percent-label { font-size: 0.8rem; }
    .stat-bar .stat-label { font-size: 0.65rem; }

    .circle-graph-group { gap: 1.5rem; }
    .circle-graph-item { width: 80px; }
    .circle-graph-item .position-relative { width: 60px; height: 60px; }
    .circle-graph-item .circle-percent { font-size: 0.8rem; }
    .circle-graph-item .circle-graph-label { font-size: 0.7rem; }

    #game-range-summary.ps-game-range-summary { padding: 0.5rem; }
    #game-range-summary .summary-title { font-size: 0.9rem; }
    #game-range-summary table th, #game-range-summary table td { font-size: 0.7rem; padding: 0.3rem; }
    #game-range-summary .clear-btn { font-size: 0.75rem; padding: 0.2em 0.6em; }
}

@media (max-width: 600px) {
    .ps-player-header__l5-box {
        display: none; /* Hide last 5 games on small screens */
    }
}

@media (max-width: 480px) { /* Smaller Mobiles */
    main { padding: 1rem 5px; }
    .ps-initial-view .title-section h1 { font-size: 1.8rem; }
    .ps-initial-view .title-section p { font-size: 0.9rem; }

    .ps-player-header__name { font-size: 1.4rem; }
    .ps-player-header__team-badge { font-size: 0.9rem; padding: 0.3em 0.6em; }

    .ps-table th, .ps-table td { padding: 0.4rem 0.5rem; font-size: 0.75rem; }
    .ps-table th { font-size: 0.65rem; }

    /* Further reduce padding/font for very small screens if necessary */
    .ps-prop-selector__control label { font-size: 0.8rem; }
    .ps-prop-selector__select { font-size: 0.8rem; padding: 0.3rem 0.5rem;}
    #threshold-value { font-size: 0.8rem; }
}

/* === PLAYER VIEW === */
.ps-player-view .bm-container.ps-container { /* bm-container provides max-width, ps-container for specifics */
    padding-top: 1.5rem; /* Add some space below nav if not already handled by main's padding */
}

/* Container wrapping the player header, season stats, percentiles
   and last-10 hit rates for a unified layout */
.ps-overview-container {
    width: 100%;
    max-width: none;
    display: flex;
    flex-direction: column;
    margin-bottom: 2rem;
    gap: 1.75rem;
    background-color: #161B22; /* Unified card background */
    border: 1px solid #30363D; /* Unified card border */
    border-radius: 8px;       /* Unified card radius */
    padding: 1.5rem;          /* Inner spacing */
    box-shadow: 0 4px 12px rgba(0,0,0,0.15); /* Consistent shadow */
}

/* Remove individual card styling inside the overview */
.ps-overview-container .ps-player-header,
.ps-overview-container .ps-content-block {
    background: none;
    border: none;
    box-shadow: none;
    margin-bottom: 0;
    padding: 0;
}

/* Container wrapping recent performance and split tables */
.ps-performance-card {
    width: 100%;
    max-width: none;
    display: flex;
    flex-direction: column;
    gap: 1.75rem;
    margin-bottom: 2rem;
    background-color: #161B22;
    border: 1px solid #30363D;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.ps-performance-card .ps-content-block {
    background: none;
    border: none;
    box-shadow: none;
    margin-bottom: 0;
    padding: 0;
}

.ps-performance-card .ps-content-block + .ps-content-block {
    margin-top: 1.75rem;
}

/* Container wrapping today's game info, prop filters, prop chart
   and game logs for a unified layout */
.ps-game-card {
    width: 100%;
    max-width: none;
    display: flex;
    flex-direction: column;
    gap: 1.75rem;
    margin-bottom: 2rem;
    background-color: #161B22;
    border: 1px solid #30363D;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.ps-game-card .ps-content-block,
.ps-game-card .ps-prop-selector-container,
.ps-game-card .ps-pulse-chart-card,
.ps-game-card .recent-performance-container,
.ps-game-card .no-data-alert {
    background: none;
    border: none;
    box-shadow: none;
    margin-bottom: 0;
    padding: 0;
}

.ps-game-card .ps-prop-selector-container {
    margin-bottom: 0;
}

.ps-game-card .ps-pulse-chart-card {
    margin-bottom: 0;
}

.ps-alert { /* For messages like 'No data available' or general alerts */
    background-color: #161B22; /* Theme card background */
    border: 1px solid #30363D; /* Theme border */
    color: #8B949E; /* Softer text for info */
    border-radius: 6px; /* Consistent radius */
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem; /* Consistent spacing */
}
/* Override for Bootstrap's .alert-warning if used, or create a .ps-alert--warning */
.alert.alert-warning.ps-alert {
    background-color: rgba(187, 134, 252, 0.1); /* Purple-ish warning, modern */
    border-color: rgba(187, 134, 252, 0.3);
    color: #BB86FC; /* Purple text */
}

@media (max-width: 576px) {
    .ps-alert {
        font-size: 0.9rem;
        padding: 0.75rem 1rem;
    }
    .premium-lock .premium-overlay {
        font-size: 0.9rem;
        padding: 0.75rem;
        width: 100%;
        margin: 0;
        flex-direction: column;
    }
}

/* === PLAYER HEADER === */
.ps-player-header {
    background-color: #161B22; /* Theme card background */
    border: 1px solid #30363D; /* Theme border */
    border-radius: 8px; /* Theme radius */
    padding: 1.5rem; /* Theme padding */
    margin-bottom: 2rem; /* Consistent spacing */
    box-shadow: 0 4px 12px rgba(0,0,0,0.15); /* Theme shadow */
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1.25rem;
    width: 100%;
    max-width: none;
}
.ps-player-header__details {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 1.25rem;
    flex-grow: 1;
}
.ps-player-header__team-badge { /* .team-badge is styled in best_matchups_redesign.css */
    font-size: 1.1rem; /* Adjusted size */
    padding: 0.7em 0.9em;
    height: fit-content; /* Fit to content */
    /* color: #FFFFFF; /* Ensure text is white or use team_text_colors if available */
}
.ps-player-header__name-details {
    flex-grow: 1;
}
.ps-player-header__name {
    font-family: 'Outfit', sans-serif;
    font-size: 2rem; /* Slightly reduced from original for balance */
    font-weight: 700;
    color: #F0F6FC; /* Theme heading color */
    margin: 0 0 0.2rem 0; /* Reduced bottom margin */
    line-height: 1.2;
}
.ps-player-header__meta {
    font-size: 0.9rem; /* Slightly smaller meta text */
    color: #8B949E; /* Theme secondary text color */
    margin: 0;
    line-height: 1.5;
}
.ps-player-header__meta-item:not(:last-child)::after {
    content: "•";
    margin: 0 0.4em; /* Adjust spacing */
    color: #484F58; /* Theme dimmer separator */
}

.ps-player-header__bio-and-l5 {
    display: contents;
    padding-top: 0;
    border-top: none;
}
.ps-player-header__bio {
    font-size: 0.85rem; /* Slightly smaller bio text */
    color: #C9D1D9; /* Theme primary text */
    display: grid;
    grid-template-columns: auto 1fr; /* Label and value */
    gap: 0.2rem 0.6rem; /* Adjust gap */
    margin-top: 1rem; /* Nudge down to align with name */
    align-items: baseline;
    flex: 2 1 300px; /* Bio takes more space, min width 300px */
}
.ps-player-header__bio dt {
    font-weight: 500; /* Less heavy label */
    color: #8B949E; /* Theme secondary color for labels */
}
.ps-player-header__bio dd {
    margin: 0;
    color: #C9D1D9; /* Theme primary text for values */
}

.ps-player-header__l5-box {
    background-color: #161B22; /* Theme darker inner box */
    border: 1px solid #21262D; /* Darker border */
    border-radius: 6px; /* Consistent radius */
    padding: 0.75rem 1rem;
    flex: 1 1 150px; /* Allow L5 box to take space, min width 280px */
    max-width: 100%; /* Allow full width on small screens if it wraps */
}
.ps-player-header__l5-title {
    font-size: 0.95rem; /* Slightly smaller title */
    font-weight: 600;
    color: #F0F6FC; /* Theme heading color */
    margin: 0 0 0.6rem 0; /* Adjust margin */
    border-bottom: 1px solid #21262D;
    padding-bottom: 0.45rem;
}
.ps-player-header__l5-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(60px, 1fr));
    gap: 0.2rem 0.4rem; /* tighter spacing to keep one line */
    font-size: 0.8rem;
}
.ps-player-header__l5-stat-item {
    color: #C9D1D9;
    white-space: nowrap;
}
.ps-player-header__l5-label {
    font-weight: 500;
    color: #8B949E;
    margin-right: 0.25em;
}

/* === CONTENT BLOCKS (replaces .recent-performance-container) === */
.ps-content-block {
    background-color: #161B22; /* Theme card background */
    border: 1px solid #30363D; /* Theme border */
    border-radius: 8px; /* Theme radius */
    padding: 1.25rem; /* Slightly less padding than main matchup blocks */
    margin-bottom: 1.75rem; /* Consistent spacing */
    box-shadow: 0 4px 12px rgba(0,0,0,0.15); /* Theme shadow */
}

/* Give extra breathing room when these blocks stack with legacy
   .recent-performance-container sections */
.ps-content-block + .recent-performance-container,
.recent-performance-container + .recent-performance-container {
    margin-top: 0.5rem;
}

/* Season stats specific block */
.ps-season-stats-block {
    width: 100%;
    max-width: none;
}

.ps-content-block__title { /* Applied to h2 in the new HTML */
    font-size: 1.4rem; /* Consistent section title size */
    font-weight: 600;
    color: #F0F6FC; /* Theme heading color */
    margin-bottom: 1rem;
    padding-bottom: 0.6rem;
    border-bottom: 1px solid #21262D; /* Theme separator */
}
.ps-content-block__description { /* For paragraphs directly under titles in content blocks */
    font-size: 0.9rem;
    color: #8B949E;
    margin-bottom: 1.25rem;
    line-height: 1.5;
    max-width: 160ch; /* For readability of longer descriptions */
}
.ps-content-block__no-data { /* For 'no data available' messages within blocks */
    color: #8B949E;
    text-align: center;
    padding: 1.5rem 0; /* More padding for no data messages */
    font-style: italic;
}

/* === TODAY'S GAME SECTION === */
.game-details-rows {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.game-info-row {
    background-color: #161B22;
    border: 1px solid #30363D;
    border-radius: 0.375rem;
    padding: 1rem;
    transition: background-color 0.2s ease-in-out;
}
.game-info-row:hover {
    background-color: #21262D;
}
.game-info-row.lineup-row:hover {
    background-color: #0D1117;
}
.lineup-table tbody tr:hover {
    background-color: #21262D;
}
.lineup-last10 {
    font-size: 0.85rem;
    color: rgba(240, 246, 252, 0.85);
    font-weight: 500;
}
.lineup-player-name {
    font-size: 0.95rem;
    font-weight: 600;
    display: block;
    color: #FFFFFF;
}
.info-row-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #F0F6FC;
    margin: 0 0 8px;
}
.opposing-pitcher-title,
.career-vs-title,
.season-splits-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #C9D1D9;
    margin-bottom: 4px;
}
.pitcher-stats-line,
.career-stats-line,
.season-splits-line,
.bullpen-stats-line {
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
    align-items: baseline;
    white-space: nowrap;
}
.season-splits-line { gap: 12px; }
.bullpen-stats-line { gap: 12px; }
.bp-rank-select {
    background-color: #161B22;
    border: 1px solid #30363D;
    color: #C9D1D9;
    border-radius: 4px;
    padding: 0.35rem 0.6rem;
    font-size: 0.85rem;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%238B949E' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    width: auto;
}
.bp-rank-select:focus {
    border-color: #58A6FF;
    box-shadow: 0 0 0 0.2rem rgba(88, 166, 255, 0.25);
    outline: none;
}

.stat-item {
    display: inline-flex;
    align-items: baseline;
}
.stat-label {
    font-weight: 600;
    color: #F0F6FC;
    margin-right: 6px;
}
.pitcher-stats-line .separator {
    margin: 0 12px;
    color: #8B949E;
}
.pitcher-stats-line .spacer {
    margin-right: 12px;
}
.split-gap {
    margin-left: 24px;
}
.stat-highlight {
    background: rgba(88, 166, 255, 0.15);
    border-radius: 6px;
    padding: 1px 3px;
    margin: -1px -3px;
}
.no-game-message {
    font-size: 0.9rem;
    color: #aaaaaa;
    text-align: center;
    padding: 0.5rem;
}

.text-muted {
    font-size: 0.9rem;
    color: #aaaaaa !important;
}

.todays-game-subtitle .team-badge {
    font-size: 0.95rem;
    padding: 4px 10px;
    display: inline-flex;
    align-items: center;
    color: #ffffff;
}

/* === PREMIUM LOCKOVERLAY === */
.premium-lock {
    position: relative;
}
.premium-lock .premium-content {
    position: relative;
    z-index: 0;
    filter: blur(6px);
    pointer-events: none;
}
.premium-lock .premium-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    font-size: 1rem; /* slightly smaller, matches ps-alert */
    color: #C9D1D9; /* theme text color */
    font-weight: 500;
    line-height: 1.4;
    background: rgba(22,27,34,0.92);
    border: 1px solid #30363D;
    border-radius: 8px;
    padding: 1rem;
    backdrop-filter: blur(2px);
    z-index: 20;
    pointer-events: auto; /* allow links inside overlay to be clickable */
    width: 100%;
    margin: 0;
}
.premium-lock .premium-overlay a {
    color: #58A6FF;
    text-decoration: underline;
}

/* === TODAY'S GAME NEW STYLES === */
.todays-game {
    /* Uses .ps-content-block styles, so no need for redundant background/border */
}

.todays-game__title {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    flex-wrap: wrap; /* Allow subtitle to wrap on small screens */
}

.todays-game__subtitle {
    font-size: 1rem;
    font-weight: 400;
    color: #8B949E; /* Softer color for subtitle */
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.todays-game__subtitle .team-badge {
    font-size: 0.9rem;
    padding: 0.25em 0.6em;
    color: #ffffff;
}

.todays-game__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.25rem; /* Consistent gap between cards */
    margin-top: 1rem;
}

/* Balance card layout on tablets so rows are even */
@media (min-width: 768px) and (max-width: 1199.98px) {
    .todays-game__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.todays-game__card {
    background-color: #0D1117; /* Darker, distinct card background */
    border: 1px solid #21262D; /* Subtle border */
    border-radius: 6px; /* Consistent radius */
    display: flex;
    flex-direction: column; /* Ensure cards have consistent height if needed */
}

.todays-game__card-header {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #21262D;
}

.todays-game__card-title {
    font-size: 1rem;
    font-weight: 600;
    color: #E6EDF3; /* Brighter title text */
    margin: 0;
}

.todays-game__card-body {
    padding: 1rem;
    flex-grow: 1; /* Allow body to fill available space */
}

.todays-game__pitcher-name {
    font-size: 1.1rem;
    font-weight: 500;
    color: #C9D1D9;
    margin-bottom: 0.75rem;
}

.todays-game__stats-list {
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 0.9rem;
}

.todays-game__stats-list li {
    display: flex;
    justify-content: flex-start;
    gap: 0.25rem;
    padding: 0.3rem 0;
    color: #C9D1D9;
}

.todays-game__stats-list li .label {
    font-weight: 500;
    color: #8B949E; /* Softer label color */
}

.pitcher-stats-columns {
    display: flex;
    gap: 1rem;
    margin-bottom: 0.5rem;
}
.pitcher-stats-col {
    flex: 1;
}
.pitcher-stats-heading {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
    color: #E6EDF3;
}

/* For side-by-side splits */
.todays-game__stats-list--splits li {
    justify-content: flex-start;
    gap: 0.5rem;
}
.todays-game__stats-list--splits li.highlight {
    background-color: rgba(56, 139, 253, 0.1); /* Subtle highlight */
    border-radius: 4px;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
    margin: 0.1rem -0.5rem;
}

.todays-game__split-divider {
    border-top: 1px solid #30363d;
    margin: 0.25rem 0;
}

.todays-game__sub-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: #E6EDF3;
    margin-top: 1rem;
    margin-bottom: 0.5rem;
    padding-bottom: 0.25rem;
    border-bottom: 1px solid #21262D;
}

.todays-game__split-group:first-child .todays-game__sub-title {
    margin-top: 0; /* Remove top margin for the first split group */
}

.todays-game__no-data {
    color: #7D8590;
    font-style: italic;
    text-align: center;
    padding: 1rem 0;
}

/* Bullpen Table Specifics */
.todays-game__bullpen-card .todays-game__card-title {
    font-size: 1rem; /* Match other titles */
}

.todays-game__bullpen-table {
    width: 100%;
    font-size: 0.8rem; /* Smaller font for dense table */
}
.todays-game__bullpen-table th,
.todays-game__bullpen-table td {
    text-align: center;
    padding: 0.4rem;
}
.todays-game__bullpen-table th {
    font-size: 0.7rem;
}
.todays-game__bullpen-table td:first-child,
.todays-game__bullpen-table th:first-child {
    text-align: left;
    font-weight: 600;
}

/* === General Page Polish === */

/* Player Header Refinements */
.ps-player-header__name {
    font-size: 2.2rem; /* Slightly larger name */
}
.ps-player-header__bio {
    margin-top: 0.25rem; /* Better align bio with name details if wrapped */
}

/* Table styling consistency (applied to .ps-table, .performance-table) */
.ps-table th, .performance-table th {
    background-color: #161B22; /* Darker, consistent header */
    border-bottom: 2px solid #388BFD; /* Accent border for header bottom */
}
.ps-table td, .performance-table td {
    border-bottom: 1px solid #21262D; /* Consistent row separator */
}
.ps-table tbody tr:hover, .performance-table tbody tr:hover {
    background-color: #1C2128; /* Slightly lighter hover for rows */
}

/* Percentile Rankings Description */
.ps-content-block .ps-content-block__description {
    font-size: 0.85rem; /* Slightly smaller description */
    color: #A0AEC0; /* Lighter grey for less emphasis */
    margin-bottom: 1rem; /* Adjust spacing */
}

/* Last 10 Games Hit Rates (Circle Graphs) */
.circle-graph-group {
    gap: 1rem; /* Adjust gap for better spacing */
}
@media (max-width: 768px) {
    .circle-graph-item {
        width: 80px; /* Slightly smaller on mobile */
    }
    .circle-graph-item .position-relative {
        width: 60px;
        height: 60px;
    }
    .circle-graph-item .circle-percent {
        font-size: 0.8rem;
    }
    .circle-graph-item .circle-graph-label {
        font-size: 0.7rem;
    }
}

/* Prop Performance History Filters */
.ps-prop-selector-container {
    gap: 0.75rem; /* Tighter gap for controls */
}
.ps-prop-selector__control label {
    font-size: 0.8rem; /* Smaller labels */
}
.ps-prop-selector__select {
    padding: 0.3rem 0.5rem; /* More compact select */
    font-size: 0.8rem;
}
#threshold-slider {
    height: 3px; /* Slimmer slider track */
}
#threshold-slider::-webkit-slider-thumb {
    width: 14px; /* Smaller thumb */
    height: 14px;
    margin-top: -5.5px; /* Adjust thumb alignment */
}
#threshold-slider::-moz-range-thumb {
    width: 14px;
    height: 14px;
}
#threshold-value {
    font-size: 0.85rem; /* Smaller value display */
    padding: 0.1em 0.35em;
}

/* Game Logs Table */
.ps-game-log__table th {
    font-size: 0.8rem; /* Larger header text for readability */
    text-align: center;
}
.ps-game-log__table td {
    font-size: 0.85rem; /* Larger cell text */
    padding: 0.6rem 0.75rem; /* Adjust padding */
    text-align: center;
}

/* Load More Button - ensure it stands out but fits the theme */
.load-more-btn {
    background-color: #23272F; /* Darker, less prominent background */
    border: 1px solid #30363D;
}
.load-more-btn:hover {
    background-color: #2D333B; /* Slightly lighter on hover */
    border-color: #388BFD;
}


/* Alternate overlay using pseudo-element */
.premium-auto-overlay::after {
    content: "Premium Feature";
    position: absolute;
    inset: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    font-size: 1.2rem;
    color: #ffffff;
    font-weight: 600;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(3px);
    z-index: 20;
    pointer-events: none;
}

@media (max-width: 400px) {
    main { padding: 0.75rem 4px; }
    .ps-player-header__name { font-size: 1.2rem; }
    .ps-player-header__meta { font-size: 0.7rem; }
    .ps-content-block,
    .ps-overview-container,
    .ps-performance-card,
    .ps-game-card { padding: 1rem; }
    .ps-content-block__title { font-size: 1rem; }
    .ps-table th, .ps-table td { padding: 0.35rem 0.4rem; font-size: 0.7rem; }
    .ps-prop-selector__control label,
    .ps-prop-selector__select,
    #threshold-value { font-size: 0.75rem; }
    .circle-graph-item { width: 60px; }
    .circle-graph-item .position-relative { width: 45px; height: 45px; }
    .circle-graph-item .circle-percent { font-size: 0.75rem; }
    .circle-graph-item .circle-graph-label { font-size: 0.65rem; }