:root {
    font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}

body {
    margin: 0;
    line-height: 1.5;
}

.container {
    max-width: 960px;
    margin: 0 auto;
    padding: 16px;
}

.nav {
    border-bottom: 1px solid #ddd;
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.brand {
    font-weight: 700;
    text-decoration: none;
    color: #111;
}

.links a {
    margin-left: 12px;
    text-decoration: none;
    color: #111;
}

.links a:hover {
    text-decoration: underline;
}

.card {
    border: 1px solid #ddd;
    border-radius: 12px;
    padding: 16px;
    margin-top: 16px;
}

.footer {
    margin-top: 48px;
    color: #666;
}

.muted {
    color: #666;
}

.map-placeholder {
    border: 1px dashed #bbb;
    border-radius: 12px;
    height: 220px;
    display: grid;
    place-items: center;
    margin-top: 12px;
    color: #666;
}

.loc-item {
    cursor: pointer;
    padding: 8px;
    border-radius: 10px;
}

.loc-item:hover {
    background: #f5f5f5;
}

.grid {
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.card-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
}

.card-head a {
    text-decoration: none;
}

.card-head a:hover {
    text-decoration: underline;
}

/* Map needs an explicit height */
.map {
    height: 420px;
    border-radius: 12px;
    overflow: hidden;
}

/* Kleine Abstände in Listen */
.list li {
    margin: 10px 0;
}

.news-body {
    margin-top: 6px;
}

/* Pico nav: immer eine Zeile; linke Seite darf horizontal scrollen */
.topnav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: nowrap;
}

.topnav-links {
    display: flex;
    gap: 0.25rem;
    flex-wrap: nowrap;
    flex: 1 1 auto;
    min-width: 0;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
}

.topnav-links li {
    flex: 0 0 auto;
}

.topnav-links a {
    white-space: nowrap;
}

.topnav-actions {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    flex-wrap: nowrap;
    flex: 0 0 auto;
    margin-left: auto;
    justify-content: flex-end;
}

.account-menu summary {
    white-space: nowrap;
}

.account-trigger {
    padding: 0.2rem 0.25rem;
    min-width: 2.2rem;
}

.account-trigger::after {
    display: none;
}

.account-avatar {
    width: 2rem;
    height: 2rem;
    border-radius: 999px;
    display: grid;
    place-items: center;
    object-fit: cover;
    border: 1px solid #cfcfcf;
    background: #f2f2f2;
    color: #2b2b2b;
    font-size: 0.75rem;
    font-weight: 700;
    line-height: 1;
}

.account-avatar-icon svg {
    width: 1rem;
    height: 1rem;
    fill: currentColor;
}

.account-menu ul {
    min-width: 16rem;
}

.account-menu {
    position: relative;
}

.account-menu > summary+ul {
    left: auto;
    right: 0;
    inset-inline-start: auto;
    inset-inline-end: 0;
}

.account-menu-section {
    padding: 0.25rem 0.75rem 0.1rem 0.75rem;
    line-height: 1;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: #666;
}

.account-menu-user {
    padding: 0.35rem 0.75rem 0.15rem;
    color: #666;
    max-width: 16rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.account-menu-separator {
    padding: 0;
}

.account-menu-separator hr {
    margin: 0.25rem 0;
}

.account-menu-link {
    display: block;
}

.account-menu-link-active {
    font-weight: 700;
}

@media (max-width: 480px) {
    .topnav {
        justify-content: space-between;
    }
}

.auth-card {
    max-width: 520px;
    margin: 0 auto;
}

[role="alert"] {
    margin-bottom: 1rem;
}

.table-shell {
    overflow: hidden;
}

.table-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.offers-table {
    min-width: 920px;
}

.member-offers-table {
    min-width: 980px;
}

.archive-offers-table {
    min-width: 860px;
}

.offers-actions-cell {
    width: 1%;
    white-space: nowrap;
}

.offers-actions {
    min-width: 150px;
    display: grid;
    gap: 0.5rem;
}

.offers-actions form {
    margin: 0;
}

.offers-actions button {
    width: 100%;
    margin: 0;
}

@media (max-width: 1100px) {
    .offers-table {
        min-width: 820px;
    }

    .offers-actions {
        min-width: 136px;
    }

    .offers-table th:nth-child(1),
    .offers-table td:nth-child(1) {
        display: none;
    }

    .member-offers-table {
        min-width: 860px;
    }

    .archive-offers-table {
        min-width: 760px;
    }

    .archive-offers-table th:nth-child(1),
    .archive-offers-table td:nth-child(1) {
        display: none;
    }
}

@media (max-width: 860px) {
    .offers-table {
        min-width: 700px;
    }

    .offers-table th:nth-child(5),
    .offers-table td:nth-child(5) {
        display: none;
    }

    .member-offers-table {
        min-width: 740px;
    }

    .member-offers-table th:nth-child(4),
    .member-offers-table td:nth-child(4) {
        display: none;
    }

    .archive-offers-table {
        min-width: 660px;
    }

    .archive-offers-table th:nth-child(5),
    .archive-offers-table td:nth-child(5) {
        display: none;
    }
}

.people-grid,
.admin-people-grid,
.stories-list {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.person-card,
.story-card,
.person-profile,
.person-inline-card {
    border: 1px solid #ddd;
    border-radius: 12px;
    padding: 1rem;
}

.person-photo,
.story-photo {
    width: 100%;
    max-height: 220px;
    object-fit: cover;
    border-radius: 10px;
}

.person-photo-large {
    width: 100%;
    max-width: 460px;
    border-radius: 12px;
}

.badge-chip {
    display: inline-block;
    margin: 0 0.35rem 0.35rem 0;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    border: 1px solid #bbb;
    font-size: 0.8rem;
}

.inline-form {
    display: inline-block;
    margin-right: 0.4rem;
}

.badge-form {
    margin-top: 0.75rem;
}
