.participants-groups {
    --pg-bg: #0b1220;
    --pg-bg-soft: #121b2d;
    --pg-surface: #ffffff;
    --pg-surface-soft: #f3f5f7;
    --pg-line: #dbe2ea;
    --pg-text: #121826;
    --pg-muted: #66758a;
    --pg-accent: #ff5a1f;
    --pg-accent-2: #11b3a3;
    --pg-warning: #f59e0b;
    --pg-shadow: 0 20px 50px rgba(8, 15, 30, 0.08);
    color: var(--pg-text);
    display: grid;
    gap: 18px;
    margin: 24px 0 32px;
}

.participants-groups ul,
.participants-groups ol {
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

.participants-groups li {
    list-style: none !important;
    margin: 0 !important;
    padding-left: 0 !important;
}

.participants-groups li::before,
.participants-groups li::marker {
    content: none !important;
    display: none !important;
}

.participants-groups__section {
    background: var(--pg-surface);
    border: 1px solid var(--pg-line);
    border-radius: 24px;
    box-shadow: var(--pg-shadow);
    overflow: hidden;
}

.participants-groups__cta-wrap {
    bottom: max(var(--sp-cta-bottom, 18px), env(safe-area-inset-bottom));
    pointer-events: none;
    position: fixed;
    right: max(var(--sp-cta-right, 18px), env(safe-area-inset-right));
    width: min(248px, calc(100vw - 24px));
    z-index: 40;
}

.participants-groups__cta {
    align-items: center;
    background:
        radial-gradient(circle at top right, rgba(255, 255, 255, 0.22), transparent 30%),
        linear-gradient(135deg, var(--pg-accent) 0%, #ff7a45 62%, #ff9d57 100%);
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 18px;
    box-shadow: 0 14px 32px rgba(255, 90, 31, 0.2);
    color: #ffffff;
    display: grid;
    gap: 2px 12px;
    grid-template-areas:
        "kicker arrow"
        "text arrow";
    grid-template-columns: minmax(0, 1fr) auto;
    margin: 0;
    min-height: 0;
    overflow: hidden;
    padding: 12px 14px;
    position: relative;
    pointer-events: auto;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.participants-groups__cta::before {
    animation: participants-groups-cta-sheen 5.2s ease-in-out infinite;
    background: linear-gradient(110deg, transparent 0%, rgba(255, 255, 255, 0.18) 48%, transparent 100%);
    content: "";
    inset: -8px;
    pointer-events: none;
    position: absolute;
    transform: translateX(-150%);
}

.participants-groups__cta:hover,
.participants-groups__cta:focus-visible {
    box-shadow: 0 16px 36px rgba(255, 90, 31, 0.26);
    color: #ffffff;
    filter: saturate(1.03);
    outline: none;
    transform: translateY(-2px);
}

.participants-groups__cta-kicker {
    color: rgba(255, 255, 255, 0.78);
    display: block;
    font-size: 0.66rem;
    font-weight: 800;
    grid-area: kicker;
    letter-spacing: 0.14em;
    margin-bottom: 0;
    position: relative;
    z-index: 1;
    text-transform: uppercase;
}

.participants-groups__cta-text {
    color: #ffffff;
    display: block;
    font-size: 0.96rem;
    font-weight: 900;
    grid-area: text;
    letter-spacing: -0.02em;
    line-height: 1.1;
    position: relative;
    z-index: 1;
}

.participants-groups__cta::after {
    align-self: center;
    color: #ffffff;
    content: "→";
    grid-area: arrow;
    flex-shrink: 0;
    font-size: 1.1rem;
    font-weight: 900;
    line-height: 1;
    position: relative;
    z-index: 1;
}

.participants-groups--with-cta {
    padding-bottom: 92px;
}

.participants-groups__section--summary {
    background:
        radial-gradient(circle at top right, rgba(17, 179, 163, 0.18), transparent 24%),
        linear-gradient(135deg, var(--pg-bg) 0%, var(--pg-bg-soft) 100%);
    border: 0;
    color: #f4f7fb;
    padding: 22px 22px 18px;
}

.participants-groups__summary-head {
    margin-bottom: 16px;
}

.participants-groups__eyebrow {
    color: rgba(255, 255, 255, 0.68);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.18em;
    margin-bottom: 8px;
    text-transform: uppercase;
}

.participants-groups__summary-head h2 {
    color: #ffffff;
    font-size: clamp(1.3rem, 3vw, 1.9rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.05;
    margin: 0;
}

.participants-groups__summary-head p {
    color: rgba(244, 247, 251, 0.72);
    font-size: 0.95rem;
    line-height: 1.45;
    margin: 8px 0 0;
    max-width: 720px;
}

.participants-groups__metrics {
    display: grid;
    gap: 10px;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin-bottom: 14px;
}

.participants-groups__metric {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 18px;
    min-height: 86px;
    padding: 14px 16px;
}

.participants-groups__metric-label {
    color: rgba(244, 247, 251, 0.64);
    display: block;
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    margin-bottom: 10px;
    text-transform: uppercase;
}

.participants-groups__metric-value {
    color: #ffffff;
    display: block;
    font-size: clamp(1.8rem, 3vw, 2.4rem);
    font-weight: 900;
    letter-spacing: -0.04em;
    line-height: 1;
}

.participants-groups__cities {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}

.participants-groups__cities[hidden] {
    display: none;
}

.participants-groups__cities-accordion {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding-top: 14px;
}

.participants-groups__cities-toggle {
    align-items: center;
    appearance: none;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    color: #ffffff;
    cursor: pointer;
    display: inline-flex;
    font-size: 0.86rem;
    font-weight: 900;
    gap: 10px;
    justify-content: center;
    line-height: 1;
    min-height: 42px;
    padding: 0 16px;
    transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.participants-groups__cities-toggle:hover,
.participants-groups__cities-toggle:focus-visible {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.2);
    outline: none;
    transform: translateY(-1px);
}

.participants-groups__cities-toggle::after {
    content: "↓";
    font-size: 0.9rem;
    font-weight: 900;
    line-height: 1;
    transition: transform 0.2s ease;
}

.participants-groups__cities-toggle[aria-expanded="true"]::after {
    transform: rotate(180deg);
}

.participants-groups__city-card {
    align-items: center;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    display: inline-flex;
    gap: 10px;
    min-height: 42px;
    padding: 8px 14px 8px 10px;
}

.participants-groups__city-name {
    color: #ffffff;
    font-size: 0.9rem;
    font-weight: 500;
    line-height: 1;
}

.participants-groups__city-count {
    align-items: center;
    background: linear-gradient(135deg, var(--pg-accent), #ff7a45);
    border-radius: 999px;
    color: #ffffff;
    display: inline-flex;
    font-size: 0.82rem;
    font-weight: 900;
    height: 30px;
    justify-content: center;
    min-width: 30px;
    padding: 0;
    width: 30px;
}

.participants-groups__section > h2 {
    border-bottom: 1px solid var(--pg-line);
    color: var(--pg-text);
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    margin: 0;
    padding: 18px 20px 16px;
}

.participants-groups__group {
    padding: 18px 20px 20px;
}

.participants-groups__group + .participants-groups__group {
    border-top: 1px solid var(--pg-line);
}

.participants-groups__group > h3 {
    align-items: center;
    color: var(--pg-text);
    display: flex;
    justify-content: space-between;
    font-size: 1rem;
    font-weight: 800;
    gap: 10px;
    line-height: 1.2;
    margin: 0 0 14px;
    text-transform: uppercase;
}

.participants-groups__group > h3::before {
    background: linear-gradient(180deg, var(--pg-accent), var(--pg-accent-2));
    border-radius: 999px;
    content: "";
    display: inline-block;
    height: 14px;
    width: 4px;
}

.participants-groups__group > h3 > span:first-child {
    align-items: center;
    display: inline-flex;
    gap: 10px;
}

.participants-groups__group-count {
    align-items: center;
    background: #eef2f6;
    border-radius: 999px;
    color: var(--pg-muted);
    display: inline-flex;
    font-size: 0.78rem;
    font-weight: 900;
    justify-content: center;
    line-height: 1;
    min-width: 30px;
    padding: 7px 9px;
}

.participants-groups__group ul {
    display: grid;
    gap: 0;
}

.participants-groups__table-head {
    border-bottom: 1px solid #e8edf3;
    color: var(--pg-muted);
    display: grid;
    gap: 12px;
    grid-template-columns: 112px minmax(150px, 1.2fr) minmax(120px, 1fr) 90px minmax(140px, 1fr) minmax(160px, 1.1fr);
    padding: 0 0 10px;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    margin-bottom: 2px;
    text-transform: uppercase;
}

.participants-groups__person {
    align-items: center;
    border-bottom: 1px solid #edf2f6;
    display: grid;
    gap: 12px;
    grid-template-columns: 112px minmax(150px, 1.2fr) minmax(120px, 1fr) 90px minmax(140px, 1fr) minmax(160px, 1.1fr);
    min-height: 54px;
    padding: 0 0;
}

.participants-groups__person:last-child {
    border-bottom: 0;
}

.participants-groups__person-fullname {
    display: none;
}

.participants-groups__person-number {
    align-items: center;
    background: linear-gradient(135deg, #df2a4a 0%, #4d3bfe 100%);
    border: 0;
    border-radius: 5px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
    color: #ffffff;
    display: inline-flex;
    font-size: 1.4rem;
    font-weight: 900;
    justify-content: center;
    line-height: 1;
    min-height: 32px;
    min-width: 56px;
    padding: 0 12px;
    text-align: center;
    width: fit-content;
}

.participants-groups__person-last,
.participants-groups__person-first,
.participants-groups__person-bike,
.participants-groups__person-city,
.participants-groups__person-year {
    align-items: center;
    display: inline-flex;
    font-size: 0.84rem;
    font-weight: 700;
    line-height: 1.2;
    min-height: 54px;
}

.participants-groups__person-last,
.participants-groups__person-first {
    color: var(--pg-text);
    padding: 10px 0;
}

.participants-groups__person-last {
    font-size: 0.92rem;
    font-weight: 800;
}

.participants-groups__person-first {
    font-size: 0.9rem;
}

.participants-groups__person-city {
    color: var(--pg-muted);
    padding: 10px 0;
}

.participants-groups__person-bike {
    color: var(--pg-text);
    padding: 10px 0;
}

.participants-groups__person-year {
    color: #2563eb;
    justify-content: flex-start;
    padding: 10px 0;
}

.participants-groups__section--warning .participants-groups__table-head,
.participants-groups__section--warning ul {
    padding-left: 20px !important;
    padding-right: 20px !important;
}

.participants-groups__toggle {
    display: none;
}

.participants-groups__section--warning {
    background: linear-gradient(180deg, #fffaf1 0%, #fff5e8 100%);
    border-color: #f6d4a2;
}

.participants-groups__section--warning > h2 {
    color: #a04b00;
}

.participants-groups__section--warning .participants-groups__person::before {
    background: linear-gradient(135deg, #f59e0b, #f97316);
}

.participants-groups--error {
    background: linear-gradient(135deg, #3a1111 0%, #561818 100%);
    border: 1px solid rgba(239, 68, 68, 0.34);
    border-radius: 18px;
    color: #ffe4e4;
    padding: 16px 18px;
}

.participants-registration {
    --pr-bg: linear-gradient(135deg, #fff8ee 0%, #ffffff 52%, #eefaf8 100%);
    --pr-line: rgba(18, 24, 38, 0.1);
    --pr-text: #121826;
    --pr-muted: #6a7688;
    --pr-accent: #ff5a1f;
    --pr-accent-2: #11b3a3;
    background: var(--pr-bg);
    border: 1px solid var(--pr-line);
    border-radius: 28px;
    box-shadow: 0 20px 50px rgba(8, 15, 30, 0.08);
    color: var(--pr-text);
    margin: 24px 0 32px;
    overflow: hidden;
    padding: 24px;
}

.participants-registration--error {
    background: linear-gradient(135deg, #3a1111 0%, #561818 100%);
    border-color: rgba(239, 68, 68, 0.34);
    color: #ffe4e4;
}

.participants-registration-shell {
    position: relative;
}

.participants-registration-shell.is-loading {
    opacity: 0.76;
    transition: opacity 0.2s ease;
}

.participants-registration__head {
    margin-bottom: 18px;
    max-width: 760px;
}

.participants-registration__head--with-actions {
    align-items: flex-start;
    display: flex;
    gap: 16px;
    justify-content: space-between;
    max-width: none;
}

.participants-registration__eyebrow {
    color: var(--pr-accent);
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    margin: 0 0 8px;
    text-transform: uppercase;
}

.participants-registration__head h2 {
    font-size: clamp(1.35rem, 3vw, 2rem);
    font-weight: 900;
    letter-spacing: -0.03em;
    line-height: 1.05;
    margin: 0;
}

.participants-registration__head p:last-child {
    color: var(--pr-muted);
    font-size: 0.98rem;
    line-height: 1.55;
    margin: 10px 0 0;
}

.participants-registration__form {
    display: grid;
    gap: 18px;
}

.participants-registration__form--auth {
    max-width: 720px;
}

.participants-registration__grid {
    display: grid;
    gap: 14px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.participants-registration__grid--auth {
    grid-template-columns: repeat(2, minmax(220px, 1fr));
}

.participants-registration__field {
    display: grid;
    gap: 8px;
}

.participants-registration__field span {
    color: var(--pr-text);
    font-size: 0.82rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.participants-registration__field input,
.participants-registration__field select {
    appearance: none;
    background: rgba(255, 255, 255, 0.88);
    border: 1px solid rgba(18, 24, 38, 0.12);
    border-radius: 16px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4);
    color: var(--pr-text);
    font-size: 1rem;
    line-height: 1.2;
    min-height: 52px;
    padding: 0 16px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
    width: 100%;
}

.participants-registration__field input:focus,
.participants-registration__field select:focus {
    border-color: rgba(17, 179, 163, 0.9);
    box-shadow: 0 0 0 4px rgba(17, 179, 163, 0.14);
    outline: none;
    transform: translateY(-1px);
}

.participants-registration__field input::placeholder {
    color: #8b96a8;
}

.participants-registration__field--wide {
    grid-column: span 2;
}

.participants-registration__field--trap {
    left: -9999px;
    opacity: 0;
    pointer-events: none;
    position: absolute;
    top: auto;
}

.participants-registration__actions {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 14px 18px;
}

.participants-registration__submit {
    align-items: center;
    appearance: none;
    background: linear-gradient(135deg, var(--pr-accent), #ff7a45);
    border: 0;
    border-radius: 999px;
    color: #ffffff;
    cursor: pointer;
    display: inline-flex;
    font-size: 0.96rem;
    font-weight: 900;
    justify-content: center;
    letter-spacing: 0.01em;
    min-height: 52px;
    min-width: 220px;
    padding: 0 24px;
    transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.participants-registration__submit:hover,
.participants-registration__submit:focus-visible {
    box-shadow: 0 14px 30px rgba(255, 90, 31, 0.24);
    outline: none;
    transform: translateY(-1px);
}

.participants-registration__submit:disabled {
    cursor: wait;
    opacity: 0.8;
}

.participants-registration__submit.is-loading::after {
    animation: participants-registration-spin 0.8s linear infinite;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-right-color: #ffffff;
    border-radius: 999px;
    content: "";
    display: inline-block;
    height: 16px;
    margin-left: 10px;
    width: 16px;
}

.participants-registration__logout {
    appearance: none;
    background: rgba(18, 24, 38, 0.04);
    border: 1px solid rgba(18, 24, 38, 0.1);
    border-radius: 999px;
    color: var(--pr-text);
    cursor: pointer;
    font-size: 0.84rem;
    font-weight: 800;
    line-height: 1;
    min-height: 44px;
    padding: 0 16px;
    transition: background-color 0.2s ease, border-color 0.2s ease, opacity 0.2s ease;
    white-space: nowrap;
}

.participants-registration__logout:hover,
.participants-registration__logout:focus-visible {
    background: rgba(18, 24, 38, 0.07);
    border-color: rgba(18, 24, 38, 0.18);
    outline: none;
}

.participants-registration__logout:disabled {
    cursor: wait;
    opacity: 0.8;
}

.participants-registration__logout.is-loading::after {
    animation: participants-registration-spin 0.8s linear infinite;
    border: 2px solid rgba(18, 24, 38, 0.18);
    border-right-color: var(--pr-text);
    border-radius: 999px;
    content: "";
    display: inline-block;
    height: 14px;
    margin-left: 8px;
    vertical-align: middle;
    width: 14px;
}

.participants-registration__hint {
    color: var(--pr-muted);
    font-size: 0.9rem;
    line-height: 1.45;
    margin: 0;
}

.participants-registration__status {
    border-radius: 18px;
    display: none;
    font-size: 0.94rem;
    font-weight: 700;
    line-height: 1.45;
    padding: 14px 16px;
}

.participants-registration__status.is-success,
.participants-registration__status.is-error {
    display: block;
}

.participants-registration__status.is-success {
    background: rgba(17, 179, 163, 0.12);
    color: #0e7469;
}

.participants-registration__status.is-error {
    background: rgba(239, 68, 68, 0.1);
    color: #b42318;
}

@keyframes participants-registration-spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes participants-groups-cta-sheen {
    0%,
    72%,
    100% {
        transform: translateX(-150%);
    }

    84% {
        transform: translateX(150%);
    }
}

@media (prefers-reduced-motion: reduce) {
    .participants-groups__cta,
    .participants-groups__cta::before {
        animation: none;
    }
}

@media (max-width: 767px) {
    .participants-groups {
        gap: 14px;
        margin: 18px 0 24px;
    }

    .participants-groups--with-cta {
        padding-bottom: 82px;
    }

    .participants-groups__section--summary {
        background:
            radial-gradient(circle at top right, rgba(17, 179, 163, 0.18), transparent 24%),
            linear-gradient(135deg, var(--pg-bg) 0%, var(--pg-bg-soft) 100%);
        padding: 16px 16px 14px;
    }

    .participants-groups__metrics {
        grid-template-columns: 1fr 1fr;
    }

    .participants-groups__metric {
        min-height: auto;
        padding: 12px 14px;
    }

    .participants-groups__metric:nth-child(2) {
        order: 3;
    }

    .participants-groups__metric:nth-child(3) {
        order: 4;
    }

    .participants-groups__metric:nth-child(4) {
        order: 2;
    }

    .participants-groups__section > h2 {
        font-size: 1.15rem;
        padding: 14px 16px 13px;
    }

    .participants-groups__group {
        padding: 14px 16px 16px;
    }

    .participants-groups__group > h3 {
        font-size: 0.92rem;
        margin-bottom: 12px;
    }

    .participants-groups__table-head {
        display: none;
    }

    .participants-groups__group--collapsible.is-collapsed .participants-groups__person:nth-child(n+6) {
        display: none;
    }

    .participants-groups__person {
        background: linear-gradient(180deg, #ffffff 0%, #fbfcfd 100%);
        border: 1px solid #eef2f6;
        border-radius: 16px;
        gap: 4px 10px;
        grid-template-columns: 68px minmax(0, 1fr);
        min-height: auto;
        padding: 12px 12px 11px;
        margin-bottom: 10px;
    }

    .participants-groups__person:last-child {
        margin-bottom: 0;
    }

    .participants-groups__person-number {
        align-self: start;
        min-width: 52px;
    }

    .participants-groups__person-last,
    .participants-groups__person-first {
        display: none;
    }

    .participants-groups__person-fullname {
        grid-column: 2;
        color: var(--pg-text);
        display: block;
        font-size: 0.96rem;
        font-weight: 800;
        line-height: 1.15;
    }

    .participants-groups__person-year,
    .participants-groups__person-city,
    .participants-groups__person-bike {
        grid-column: 2;
        font-size: 0.82rem;
        min-height: auto;
        padding: 0;
    }

    .participants-groups__person-year::before,
    .participants-groups__person-city::before,
    .participants-groups__person-bike::before {
        color: var(--pg-muted);
        display: inline-block;
        font-size: 0.72rem;
        font-weight: 800;
        letter-spacing: 0.06em;
        margin-right: 6px;
        text-transform: uppercase;
    }

    .participants-groups__person-year::before {
        content: "Год";
    }

    .participants-groups__person-city::before {
        content: "Город";
    }

    .participants-groups__person-bike::before {
        content: "Велосипед";
    }

    .participants-groups__person-year {
        justify-content: flex-start;
        padding: 2px 0 0;
    }

    .participants-groups__section--warning .participants-groups__table-head,
    .participants-groups__section--warning ul {
        padding-left: 14px !important;
        padding-right: 14px !important;
    }

    .participants-groups__toggle {
        align-items: center;
        appearance: none;
        background: #f3f6f9;
        border: 1px solid #e2e8f0;
        border-radius: 999px;
        color: var(--pg-text);
        display: inline-flex;
        font-size: 0.84rem;
        font-weight: 800;
        justify-content: center;
        line-height: 1;
        margin-top: 10px;
        min-height: 40px;
        padding: 0 16px;
        text-align: center;
        width: 100%;
    }

    .participants-groups__cta-wrap {
        bottom: max(var(--sp-cta-bottom, 18px), env(safe-area-inset-bottom));
        right: max(var(--sp-cta-right, 18px), env(safe-area-inset-right));
        width: min(224px, calc(100vw - 24px));
    }

    .participants-groups__cta {
        border-radius: 16px;
        gap: 2px 10px;
        padding: 11px 13px;
    }

    .participants-groups__cta-kicker {
        font-size: 0.62rem;
    }

    .participants-groups__cta-text {
        font-size: 0.9rem;
    }

    .participants-registration {
        border-radius: 24px;
        margin: 18px 0 24px;
        padding: 18px 16px;
    }

    .participants-registration__grid {
        grid-template-columns: 1fr;
    }

    .participants-registration__grid--auth {
        grid-template-columns: 1fr;
    }

    .participants-registration__field--wide {
        grid-column: auto;
    }

    .participants-registration__head--with-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .participants-registration__actions {
        align-items: stretch;
        flex-direction: column;
    }

    .participants-registration__submit {
        min-width: 0;
        width: 100%;
    }

    .participants-registration__logout {
        width: 100%;
    }
}
