/* zoky.pt — agenda pages (/e/…, /<concelho>/…, /agenda/). Generated nightly by tools/build_agenda.mjs.
   Tokens are the same as site.css (DESIGN.md): change them there first, then here. */
@font-face { font-family: "Nunito"; font-weight: 900; font-display: swap; src: url(/assets/fonts/nunito-900.woff2) format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 800 900; font-display: swap; src: url(/assets/fonts/inter-800.woff2) format("woff2"); }
@font-face { font-family: "DM Sans"; font-weight: 400; font-display: swap; src: url(/assets/fonts/dmsans-400.woff2) format("woff2"); }
@font-face { font-family: "DM Sans"; font-weight: 500; font-display: swap; src: url(/assets/fonts/dmsans-500.woff2) format("woff2"); }
@font-face { font-family: "DM Sans"; font-weight: 700; font-display: swap; src: url(/assets/fonts/dmsans-700.woff2) format("woff2"); }

:root {
  --orange: #D97757; --orange-deep: #C15F3C; --why: #A64B2A; --cream: #FFF8F3; --ink-0: #1D1A17; --night: #16130F; --map-hot: #F3A585;
  --bg: var(--cream); --text: var(--ink-0); --muted: #6B625A; --card: #FFFFFF; --line: #EEDFD2; --focus: var(--ink-0);
  --accent-text: var(--why); --app-bg: var(--night);
  --radius-photo: 20px; --radius-btn: 14px;
  --gutter: clamp(16px, 4.5vw, 64px);
  --font-logo: "Nunito", "Arial Rounded MT Bold", system-ui, sans-serif; /* only the «zoky.» logo */
  --font-display: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; /* titles: Inter ExtraBold (José, 11/Nov) */
  --font-text: "DM Sans", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: var(--night); --text: #F6EFE8; --muted: #B3A89D; --card: #221D18; --line: #2C2620; --focus: #F6EFE8;
    --accent-text: var(--map-hot); --app-bg: #221D18; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: var(--night); --text: #F6EFE8; --muted: #B3A89D; --card: #221D18; --line: #2C2620; --focus: #F6EFE8;
  --accent-text: var(--map-hot); --app-bg: #221D18; color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 400 17px/1.55 var(--font-text); overflow-x: hidden; }
img { display: block; max-width: 100%; }
h1, h2, h3, p { margin: 0; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 6px; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 50; background: var(--ink-0); color: var(--cream); padding: 10px 16px; border-radius: 10px; text-decoration: none; font-weight: 700; }
.skip:focus { top: 12px; }
.wrap { width: 100%; max-width: 1240px; margin: 0 auto; padding: 0 var(--gutter); }
.muted { color: var(--muted); }

/* header */
.top { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding-top: 14px; padding-bottom: 14px; }
.logo { font: 900 30px/1 var(--font-logo); letter-spacing: -0.035em; text-decoration: none; }
.logo span { color: var(--orange); }
.top-actions { display: flex; align-items: center; gap: 2px; }
.top-link { display: inline-flex; align-items: center; min-height: 44px; padding: 0 12px; font-weight: 700; font-size: 15px; text-decoration: none; border-radius: 999px; }
.top-link:hover, .icon-btn:hover { background: var(--line); }
.icon-btn { width: 44px; height: 44px; border-radius: 50%; border: 0; background: transparent; display: grid; place-items: center; cursor: pointer; font: 700 14px var(--font-text); letter-spacing: .02em; color: inherit; text-decoration: none; }
.icon-btn svg { width: 22px; height: 22px; fill: currentColor; }
.icon-btn .i-sun { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; display: none; }
.icon-btn .i-sun circle { fill: currentColor; }
:root[data-theme="dark"] .i-sun { display: block; } :root[data-theme="dark"] .i-moon { display: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .i-sun { display: block; } :root:not([data-theme="light"]) .i-moon { display: none; } }

/* breadcrumb + titles */
.crumbs { list-style: none; margin: 18px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 2px 0; font-size: 14.5px; color: var(--muted); }
.crumbs li + li::before { content: "›"; margin: 0 8px; }
.crumbs a { text-decoration: none; font-weight: 500; }
.crumbs a:hover { text-decoration: underline; }
h1 { margin-top: 10px; font: 900 clamp(34px, 6.2vw, 68px)/0.98 var(--font-display); letter-spacing: -0.025em; text-wrap: balance; overflow-wrap: anywhere; }
.lead { margin-top: 14px; font-size: clamp(17px, 1.5vw, 19px); max-width: 60ch; }
h2 { font: 900 clamp(24px, 3vw, 32px)/1.05 var(--font-display); letter-spacing: -0.025em; }

/* pills (filters: today, weekend, categories) */
.pills { list-style: none; margin: 22px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.pills a { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 16px; border-radius: 999px; background: var(--card); box-shadow: inset 0 0 0 1.5px var(--line); font-weight: 700; font-size: 15px; text-decoration: none; }
.pills a:hover { box-shadow: inset 0 0 0 1.5px var(--orange); }
.pills a[aria-current="page"] { background: var(--orange); color: var(--ink-0); box-shadow: none; }
.pills small { font-weight: 500; font-size: 13px; opacity: .75; }

/* day groups and cards */
.day { margin-top: 40px; }
.day h2 { margin-bottom: 16px; }
.cards { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.card { position: relative; background: var(--card); border-radius: var(--radius-photo); overflow: hidden; display: flex; flex-direction: column; }
.card-photo { aspect-ratio: 4 / 3; background: var(--line); overflow: hidden; }
.card-photo img { width: 100%; height: 100%; object-fit: cover; }
.card-body { padding: 14px 16px 16px; display: grid; gap: 4px; font-size: 15px; }
.card-cat { color: var(--accent-text); font-weight: 700; font-size: 13.5px; }
.card h3 { font: 700 19px/1.2 var(--font-text); letter-spacing: -0.01em; overflow-wrap: anywhere; }
.card h3 a { text-decoration: none; }
.card h3 a::after { content: ""; position: absolute; inset: 0; }
.card h3 a:focus-visible { outline: none; }
.card:has(h3 a:focus-visible) { outline: 3px solid var(--focus); outline-offset: 3px; }
.card .meta { font-weight: 500; }
.card .src { color: var(--muted); font-size: 13.5px; }
.card .times { color: var(--muted); }

/* facts-only rows (no photo, link goes to the source) */
.rows { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 10px; }
.row { position: relative; background: var(--card); border-radius: 16px; padding: 14px 16px; display: grid; gap: 2px; font-size: 15px; }
.row h3 { font: 700 17px/1.25 var(--font-text); overflow-wrap: anywhere; }
.row h3 a { text-decoration: none; }
.row h3 a::after { content: ""; position: absolute; inset: 0; }
.row:has(h3 a:focus-visible) { outline: 3px solid var(--focus); outline-offset: 3px; }
.row h3 a:focus-visible { outline: none; }
.row .src { color: var(--muted); font-size: 13.5px; }
.sub { margin-top: 28px; font: 900 22px/1.1 var(--font-display); letter-spacing: -0.02em; }

.empty { margin-top: 32px; background: var(--card); border-radius: var(--radius-photo); padding: 24px; display: grid; gap: 14px; justify-items: start; }
.more { margin-top: 18px; }

/* event page */
.ev { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: clamp(22px, 4vw, 56px); margin-top: 22px; align-items: start; }
.ev-photo { border-radius: var(--radius-photo); overflow: hidden; background: var(--line); aspect-ratio: 4 / 3; }
.ev-photo img { width: 100%; height: 100%; object-fit: cover; }
.ev-photo figcaption { font-size: 13px; color: var(--muted); padding-top: 8px; }
.ev-side { display: grid; gap: 18px; }
.facts { margin: 0; display: grid; gap: 14px; }
.facts div { display: grid; gap: 2px; }
.facts dt { font-size: 13.5px; font-weight: 700; color: var(--accent-text); text-transform: uppercase; letter-spacing: .06em; }
.facts dd { margin: 0; font-weight: 500; overflow-wrap: anywhere; }
.facts dd a { font-weight: 700; text-underline-offset: 3px; }
.summary { font-size: 17.5px; max-width: 62ch; white-space: pre-line; }
.sessions { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-weight: 500; }
.sessions li { display: flex; flex-wrap: wrap; gap: 0 10px; }
.sessions .muted { font-weight: 400; }
.ctas { display: flex; flex-wrap: wrap; gap: 10px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding: 0 22px; border-radius: var(--radius-btn); font-weight: 700; font-size: 16px; text-decoration: none; border: 0; cursor: pointer; }
.btn-orange { background: var(--orange); color: var(--ink-0); }
.btn-orange:hover { background: #E3876A; }
.btn-line { background: transparent; color: var(--text); box-shadow: inset 0 0 0 2px var(--line); }
.btn-line:hover { box-shadow: inset 0 0 0 2px var(--orange); }
.past { background: var(--card); border-radius: 16px; padding: 14px 16px; font-weight: 700; }
.credit { font-size: 14px; color: var(--muted); max-width: 70ch; }
.credit a { color: inherit; }

/* municipality index (/agenda/) */
.towns { list-style: none; margin: 24px 0 0; padding: 0; columns: 3 220px; column-gap: 24px; }
.towns li { break-inside: avoid; }
.towns a { display: flex; justify-content: space-between; gap: 12px; min-height: 44px; align-items: center; text-decoration: none; font-weight: 700; border-bottom: 1px solid var(--line); }
.towns a:hover { color: var(--accent-text); }
.towns small { font-weight: 500; color: var(--muted); }

/* app block */
.app { margin-top: 56px; background: var(--app-bg); color: #F6EFE8; border-radius: 28px; padding: clamp(22px, 4vw, 40px); display: flex; flex-wrap: wrap; gap: 16px 28px; align-items: center; justify-content: space-between; }
.app p { font: 900 clamp(24px, 3vw, 34px)/1.05 var(--font-display); letter-spacing: -0.025em; max-width: 22ch; }
.app p span { color: var(--orange); }
.app :focus-visible { outline-color: #F6EFE8; }

/* footer */
.foot { padding: 40px 0 52px; font-size: 15px; }
.foot-grid { display: grid; grid-template-columns: auto 1fr; gap: 12px 32px; align-items: center; }
.foot-links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 24px; justify-content: flex-end; }
.foot-links a { display: inline-flex; min-height: 44px; align-items: center; text-decoration: none; font-weight: 700; }
.foot-links a:hover { text-decoration: underline; }
.foot-note { grid-column: 1 / -1; color: var(--muted); font-size: 14px; }

@media (max-width: 960px) {
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ev { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 620px) {
  .top-link.hide-s { display: none; }
  .pills { flex-wrap: nowrap; overflow-x: auto; margin-left: calc(-1 * var(--gutter)); margin-right: calc(-1 * var(--gutter)); padding: 2px var(--gutter) 6px; scrollbar-width: none; }
  .pills::-webkit-scrollbar { display: none; }
  .pills li { flex: 0 0 auto; }
  .cards { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .card { flex-direction: row; min-height: 112px; }
  .card-photo { flex: 0 0 104px; aspect-ratio: auto; }
  .card-body { padding: 12px 14px; align-content: start; }
  .card h3 { font-size: 17px; }
  .foot-grid { grid-template-columns: 1fr; }
  .foot-links { justify-content: flex-start; }
}
