/* Keep Our Port Public (NZDE) — campaign demo styles
   Built on the Guardian Angel demo stylesheet, re-themed for the KOPP campaign.
   Class names are unchanged so the shared demo JS works as-is. */

:root {
    --kopp-navy: #0a2540;      /* deep ocean navy — header/footer */
    --kopp-teal: #0a9396;      /* primary accent */
    --kopp-teal-dark: #087f86;
    --kopp-sand: #f4f1ea;      /* page background */
    --kopp-ink: #1a2a33;
}

/* Reset and base */
* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: var(--kopp-ink);
    background-color: var(--kopp-sand);
}

.container { max-width: 800px; margin: 0 auto; padding: 20px; }

/* Header */
header {
    background: linear-gradient(120deg, var(--kopp-navy), #123a5a);
    color: white;
    padding: 18px 0;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

header .container { display: flex; justify-content: space-between; align-items: center; }

header h1 { font-size: 1.4rem; margin: 0; letter-spacing: 0.3px; }
header h1 .brandmark { color: var(--kopp-teal); }

header nav { display: flex; gap: 15px; align-items: center; }

header nav a {
    color: white;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 4px;
    transition: background-color 0.3s;
}
header nav a:hover { background-color: rgba(255,255,255,0.12); }

/* Campaign banner */
.campaign-banner {
    background: var(--kopp-teal);
    color: white;
    text-align: center;
    padding: 10px 16px;
    font-weight: 600;
    letter-spacing: 0.3px;
}
.campaign-banner small { display: block; font-weight: 400; opacity: 0.9; }

/* Main content */
main { padding: 40px 0; }

/* Cards (petition + generic) */
.petition-card {
    background: white;
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 2px 8px rgba(10,37,64,0.08);
    margin-bottom: 30px;
    border-top: 4px solid var(--kopp-teal);
}

.petition-card h2 { color: var(--kopp-navy); margin-bottom: 15px; }

.petition-meta { font-size: 0.9rem; color: #5a6b75; margin-bottom: 20px; }
.petition-meta span { margin-right: 15px; }
.petition-meta .category {
    background: #e6f4f4;
    color: var(--kopp-teal-dark);
    padding: 2px 10px;
    border-radius: 12px;
    font-weight: 600;
}

.petition-description { color: #40525c; margin-bottom: 25px; line-height: 1.8; }

/* Progress bar */
.progress-section { margin: 30px 0; }
.progress {
    width: 100%;
    height: 30px;
    background-color: #e2e0d8;
    border-radius: 15px;
    overflow: hidden;
    margin-bottom: 10px;
}
.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--kopp-teal), #2a9d8f);
    transition: width 0.5s ease-out;
    border-radius: 15px;
}
.signature-count { font-size: 1.2rem; font-weight: bold; color: var(--kopp-navy); }
.signature-count strong { color: var(--kopp-teal-dark); }

/* Forms */
.sign-section {
    background: #faf9f5;
    padding: 25px;
    border-radius: 8px;
    margin-top: 30px;
    border: 1px solid #ece9e0;
}
.sign-section h3 { margin-bottom: 20px; color: var(--kopp-navy); }

.form-group { margin-bottom: 15px; }
.form-group label { display: block; margin-bottom: 5px; font-weight: 600; color: #40525c; }
.form-group input {
    width: 100%;
    padding: 10px;
    border: 1px solid #cfd8dc;
    border-radius: 4px;
    font-size: 1rem;
}
.form-group input:focus { outline: none; border-color: var(--kopp-teal); }
.form-group small { color: #77848c; font-size: 0.85rem; }

.btn {
    display: inline-block;
    padding: 12px 24px;
    font-size: 1rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.1s;
}
.btn-primary { background-color: var(--kopp-teal); color: white; }
.btn-primary:hover { background-color: var(--kopp-teal-dark); }
.btn-primary:active { transform: translateY(2px); }
.btn-secondary { background-color: #607d8b; color: white; padding: 8px 16px; font-size: 0.9rem; }
.btn-secondary:hover { background-color: #4d6572; }

/* Recent signatures */
.signatures-section {
    background: white;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 2px 8px rgba(10,37,64,0.08);
    margin-top: 30px;
}
.signatures-section h3 { margin-bottom: 15px; color: var(--kopp-navy); }
.signatures-list { list-style: none; padding: 0; }
.signatures-list li { padding: 10px 0; border-bottom: 1px solid #eee; }
.signatures-list li:last-child { border-bottom: none; }

/* Auth pages */
.auth-page { display: flex; align-items: center; justify-content: center; min-height: 80vh; }
.auth-form {
    background: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(10,37,64,0.08);
    width: 100%;
    max-width: 400px;
}
.auth-form h1 { margin-bottom: 20px; color: var(--kopp-navy); }
.auth-link { margin-top: 20px; text-align: center; color: #666; }
.auth-link a { color: var(--kopp-teal-dark); text-decoration: none; }
.auth-link a:hover { text-decoration: underline; }

/* Status messages */
.loading { text-align: center; color: #666; margin: 40px 0; }
.error {
    background-color: #fdecea;
    border-left: 4px solid #d64545;
    padding: 15px; margin: 20px 0; border-radius: 4px;
}
.success {
    background-color: #e6f4f1;
    border-left: 4px solid var(--kopp-teal);
    padding: 15px; margin: 20px 0; border-radius: 4px;
}
.success h3 { margin-bottom: 10px; color: var(--kopp-teal-dark); }
.hidden { display: none; }

/* Footer */
footer {
    text-align: center;
    padding: 24px 20px;
    color: #eef2f4;
    font-size: 0.9rem;
    margin-top: 40px;
    background: var(--kopp-navy);
}
footer a { color: var(--kopp-teal); text-decoration: none; }

/* Responsive */
@media (max-width: 600px) {
    header .container { flex-direction: column; gap: 15px; }
    .container { padding: 15px; }
    .petition-card { padding: 20px; }
    .auth-form { padding: 20px; }
}

/* Survey styles */
.survey-description { color: #40525c; margin-bottom: 25px; line-height: 1.8; }
.statements-list { display: flex; flex-direction: column; gap: 20px; }
.statement-card {
    background: white;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 2px 8px rgba(10,37,64,0.08);
    border-left: 4px solid var(--kopp-teal);
}
.statement-text { font-size: 1.1rem; font-weight: 500; color: var(--kopp-navy); margin-bottom: 10px; }
.statement-source { color: #77848c; margin-bottom: 15px; }
.vote-options { display: flex; gap: 20px; margin-top: 15px; flex-wrap: wrap; }
.vote-option {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 8px 16px;
    border-radius: 4px;
    background: #f0efe8;
    transition: background-color 0.2s;
}
.vote-option:hover { background: #e3e1d7; }
.vote-option input[type="radio"] { width: auto; margin: 0; }

.results-list { display: flex; flex-direction: column; gap: 20px; }
.result-card {
    background: white;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 2px 8px rgba(10,37,64,0.08);
}
.result-text { font-size: 1.1rem; font-weight: 500; color: var(--kopp-navy); margin-bottom: 15px; }
.vote-bars { display: flex; gap: 10px; margin-top: 15px; }
.vote-bar {
    flex: 1;
    height: 30px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 0.85rem;
    min-width: 60px;
}
.vote-bar.agree { background-color: var(--kopp-teal); }
.vote-bar.disagree { background-color: #d64545; }
.vote-bar.pass { background-color: #9aa5ab; }
