/* Agenda Tech Torino: club flyer / night poster wall */
:root {
  --bg: #0a0a0b;
  --panel: #131315;
  --panel-2: #1c1c1f;
  --line: #2e2e33;
  --ink: #f3efe7;
  --muted: #aaa69f;
  --lime: #c8ff1a;
  --pink: #ff2d87;
  --bone: #ece6da;
  --grey: #8d8a85;
  --font-display: "Big Shoulders Display", "Arial Narrow", Impact, sans-serif;
  --font-body: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --font-mono: "Space Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --gutter: 16px;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; background: var(--bg); }
html:has(dialog[open]) { overflow: hidden; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.5;
  overflow-x: clip;
  overflow-wrap: anywhere;
}

/* film grain over everything (decorative, never blocks clicks) */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 50;
  pointer-events: none;
  opacity: 0.09;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .6 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

::selection { background: var(--lime); color: var(--bg); }
html { scrollbar-color: var(--line) var(--bg); }
input, textarea { caret-color: var(--lime); }

img { max-width: 100%; display: block; }
a { color: var(--ink); }

:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
}

[hidden] { display: none !important; }

.skip-link {
  position: absolute;
  left: 8px;
  top: -80px;
  z-index: 60;
  background: var(--lime);
  color: var(--bg);
  font-weight: 700;
  padding: 10px 16px;
}
.skip-link:focus { top: 8px; }

.wrap {
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 22px;
  border: 2px solid transparent;
  border-radius: 0;
  font-family: var(--font-body);
  font-stretch: 80%;
  font-weight: 750;
  font-size: 0.95rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1.1;
  text-decoration: none;
  text-align: center;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s, color 0.15s;
}
.btn-primary { background: var(--lime); border-color: var(--lime); color: var(--bg); }
.btn-primary:hover { transform: translate(-3px, -3px); box-shadow: 5px 5px 0 var(--pink); }
.btn-secondary { background: transparent; border-color: var(--ink); color: var(--ink); }
.btn-secondary:hover { background: var(--ink); color: var(--bg); }
.btn-small { min-height: 44px; padding: 10px 16px; font-size: 0.875rem; }

.link-button {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 6px;
  background: none;
  border: 0;
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: underline;
  text-decoration-color: var(--pink);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
  cursor: pointer;
}
.link-button:hover { color: var(--pink); }

.copy-status {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--lime);
  min-height: 1.2em;
}

/* Ticker */
.ticker {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: stretch;
  background: var(--lime);
  color: var(--bg);
  border-bottom: 2px solid var(--bg);
}
.ticker-label {
  flex: none;
  display: flex;
  align-items: center;
  padding: 0 14px;
  background: var(--bg);
  color: var(--lime);
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.ticker-window {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 32px, #000 calc(100% - 32px), transparent 100%);
          mask-image: linear-gradient(90deg, transparent 0, #000 32px, #000 calc(100% - 32px), transparent 100%);
}
.ticker-track {
  display: flex;
  width: max-content;
  animation: ticker var(--ticker-dur, 60s) linear infinite;
}
.ticker.is-paused .ticker-track,
.ticker-window:hover .ticker-track { animation-play-state: paused; }
.ticker-group { display: flex; flex: none; }
.ticker-item {
  display: inline-flex;
  align-items: baseline;
  gap: 10px;
  padding: 11px 22px 11px 0;
  white-space: nowrap;
}
.ticker-item::before {
  content: "";
  width: 9px;
  height: 9px;
  background: var(--bg);
  transform: rotate(45deg) translateY(-2px);
  align-self: center;
  margin-right: 8px;
}
.ticker-item b {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.ticker-item span {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.25rem;
  line-height: 1;
  text-transform: uppercase;
}
.ticker-item i { font-style: normal; font-size: 0.85rem; font-weight: 500; }
a.ticker-item { color: inherit; text-decoration: none; cursor: pointer; }
a.ticker-item:hover span { text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 3px; }
.ticker-toggle {
  flex: none;
  width: 44px;
  min-height: 44px;
  border: 0;
  background: var(--bg);
  color: var(--lime);
  cursor: pointer;
  display: grid;
  place-items: center;
}
.ticker-toggle:focus-visible { outline-color: var(--pink); outline-offset: -4px; }
.ticker-icon {
  width: 12px;
  height: 14px;
  border-left: 4px solid currentColor;
  border-right: 4px solid currentColor;
}
.ticker.is-paused .ticker-icon {
  width: 0;
  height: 0;
  border-right: 0;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-left: 13px solid currentColor;
  margin-left: 4px;
}
@keyframes ticker { to { transform: translateX(-50%); } }

/* Top of the page: masthead and this week's strip.
   On phones the two share one grid, so the week sits right under the title, before the buttons */
.top {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 40%);
  grid-template-areas: "title stack" "tagline tagline" "next next" "copy copy" "actions actions";
  gap: 14px 12px;
  padding: 24px 0 8px;
}
.masthead, .masthead-grid { display: contents; }
.masthead::before {
  content: "";
  position: absolute;
  right: 0;
  top: 0;
  width: 70%;
  height: 100%;
  max-height: 420px;
  background-image: radial-gradient(circle, var(--pink) 1.6px, transparent 2.2px);
  background-size: 14px 14px;
  opacity: 0.32;
  -webkit-mask-image: radial-gradient(ellipse at 85% 30%, #000 0, transparent 65%);
          mask-image: radial-gradient(ellipse at 85% 30%, #000 0, transparent 65%);
  pointer-events: none;
}
.title, .tagline, .masthead-copy, .hero-actions { padding-left: var(--gutter); }
.tagline, .masthead-copy, .hero-actions { padding-right: var(--gutter); }
.tagline {
  grid-area: tagline;
  margin: 0;
  max-width: 26em;
  font-size: clamp(1rem, 1.6vw, 1.2rem);
  line-height: 1.4;
  color: var(--muted);
  text-wrap: balance;
}

/* Hero flyer stack: the next posters pasted on the wall, tape on top */
.hero-stack {
  grid-area: stack;
  position: relative;
  align-self: center;
  width: calc(100% - var(--gutter));
  max-width: 460px;
  justify-self: start;
  aspect-ratio: 1 / 1.08;
}
.stack-flyer {
  position: absolute;
  width: 66%;
  aspect-ratio: 4 / 5;
  padding: 0;
  border: 0;
  background: var(--panel);
  color: inherit;
  cursor: pointer;
  box-shadow: 0 18px 36px -12px rgba(0, 0, 0, 0.85), 0 2px 6px rgba(0, 0, 0, 0.5);
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}
.stack-flyer .cover { position: absolute; inset: 0; aspect-ratio: auto; }
.stack-flyer .cover img { width: 100%; height: 100%; object-fit: cover; }
/* masking tape */
.stack-flyer::before {
  content: "";
  position: absolute;
  z-index: 2;
  top: -9px;
  left: 50%;
  width: 34%;
  height: 20px;
  transform: translateX(-50%) rotate(-3deg);
  background: rgba(236, 230, 218, 0.78);
  -webkit-mask-image: linear-gradient(90deg, transparent 0 3px, #000 3px calc(100% - 3px), transparent calc(100% - 3px));
          mask-image: linear-gradient(90deg, transparent 0 3px, #000 3px calc(100% - 3px), transparent calc(100% - 3px));
}
.stack-flyer.s0 { left: 0; top: 14%; transform: rotate(-7deg); z-index: 1; }
.stack-flyer.s1 { right: 0; top: 0; transform: rotate(5deg); z-index: 2; }
.stack-flyer.s2 { left: 17%; top: 30%; transform: rotate(-1.5deg); z-index: 3; }
.hero-stack[data-count="1"] .stack-flyer.s0 { left: 17%; top: 6%; transform: rotate(-3deg); }
.hero-stack[data-count="2"] .stack-flyer.s1 { top: 22%; }
.stack-flyer:hover, .stack-flyer:focus-visible {
  z-index: 4;
  transform: rotate(0deg) translateY(-8px) scale(1.04);
  box-shadow: 0 30px 50px -14px rgba(0, 0, 0, 0.9), 0 0 0 3px var(--tone, var(--lime));
}
.stack-flyer:focus-visible { outline: none; }
.stack-date {
  position: absolute;
  z-index: 2;
  left: -6px;
  bottom: 10px;
  display: flex;
  align-items: baseline;
  gap: 4px;
  padding: 2px 8px 1px;
  background: var(--tone, var(--lime));
  color: var(--bg);
  font-family: var(--font-display);
  font-weight: 900;
  text-transform: uppercase;
  line-height: 1;
}
.stack-flyer.s1 .stack-date { left: auto; right: -6px; bottom: auto; top: 22px; }
.stack-date b { font-size: clamp(1.1rem, 4vw, 2.2rem); }
.stack-date span { font-size: clamp(0.7rem, 2vw, 1.05rem); }
/* Nothing to come: the last flyers fade, a sticker says it picks up again, and a button puts the next one up */
.hero-stack.is-over .stack-flyer .cover { filter: grayscale(0.8) brightness(0.62); transition: filter 0.45s ease; }
.hero-stack.is-over .stack-flyer:hover .cover,
.hero-stack.is-over .stack-flyer:focus-visible .cover { filter: grayscale(0.35) brightness(0.85); }
.hero-stack.is-over .stack-date { background: var(--bone); }
.stack-sticker {
  position: absolute;
  z-index: 6;
  left: 4%;
  top: 34%;
  max-width: 62%;
  padding: 0.14em 0.4em 0.04em;
  background: var(--pink);
  color: var(--bg);
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(1.05rem, 4.4vw, 2.3rem);
  line-height: 0.9;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  transform: rotate(-6deg);
  box-shadow: 4px 4px 0 var(--bg);
  pointer-events: none;
}
.stack-cta {
  position: absolute;
  z-index: 7;
  right: 6%;
  bottom: -3%;
  white-space: nowrap;
}
/* phones: the sticker shrinks so the posters stay readable, the button sits under the stack instead of over a poster */
@media (max-width: 719px) {
  .hero-stack.is-over { margin-bottom: 54px; }
  .stack-sticker { left: 2%; top: 40%; max-width: 78%; font-size: clamp(0.78rem, 3.2vw, 1.3rem); box-shadow: 2px 2px 0 var(--bg); }
  .stack-cta { right: 0; bottom: -54px; }
}
.title {
  grid-area: title;
  margin: 0;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(3.4rem, 15vw, 10.5rem);
  line-height: 0.82;
  letter-spacing: -0.005em;
  text-transform: uppercase;
  overflow-wrap: normal;
}
.title span { display: inline-block; }
.title .t1 { display: block; }
.title .t2 {
  background: var(--pink);
  color: var(--bg);
  padding: 0.06em 0.08em 0;
  margin: 0.08em 0.12em 0 -0.02em;
  transform: rotate(-2deg);
}
.title .t3 {
  display: block;
  color: transparent;
  -webkit-text-stroke: 2px var(--lime);
  margin-top: 0.08em;
}
.masthead-copy { grid-area: copy; }
.subtitle {
  margin: 0;
  max-width: 30em;
  font-size: 1.15rem;
  line-height: 1.45;
  color: var(--ink);
}
.stats {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  margin: 8px 0 0;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}
.stats b {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 1.9rem;
  color: var(--lime);
  letter-spacing: 0;
  margin-right: 4px;
  vertical-align: -3px;
}
/* above the next section, or the calendar menu would open under it */
.hero-actions {
  grid-area: actions;
  position: relative;
  z-index: 5;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 12px;
}
/* the follow links get their own line under the buttons */
.hero-links { display: flex; flex-wrap: wrap; align-items: center; gap: 0 12px; flex-basis: 100%; }

/* This week: the evenings from now to Sunday, flyers taped in a row (it scrolls sideways when they do not fit) */
.week {
  grid-area: next;
  position: relative;
  border-top: 2px solid var(--ink);
  border-bottom: 2px solid var(--ink);
  background:
    radial-gradient(circle, rgba(236, 230, 218, 0.07) 1.2px, transparent 1.6px) 0 0 / 8px 8px,
    var(--panel);
}
.week-in { position: relative; padding-top: 16px; padding-bottom: 12px; }
.week-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 18px;
}
.week-title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(2.6rem, 6.4vw, 5rem);
  line-height: 0.85;
  text-transform: uppercase;
}
.week-meta {
  margin: 0;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--lime);
}
.week-more { display: flex; margin: -8px 0 0 auto; }
.week-list {
  display: flex;
  gap: 16px;
  margin: 0 calc(var(--gutter) * -1);
  padding: 20px var(--gutter) 22px;
  list-style: none;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-padding-left: var(--gutter);
  scrollbar-width: thin;
  scrollbar-color: var(--line) transparent;
}
.week-list .card {
  flex: 0 0 62%;
  max-width: 270px;
  aspect-ratio: 4 / 5;
  scroll-snap-align: start;
  transform: rotate(-1.2deg);
  box-shadow: 0 16px 30px -14px rgba(0, 0, 0, 0.9);
}
.week-list .card:nth-child(even) { transform: rotate(1deg) translateY(5px); }
/* the posters keep their colours here; the wall below is the two-ink print */
.week-list .wk .cover img { filter: none; mix-blend-mode: normal; }
.wk::before {
  content: "";
  position: absolute;
  z-index: 2;
  top: -9px;
  left: 50%;
  width: 34%;
  height: 20px;
  transform: translateX(-50%) rotate(-3deg);
  background: rgba(236, 230, 218, 0.78);
  -webkit-mask-image: linear-gradient(90deg, transparent 0 3px, #000 3px calc(100% - 3px), transparent calc(100% - 3px));
          mask-image: linear-gradient(90deg, transparent 0 3px, #000 3px calc(100% - 3px), transparent calc(100% - 3px));
}
.week-list .card:hover, .week-list .card:has(.flyer-open:focus-visible) {
  transform: translateY(-6px) rotate(0deg);
  box-shadow: 8px 8px 0 var(--tone-alt);
}
.wk .flyer-bottom .tags { display: flex; }
.wk .flyer-bottom .tags li + li { display: none; }
/* the way in for the next evening, above the flyer's own hit area */
.wk-cta { position: relative; z-index: 3; align-self: flex-start; margin-top: 4px; }
/* with the button inside, the title gets one line less so the flyer still holds it */
.wk:has(.wk-cta) .flyer-open { -webkit-line-clamp: 3; }
/* the flyer grows to hold the button instead of letting it hang below */
.wk:has(.wk-cta) { display: flex; flex-direction: column; }
.wk:has(.wk-cta) .card-body { position: relative; flex: 1 0 auto; }
/* and the others in the strip follow its height */
.week-list .card { align-self: stretch; }

/* Featured next event */
.featured {
  grid-area: next;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  border-top: 2px solid var(--ink);
  border-bottom: 2px solid var(--ink);
  background: var(--panel);
}
.featured-bg {
  position: absolute;
  inset: -40px;
  z-index: -2;
}
.featured-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(28px) saturate(1.4) brightness(0.55);
  transform: scale(1.1);
}
.featured-bg .cover-fallback { filter: blur(20px) brightness(0.5); }
.featured::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(90deg, rgba(10, 10, 11, 0.94) 0%, rgba(10, 10, 11, 0.82) 45%, rgba(10, 10, 11, 0.45) 100%),
    radial-gradient(circle, rgba(10, 10, 11, 0.6) 1.2px, transparent 1.6px) 0 0 / 6px 6px;
}
.featured-inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  padding-top: 28px;
  padding-bottom: 36px;
}
.featured-poster {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--tone, var(--lime));
  border: 3px solid var(--ink);
  box-shadow: 10px 10px 0 var(--tone, var(--lime));
  transform: rotate(-1.5deg);
  overflow: hidden;
  margin-right: 10px;
}
.featured-poster img { width: 100%; height: 100%; object-fit: cover; }
.featured-text { min-width: 0; }
.featured-kicker {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  margin: 0 0 10px;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--lime);
}
.featured-kicker .badges { margin: 0; }
.featured-date {
  display: flex;
  align-items: flex-end;
  gap: 10px;
  margin: 0 0 8px;
  font-family: var(--font-display);
  font-weight: 900;
  text-transform: uppercase;
  line-height: 0.78;
}
.fd-day { font-size: clamp(6rem, 22vw, 13rem); color: var(--lime); letter-spacing: -0.03em; }
.fd-side { display: flex; flex-direction: column; gap: 6px; padding-bottom: 0.25em; }
.fd-mon { font-size: clamp(2.4rem, 7vw, 4.2rem); color: var(--ink); }
.fd-dow {
  font-size: clamp(1.6rem, 4.5vw, 2.6rem);
  color: transparent;
  -webkit-text-stroke: 1.5px var(--ink);
}
.featured h2 {
  margin: 0 0 14px;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(2.3rem, 6.2vw, 5rem);
  line-height: 0.9;
  text-transform: uppercase;
  max-width: 14em;
}
.featured .when {
  margin: 0 0 4px;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--lime);
}
.featured .where { margin: 0 0 14px; }
.featured .tags { margin-bottom: 22px; }

/* Shared event bits */
.badges { display: flex; flex-wrap: wrap; gap: 6px; }
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 9px;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.7rem;
  line-height: 1.2;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.badge-today { background: var(--pink); color: var(--bg); }
.badge-today::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--bg);
  animation: blink 1.1s steps(2, start) infinite;
}
.badge-week { background: var(--lime); color: var(--bg); }
.badge-count { background: transparent; color: var(--lime); box-shadow: inset 0 0 0 2px var(--lime); }
.card.is-live { box-shadow: 6px 6px 0 var(--pink), 0 0 0 3px var(--pink); }
.badge-tomorrow { background: var(--bg); color: var(--pink); box-shadow: inset 0 0 0 2px var(--pink); }
.badge-past { background: #2b2b30; color: var(--ink); }
@keyframes blink { to { visibility: hidden; } }

.where { margin: 0; }
.where .place { font-weight: 650; }
.where a.place { color: inherit; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.where a.place:hover { color: var(--lime); }
.where .addr { display: block; font-size: 0.875rem; color: var(--muted); }
.where .addr.is-locked { display: flex; align-items: center; gap: 6px; }
.lock { width: 13px; height: 13px; flex: none; fill: none; stroke: var(--lime); stroke-width: 1.6; }
.where .tbd {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--pink);
  border: 1.5px dashed var(--pink);
  padding: 3px 8px;
}

.tags { display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 0; list-style: none; }
.chip {
  display: inline-block;
  padding: 3px 9px 2px;
  font-family: var(--font-body);
  font-stretch: 75%;
  font-weight: 750;
  font-size: 0.78rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border: 1.5px solid currentColor;
}
.chip.c0 { background: var(--lime); border-color: var(--lime); color: var(--bg); }
.chip.c1 { background: var(--pink); border-color: var(--pink); color: var(--bg); }
.chip.c2 { background: var(--bone); border-color: var(--bone); color: var(--bg); }
.chip.c3 { background: var(--bg); color: var(--pink); }
.chip.c4 { background: var(--bg); color: var(--lime); }

.actions { display: flex; flex-wrap: wrap; gap: 10px; }

/* Tones per community: lime, pink, bone */
.tone-0, .tone-4 { --tone: var(--lime); --tone-alt: var(--pink); }
.tone-1, .tone-3 { --tone: var(--pink); --tone-alt: var(--lime); }
.tone-2 { --tone: var(--bone); --tone-alt: var(--lime); }
.is-past { --tone: var(--grey); --tone-alt: var(--grey); }

.cover-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(4rem, 12vw, 8rem);
  line-height: 1;
  color: var(--bg);
  background-color: var(--tone, var(--lime));
  background-image: radial-gradient(circle, rgba(10, 10, 11, 0.28) 1.4px, transparent 1.9px);
  background-size: 9px 9px;
}

/* Wall controls */
#wall:focus { outline: none; }
.controls { padding-top: 64px; }
.controls-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px 20px;
  padding-bottom: 14px;
  border-bottom: 2px solid var(--ink);
}
.wall-title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(2.8rem, 9vw, 6.5rem);
  line-height: 0.82;
  text-transform: uppercase;
}
.day-toggle {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 10px 18px;
  border: 2px solid var(--ink);
  background: transparent;
  color: var(--ink);
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
}
.day-toggle:hover { background: var(--panel-2); }
.day-toggle[aria-expanded="true"] { background: var(--ink); color: var(--bg); }
.day-toggle.has-day { background: var(--lime); border-color: var(--lime); color: var(--bg); }
.day-toggle-icon {
  position: relative;
  width: 16px;
  height: 15px;
  border: 2px solid currentColor;
  border-top-width: 5px;
}
.day-toggle-icon::after {
  content: "";
  position: absolute;
  right: 2px;
  bottom: 2px;
  width: 4px;
  height: 4px;
  background: currentColor;
}

.day-panel {
  margin: 16px 0 0 auto;
  max-width: 860px;
  padding: 16px;
  background: var(--panel);
  border: 2px solid var(--ink);
  box-shadow: 8px 8px 0 var(--lime);
}

/* Search */
.search-bar { margin-top: 22px; max-width: 560px; }
.search-label {
  display: block;
  margin: 0 0 10px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}
.search-box { position: relative; }
.search-input {
  display: block;
  width: 100%;
  min-height: 52px;
  padding: 12px 52px 12px 14px;
  border: 2px solid var(--ink);
  border-radius: 0;
  background: var(--bg);
  color: var(--ink);
  font: inherit;
  font-size: 1.05rem;
  -webkit-appearance: none;
  appearance: none;
  transition: border-color 0.15s;
}
.search-input::placeholder { color: #8f8b84; }
.search-input::-webkit-search-cancel-button,
.search-input::-webkit-search-decoration { -webkit-appearance: none; display: none; }
.search-input:hover { background: var(--panel); }
.search-input:focus-visible { outline: 3px solid var(--lime); outline-offset: 2px; border-color: var(--lime); }
.search-clear {
  position: absolute;
  top: 50%;
  right: 4px;
  width: 44px;
  height: 44px;
  margin-top: -22px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--ink);
  cursor: pointer;
}
.search-clear[hidden] { display: none; }
.search-clear::before, .search-clear::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 18px;
  height: 3px;
  margin: -1.5px 0 0 -9px;
  background: currentColor;
  transform: rotate(45deg);
}
.search-clear::after { transform: rotate(-45deg); }
.search-clear:hover { color: var(--pink); }
.search-clear:focus-visible { outline: 3px solid var(--lime); outline-offset: -4px; }

.filters-bar { margin-top: 22px; }
.filters-label {
  margin: 0 0 10px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}
.filters {
  display: flex;
  flex-wrap: nowrap;
  gap: 10px;
  overflow-x: auto;
  margin: 0 calc(var(--gutter) * -1);
  padding: 6px var(--gutter) 14px;
  scrollbar-width: thin;
  scrollbar-color: var(--line) transparent;
}
.filter {
  --f: var(--muted);
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 8px 16px 8px 12px;
  border: 2px solid var(--line);
  border-radius: 6px;
  background: var(--panel-2);
  color: var(--ink);
  font-family: var(--font-body);
  font-stretch: 75%;
  font-weight: 750;
  font-size: 0.95rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  white-space: nowrap;
  cursor: pointer;
  transition: transform 0.15s ease, background-color 0.15s, border-color 0.15s, box-shadow 0.15s;
}
.filter::before {
  content: "";
  flex: none;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--f);
  box-shadow: inset 0 0 0 2px rgba(10, 10, 11, 0.35);
}
.filter.filter-all { --f: var(--ink); }
.filter.f0, .filter.f4 { --f: var(--lime); }
.filter.f1, .filter.f3 { --f: var(--pink); }
.filter.f2 { --f: var(--bone); }
.filter:hover { border-color: var(--f); transform: rotate(-1.5deg); }
.filter[aria-pressed="true"] {
  background: var(--f);
  border-color: var(--f);
  color: var(--bg);
  transform: rotate(-2.5deg);
  box-shadow: 4px 4px 0 var(--ink);
}
.filter[aria-pressed="true"]::before { background: var(--bg); box-shadow: none; }

/* Day bar */
.day-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 16px;
  margin-top: 24px;
  padding: 12px 12px 12px 18px;
  background: var(--lime);
  color: var(--bg);
  scroll-margin-top: 16px;
}
.day-bar-text {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 1.7rem;
  line-height: 1;
  text-transform: uppercase;
}
.day-bar .btn-secondary { background: var(--bg); border-color: var(--bg); color: var(--lime); }
.day-bar .btn-secondary:hover { background: var(--panel-2); }
.day-bar .btn:focus-visible { outline-color: var(--bg); }

/* Status */
.status {
  margin: 40px 0;
  padding: 40px 20px;
  text-align: center;
  border: 2px dashed var(--line);
  color: var(--muted);
}
.status strong {
  display: block;
  margin-bottom: 8px;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(2rem, 6vw, 3.4rem);
  line-height: 0.95;
  text-transform: uppercase;
  color: var(--ink);
}
.status span { display: block; max-width: 34em; margin: 0 auto; }
.status .btn { margin-top: 18px; }
.status:not(:has(span)) strong { animation: flicker 1.4s ease-in-out infinite; color: var(--lime); }
@keyframes flicker { 50% { opacity: 0.35; } }

.notice {
  margin: 16px 0 0;
  padding: 10px 14px;
  border: 1.5px solid var(--pink);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 0.85rem;
}

/* Month sections */
.month { margin-top: 56px; }
.month-title {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0 0.18em;
  margin: 0 0 22px;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(4rem, 17vw, 12rem);
  line-height: 0.8;
  letter-spacing: -0.01em;
  text-transform: uppercase;
}
.month-year {
  font-size: 0.42em;
  color: transparent;
  -webkit-text-stroke: 2px var(--lime);
  letter-spacing: 0.02em;
}

/* Poster wall */
.list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.card {
  position: relative;
  isolation: isolate;
  aspect-ratio: 3 / 4;
  background: var(--tone);
  transition: transform 0.22s cubic-bezier(.2, .8, .3, 1.2), box-shadow 0.22s ease;
}
.card .cover {
  position: absolute;
  inset: 0;
  overflow: hidden;
  isolation: isolate;
  background: var(--tone);
}
.card .cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(1) contrast(1.3) brightness(1.08);
  mix-blend-mode: multiply;
  transition: filter 0.3s ease, transform 0.4s ease;
}
.card .cover-fallback { font-size: clamp(3.6rem, 9vw, 6rem); }
.card-body {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 10px;
  background: linear-gradient(0deg, rgba(10, 10, 11, 0.97) 0%, rgba(10, 10, 11, 0.9) 34%, rgba(10, 10, 11, 0.35) 58%, rgba(10, 10, 11, 0) 72%);
}
.flyer-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 6px;
}
.flyer-top .badges { justify-content: flex-end; }
/* on the wall the date already says it: keep only Oggi / Domani / Concluso */
.flyer-top .badge-week { display: none; }
.date {
  flex: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 52px;
  padding: 5px 6px 6px;
  background: var(--bg);
  color: var(--ink);
  line-height: 1;
  transform: rotate(-4deg);
  box-shadow: 3px 3px 0 var(--tone-alt);
}
.date .dow, .date .mon {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.date .day {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 2.3rem;
  line-height: 0.9;
  color: var(--tone);
  margin: 1px 0 2px;
}
.flyer-bottom { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.flyer-bottom .tags { display: none; }
.card h3 { margin: 0; }
.flyer-open {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
  overflow: hidden;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.2rem;
  line-height: 0.98;
  text-align: left;
  text-transform: uppercase;
  cursor: pointer;
}
.flyer-open::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
}
.flyer-open:focus-visible { outline: none; }
.card:has(.flyer-open:focus-visible) { outline: 3px solid var(--ink); outline-offset: 4px; }
.flyer-meta {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  line-height: 1.3;
  color: var(--muted);
  overflow: hidden;
}
.flyer-meta.is-tbd { color: var(--pink); }

.card:hover, .card:has(.flyer-open:focus-visible) {
  transform: translate(-4px, -4px) rotate(-1.2deg);
  box-shadow: 8px 8px 0 var(--tone-alt);
  z-index: 3;
}
.list > .card:nth-child(even):hover,
.list > .card:nth-child(even):has(.flyer-open:focus-visible) {
  transform: translate(-4px, -4px) rotate(1.2deg);
}
.card:hover .cover img, .card:has(.flyer-open:focus-visible) .cover img {
  filter: none;
  mix-blend-mode: normal;
  transform: scale(1.04);
}
.card.is-today { box-shadow: 6px 6px 0 var(--pink); }
.card.is-past .flyer-open { color: #d8d3ca; }
.card.is-past .date { box-shadow: none; }
.card.is-past .cover img { filter: grayscale(1) contrast(1.1) brightness(0.9); }

/* Detail sheet */
.sheet {
  position: fixed;
  inset: auto 0 0 0;
  width: 100%;
  max-width: 100%;
  height: auto;
  max-height: 92dvh;
  margin: 0;
  padding: 0;
  border: 0;
  border-top: 4px solid var(--tone, var(--lime));
  background: var(--bg);
  color: var(--ink);
  overflow: hidden;
}
.sheet[open] { display: flex; flex-direction: column; animation: sheet-up 0.32s cubic-bezier(.2, .8, .3, 1); }
.sheet::backdrop {
  background:
    radial-gradient(circle, rgba(200, 255, 26, 0.12) 1.2px, transparent 1.6px) 0 0 / 8px 8px,
    rgba(10, 10, 11, 0.82);
}
.sheet-inner {
  position: relative;
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.sheet-close {
  position: sticky;
  top: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 -48px auto;
  min-height: 48px;
  padding: 0 16px;
  border: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
}
.sheet-close::after {
  content: "";
  width: 16px;
  height: 16px;
  background:
    linear-gradient(45deg, transparent 43%, currentColor 43%, currentColor 57%, transparent 57%),
    linear-gradient(-45deg, transparent 43%, currentColor 43%, currentColor 57%, transparent 57%);
}
.sheet-close:hover { background: var(--pink); color: var(--bg); }
.sheet-close:focus-visible { outline-offset: -5px; }
.sheet .cover {
  display: flex;
  justify-content: center;
  max-height: min(56vh, 520px);
  background: var(--tone);
  overflow: hidden;
}
.sheet .cover.is-fallback { aspect-ratio: 16 / 9; }
.sheet .cover img { width: auto; max-width: 100%; height: auto; max-height: min(56vh, 520px); object-fit: contain; }
.sheet-body {
  display: grid;
  gap: 14px;
  padding: 0 20px 28px;
}
.sheet-stamp {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  margin-top: -36px;
  position: relative;
}
.date.date-xl {
  min-width: 84px;
  padding: 8px 10px 10px;
  border: 2px solid var(--tone);
  box-shadow: 5px 5px 0 var(--tone);
}
.date.date-xl .day { font-size: 3.8rem; }
.date.date-xl .dow, .date.date-xl .mon { font-size: 0.75rem; }
.sheet-stamp .badges { padding-bottom: 6px; }
.sheet h2 {
  margin: 4px 0 0;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(2.2rem, 7vw, 3.4rem);
  line-height: 0.92;
  text-transform: uppercase;
}
.sheet .when {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.95rem;
  color: var(--lime);
}
.sheet.is-past .when { color: var(--muted); }
.sheet-desc { display: grid; gap: 8px; color: var(--muted); font-size: 0.95rem; }
.sheet-desc:empty { display: none; }
.sheet-desc p { margin: 0; }
.sheet-desc ul, .sheet-desc ol { margin: 0; padding-left: 1.2em; display: grid; gap: 4px; }
.sheet-desc strong { color: var(--ink); font-weight: 700; }
.sheet-desc a { color: inherit; text-decoration: underline; text-underline-offset: 2px; overflow-wrap: anywhere; }
.sheet-desc a:hover { color: var(--lime); }
.sheet-desc.is-clamped {
  max-height: 300px;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(#000 55%, transparent);
          mask-image: linear-gradient(#000 55%, transparent);
}
.desc-more { justify-self: start; align-self: flex-start; margin: -2px 0 14px; }
.ev-info .sheet-desc.is-clamped { margin-bottom: 4px; }
.sheet-link { border-top: 1px solid var(--line); padding-top: 12px; }
.sheet-link:empty { display: none; }
.sheet-loading {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--muted);
}
.sheet .actions .btn { flex: 1 1 160px; }
.sheet-more { margin-top: 26px; padding-top: 18px; border-top: 1px solid var(--line); }
.sheet-more-title {
  margin: 14px 0 6px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.sheet-more-title:first-child { margin-top: 0; }
.sheet-more-list { max-height: none; }
.sheet-cal {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0 10px;
  margin: 14px 0 0;
}
.sheet-cal-label {
  flex-basis: 100%;
  margin-right: 4px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

@keyframes sheet-up { from { transform: translateY(40px); opacity: 0; } }
@keyframes sheet-in { from { transform: translateX(60px); opacity: 0; } }

/* Mini calendar (inside the day panel) */
.minical {
  display: grid;
  grid-template-columns: 44px 1fr 44px;
  align-items: start;
}
.mc-months {
  grid-column: 1 / -1;
  grid-row: 1;
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  min-width: 0;
}
.mc-month:nth-child(2) { display: none; }
.mc-nav {
  grid-row: 1;
  z-index: 1;
  width: 44px;
  height: 44px;
  border: 2px solid var(--line);
  background: var(--bg);
  color: var(--ink);
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
}
.mc-nav:hover { border-color: var(--lime); color: var(--lime); }
.mc-prev { grid-column: 1; }
.mc-next { grid-column: 3; }
.mc-title {
  margin: 0 0 8px;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 1.7rem;
  line-height: 1;
  text-transform: uppercase;
}
.mc-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 3px;
}
.mc-dow {
  text-align: center;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--muted);
  padding-bottom: 4px;
}
.mc-day, .mc-pad { min-height: 44px; }
.mc-day {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 2px 0;
  border: 2px solid transparent;
  background: transparent;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 0.85rem;
}
.mc-day.is-past { opacity: 0.45; }
.mc-day.is-today { border-color: var(--pink); color: var(--ink); opacity: 1; }
button.mc-day {
  cursor: pointer;
  background: var(--panel-2);
  color: var(--ink);
  font-weight: 700;
}
button.mc-day.is-past { opacity: 0.75; color: var(--muted); }
button.mc-day:hover { border-color: var(--lime); }
button.mc-day.is-today:hover { border-color: var(--pink); }
button.mc-day[aria-pressed="true"] { background: var(--lime); border-color: var(--lime); color: var(--bg); opacity: 1; }
.mc-dots { display: flex; gap: 3px; height: 5px; }
.mc-dot { width: 5px; height: 5px; background: var(--lime); }
.mc-dot.d0, .mc-dot.d4 { background: var(--lime); }
.mc-dot.d1, .mc-dot.d3 { background: var(--pink); }
.mc-dot.d2 { background: var(--bone); }
button.mc-day[aria-pressed="true"] .mc-dot { background: var(--bg); }

/* About, FAQ and the list of upcoming evenings (text version of the calendar, also read by crawlers) */
.about { margin-top: 96px; padding-top: 56px; border-top: 2px dashed var(--line); }
.about-title {
  margin: 0 0 12px;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(2.2rem, 7vw, 4rem);
  line-height: 0.9;
  text-transform: uppercase;
}
.about-lead { margin: 0 0 28px; max-width: 60ch; color: var(--muted); font-size: 1.05rem; }
.about-sub {
  margin: 40px 0 12px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.about a:not(.chip):not(.link-button) { color: var(--ink); text-decoration-color: var(--lime); text-underline-offset: 3px; }
.about a:not(.chip):not(.link-button):hover { color: var(--lime); }
.faq { display: grid; gap: 16px; margin-bottom: 72px; }
.faq-item {
  padding: 20px 20px 22px;
  border: 2px solid var(--line);
  background: var(--panel);
  box-shadow: 6px 6px 0 var(--line);
}
.faq-item:nth-child(odd) { border-left-color: var(--lime); }
.faq-item:nth-child(even) { border-left-color: var(--pink); }
.faq-q {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin: 0 0 10px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.6rem;
  line-height: 1;
  text-transform: uppercase;
}
.faq-n { font-family: var(--font-mono); font-size: 0.8rem; font-weight: 700; color: var(--pink); }
.faq-item:nth-child(even) .faq-n { color: var(--lime); }
.faq-a { margin: 0; max-width: 56ch; color: var(--muted); }
.up-list { display: grid; gap: 0 48px; margin: 0; padding: 0; list-style: none; }
.up-row {
  display: grid;
  grid-template-columns: 10.5rem minmax(0, 1fr);
  gap: 14px;
  align-items: baseline;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}
.up-when {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--lime);
}
.up-title { color: var(--ink); font-weight: 700; text-decoration: none; }
.up-title:hover, .up-title:focus-visible { color: var(--lime); text-decoration: underline; text-decoration-color: var(--lime); text-underline-offset: 3px; }
.up-meta { margin: 2px 0 0; font-size: 0.88rem; color: var(--muted); }
.up-meta a { color: var(--muted); text-decoration-color: var(--pink); text-underline-offset: 3px; }
.up-meta a:hover { color: var(--pink); }
.up-coms { margin-bottom: 8px; }
.up-coms .chip { text-decoration: none; }
.up-more { display: flex; flex-wrap: wrap; gap: 4px 20px; margin: 18px 0 0; }
.up-more .link-button { min-height: 44px; display: inline-flex; align-items: center; }
@media (min-width: 720px) {
  .faq { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
}
@media (min-width: 1000px) {
  .up-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 479px) {
  .up-row { grid-template-columns: 1fr; gap: 2px; }
  .faq-item { box-shadow: 4px 4px 0 var(--line); }
}

/* Footer */
.site-footer {
  margin-top: 96px;
  padding: 40px 0 48px;
  border-top: 2px solid var(--ink);
  color: var(--muted);
  font-size: 0.95rem;
}
.footer-grid { display: grid; gap: 24px; }
.footer-copy p { margin: 0 0 8px; max-width: 32em; }
.footer-copy a { color: var(--ink); text-decoration-color: var(--lime); text-underline-offset: 3px; }
.footer-join { margin: 0; }
.footer-join .tg-link { min-height: 44px; }
.footer-small { font-family: var(--font-mono); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.04em; }

/* Telegram invite and RSS feed: quiet text links with an icon, never a primary action */
.tg-link, .rss-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-stretch: 80%;
  font-weight: 750;
  font-size: 0.875rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--lime);
  text-underline-offset: 4px;
}
.tg-link svg, .rss-link svg { flex: none; }
.tg-link:hover, .rss-link:hover { color: var(--lime); }
.hero-actions .tg-link, .hero-actions .rss-link, .ev-join .tg-link { min-height: 44px; }
.ev-join { margin: 14px 0 0; }

/* Screen-reader only text */
.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  margin: -1px !important;
  padding: 0 !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* View switch: posters / list / map */
.view-switch {
  display: inline-flex;
  margin-left: auto;
  border: 2px solid var(--ink);
}
.view-switch button {
  min-height: 44px;
  padding: 8px 14px;
  border: 0;
  background: transparent;
  color: var(--ink);
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
}
.view-switch button + button { border-left: 2px solid var(--ink); }
.view-switch button:hover { background: var(--panel-2); }
.view-switch button[aria-pressed="true"] { background: var(--ink); color: var(--bg); }
.view-switch button:focus-visible { outline-offset: -5px; outline-color: var(--pink); }

/* "Le mie": star instead of the dot */
.filter.filter-mine { --f: var(--pink); }
.filter.filter-mine::before {
  width: 13px;
  height: 13px;
  border-radius: 0;
  box-shadow: none;
  clip-path: polygon(50% 0, 62% 35%, 100% 38%, 70% 60%, 80% 98%, 50% 76%, 20% 98%, 30% 60%, 0 38%, 38% 35%);
}

.follow-panel {
  margin-top: 16px;
  padding: 18px;
  background: var(--panel);
  border: 2px solid var(--ink);
  box-shadow: 8px 8px 0 var(--pink);
}
.follow-title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 1.9rem;
  line-height: 1;
  text-transform: uppercase;
}
.follow-hint { margin: 6px 0 14px; color: var(--muted); font-size: 0.95rem; max-width: 40em; }
.follow-list { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 18px; }

/* Selected community: its calendar and its link */
.community-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 4px 18px;
  margin-top: 6px;
  padding: 6px 4px 6px 14px;
  border: 2px dashed var(--line);
}
.community-text {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}
.community-actions { display: flex; flex-wrap: wrap; gap: 0 6px; }
.link-button[hidden] { display: none; }

/* Compact list view */
.view-list .list {
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
  border-top: 2px solid var(--ink);
}
.view-list .card {
  aspect-ratio: auto;
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  align-items: center;
  background: transparent;
  border-bottom: 1px solid var(--line);
  transition: background-color 0.15s ease;
}
.view-list .card .cover {
  position: relative;
  inset: auto;
  width: 64px;
  height: 80px;
  margin: 10px 0;
}
.view-list .card .cover-fallback { font-size: 1.6rem; }
.view-list .card-body {
  position: static;
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  gap: 14px;
  padding: 10px 6px 10px 14px;
  background: none;
}
.view-list .flyer-top { flex: none; flex-direction: column; align-items: center; gap: 6px; }
.view-list .date { transform: none; box-shadow: none; min-width: 48px; padding: 4px 4px 5px; background: var(--panel-2); }
.view-list .date .day { font-size: 1.9rem; }
.view-list .flyer-top .badges { display: none; }
.view-list .flyer-bottom { flex: 1; gap: 5px; }
.view-list .flyer-bottom .tags { display: flex; order: 3; }
.view-list .flyer-open { font-size: 1.3rem; -webkit-line-clamp: 2; }
.view-list .card:hover,
.view-list .card:has(.flyer-open:focus-visible),
.view-list .list > .card:nth-child(even):hover,
.view-list .list > .card:nth-child(even):has(.flyer-open:focus-visible) {
  transform: none;
  box-shadow: none;
  background: var(--panel);
}
.view-list .card.is-today { background: rgba(255, 45, 135, 0.1); box-shadow: none; }
.view-list .card .cover img { filter: none; mix-blend-mode: normal; }
.view-list .card.is-past .cover img { filter: grayscale(1); }

/* Map view */
.map-view { margin-top: 28px; }
.map {
  position: relative;
  height: min(62vh, 560px);
  min-height: 340px;
  background: var(--panel);
  border: 2px solid var(--ink);
  box-shadow: 8px 8px 0 var(--lime);
}
.map-error { margin: 0; padding: 40px 20px; text-align: center; color: var(--muted); }
.map .leaflet-container, .map.leaflet-container { background: #111114; font-family: var(--font-body); }
/* OpenStreetMap tiles turned into a night print: inverted, no colour, low contrast */
.map .leaflet-tile-pane { filter: invert(1) grayscale(1) brightness(0.78) contrast(0.92); }
.leaflet-bar { border: 2px solid var(--ink) !important; border-radius: 0 !important; box-shadow: none !important; }
.leaflet-bar a, .leaflet-bar a:hover {
  width: 36px !important;
  height: 36px !important;
  line-height: 34px !important;
  border-radius: 0 !important;
  background: var(--bg) !important;
  color: var(--ink) !important;
  border-bottom-color: var(--line) !important;
}
.leaflet-bar a:hover { background: var(--ink) !important; color: var(--bg) !important; }
.leaflet-control-attribution {
  background: rgba(10, 10, 11, 0.85) !important;
  color: var(--muted) !important;
  font-family: var(--font-mono);
  font-size: 0.65rem !important;
}
.leaflet-control-attribution a { color: var(--ink) !important; }

.pin { background: none; border: 0; }
.pin span {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 32px;
  background: var(--tone, var(--lime));
  color: var(--bg);
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 1.35rem;
  line-height: 1;
  transform: rotate(-5deg);
  box-shadow: 0 8px 16px -6px rgba(0, 0, 0, 0.9), 0 0 0 2px var(--bg);
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.pin span::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -7px;
  width: 0;
  height: 0;
  margin-left: -7px;
  border: 7px solid transparent;
  border-bottom: 0;
  border-top-color: var(--tone, var(--lime));
}
.pin:hover span, .pin:focus-visible span { transform: rotate(0deg) scale(1.15); }

.pop-wrap .leaflet-popup-content-wrapper {
  border: 2px solid var(--ink);
  border-radius: 0;
  background: var(--bg);
  color: var(--ink);
  box-shadow: 8px 8px 0 var(--pink);
}
.pop-wrap .leaflet-popup-tip { background: var(--ink); box-shadow: none; }
.pop-wrap .leaflet-popup-content { margin: 14px 16px 12px; font-family: var(--font-body); font-size: 0.95rem; line-height: 1.35; }
.pop-wrap a.leaflet-popup-close-button { color: var(--ink); font-size: 20px; width: 28px; height: 28px; }
.pop-place {
  margin: 0 22px 8px 0 !important;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 1.45rem;
  line-height: 0.95;
  text-transform: uppercase;
}
/* the page breaks long words anywhere; inside the popup words stay whole */
.pop { width: min(270px, 68vw); overflow-wrap: break-word; word-break: normal; }
.pop-list { display: grid; gap: 2px; margin: 0; padding: 0; list-style: none; max-height: 220px; overflow-y: auto; }
.pop-ev {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: baseline;
  width: 100%;
  min-height: 40px;
  padding: 8px 0;
  border: 0;
  border-top: 1px solid var(--line);
  background: none;
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.pop-ev b { font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.04em; text-transform: uppercase; color: var(--lime); white-space: nowrap; }
.pop-ev:hover span, .pop-ev:focus-visible span { color: var(--lime); text-decoration: underline; text-underline-offset: 3px; }

.pin-cluster span { width: 46px; height: 40px; font-size: 1.55rem; background: var(--ink); }
.pin-cluster span::after { border-top-color: var(--ink); }
.pin-cluster span::before {
  content: "";
  position: absolute;
  inset: -5px;
  border: 2px dashed var(--lime);
  pointer-events: none;
}
.leaflet-cluster-anim .leaflet-marker-icon, .leaflet-cluster-anim .leaflet-marker-shadow {
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease-in;
}
.leaflet-oldie .marker-cluster { background: none; }

.map-list {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  margin: 26px 0 0;
  padding: 0;
  list-style: none;
}
.map-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  grid-template-areas: "count name" "count next";
  gap: 0 14px;
  align-items: center;
  width: 100%;
  min-height: 56px;
  padding: 8px 12px 8px 8px;
  border: 2px solid var(--line);
  background: var(--panel);
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  transition: border-color 0.15s ease, transform 0.15s ease;
}
.map-item:hover { border-color: var(--lime); transform: translateX(3px); }
.map-count {
  grid-area: count;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  background: var(--lime);
  color: var(--bg);
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 1.5rem;
}
.map-name { grid-area: name; font-weight: 700; line-height: 1.2; }
.map-next { grid-area: next; font-family: var(--font-mono); font-size: 0.75rem; text-transform: uppercase; color: var(--muted); }
.map-tbd { padding: 10px 2px; font-family: var(--font-mono); font-size: 0.8rem; color: var(--muted); }

/* Archive: past evenings, collapsed */
.archive { margin-top: 80px; }
.archive-toggle {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px 18px;
  width: 100%;
  padding: 20px 4px;
  border: 0;
  border-top: 2px solid var(--ink);
  border-bottom: 2px solid var(--ink);
  background: none;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}
.archive-title {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(2.6rem, 9vw, 6rem);
  line-height: 0.82;
  text-transform: uppercase;
  color: transparent;
  -webkit-text-stroke: 2px var(--ink);
  transition: color 0.2s ease;
}
.archive-toggle:hover .archive-title, .archive-toggle[aria-expanded="true"] .archive-title { color: var(--ink); }
.archive-stats {
  grid-column: 1;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.archive-chevron {
  grid-column: 2;
  grid-row: 1 / span 2;
  width: 22px;
  height: 22px;
  margin-right: 10px;
  border-right: 4px solid var(--lime);
  border-bottom: 4px solid var(--lime);
  transform: rotate(45deg) translate(-4px, -4px);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.archive-toggle[aria-expanded="true"] .archive-chevron { transform: rotate(-135deg) translate(-4px, -4px); }
.archive-toggle:focus-visible { outline-offset: 4px; }
.archive-toggle[aria-disabled="true"] { cursor: default; }
.archive-list .month:first-child { margin-top: 36px; }
.view-list .month-title { font-size: clamp(2.8rem, 9vw, 5.5rem); margin-bottom: 14px; }
.archive-list .month-title { font-size: clamp(3rem, 12vw, 8rem); }
.archive-list .month-name { color: var(--muted); }

/* Loading: poster-shaped placeholders */
.sk-title {
  display: block;
  width: min(70%, 640px);
  height: clamp(3.2rem, 13vw, 9.6rem);
  margin: 0 0 22px;
  background: var(--panel);
}
.sk-card {
  position: relative;
  aspect-ratio: 3 / 4;
  background: linear-gradient(100deg, var(--panel) 35%, var(--panel-2) 50%, var(--panel) 65%) 100% 0 / 300% 100%;
  animation: shimmer 1.6s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}
.sk-date { position: absolute; left: 10px; top: 10px; width: 52px; height: 62px; background: var(--bg); transform: rotate(-4deg); }
.sk-line { position: absolute; left: 10px; right: 28%; bottom: 36px; height: 16px; background: var(--line); }
.sk-line.short { right: 55%; bottom: 14px; height: 10px; }
@keyframes shimmer { to { background-position: 0 0; } }

/* Server-rendered pages: event, community, communities index */
.page-top { border-bottom: 2px solid var(--ink); }
.page-top-in {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 24px;
  padding-top: 14px;
  padding-bottom: 14px;
}
.page-mark {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 1.7rem;
  line-height: 1;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ink);
}
.page-mark .pm-tech { display: inline-block; padding: 0.06em 0.12em 0; background: var(--pink); color: var(--bg); transform: rotate(-2deg); }
.page-mark .pm-torino { color: transparent; -webkit-text-stroke: 1.2px var(--lime); }
.page-back {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--lime);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}
.page-back:hover { color: var(--lime); }

a.flyer-open { color: var(--ink); text-decoration: none; }
a.chip { text-decoration: none; transition: transform 0.15s ease; }
a.chip:hover { transform: rotate(-2deg); }
a.pop-ev { text-decoration: none; }
.ev-more-link { margin: 10px 0 0; }

.ev-page { padding-top: 32px; padding-bottom: 72px; }
.ev { display: grid; gap: 28px; }
.ev-poster .cover {
  position: relative;
  overflow: hidden;
  background: var(--tone);
  box-shadow: 10px 10px 0 var(--tone-alt, var(--pink));
  transform: rotate(-1.5deg);
}
.ev-poster .cover img { width: 100%; height: auto; }
.ev-poster .cover.is-fallback { aspect-ratio: 4 / 5; }
.ev-poster .cover-fallback { font-size: clamp(5rem, 22vw, 11rem); }
.ev-page.is-past .ev-poster .cover img { filter: grayscale(1); }
.ev-info { min-width: 0; }
.ev-info .sheet-stamp { margin-bottom: 14px; }
.ev-title {
  margin: 0 0 12px;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(2.6rem, 8vw, 5.2rem);
  line-height: 0.86;
  text-transform: uppercase;
  text-wrap: balance;
}
.ev-info .when { margin: 0 0 12px; font-family: var(--font-mono); color: var(--tone, var(--lime)); }
.ev-info .where { margin: 0 0 14px; }
.ev-info .tags { margin-bottom: 18px; }
.ev-info .sheet-desc { margin-bottom: 20px; max-width: 62ch; color: var(--ink); }
.ev-info .sheet-desc p { margin: 0 0 10px; }
.ev-info .actions .btn { flex: 1 1 180px; }
.ev-info > .actions { margin-bottom: 24px; }
.sheet-body > .actions { margin-bottom: 4px; }
.ev-more {
  display: grid;
  gap: 28px;
  margin-top: 48px;
  padding-top: 24px;
  border-top: 2px solid var(--ink);
}

.com-page { padding-top: 32px; padding-bottom: 72px; }
.com-head { padding-bottom: 8px; }
.com-title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(3.6rem, 15vw, 11rem);
  line-height: 0.8;
  text-transform: uppercase;
  text-wrap: balance;
}
.com-page.tone-0 .com-title, .com-page.tone-4 .com-title { -webkit-text-stroke: 0; }
.com-stats {
  margin: 18px 0 22px;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--tone, var(--lime));
}
.com-stats span { color: var(--muted); padding: 0 4px; }
.com-actions .btn { flex: 0 1 auto; }
.com-feed { margin: 8px 0 0; }
.com-feed .rss-link { min-height: 44px; }
.com-sub {
  margin: 64px 0 12px;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(2.2rem, 7vw, 4rem);
  line-height: 0.9;
  text-transform: uppercase;
}
.com-hint { margin: 0 0 12px; max-width: 60ch; color: var(--muted); }
.com-code {
  margin: 0 0 12px;
  padding: 14px 16px;
  overflow-x: auto;
  background: var(--panel);
  border: 2px solid var(--line);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.5;
  color: var(--lime);
  white-space: pre-wrap;
  word-break: break-all;
}
.com-past .pop-list { max-height: none; max-width: 760px; }
.com-list { margin-top: 32px; }
.com-item { text-decoration: none; }
.com-item .map-count { background: var(--tone, var(--lime)); }
.com-item.is-empty .map-count { background: var(--panel-2); color: var(--muted); }
.com-item.is-empty .map-name { color: var(--muted); }

.nf-page { padding-top: 48px; padding-bottom: 96px; }
.nf-code {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(8rem, 38vw, 22rem);
  line-height: 0.78;
  color: transparent;
  -webkit-text-stroke: 3px var(--pink);
}
.nf-title {
  margin: 18px 0 10px;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(2.4rem, 8vw, 4.6rem);
  line-height: 0.9;
  text-transform: uppercase;
}
.nf-text { margin: 0 0 24px; max-width: 46ch; color: var(--muted); font-size: 1.1rem; }


/* No poster: the community name, big, instead of two letters */
.cover-fallback.is-name {
  padding: 14px;
  font-size: clamp(2.2rem, 7vw, 4.4rem);
  line-height: 0.88;
  text-align: center;
  text-transform: uppercase;
  overflow-wrap: normal;
  word-break: normal;
  hyphens: auto;
}
.card .cover-fallback.is-name { font-size: clamp(1.5rem, 4.6vw, 2.6rem); align-items: flex-start; padding-top: 70px; }
.view-list .cover-fallback.is-name { font-size: 0.6rem; padding: 4px; align-items: center; }
.ev-poster .cover-fallback.is-name { font-size: clamp(3rem, 10vw, 6rem); }

/* Calendar subscription menu */
.cal-menu { position: relative; display: inline-block; }
.cal-menu > summary { list-style: none; cursor: pointer; }
.cal-menu > summary::-webkit-details-marker { display: none; }
.cal-menu > summary::after {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-left: 10px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-3px) rotate(45deg);
  transition: transform 0.2s ease;
}
.cal-menu[open] > summary::after { transform: translateY(1px) rotate(-135deg); }
.cal-pop {
  position: absolute;
  z-index: 20;
  top: calc(100% + 8px);
  left: 0;
  display: grid;
  min-width: 260px;
  padding: 6px;
  background: var(--bg);
  border: 2px solid var(--ink);
  box-shadow: 8px 8px 0 var(--lime);
}
.cal-opt {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 12px;
  border: 0;
  background: none;
  color: var(--ink);
  font: 700 0.9rem/1.2 var(--font-body);
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}
.cal-opt + .cal-opt { border-top: 1px solid var(--line); }
.cal-opt:hover, .cal-opt:focus-visible { background: var(--ink); color: var(--bg); outline: none; }
.cal-menu-small .cal-pop { right: 0; left: auto; }

/* "Iscriviti" placeholder while the link loads */
.btn.is-pending { opacity: 0.35; pointer-events: none; animation: flicker 1.4s ease-in-out infinite; }

/* Archive cards: the section already says they are over */
.archive-list .badge-past { display: none; }

/* Touch targets */
.pop-ev { min-height: 44px; }
.leaflet-bar a, .leaflet-bar a:hover { width: 44px !important; height: 44px !important; line-height: 42px !important; }
.pop-wrap a.leaflet-popup-close-button { width: 44px; height: 44px; font-size: 24px; line-height: 44px; }
.page-back, .footer-small a { display: inline-flex; align-items: center; min-height: 44px; }

.map-empty {
  position: absolute;
  z-index: 500;
  left: 50%;
  top: 50%;
  margin: 0;
  padding: 10px 14px;
  transform: translate(-50%, -50%);
  background: var(--bg);
  border: 2px solid var(--ink);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  text-align: center;
  pointer-events: none;
}
a.chip { min-height: 44px; padding-top: 0; padding-bottom: 0; display: inline-flex; align-items: center; }
.com-embed-sum, .page-mark { display: inline-flex; align-items: center; min-height: 44px; }
.com-embed-sum { cursor: pointer; font-family: var(--font-mono); font-weight: 700; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.06em; }

/* Phones: community on the card, lighter featured section, shorter map */
@media (max-width: 719px) {
  .flyer-bottom .tags { display: flex; }
  .flyer-bottom .tags li + li { display: none; }
  .flyer-bottom .chip { font-size: 0.62rem; padding: 2px 6px; }
  .featured-poster { display: none; }
  /* the chip row scrolls sideways: fade the right edge so it shows */
  .filters { -webkit-mask-image: linear-gradient(90deg, #000 85%, transparent); mask-image: linear-gradient(90deg, #000 85%, transparent); }
  .fd-day { font-size: 4.5rem; }
  .map { height: min(52vh, 560px); }
  .cal-pop { min-width: min(280px, calc(100vw - 2 * var(--gutter))); }
  /* event page opened from a shared link: one-line top bar, poster that leaves room for the title */
  .page-top-in { gap: 6px 12px; padding-top: 8px; padding-bottom: 8px; }
  .page-mark { font-size: 1.35rem; }
  .page-back { font-size: 0.72rem; white-space: nowrap; }
  .ev-page { padding-top: 22px; }
  .ev-poster { display: flex; justify-content: center; }
  .ev-poster .cover img { width: auto; max-width: 100%; max-height: 50vh; }
  .ev-poster .cover.is-fallback { width: min(100%, 40vh); }
  /* event page: register and share pinned to the bottom of the screen */
  .ev-info > .actions:has(.btn-primary) {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 40;
    flex-wrap: nowrap;
    padding: 10px var(--gutter) calc(10px + env(safe-area-inset-bottom, 0px));
    background: var(--bg);
    border-top: 2px solid var(--ink);
  }
  .ev-info > .actions:has(.btn-primary) .btn { flex: 1 1 0; min-width: 0; }
  .ev-info > .actions:has(.btn-primary) .btn-primary { flex-grow: 1.6; }
  .page-event:has(.ev-info > .actions .btn-primary) .site-footer { padding-bottom: calc(120px + env(safe-area-inset-bottom, 0px)); }
  /* the week strip is swiped: no scrollbar */
  .week-list { scrollbar-width: none; }
  .week-list::-webkit-scrollbar { display: none; }
}
/* Event page: the date stamp sits under the poster column, not over the header */
@media (min-width: 720px) {
  .ev-info .sheet-stamp { margin-top: 0; }
}
/* Tablet and up */
@media (min-width: 720px) {
  :root { --gutter: 28px; }
  /* the masthead is a block again, a little shorter: the week strip shows at the bottom of the first screen */
  .top { display: block; padding: 0; }
  .masthead { display: block; position: relative; z-index: 5; padding: 30px 0 32px; }
  .masthead::before { max-height: none; }
  .masthead-grid {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 44%);
    grid-template-areas: "title stack" "tagline stack" "copy stack" "actions stack";
    gap: 18px 40px;
  }
  .title, .tagline, .masthead-copy, .hero-actions { padding-left: 0; padding-right: 0; }
  .hero-stack { width: 100%; justify-self: end; }
  .stats { gap: 6px 22px; font-size: 0.8rem; }
  .title { align-self: end; }
  .title { font-size: clamp(3.4rem, 12.5vw, 10rem); }
  .week-in { padding-top: 24px; padding-bottom: 18px; }

  .week-list {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(170px, 264px);
    gap: 24px;
    margin: 0 -8px;
    padding: 24px 8px 26px;
    scroll-padding-left: 8px;
  }
  .week-list .card { max-width: none; }
  .list { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 26px 20px; }
  .card { aspect-ratio: 4 / 5; }
  .card-body { padding: 14px; }
  .flyer-bottom .tags { display: flex; }
  .flyer-open { font-size: 1.55rem; }
  .flyer-meta { font-size: 0.75rem; }
  .date { min-width: 60px; }
  .date .day { font-size: 2.8rem; }
  .filters { flex-wrap: wrap; overflow: visible; margin: 0; padding: 0; }
  .mc-months { grid-template-columns: 1fr 1fr; }
  .mc-month:nth-child(2) { display: block; }
  .day-panel { padding: 20px; }
  .sk-card { aspect-ratio: 4 / 5; }
  .ev { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: 56px; align-items: start; }
  .ev-poster { position: sticky; top: 24px; }
  .ev-more { grid-template-columns: 1fr 1fr; gap: 40px; }
  .map-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .sheet {
    inset: 0 0 0 auto;
    width: min(620px, 92vw);
    height: 100dvh;
    max-height: 100dvh;
    border-top: 0;
    border-left: 4px solid var(--tone, var(--lime));
  }
  .sheet[open] { animation-name: sheet-in; }
  .sheet-body { padding: 0 32px 40px; }
  .sheet-cal-label { flex-basis: auto; }
}

@media (min-width: 1000px) {
  /* the jump to next week goes up, on the heading's line */
  .week-more { position: absolute; top: 34px; right: var(--gutter); margin: 0; }
}

@media (min-width: 1200px) {
  .featured-inner {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
    align-items: center;
    gap: 56px;
    padding-top: 56px;
    padding-bottom: 64px;
    min-height: 560px;
  }
  .featured-poster { order: 2; transform: rotate(2deg); margin: 0 12px 12px 0; }
}

@media (min-width: 1200px) {
  :root { --gutter: 40px; }
  .map-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .list { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px 24px; }
  .masthead-grid { column-gap: 64px; }
  .controls {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    column-gap: 40px;
    align-items: start;
  }
  .controls-head { grid-column: 1 / -1; }
  .follow-panel, .community-bar { grid-column: 1 / -1; }
  .search-bar { grid-column: 1 / -1; grid-row: 2; width: 100%; }
  .filters-bar { grid-column: 1; grid-row: 3; }
  .day-panel { grid-column: 2; grid-row: 3; width: 720px; margin: 22px 8px 0 0; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
  .ticker-toggle { display: none; }
  .card:hover, .card:has(.flyer-open:focus-visible),
  .list > .card:nth-child(even):hover { transform: none; }
  .card:hover .cover img { transform: none; }
  .stack-flyer:hover, .stack-flyer:focus-visible { transform: none; }
}
