/* ---------------------------------------------------------------
   Theme – adjust these to re-skin the whole site
   Palette is taken from the pamphlet image: warm black, sepia
   amber, cream paper and a touch of teal.
   --------------------------------------------------------------- */
:root {
    --color-page-bg: #1a1410;       /* warm black */
    --color-paper: #f4ead8;         /* cream "poster" paper */
    --color-accent: #d9902f;        /* amber */
    --color-accent-light: #f0b45a;
    --color-accent-dark: #b5532f;   /* terracotta, for headings on paper */
    --color-teal: #2f7f7a;
    --color-ink: #2d2a26;
    --color-cream: #f4ead8;
    --color-form-bg: #2b6561;       /* sign-up panel (teal from the image) */
    --radius: 0.3rem;
    --font-display: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
    --font-body: "Avenir Next", "Segoe UI", system-ui, sans-serif;
}

/* --------------------------------------------------------------- */

* { box-sizing: border-box; }

html { height: 100%; }

body {
    margin: 0;
    min-height: 100vh;
    background: var(--color-page-bg);
    color: var(--color-ink);
    font-family: var(--font-body);
    line-height: 1.6;
}

/* ---------- Fixed backdrop band: stays put while the cards scroll over it,
   fading from the image into the page colour towards the bottom ---------- */
.backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: clamp(18rem, 42vh, 26rem);
    z-index: -1;
    background:
        linear-gradient(
            to bottom,
            rgba(26, 20, 17, 0.45) 0%,
            rgba(26, 20, 17, 0.6) 55%,
            var(--color-page-bg) 100%
        ),
        url("pamphlet_empty.jpg") center 58% / cover no-repeat;
}

/* ---------- Header: lettering in the spirit of an old record sleeve ---------- */
.hero {
    padding: 4.5rem 1.25rem 3.5rem;
    text-align: center;
}

.hero h1 {
    font-family: var(--font-display);
    font-weight: 500;
    font-size: clamp(1.8rem, 6.5vw, 3.4rem);
    line-height: 1.15;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin: 0 0 0.6rem;
    color: var(--color-cream);
    text-shadow: 0 2px 18px rgba(0, 0, 0, 0.6);
}

.tagline {
    margin: 0;
    color: var(--color-accent);
    font-family: var(--font-display);
    font-style: italic;
    font-size: clamp(1.05rem, 3vw, 1.35rem);
    letter-spacing: 0.04em;
    text-shadow: 0 1px 10px rgba(0, 0, 0, 0.7);
}

/* compact header on the legal pages */
.hero-compact { padding: 2.5rem 1.25rem 2rem; }

.site-title {
    margin: 0;
    font-family: var(--font-display);
    font-size: clamp(1.1rem, 4vw, 1.5rem);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    text-shadow: 0 2px 18px rgba(0, 0, 0, 0.6);
}

.site-title a { color: var(--color-cream); text-decoration: none; }
.site-title a:hover { color: var(--color-accent); }

/* ---------- Layout ---------- */
.page {
    max-width: 46rem;
    margin: 0 auto;
    padding: 0 1.25rem 3rem;
}

/* ---------- Event card: flat cream paper ---------- */
.event-card {
    background: var(--color-paper);
    border-radius: var(--radius);
    box-shadow: 0 1rem 2.5rem rgba(0, 0, 0, 0.45);
    padding: 2.25rem 2rem 0;
    margin-bottom: 2.5rem;
}

.event-card h2 {
    font-family: var(--font-display);
    font-weight: 500;
    font-size: clamp(1.6rem, 5vw, 2.1rem);
    line-height: 1.2;
    margin: 0 0 1.1rem;
    color: var(--color-accent-dark);
}

/* legal pages: same card without a form panel */
.event-card.legal { padding-bottom: 2rem; }
.event-card.legal .event-body { margin-bottom: 0; }

.event-body h3 {
    font-family: var(--font-display);
    font-weight: 500;
    font-size: 1.15rem;
    margin: 1.4rem 0 0.3rem;
}

/* section line, written as --- in the markdown */
.event-body hr {
    border: 0;
    border-top: 1px solid rgba(45, 42, 38, 0.3);
    margin: 0 0 1.5rem;
}

.event-body { margin-bottom: 2rem; }

.event-body p { margin: 0 0 0.9rem; }

/* extra gap, written as a line with only <br> in the markdown */
.event-body .spacer { height: 1.2rem; }


.event-body em { color: var(--color-accent-dark); }

/* the tagline right after the heading's section line: larger and black */
.event-card:not(.legal) .event-body h2 + hr + p {
    font-size: 1.35rem;
    line-height: 1.3;
    margin-bottom: 0.4rem;
}

.event-card:not(.legal) .event-body h2 + hr + p em { color: var(--color-ink); }


.event-body ul {
    margin: 0.5rem 0 1.1rem;
    padding-left: 1.25rem;
}

.event-body li { margin-bottom: 0.3rem; padding-left: 0.2rem; }

.event-body li::marker { color: var(--color-accent); }

.event-body a {
    color: var(--color-accent-dark);
    font-weight: 600;
    text-decoration-color: var(--color-accent);
    text-decoration-thickness: 2px;
    text-underline-offset: 3px;
}

.event-body a:hover { color: var(--color-teal); text-decoration-color: var(--color-teal); }

/* ---------- Sign-up form: its own coloured area, full width of the card ---------- */
.signup {
    margin: 0 -2rem;
    padding: 2rem 2rem 2.25rem;
    background: var(--color-form-bg);
    color: var(--color-cream);
    border-radius: 0 0 var(--radius) var(--radius);
}

.signup h3 {
    font-family: var(--font-display);
    font-weight: 500;
    font-size: 1.5rem;
    margin: 0 0 1.25rem;
    color: var(--color-cream);
}

.signup .field {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    margin-bottom: 1rem;
}

.signup label {
    font-size: 0.85rem;
    letter-spacing: 0.03em;
    color: rgba(244, 234, 216, 0.9);
}

.signup input,
.signup textarea {
    font: inherit;
    padding: 0.6rem 0.8rem;
    border: 1px solid transparent;
    border-radius: var(--radius);
    background: #fbf5e9;
    color: var(--color-ink);
}

.signup input:focus,
.signup textarea:focus {
    outline: 2px solid var(--color-accent-light);
    outline-offset: 2px;
}

.signup textarea { resize: vertical; min-height: 4.5rem; }

.signup button {
    font: inherit;
    font-weight: 700;
    letter-spacing: 0.04em;
    padding: 0.7rem 2rem;
    border: none;
    border-radius: var(--radius);
    background: var(--color-accent-light);
    color: #1a1410;
    cursor: pointer;
    transition: background 0.15s ease;
}

.signup button:hover { background: #f7c577; }
.signup button:focus-visible { outline: 2px solid var(--color-cream); outline-offset: 3px; }
.signup button:disabled { opacity: 0.6; cursor: wait; }

.signup .status {
    margin: 0.9rem 0 0;
    font-size: 0.95rem;
    min-height: 1.4em;
}

.signup .status.ok { color: #c2f2cc; }
.signup .status.error { color: #ffd3ca; }

.signup .form-intro { margin: -0.5rem 0 1.25rem; }

.signup a {
    color: var(--color-accent-light);
    font-weight: 600;
    text-underline-offset: 3px;
}

.signup a:hover { color: #fff; }

/* confirmation shown in place of the fields after a successful sign-up */
.signup [hidden] { display: none !important; }

.signup .done { outline: none; }

.signup .done-title {
    margin: 0 0 1.25rem;
    font-family: var(--font-display);
    font-size: 1.5rem;
    line-height: 1.25;
}

.signup .done-title::before {
    content: "✓";
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.6rem;
    height: 2.6rem;
    margin-bottom: 0.8rem;
    border-radius: 50%;
    background: var(--color-accent-light);
    color: #1a1410;
    font-family: var(--font-body);
    font-size: 1.4rem;
    font-weight: 700;
}


.signup .again {
    font: inherit;
    padding: 0.5rem 1.1rem;
    border: 1px solid rgba(244, 234, 216, 0.6);
    border-radius: var(--radius);
    background: transparent;
    color: var(--color-cream);
    cursor: pointer;
}

.signup .again:hover { background: rgba(244, 234, 216, 0.12); }
.signup .again:focus-visible { outline: 2px solid var(--color-cream); outline-offset: 3px; }

/* Netlify honeypot */
.hp { position: absolute; left: -9999px; }

/* ---------- Footer ---------- */
.site-footer {
    text-align: center;
    color: rgba(244, 234, 216, 0.8);
    font-size: 0.85rem;
    letter-spacing: 0.05em;
    padding: 0 1.25rem 2.5rem;
}

.site-footer p { margin: 0; }
.site-footer .legal-links { margin-top: 0.3rem; }
.site-footer a { color: inherit; text-underline-offset: 3px; }
.site-footer a:hover { color: var(--color-accent); }
.site-footer span { color: var(--color-accent); }

/* ---------- Small screens ---------- */
@media (max-width: 480px) {
    .hero { padding: 3rem 1rem 2.5rem; }
    .event-card { padding: 1.75rem 1.25rem 0; }
    .signup { margin: 0 -1.25rem; padding: 1.75rem 1.25rem 2rem; }
    .signup button { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
    .signup button { transition: none; }
}
