/* ==========================================================================
   Player Detail — Shot Map
   Shot distance breakdown, rink visualization, metric toggle,
   edge bracket rows, situation blocks, zone mini bars
   ========================================================================== */

/* --------------------------------------------------------------------------
   Shot distance breakdown rows
   -------------------------------------------------------------------------- */

.dist-row {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 4px;
}

.dist-row-label {
    font-size: var(--text-xs);
    font-weight: 800;
    text-transform: uppercase;
    width: 32px;
    flex-shrink: 0;
    color: var(--text-muted);
}

.dist-row-stats {
    font-size: var(--text-xs);
    font-weight: 600;
    color: var(--text-muted);
    flex-shrink: 0;
    min-width: 40px;
    text-align: right;
}

.dist-row-goals {
    display: flex;
    gap: 8px;
    margin-top: 6px;
    padding-top: 6px;
    border-top: 1px solid var(--theme-border-strong);
}

.dist-goal-item {
    flex: 1;
    text-align: center;
}

.dist-goal-label {
    display: block;
    font-size: var(--text-2xs);
    font-weight: 700;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 1px;
}

.dist-goal-value {
    display: block;
    font-size: var(--text-xs);
    font-weight: 800;
    color: var(--text-main);
}

.dist-goal-pct {
    display: block;
    font-size: var(--text-micro);
    font-weight: 600;
    color: var(--text-muted);
}

/* (zone-pctl-badge removed -- replaced by zone-card-pctl) */

/* --------------------------------------------------------------------------
   Shot map -- rink layout
   -------------------------------------------------------------------------- */

.rink-wrapper {
    position: relative;
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
}

.rink-border {
    position: relative;
    border: 1px solid var(--theme-border-strong);
    overflow: hidden;
    background: #FAFAFA;
}

.blue-line {
    height: 3px;
    background: #2A5A8C;
    opacity: 0.5;
}

.goal-line {
    height: 2px;
    background: #8B3030;
    opacity: 0.5;
}

.row-section {
    position: relative;
}

.row-label {
    position: absolute;
    left: -44px;
    top: 50%;
    transform: translateY(-50%);
    font-size: var(--text-3xs);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    width: 38px;
    text-align: right;
}

.zone-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 1px;
    background: var(--theme-border-strong);
}

.zone-cell {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 6px 2px;
    min-height: 36px;
    position: relative;
}

.zone-shots {
    font-size: var(--text-lg-plus);
    font-weight: 800;
    line-height: 1;
}

.zone-label-text {
    font-size: var(--text-3xs);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    opacity: 0.7;
    margin-top: 2px;
}

.zone-pctl {
    font-size: var(--text-2xs);
    font-weight: 600;
    opacity: 0.6;
    margin-top: 1px;
}

.row-divider {
    height: 1px;
    background: var(--theme-border-strong);
}

.faceoff-dots {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.faceoff-dot {
    position: absolute;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #8B3030;
    opacity: 0.35;
}

.goal-net {
    display: flex;
    justify-content: center;
    margin-top: 4px;
}

.behind-net-area {
    margin: 6px 0 0;
    border-radius: 0 0 60px 60px;
    overflow: hidden;
    border: 1px solid var(--theme-border-strong);
}

.behind-net-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 1px;
    background: var(--theme-border-strong);
}

.behind-net-cell {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 6px 2px;
    min-height: 32px;
}
.behind-net-cell .zone-shots { font-size: var(--text-lg); }
.behind-net-cell .zone-label-text { font-size: var(--text-3xs); }
.behind-net-cell .zone-pctl { font-size: var(--text-2xs); }

.footer-area {
    margin-top: 4px;
}

.footer-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2px;
}

.footer-cell {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 6px 4px;
    border: 1px solid var(--theme-border-strong);
}
.footer-cell .zone-shots { font-size: var(--text-lg); }
.footer-cell .zone-label-text { font-size: var(--text-3xs); }
.footer-cell .zone-pctl { font-size: var(--text-2xs); }

.shot-map-legend {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    margin-top: 10px;
    font-size: var(--text-2xs);
    font-weight: 700;
    text-transform: uppercase;
    color: var(--text-muted);
}

.shot-map-legend-bar {
    display: flex;
    height: 8px;
    width: 120px;
}

.shot-map-legend-bar span {
    flex: 1;
}

/* Top zones table */
.topzones-table {
    width: 100%;
    border-collapse: collapse;
}

.topzones-table thead th {
    font-size: var(--text-2xs);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    padding: 0 0 6px 0;
    border-bottom: 1px solid var(--theme-border-strong);
    text-align: left;
}
.topzones-table thead th:nth-child(2) { text-align: center; }
.topzones-table thead th:nth-child(3) { text-align: right; }

.topzones-table tbody td {
    padding: 5px 0;
    font-size: var(--text-xs);
    font-weight: 600;
    border-bottom: 1px solid var(--theme-border-strong);
    color: var(--text-main);
}
.topzones-table tbody tr:last-child td { border-bottom: none; }

.topzones-zone { color: var(--text-main); }
.topzones-rank {
    font-size: var(--text-micro);
    font-weight: 800;
    color: var(--text-muted);
    margin-right: 6px;
}
.topzones-shots {
    text-align: center;
    color: var(--text-muted);
    font-weight: 700;
}
.topzones-pctl { text-align: right; }

.pctl-badge {
    display: inline-block;
    font-size: var(--text-micro);
    font-weight: 800;
    padding: 1px 5px;
    border-radius: 2px;
    min-width: 24px;
    text-align: center;
}
.pctl-badge.pctl-q4 { background: #2E5E3E; color: #B8E6C8; }
.pctl-badge.pctl-q3 { background: #2E6E90; color: #B8D8E8; }
.pctl-badge.pctl-q2 { background: #C08040; color: #FFF0D0; }
.pctl-badge.pctl-q1 { background: #A84848; color: #F0C8C8; }

/* --------------------------------------------------------------------------
   Shot map metric toggle
   -------------------------------------------------------------------------- */
.shotmap-metric-toggle {
    display: flex;
    gap: 1px;
    background: #000;
    border: 1px solid #000;
}
.shotmap-metric-btn {
    font-size: var(--text-2xs);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 2px 8px;
    background: #fff;
    color: #333;
    border: none;
    cursor: pointer;
    font-family: inherit;
}
.shotmap-metric-btn.active {
    background: #000;
    color: #fff;
}
.shotmap-metric-btn:hover:not(.active) {
    background: #f0f0f0;
}

/* --------------------------------------------------------------------------
   Edge bracket rows (burst brackets, shot attempt brackets)
   -------------------------------------------------------------------------- */
.edge-bracket-row {
    display: flex;
    align-items: baseline;
    gap: 6px;
    padding: 2px 0;
}
.edge-bracket-label {
    font-size: var(--text-2xs);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    min-width: 68px;
    color: #333;
}
.edge-bracket-value {
    font-size: var(--text-xs);
    font-weight: 900;
    color: #000;
}
.edge-bracket-avg {
    font-size: var(--text-2xs);
    color: #888;
    margin-left: auto;
}

/* Situation blocks (distance/zones per strength) */
.edge-situation-block {
    margin-bottom: 8px;
    padding-bottom: 6px;
    border-bottom: 1px solid #eee;
}
.edge-situation-block:last-child {
    border-bottom: none;
    margin-bottom: 0;
}
.edge-sit-label {
    font-size: var(--text-2xs);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #555;
    margin-bottom: 4px;
}

/* Zone mini bars (per-strength zone breakdown) */
.zone-mini-bars {
    display: flex;
    flex-direction: column;
    gap: 3px;
}
.zone-mini-row {
    display: flex;
    align-items: center;
    gap: 6px;
    height: 18px;
}
.zone-mini-tag {
    font-size: var(--text-2xs);
    font-weight: 900;
    text-transform: uppercase;
    width: 20px;
    text-align: center;
}
.zone-mini-tag.oz { color: #22863a; }
.zone-mini-tag.nz { color: #6a737d; }
.zone-mini-tag.dz { color: #cb2431; }
.zone-mini-track {
    flex: 1;
    height: 10px;
    background: #f0f0f0;
    border: 1px solid #ddd;
    position: relative;
}
.zone-mini-fill {
    height: 100%;
    transition: width 0.3s ease;
}
.zone-mini-fill.oz { background: #22863a; opacity: 0.7; }
.zone-mini-fill.nz { background: #6a737d; opacity: 0.5; }
.zone-mini-fill.dz { background: #cb2431; opacity: 0.7; }
.zone-mini-val {
    font-size: var(--text-2xs);
    font-weight: 700;
    min-width: 36px;
    text-align: right;
}
.zone-mini-pctl {
    font-size: var(--text-2xs);
    font-weight: 700;
    min-width: 28px;
    text-align: right;
}
