.ev-page {
    width: 100%;
    max-width: 1380px;
    margin: 0 auto;
    display: grid;
    gap: 20px;
    color: var(--ink-900);
}

.ev-page [hidden] {
    display: none;
}

.ev-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
}

.ev-head h1 {
    margin: 0 0 6px;
    font: 700 32px/1.2 var(--font-heading);
}

.ev-head p {
    margin: 0;
    color: #425b72;
    font-size: 16px;
}

.ev-btn {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-sizing: border-box;
    padding: 0 16px;
    border: 1px solid transparent;
    border-radius: 12px;
    background: var(--white);
    color: #1f334d;
    font: 700 14px var(--font-body);
    text-decoration: none;
    white-space: nowrap;
    cursor: pointer;
}

.ev-btn.is-large {
    min-height: 48px;
    font-weight: 800;
}

.ev-btn.is-primary {
    background: var(--green-600);
    color: var(--white);
}

.ev-btn.is-primary:hover {
    background: var(--green-800);
    color: var(--white);
}

.ev-btn.is-ghost {
    border-color: #dce9df;
}

.ev-btn.is-ghost:hover {
    border-color: var(--green-400);
    color: var(--green-800);
}

.ev-btn.is-joined {
    border-color: #b9d3c0;
    color: var(--green-800);
}

.ev-btn.is-muted {
    background: #eef2f5;
    color: #567089;
    cursor: default;
}

.ev-btn.is-danger {
    border-color: #e6b5b5;
    color: var(--red-600);
}

.ev-btn.is-rate,
.ev-rate {
    border-color: #f0d9a8;
    background: #fff8ea;
    color: #8a5a00;
}

.ev-rate[aria-pressed="true"] {
    border: 2px solid #e8b04a;
    background: #fff4e0;
}

.ev-switch {
    display: flex;
    gap: 6px;
    padding: 6px;
    border-radius: 18px;
    background: #e2ece5;
}

.ev-switch button {
    flex: 1;
    min-height: 54px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border: 0;
    border-radius: 14px;
    background: transparent;
    color: #425b72;
    font: 800 16px var(--font-body);
    cursor: pointer;
}

.ev-switch button[aria-pressed="true"] {
    background: var(--white);
    color: var(--ink-900);
    box-shadow: 0 2px 6px rgba(19, 32, 51, 0.12);
}

.ev-count {
    min-width: 26px;
    height: 24px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    padding: 0 8px;
    border-radius: 999px;
    background: var(--white);
    color: #425b72;
    font-size: 12px;
    font-weight: 800;
}

.ev-switch button[aria-pressed="true"] .ev-count {
    background: #eaf7ed;
    color: var(--green-800);
}

.ev-switch-rate {
    color: #8a5a00;
    font-size: 12px;
}

.ev-narrow,
.ev-mobile-meta,
.ev-chevron {
    display: none;
}

.ev-panel {
    display: grid;
    gap: 20px;
}

.ev-filters {
    display: grid;
    gap: 18px;
    padding: 22px;
    border: 1px solid #e3eee7;
    border-radius: 22px;
    background: var(--white);
}

.ev-filter-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.ev-filter {
    display: flex;
    align-items: center;
    gap: 10px;
}

.ev-label {
    min-width: 64px;
    color: #567089;
    font-size: 13px;
    font-weight: 800;
}

.ev-seg {
    display: inline-flex;
    padding: 4px;
    border-radius: 12px;
    background: #eef3f0;
}

.ev-seg button {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 0 14px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: #425b72;
    font: 800 14px var(--font-body);
    white-space: nowrap;
    cursor: pointer;
}

.ev-seg button[aria-pressed="true"] {
    background: var(--white);
    color: var(--ink-900);
    box-shadow: 0 1px 3px rgba(19, 32, 51, 0.14);
}

.ev-seg button span:not(.ev-dot) {
    color: #567089;
}

.ev-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--ink-900);
}

.ev-dot.is-green {
    background: var(--green-600);
}

.ev-dot.is-blue {
    background: #2f6d9e;
}

.ev-origin {
    color: #425b72;
    font-size: 13px;
}

.ev-origin strong {
    color: var(--ink-900);
}

.ev-origin-toggle {
    padding: 0;
    border: 0;
    background: none;
    color: var(--green-700);
    font: 800 13px var(--font-body);
    text-decoration: underline;
    cursor: pointer;
}

.ev-origin-form {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.ev-origin-form[hidden] {
    display: none;
}

.ev-origin-form input {
    flex: 1 1 240px;
    min-height: 44px;
    box-sizing: border-box;
    padding: 0 14px;
    border: 1px solid #dce9df;
    border-radius: 12px;
    font: 500 15px var(--font-body);
}

.ev-origin-form input:focus {
    border-color: var(--green-600);
    outline: 2px solid rgba(46, 125, 50, 0.18);
}

.ev-origin-error {
    flex-basis: 100%;
    margin: 0;
    color: #b42318;
    font-size: 13px;
}

.ev-types {
    display: grid;
    grid-template-columns: repeat(10, minmax(0, 1fr));
    gap: 8px;
}

.ev-type {
    min-width: 0;
    min-height: 78px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-sizing: border-box;
    padding: 0 4px;
    border: 1px solid #e3eee7;
    border-radius: 16px;
    background: #f8fbf9;
    color: #1f334d;
    font: 800 12px/1.2 var(--font-body);
    white-space: nowrap;
    cursor: pointer;
}

.ev-type span {
    font-size: 22px;
    line-height: 1;
}

.ev-type:hover {
    border-color: var(--green-400);
}

.ev-type[aria-pressed="true"] {
    border: 2px solid var(--green-600);
    background: #eaf7ed;
    color: var(--green-800);
}

.ev-summary {
    margin: 0;
    padding: 0 4px;
    color: #425b72;
    font-size: 14px;
}

.ev-summary strong {
    color: var(--ink-900);
}

.ev-groups {
    display: grid;
    gap: 20px;
}

.ev-groups:empty {
    display: none;
}

.ev-group {
    display: grid;
    gap: 10px;
}

.ev-group h2 {
    margin: 0;
    padding: 0 4px;
    display: flex;
    align-items: baseline;
    gap: 10px;
    font: 700 16px var(--font-heading);
}

.ev-group h2 span {
    color: #567089;
    font: 700 13px var(--font-body);
}

.ev-card {
    overflow: hidden;
    border: 1px solid #e3eee7;
    border-radius: 22px;
    background: var(--white);
}

.ev-row {
    display: grid;
    grid-template-columns: 96px 44px minmax(0, 1fr) 170px auto;
    align-items: center;
    gap: 16px;
    padding: 14px 18px;
    border-top: 1px solid #edf3ef;
    cursor: pointer;
}

.ev-row:first-child {
    border-top: 0;
}

.ev-row:hover {
    background: #f8fbf9;
}

.ev-time {
    display: grid;
    gap: 2px;
}

.ev-time strong {
    font: 700 17px var(--font-heading);
}

.ev-time small {
    color: #567089;
    font-size: 12px;
    font-weight: 700;
}

.ev-icon {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    font-size: 20px;
}

.ev-body {
    min-width: 0;
    display: grid;
    gap: 4px;
}

.ev-title-line {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.ev-title {
    overflow: hidden;
    color: var(--ink-900);
    font-size: 16px;
    font-weight: 800;
    text-decoration: none;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ev-title:hover {
    color: var(--green-800);
}

.ev-role {
    flex: none;
    height: 22px;
    display: inline-flex;
    align-items: center;
    padding: 0 8px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 800;
    white-space: nowrap;
}

.ev-role.is-organizer {
    background: #e7f1fa;
    color: #2f6d9e;
}

.ev-role.is-participant {
    background: #eaf7ed;
    color: var(--green-800);
}

.ev-sub {
    overflow: hidden;
    color: #425b72;
    font-size: 13px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ev-info {
    font-size: 13px;
    font-weight: 800;
}

.ev-page .is-ok {
    color: var(--green-800);
}

.ev-page .is-low {
    color: #8a5a00;
}

.ev-page .is-full {
    color: var(--red-600);
}

.ev-page .is-blue {
    color: #2f6d9e;
}

.ev-page .is-muted {
    color: #567089;
}

.ev-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}

@property --ev-state-angle {
    syntax: '<angle>';
    inherits: false;
    initial-value: 0deg;
}

.ev-state {
    margin: 0;
    padding: 28px 20px;
    border: 1px solid #cfe0d4;
    border-radius: 22px;
    color: #425b72;
    font-size: 15px;
    text-align: center;
}

.ev-state--loading {
    border-color: transparent;
    background:
        linear-gradient(var(--gray-100), var(--gray-100)) padding-box,
        conic-gradient(from var(--ev-state-angle), #cfe0d4, #7fb896, #e8b81a, #7fb896, #cfe0d4) border-box;
    animation: ev-state-border 4s linear infinite;
}

@keyframes ev-state-border {
    to {
        --ev-state-angle: 360deg;
    }
}

@media (prefers-reduced-motion: reduce) {
    .ev-state--loading {
        animation: none;
    }
}

.ev-more {
    justify-self: center;
    min-width: 260px;
}

@media (max-width: 1100px) {
    .ev-types {
        grid-template-columns: repeat(5, minmax(0, 1fr));
    }

    .ev-row {
        grid-template-columns: 84px 44px minmax(0, 1fr) auto;
    }

    .ev-info {
        display: none;
    }

    .ev-mobile-meta {
        display: block;
        color: #567089;
        font-size: 12px;
        font-weight: 700;
    }
}

@media (max-width: 760px) {
    .ev-head h1 {
        margin: 0;
        font-size: 26px;
    }

    .ev-head p,
    .ev-head .ev-btn,
    .ev-switch svg,
    .ev-wide,
    .ev-label,
    .ev-time,
    .ev-sub,
    .ev-actions,
    .ev-map-link {
        display: none;
    }

    .ev-narrow {
        display: inline;
    }

    .ev-page,
    .ev-panel {
        gap: 14px;
    }

    .ev-switch {
        gap: 4px;
        padding: 4px;
        border-radius: 16px;
    }

    .ev-switch button {
        min-height: 46px;
        gap: 6px;
        border-radius: 12px;
        font-size: 14px;
    }

    .ev-count {
        min-width: 22px;
        height: 20px;
        padding: 0 6px;
        font-size: 11px;
    }

    .ev-filters {
        gap: 10px;
        margin: 0 -14px;
        padding: 14px;
        border-width: 1px 0;
        border-radius: 0;
    }

    .ev-filter-row {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        gap: 10px;
    }

    .ev-filter,
    .ev-seg {
        display: flex;
    }

    .ev-seg {
        flex: 1;
    }

    .ev-seg button {
        flex: 1;
        padding: 0 8px;
        font-size: 13px;
    }

    .ev-rate {
        justify-self: start;
        min-height: 38px;
    }

    .ev-types {
        display: flex;
        gap: 8px;
        margin-right: -14px;
        overflow-x: auto;
        scrollbar-width: none;
    }

    .ev-type {
        flex: none;
        min-height: 36px;
        flex-direction: row;
        gap: 6px;
        padding: 0 12px;
        border-radius: 999px;
        background: var(--white);
        font-size: 13px;
    }

    .ev-type span {
        font-size: 16px;
    }

    .ev-group h2 {
        font-size: 15px;
    }

    .ev-card {
        border-radius: 18px;
    }

    .ev-row {
        grid-template-columns: 40px minmax(0, 1fr) 18px;
        gap: 12px;
        padding: 12px 14px;
    }

    .ev-icon {
        width: 40px;
        height: 40px;
        border-radius: 12px;
        font-size: 18px;
    }

    .ev-title-line {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .ev-role {
        order: -1;
        height: 20px;
    }

    .ev-title {
        font-size: 14px;
        line-height: 1.3;
        white-space: normal;
    }

    .ev-chevron {
        display: block;
        color: #567089;
    }

    .ev-more {
        width: 100%;
        min-width: 0;
    }
}
