/* Compare Teams: the comparison of Daily Scrims (styles/dailyscrims.css) on its own page, and a rating chart that names its dates. */
.cp-page .ds-card--compare { margin-top: 18px; }
.cp-pick { align-items: flex-end; }
.cp-team-link { display: flex; flex-direction: column; align-items: center; gap: 8px; color: inherit; text-decoration: none; }
.cp-team-link:hover h4 { color: var(--primary); }

/* head to head as results: a scrim or a tournament match each, with its score in sets */
.cp-results { display: flex; flex-direction: column; gap: 6px; margin-top: 6px; }
.cp-result {
    display: grid; grid-template-columns: 74px 92px 64px minmax(0, 1fr) 18px; align-items: center; gap: 12px;
    padding: 9px 12px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--border);
    border-left-width: 3px; font-size: 13px; color: inherit; text-decoration: none;
}
.cp-result.is-a { border-left-color: var(--primary); }
.cp-result.is-b { border-left-color: var(--blue); }
.cp-result.is-draw { border-left-color: var(--text-muted); }
.cp-result.is-link:hover { background: var(--surface-3); }
.cp-r-date { font-weight: 700; color: var(--text-dim); white-space: nowrap; }
.cp-r-type { justify-self: start; padding: 1px 9px; border-radius: 99px; font-size: 10.5px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; }
.cp-r-type--scrim { background: rgba(174, 232, 117, 0.14); color: var(--primary); }
.cp-r-type--tourn { background: rgba(224, 197, 63, 0.16); color: #e8d36a; }
.cp-r-score { font-family: var(--font-display); font-size: 18px; letter-spacing: 0.02em; white-space: nowrap; }
.cp-r-who { color: var(--text-dim); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cp-r-open { color: var(--text-muted); font-weight: 800; }
.cp-result.is-link:hover .cp-r-open { color: var(--primary); }
@media (max-width: 620px) {
    /* the type column is wide enough for "Tournament" (it ran into the score at 78px), and the date column for "29 Sept 26" */
    .cp-result { grid-template-columns: auto auto auto minmax(0, 1fr); gap: 8px; padding: 9px 10px; }
    .cp-r-type { padding: 1px 7px; font-size: 9.5px; letter-spacing: 0.04em; }
    .cp-r-open { display: none; }
}
/* a narrow phone: who won and the games go on a line of their own under date, type and score (beside them it was left a few letters) */
@media (max-width: 460px) {
    .cp-result { grid-template-columns: auto auto minmax(0, 1fr); row-gap: 4px; }
    .cp-r-score { justify-self: end; }
    .cp-r-who { grid-column: 1 / -1; white-space: normal; }
}

/* the rating chart: a name for every month under it, the first and the last day at the ends, a pointer that reads the day */
.cp-line { padding-bottom: 2px; }
.cp-axis { position: relative; display: block; height: 18px; margin-top: 6px; }
.cp-tick { position: absolute; top: 0; transform: translateX(-50%); font-size: 10.5px; font-weight: 700; color: var(--text-muted); white-space: nowrap; }
.cp-tick--end { color: var(--text-dim); }
.cp-tick--start { transform: none; }
.cp-tick--last { transform: translateX(-100%); }
.cp-guide { position: absolute; width: 1px; background: var(--text-muted); opacity: 0.8; pointer-events: none; }
.cp-line-tip {
    position: absolute; z-index: 3; display: flex; flex-direction: column; gap: 2px; padding: 7px 10px; border-radius: 10px;
    background: var(--surface-2); border: 1px solid var(--border-strong); box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35);
    font-size: 12px; white-space: nowrap; pointer-events: none;
}
.cp-line-tip b { font-size: 12px; color: var(--text); }
.cp-line-tip span { display: inline-flex; align-items: center; gap: 6px; color: var(--text-dim); }
.cp-line-tip i { display: inline-block; width: 10px; height: 4px; border-radius: 99px; }
.cp-line-tip strong { color: var(--text); margin-left: auto; padding-left: 10px; }
