/* ========================================================================== 
   NFL Fantasy Mate - Players + Player Intelligence
   Internal research pages: restrained light surfaces with charcoal/gold cues.
   ========================================================================== */

.players-page,
.player-page {
    background: #f4f5f3 !important;
    color: #111315 !important;
}

.nav-link { cursor: pointer !important; }
.nav-link.is-active {
    color: #f2c230 !important;
    border-bottom-color: #f2c230 !important;
}

.players-intro,
.player-intro {
    border-bottom: 1px solid rgba(17, 19, 21, .10);
    background:
        radial-gradient(circle at 78% 16%, rgba(242, 194, 48, .13), transparent 23rem),
        linear-gradient(180deg, #ffffff 0%, #f5f5f2 100%);
}

.players-intro-inner,
.player-intro-inner {
    width: min(100%, var(--max-width));
    margin: 0 auto;
    padding: 54px 28px 46px;
    display: flex;
    justify-content: space-between;
    gap: 36px;
    align-items: flex-end;
}

.players-intro h1,
.player-intro h1 {
    margin: 0;
    color: #111315;
    font-size: clamp(2.4rem, 4vw, 4rem);
    line-height: .96;
    letter-spacing: -.055em;
}

.players-intro-copy,
.player-intro-copy {
    max-width: 720px;
    margin: 14px 0 0;
    color: #596064;
    font-size: 1rem;
    line-height: 1.62;
}

.players-freshness,
.player-freshness {
    flex: 0 0 auto;
    color: #6d7478;
    font-size: .78rem;
    font-weight: 700;
    text-align: right;
}

.players-freshness strong,
.player-freshness strong { color: #111315; }

.players-shell,
.player-shell {
    width: min(100%, var(--max-width));
    margin: 0 auto;
    padding: 34px 28px 72px;
}

.player-view-tabs,
.player-detail-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(17, 19, 21, .10);
}

.player-view-tab,
.player-detail-tab,
.position-tab,
.preset-button,
.secondary-action,
.download-button,
.pagination button,
.chart-toggle,
.player-season-select,
.compact-select {
    font: inherit;
}

.player-view-tab,
.player-detail-tab,
.position-tab,
.preset-button,
.secondary-action,
.download-button,
.pagination button,
.chart-toggle {
    border: 1px solid rgba(17, 19, 21, .14);
    background: #ffffff;
    color: #313639;
    cursor: pointer;
}

.player-view-tab,
.player-detail-tab {
    min-height: 40px;
    padding: 0 14px;
    border-radius: 8px;
    font-size: .82rem;
    font-weight: 820;
}

.player-view-tab.is-active,
.player-detail-tab.is-active {
    color: #17191b;
    background: #f2c230;
    border-color: #f2c230;
}

.premium-chip {
    display: inline-flex;
    align-items: center;
    min-height: 18px;
    margin-left: 5px;
    padding: 0 6px;
    border: 1px solid rgba(17, 19, 21, .22);
    border-radius: 999px;
    font-size: .56rem;
    font-weight: 900;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.players-toolbar {
    display: grid;
    grid-template-columns: auto minmax(240px, 430px);
    justify-content: space-between;
    gap: 22px;
    align-items: center;
    margin: 24px 0 30px;
}

.position-tabs { display: flex; gap: 8px; }
.position-tab {
    min-width: 56px;
    height: 42px;
    padding: 0 15px;
    border-radius: 9px;
    font-size: .82rem;
    font-weight: 900;
}
.position-tab:hover,
.position-tab.is-active {
    border-color: #17191b;
    background: #17191b;
    color: #f2c230;
}

.players-search {
    width: 100%;
    height: 44px;
    padding: 0 14px;
    border: 1px solid rgba(17, 19, 21, .14);
    border-radius: 9px;
    background: #ffffff;
    color: #111315;
    font: inherit;
}
.players-search::placeholder { color: #8b9194; }
.players-search:focus { border-color: rgba(242, 194, 48, .78); outline: none; box-shadow: 0 0 0 3px rgba(242, 194, 48, .14); }

.player-view[hidden],
.player-detail-panel[hidden] { display: none !important; }
.player-view.is-active,
.player-detail-panel.is-active { display: block; }

.view-heading-row {
    display: flex;
    justify-content: space-between;
    gap: 28px;
    align-items: flex-end;
    margin-bottom: 22px;
}
.view-heading-row h2 {
    margin: 3px 0 7px;
    font-size: clamp(1.55rem, 2.5vw, 2.15rem);
    letter-spacing: -.035em;
}
.view-heading-row p:not(.view-kicker) { margin: 0; color: #697074; max-width: 780px; line-height: 1.55; font-size: .88rem; }
.view-kicker {
    margin: 0;
    color: #8c6900;
    font-size: .67rem;
    font-weight: 900;
    letter-spacing: .11em;
}

.view-controls,
.historical-filter-row label {
    color: #6b7174;
    font-size: .68rem;
    font-weight: 850;
    letter-spacing: .055em;
    text-transform: uppercase;
}
.view-controls { display: flex; align-items: center; gap: 9px; }
.compact-select,
.player-season-select {
    min-height: 38px;
    padding: 0 32px 0 11px;
    border: 1px solid rgba(17, 19, 21, .14);
    border-radius: 8px;
    background: #fff;
    color: #111315;
    font-size: .76rem;
    font-weight: 760;
}

.table-status-row {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin: 12px 0 10px;
    color: #6d7478;
    font-size: .72rem;
}
.table-status-note { text-align: right; }

.data-table-wrap {
    overflow: auto;
    border: 1px solid rgba(17, 19, 21, .11);
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 10px 28px rgba(17, 19, 21, .055);
}

.player-table {
    width: 100%;
    min-width: 920px;
    border-collapse: collapse;
    table-layout: fixed;
}
.player-table th,
.player-table td {
    padding: 14px 15px;
    border-bottom: 1px solid rgba(17, 19, 21, .075);
    vertical-align: middle;
    text-align: left;
}
.player-table th {
    position: sticky;
    top: 0;
    z-index: 2;
    background: #f3f4f1;
    color: #6c7275;
    font-size: .64rem;
    font-weight: 900;
    letter-spacing: .065em;
    text-transform: uppercase;
}
.player-table tbody tr:last-child td { border-bottom: 0; }
.player-table tbody tr.player-row { cursor: pointer; transition: background-color .14s ease, box-shadow .14s ease; }
.player-table tbody tr.player-row:hover { background: #fff9e8; box-shadow: inset 4px 0 0 #f2c230; }
.player-table tbody tr.player-row:focus-visible { outline: 3px solid rgba(242, 194, 48, .48); outline-offset: -3px; }

.sort-button {
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    font-weight: inherit;
    letter-spacing: inherit;
    text-transform: inherit;
    cursor: pointer;
}
.sort-button:hover { color: #111315; }

.player-cell { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.player-name { color: #111315; font-weight: 860; font-size: .9rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.player-meta { color: #858b8e; font-size: .67rem; font-weight: 720; }
.score-cell strong { display: block; color: #111315; font-size: 1rem; }
.score-cell small { display: block; margin-top: 3px; color: #858b8e; font-size: .62rem; }
.score-cell.primary strong { color: #8f6d00; }
.unavailable-value { color: #8b9194; font-size: .72rem; line-height: 1.3; }

.context-stack { display: flex; flex-wrap: wrap; gap: 5px; }
.context-chip,
.signal-chip,
.role-chip {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 0 8px;
    border: 1px solid rgba(242, 194, 48, .30);
    border-radius: 6px;
    background: rgba(242, 194, 48, .08);
    color: #745800;
    font-size: .62rem;
    font-weight: 820;
}
.context-chip.neutral { border-color: rgba(17, 19, 21, .12); background: #f3f4f2; color: #687074; }

.market-cell strong { display: block; color: #111315; font-size: .87rem; }
.market-cell small { display: block; margin-top: 3px; color: #808689; font-size: .62rem; }

.pagination {
    min-height: 42px;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 8px;
    margin-top: 13px;
}
.pagination span { color: #71777a; font-size: .7rem; }
.pagination button { min-width: 34px; height: 34px; border-radius: 7px; font-size: .72rem; font-weight: 800; }
.pagination button:hover:not(:disabled) { border-color: #17191b; background: #17191b; color: #f2c230; }
.pagination button:disabled { opacity: .38; cursor: default; }

.compare-presets {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 4px 0 16px;
}
.preset-button { min-height: 36px; padding: 0 12px; border-radius: 8px; font-size: .72rem; font-weight: 820; }
.preset-button:hover,
.preset-button.is-active { background: #17191b; color: #f2c230; border-color: #17191b; }
.download-button,
.secondary-action {
    min-height: 40px;
    padding: 0 14px;
    border-radius: 8px;
    font-size: .73rem;
    font-weight: 850;
}
.download-button { background: #17191b; color: #f2c230; border-color: #17191b; }
.download-button:hover:not(:disabled) { background: #272a2c; }
.download-button:disabled,
.secondary-action:disabled { opacity: .42; cursor: default; }
.secondary-action:hover:not(:disabled) { border-color: #17191b; }

.compare-table { min-width: 980px; }
.compare-table th:first-child,
.compare-table td:first-child { width: 240px; }
.metric-number { font-variant-numeric: tabular-nums; font-weight: 790; color: #25292b; }
.metric-number.accent { color: #8a6800; }

.historical-heading-row { align-items: flex-end; }
.historical-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.historical-filter-row {
    display: grid;
    grid-template-columns: repeat(3, minmax(150px, 220px));
    gap: 12px;
    margin: 0 0 16px;
}
.historical-filter-row label { display: grid; gap: 7px; }
.historical-table { min-width: 1160px; }
.selection-column { width: 48px; }
.historical-check { width: 17px; height: 17px; accent-color: #d9aa15; cursor: pointer; }
.historical-selection {
    margin: 8px 0 16px;
    padding: 14px;
    border: 1px solid rgba(242, 194, 48, .28);
    border-radius: 10px;
    background: #fff9e7;
}
.selected-season-list { display: flex; flex-wrap: wrap; gap: 8px; }
.selected-season-chip { padding: 7px 9px; border: 1px solid rgba(17, 19, 21, .10); border-radius: 7px; background: #fff; font-size: .7rem; font-weight: 780; }
.historical-comparison-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-top: 14px; }
.historical-compare-card { padding: 14px; border: 1px solid rgba(17, 19, 21, .10); border-radius: 9px; background: #fff; }
.historical-compare-card strong { display: block; font-size: .86rem; }
.historical-compare-card small { color: #747b7e; }
.historical-compare-score { margin-top: 12px; color: #8a6800; font-size: 1.45rem; font-weight: 900; }
.historical-compare-card dl { margin: 12px 0 0; display: grid; gap: 6px; }
.historical-compare-card dl div { display: flex; justify-content: space-between; gap: 10px; font-size: .68rem; }
.historical-compare-card dt { color: #7b8184; }
.historical-compare-card dd { margin: 0; color: #222628; font-weight: 760; }

.players-load-error,
.player-load-error {
    margin-top: 24px;
    padding: 24px;
    border: 1px solid rgba(185, 54, 54, .24);
    border-radius: 10px;
    background: #fff2f2;
    color: #7f2929;
}

/* Player Intelligence ----------------------------------------------------- */
.player-breadcrumb {
    width: min(100%, var(--max-width));
    margin: 0 auto;
    padding: 22px 28px 0;
    font-size: .72rem;
    color: #757b7e;
}
.player-breadcrumb a { font-weight: 780; }
.player-breadcrumb a:hover { color: #8a6800; }

.player-intro-inner { align-items: center; }
.player-title-block { min-width: 0; }
.player-position-line { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 10px; }
.player-team-pill,
.player-position-pill {
    display: inline-flex;
    min-height: 26px;
    align-items: center;
    padding: 0 9px;
    border-radius: 6px;
    font-size: .65rem;
    font-weight: 900;
    letter-spacing: .05em;
}
.player-position-pill { background: #17191b; color: #f2c230; }
.player-team-pill { background: rgba(242, 194, 48, .15); border: 1px solid rgba(242, 194, 48, .34); color: #6e5400; }
.player-secondary-meta { margin-top: 12px; color: #777e81; font-size: .75rem; }

.player-core-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 18px;
}
.player-core-card {
    min-height: 138px;
    padding: 19px;
    border: 1px solid rgba(17, 19, 21, .11);
    border-radius: 12px;
    background: #17191b;
    box-shadow: 0 12px 28px rgba(17, 19, 21, .10);
}
.player-core-card small { display: block; color: #aeb4b7; font-size: .65rem; font-weight: 900; letter-spacing: .075em; }
.player-core-card strong { display: block; margin-top: 10px; color: #f2c230; font-size: clamp(2rem, 4vw, 3.1rem); line-height: .95; letter-spacing: -.05em; }
.player-core-card span { display: block; margin-top: 7px; color: #d9dcdd; font-size: .72rem; }
.player-core-card.is-unavailable strong { color: #858b8e; font-size: 1.15rem; letter-spacing: -.02em; line-height: 1.25; }

.player-signal-section {
    margin-bottom: 24px;
    padding: 18px;
    border: 1px solid rgba(17, 19, 21, .10);
    border-radius: 12px;
    background: #ffffff;
}
.player-signal-heading { display: flex; justify-content: space-between; gap: 14px; align-items: baseline; margin-bottom: 12px; }
.player-signal-heading h2 { margin: 0; font-size: 1rem; }
.player-signal-heading span { color: #83898c; font-size: .67rem; }
.player-signals { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.player-signal-card { padding: 13px 14px; border: 1px solid rgba(17, 19, 21, .10); border-radius: 9px; background: #f7f7f4; }
.player-signal-card .signal-type { color: #8a6800; font-size: .6rem; font-weight: 900; letter-spacing: .08em; }
.player-signal-card strong { display: block; margin-top: 5px; font-size: .86rem; }
.player-signal-card p { margin: 5px 0 0; color: #737a7d; font-size: .68rem; line-height: 1.4; }
.player-signal-empty { color: #767d80; font-size: .78rem; }

.player-detail-tabs { margin-bottom: 24px; }
.player-detail-panel { min-height: 320px; }
.detail-section-grid { display: grid; grid-template-columns: 1.25fr .75fr; gap: 18px; }
.detail-panel-card {
    border: 1px solid rgba(17, 19, 21, .10);
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 9px 24px rgba(17, 19, 21, .045);
}
.detail-panel-card-header { padding: 18px 20px 14px; border-bottom: 1px solid rgba(17, 19, 21, .075); }
.detail-panel-card-header h3 { margin: 3px 0 0; font-size: 1.04rem; }
.detail-panel-card-body { padding: 18px 20px 20px; }

.component-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.component-row { padding: 12px 13px; border: 1px solid rgba(17, 19, 21, .08); border-radius: 8px; background: #f8f8f5; }
.component-row-top { display: flex; justify-content: space-between; gap: 14px; align-items: baseline; }
.component-row strong { font-size: .78rem; }
.component-row span { color: #8a6800; font-size: .82rem; font-weight: 880; }
.component-bar { height: 5px; margin-top: 9px; overflow: hidden; border-radius: 999px; background: #e4e5e1; }
.component-bar i { display: block; height: 100%; background: #d7aa17; border-radius: inherit; }

.summary-list { display: grid; gap: 10px; }
.summary-row { display: flex; justify-content: space-between; gap: 16px; padding-bottom: 10px; border-bottom: 1px solid rgba(17, 19, 21, .075); }
.summary-row:last-child { border-bottom: 0; padding-bottom: 0; }
.summary-row dt { color: #777e81; font-size: .7rem; }
.summary-row dd { margin: 0; color: #25292b; font-size: .72rem; font-weight: 820; text-align: right; }
.summary-row dd.accent { color: #8a6800; }

.chart-card { padding: 20px; border: 1px solid rgba(17,19,21,.10); border-radius: 12px; background: #17191b; }
.chart-card-header { display: flex; justify-content: space-between; gap: 18px; align-items: flex-start; }
.chart-card-header h3 { margin: 0; color: #fff; font-size: 1.12rem; }
.chart-card-header p { margin: 6px 0 0; color: #aeb4b7; font-size: .7rem; }
.chart-controls { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }
.chart-toggle { min-height: 32px; padding: 0 9px; border-color: rgba(255,255,255,.14); background: rgba(255,255,255,.05); color: #d7dbdc; border-radius: 7px; font-size: .66rem; font-weight: 800; }
.chart-toggle.is-active { color: #17191b; background: #f2c230; border-color: #f2c230; }
.player-chart { display: block; width: 100%; height: 340px; margin-top: 10px; }
.player-chart .gridline { stroke: rgba(255,255,255,.09); stroke-width: 1; stroke-dasharray: 4 5; }
.player-chart .axis-label { fill: #949b9e; font-size: 11px; }
.player-chart .line-profile { fill: none; stroke: #f2c230; stroke-width: 3.2; stroke-linecap: round; stroke-linejoin: round; }
.player-chart .line-opportunity { fill: none; stroke: #ffffff; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.player-chart .line-performance { fill: none; stroke: #9ca3a6; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.player-chart .baseline { stroke: #696f72; stroke-width: 1.5; stroke-dasharray: 7 6; }
.player-chart .point-profile { fill: #f2c230; stroke: #fff; stroke-width: 2; }
.player-chart .market-line { fill: none; stroke: #f2c230; stroke-width: 3; stroke-linejoin: round; stroke-linecap: round; }

.chart-legend-inline { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 5px; color: #aeb4b7; font-size: .67rem; }
.chart-legend-inline span::before { content: ""; display: inline-block; width: 19px; height: 3px; margin-right: 6px; vertical-align: middle; border-radius: 3px; }
.legend-profile::before { background: #f2c230; }
.legend-opportunity::before { background: #fff; }
.legend-performance::before { background: #9ca3a6; }

.trend-event-list { display: grid; gap: 8px; margin-top: 16px; }
.trend-event { display: flex; justify-content: space-between; gap: 16px; padding: 11px 12px; border: 1px solid rgba(17,19,21,.09); border-radius: 8px; background: #fff; font-size: .7rem; }
.trend-event strong { color: #25292b; }
.trend-event span { color: #777d80; text-align: right; }

.detail-table-wrap { overflow: auto; border: 1px solid rgba(17,19,21,.10); border-radius: 12px; background: #fff; }
.detail-table { width: 100%; min-width: 820px; border-collapse: collapse; }
.detail-table th, .detail-table td { padding: 13px 14px; border-bottom: 1px solid rgba(17,19,21,.075); text-align: left; font-size: .72rem; }
.detail-table th { background: #f3f4f1; color: #707679; font-size: .62rem; letter-spacing: .06em; text-transform: uppercase; }
.detail-table td strong { color: #202426; }
.detail-table tbody tr:last-child td { border-bottom: 0; }

.metric-summary-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 10px; margin-bottom: 18px; }
.metric-summary-card { padding: 15px; border: 1px solid rgba(17,19,21,.09); border-radius: 9px; background: #fff; }
.metric-summary-card small { display: block; color: #777e81; font-size: .6rem; font-weight: 850; letter-spacing: .06em; }
.metric-summary-card strong { display: block; margin-top: 7px; color: #8a6800; font-size: 1.25rem; }

.metric-groups { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 14px; }
.metric-group { padding: 16px; border: 1px solid rgba(17,19,21,.09); border-radius: 10px; background: #fff; }
.metric-group h3 { margin: 0 0 12px; font-size: .9rem; }
.metric-list { display: grid; gap: 8px; }
.metric-list-row { display: flex; justify-content: space-between; gap: 16px; padding-bottom: 8px; border-bottom: 1px solid rgba(17,19,21,.06); font-size: .7rem; }
.metric-list-row:last-child { padding-bottom: 0; border-bottom: 0; }
.metric-list-row span { color: #747b7e; }
.metric-list-row strong { color: #202426; }

.team-context-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.team-context-card { padding: 18px; border: 1px solid rgba(17,19,21,.10); border-radius: 11px; background: #fff; }
.team-context-card h3 { margin: 4px 0 6px; font-size: 1rem; }
.team-context-card > p { margin: 0 0 14px; color: #747b7e; font-size: .72rem; line-height: 1.5; }
.team-context-metrics { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; }
.team-context-metric { padding: 11px; border-radius: 8px; background: #f5f6f3; }
.team-context-metric small { display: block; color: #7a8083; font-size: .58rem; font-weight: 800; }
.team-context-metric strong { display: block; margin-top: 5px; color: #8a6800; font-size: .92rem; }

.empty-state { padding: 26px; border: 1px dashed rgba(17,19,21,.18); border-radius: 10px; background: #fafaf8; color: #72797c; font-size: .8rem; line-height: 1.55; }

@media (max-width: 1100px) {
    .players-toolbar { grid-template-columns: 1fr; }
    .players-search-wrap { max-width: none; }
    .historical-comparison-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
    .detail-section-grid { grid-template-columns: 1fr; }
    .player-signals { grid-template-columns: 1fr 1fr; }
    .team-context-grid { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
    .nav-link.is-active { border-bottom-color: transparent !important; border-left-color: #f2c230 !important; }
    .players-intro-inner,
    .player-intro-inner { padding: 38px 18px 34px; flex-direction: column; align-items: flex-start; }
    .players-freshness,
    .player-freshness { text-align: left; }
    .players-shell,
    .player-shell { padding: 24px 18px 50px; }
    .player-view-tabs,
    .player-detail-tabs { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 14px; }
    .player-view-tab,
    .player-detail-tab { flex: 0 0 auto; }
    .players-toolbar { margin-top: 18px; }
    .position-tabs { display: grid; grid-template-columns: repeat(4,1fr); }
    .position-tab { min-width: 0; padding: 0 8px; }
    .view-heading-row { flex-direction: column; align-items: flex-start; }
    .view-controls { width: 100%; justify-content: space-between; }
    .compact-select { max-width: 100%; }
    .table-status-row { flex-direction: column; gap: 5px; }
    .table-status-note { text-align: left; }
    .historical-actions { width: 100%; justify-content: flex-start; }
    .historical-filter-row { grid-template-columns: 1fr; }
    .historical-comparison-grid { grid-template-columns: 1fr; }
    .player-core-grid { grid-template-columns: 1fr 1fr; }
    .player-core-card:first-child { grid-column: 1 / -1; }
    .player-signals { grid-template-columns: 1fr; }
    .component-grid { grid-template-columns: 1fr; }
    .chart-card-header { flex-direction: column; }
    .chart-controls { justify-content: flex-start; }
    .player-chart { height: 260px; }
    .metric-summary-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .metric-groups { grid-template-columns: 1fr; }
    .team-context-metrics { grid-template-columns: 1fr 1fr; }
}

@media (prefers-reduced-motion: reduce) {
    .player-table tbody tr.player-row,
    .preset-button,
    .position-tab,
    .player-view-tab,
    .player-detail-tab { transition: none !important; }
}

/* ========================================================================== 
   NFL Fantasy Mate - Players Explorer visual refinement
   Stronger hierarchy and product identity without turning the explorer into
   a dashboard. Landing page only; Player Intelligence keeps its own layout.
   ========================================================================== */

.players-page {
    background:
        linear-gradient(180deg, #f1f2ef 0%, #f6f6f4 34rem, #f2f3f1 100%) !important;
}

/* Compact product header: internal pages should feel related to Home without
   repeating the full gold homepage hero. */
.players-page .players-intro {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    border-bottom: 1px solid rgba(242, 194, 48, .22);
    background: linear-gradient(118deg, #111315 0%, #191c1e 58%, #202326 100%);
}

.players-page .players-intro::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -2;
    background:
        radial-gradient(circle at 82% 12%, rgba(242, 194, 48, .22), transparent 22rem),
        radial-gradient(circle at 66% 110%, rgba(242, 194, 48, .08), transparent 28rem);
}

.players-page .players-intro::after {
    content: "PLAYERS";
    position: absolute;
    right: max(28px, calc((100vw - var(--max-width)) / 2 + 28px));
    bottom: -25px;
    z-index: -1;
    color: rgba(255, 255, 255, .035);
    font-size: clamp(5rem, 10vw, 10rem);
    line-height: .82;
    font-weight: 950;
    letter-spacing: -.07em;
    pointer-events: none;
}

.players-page .players-intro-inner {
    padding-top: 48px;
    padding-bottom: 68px;
}

.players-page .players-intro .eyebrow {
    color: var(--fm-gold, #f2c230) !important;
}

.players-page .players-intro h1 {
    color: #ffffff;
    text-shadow: 0 1px 0 rgba(255, 255, 255, .02);
}

.players-page .players-intro-copy {
    max-width: 650px;
    color: #c7ccce;
}

.players-page .players-freshness {
    min-width: 255px;
    padding: 12px 15px;
    border: 1px solid rgba(242, 194, 48, .25);
    border-radius: 11px;
    background: rgba(255, 255, 255, .045);
    color: #adb3b6;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .035);
}

.players-page .players-freshness strong {
    color: var(--fm-gold, #f2c230);
}

.players-page .players-shell {
    position: relative;
    z-index: 2;
    margin-top: -30px;
    padding-top: 0;
}

/* Explorer view switcher becomes a compact floating control rather than a
   loose row of buttons. */
.players-page .player-view-tabs {
    width: max-content;
    max-width: 100%;
    gap: 6px;
    padding: 7px;
    border: 1px solid rgba(17, 19, 21, .11);
    border-radius: 13px;
    background: rgba(255, 255, 255, .98);
    box-shadow: 0 14px 32px rgba(17, 19, 21, .10);
}

.players-page .player-view-tab {
    min-height: 42px;
    padding-inline: 16px;
    border-color: transparent;
    background: transparent;
}

.players-page .player-view-tab:hover:not(.is-active) {
    background: #f2f3f0;
    border-color: rgba(17, 19, 21, .08);
}

.players-page .player-view-tab.is-active {
    box-shadow: 0 5px 14px rgba(171, 124, 0, .18);
}

/* Filters live on one deliberate control surface. */
.players-page .players-toolbar {
    margin: 18px 0 34px;
    padding: 14px 16px;
    border: 1px solid rgba(17, 19, 21, .10);
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 10px 28px rgba(17, 19, 21, .055);
}

.players-page .position-tabs {
    gap: 7px;
}

.players-page .position-tab {
    min-width: 60px;
    height: 44px;
    border-color: rgba(17, 19, 21, .10);
    background: #f3f4f1;
}

.players-page .position-tab:hover:not(.is-active) {
    border-color: rgba(17, 19, 21, .23);
    background: #eceeeb;
    color: #111315;
}

.players-page .position-tab.is-active {
    border-color: #17191b;
    background: #17191b;
    color: var(--fm-gold, #f2c230);
    box-shadow: 0 6px 16px rgba(17, 19, 21, .13);
}

.players-page .players-search {
    height: 46px;
    border-color: rgba(17, 19, 21, .13);
    background: #fafaf8;
    box-shadow: inset 0 1px 1px rgba(17, 19, 21, .02);
}

/* View heading has an obvious analytical accent and stronger hierarchy. */
.players-page .view-heading-row {
    position: relative;
    padding-left: 18px;
    margin-bottom: 24px;
}

.players-page .view-heading-row::before {
    content: "";
    position: absolute;
    left: 0;
    top: 4px;
    bottom: 4px;
    width: 4px;
    border-radius: 999px;
    background: var(--fm-gold, #f2c230);
}

.players-page .view-kicker {
    color: #8b6800;
}

.players-page .view-heading-row h2 {
    margin-top: 5px;
    font-size: clamp(1.75rem, 2.6vw, 2.4rem);
}

.players-page .view-controls {
    padding: 7px 8px 7px 11px;
    border: 1px solid rgba(17, 19, 21, .10);
    border-radius: 10px;
    background: #ffffff;
    box-shadow: 0 6px 18px rgba(17, 19, 21, .045);
}

.players-page .compact-select {
    border-color: rgba(17, 19, 21, .11);
    background: #f7f7f4;
}

.players-page .table-status-row {
    align-items: center;
    margin-bottom: 12px;
}

.players-page #overview-count,
.players-page #compare-count,
.players-page #historical-count {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 9px;
    border: 1px solid rgba(17, 19, 21, .09);
    border-radius: 999px;
    background: #ffffff;
    color: #313639;
    font-weight: 820;
    box-shadow: 0 3px 10px rgba(17, 19, 21, .035);
}

/* Table becomes the primary analytical surface. */
.players-page .data-table-wrap {
    overflow: auto;
    border: 1px solid rgba(17, 19, 21, .10);
    border-radius: 15px;
    background: #ffffff;
    box-shadow: 0 16px 38px rgba(17, 19, 21, .075);
}

.players-page .player-table {
    min-width: 960px;
}

.players-page .player-table th {
    padding-top: 15px;
    padding-bottom: 15px;
    border-bottom: 0;
    background: #17191b;
    color: #c9ced0;
    letter-spacing: .08em;
}

.players-page .player-table th:first-child {
    border-top-left-radius: 13px;
}

.players-page .player-table th:last-child {
    border-top-right-radius: 13px;
}

.players-page .sort-button:hover {
    color: var(--fm-gold, #f2c230);
}

.players-page .player-table td {
    padding-top: 16px;
    padding-bottom: 16px;
    border-bottom-color: rgba(17, 19, 21, .065);
}

.players-page .player-table tbody tr.player-row {
    position: relative;
    background: #ffffff;
    transition: background-color .14s ease, box-shadow .14s ease;
}

.players-page .player-table tbody tr.player-row:nth-child(even) {
    background: #fbfbf9;
}

.players-page .player-table tbody tr.player-row:hover {
    background: #fff9e7;
    box-shadow: inset 5px 0 0 var(--fm-gold, #f2c230);
}

.players-page .player-name {
    color: #111315;
    font-size: .94rem;
    font-weight: 900;
    letter-spacing: -.012em;
}

.players-page .player-meta {
    margin-top: 1px;
    color: #7d8487;
    font-size: .66rem;
    font-weight: 760;
    letter-spacing: .025em;
}

/* Profile / Opportunity / Performance gain a tiny visual scale. The values
   remain the authoritative exported numbers; the bar is presentation only. */
.players-page .score-cell {
    min-width: 92px;
    max-width: 128px;
}

.players-page .score-main {
    display: flex;
    align-items: baseline;
    gap: 8px;
}

.players-page .score-cell strong {
    margin: 0;
    font-size: 1.05rem;
    font-variant-numeric: tabular-nums;
}

.players-page .score-cell small {
    margin: 0;
    color: #8b9194;
    font-size: .58rem;
    font-weight: 800;
}

.players-page .score-track {
    display: block;
    width: 100%;
    height: 5px;
    margin-top: 8px;
    overflow: hidden;
    border-radius: 999px;
    background: #e9eae7;
}

.players-page .score-track i {
    display: block;
    width: var(--score, 0%);
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #c99b09 0%, var(--fm-gold, #f2c230) 100%);
}

.players-page .score-cell.primary {
    padding: 7px 9px 8px;
    border: 1px solid rgba(242, 194, 48, .24);
    border-radius: 9px;
    background: rgba(242, 194, 48, .075);
}

.players-page .score-cell.primary strong {
    color: #7c5f00;
}

.players-page .score-cell.primary .score-track {
    background: rgba(125, 95, 0, .10);
}

.players-page .context-chip,
.players-page .signal-chip,
.players-page .role-chip {
    min-height: 25px;
    border-color: rgba(242, 194, 48, .34);
    background: #fff8df;
    color: #735800;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .55);
}

.players-page .context-chip.neutral {
    border-color: rgba(17, 19, 21, .10);
    background: #f1f2ef;
    color: #6b7275;
}

.players-page .market-cell strong {
    display: inline-flex;
    align-items: center;
    min-height: 29px;
    padding: 0 9px;
    border-radius: 7px;
    background: #17191b;
    color: var(--fm-gold, #f2c230);
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: .015em;
}

.players-page .market-cell small {
    margin-top: 6px;
    color: #7e8588;
    font-size: .61rem;
    font-weight: 700;
}

.players-page .unavailable-value {
    display: inline-flex;
    align-items: center;
    min-height: 27px;
    padding: 0 8px;
    border-radius: 7px;
    background: #f2f3f0;
    color: #858c8f;
}

/* Premium/current comparison and historical controls receive the same surface
   treatment so switching modes still feels like one product. */
.players-page .compare-presets,
.players-page .historical-filter-row {
    padding: 13px;
    border: 1px solid rgba(17, 19, 21, .09);
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 8px 22px rgba(17, 19, 21, .045);
}

.players-page .preset-button {
    background: #f3f4f1;
    border-color: rgba(17, 19, 21, .09);
}

.players-page .preset-button:hover,
.players-page .preset-button.is-active {
    background: #17191b;
    color: var(--fm-gold, #f2c230);
    border-color: #17191b;
}

.players-page .download-button {
    box-shadow: 0 6px 16px rgba(17, 19, 21, .10);
}

.players-page .historical-selection {
    box-shadow: 0 7px 20px rgba(171, 124, 0, .06);
}

.players-page .pagination button {
    background: #ffffff;
}

@media (max-width: 900px) {
    .players-page .players-intro-inner {
        align-items: flex-start;
        flex-direction: column;
        padding-bottom: 62px;
    }

    .players-page .players-freshness {
        min-width: 0;
        width: 100%;
        text-align: left;
    }

    .players-page .players-toolbar {
        grid-template-columns: 1fr;
    }

    .players-page .players-search-wrap {
        width: 100%;
    }
}

@media (max-width: 720px) {
    .players-page .players-intro-inner {
        padding-top: 38px;
        padding-bottom: 56px;
    }

    .players-page .players-intro::after {
        right: 10px;
        bottom: -12px;
        font-size: 5.3rem;
    }

    .players-page .players-shell {
        margin-top: -24px;
    }

    .players-page .player-view-tabs {
        width: 100%;
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .players-page .player-view-tab {
        padding-inline: 7px;
        font-size: .72rem;
    }

    .players-page .position-tabs {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
    }

    .players-page .position-tab {
        min-width: 0;
        width: 100%;
    }

    .players-page .view-heading-row {
        padding-left: 14px;
    }

    .players-page .table-status-row {
        align-items: flex-start;
        flex-direction: column;
    }

    .players-page .table-status-note {
        text-align: left;
    }
}
