.kha-polls {
    --kha-red: #d7193f;
    --kha-red-dark: #b51234;
    --kha-red-soft: #fff3f6;
    --kha-green: #0c9b4a;
    --kha-green-soft: #eaf8f0;
    --kha-text: #15171a;
    --kha-muted: #6f747b;
    --kha-border: #e3e6ea;
    --kha-surface: #ffffff;
    --kha-option: #f7f7f8;
    --kha-shadow: 0 20px 55px rgba(18, 22, 28, 0.08);
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    color: var(--kha-text);
    font-family: Inter, "Noto Sans Devanagari", "Helvetica Neue", Arial, sans-serif;
}

.kha-polls *,
.kha-polls *::before,
.kha-polls *::after {
    box-sizing: border-box;
}

.kha-poll-card {
    width: 100%;
    margin: 0 0 34px;
    padding: 0;
    background: var(--kha-surface);
    border-top: 1px solid var(--kha-border);
    border-bottom: 1px solid var(--kha-border);
}

.kha-poll-heading {
    min-height: 96px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 18px 0;
}

.kha-poll-kicker {
    display: flex;
    align-items: baseline;
    gap: 12px;
    min-width: 0;
}

.kha-kicker-primary {
    font-size: clamp(25px, 2.2vw, 34px);
    line-height: 1.1;
    font-weight: 850;
    letter-spacing: -0.035em;
}

.kha-kicker-secondary {
    color: var(--kha-muted);
    font-size: 11px;
    line-height: 1;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.kha-voted-badge {
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex: 0 0 auto;
    padding: 8px 18px;
    border: 1px solid #b9e4ca;
    border-radius: 999px;
    background: var(--kha-green-soft);
    color: var(--kha-green);
    font-size: 14px;
    font-weight: 800;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.kha-voted-badge[aria-hidden="true"] {
    opacity: 0;
    visibility: hidden;
}

.kha-badge-check {
    font-size: 17px;
    line-height: 1;
}

.kha-poll-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(360px, 0.92fr);
    gap: clamp(30px, 4vw, 54px);
    align-items: stretch;
    padding: 0 0 38px;
}

.kha-poll-media {
    position: relative;
    min-height: 430px;
    overflow: hidden;
    border-radius: 20px;
    background: #ece9e7;
}

.kha-poll-media img {
    width: 100%;
    height: 100%;
    min-height: 430px;
    display: block;
    object-fit: cover;
}

.kha-poll-placeholder {
    width: 100%;
    min-height: 430px;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, #f5ecee, #eceff4);
}

.kha-poll-placeholder span {
    width: 90px;
    height: 90px;
    display: grid;
    place-items: center;
    border: 2px solid rgba(215, 25, 63, 0.2);
    border-radius: 50%;
    color: var(--kha-red);
    font-size: 42px;
    font-weight: 850;
}

.kha-poll-media-status {
    position: absolute;
    left: 20px;
    bottom: 20px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    max-width: calc(100% - 40px);
    padding: 10px 14px;
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 999px;
    background: rgba(15, 17, 20, 0.74);
    color: #fff;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.16);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    font-size: 12px;
    line-height: 1;
    font-weight: 800;
}

.kha-poll-media-status small {
    color: rgba(255, 255, 255, 0.72);
    font-size: 9px;
    letter-spacing: 0.07em;
}

.kha-status-dot {
    width: 8px;
    height: 8px;
    flex: 0 0 8px;
    border-radius: 50%;
    background: #ff3155;
    box-shadow: 0 0 0 5px rgba(255, 49, 85, 0.18);
}

.kha-poll-card.is-closed .kha-status-dot {
    background: #a3a8ae;
    box-shadow: 0 0 0 5px rgba(163, 168, 174, 0.2);
}

.kha-poll-content {
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.kha-question-block {
    margin: 0 0 22px;
}

.kha-question-primary {
    margin: 0;
    color: var(--kha-text);
    font-size: clamp(25px, 2.35vw, 34px);
    line-height: 1.17;
    font-weight: 850;
    letter-spacing: -0.035em;
    text-wrap: balance;
}

.kha-question-secondary {
    margin: 10px 0 0;
    color: var(--kha-muted);
    font-size: 14px;
    line-height: 1.45;
    font-weight: 550;
}

.kha-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.kha-option {
    position: relative;
    isolation: isolate;
    width: 100%;
    min-height: 70px;
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr) auto;
    align-items: center;
    gap: 14px;
    overflow: hidden;
    padding: 11px 18px;
    border: 1px solid #d8dadd;
    border-radius: 15px;
    background: var(--kha-option);
    color: var(--kha-text);
    text-align: left;
    font: inherit;
    cursor: pointer;
    transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.kha-option:not(:disabled):hover {
    transform: translateY(-1px);
    border-color: #b7bbc0;
    background: #fff;
    box-shadow: 0 8px 22px rgba(18, 22, 28, 0.06);
}

.kha-option:focus-visible {
    outline: 3px solid rgba(215, 25, 63, 0.25);
    outline-offset: 3px;
}

.kha-option:disabled {
    cursor: default;
}

.kha-option-fill {
    position: absolute;
    inset: 0 auto 0 0;
    z-index: -1;
    width: 0;
    background: linear-gradient(90deg, rgba(215, 25, 63, 0.14), rgba(215, 25, 63, 0.07));
    border-right: 1px solid rgba(215, 25, 63, 0.1);
    transition: width 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}

.kha-poll-card.show-results .kha-option-fill {
    width: var(--kha-result);
}

.kha-option-marker {
    width: 27px;
    height: 27px;
    display: grid;
    place-items: center;
    border: 3px solid #e0e2e4;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.76);
    color: transparent;
    font-size: 14px;
    font-weight: 900;
    transition: border-color 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.kha-option.is-selected {
    border-color: var(--kha-red);
    background: #fff8fa;
    box-shadow: inset 0 -3px 0 var(--kha-red);
}

.kha-option.is-selected .kha-option-marker {
    border-color: var(--kha-red);
    background: var(--kha-red);
    color: #fff;
}

.kha-option-copy {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.kha-option-primary {
    color: inherit;
    font-size: 16px;
    line-height: 1.25;
    font-weight: 700;
}

.kha-option-secondary {
    color: var(--kha-muted);
    font-size: 11px;
    line-height: 1.25;
    font-weight: 550;
}

.kha-option-percent {
    min-width: 48px;
    color: #979ba0;
    font-size: 17px;
    line-height: 1;
    font-weight: 850;
    text-align: right;
    opacity: 0;
    transform: translateX(5px);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.kha-poll-card.show-results .kha-option-percent {
    opacity: 1;
    transform: translateX(0);
}

.kha-option.is-selected .kha-option-percent {
    color: var(--kha-red);
}

.kha-poll-message {
    min-height: 22px;
    margin: 12px 0 0;
    color: var(--kha-muted);
    font-size: 12px;
    line-height: 1.4;
    font-weight: 650;
}

.kha-poll-message.is-success {
    color: var(--kha-green);
}

.kha-poll-message.is-error {
    color: var(--kha-red-dark);
}

.kha-poll-footer {
    min-height: 50px;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-top: auto;
    padding-top: 20px;
    border-top: 1px solid var(--kha-border);
}

.kha-total-votes {
    color: #999da2;
    font-size: 12px;
    line-height: 1.2;
    font-weight: 800;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.kha-thank-you {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 3px;
    color: var(--kha-red);
    font-size: 11px;
    line-height: 1.2;
    font-weight: 850;
    letter-spacing: 0.04em;
    text-align: right;
}

.kha-thank-you small {
    color: var(--kha-muted);
    font-size: 9px;
    font-weight: 650;
    letter-spacing: 0;
}

.kha-poll-card.is-loading {
    opacity: 0.76;
    pointer-events: none;
}

.kha-poll-embed-page {
    margin: 0;
    padding: 22px;
    background: #fff;
}

.kha-poll-embed-page .kha-polls {
    max-width: 1240px;
}

@media (max-width: 980px) {
    .kha-poll-layout {
        grid-template-columns: 1fr;
        gap: 26px;
    }

    .kha-poll-media,
    .kha-poll-media img,
    .kha-poll-placeholder {
        min-height: 390px;
    }
}

@media (max-width: 680px) {
    .kha-poll-card {
        margin-bottom: 24px;
    }

    .kha-poll-heading {
        min-height: 76px;
        padding: 14px 0;
    }

    .kha-kicker-primary {
        font-size: 23px;
    }

    .kha-kicker-secondary {
        display: none;
    }

    .kha-voted-badge {
        min-height: 36px;
        padding: 7px 12px;
        font-size: 12px;
    }

    .kha-poll-layout {
        gap: 22px;
        padding-bottom: 26px;
    }

    .kha-poll-media,
    .kha-poll-media img,
    .kha-poll-placeholder {
        min-height: 270px;
    }

    .kha-poll-media {
        border-radius: 16px;
    }

    .kha-question-primary {
        font-size: 23px;
        line-height: 1.25;
    }

    .kha-question-secondary {
        font-size: 12px;
    }

    .kha-option {
        min-height: 66px;
        grid-template-columns: 25px minmax(0, 1fr) auto;
        gap: 11px;
        padding: 10px 13px;
        border-radius: 13px;
    }

    .kha-option-marker {
        width: 24px;
        height: 24px;
        border-width: 2px;
    }

    .kha-option-primary {
        font-size: 14px;
    }

    .kha-option-secondary {
        font-size: 10px;
    }

    .kha-option-percent {
        min-width: 40px;
        font-size: 14px;
    }

    .kha-poll-footer {
        align-items: flex-start;
        flex-direction: column;
        gap: 9px;
    }

    .kha-thank-you {
        align-items: flex-start;
        text-align: left;
    }

    .kha-poll-embed-page {
        padding: 12px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .kha-polls *,
    .kha-polls *::before,
    .kha-polls *::after {
        scroll-behavior: auto !important;
        transition: none !important;
        animation: none !important;
    }
}
