.vote-feedback-modal {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: grid;
    place-items: center;
    padding: 16px;
}
.vote-feedback-modal[hidden] { display: none; }
.vote-feedback-backdrop {
    position: absolute;
    inset: 0;
    border: 0;
    background: rgba(34, 33, 31, .44);
    backdrop-filter: blur(6px);
}
.vote-feedback-dialog {
    position: relative;
    width: min(100%, 500px);
    max-height: min(720px, calc(100dvh - 32px));
    overflow-y: auto;
    padding: 24px;
    border: 1px solid var(--line, #ded7cf);
    border-radius: 28px;
    background: var(--surface, #fffdfa);
    color: var(--ink, #22211f);
    box-shadow: 0 30px 90px rgba(52, 43, 36, .24);
}
.vote-feedback-close {
    position: absolute;
    top: 10px;
    right: 18px;
    width: 38px;
    height: 38px;
    border: 1px solid var(--line, #ded7cf);
    border-radius: 50%;
    background: var(--paper-strong, #f5f0e9);
    color: var(--ink, #22211f);
    font-size: 1.35rem;
    line-height: 1;
}
.vote-feedback-kicker {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin: 0 42px 8px;
    color: var(--accent-dark, #cf5944);
    font: 800 .68rem/1.2 var(--font-display, var(--display, system-ui));
    letter-spacing: .12em;
    text-align: center;
    text-transform: uppercase;
}
.vote-feedback-check {
    width: 18px;
    height: 18px;
    display: grid;
    flex: 0 0 18px;
    place-items: center;
    border-radius: 50%;
    background: var(--accent, #ea765f);
    color: #fff;
    font-size: .7rem;
    letter-spacing: 0;
}
.vote-feedback-selection {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 16px 0 20px;
    padding: 10px 12px;
    border: 1px solid var(--line, #ded7cf);
    border-radius: 16px;
    background: var(--paper-strong, #f5f0e9);
    color: var(--quiet, #827b75);
}
.vote-feedback-avatar {
    position: relative;
    width: 50px;
    height: 50px;
    display: grid;
    flex: 0 0 50px;
    overflow: hidden;
    place-items: center;
    border-radius: 13px;
    background: var(--accent, #ea765f);
    color: #fff;
    font-size: .72rem;
    font-weight: 800;
}
.vote-feedback-avatar.has-logo { background: transparent; }
.vote-feedback-avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: transparent; }
.vote-feedback-identity-copy { min-width: 0; display: grid; gap: 3px; }
.vote-feedback-identity-copy strong { overflow: hidden; color: var(--ink, #22211f); font-size: .95rem; text-overflow: ellipsis; white-space: nowrap; }
.vote-feedback-identity-copy > span { display: -webkit-box; overflow: hidden; font-size: .73rem; line-height: 1.3; -webkit-box-orient: vertical; -webkit-line-clamp: 4; }
.punch-power { margin: 0 0 18px; padding: 0; border: 0; }
.punch-power legend,
.vote-reason-field > span {
    display: flex;
    justify-content: space-between;
    width: 100%;
    margin-bottom: 8px;
    font: 800 .72rem/1.2 var(--font-display, var(--display, system-ui));
    letter-spacing: .04em;
    text-transform: uppercase;
}
.punch-power legend span,
.vote-reason-field small { color: var(--quiet, #827b75); font: inherit; }
.punch-power-options { display: grid; grid-template-columns: repeat(5, 1fr); gap: 7px; }
.punch-power-option { position: relative; cursor: pointer; }
.punch-power-option input { position: absolute; opacity: 0; pointer-events: none; }
.punch-power-option span {
    min-height: 48px;
    display: grid;
    place-items: center;
    border: 1px solid var(--line, #ded7cf);
    border-radius: 14px;
    background: var(--paper-strong, #f5f0e9);
    color: var(--ink, #22211f);
    font: 800 1.45rem/1 var(--font-display, var(--display, system-ui));
    pointer-events: none;
    filter: grayscale(1);
    opacity: .3;
    transition: opacity .14s ease, filter .14s ease, transform .14s ease, background .14s ease, border-color .14s ease;
}
.punch-power-option .impact-rating-icon img {
    display: block;
    width: 30px;
    height: 30px;
}
.punch-power-option:hover span,
.punch-power-option input:focus-visible + span { border-color: var(--accent, #ea765f); }
.punch-power-option.is-filled span {
    border-color: rgba(234, 118, 95, .5);
    background: var(--accent-pale, #fff0eb);
    filter: none;
    opacity: 1;
    transform: translateY(-2px);
}
.punch-power-option input:checked + span {
    border-color: var(--accent, #ea765f);
    box-shadow: 0 0 0 2px rgba(234, 118, 95, .16);
}
.punch-power-scale { display: flex; justify-content: space-between; margin-top: 6px; color: var(--quiet, #827b75); font: 700 .56rem/1.2 var(--font-display, var(--display, system-ui)); text-transform: uppercase; }
.vote-reason-field { display: block; }
.vote-reason-field textarea {
    width: 100%;
    min-height: 92px;
    resize: vertical;
    padding: 11px;
    border: 1px solid var(--line, #ded7cf);
    border-radius: 14px;
    outline: 0;
    background: var(--surface, #fffdfa);
    color: var(--ink, #22211f);
    font: 500 .9rem/1.4 var(--font-body, var(--display, system-ui));
}
.vote-reason-field textarea:focus { border-color: var(--accent, #ea765f); box-shadow: 0 0 0 3px rgba(234, 118, 95, .1); }
.vote-reason-field textarea::placeholder { color: var(--quiet, #827b75); }
.vote-feedback-error { margin: 10px 0 0; color: #ff8b80; font-size: .78rem; font-weight: 700; }
.vote-feedback-actions { display: grid; grid-template-columns: 1fr 1.35fr; gap: 8px; margin-top: 18px; }
.vote-feedback-actions button { min-height: 46px; padding: 10px; border-radius: 999px; font-weight: 700; }
.vote-feedback-cancel { border: 1px solid var(--line, #ded7cf); background: var(--paper-strong, #f5f0e9); color: var(--ink-soft, #514d49); }
.vote-feedback-submit { border: 1px solid var(--accent, #ea765f); background: var(--accent, #ea765f); color: #fff; }
body.vote-feedback-open { overflow: hidden; }

.h2h-confetti {
    position: fixed;
    inset: 0;
    z-index: 120;
    overflow: hidden;
    pointer-events: none;
}
.h2h-confetti-piece {
    position: absolute;
    top: 14%;
    left: 50%;
    width: 13px;
    height: 21px;
    border-radius: 3px;
    background: var(--confetti-color);
    opacity: 0;
    animation: h2h-confetti-pop var(--confetti-duration) cubic-bezier(.16, .7, .24, 1) var(--confetti-delay) forwards;
}
.h2h-confetti-piece:nth-child(3n) { width: 16px; height: 16px; border-radius: 50%; }
.h2h-confetti-piece:nth-child(4n) { width: 10px; height: 25px; }
@keyframes h2h-confetti-pop {
    0% { opacity: 0; transform: translate(-50%, 0) rotate(0deg) scale(.5); }
    7% { opacity: 1; }
    92% { opacity: 1; }
    100% { opacity: 0; transform: translate(calc(-50% + var(--confetti-x)), var(--confetti-y)) rotate(var(--confetti-rotate)) scale(1); }
}

@media (max-width: 760px) {
    .vote-feedback-modal { align-items: end; padding: 0; }
    .vote-feedback-dialog {
        width: 100%;
        max-height: calc(100dvh - 16px);
        padding: 24px 18px calc(24px + env(safe-area-inset-bottom));
        border-width: 1px 0 0;
        border-radius: 26px 26px 0 0;
    }
}

@media (max-width: 420px), (max-height: 620px) {
    .vote-feedback-dialog { max-height: calc(100dvh - 8px); padding: 20px 16px calc(20px + env(safe-area-inset-bottom)); }
    .vote-feedback-selection { margin-bottom: 15px; }
    .punch-power { margin-bottom: 14px; }
    .punch-power-option span { min-height: 44px; }
    .vote-reason-field textarea { min-height: 76px; }
}

@media (prefers-reduced-motion: reduce) {
    .h2h-confetti { display: none; }
}
