:root {
    --bg: #f4efe7;
    --bg-accent: #e9dfd1;
    --surface: rgba(255, 250, 244, 0.82);
    --surface-strong: #fffaf4;
    --text: #1c140d;
    --muted: #6c5b4f;
    --border: rgba(28, 20, 13, 0.12);
    --shadow: 0 20px 60px rgba(70, 44, 18, 0.12);
    --yes: #0f9d58;
    --yes-soft: #d8f1df;
    --no: #d1495b;
    --no-soft: #f8d8dd;
    --info: #26547c;
    --info-soft: #d8e9f6;
    --warning: #9a6700;
    --warning-soft: #f6e8c9;
}

* {
    box-sizing: border-box;
}

html {
    min-height: 100%;
}

body {
    margin: 0;
    min-height: 100%;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(209, 73, 91, 0.14), transparent 32%),
        radial-gradient(circle at top right, rgba(15, 157, 88, 0.1), transparent 26%),
        linear-gradient(180deg, #f8f3ec 0%, var(--bg) 100%);
    font-family: "Space Grotesk", sans-serif;
}

button,
input,
textarea,
select {
    font: inherit;
}

.page-shell {
    padding: 24px;
}

.hero {
    position: relative;
    overflow: hidden;
    margin: 0 auto 28px;
    max-width: 1180px;
    border: 1px solid var(--border);
    border-radius: 32px;
    background:
        linear-gradient(135deg, rgba(255, 250, 244, 0.95), rgba(233, 223, 209, 0.88)),
        #fff;
    box-shadow: var(--shadow);
}

.hero::after {
    content: "";
    position: absolute;
    inset: auto -60px -80px auto;
    width: 220px;
    height: 220px;
    border-radius: 50%;
    background: rgba(209, 73, 91, 0.12);
    filter: blur(8px);
}

.hero__inner {
    position: relative;
    padding: 48px;
    max-width: 760px;
}

.eyebrow,
.section-heading__kicker {
    margin: 0 0 10px;
    color: var(--muted);
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.hero h1,
.section-heading h2 {
    margin: 0;
    line-height: 0.98;
    letter-spacing: -0.04em;
}

.hero h1 {
    font-family: "Instrument Serif", serif;
    font-size: clamp(3rem, 7vw, 5.8rem);
    font-weight: 400;
}

.hero__copy {
    margin: 20px 0 0;
    max-width: 620px;
    color: var(--muted);
    font-size: 1.05rem;
    line-height: 1.6;
}

.content {
    margin: 0 auto;
    max-width: 1180px;
}

.flash {
    margin-bottom: 20px;
    padding: 14px 16px;
    border-radius: 16px;
    border: 1px solid transparent;
    font-weight: 500;
}

.flash--success {
    color: var(--yes);
    background: var(--yes-soft);
    border-color: rgba(15, 157, 88, 0.18);
}

.flash--error {
    color: var(--no);
    background: var(--no-soft);
    border-color: rgba(209, 73, 91, 0.18);
}

.flash--info {
    color: var(--info);
    background: var(--info-soft);
    border-color: rgba(38, 84, 124, 0.18);
}

.section-heading {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: end;
    margin-bottom: 22px;
}

.section-heading__note {
    margin: 0;
    max-width: 360px;
    color: var(--muted);
    line-height: 1.5;
}

.section-cta {
    margin: 0 0 22px;
    color: var(--text);
    font-size: 1.02rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.question-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.question-card {
    display: flex;
    flex-direction: column;
    gap: 18px;
    padding: 22px;
    min-height: 100%;
    border: 1px solid var(--border);
    border-radius: 26px;
    background: var(--surface);
    backdrop-filter: blur(14px);
    box-shadow: 0 16px 40px rgba(70, 44, 18, 0.08);
}

.question-card__header,
.question-card__meta,
.vote-form {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
}

.pill {
    display: inline-flex;
    align-items: center;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(28, 20, 13, 0.06);
    color: var(--text);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.03em;
}

.pill--category {
    background: rgba(28, 20, 13, 0.06);
}

.pill--open {
    background: var(--yes-soft);
    color: var(--yes);
}

.pill--closed {
    background: var(--no-soft);
    color: var(--no);
}

.question-card__title {
    margin: 0;
    font-size: 1.35rem;
    line-height: 1.35;
}

.question-card__meta {
    color: var(--muted);
    font-size: 0.92rem;
}

.deadline-label {
    color: var(--text);
    font-size: 1rem;
    font-weight: 700;
}

.results {
    display: grid;
    gap: 14px;
}

.results--placeholder {
    padding: 18px;
    border: 1px dashed rgba(28, 20, 13, 0.14);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.4);
}

.results__row {
    display: grid;
    gap: 8px;
}

.results__labels {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    font-size: 0.95rem;
}

.results__track {
    overflow: hidden;
    height: 12px;
    border-radius: 999px;
    background: rgba(28, 20, 13, 0.08);
}

.results__fill {
    display: block;
    height: 100%;
    border-radius: inherit;
}

.results__fill--yes {
    background: linear-gradient(90deg, #52c784, var(--yes));
}

.results__fill--no {
    background: linear-gradient(90deg, #ee8d9a, var(--no));
}

.results__placeholder-copy,
.results__placeholder-note {
    margin: 0;
}

.results__placeholder-copy {
    font-weight: 700;
}

.results__placeholder-note {
    color: var(--muted);
    line-height: 1.5;
}

.vote-form {
    margin-top: auto;
}

.vote-button {
    flex: 1 1 50%;
    padding: 14px 16px;
    border: 0;
    border-radius: 16px;
    cursor: pointer;
    font-weight: 700;
    transition: transform 160ms ease, box-shadow 160ms ease, opacity 160ms ease;
}

.vote-button:hover,
.vote-button:focus-visible {
    transform: translateY(-1px);
    box-shadow: 0 10px 18px rgba(28, 20, 13, 0.12);
}

.vote-button--yes {
    background: var(--yes);
    color: #fff;
}

.vote-button--no {
    background: #fff;
    color: var(--text);
    border: 1px solid rgba(28, 20, 13, 0.12);
}

.question-card__message {
    margin: auto 0 0;
    color: var(--muted);
    line-height: 1.5;
}

.question-card__message--hint {
    margin-top: -10px;
    color: var(--text);
    font-weight: 700;
}

@media (max-width: 980px) {
    .question-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .section-heading {
        flex-direction: column;
        align-items: start;
    }
}

@media (max-width: 640px) {
    .page-shell {
        padding: 14px;
    }

    .hero {
        border-radius: 26px;
    }

    .hero__inner {
        padding: 28px 22px 30px;
    }

    .question-grid {
        grid-template-columns: 1fr;
    }

    .question-card {
        padding: 18px;
        border-radius: 22px;
    }

    .question-card__header,
    .question-card__meta,
    .vote-form {
        flex-direction: column;
        align-items: stretch;
    }
}
