/* Competition browser and profile */
.comp-browser-panel {
    padding: 0;
    overflow: hidden;
}

.comp-browser-panel:has(.comp-country-control.is-open) {
    overflow: visible;
}

.comp-search-toolbar {
    --comp-header-inline: 2rem;
    border-top-left-radius: inherit;
    border-top-right-radius: inherit;
    display: grid;
    align-content: space-between;
    gap: 1.6rem;
    padding: 1.55rem var(--comp-header-inline) 1.75rem;
    border-bottom: 1px solid var(--line-soft);
    background:
        linear-gradient(90deg, rgba(238, 243, 245, .94) 0%, rgba(238, 243, 245, .68) 44%, rgba(238, 243, 245, .10) 78%),
        linear-gradient(180deg, rgba(16, 42, 58, .02) 52%, rgba(16, 42, 58, .16) 100%),
        url("/res/img/comp/hero-comp.jpg");
    background-position: center center;
    background-size: cover;
    background-repeat: no-repeat;
}

.comp-search-toolbar .comp-browser-heading {
    align-items: center;
    padding: 0;
    background: transparent;
}
.comp-browser-heading .page-heading-actions { align-self: center; }
.comp-browser-heading__identity {
    min-width: 0;
    max-width: 100%;
}
.comp-browser-heading h1 {
    color: var(--text);
    font-size: 1.75rem;
    text-shadow: 0 1px 1px rgba(255, 255, 255, .48);
}
.comp-browser-heading .page-action {
    box-shadow: var(--shadow-control);
}
.comp-profile-icon {
    display: grid; place-items: center; flex: 0 0 2.9rem; width: 2.9rem; height: 2.9rem;
    border-radius: .85rem; color: #fff; background: linear-gradient(135deg, #0284c7, #f97316);
    box-shadow: 0 8px 20px rgba(2, 132, 199, .18);
}
.comp-profile-icon .ui-icon { width: 1.5rem; height: 1.5rem; filter: brightness(0) invert(1); }

.comp-search-form {
    position: relative;
    z-index: var(--z-local-popover);
    width: min(100%, 820px);
    display: grid;
    grid-template-columns: minmax(100px, .55fr) minmax(170px, 1fr) minmax(210px, 1.65fr) auto;
    gap: .65rem;
    align-items: end;
    padding: .85rem;
    border: 1px solid color-mix(in srgb, var(--panel-border) 82%, transparent);
    border-radius: var(--radius-md);
    background: color-mix(in srgb, var(--surface-raised) 94%, transparent);
    box-shadow: 0 6px 18px rgba(15, 54, 72, .12);
    transition: border-color 160ms ease, box-shadow 160ms ease;
}
.comp-search-form:focus-within {
    border-color: var(--control-border-hover);
    box-shadow: var(--focus-ring), 0 8px 22px rgba(15, 54, 72, .14);
}
.comp-search-field { display: grid; gap: .32rem; min-width: 0; font-size: .78rem; font-weight: 700; color: var(--muted); }
.comp-search-field .form-control { min-width: 0; height: 2.65rem; }
.comp-country-control { --autocomplete-input-height: 2.65rem; }
.comp-country-control input[data-autocomplete-input],
#comp-registration-country { font-size: 16px; }
.comp-search-submit { display: grid; place-items: center; width: 2.65rem; height: 2.65rem; border: 0; border-radius: .65rem; background: var(--control-primary); color: #fff; cursor: pointer; transition: background 140ms ease, box-shadow 140ms ease; }
.comp-search-submit:hover { background: var(--control-primary-hover); }
.comp-search-submit:focus-visible { outline: 2px solid var(--focus-outline); outline-offset: 2px; box-shadow: var(--focus-ring); }
.comp-search-submit .ui-icon { filter: brightness(0) invert(1); }

.comp-workspace { min-height: 24rem; }
.comp-workspace-error { margin: 1rem 1.5rem 0; padding: .8rem 1rem; border-radius: .65rem; color: #991b1b; background: #fef2f2; }
.comp-results-surface { padding: 6px 8px 16px; }
.comp-result-table-wrap { overflow-x: visible; }
.comp-browser-table {
    --comp-result-grid: 42px minmax(190px, 1.65fr) minmax(150px, 1fr) minmax(90px, .55fr) 68px;
    width: 100%;
    display: block;
    border-collapse: separate;
}
.comp-browser-table thead, .comp-browser-table tbody { display: block; }
.comp-browser-table tr {
    display: grid;
    grid-template-columns: var(--comp-result-grid);
    column-gap: 10px;
    align-items: center;
    border-bottom: 1px solid var(--line-soft);
}
.comp-browser-table th {
    min-width: 0;
    padding: 9px 0;
    color: var(--muted);
    font-size: var(--font-sm);
    font-weight: 700;
    letter-spacing: 0;
    text-align: left;
    text-transform: uppercase;
    white-space: nowrap;
}
.comp-browser-table td { min-width: 0; padding: 9px 0; vertical-align: middle; }
.comp-browser-row { cursor: pointer; transition: background .15s ease; }
.comp-browser-row:hover, .comp-browser-row:focus-visible { background: var(--row-hover); }
.comp-browser-row:focus-visible { outline: 2px solid var(--focus-outline); outline-offset: -2px; }
.comp-browser-icon { position: relative; display: grid; place-items: center; width: 34px; height: 34px; }
.comp-browser-trophy { display: block; width: 32px; height: 32px; object-fit: contain; }
.comp-browser-main { display: grid; gap: 2px; min-width: 0; }
.comp-browser-main strong, .comp-browser-main span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.comp-browser-main strong { color: var(--text); }
.comp-browser-main span, .comp-browser-countries { color: var(--muted); font-size: var(--font-md); }
.comp-browser-main .comp-browser-title { display: flex; align-items: center; gap: 6px; min-width: 0; }
.comp-browser-title strong { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.comp-browser-country-col, .comp-browser-scoring-col { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); font-size: var(--font-sm); }
.comp-browser-season-col { text-align: center; font-variant-numeric: tabular-nums; }
.comp-browser-mobile-meta { display: none; }
.comp-browser-empty { display: grid; justify-items: center; gap: .55rem; padding: 4rem 1.5rem; text-align: center; color: var(--text-muted, #667085); }
.comp-browser-empty .ui-icon { width: 2rem; height: 2rem; }
.comp-browser-empty h2, .comp-browser-empty p { margin: 0; }
.comp-results-truncated { margin: 0; padding: .9rem 1rem; color: var(--text-muted, #667085); text-align: center; }

.comp-profile-host, .comp-profile-view { min-width: 0; }
.comp-profile-view { display: grid; gap: 0; align-content: start; }
.comp-profile-context {
    min-width: 0;
    min-height: 48px;
    display: flex;
    align-items: center;
    padding: 0 18px;
    border-bottom: 1px solid var(--panel-border);
    background: var(--panel);
}
.comp-results-back { display: inline-flex; align-items: center; gap: .35rem; }
.comp-results-back .ui-icon { width: 16px; height: 16px; }
.comp-profile { display: grid; gap: 0; align-content: start; background: var(--panel); container-name: comp-profile; container-type: inline-size; }
.comp-profile-header {
    display: grid;
    grid-template-columns: 56px minmax(0, 1fr) auto;
    gap: 14px;
    align-items: center;
    padding: 20px 24px 17px;
    border: 0;
    border-radius: 0;
    background: var(--panel);
}
.comp-profile-icon {
    width: 54px;
    height: 54px;
    border: 1px solid var(--avatar-border);
    border-radius: 50%;
    background: var(--avatar-bg);
    box-shadow: none;
}
.comp-profile-icon .ui-icon { width: 25px; height: 25px; filter: none; opacity: .78; }
.comp-profile-title { min-width: 0; }
.comp-profile-title p { margin: 0 0 2px; color: var(--muted); font-size: .75rem; font-weight: 700; letter-spacing: .045em; text-transform: uppercase; }
.comp-profile-title h1 { margin: 0; overflow-wrap: anywhere; font-size: clamp(1.55rem, 2vw, 1.85rem); line-height: 1.12; }
.comp-profile-badges { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 7px; }
.comp-profile-badges span { padding: 3px 8px; border: 1px solid var(--badge-border); border-radius: 999px; background: var(--badge-bg); color: var(--badge-text); font-size: var(--font-sm); font-weight: 700; }
.comp-profile-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .45rem; min-width: 0; }
.comp-profile-actions form { margin: 0; }
.comp-profile-actions .comp-register-action, .comp-profile-actions .comp-registration-open { min-width: 44px; min-height: 44px; }
.comp-register-action:focus-visible, .comp-registration-open:focus-visible { outline: 2px solid var(--focus-outline); outline-offset: 2px; box-shadow: var(--focus-ring); }
.comp-registration-status {
    margin: 0;
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
    line-height: 1.5;
}
.comp-registration-content { display: grid; gap: var(--form-grid-gap); }
.comp-registration-wing { grid-column: 1 / -1; }
.comp-registration-content .field-error { margin: 0; }
.comp-registration-content small { color: var(--muted); line-height: 1.5; }
[data-comp-registration-summary] { min-width: 0; color: var(--muted); font-size: var(--font-sm); overflow-wrap: anywhere; }
.comp-tabs-bar { margin: 0; border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--panel-border); }
.comp-tabs { padding-inline: 1rem; }
.comp-profile-content { min-height: 22rem; }
.comp-profile-content > .pilot-profile-panel { padding: 0; }
.comp-results-toolbar { display: flex; justify-content: flex-end; margin-bottom: .8rem; }
.comp-info-layout { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.comp-info-description { grid-column: 1 / -1; padding: 1rem 1.1rem; border-radius: .8rem; background: rgba(14, 165, 233, .06); }
.comp-info-description h2, .comp-info-card h2 { margin: 0 0 .7rem; font-size: 1rem; }
.comp-info-description p { margin: 0; white-space: pre-line; line-height: 1.55; }
.comp-info-card { padding: 1rem 1.1rem; border: 1px solid var(--border-color, #e4e7ec); border-radius: .8rem; }
.comp-info-list { display: grid; gap: 0; margin: 0; }
.comp-info-list > div { display: grid; grid-template-columns: minmax(110px, .7fr) minmax(0, 1.5fr); gap: .8rem; padding: .65rem 0; border-top: 1px solid var(--border-color, #eef2f6); }
.comp-info-list > div:first-child { border-top: 0; }
.comp-info-list dt { color: var(--text-muted, #667085); font-size: .8rem; font-weight: 700; }
.comp-info-list dd { margin: 0; }
.comp-info-editor-list { display: flex; flex-wrap: wrap; align-items: center; gap: .2rem .45rem; }
.comp-info-editor-list span { display: inline-flex; align-items: center; gap: .45rem; }
.comp-info-editor-list span:not(:last-child)::after { content: "\00b7"; color: var(--text-muted, #667085); }
.comp-info-admin { grid-column: 1 / -1; }
.pilot-profile-tab-icon--results { mask-image: url("/res/icons/ui/trophy.svg"); }
.pilot-profile-tab-icon--teams { mask-image: url("/res/icons/ui/users.svg"); }
.pilot-profile-tab-icon--live { mask-image: url("/res/icons/ui/map-pin.svg"); }
.pilot-profile-tab-icon--admin { mask-image: url("/res/icons/ui/shield-check.svg"); }
.comp-live {
    display: grid;
    gap: 1rem;
    padding: 1rem;
}
.comp-live-header {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: .65rem;
}
.comp-live-heading { min-width: 0; display: flex; align-items: baseline; gap: .65rem; }
.comp-live-header h2 { margin: 0; font-size: 1.1rem; }
.comp-live-header .comp-live-phase { margin-inline-start: auto; }
.comp-live-context {
    display: none;
    min-width: 0;
    overflow: hidden;
    color: var(--muted);
    font-size: var(--font-sm);
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.comp-live-view-bar {
    min-width: 0;
    display: flex;
    align-items: flex-end;
    gap: .75rem;
    border-bottom: 1px solid var(--panel-border);
}
.comp-live-view-tabs {
    min-width: 0;
    flex: 1 1 auto;
    display: flex;
    align-items: flex-end;
    gap: 1.25rem;
}
.comp-live-view-tab {
    min-height: 42px;
    margin-bottom: -1px;
    padding: .55rem .15rem .5rem;
    border: 0;
    border-bottom: 2px solid transparent;
    background: transparent;
    color: var(--muted);
    font: inherit;
    font-weight: 750;
    cursor: pointer;
}
.comp-live-view-tab:hover { color: var(--text); }
.comp-live-view-tab:focus-visible {
    border-radius: var(--radius-sm);
    outline: 2px solid var(--focus-outline);
    outline-offset: 2px;
}
.comp-live-view-tab.is-active {
    border-bottom-color: var(--blue);
    color: var(--blue-dark);
}
.comp-live-focus-toggle {
    flex: 0 0 auto;
    width: 38px;
    height: 38px;
    margin-bottom: 2px;
}
.comp-live-focus-toggle .ui-icon { width: 18px; height: 18px; }
.comp-live-view-panel { min-width: 0; }
.comp-live-view-panel[hidden] { display: none; }
.comp-live-standings-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}
.comp-live-standings-header h3 { margin: 0; font-size: 1.05rem; }
.comp-live-standings-header p { margin: .35rem 0 0; color: var(--muted); line-height: 1.45; }
.comp-live-title-row { display: flex; align-items: center; flex-wrap: wrap; gap: .55rem; }
.comp-live-provisional,
.comp-live-phase {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 2px 8px;
    border: 1px solid var(--badge-border);
    border-radius: 999px;
    background: var(--badge-bg);
    color: var(--badge-text);
    font-size: var(--font-sm);
    font-weight: 750;
}
.comp-live-provisional { border-color: #f2cf72; background: #fff8dc; color: #755100; }
.comp-live-phase[data-phase="live"] { border-color: #8fd0a7; background: #edfbf1; color: #176534; }
.comp-live-phase[data-phase="frozen"] { border-color: #b8c2cd; background: #f3f5f7; color: #475569; }
.comp-live-updated { flex: 0 0 auto; font-size: var(--font-sm); white-space: nowrap; }
.comp-live-updated span { font-weight: 700; }
.comp-live-table-scroll {
    overflow-x: auto;
    border: 1px solid var(--panel-border);
    border-radius: var(--radius-md);
}
.comp-live-table { width: 100%; border-collapse: collapse; background: #fff; }
.comp-live-table th,
.comp-live-table td {
    padding: .7rem .8rem;
    border-bottom: 1px solid var(--line-soft);
    text-align: left;
    white-space: nowrap;
}
.comp-live-table th {
    background: #f8fbfd;
    color: var(--muted);
    font-size: var(--font-sm);
    font-weight: 750;
}
.comp-live-table tbody tr:last-child td { border-bottom: 0; }
.comp-live-table tbody tr:hover { background: var(--row-hover); }
.comp-live-table .is-numeric { text-align: right; font-variant-numeric: tabular-nums; }
.comp-live-pilot { display: inline-flex; align-items: center; gap: .55rem; }
.comp-live-pilot-signal {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #c5ccd3;
}
.comp-live-pilot-signal.is-tracked {
    background: #20a357;
    box-shadow: 0 0 0 3px rgba(32, 163, 87, .14);
}
.comp-live-message { color: var(--muted); font-weight: 700; text-align: center !important; }
.comp-live-map-root {
    position: relative;
    height: min(62vh, 620px);
    min-height: 430px;
}
.comp-live-map-root .live-layout { height: 100%; }
.comp-live-map-root.is-live-panel-minimized .live-layout {
    position: relative;
    grid-template-columns: minmax(0, 1fr);
}
.comp-profile.is-live-focus-container {
    position: fixed;
    inset: 0;
    z-index: var(--z-task-editor-fullscreen);
    width: 100%;
    height: 100dvh;
    overflow: hidden;
    border: 0;
    border-radius: 0;
}
.comp-live.is-focus-mode {
    position: absolute;
    inset: 0;
    z-index: 1;
    grid-template-rows: auto auto minmax(0, 1fr);
    gap: .7rem;
    height: 100%;
    min-height: 0;
    padding: max(.75rem, env(safe-area-inset-top)) max(.75rem, env(safe-area-inset-right))
        max(.75rem, env(safe-area-inset-bottom)) max(.75rem, env(safe-area-inset-left));
    overflow: hidden;
    background: var(--panel);
}
.comp-live.is-focus-mode .comp-live-context { display: block; }
.comp-live.is-focus-mode .comp-live-view-panel:not([hidden]) {
    min-height: 0;
    height: 100%;
    overflow: hidden;
}
.comp-live.is-focus-mode .comp-live-map-root {
    height: 100%;
    min-height: 0;
}
.comp-live.is-focus-mode [data-comp-live-view-panel="standings"] {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
}
.comp-live.is-focus-mode .comp-live-table-scroll {
    min-height: 0;
    height: 100%;
    overflow: auto;
}
@media (min-width: 761px) {
    .comp-live.is-focus-mode .comp-live-table thead {
        position: sticky;
        top: 0;
        z-index: 1;
    }
}
@media (max-width: 760px) {
    .comp-live { padding: .8rem; }
    .comp-live-standings-header { display: grid; gap: .45rem; }
    .comp-live-updated { white-space: normal; }
    .comp-live-table-scroll { overflow-x: visible; }
    .comp-live-table,
    .comp-live-table tbody { display: block; }
    .comp-live-table thead {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip-path: inset(50%);
        white-space: nowrap;
    }
    .comp-live-table tbody tr {
        display: grid;
        grid-template-columns: 2.25rem minmax(0, 1fr) auto;
        grid-template-areas:
            "rank pilot points"
            "rank status distance"
            "rank next signal";
        gap: .25rem .65rem;
        padding: .7rem .75rem;
        border-bottom: 1px solid var(--line-soft);
    }
    .comp-live-table tbody tr:last-child { border-bottom: 0; }
    .comp-live-table td {
        min-width: 0;
        padding: 0;
        border-bottom: 0;
        white-space: normal;
    }
    .comp-live-rank-cell {
        grid-area: rank;
        align-self: center;
        color: var(--muted);
        font-weight: 750;
        text-align: center !important;
    }
    .comp-live-pilot-cell { grid-area: pilot; }
    .comp-live-pilot-cell strong { overflow-wrap: anywhere; }
    .comp-live-status-cell {
        grid-area: status;
        color: var(--muted);
        font-size: var(--font-sm);
    }
    .comp-live-points-cell {
        grid-area: points;
        align-self: start;
        color: var(--text);
        font-weight: 800;
    }
    .comp-live-distance-cell {
        grid-area: distance;
        color: var(--muted);
        font-size: var(--font-sm);
    }
    .comp-live-next-control-cell {
        grid-area: next;
        color: var(--muted);
        font-size: var(--font-sm);
    }
    .comp-live-last-signal-cell {
        grid-area: signal;
        color: var(--muted);
        font-size: var(--font-sm);
    }
    .comp-live-next-control-cell::before,
    .comp-live-last-signal-cell::before {
        content: attr(data-label) ": ";
        font-weight: 700;
    }
    .comp-live-message { grid-column: 1 / -1; }
    .comp-live.is-focus-mode .comp-live-table-scroll {
        overflow-x: hidden;
        overflow-y: auto;
    }
}
.comp-admin-layout { display: grid; gap: .85rem; max-width: 58rem; }
.comp-admin-action-card {
    display: flex; align-items: center; justify-content: space-between; gap: 1.25rem;
    padding: 1rem 1.1rem; border: 1px solid var(--border-color, #e4e7ec); border-radius: .8rem;
    background: var(--surface, #fff);
}
.comp-admin-action-card h2 { margin: 0 0 .28rem; font-size: 1rem; }
.comp-admin-action-card p { margin: 0; color: var(--text-muted, #667085); line-height: 1.45; }
.comp-admin-action-card form { margin: 0; }
.comp-admin-action-card > button, .comp-admin-action-card > form, .comp-admin-action-card > .comp-status-badge { flex: 0 0 auto; }
.comp-admin-actions { display: flex; flex: 0 0 auto; flex-wrap: wrap; justify-content: flex-end; gap: .5rem; }
.comp-admin-action-card--danger { border-color: rgba(185, 28, 28, .25); background: rgba(254, 242, 242, .55); }
.comp-task-pilot-list {
    display: grid;
    border: 1px solid var(--border-color, #e4e7ec);
    border-radius: .7rem;
    background: var(--surface, #fff);
}
.comp-task-pilot-row {
    display: grid;
    grid-template-columns: minmax(9rem, 1fr) auto minmax(12rem, 1.1fr) 36px;
    grid-template-areas:
        "identity status adjustment edit"
        "error error error error";
    align-items: center;
    gap: .35rem .75rem;
    min-width: 0;
    padding: .62rem .75rem;
    border-bottom: 1px solid var(--border-color, #e4e7ec);
    background: var(--surface, #fff);
}
.comp-task-pilot-row:first-child { border-radius: .7rem .7rem 0 0; }
.comp-task-pilot-row:last-child { border-bottom: 0; border-radius: 0 0 .7rem .7rem; }
.comp-task-pilot-row:only-child { border-radius: .7rem; }
.comp-task-pilot-identity { grid-area: identity; min-width: 0; }
.comp-task-pilot-identity strong {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.comp-task-pilot-status-control { grid-area: status; }
.comp-status-badge.comp-task-pilot-status-button {
    justify-content: space-between;
    gap: .28rem;
    width: 7.5rem;
    min-height: 28px;
    max-width: 7.5rem;
    cursor: pointer;
    font: inherit;
    font-size: .75rem;
    line-height: 1.15;
}
.comp-status-badge.comp-task-pilot-status-button:hover { filter: brightness(.98); }
.comp-status-badge.comp-task-pilot-status-button > span {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.comp-status-badge.comp-task-pilot-status-button .ui-icon { width: 13px; height: 13px; flex: 0 0 auto; }
.comp-task-pilot-adjustment-summary {
    grid-area: adjustment;
    display: flex;
    align-items: baseline;
    min-width: 0;
    gap: .3rem;
    font-size: .8rem;
}
.comp-task-pilot-adjustment-label { color: var(--text-muted, #667085); white-space: nowrap; }
.comp-task-pilot-adjustment-summary strong { font-variant-numeric: tabular-nums; white-space: nowrap; }
.comp-task-pilot-adjustment-detail {
    min-width: 0;
    overflow: hidden;
    color: var(--text-muted, #667085);
    text-overflow: ellipsis;
    white-space: nowrap;
}
.comp-task-pilot-edit {
    grid-area: edit;
    display: inline-grid;
    place-items: center;
    width: 36px;
    height: 36px;
    padding: 0;
    border: 1px solid transparent;
    border-radius: 50%;
    background: transparent;
    color: var(--text-color, #25313d);
    cursor: pointer;
}
.comp-task-pilot-edit:hover { border-color: var(--border-color, #d7dee6); background: var(--content-subtle-bg, #f7fafc); }
.comp-task-pilot-edit:disabled { opacity: .4; cursor: not-allowed; }
.comp-task-pilot-edit .ui-icon { width: 17px; height: 17px; }
.comp-task-pilot-row-error {
    grid-area: error;
    margin: .15rem 0 0;
    color: var(--danger, #b42318);
    font-size: .78rem;
}
.comp-task-pilot-saving {
    display: none;
    grid-area: edit;
    justify-self: center;
    width: 17px;
    height: 17px;
    border: 2px solid color-mix(in srgb, var(--accent, #146f68) 22%, transparent);
    border-top-color: var(--accent, #146f68);
    border-radius: 50%;
    animation: app-busy-indicator-spin 680ms linear infinite;
}
.comp-task-pilot-row.htmx-request .comp-task-pilot-edit { visibility: hidden; }
.comp-task-pilot-row.htmx-request .comp-task-pilot-saving { display: block; }
.comp-task-pilot-status-menu {
    width: min(260px, calc(100vw - 20px));
    padding: .3rem;
    border: 1px solid var(--panel-border, #d4dde6);
    border-radius: .65rem;
    background: var(--panel, #fff);
    box-shadow: 0 12px 32px rgba(15, 23, 42, .18);
}
.comp-task-pilot-status-menu button {
    display: flex;
    align-items: center;
    width: 100%;
    min-height: 38px;
    padding: .45rem .65rem;
    border: 0;
    border-radius: .45rem;
    background: transparent;
    color: inherit;
    text-align: left;
    cursor: pointer;
}
.comp-task-pilot-status-menu button:hover,
.comp-task-pilot-status-menu button:focus-visible { background: var(--content-subtle-bg, #f5f8fa); }
.comp-task-pilot-status-menu button[aria-checked="true"] { color: var(--accent, #146f68); font-weight: 750; }
.comp-task-pilot-status-menu button[aria-checked="true"]::after {
    content: "✓";
    margin-left: auto;
    font-size: 1rem;
    line-height: 1;
}
.comp-task-pilot-adjustment-content { display: grid; gap: .85rem; }
.comp-task-pilot-adjustment-content .field { margin: 0; }
.comp-task-pilot-adjustment-content .field small { color: var(--text-muted, #667085); }

@media (max-width: 1050px) {
    .comp-search-toolbar { background-position: 54% center; }
}

@media (max-width: 720px) {
    .comp-search-toolbar {
        --comp-header-inline: 1rem;
        gap: 1.25rem;
        padding: 1rem var(--comp-header-inline);
        background:
            linear-gradient(90deg, rgba(238, 243, 245, .92) 0%, rgba(238, 243, 245, .68) 62%, rgba(238, 243, 245, .18) 100%),
            linear-gradient(180deg, rgba(16, 42, 58, .02) 50%, rgba(16, 42, 58, .18) 100%),
            url("/res/img/comp/hero-comp.jpg");
        background-position: 58% center;
        background-size: cover;
    }
    .comp-browser-heading { align-items: center; }
    .comp-browser-heading .page-heading-actions { margin-left: auto; }
    .comp-search-form { grid-template-columns: minmax(74px, .6fr) minmax(0, 1fr) auto; padding: .72rem; }
    .comp-search-field--country { grid-column: 2 / -1; }
    .comp-search-field--query { grid-column: 1 / 3; }
    .comp-search-submit { align-self: end; }
    .comp-browser-table thead { display: none; }
    .comp-browser-table .comp-browser-row { display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 9px; padding: 0; }
    .comp-browser-table td { width: auto; min-width: 0; padding: 9px 0; border: 0; text-align: left; }
    .comp-browser-table td.comp-browser-country-col,
    .comp-browser-table td.comp-browser-scoring-col,
    .comp-browser-table td.comp-browser-season-col { display: none; }
    .comp-browser-main-col { display: grid; gap: 4px; }
    .comp-browser-mobile-meta {
        display: flex; align-items: center; flex-wrap: wrap; gap: 4px 9px;
        min-width: 0; color: var(--muted); font-size: .76rem; line-height: 1.25;
    }
    .comp-browser-mobile-meta > span:not(.comp-status-badge) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .comp-browser-mobile-meta .comp-status-badge { padding-block: 2px; }
    .comp-profile-header { grid-template-columns: auto 1fr; padding: 1rem; }
    .comp-profile-actions { grid-column: 1 / -1; justify-content: flex-start; }
    .comp-info-layout { grid-template-columns: 1fr; }
    .comp-info-description, .comp-info-admin { grid-column: 1; }
    .comp-admin-action-card { align-items: flex-start; flex-direction: column; }
    .comp-task-pilot-row {
        grid-template-columns: minmax(0, 1fr) 36px;
        grid-template-areas:
            "identity edit"
            "status status"
            "adjustment adjustment"
            "error error";
        gap: .45rem .65rem;
        padding: .7rem;
    }
    .comp-task-pilot-status-control { min-width: 0; }
    .comp-status-badge.comp-task-pilot-status-button { min-height: 32px; }
    .comp-task-pilot-adjustment-summary { flex-wrap: wrap; }
    .comp-task-pilot-adjustment-detail { flex-basis: 100%; }
    .comp-profile-content > .pilot-profile-panel { padding: 0; }
    .comp-live { padding: .75rem; }
    .comp-live-header { display: grid; }
    .comp-live-updated { margin-top: 0 !important; }
    .comp-live-map-root { height: 68vh; min-height: 380px; }
}

