/* Compact event rows; wide desktop layouts float splits into the adjacent space. */
.profile-meet-results-list{display:block;margin-top:8px;border:1px solid #e0e6ef;border-radius:0 0 12px 12px;overflow:hidden;background:#fff;container-type:inline-size;container-name:profile-results}
.profile-meet-results-table{--result-columns:minmax(96px,.65fr) 64px 102px minmax(0,1.6fr);--result-value-font-size:14px;--result-delta-line-height:13.2px;display:block;box-sizing:border-box;width:100%;border-collapse:collapse;margin:0;font-variant-numeric:tabular-nums}
.profile-meet-results-table thead,.profile-meet-results-table tbody{display:block}
.profile-meet-results-table thead tr,.profile-meet-results-table .profile-results-event{display:grid;grid-template-columns:var(--result-columns);align-items:center}
.profile-meet-results-table thead th{padding:12px 10px;text-align:left;background:#eaf2ff;color:#12345f;font-size:11px;font-weight:700;text-transform:uppercase;border:0;align-self:stretch}
.profile-meet-results-table tbody .profile-results-event{border-top:1px solid #e0e6ef;background:#fff}
.profile-meet-results-table tbody .profile-results-event>th,.profile-meet-results-table tbody .profile-results-event>td{min-width:0;padding:13px 10px;border:0;vertical-align:middle;background:transparent;white-space:normal;text-align:left}
.profile-meet-results-table .profile-results-event__name,.profile-meet-results-table .profile-results-pb,.profile-result-round__time .swim-time-main{font-size:14px;font-weight:500;line-height:1.4;color:#132e51}
.profile-meet-results-table .profile-results-event__name{display:flex;align-items:center;flex-wrap:wrap;gap:4px 6px;overflow-wrap:break-word}
.profile-meet-results-table tbody .profile-results-event>.profile-results-event__name{align-self:start;padding-top:calc(13px + var(--result-delta-line-height))}
.profile-results-event-label{min-width:0}
.profile-meet-results-table .profile-results-pb{align-self:start;display:flex;flex-direction:column;align-items:flex-end;gap:3px;white-space:nowrap;text-align:right}
.profile-meet-results-table .profile-results-pb::before{content:'';display:block;flex:none;width:100%;height:var(--result-delta-line-height)}
.profile-results-time-stack{display:flex;flex-direction:column;align-items:flex-end;width:100%;max-width:100%}
.profile-result-rounds,.profile-result-rounds.has-rounds{display:grid;grid-template-columns:1fr;gap:12px;width:100%}
.profile-result-round{display:grid;grid-template-columns:22px minmax(0,1fr);gap:8px;align-items:center;width:100%;min-width:0}
.profile-result-round__label{display:flex;flex-direction:column;align-items:flex-start;gap:4px}
.profile-round-date{font-size:8px;line-height:1.3;color:#738197;overflow-wrap:anywhere}
.profile-result-round__time{display:flex;flex-direction:column;align-items:flex-end;justify-self:stretch;gap:3px;min-width:0;white-space:nowrap;text-align:right}
.profile-result-round__time .recent-meet-delta{margin:0;font-size:11px;line-height:1.2;font-weight:700}
.profile-result-round__time .recent-meet-delta--empty,.profile-result-round__time .reaction-time--empty{visibility:hidden}
.profile-result-round__time .swim-time-stack{display:flex;flex-direction:column;align-items:flex-end;gap:3px}
.profile-result-round__time .reaction-time{font-size:10px;font-weight:500;line-height:1.25;color:#657c98}
.profile-results-time-stack>.profile-result-points{display:block;align-self:flex-end;margin:8px 0 0;font-size:10px;line-height:1.2;text-align:right;color:#6f8096;font-weight:400;white-space:nowrap}
/* Keep numeric values right-aligned; the Time label starts at a seven-character time track. */
.profile-meet-results-table thead .profile-results-pb-head{text-align:right}
.profile-meet-results-table thead .profile-results-time-head{display:flex;justify-content:flex-end;padding-right:0;text-align:left}
.profile-results-time-head__track{flex:none;width:7ch;font-size:var(--result-value-font-size);text-align:left}
.profile-results-time-head__track>span{font-size:11px}
.profile-meet-results-table tbody .profile-results-event>.profile-results-times{align-self:start;display:flex;justify-content:flex-end;padding-right:0;text-align:right}
.profile-meet-results-table .profile-results-splits-cell{display:flex;align-items:center;justify-content:center;gap:8px;padding-left:0;padding-right:0}
.profile-results-splits-cell>.swim-splits-icon,.profile-round-split-controls>.swim-splits-icon{box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;flex:none;width:30px;min-width:30px;max-width:100%;height:30px;margin:0;padding:3px;border:1px solid #d5e1f0;border-radius:7px;background:#f3f7fd;color:#315981;box-shadow:none;cursor:pointer}
.profile-results-splits-cell>.swim-splits-icon[aria-expanded=true],.profile-round-split-controls>.swim-splits-icon[aria-expanded=true]{background:#e6effa;border-color:#7299c4}
.profile-result-splits__body{min-width:0;flex:1;font-size:11px}
.profile-result-splits__body[hidden]{display:none!important}
.profile-result-splits__body .swim-split-columns{margin-top:0;gap:0 7px}
.profile-round-split-controls{display:grid;grid-template-rows:repeat(2,minmax(30px,1fr));align-items:center;align-self:stretch;gap:12px;flex:none}
.profile-round-split-controls>*{justify-self:center}
.profile-round-split-placeholder{display:block;width:30px;height:30px}
.profile-meet-results-table .profile-results-day{display:block}
.profile-meet-results-table .profile-results-day td{display:block;padding:9px 14px;background:#edf2f8;border:0;border-top:1px solid #e0e6ef;text-align:center}
.profile-results-day td>span{display:flex;align-items:center;gap:14px;font-size:10px;font-weight:700;color:#5b7597;text-transform:uppercase;letter-spacing:.04em}
.profile-results-day td>span::before,.profile-results-day td>span::after{content:'';height:1px;background:#d3dfec;flex:1}
.profile-results-day td>span>b{padding:4px 13px;border-radius:999px;background:#fff;font-weight:700}

@media(min-width:821px){
  .profile-result-splits__body .event-splits-item,.profile-result-splits__body .event-splits-summary,.profile-result-splits__body .event-splits-total{padding:8px;gap:6px}
  .profile-result-splits__body .event-splits-item-left,.profile-result-splits__body .event-splits-main{font-size:13px}
  .profile-result-splits__body .event-splits-sub{font-size:9px;line-height:1.3}
  .profile-result-splits__body .event-splits-compact-head{margin:8px 8px 6px;padding:5px 7px;font-size:9px}
  @container profile-results (max-width:560px){
    .profile-meet-results-table{--result-columns:minmax(0,1fr) 64px 102px 50px}
    .results-page .profile-meet-results-table{--result-columns:minmax(0,1fr) 64px 102px 64px}
    .profile-meet-results-table .profile-results-splits-cell{display:contents}
    .profile-results-splits-cell>.swim-splits-icon,.profile-results-splits-cell>.profile-round-split-controls{grid-column:4;grid-row:1;justify-self:center}
    .profile-results-splits-cell>.profile-result-splits__body{grid-column:1/-1;grid-row:2;padding:10px;background:#f7faff;border-top:1px solid #e0e6ef}
  }
}

/* One race badge design across history, profile results, meet results, and split dialogs. */
.swimmer-page .course-results-panel .event-results .race-tag,
.profile-result-round .race-tag,.results-page .race-tag:not(.result-qualifier-badge),.swim-split-summary__result .race-tag{box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;flex:none;width:22px;min-width:22px;height:22px;margin:0;padding:0;border:1px solid #d5e1f6;border-radius:7px;background:#eaf1fc;color:#24559b;font-family:inherit;font-size:10px;font-weight:700;line-height:1;letter-spacing:0;vertical-align:middle}

/* Meet-wide cards reuse the event table without the old scale transform. */
.results-page .results-swimmer-card .profile-meet-results-list{margin-top:16px;max-width:100%;box-shadow:none}
.results-page .profile-meet-results-table .recent-meet-delta.good{color:#178147}
.results-page .profile-meet-results-table .recent-meet-delta.bad{color:#bd2836}
.results-page .results-swimmer-card--female .profile-meet-results-table thead th{background:#fceef5}
.profile-meet-results-table .results-qualifier-badges{display:inline-flex;flex:0 1 auto;flex-wrap:wrap;gap:4px;width:auto;margin:0}
.profile-meet-results-table .result-qualifier-badge{font-size:10px;line-height:1.3;white-space:normal}
a.result-qualifier-badge{text-decoration:none}
a.result-qualifier-badge:hover,a.result-qualifier-badge:focus-visible{background:#d3f0df;text-decoration:underline;outline-offset:3px}
@container profile-results (max-width:560px){.profile-meet-results-table tbody .profile-results-event>.profile-results-event__name{padding-top:calc(12px + var(--result-delta-line-height))}}

/* Fixed-width dates keep age aligned; time columns reserve trophy and race slots even when empty. */
.swimmer-page .course-results-panel .event-results .history-date-cell{white-space:nowrap;font-variant-numeric:tabular-nums}
.swimmer-page .course-results-panel .event-results .history-date-cell .meet-age{display:inline-block;min-width:2ch;font-variant-numeric:tabular-nums}
@media(max-width:820px){
  .swimmer-page #recent_meet .profile-meet-results-block{padding:0!important}
  .swimmer-page #recent_meet .profile-meet-results-list{margin:0;border:0;border-radius:0 0 14px 14px}
  .swimmer-page #profile_meets #recent_meet .profile-meet-context+.profile-meet-results-list{margin-top:0}
  .profile-meet-results-table{--result-columns:minmax(0,1fr) 57px 94px 50px;--result-value-font-size:12px;--result-delta-line-height:12px}
  .profile-meet-results-table thead th{font-size:10px;padding:10px 6px}
  .profile-meet-results-table tbody .profile-results-event>th,.profile-meet-results-table tbody .profile-results-event>td{padding:12px 6px}
  .profile-meet-results-table .profile-results-event__name,.profile-meet-results-table .profile-results-pb,.profile-result-round__time .swim-time-main{font-size:12px}
  .profile-result-round{gap:5px}
  .profile-result-round__time .recent-meet-delta{font-size:10px}
  .profile-result-round__time .reaction-time{font-size:9px}
  .profile-results-time-head__track>span{font-size:10px}
  .profile-result-points{font-size:9px}
  .profile-meet-results-table .profile-results-splits-cell{display:contents}
  .profile-results-splits-cell>.swim-splits-icon,.profile-results-splits-cell>.profile-round-split-controls{grid-column:4;grid-row:1;justify-self:center}
  .profile-results-splits-cell>.profile-result-splits__body{grid-column:1/-1;grid-row:2;padding:10px;background:#f7faff;border-top:1px solid #e0e6ef}
  .profile-result-splits__body .swim-split-columns{gap:0 8px}
  .results-page .results-swimmer-card .profile-meet-results-list{border-radius:0 0 10px 10px}
  .swimmer-page .course-results-panel .event-results .report-table th,.swimmer-page .course-results-panel .event-results .report-table td{box-sizing:border-box}
  .swimmer-page .course-results-panel .event-results .report-table th:first-child,.swimmer-page .course-results-panel .event-results .report-table td.history-date-cell{width:98px;padding-left:3px;padding-right:6px;white-space:nowrap}
  .swimmer-page .course-results-panel .event-results .report-table th:nth-child(2),.swimmer-page .course-results-panel .event-results .report-table td.history-meet-cell{width:auto;padding-right:6px}
  .swimmer-page .course-results-panel .event-results .report-table th:nth-child(3),.swimmer-page .course-results-panel .event-results .report-table td.result-time-td{width:calc(var(--history-time-width,7ch) + 48px);padding-right:0;text-align:right}
  .swimmer-page .course-results-panel .event-results .report-table th:nth-child(3){padding-right:25px}
  .swimmer-page .course-results-panel .event-results .result-time-cell{--result-record-slot:18px;--result-time-slot:calc(var(--history-time-width,7ch) + 2px);--result-badge-slot:22px;column-gap:3px;justify-content:end;width:max-content;max-width:none;margin-left:auto;margin-right:0}
  .swimmer-page .course-results-panel .event-results .result-time-main{justify-content:flex-end;text-align:right}
  .swimmer-page .course-results-panel .event-results .swim-time-stack{align-items:flex-end;justify-items:end;text-align:right}
  .swimmer-page .course-results-panel .event-results .swim-time-main{line-height:22px}
  .swimmer-page .course-results-panel .event-results .reaction-time--block{text-align:right}
  .swimmer-page .course-results-panel .event-results .result-record-slot,.swimmer-page .course-results-panel .event-results .result-badge-slot{min-height:22px}
}
@media(max-width:360px){
  .profile-meet-results-table{--result-columns:minmax(0,1fr) 48px 86px 42px;--result-value-font-size:11px}
  .profile-meet-results-table tbody .profile-results-event>th,.profile-meet-results-table tbody .profile-results-event>td,.profile-meet-results-table thead th{padding-left:4px;padding-right:4px}
  .profile-meet-results-table .profile-results-event__name,.profile-meet-results-table .profile-results-pb,.profile-result-round__time .swim-time-main{font-size:11px}
  .profile-result-round{grid-template-columns:19px minmax(0,1fr)}
  .profile-round-split-placeholder{width:30px}
  .swimmer-page .course-results-panel .event-results .race-tag,
  .profile-result-round .race-tag,.results-page .race-tag:not(.result-qualifier-badge),.swim-split-summary__result .race-tag{width:19px;min-width:19px;height:19px;font-size:9px}
  .swimmer-page .course-results-panel .history-meet-cell .profile-result-meet-link{overflow-wrap:anywhere}
  .swimmer-page .course-results-panel .event-results .swim-time-main{line-height:19px}
  .swimmer-page .course-results-panel .event-results .result-record-slot,.swimmer-page .course-results-panel .event-results .result-badge-slot{min-height:19px}
  .swimmer-page .course-results-panel .event-results .result-time-cell{--result-badge-slot:19px;column-gap:2px}
  .swimmer-page .course-results-panel .event-results .report-table th:first-child,.swimmer-page .course-results-panel .event-results .report-table td.history-date-cell{width:91px;padding-left:2px;padding-right:3px;font-size:10px}
  .swimmer-page .course-results-panel .event-results .report-table th:nth-child(3),.swimmer-page .course-results-panel .event-results .report-table td.result-time-td{width:calc(var(--history-time-width,7ch) + 43px)}
  .swimmer-page .course-results-panel .event-results .report-table th:nth-child(3){padding-right:21px}
}

/* Keep the table edge just beyond the controls, with open profile splits beside it. */
@media(min-width:821px){
  .profile-meet-results-list{border:0;border-radius:0;overflow:visible;background:transparent}
  .profile-meet-results-table{--result-columns:minmax(0,1fr) 72px 118px 50px;width:min(100%,480px);border:1px solid #e0e6ef;background:#fff}
  .profile-meet-results-table:not(:has(.swim-splits-icon)){--result-columns:minmax(0,1fr) 72px 118px 8px;width:min(100%,428px)}
  .profile-meet-results-table:not(:has(.swim-splits-icon)) .profile-results-splits-cell,
  .profile-meet-results-table:not(:has(.swim-splits-icon)) thead th:last-child{padding-left:0;padding-right:0}
  .profile-meet-results-table .profile-results-event{position:relative}
  .profile-meet-results-table .profile-results-splits-cell{display:contents}
  .profile-results-splits-cell>.swim-splits-icon,.profile-results-splits-cell>.profile-round-split-controls{grid-column:4;grid-row:1;justify-self:center}
  .profile-results-splits-cell>.profile-result-splits__body{grid-column:1/-1;grid-row:2;padding:12px;background:#f7faff;border-top:1px solid #e0e6ef}
  @container profile-results (min-width:680px){
    .profile-meet-results-table:has(.swim-splits-icon){width:min(480px,calc(100cqw - 244px))}
    .profile-results-splits-cell>.profile-result-splits__body{position:absolute;grid-column:auto;grid-row:auto;left:calc(100% + 16px);top:0;width:min(500px,calc(100cqw - 100% - 18px));box-sizing:border-box;padding:10px 0;border:0;background:transparent;z-index:2}
    .profile-result-splits__body .swim-split-columns{margin-left:0;margin-right:0}
    .profile-result-splits__body:has(.swim-split-columns--single){max-width:280px}
  }
  @container profile-results (min-width:680px) and (max-width:880px){
    .profile-result-splits__body .swim-split-columns:not(.swim-split-columns--single){display:flex;flex-direction:column;gap:12px}
    .profile-result-splits__body .swim-split-columns:not(.swim-split-columns--single) .swim-split-card{display:block}
  }
}

/* Meet-result cards remain full width and expand their splits inside the row. */
.results-page .results-swimmer-card .profile-meet-results-table{width:100%;box-sizing:border-box}
.results-page .profile-results-splits-cell>.profile-result-splits__body{position:static;grid-column:1/-1;grid-row:2;left:auto;top:auto;width:100%;max-width:none;box-sizing:border-box;padding:12px;background:#f7faff;border-top:1px solid #e0e6ef}
.results-page .profile-result-splits__body .swim-split-columns{margin-left:auto;margin-right:auto;max-width:580px}
@media(min-width:821px){
  .results-page .profile-meet-results-table{--result-columns:minmax(0,1fr) 72px 118px 50px}
  .results-page .profile-result-splits__body .swim-split-columns:not(.swim-split-columns--single){display:grid;grid-template-columns:repeat(var(--split-columns,2),minmax(0,1fr));gap:0 12px}
  .results-page .profile-result-splits__body .swim-split-columns:not(.swim-split-columns--single) .swim-split-card{display:grid}
}

/* Readable split labels, intervals, cumulative values, and summary controls. */
.swim-split-card .event-splits-item-left,.swim-split-card .event-splits-main,
.profile-result-splits__body .event-splits-item-left,.profile-result-splits__body .event-splits-main{font-size:17px;line-height:1.3}
.swim-split-card .event-splits-sub,.profile-result-splits__body .event-splits-sub{font-size:12px;line-height:1.35}
.swim-split-card .event-splits-compact-head,.profile-result-splits__body .event-splits-compact-head{font-size:12px;padding:7px 10px;margin:10px 10px 8px}
.swim-split-card .event-splits-item,.swim-split-card .event-splits-summary,.swim-split-card .event-splits-total{padding:10px;gap:10px}
.swim-split-columns.swim-split-columns--single{width:min(100%,280px)}
.swim-split-summary__date,.swim-split-summary__meet{font-size:14px}
.swim-split-summary__result .reaction-time{font-size:12px}
.swim-split-summary__result .swim-time-main{font-size:21px}
.swim-split-empty{font-size:14px}
@media(max-width:820px){
  .swim-split-card .event-splits-item-left,.swim-split-card .event-splits-main,
  .profile-result-splits__body .event-splits-item-left,.profile-result-splits__body .event-splits-main{font-size:15px}
  .swim-split-card .event-splits-sub,.profile-result-splits__body .event-splits-sub{font-size:12px}
  .swim-split-card .event-splits-item,.swim-split-card .event-splits-summary,.swim-split-card .event-splits-total{padding:9px 8px;gap:7px}
  .swim-split-card .event-splits-compact-head{font-size:12px;margin:8px 6px;padding:6px}
  .swim-split-summary__date,.swim-split-summary__meet{font-size:12px}
  .swim-split-summary__result .swim-time-main{font-size:18px}
  .swim-split-summary__result .reaction-time{font-size:12px}
  .swim-split-summary__result .record-trophy{font-size:14px}
  .swimmer-page #profile_meets #current_nominations .meet-event-planner-table-wrap,
  .swimmer-page #profile_meets #current_nominations .recent-meet-table-wrap{height:auto;max-height:min(60dvh,520px)!important;overflow-x:hidden!important;overflow-y:auto!important;overscroll-behavior-y:contain;scrollbar-width:thin;scrollbar-gutter:stable}
}
