:root {
    --primary: #2c3e50;
    --primary-dark: #1a252f;
    --accent: #398be3;
    --accent-dark: #2b6cb0;
    --text: #2d3748;
    --text-light: #718096;
    --bg: #ffffff;
    --bg-alt: #f9fafb;
    --border: #e2e8f0;
    --radius: 10px;
    --shadow: 0 4px 16px rgba(0,0,0,0.08);
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.6;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.container { max-width: 1140px; margin: 0 auto; padding: 0 24px; }

h1, h2, h3, h4 { color: var(--primary); margin-top: 0; }

/* ── Navbar ───────────────────────────────── */
.navbar {
    background: var(--bg);
    border-bottom: 1px solid var(--border);
}
.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
    padding: 14px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.logo {
    display: inline-block;
    font-weight: 800;
    font-size: 1.2rem;
    color: var(--primary);
    text-decoration: none;
}
.logo-wordmark { position: relative; display: inline-block; }
.nav-links {
    list-style: none;
    display: flex;
    gap: 28px;
    margin: 0;
    margin-left: auto;
    padding: 0;
    align-items: center;
}
.nav-links a {
    color: var(--text);
    font-weight: 400;
    font-size: 0.95rem;
    text-decoration: none;
}
.nav-links a:hover { color: var(--accent); }
.nav-actions { display: flex; align-items: center; gap: 16px; margin-left: 24px; }
.logo-wordmark .seasonal-mark { position: static; display: inline-block; width: 0.62em; height: 0.72em; margin-left: 2px; color: var(--text-light); font-size: 0.68rem; line-height: 1; vertical-align: -0.04em; overflow: visible; }
.logo-wordmark #logoPeriod[hidden], .logo-wordmark .seasonal-mark[hidden] { display: none; }
.poppy-mark { position: relative; display: inline-block; width: 0.72em; height: 0.72em; vertical-align: -0.04em; background: radial-gradient(circle at 50% 19%, #c53030 0 30%, transparent 32%), radial-gradient(circle at 81% 50%, #c53030 0 30%, transparent 32%), radial-gradient(circle at 50% 81%, #c53030 0 30%, transparent 32%), radial-gradient(circle at 19% 50%, #c53030 0 30%, transparent 32%); }
.poppy-mark::after { content: ''; position: absolute; width: 25%; height: 25%; left: 37.5%; top: 37.5%; border-radius: 50%; background: #171717; }
.theme-pride .seasonal-mark { background: linear-gradient(90deg, #e53e3e, #d69e2e, #38a169, #3182ce, #805ad5); background-clip: text; -webkit-background-clip: text; color: transparent; }
.theme-canada .seasonal-mark, .theme-remembrance .seasonal-mark { color: #c53030; }
.theme-remembrance .poppy-mark { color: #c53030; }
.theme-truth-reconciliation .seasonal-mark { color: #c05621; }
.theme-black-history .seasonal-mark { color: #8f6418; }
.theme-thanksgiving .seasonal-mark { color: #b7791f; }
.theme-truth-reconciliation .seasonal-mark,
.theme-black-history .seasonal-mark,
.theme-new-year .seasonal-mark,
.theme-thanksgiving .seasonal-mark { width: 0.56em; font-size: 0.58rem; }
.theme-pride .seasonal-mark { width: 0.9em; font-size: 0.62rem; white-space: nowrap; }
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
}
.mobile-menu-btn span {
    width: 24px;
    height: 2px;
    background: var(--primary);
}

@media (max-width: 800px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg);
        flex-direction: column;
        padding: 20px 24px;
        border-bottom: 1px solid var(--border);
        gap: 16px;
    }
    .nav-links.open { display: flex; }
    .mobile-menu-btn { display: flex; }
}

/* ── Buttons ──────────────────────────────── */
.btn {
    display: inline-block;
    padding: 8px 18px;
    border-radius: 6px;
    font-weight: 500;
    font-size: 0.88rem;
    cursor: pointer;
    border: 1px solid transparent;
    text-decoration: none;
    transition: background-color 0.15s, border-color 0.15s, color 0.15s;
}
.btn:hover { text-decoration: none; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dark); }
.btn-post { background: transparent; color: var(--primary); border-color: var(--primary); font-weight: 400; }
.btn-post:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.btn-outline { background: transparent; color: var(--primary); border-color: var(--border); }
.btn-outline:hover { background: var(--bg-alt); border-color: var(--primary); }
.btn-small { padding: 6px 14px; font-size: 0.8rem; }
.btn-danger { background: #e53e3e; color: #fff; }
.btn-danger:hover { background: #c53030; }
.btn:disabled { opacity: 0.6; cursor: not-allowed; }

/* ── Hero ─────────────────────────────────── */
.hero {
    background: var(--bg-alt);
    border-bottom: 1px solid var(--border);
    padding: 60px 0 44px;
}
.hero h1 { color: var(--primary); font-size: 2.4rem; margin-bottom: 14px; }
.hero p { font-size: 1.1rem; color: var(--text-light); max-width: 720px; margin: 0; }
.hero-actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

/* ── Homepage header banner ──────────────────────── */
.home-header {
    background: #fff;
    padding: 60px 0 40px;
    border-bottom: 1px solid var(--border);
}
.home-header .hp-label {
    display: inline-block;
    color: var(--accent-dark);
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    font-size: 0.8rem;
    margin-bottom: 10px;
}
.home-header h1 { font-size: 2.4rem; margin-bottom: 14px; }
.home-header h1 .hh-line { display: inline; }
.home-header p { color: var(--text-light); font-size: 1.1rem; max-width: 720px; margin: 0; }
.home-header h1 span {
    display: inline-block;
    color: inherit;
    transition: opacity 0.75s ease, color 0.75s ease, -webkit-text-fill-color 0.75s ease;
    -webkit-text-fill-color: currentColor;
}
@keyframes sloganGoldShine {
    0%, 100% { background-position: 150% center; }
    50% { background-position: 0 center; }
}
.home-header h1 span.slogan-hidden { opacity: 0; }
.home-header h1 span.slogan-you-shine {
    background: linear-gradient(110deg, #b28a3c 0%, #c5a65c 46%, #d8c487 52%, #b28a3c 62%, #b28a3c 100%);
    background-size: 180% auto;
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: sloganGoldShine 2.4s ease-in-out 1;
}
.home-header h1 span.slogan-you-fade-black {
    background: none;
    background-clip: initial;
    -webkit-background-clip: initial;
    -webkit-text-fill-color: currentColor;
    animation: sloganGoldFadeBlack 1.2s ease-in forwards;
}
@keyframes sloganGoldFadeBlack {
    from { color: #d9bd68; }
    to { color: var(--primary); }
}

/* ── Homepage split layout: welcome (left) + opportunities (right) ── */
.container-wide { max-width: 1400px; }

.home-split-section {
    background: var(--bg-alt);
    padding: 50px 0 90px;
}
.home-split { display: flex; align-items: flex-start; gap: 40px; }
.home-welcome {
    flex: 0 0 26%;
    position: sticky;
    top: 90px;
}
.home-intro {
    color: var(--text-light);
    font-size: 1rem;
    margin: 0 0 24px;
}
.home-welcome .hp-label {
    display: block;
    color: var(--accent-dark);
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    font-size: 0.8rem;
    margin-bottom: 8px;
}
.home-browse {
    flex: 1;
    min-width: 0;
}
@media (max-width: 900px) {
    .home-split { flex-direction: column; }
    .home-welcome { position: static; width: 100%; }
    .home-browse { width: 100%; }
}
@media (max-width: 600px) {
    /* Keep the rotating slogan from reflowing the heading between one and two lines. */
    .home-header h1 { font-size: min(1.8rem, 6vw); }
    .home-header h1 .hh-line { display: block; white-space: nowrap; }
    .home-header-filters { align-items: stretch; flex-direction: column; }
    .home-header-filters .btn { width: 100%; }
    .opp-search-wrap input { padding-right: 126px; }
    .opp-search-wrap select { width: 116px; }
}

.how-stack { display: flex; flex-direction: column; gap: 0; }
.how-card {
    position: relative;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
}
/* Connector column is aligned to the step badge: 24px card padding + half of the 26px badge. */
.how-link {
    position: relative;
    flex: 0 0 auto;
    height: 38px;
}
.how-link-line {
    position: absolute;
    left: 37px;
    top: -1px;
    bottom: -1px;
    width: 2px;
    margin-left: -1px;
    border-radius: 2px;
    background: linear-gradient(to bottom, var(--border) 0%, var(--accent) 45%, var(--accent) 55%, var(--border) 100%);
}
.how-link-bubble {
    position: absolute;
    left: 37px;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--bg);
    border: 1px solid var(--border);
    box-shadow: 0 1px 4px rgba(44, 62, 80, 0.1);
    color: var(--accent);
    font-size: 0.6rem;
    display: flex;
    align-items: center;
    justify-content: center;
}
.how-card-head { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.how-badge {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    font-weight: 800;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.how-card h3 { color: var(--primary); margin: 0; }
.how-card p { color: var(--text-light); margin: 0; font-size: 0.9rem; }

section { padding: 70px 0; }
.section-alt { background: var(--bg-alt); }
.section-header { text-align: center; max-width: 640px; margin: 0 auto 44px; }
.section-header p { color: var(--text-light); }

/* ── Cards / grid ─────────────────────────── */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
@media (max-width: 900px) { .grid-3 { grid-template-columns: 1fr; } }


.card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
}
.card i.card-icon { font-size: 1.8rem; color: var(--accent); margin-bottom: 14px; }

/* ── Tabs (get-involved page) ─────────────── */
.tabs { display: flex; gap: 10px; justify-content: center; margin-bottom: 40px; flex-wrap: wrap; }
.tab-btn {
    background: transparent;
    border: 2px solid var(--border);
    padding: 10px 22px;
    border-radius: 999px;
    font-weight: 700;
    cursor: pointer;
    color: var(--text);
}
.tab-btn.active { background: var(--primary); border-color: var(--primary); color: #fff; }
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ── Opportunity list ─────────────────────── */
.opp-filters {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    position: relative;
}
.opp-search-wrap { position: relative; flex: 1; min-width: 200px; }
.opp-search-wrap i {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-light);
    font-size: 0.9rem;
}
.opp-search-wrap input {
    width: 100%;
    padding: 10px 150px 10px 36px;
    border: 1px solid var(--border);
    border-radius: 6px;
    font-size: 0.95rem;
    background: #fff;
}
.opp-search-wrap select {
    position: absolute;
    top: 1px;
    right: 1px;
    bottom: 1px;
    width: 138px;
    padding: 0 10px;
    border: 0;
    border-left: 1px solid var(--border);
    border-radius: 0 5px 5px 0;
    color: var(--text);
    background: var(--bg-alt);
    font-size: 0.82rem;
}
.home-header-filters { margin: 28px 0 0; max-width: 920px; }

.opp-list {
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    background: #fff;
}
.opp-list .empty-state { padding: 40px 0; }

/* Dense, email-inbox-style expandable row */
.opp-row { border-bottom: 1px solid var(--border); }
.opp-row:last-child { border-bottom: none; }
.opp-row-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 20px;
    cursor: pointer;
    transition: background 0.12s;
}
.opp-row-summary:hover { background: var(--bg-alt); }
.opp-row-main {
    display: flex;
    align-items: baseline;
    gap: 12px;
    flex-wrap: wrap;
    min-width: 0;
}
.opp-row-title { font-weight: 700; color: var(--primary); }
.opp-row-sub { color: var(--text-light); font-size: 0.85rem; white-space: nowrap; }
.opp-row-sub i { color: var(--accent); margin-right: 3px; }
.opp-row-meta { display: flex; align-items: center; gap: 14px; flex-shrink: 0; color: var(--text-light); font-size: 0.85rem; }
.opp-count i { margin-right: 4px; color: var(--accent); }
.opp-chevron { transition: transform 0.18s; }
.opp-row.expanded .opp-chevron { transform: rotate(180deg); }

.opp-row-detail {
    display: none;
    padding: 0 20px 22px;
    border-top: 1px dashed var(--border);
}
.opp-row.expanded .opp-row-detail { display: block; padding-top: 18px; }
.opp-row.new-opportunity { border-color: #d69e2e; background: #fffaf0; animation: newOpportunityHighlight 2.8s ease-out; }
@keyframes newOpportunityHighlight { 0%, 55% { box-shadow: 0 0 0 4px rgba(214,158,46,0.28); } 100% { box-shadow: none; } }
.opp-row-detail p { margin-top: 0; color: var(--text); }

.opp-bottom-row {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
    min-width: 0;
}
.opp-report-zone, .opp-edit-zone { min-width: 0; min-height: 28px; display: flex; align-items: flex-start; justify-content: flex-start; }
.opp-report-form { max-width: 300px; display: flex; flex-direction: column; gap: 8px; }
.opp-report-links { justify-content: flex-start !important; margin-left: 0 !important; }

.opp-secondary-actions {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    width: 100%;
    gap: 14px;
    margin-left: 0;
    text-align: left;
    min-width: 0;
}

.opp-edit-zone {
    text-align: right;
    justify-content: flex-end;
}
.opp-edit-link {
    font-size: 0.82rem;
    color: var(--text-light);
    text-decoration: underline;
    cursor: pointer;
    white-space: nowrap;
}
.opp-edit-link:hover { color: var(--accent-dark); }
.opp-edit-link-danger { color: #c53030; }
.opp-edit-link-danger:hover { color: #9b2c2c; }

.opp-edit-inline {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    max-width: none;
    flex-wrap: wrap;
}
.opp-edit-zone.opp-edit-active { min-width: 0; }
.opp-edit-mini-input {
    padding: 5px 8px;
    border: 1px solid var(--border);
    border-radius: 6px;
    font-size: 0.78rem;
    font-family: inherit;
}
.opp-edit-inline .opp-edit-mini-input { flex: 1; min-width: 0; }

.opp-edit-fields {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-width: 100%;
    width: 100%;
    margin-left: 0;
}
.opp-edit-fields textarea.opp-edit-mini-input { min-height: 70px; resize: vertical; }

.opp-edit-links {
    display: flex;
    gap: 14px;
    justify-content: flex-end;
    max-width: 100%;
    margin-left: 0;
    margin-top: 8px;
}

.opp-edit-alert:not(:empty) {
    text-align: right;
    font-size: 0.8rem;
    margin-top: 6px;
}
.opp-edit-alert.success { color: #1e7e4b; }
.opp-edit-alert.error { color: #c53030; }

.opp-edit-meta {
    font-size: 0.78rem;
    color: var(--text-light);
    margin-top: 10px;
}
.opp-edit-history-list {
    list-style: none;
    padding: 0;
    margin: 8px 0 0;
    font-size: 0.78rem;
    color: var(--text-light);
}
.opp-edit-history-list li { padding: 3px 0; border-top: 1px dashed var(--border); }
.opp-edit-history-list li:first-child { border-top: none; }
.opp-edit-alert:empty { display: none; }
.site-toast {
    position: fixed;
    left: 50%;
    bottom: 22px;
    z-index: 1400;
    max-width: min(420px, calc(100vw - 32px));
    padding: 10px 14px;
    border-radius: 5px;
    background: var(--primary);
    color: #fff;
    font-size: 0.82rem;
    opacity: 0;
    pointer-events: none;
    transform: translate(-50%, 12px);
    transition: opacity 0.2s ease, transform 0.2s ease;
}
.site-toast.visible { opacity: 1; transform: translate(-50%, 0); }
.site-toast.error { background: #c53030; }
.site-toast.success { background: #276749; }

.opp-category {
    display: inline-block;
    background: #e6f0fb;
    color: var(--accent-dark);
    font-size: 0.72rem;
    font-weight: 700;
    padding: 2px 9px;
    border-radius: 999px;
}

.opp-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}
@media (max-width: 700px) {
    .opp-secondary-actions { grid-template-columns: 1fr; gap: 8px; }
    .opp-edit-zone { justify-content: flex-start; text-align: left; }
}
.empty-state { text-align: center; color: var(--text-light); padding: 40px 0; }

/* ── Forms ────────────────────────────────── */
.form-group { margin-bottom: 20px; }
.form-group label { display: block; font-weight: 700; margin-bottom: 6px; font-size: 0.92rem; }
.form-group input, .form-group textarea, .form-group select {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 0.95rem;
    font-family: inherit;
}
.form-group textarea { resize: vertical; min-height: 110px; }
.form-hint { font-size: 0.8rem; color: var(--text-light); margin-top: 4px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 700px) { .form-row { grid-template-columns: 1fr; } }
.form-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 32px;
    box-shadow: var(--shadow);
    max-width: 640px;
    margin: 0 auto;
}
.post-page-card { max-width: 1400px; margin: 0 auto; padding: 0 24px; }
.post-progress { height: 4px; background: var(--border); overflow: hidden; margin-bottom: 10px; }
.post-progress-bar { display: block; width: 25%; height: 100%; background: var(--primary); transition: width 0.35s ease; }
.post-progress-label { color: var(--text-light); font-size: 0.78rem; margin: 0 0 34px; }
.post-step { display: none; max-width: 760px; }
.post-step.active { display: block; animation: postStepIn 0.3s ease both; }
.post-step h2 { font-size: 1.65rem; font-weight: 500; margin-bottom: 8px; }
.post-step-copy { color: var(--text-light); margin: 0 0 28px; }
.post-step-actions { display: flex; gap: 10px; justify-content: flex-start; align-items: center; margin-top: 28px; }
.post-verify-step { max-width: 560px; }
@keyframes postStepIn { from { opacity: 0; transform: translateX(10px); } to { opacity: 1; transform: translateX(0); } }
.post-loading-overlay { display: none; position: fixed; inset: 0; z-index: 1500; background: rgba(20, 25, 30, 0.18); align-items: center; justify-content: center; }
.post-loading-overlay.open { display: flex; }
.post-loading-spinner { width: 34px; height: 34px; border: 3px solid rgba(255,255,255,0.55); border-top-color: var(--primary); border-radius: 50%; animation: spin 0.7s linear infinite; }
.form-alert {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 0.9rem;
    display: none;
}
.form-alert.success { background: #e6fbf0; color: #1e7e4b; display: block; }
.form-alert.error { background: #fdecec; color: #c53030; display: block; }
.code-input {
    letter-spacing: 6px;
    font-size: 1.3rem;
    text-align: center;
    font-weight: 700;
}

/* ── Modal ────────────────────────────────── */
.modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}
.modal-overlay.open { display: flex; }
.modal-box {
    background: #fff;
    border-radius: var(--radius);
    padding: 32px;
    max-width: 480px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}
.modal-close {
    position: absolute;
    top: 16px;
    right: 20px;
    font-size: 1.3rem;
    cursor: pointer;
    color: var(--text-light);
    background: none;
    border: none;
}
.moderator-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1100;
    align-items: flex-end;
    justify-content: flex-end;
    padding: 18px 24px;
    pointer-events: none;
}
.moderator-overlay.open, .moderator-overlay.closing { display: flex; }
.moderator-sheet {
    width: min(720px, 100%);
    max-height: 75vh;
    overflow-y: auto;
    padding: 24px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 12px 36px rgba(0,0,0,0.2);
    pointer-events: auto;
    animation: moderatorSheetIn 0.25s ease-out both;
}
.moderator-overlay:not(.open) .moderator-sheet { animation-name: moderatorSheetOut; }
@keyframes moderatorSheetIn { from { opacity: 0; transform: translateY(28px); } to { opacity: 1; transform: translateY(0); } }
@keyframes moderatorSheetOut { from { opacity: 1; transform: translateY(0); } to { opacity: 0; transform: translateY(28px); } }
.moderator-sheet h3 { font-size: 1.1rem; font-weight: 500; margin-bottom: 4px; }
.moderator-sheet > .modal-close { position: sticky; top: -4px; float: right; z-index: 2; margin: -6px -6px 0 8px; padding: 2px 4px; background: #fff; }
.admin-login-sheet { width: min(360px, 100%); }
.admin-login-sheet .form-group { margin-bottom: 12px; }
.admin-login-sheet label { color: var(--text); font-size: 0.84rem; font-weight: 400; }
.admin-login-sheet input { padding: 8px 10px; }
.moderator-layout { display: flex; gap: 24px; }
.moderator-tabs { width: 92px; flex: 0 0 92px; display: flex; flex-direction: column; gap: 4px; padding-top: 4px; }
.moderator-tab { padding: 8px 10px; border: 0; border-left: 2px solid transparent; background: transparent; color: var(--text-light); text-align: left; font: inherit; font-size: 0.82rem; cursor: pointer; }
.moderator-tab:hover, .moderator-tab.active { color: var(--primary); border-left-color: var(--accent); background: var(--bg-alt); }
.moderator-content { flex: 1; min-width: 0; }
.moderator-panel { display: none; }
.moderator-panel.active { display: block; }
.moderator-search-form { display: flex; gap: 8px; margin: 16px 0; flex-wrap: wrap; }
.moderator-search-form input { flex: 1; min-width: 130px; padding: 8px 10px; border: 1px solid var(--border); border-radius: 5px; font: inherit; }
.moderator-results h4 { color: var(--primary); font-size: 0.85rem; font-weight: 500; margin: 18px 0 8px; }
.moderator-range-label { color: var(--text-light); display: block; font-size: 0.75rem; margin-top: 14px; }
.moderator-range { padding: 7px 9px; border: 1px solid var(--border); border-radius: 5px; color: var(--text); background: #fff; font: inherit; font-size: 0.8rem; }
.moderator-clear-analytics { margin: 12px 0 0 8px; }
.moderator-stat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 18px 0; }
.moderator-stat-grid div { padding: 12px; border: 1px solid var(--border); background: var(--bg-alt); }
.moderator-stat-grid strong, .moderator-stat-grid span { display: block; }
.moderator-stat-grid strong { color: var(--primary); font-size: 1.25rem; font-weight: 500; }
.moderator-stat-grid span { color: var(--text-light); font-size: 0.75rem; }
.moderator-city-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.moderator-list, .moderator-results-list { list-style: none; padding: 0; margin: 0; }
.moderator-list li, .moderator-results-list li { display: flex; justify-content: space-between; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--border); font-size: 0.8rem; }
.moderator-results-list li { align-items: center; flex-wrap: wrap; }
.moderator-results-list small { display: block; width: 100%; color: var(--text-light); font-size: 0.74rem; }
.moderator-filter-list { list-style: none; margin: 16px 0 0; padding: 0; }
.moderator-filter-list li { display: flex; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--border); }
.moderator-filter-fields { display: flex; gap: 6px; flex: 1; min-width: 0; }
.moderator-filter-fields input, .moderator-filter-fields select { min-width: 0; padding: 6px 8px; border: 1px solid var(--border); border-radius: 4px; font: inherit; font-size: 0.78rem; }
.moderator-filter-fields input { flex: 1; }
.moderator-filter-actions { display: flex; gap: 4px; flex-shrink: 0; }
@media (max-width: 600px) {
    .moderator-overlay { padding: 10px; }
    .moderator-sheet { max-height: 82vh; padding: 20px; }
    .moderator-layout { gap: 12px; }
    .moderator-tabs { width: 72px; flex-basis: 72px; }
    .moderator-city-grid { grid-template-columns: 1fr; gap: 8px; }
    .moderator-filter-list li { align-items: stretch; flex-direction: column; }
    .moderator-filter-actions { justify-content: flex-end; }
}
.respond-modal-box { max-width: 380px; padding: 24px; }
.respond-modal-box h3 { font-size: 1.08rem; font-weight: 500; padding-right: 24px; margin: 0 0 12px; }
.respond-progress { height: 3px; margin: 0 0 16px; background: var(--border); border-radius: 2px; overflow: hidden; }
.respond-progress span { display: block; width: 33.333%; height: 100%; background: var(--accent); transition: width 0.2s ease; }
.respond-step { display: none; }
.respond-step.active { display: block; }
.respond-step label { display: block; color: var(--text); font-size: 0.84rem; font-weight: 400; margin-bottom: 6px; }
.respond-step label span { color: var(--text-light); font-weight: 400; }
.respond-step input[type="text"], .respond-step input[type="email"], .respond-step input[type="tel"] { width: 100%; padding: 7px 10px; border: 1px solid var(--border); border-radius: 5px; font: inherit; margin-bottom: 12px; }
.respond-check { display: flex !important; gap: 8px; align-items: flex-start; margin: 4px 0 16px; font-weight: 400 !important; }
.respond-check input { margin-top: 3px; }
.respond-check span { font-size: 0.8rem; color: var(--text-light); }

/* ── Policies page ────────────────────────── */
.policy-section { max-width: 1000px; margin: 0 0 50px; scroll-margin-top: 90px; }
.policy-section h3 { font-size: 1.05rem; font-weight: 600; margin: 28px 0 8px; }
.policy-updated { color: var(--text-light); font-size: 0.82rem; margin-top: -6px; }
.policy-list { margin: 0 0 14px; padding-left: 20px; }
.policy-list li { margin-bottom: 6px; }
.policy-warning {
    max-width: 1000px;
    margin-bottom: 28px;
    padding: 14px 18px;
    border: 1px solid #e6c65c;
    border-left: 4px solid #c99700;
    border-radius: 6px;
    background: #fff8d6;
    color: #5f4b00;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
.policy-warning a { color: #805f00; font-weight: 500; }
.policy-nav { display: flex; gap: 20px; justify-content: flex-start; margin-bottom: 40px; flex-wrap: wrap; }
.about-main { max-width: 1180px; }
.about-lead { display: block; max-width: 760px; padding-bottom: 64px; border-bottom: 1px solid var(--border); text-align: left; }
.about-label { color: var(--accent-dark); font-size: 0.75rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; }
.about-lead h2 { max-width: 620px; font-size: 2rem; margin: 0 0 18px; text-align: left; }
.about-lead > p { max-width: 680px; margin: 0; color: var(--text-light); font-size: 1.05rem; text-align: left; }
.about-principles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; }
.about-principle { padding: 32px 28px 8px 0; margin-right: 28px; border-right: 1px solid var(--border); }
.about-principle:last-child { border-right: 0; margin-right: 0; }
.about-principle h3 { font-size: 1.1rem; font-weight: 500; margin: 16px 0 8px; }
.about-principle p { color: var(--text-light); font-size: 0.9rem; margin: 0; }
.about-process-section { padding: 64px 0; background: #fff; }
.about-process { max-width: 1080px; }
.about-process h2 { max-width: 620px; font-size: 1.8rem; margin: 10px 0 34px; }
.about-process-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; }
.about-process-steps p { display: flex; flex-direction: column; gap: 5px; margin: 0; }
.about-process-steps strong { color: var(--primary); font-weight: 500; }
.about-process-steps span { color: var(--text-light); font-size: 0.9rem; }
.about-contact { max-width: 1000px; }
@media (max-width: 800px) {
    .about-lead, .about-process-steps { grid-template-columns: 1fr; gap: 24px; }
    .about-lead { padding-bottom: 42px; }
    .about-principles { grid-template-columns: 1fr; }
    .about-principle { border-right: 0; border-bottom: 1px solid var(--border); margin-right: 0; padding: 26px 0; }
    .about-principle:last-child { border-bottom: 0; }
}

/* ── Footer (preserved) ───────────────────── */
/* The svg's fill is the wave shape itself (matches the section above it);
   the container background fills the svg's transparent gaps with the
   footer's own color so no stray sliver of page background shows through. */
.footer-wave-top { line-height: 0; margin-top: 0; background: var(--primary); }
.footer-wave-path { fill: var(--bg-alt); }
.footer { background: var(--primary); color: #dfe6ec; padding-top: 50px; }
.footer-container {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.4fr;
    gap: 30px;
    padding-bottom: 40px;
}
@media (max-width: 900px) { .footer-container { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer-container { grid-template-columns: 1fr; } }
.footer-col h3, .footer-col h4 { color: #fff; }
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col ul li { margin-bottom: 8px; }
.footer-col ul li a { color: #cbd5e0; }
.footer-col ul li a:hover { color: #fff; }
.social-links { display: flex; gap: 12px; margin-top: 14px; }
.social-links a {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
}
.newsletter-form { display: flex; gap: 8px; margin-top: 10px; }
.newsletter-form input {
    flex: 1;
    padding: 10px 12px;
    border-radius: 6px;
    border: none;
}
.newsletter-btn {
    background: var(--accent);
    color: #fff;
    border: none;
    padding: 10px 18px;
    border-radius: 6px;
    font-weight: 700;
    cursor: pointer;
}
.newsletter-status { margin: 8px 0 0; font-size: 0.78rem; color: #a0aec0; min-height: 1em; }
.newsletter-status.success { color: #9ae6b4; }
.newsletter-status.error { color: #feb2b2; }

/* ── Email preference centre ───────────────── */
.prefs-card {
    max-width: 620px;
    margin: 0 auto 60px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 26px;
}
.prefs-email { color: var(--text-light); font-size: 0.9rem; margin: 0 0 18px; }
.prefs-option {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 10px;
    cursor: pointer;
}
.prefs-option:hover { border-color: var(--accent); }
.prefs-option input { margin-top: 4px; }
.prefs-option small { display: block; color: var(--text-light); font-size: 0.82rem; }
.prefs-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
.prefs-note { color: var(--text-light); font-size: 0.8rem; margin: 16px 0 0; }

/* ── Moderator newsletter composer ─────────── */
.moderator-newsletter-form { display: flex; flex-direction: column; gap: 6px; margin: 14px 0 18px; }
.moderator-newsletter-form label { font-size: 0.78rem; font-weight: 700; color: var(--text-light); }
.moderator-newsletter-form input,
.moderator-newsletter-form select,
.moderator-newsletter-form textarea {
    padding: 8px 10px;
    border: 1px solid var(--border);
    border-radius: 5px;
    font: inherit;
    font-size: 0.85rem;
}
.moderator-newsletter-form textarea { resize: vertical; min-height: 140px; }
.moderator-newsletter-form button { align-self: flex-start; margin-top: 6px; }
.moderator-newsletter-review {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px;
    margin-bottom: 20px;
    background: var(--bg-alt);
}
.moderator-newsletter-review h4 { margin: 0 0 8px; }
.moderator-newsletter-count { margin: 0 0 12px; font-size: 0.85rem; }
.moderator-newsletter-preview {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 14px;
    font-size: 0.85rem;
    margin-bottom: 14px;
    max-height: 240px;
    overflow-y: auto;
}
.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.12);
    padding: 18px 24px;
    text-align: left;
    font-size: 0.8rem;
    color: #a0aec0;
}
.footer-bottom p { margin: 4px 0; }

/* ── Utility ──────────────────────────────── */
.text-center { text-align: center; }
.mt-2 { margin-top: 20px; }
.spinner { display: inline-block; width: 16px; height: 16px; border: 2px solid rgba(255,255,255,0.4); border-top-color: #fff; border-radius: 50%; animation: spin 0.6s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
