/* Structure only: grids, spacing, positions. Colours and fonts come from theme.css. */

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--bg); color: var(--text); font: var(--size-body)/1.55 var(--font-body); }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--bg); }
a { color: inherit; }
h1, h2, h3 { text-wrap: balance; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 20; background: var(--surface); padding: 8px 12px; }

.container, .header-inner, .footer-inner {
  max-width: 1180px; margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
.container.narrow { max-width: 760px; }

/* Shared type roles */
.display { font-family: var(--font-display); font-weight: var(--display-weight); text-transform: var(--display-transform); letter-spacing: var(--display-tracking); line-height: 1.05; margin: 0; }
.eyebrow, .label, .filter-label { font-size: var(--size-label); text-transform: var(--label-transform); letter-spacing: var(--label-tracking); color: var(--muted); }
.lead { color: var(--muted); max-width: 62ch; margin: 14px 0 0; }

/* Pills (buttons and links) */
.pill { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 8px 16px; border: 1px solid var(--line); border-radius: var(--radius-pill); background: var(--surface); color: var(--text); font: 600 13.5px/1 var(--font-body); text-transform: var(--label-transform); letter-spacing: var(--label-tracking); text-decoration: none; cursor: pointer; white-space: nowrap; }
.pill-dark { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.pill-lg { padding: 14px 24px; }
.pill-opt { padding: 5px 11px; border: 1px solid var(--text); border-radius: var(--radius-pill); background: transparent; color: var(--text); font: inherit; font-size: var(--size-small); cursor: pointer; }
.pill-opt[aria-pressed="true"] { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.pills { display: flex; flex-wrap: wrap; gap: 6px; }
.link-btn { background: none; border: 0; padding: 0; font: inherit; font-size: var(--size-small); color: var(--muted); text-decoration: underline; cursor: pointer; }

/* Header */
.site-header { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 5; background: var(--bg); border-bottom: 1px solid var(--line); }
.header-inner { max-width: 1440px; display: grid; grid-template-columns: minmax(150px, 1fr) minmax(0, 800px) minmax(150px, 1fr); align-items: center; gap: 20px; min-height: 68px; padding-block: 10px; }
.header-inner .search { max-width: none; padding-block: 8px; }
.brand { font: var(--display-weight) 15px/1.1 var(--font-display); text-transform: var(--display-transform); text-decoration: none; white-space: nowrap; }
.header-tools { display: flex; justify-content: flex-end; align-items: center; gap: 4px; }
/* "Propose a service" in the header: a small pill; on narrow screens only the plus. */
.header-propose { display: inline-flex; align-items: center; gap: 6px; height: 38px; padding: 0 14px 0 10px; margin-right: 4px; border-radius: var(--radius-pill); background: var(--accent); color: var(--on-accent); font-size: 13.5px; font-weight: 600; text-decoration: none; white-space: nowrap; }
.header-propose svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; }
.header-propose:hover { opacity: 0.88; }
@media (max-width: 1180px) { .header-propose span { display: none; } .header-propose { width: 38px; padding: 0; justify-content: center; } }
/* Home: propose a service */
.propose-card { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 36px; align-items: center; padding: 32px; border-radius: var(--radius-card); background: var(--surface-alt); }
.propose-text { display: grid; gap: 14px; justify-items: start; }
.propose-points { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; font-size: 15px; }
.propose-points li { display: flex; gap: 10px; align-items: baseline; }
.propose-points li::before { content: "✓"; font-weight: 700; }
.propose-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
.propose-photo { aspect-ratio: 4 / 3; border-radius: var(--radius-media); }
/* Phones: two buttons under the carousel; proposing stays one tap away via the + in the header. */
@media (max-width: 600px) { .home-propose { display: none; } }
@media (max-width: 760px) { .propose-card { grid-template-columns: 1fr; padding: 20px; gap: 20px; } .propose-photo { order: -1; aspect-ratio: 16 / 9; } }
.icon-btn { display: grid; place-items: center; width: 38px; height: 38px; border: 0; border-radius: 50%; background: transparent; color: var(--text); cursor: pointer; }
.icon-btn:hover { background: var(--surface-alt); }
.lang-btn { width: auto; min-width: 38px; padding: 0 10px; border: 1px solid var(--line); border-radius: var(--radius-pill); font: 700 12px/1 var(--font-body); letter-spacing: 0.08em; }
.icon-btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
/* Show the icon of the mode you'd switch to. */
.i-sun { display: none; }
:root[data-mode="dark"] .i-sun { display: block; }
:root[data-mode="dark"] .i-moon { display: none; }
.menu-wrap { position: relative; }
.main-menu { position: absolute; right: 0; top: calc(100% + 8px); min-width: 220px; padding: 8px; display: grid; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-card); box-shadow: var(--shadow-menu); z-index: 6; }
.main-menu a { padding: 10px 12px; border-radius: 10px; text-decoration: none; font-size: 14px; }
.main-menu a:hover, .main-menu a[aria-current="page"] { background: var(--surface-alt); }

/* Search with filter menu */
.search { position: relative; display: flex; align-items: center; gap: 8px; max-width: 520px; width: 100%; justify-self: center; padding: 6px 6px 6px 16px; border: 1px solid var(--line); border-radius: var(--radius-pill); background: var(--surface-alt); }
.search-icon, .filter-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; flex: none; }
.search-icon { color: var(--muted); }
.search input { flex: 1; min-width: 0; border: 0; background: transparent; color: var(--text); font: inherit; padding: 6px 0; outline: none; }
.search input::-webkit-search-cancel-button { display: none; }
.filter-btn { position: relative; display: grid; place-items: center; width: 34px; height: 34px; border: 0; border-radius: 50%; background: var(--surface); color: var(--text); cursor: pointer; flex: none; }
.filter-count { position: absolute; top: -3px; right: -3px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: var(--radius-pill); background: var(--accent); color: var(--on-accent); font-size: 10px; line-height: 16px; text-align: center; }
/* Search suggestions: same place as the filter menu, as wide as the search bar. */
.suggest { position: absolute; top: calc(100% + 8px); left: 0; right: 0; z-index: 6; max-height: min(64vh, 520px); overflow-y: auto; padding: 8px; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow-menu); }
.suggest[hidden] { display: none; }
.suggest-head { padding: 10px 10px 4px; font-size: 12px; font-weight: 600; color: var(--muted); }
.suggest-group { display: grid; }
.suggest-group.chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 4px 6px 8px; }
.suggest-opt { display: grid; gap: 2px; width: 100%; padding: 9px 10px; border: 0; border-radius: 12px; background: none; color: var(--text); font: inherit; text-align: left; cursor: pointer; }
.suggest-opt:hover, .suggest-opt.is-active { background: var(--surface-alt); }
.suggest-label { font-size: 14.5px; font-weight: 500; }
.suggest-hint { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chips .suggest-opt { width: auto; padding: 7px 13px; border: 1px solid var(--line); border-radius: var(--radius-pill); }
.chips .suggest-opt:hover, .chips .suggest-opt.is-active { border-color: var(--text); background: var(--surface-alt); }
.opt-all .suggest-label { font-weight: 600; }
.filter-menu { position: absolute; top: calc(100% + 8px); left: 50%; translate: -50% 0; width: min(420px, calc(100vw - 32px)); max-height: min(70vh, 620px); overflow-y: auto; padding: 18px; display: grid; gap: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-card); box-shadow: var(--shadow-menu); }
.filter-group { display: grid; gap: 8px; }
.filter-actions { position: sticky; bottom: -18px; display: flex; justify-content: space-between; gap: 8px; padding: 12px 0 0; background: var(--surface); }

/* Views */
.view { padding-block: 40px 64px; }
.view[hidden] { display: none !important; }
.page-title { font-size: var(--size-page); }

/* Home */
/* The whole home header (title, carousel, buttons) fits in the first screen:
   spacing and title shrink with the window height; carousel.js scales the cards. */
.view-home { padding-top: clamp(14px, 3.2vh, 48px); }
.home-hero { text-align: center; display: grid; justify-items: center; gap: 14px; padding-inline: 16px; }
.home-hero { gap: clamp(6px, 1.4vh, 14px); }
.home-hero .display { font-size: min(var(--size-hero), 7.4vh); }
/* "in one place." in a light serif italic against the bold sans: same line height, a bit larger
   because the serif runs smaller, and without the tight sans tracking. */
.home-hero .display em { font-family: var(--font-accent); font-style: italic; font-weight: 400; font-size: 1.14em; letter-spacing: -0.005em; line-height: 0.9; }
@media (min-width: 900px) { .home-hero .display br { display: none; } .home-hero .display { font-size: min(var(--size-hero), 7.4vh, 4.6vw); } }
.home-hero .lead { margin: 0; text-align: center; }
.tagline { margin: 0; color: var(--muted); font-size: clamp(15px, 1.8vw, 18px); letter-spacing: 0.01em; }
.home-actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; padding-inline: 16px; }
.causes-block { margin-top: 72px; display: grid; gap: 14px; }
.cause-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 28px 20px; grid-auto-flow: row dense; }
.cause-tile { display: flex; flex-direction: column; gap: 10px; min-width: 0; text-align: left; border: 0; padding: 0; background: none; color: inherit; font: inherit; cursor: pointer; }
.cause-text { display: grid; gap: 4px; align-content: start; }
.cause-tile .media { width: 100%; }
.cause-tile:hover .media img { scale: 1.03; }
.cause-tile .media img { transition: scale 0.4s ease; }
.cause-tile strong { font: var(--display-weight) var(--size-card)/1.15 var(--font-display); }
.s-3 { grid-column: span 3; } .s-4 { grid-column: span 4; } .s-6 { grid-column: span 6; } .s-8 { grid-column: span 8; } .s-12 { grid-column: span 12; }
.s-6 .media { aspect-ratio: 5 / 2; }
.s-4 .media { aspect-ratio: 16 / 10; }
.s-3 .media { aspect-ratio: 4 / 3; }
.s-3 strong { font-size: 17px; }
.s-3 p { font-size: 13px; }
.s-6 strong { font-size: 24px; }
.cause-tile.wide { flex-direction: row; align-items: flex-start; gap: 22px; }
/* 3:2 over ~46% of eight columns is about as tall as a neighbouring 16:10 four-column photo. */
.cause-tile.wide .media { flex: 0 0 46%; aspect-ratio: 3 / 2; }
.cause-tile.wide .cause-text { padding-top: 6px; }
.cause-tile.wide strong { font-size: 26px; }
@media (max-width: 960px) {
  .cause-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .s-3, .s-4 { grid-column: span 3; } .s-6, .s-8, .s-12 { grid-column: span 6; }
}
@media (max-width: 600px) {
  .cause-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 12px; }
  .s-3, .s-4 { grid-column: span 1; } .s-6, .s-8, .s-12 { grid-column: span 2; }
  .cause-tile.wide { flex-direction: column; align-items: stretch; gap: 10px; }
  .cause-tile.wide .media { flex: none; }
  .s-3 p, .s-4 p { display: none; }
}
.stories { margin-top: 0; padding-top: 48px; padding-bottom: 72px; border-top: 1px solid var(--line); }
.stories[hidden] { display: none; }
.post-picks { margin: 8px 0 4px; }
.block-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
/* Home section titles: same display face as the hero, sized between the hero and card titles. */
.block-title { margin: 0; display: flex; align-items: center; gap: 12px; font: var(--display-weight) clamp(26px, 3.4vw, 38px)/1.05 var(--font-display); text-transform: var(--display-transform); letter-spacing: var(--display-tracking); color: var(--text); }
.block-title.region::before { content: ""; flex: none; width: 12px; height: 12px; border-radius: 50%; background: var(--region); }
.block-head .link-btn { font-size: 14px; white-space: nowrap; }
@media (max-width: 600px) { .block-title { font-size: 22px; gap: 10px; } .block-title.region::before { width: 10px; height: 10px; } .block-lead { font-size: 15px; } }
.block-lead { margin: -2px 0 8px; color: var(--muted); max-width: 62ch; font-size: 16px; line-height: 1.5; }
#culture-groups { margin-top: 10px; }
.cause-tile p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.45; }
.cause-tile span { color: var(--text); font-size: var(--size-small); font-weight: 600; font-variant-numeric: tabular-nums; }

/* Connected carousel (home header): active card, notched neighbours, progress tabs */
.cc { position: relative; isolation: isolate; width: 100%; max-width: 1240px; margin: clamp(8px, 2.6vh, 36px) auto clamp(6px, 1.8vh, 28px); display: flex; flex-direction: column; align-items: center; overflow: hidden; padding-block: 16px; outline: none; user-select: none; }
.cc:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.cc-panel { position: relative; width: 100%; }
.cc-card { position: absolute; left: 50%; top: 50%; border-radius: var(--radius-carousel); background: var(--surface); box-shadow: var(--shadow-raised); will-change: transform;
  transition: transform 0.6s var(--ease-spring), width 0.6s var(--ease-spring), height 0.6s var(--ease-spring), opacity 0.4s ease; }
.cc-card:not(.is-active) { cursor: pointer; }
.cc-static .cc-card, .cc-static .cc-content, .cc-static .cc-thumb { transition: none; }
.cc-panel { cursor: grab; }
.cc-dragging .cc-panel { cursor: grabbing; }
.cc-dragging .cc-card { transition: width 0.6s var(--ease-spring), height 0.6s var(--ease-spring), opacity 0.4s ease; }
.cc-notch { position: absolute; top: 0; bottom: 0; margin: auto 0; display: none; color: var(--surface); pointer-events: none; z-index: 100; }
.cc-notch svg { display: block; width: 100%; height: 100%; fill: currentColor; overflow: visible; }
.cc-notch-right { left: calc(100% - 1px); }
.cc-notch-left { right: calc(100% - 1px); }
.show-big-right .cc-big.cc-notch-right, .show-big-left .cc-big.cc-notch-left,
.show-small-right .cc-small.cc-notch-right, .show-small-left .cc-small.cc-notch-left { display: block; }
.cc-clip { position: relative; width: 100%; height: 100%; overflow: hidden; border-radius: inherit; }
.cc-thumb { position: absolute; inset: 0; padding: 8px; transition: opacity 0.22s ease-out; }
.is-active .cc-thumb { opacity: 0; pointer-events: none; }
.cc-thumb-img { position: relative; width: 100%; height: 100%; overflow: hidden; border-radius: calc(var(--radius-carousel) - 8px); background: var(--placeholder); }
.cc img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.cc-stage { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); }
.cc-content { width: 100%; height: 100%; display: flex; gap: 24px; padding: 28px; opacity: 0; transform: translateX(60px); pointer-events: none; transition: opacity 0.4s ease, transform 0.6s var(--ease-spring); }
.is-left .cc-content { transform: translateX(-60px); }
.is-active .cc-content { opacity: 1; transform: none; pointer-events: auto; }
.cc-text { flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: space-between; gap: 14px; padding-block: 4px; text-align: left; }
.cc-stat { margin: 0; font: var(--display-weight) clamp(22px, 3.2vw, 36px)/1.08 var(--font-display); text-transform: var(--display-transform); letter-spacing: var(--display-tracking); }
.cc-head { display: grid; gap: 10px; }
.cc-desc { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.cc-feature { display: grid; gap: 4px; margin-block: auto; }
.cc-label { font-size: var(--size-label); text-transform: var(--label-transform); letter-spacing: var(--label-tracking); color: var(--muted); }
/* Headline link stretched over the whole active card; the featured offer sits above it. */
.cc-open { color: inherit; text-decoration: none; }
.cc-open::after { content: ""; position: absolute; inset: 0; z-index: 1; border-radius: inherit; }
.cc-card.is-active { cursor: pointer; }
.cc-card.is-active:hover .cc-photo img { scale: 1.03; }
.cc-photo img { transition: scale 0.4s ease; }
.cc-open:focus-visible { outline: none; }
.cc-open:focus-visible::after { outline: 2px solid var(--text); outline-offset: -4px; border-radius: calc(var(--radius-carousel) - 4px); }
.cc-quote, .cc-people { position: relative; z-index: 2; }
.cc-quote { font: var(--display-weight) clamp(15px, 1.6vw, 19px)/1.35 var(--font-display); color: var(--text); text-decoration: none; }
.cc-quote:hover { text-decoration: underline; }
.cc-people { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; max-width: 100%; }
.cc-tag { max-width: 100%; padding: 4px 10px; border-radius: 4px; background: var(--surface-alt); font-size: 12px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cc-tag-muted { font-weight: 500; color: var(--muted); }
.cc-join { display: flex; height: 6px; margin: -1px 0; padding: 0 12px; color: var(--surface-alt); position: relative; z-index: 1; }
.cc-join svg { display: block; fill: currentColor; overflow: visible; }
.cc-photo { position: relative; flex: 0 0 clamp(180px, 44%, 330px); overflow: hidden; border-radius: calc(var(--radius-carousel) - 8px); background: var(--placeholder); }
.cc-tabs { display: flex; align-items: center; gap: 6px; margin-top: clamp(10px, 2vh, 20px); }
/* Smaller cards on short windows (carousel.js sets cc-compact / cc-tight). */
.cc-compact .cc-content { padding: 20px; gap: 18px; }
.cc-compact .cc-text { gap: 10px; }
.cc-compact .cc-stat { font-size: clamp(20px, 2.4vw, 28px); }
.cc-compact .cc-desc { -webkit-line-clamp: 2; font-size: 14px; }
.cc-tight .cc-content { padding: 16px; gap: 14px; }
.cc-tight .cc-tag-muted { display: none; }
.cc-tight .cc-desc { -webkit-line-clamp: 2; font-size: 13.5px; }
@media (max-width: 767px) {
  /* Short phones: no photo strip in the card, the text gets the room. */
  .cc-tight .cc-photo { display: none; }
  .cc-tiny .cc-desc { display: none; }
  .cc-compact .cc-photo { max-height: 140px; }
  .home-hero .display { font-size: min(clamp(28px, 8.6vw, 38px), 5.8vh); }
  .home-hero .display em { font-size: 1.08em; }
}
.cc-tab { width: 8px; height: 8px; padding: 0; border: 0; border-radius: 3px; overflow: hidden; background: var(--line); cursor: pointer; transition: width 0.3s ease-out; }
.cc-tab[aria-selected="true"] { width: 80px; }
.cc-fill { display: block; height: 100%; border-radius: 3px; background: var(--accent); transform: scaleX(0); transform-origin: 0 50%; }
@media (max-width: 767px) {
  .cc-content { flex-direction: column; gap: 12px; padding: 16px; }
  .cc-desc { font-size: 13.5px; -webkit-line-clamp: 3; }
  .cc-text { gap: 10px; }
  .cc-text { text-align: center; align-items: center; flex: 0 0 auto; }
  .cc-people { align-items: center; }
  .cc-photo { flex: 1 1 auto; max-height: 220px; width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .cc-card, .cc-content, .cc-thumb, .cc-tab { transition: none; }
}

/* Bento gallery (home, culture): tall and wide photo tiles, full view with a draggable dock */
.bento-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-rows: 104px; grid-auto-flow: row dense; gap: 14px; }
.bento-tile { position: relative; min-width: 0; border-radius: var(--radius-card); overflow: hidden; background: var(--placeholder); transition: scale 0.25s var(--ease-spring); }
.bento-tall { grid-row: span 3; }
.bento-wide { grid-column: span 2; grid-row: span 2; }
.bento-tile:hover { scale: 1.02; }
.bento-tile.is-dragging { z-index: 2; scale: 1.04; cursor: grabbing; box-shadow: var(--shadow-menu); transition: none; }
.bento-enter { opacity: 0; translate: 0 50px; scale: 0.9; }
.bento-in .bento-enter { animation: bento-rise 0.6s var(--ease-spring) calc(var(--i) * 0.07s) forwards; }
@keyframes bento-rise { to { opacity: 1; translate: 0 0; scale: 1; } }
.bento-hit { position: absolute; inset: 0; width: 100%; padding: 0; border: 0; background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; }
@media (pointer: fine) { .bento-hit { cursor: grab; } }
.bento-hit img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; user-select: none; -webkit-user-drag: none; }
.bento-ph { position: absolute; inset: 0; display: grid; place-items: center; color: var(--placeholder-text); }
.bento-caption { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: flex-end; gap: 2px; padding: 14px 16px; color: #fff; background: linear-gradient(to top, rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.4) 45%, transparent); opacity: 0; transition: opacity 0.2s ease; }
.bento-tile:hover .bento-caption, .bento-hit:focus-visible .bento-caption { opacity: 1; }
@media (hover: none) { .bento-caption { opacity: 1; } }
.bento-caption strong { font: var(--display-weight) 16px/1.2 var(--font-display); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.bento-caption span { font-size: 12.5px; line-height: 1.4; color: rgba(255, 255, 255, 0.78); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.bento-hint { margin: -2px 0 4px; font-size: var(--size-small); color: var(--muted); }

.bento-locked { overflow: hidden; }
.bento-locked .ai-launch { display: none; }
.bento-modal { position: fixed; inset: 0; z-index: 40; }
.bento-backdrop { position: absolute; inset: 0; background: color-mix(in srgb, var(--bg) 72%, transparent); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); animation: bento-fade 0.2s ease; }
.bento-stage { position: absolute; inset: 0 0 92px; display: grid; place-items: center; padding: 64px 16px 0; pointer-events: none; }
.bento-stage > * { pointer-events: auto; }
/* Photo on the left, the event's facts on the right; stacked and scrollable on phones. */
.bento-sheet { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); width: min(1060px, 94vw); height: min(600px, 100%); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; background: var(--surface); box-shadow: var(--shadow-menu); }
.bento-sheet.is-swapping { animation: bento-swap 0.45s var(--ease-spring); }
@keyframes bento-swap { from { translate: 0 20px; scale: 0.97; } }
@keyframes bento-fade { from { opacity: 0; } }
.bento-figure { position: relative; margin: 0; min-height: 0; background: var(--placeholder); }
.bento-figure img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.bento-info { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; padding: 26px 28px; overflow-y: auto; min-height: 0; }
.bento-kicker { font-size: var(--size-label); text-transform: var(--label-transform); letter-spacing: var(--label-tracking); color: var(--muted); }
.bento-title { margin: 0; font: var(--display-weight) clamp(20px, 2.4vw, 28px)/1.15 var(--font-display); }
.bento-orig { margin: -4px 0 0; font-size: var(--size-small); color: var(--muted); font-style: italic; }
.bento-summary { margin: 0; font-size: 14.5px; line-height: 1.55; }
.bento-facts { display: grid; grid-template-columns: max-content 1fr; gap: 8px 16px; width: 100%; margin: 6px 0 4px; padding-top: 14px; border-top: 1px solid var(--line); font-size: 13.5px; }
.bento-facts dt { color: var(--muted); }
.bento-facts dd { margin: 0; overflow-wrap: anywhere; white-space: pre-line; }
.bento-note { margin: 0; font-size: 12px; color: var(--muted); }
.bento-close { position: absolute; top: 14px; right: max(14px, env(safe-area-inset-right, 0px)); display: grid; place-items: center; width: 40px; height: 40px; border: 1px solid var(--line); border-radius: 50%; background: var(--surface); color: var(--text); cursor: pointer; transition: scale 0.2s var(--ease-spring); }
.bento-close:hover { scale: 1.1; }
.bento-close:active { scale: 0.9; }
.bento-close svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.bento-dock { position: absolute; left: 50%; bottom: max(16px, env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); touch-action: none; cursor: grab; max-width: calc(100vw - 24px); }
.bento-dock.is-dragging { cursor: grabbing; }
.bento-dock-inner { display: flex; align-items: center; padding: 10px 16px 10px 24px; border: 1px solid var(--line); border-radius: 16px; background: color-mix(in srgb, var(--surface) 70%, transparent); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); box-shadow: var(--shadow-menu); overflow-x: auto; scrollbar-width: none; }
.bento-thumb { position: relative; flex: none; width: 42px; height: 42px; margin-left: -8px; padding: 0; border: 0; border-radius: 10px; overflow: hidden; background: var(--placeholder); cursor: pointer; rotate: var(--r); transition: rotate 0.3s var(--ease-spring), scale 0.3s var(--ease-spring), translate 0.3s var(--ease-spring), box-shadow 0.2s; }
.bento-thumb img { width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.bento-thumb[aria-selected="true"] { rotate: 0deg; scale: 1.2; translate: 0 -8px; box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--accent); }
.bento-thumb:hover { rotate: 0deg; scale: 1.3; translate: 0 -10px; z-index: 31 !important; }
@media (max-width: 960px) { .bento-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); grid-auto-rows: 92px; } }
@media (max-width: 600px) {
  .bento-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: 80px; gap: 10px; }
  .bento-caption { padding: 10px 12px; }
  .bento-caption strong { font-size: 14px; }
  .bento-stage { padding: 60px 10px 0; bottom: 84px; }
  .bento-sheet { grid-template-columns: 1fr; grid-template-rows: auto; height: auto; max-height: 100%; overflow-y: auto; }
  .bento-figure { aspect-ratio: 16 / 10; }
  .bento-info { overflow: visible; padding: 18px 18px 22px; }
  .bento-facts { grid-template-columns: 1fr; gap: 2px; }
  .bento-facts dd { margin-bottom: 8px; }
  .bento-thumb { width: 36px; height: 36px; }
}
@media (prefers-reduced-motion: reduce) {
  .bento-tile, .bento-thumb, .bento-close { transition: none; }
  .bento-enter { opacity: 1; translate: none; scale: none; }
}

/* Offer detail page */
.job { max-width: 980px; display: grid; gap: 28px; }
.job-back { justify-self: start; text-decoration: none; }
.job-top { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 32px; align-items: start; }
.job-top.no-photo { grid-template-columns: 1fr; }
.job-photo { order: 2; margin: 0; aspect-ratio: 4 / 3; overflow: hidden; border-radius: var(--radius-media); background: var(--placeholder); box-shadow: var(--shadow-card); }
.job-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
@media (max-width: 760px) {
  .job-top { grid-template-columns: 1fr; gap: 18px; }
  .job-photo { order: 0; aspect-ratio: 16 / 9; }
}
.job-head { display: grid; gap: 12px; justify-items: start; }
.job-head .page-title { margin: 0; }
.job-head .lead { margin: 4px 0 0; font-size: 17px; }
.job-badges { display: flex; flex-wrap: wrap; gap: 6px; }
.pill-tag { padding: 4px 10px; border-radius: var(--radius-pill); background: var(--surface-alt); font-size: 12.5px; font-weight: 600; text-transform: var(--label-transform); letter-spacing: var(--label-tracking); }
.pill-tag.good { background: var(--good-strong); color: var(--on-good); }
.pill-tag.warn { color: var(--warn); border: 1px solid currentColor; background: none; }
.job-orig { margin: -4px 0 0; color: var(--muted); font-style: italic; }
.job-org { margin: 0; font-weight: 600; }
.job-tip { margin: 0; padding: 10px 14px; border-radius: 12px; background: var(--surface-alt); font-size: 14px; }
.job-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
/* Fact boxes flow in two columns like a masonry wall: each box sits right under the one
   above it, so short boxes ("What you get") leave no holes next to tall ones. */
.job-grid { columns: 2; column-gap: 16px; }
.job-grid > .job-sec { break-inside: avoid; margin-bottom: 16px; }
.job-related { display: grid; gap: 16px; margin-top: -12px; }
.job-related:empty { display: none; }
.job-sec { padding: 18px 20px; border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--surface); min-width: 0; }
.job-sec h2 { margin: 0 0 12px; font: var(--display-weight) 19px/1.2 var(--font-display); }
.job-wide { grid-column: 1 / -1; }
.job-dl { display: grid; grid-template-columns: minmax(110px, 38%) 1fr; gap: 9px 14px; margin: 0; font-size: 14px; }
.job-dl dt { color: var(--muted); }
.job-dl dd { margin: 0; overflow-wrap: anywhere; }
.job-p { margin: 0; font-size: 14px; }
.job-p.muted { color: var(--muted); }
.job-days { overflow-x: auto; }
.job-days table { width: 100%; border-collapse: collapse; font-size: 13px; text-align: center; }
.job-days th { font-weight: 600; padding: 6px 4px; }
.job-days tbody th { text-align: left; color: var(--muted); font-weight: 500; white-space: nowrap; padding-right: 10px; }
.job-days td { padding: 6px 4px; border-top: 1px solid var(--line); color: var(--line); }
.job-days td.on { color: var(--good); }
.job-links { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.job-links a { display: grid; gap: 3px; height: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; text-decoration: none; }
.job-links a:hover { border-color: var(--text); }
.job-links strong { font: var(--display-weight) 16px/1.25 var(--font-display); }
.job-links span { font-size: 12.5px; color: var(--muted); }
@media (max-width: 760px) {
  .job-grid { columns: 1; }
  .job-links { grid-template-columns: 1fr; }
}


/* Media box: image, or a neutral placeholder naming the cause */
.media { position: relative; overflow: hidden; border-radius: var(--radius-media); background: var(--placeholder); max-width: 100%; }
.media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.media .ph { position: absolute; inset: 0; display: grid; place-items: center; padding: 12px; text-align: center; color: var(--placeholder-text); font: var(--display-weight) 15px/1.1 var(--font-display); text-transform: var(--display-transform); }
.badge { position: absolute; top: 12px; left: 12px; z-index: 1; padding: 4px 9px; border-radius: var(--radius-pill); background: var(--surface); color: var(--text); font-size: 12px; font-weight: 600; text-transform: var(--label-transform); letter-spacing: var(--label-tracking); }

/* Offers */

/* ---------- Offers page: filters in the page, left-aligned, nothing hidden in a pop-up ---------- */
.easy { display: flex; align-items: center; justify-content: space-between; gap: 16px 24px; flex-wrap: wrap; margin-top: 24px; padding: 18px 20px; border-radius: var(--radius-card); background: var(--surface-alt); }
.easy-text { display: grid; gap: 4px; max-width: 62ch; }
.easy-actions { display: flex; align-items: center; gap: 8px 16px; flex-wrap: wrap; }
/* Help right now (#now) */
.now { display: grid; gap: 10px; }
.now-jump { margin: 10px 0 6px; }
.now-jump .chip { text-decoration: none; }
.now-group { display: grid; gap: 16px; margin-top: 40px; scroll-margin-top: 96px; }
.now-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.now-card { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--radius-card); overflow: hidden; background: var(--surface); }
.now-photo { aspect-ratio: 16 / 9; border-radius: 0; }
/* How fast you can start: a badge on the photo */
.access { display: inline-flex; align-items: center; gap: 5px; padding: 4px 10px; border-radius: var(--radius-pill); font-size: 12.5px; font-weight: 600; white-space: nowrap; background: var(--surface); color: var(--text); }
.now-photo .access { position: absolute; top: 12px; left: 12px; z-index: 1; box-shadow: 0 1px 6px rgba(0, 0, 0, 0.15); }
/* All four start levels look the same; the icon and the words tell them apart. */
.access-icon { width: 14px; height: 14px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.access-legend { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; margin-top: 6px; padding: 12px 14px; border-radius: var(--radius-card); background: var(--surface-alt); font-size: 13.5px; }
.access-legend .access { border: 1px solid var(--line); }
.access-legend-title { width: 100%; font-weight: 600; }
.access-legend-text { color: var(--muted); margin-right: 10px; }
/* Home: Help right now row */
.now-mini { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.now-mini-card { display: grid; gap: 6px; align-content: start; text-decoration: none; color: inherit; }
.now-mini-card .now-photo { aspect-ratio: 4 / 3; border-radius: var(--radius-media); }
.now-mini-card .now-photo img { transition: scale 0.4s ease; }
.now-mini-card:hover .now-photo img { scale: 1.03; }
.now-mini-card strong { font: var(--display-weight) 16.5px/1.25 var(--font-display); letter-spacing: -0.01em; }
.now-mini-card span:last-child { font-size: 13px; color: var(--muted); }
@media (max-width: 900px) { .now-mini { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.now-body { display: flex; flex-direction: column; gap: 10px; padding: 16px 18px 18px; flex: 1; }
.now-body h3 { margin: 0; font: var(--display-weight) 19px/1.25 var(--font-display); letter-spacing: -0.01em; }
.now-body > p { margin: 0; font-size: 14.5px; color: var(--muted); }
.now-facts { list-style: none; margin: 0; padding: 0; display: grid; gap: 5px; font-size: 13.5px; }
.now-facts li { display: grid; grid-template-columns: 86px 1fr; gap: 8px; }
.now-k { color: var(--muted); }
.now-more { margin: 0; padding: 8px 12px; border-radius: 10px; background: var(--surface-alt); font-size: 13px; }
.now-body .pill { align-self: flex-start; margin-top: auto; }
@media (max-width: 960px) { .now-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .now-list { grid-template-columns: 1fr; } .chips.now-jump { flex-wrap: nowrap; overflow-x: auto; margin-inline: -16px; padding: 2px 16px 6px; scrollbar-width: none; } }
.easy-text strong { font-size: 17px; }
.easy-text span { color: var(--muted); font-size: 14.5px; }
#easy-btn[aria-pressed="true"] { background: var(--good-strong); border-color: var(--good-strong); color: var(--on-good); }
.fbar { display: grid; gap: 14px; margin-top: 22px; padding-bottom: 18px; border-bottom: 1px solid var(--line); outline: none; scroll-margin-top: 96px; }
.fbar-row { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 12px; align-items: center; }
.fbar-label { font-size: 13px; font-weight: 600; color: var(--muted); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { padding: 8px 14px; border: 1px solid var(--line); border-radius: var(--radius-pill); background: var(--surface); color: var(--text); font: inherit; font-size: 14px; line-height: 1.2; cursor: pointer; white-space: nowrap; transition: border-color 0.15s, background 0.15s; }
.chip:hover { border-color: var(--text); }
.chip[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.chip[aria-pressed="true"]::after { content: " ×"; opacity: 0.7; }
.chip.is-empty, .fseg button.is-empty { opacity: 0.38; }
#cat-pills .extra:not([aria-pressed="true"]) { display: none; }
#cat-pills.show-all .extra { display: inline-block; }
.chip-more { border-style: dashed; color: var(--muted); }
.fseg { display: inline-flex; flex-wrap: wrap; gap: 4px; padding: 4px; border-radius: var(--radius-pill); background: var(--surface-alt); justify-self: start; }
.fseg button { padding: 7px 14px; border: 0; border-radius: var(--radius-pill); background: transparent; color: var(--text); font: inherit; font-size: 14px; cursor: pointer; white-space: nowrap; }
.fseg button[aria-pressed="true"] { background: var(--surface); box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12); font-weight: 600; }
.results-bar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px 20px; margin: 16px 0 16px; }
.results-left, .results-right { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.results-count { font-size: 14px; font-weight: 600; }
.select { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); }
.select select { padding: 7px 30px 7px 12px; border: 1px solid var(--line); border-radius: var(--radius-pill); background: var(--surface); color: var(--text); font: inherit; font-size: 14px; cursor: pointer; appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%); background-position: right 15px center, right 10px center; background-size: 5px 5px; background-repeat: no-repeat; }
.empty p { margin: 0 0 14px; color: var(--text); font-weight: 500; }
.empty .chips { justify-content: center; margin-bottom: 14px; }
@media (max-width: 700px) {
  .fbar-row { grid-template-columns: 1fr; gap: 8px; }
  /* Phones: long chip rows scroll sideways instead of filling the screen. */
  .fbar .chips { flex-wrap: nowrap; overflow-x: auto; margin-inline: -16px; padding: 2px 16px 6px; scrollbar-width: none; }
  .fbar .chips::-webkit-scrollbar { display: none; }
  .fseg { flex-wrap: nowrap; max-width: 100%; overflow-x: auto; scrollbar-width: none; justify-self: start; }
  .fseg::-webkit-scrollbar { display: none; }
  .fseg button { padding: 7px 12px; font-size: 13.5px; }
  .easy { padding: 16px; }
  .easy .pill { width: 100%; }
  /* Sort and source side by side; their labels stay for screen readers only. */
  .results-right { gap: 8px; flex-wrap: nowrap; }
  .select > span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .select select { font-size: 13.5px; max-width: 46vw; }
}
.grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.card { display: flex; flex-direction: column; min-width: 0; border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--surface); text-decoration: none; color: inherit; overflow: hidden; }
.card:hover .media img { scale: 1.03; }
.card-media { position: relative; padding: 8px 8px 0; }
.card .media { aspect-ratio: 16 / 10; border-radius: calc(var(--radius-card) - 6px); }
.card-media .badge { top: 18px; left: 18px; }
.card-media .badge-lang { left: auto; right: 18px; background: var(--good-strong); color: var(--on-good); }
.card-media .badge-region { left: auto; right: 18px; background: var(--region); color: var(--on-region); }
.region-note { display: inline-flex; align-items: center; padding: 4px 12px; border-radius: var(--radius-pill); background: var(--region); color: var(--on-region); font-size: 13px; font-weight: 600; text-transform: var(--label-transform); letter-spacing: var(--label-tracking); }
.lang-note { display: inline-flex; align-items: center; gap: 8px; padding: 4px 12px; border-radius: var(--radius-pill); background: var(--good-strong); color: var(--on-good); font-size: 13px; font-weight: 600; text-transform: var(--label-transform); letter-spacing: var(--label-tracking); }
.card-body { display: flex; flex-direction: column; gap: 6px; padding: 16px 16px 14px; flex: 1; }
.card h3 { margin: 0; font: var(--display-weight) var(--size-card)/1.2 var(--font-display); }
.card .org { font-size: var(--size-small); color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card .desc { margin: 6px 0 0; font-size: 14px; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.card .meta-line { margin-top: auto; padding-top: 12px; font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.card .status { font-size: 12.5px; font-weight: 600; }
.card .status.good { color: var(--good); }
.card .status.warn { color: var(--warn); }
.empty { grid-column: 1 / -1; padding: 40px; text-align: center; color: var(--muted); border: 1px dashed var(--line); border-radius: var(--radius-card); }
.more { display: flex; justify-content: center; margin-top: 28px; }

/* Follow */
.view .label { display: block; margin: 32px 0 12px; }
.insta { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.insta a { display: grid; gap: 2px; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--radius-card); text-decoration: none; }
.insta strong { font: var(--display-weight) 17px/1.2 var(--font-display); }
.insta span { font-size: var(--size-small); color: var(--muted); }
.portals { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.portals a { font-weight: 600; }
.portals p { margin: 2px 0 0; color: var(--muted); font-size: 14px; }

/* Text views */
.info-list { display: grid; gap: 26px; margin-top: 36px; }
.info-list h2 { margin: 0 0 4px; font: var(--display-weight) 22px/1.2 var(--font-display); }
.info-list p { margin: 0; color: var(--muted); max-width: 62ch; }
.contact { margin-top: 36px; }
.placeholder-text { background: var(--placeholder); padding: 1px 6px; border-radius: 4px; user-select: all; }

/* Propose an offer: steps, fields, review */
.orgs-cta { margin-top: 24px; }
.steps { list-style: none; counter-reset: step; display: flex; gap: 8px; margin: 32px 0 8px; padding: 0; flex-wrap: wrap; }
.steps li { counter-increment: step; display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px 6px 6px; border: 1px solid var(--line); border-radius: var(--radius-pill); font-size: var(--size-small); color: var(--muted); }
.steps li::before { content: counter(step); display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--surface-alt); color: var(--text); font-weight: 700; font-size: 11px; }
.steps li[aria-current] { border-color: var(--accent); color: var(--text); font-weight: 600; }
.steps li[aria-current]::before { background: var(--accent); color: var(--on-accent); }
.steps li.done::before { content: "✓"; background: var(--good-strong); color: var(--on-good); }
.pf, .pf-step { display: grid; gap: 18px; }
.pf-h { margin: 16px 0 0; font: var(--display-weight) 26px/1.2 var(--font-display); outline: none; }
.pf-sub { margin: 14px 0 -10px; font: var(--display-weight) 20px/1.2 var(--font-display); }
.field { display: grid; gap: 6px; min-width: 0; margin: 0; padding: 0; border: 0; }
.field > label, .field-label { font-size: var(--size-small); font-weight: 600; }
.field input:not([type="radio"]):not([type="checkbox"]):not([type="file"]), .field select, .field textarea {
  width: 100%; padding: 11px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--text); font: inherit; }
.field textarea { resize: vertical; min-height: 120px; line-height: 1.5; }
.field input[type="file"] { font: inherit; font-size: var(--size-small); }
.field [aria-invalid="true"] { border-color: var(--warn) !important; }
.field-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 18px; align-items: start; }
.hint { margin: 0; color: var(--muted); font-size: 12.5px; line-height: 1.45; }
.hint.proto { font-style: italic; }
.err { margin: 0; color: var(--warn); font-size: 12.5px; font-weight: 600; }
.warn-text { color: var(--warn); }
.seg { display: flex; flex-wrap: wrap; gap: 6px; }
.seg label { position: relative; }
.seg input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.seg span { display: inline-block; padding: 8px 14px; border: 1px solid var(--line); border-radius: var(--radius-pill); font-size: var(--size-small); cursor: pointer; }
.seg input:checked + span { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.seg input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.check { display: flex; align-items: flex-start; gap: 10px; font-size: 14px; cursor: pointer; }
.check input { margin: 3px 0 0; width: 16px; height: 16px; accent-color: var(--accent); flex: none; }
.checks { gap: 10px; }
.consent { color: var(--muted); font-size: 13px; line-height: 1.5; }
.id-added { display: flex; gap: 10px; align-items: baseline; font-size: var(--size-small); font-weight: 600; color: var(--good); }
.pf-nav { display: flex; justify-content: space-between; gap: 12px; margin-top: 8px; }
.pf-nav .pill[disabled] { opacity: 0.6; cursor: progress; }
.pf-card { padding: 18px 20px; border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--surface); }
.pf-card + .pf-card { margin-top: 14px; }
.pf-card-head { display: flex; justify-content: space-between; align-items: baseline; }
.pf-card h3 { margin: 0 0 10px; font: var(--display-weight) 18px/1.2 var(--font-display); }
.pf-dl { display: grid; grid-template-columns: minmax(120px, 30%) 1fr; gap: 8px 16px; margin: 0; font-size: 14px; }
.pf-dl dt { color: var(--muted); }
.pf-dl dd { margin: 0; overflow-wrap: anywhere; white-space: pre-line; }
.pf-done { display: grid; gap: 12px; justify-items: start; margin-top: 28px; padding: 24px; border: 1px solid var(--line); border-radius: var(--radius-card); outline: none; }
.pf-done p { margin: 0; max-width: 62ch; }
.pf-mine { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.pf-mine li { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; font-size: 14px; }
.pf-mine span { color: var(--muted); font-size: 12.5px; }
.pf-mine .pf-status { margin-left: auto; color: var(--good); font-weight: 600; }
.pf-mine .pf-status.warn { color: var(--warn); }
@media (max-width: 600px) {
  .pf-dl { grid-template-columns: 1fr; gap: 2px; }
  .pf-dl dd { margin-bottom: 8px; }
  .pf-nav .pill-lg { padding: 12px 18px; }
}

/* Blog article */
.post { display: grid; gap: 14px; justify-items: start; }
.post-hero { width: 100%; margin-top: 8px; }
.post-hero .media { aspect-ratio: 21 / 9; }
.post .page-title { margin: 0; }
.post .lead { margin: 0; font-size: 18px; }
.post-body { display: grid; gap: 14px; max-width: 65ch; font-size: 16px; line-height: 1.65; }
.post-body p { margin: 0; }
.post h2 { margin: 18px 0 0; font: var(--display-weight) 24px/1.2 var(--font-display); }
.post-todo, .post-sources { margin: 0; padding-left: 20px; display: grid; gap: 8px; max-width: 65ch; }
.post-sources { font-size: 14px; color: var(--muted); }
.post .pill-lg { margin-top: 8px; }

/* Assistant: floating button, chat panel (bottom sheet on phones) */
.ai-launch { position: fixed; right: max(18px, calc(env(safe-area-inset-right, 0px) + 12px)); bottom: max(18px, calc(env(safe-area-inset-bottom, 0px) + 12px)); z-index: 30;
  display: inline-flex; align-items: center; gap: 8px; padding: 12px 18px; border: 0; border-radius: var(--radius-pill); background: var(--accent); color: var(--on-accent);
  font: 600 14px/1 var(--font-body); box-shadow: var(--shadow-menu); cursor: pointer; }
.ai-launch svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; }
.ai-panel { position: fixed; right: max(18px, calc(env(safe-area-inset-right, 0px) + 12px)); bottom: max(18px, calc(env(safe-area-inset-bottom, 0px) + 12px)); z-index: 31;
  width: min(400px, calc(100vw - 32px)); height: min(620px, calc(100vh - 110px)); display: flex; flex-direction: column;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-card); box-shadow: var(--shadow-menu); overflow: hidden; }
.ai-head { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.ai-head span { color: var(--muted); font-size: var(--size-small); }
.ai-close { border: 0; background: none; color: var(--text); font-size: 24px; line-height: 1; cursor: pointer; padding: 0 4px; }
.ai-log { flex: 1; overflow-y: auto; padding: 14px 16px; display: flex; flex-direction: column; gap: 12px; }
.ai-msg p { margin: 0; padding: 9px 12px; border-radius: 14px; max-width: 88%; font-size: 14px; line-height: 1.45; }
.ai-bot p { background: var(--surface-alt); border-bottom-left-radius: 4px; }
.ai-user { display: flex; justify-content: flex-end; }
.ai-user p { background: var(--accent); color: var(--on-accent); border-bottom-right-radius: 4px; }
.ai-typing p { color: var(--muted); }
.ai-cards { display: grid; gap: 8px; margin-top: 8px; }
.ai-card { display: grid; gap: 2px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; text-decoration: none; font-size: 13px; }
.ai-card:hover { border-color: var(--accent); }
.ai-card strong { font: var(--display-weight) 15px/1.25 var(--font-display); }
.ai-card span { color: var(--muted); }
.ai-card .ai-flag { justify-self: start; margin-top: 4px; padding: 1px 8px; border-radius: var(--radius-pill); font-size: 11px; font-weight: 700; }
.ai-flag.good { background: var(--good-strong); color: var(--on-good); }
.ai-flag.warn { color: var(--warn); border: 1px solid currentColor; }
.ai-chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 16px 10px; }
.ai-chips .pill-opt { text-align: left; }
.ai-form { display: flex; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--line); }
.ai-form input { flex: 1; min-width: 0; padding: 9px 12px; border: 1px solid var(--line); border-radius: var(--radius-pill); background: var(--surface-alt); color: var(--text); font: inherit; }
@media (max-width: 600px) {
  .ai-launch span { display: none; }
  .ai-launch { padding: 14px; }
  .ai-panel { right: 0; left: 0; bottom: 0; width: 100%; height: min(80vh, 640px); border-radius: var(--radius-card) var(--radius-card) 0 0;
    padding-bottom: env(safe-area-inset-bottom, 0px); }
}

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding-block: 22px; font-size: 12px; color: var(--muted); }
.footer-inner { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px 20px; text-align: center; }

/* Tablet */
@media (max-width: 960px) {
  .header-inner { grid-template-columns: auto minmax(0, 1fr) auto; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Phone */
@media (max-width: 600px) {
  .header-inner { grid-template-columns: minmax(0, 1fr) auto; row-gap: 8px; }
  .search { grid-column: 1 / -1; grid-row: 2; max-width: none; }
  .grid { grid-template-columns: 1fr; }
  .causes-block { margin-top: 48px; }
  .cause-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
}


/* ======================================================================
   Phones (up to 600 px): one slim header row, left-aligned start, causes as
   swipeable cards, compact offer rows. Desktop and tablet stay as they are.
   ====================================================================== */
.search-toggle, .menu-phone, .cause-strip { display: none; }
@media (max-width: 600px) {
  /* Header: logo left, magnifier and menu right, 56 px high. */
  .site-header .header-inner { grid-template-columns: minmax(0, 1fr) auto; min-height: 56px; padding-block: 6px; row-gap: 8px; }
  .brand { font-size: 16px; font-weight: 700; }
  .header-propose, .lang-btn, #theme-btn { display: none; }
  .search-toggle { display: grid; }
  .header-inner .search { display: none; grid-column: 1 / -1; grid-row: 2; }
  .search-open .header-inner .search { display: flex; }
  .main-menu { position: fixed; top: calc(env(safe-area-inset-top, 0px) + 58px); left: max(10px, env(safe-area-inset-left, 0px)); right: max(10px, env(safe-area-inset-right, 0px)); min-width: 0; max-height: calc(100dvh - 80px); overflow-y: auto; }
  .main-menu a { padding: 13px 12px; font-size: 16px; }
  .menu-phone { display: flex; gap: 8px; margin-top: 6px; padding-top: 8px; border-top: 1px solid var(--line); }
  .menu-phone button { flex: 1; padding: 11px 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--text); font: inherit; font-size: 15px; cursor: pointer; }

  /* Start: centred title, the two main buttons right under it. */
  .view-home { padding-top: 22px; }
  .home-hero { text-align: center; justify-items: center; gap: 8px; padding-inline: max(16px, env(safe-area-inset-left, 0px)) max(16px, env(safe-area-inset-right, 0px)); }
  .home-hero .display { font-size: clamp(30px, 8.7vw, 36px); line-height: 1.04; }
  .home-hero .display br { display: inline; }
  .tagline { font-size: 16px; }
  #featured { display: none; }
  .home-actions { justify-content: stretch; gap: 10px; margin-top: 18px; padding-inline: max(16px, env(safe-area-inset-left, 0px)) max(16px, env(safe-area-inset-right, 0px)); }
  .home-actions .pill { flex: 1; padding-inline: 12px; }

  /* Causes: a row of cards you swipe through; the next one peeks in. */
  .cause-strip { display: flex; gap: 12px; margin-top: 22px; padding: 2px max(16px, env(safe-area-inset-left, 0px)) 8px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: 16px; scrollbar-width: none; }
  .cause-strip::-webkit-scrollbar { display: none; }
  .cs-card { flex: 0 0 78%; scroll-snap-align: start; display: grid; align-content: start; border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--surface); text-decoration: none; color: inherit; overflow: hidden; }
  .cs-photo { aspect-ratio: 16 / 10; border-radius: 0; }
  .cs-body { display: grid; gap: 6px; padding: 12px 14px 14px; }
  .cs-body strong { font: var(--display-weight) 18px/1.2 var(--font-display); letter-spacing: -0.01em; }
  .cs-desc { font-size: 14px; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .cs-feat { font-size: 13px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .cs-feat span { color: var(--muted); }

  /* Offer and event cards: photo on top as a slim strip, text below, kept short. */
  .grid { grid-template-columns: 1fr; gap: 14px; }
  .grid > .card .card-media { padding: 6px 6px 0; }
  .grid > .card .media { aspect-ratio: 21 / 9; border-radius: 12px; }
  .grid > .card .card-media .badge { top: 14px; left: 14px; font-size: 11.5px; padding: 3px 8px; }
  .grid > .card .card-media .badge-lang, .grid > .card .card-media .badge-region { left: auto; right: 14px; }
  .grid > .card .card-body { padding: 10px 14px 12px; gap: 3px; }
  .grid > .card h3 { font-size: 16.5px; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .grid > .card .desc { display: none; }
  /* The green badge on the photo already says it. */
  .grid > .card .status.good { display: none; }
  .grid > .card .meta-line { padding-top: 4px; font-size: 12.5px; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }

  /* Sections a little tighter. */
  .causes-block { margin-top: 44px; }

  /* Assistant: a small round button that leaves room for the page's own buttons. */
  .ai-launch { width: 48px; height: 48px; padding: 0; justify-content: center; }
  main { padding-bottom: 72px; }
}
