:root {
    color-scheme: light dark;
    font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
    --accent: #2b7a78;
    --border: rgba(127, 127, 127, 0.3);
}

* { box-sizing: border-box; }
body { margin: 0; line-height: 1.5; }

/* ---- Hero ---- */
.hero {
    background: linear-gradient(160deg, rgba(43, 122, 120, 0.18), rgba(43, 122, 120, 0.02));
    border-bottom: 1px solid var(--border);
}
.topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 960px;
    margin: 0 auto;
    padding: 1rem 1.25rem;
}
.brand { font-weight: 700; letter-spacing: 0.02em; }
.topbar-link { color: inherit; text-decoration: none; opacity: 0.85; }
.topbar-link:hover { opacity: 1; }
.hero-inner { max-width: 960px; margin: 0 auto; padding: 3rem 1.25rem 4rem; }
.hero h1 { font-size: 2.4rem; line-height: 1.15; margin: 0 0 1rem; max-width: 18ch; }
.accent { color: var(--accent); }
.lede { font-size: 1.15rem; max-width: 60ch; opacity: 0.9; }
.cta {
    display: inline-block;
    margin-top: 1.5rem;
    padding: 0.7rem 1.3rem;
    background: var(--accent);
    color: #fff;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
}
.cta:hover { filter: brightness(1.07); }

/* ---- Main / sections ---- */
main { max-width: 960px; margin: 0 auto; padding: 0 1.25rem; }
section { padding: 3rem 0; border-bottom: 1px solid var(--border); }
section h2 { font-size: 1.6rem; margin: 0 0 0.5rem; }
.section-lede { max-width: 65ch; opacity: 0.9; margin-top: 0; }

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
    margin-top: 1.5rem;
}
.card {
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1.1rem 1.2rem;
    background: rgba(127, 127, 127, 0.05);
}
.card h3 { margin: 0 0 0.4rem; color: var(--accent); }
.card p { margin: 0; opacity: 0.9; }

/* ---- Signup form ---- */
.signup form { max-width: 560px; margin-top: 1.5rem; }
label { display: block; margin: 0.9rem 0; font-weight: 600; }
label input, label textarea {
    display: block;
    width: 100%;
    margin-top: 0.35rem;
    padding: 0.6rem;
    font: inherit;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: transparent;
    color: inherit;
}
.row { display: flex; gap: 1rem; }
.row label { flex: 1; }
button[type=submit] {
    margin-top: 0.5rem;
    padding: 0.65rem 1.4rem;
    font: inherit;
    font-weight: 600;
    color: #fff;
    background: var(--accent);
    border: none;
    border-radius: 6px;
    cursor: pointer;
}
button[type=submit]:hover { filter: brightness(1.07); }
button[type=submit]:disabled { opacity: 0.6; cursor: progress; }

#signup-status { min-height: 1.2em; margin-top: 0.75rem; font-weight: 600; }
#signup-status.success { color: var(--accent); }
#signup-status.error { color: #c0392b; }

/* ---- Footer ---- */
.site-footer {
    max-width: 960px;
    margin: 0 auto;
    padding: 2rem 1.25rem 3rem;
    opacity: 0.7;
    font-size: 0.9rem;
}

@media (max-width: 560px) {
    .hero h1 { font-size: 1.9rem; }
    .row { flex-direction: column; gap: 0; }
}

/* ---- Admin shell (reuses the variables above) ---- */
.admin-body { max-width: 960px; margin: 2rem auto; padding: 0 1.25rem; }
.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border);
    padding-bottom: 0.75rem;
    margin-bottom: 1rem;
}
.page-header h1 { margin: 0; font-size: 1.1rem; font-weight: 600; }
button.secondary {
    background: transparent;
    color: inherit;
    border: 1px solid rgba(127, 127, 127, 0.5);
    padding: 0.4rem 0.7rem;
    border-radius: 4px;
    cursor: pointer;
}
.stats { display: flex; gap: 2rem; margin: 1rem 0; }
.stat { font-size: 0.9rem; opacity: 0.85; }
.stat strong { display: block; font-size: 1.6rem; opacity: 1; }
.admin-section { margin-top: 2.5rem; }
table { border-collapse: collapse; width: 100%; font-size: 0.85rem; }
th, td {
    text-align: left;
    padding: 0.4rem 0.6rem;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
}
th { font-weight: 600; }
td.mono { font-family: ui-monospace, monospace; word-break: break-all; }
#status { font-style: italic; }
.empty { opacity: 0.7; font-style: italic; }
