/* css/town.css: Town's own pieces, set as a newspaper's civic pages (Nov 14 2026): the
   section line under the floating bar, the figures row, reference rows with their
   checked-on date and source, the address page, the council and project pages. Tokens only;
   paper.css loads after this file, so rules that must beat it are scoped under
   html:root[data-look] .tab-town. */

/* the page's own sections: a ruled line of small caps on the paper, not a second glass bar */
.tab-town .town-sub { margin: 4px var(--gutter) 0; border-bottom: var(--rule-w) solid var(--rule-2); }
html:root[data-look] .tab-town .town-sub .chips {
  display: flex; flex-wrap: nowrap; gap: 0; overflow-x: auto; scrollbar-width: none; margin: 0; padding: 9px 0 8px;
  background: none; border: 0; border-radius: 0; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none;
}
.tab-town .town-sub .chips::-webkit-scrollbar { display: none; }
html:root[data-look] .tab-town .town-sub .chip {
  flex: none; padding: 3px 11px 2px; border: 0; border-radius: 0; background: none; white-space: nowrap;
  font: 700 10.5px/1.3 var(--f-ui); letter-spacing: .1em; text-transform: uppercase; color: var(--ink-2);
}
html:root[data-look] .tab-town .town-sub .chip:first-child { padding-left: 0; }
html:root[data-look] .tab-town .town-sub .chip + .chip { border-left: var(--rule-w) solid var(--rule); }
html:root[data-look] .tab-town .town-sub .chip.on { background: none; color: var(--accent); text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 4px; }

/* three figures, set like a paper's numbers box: big figure, small-caps label, column rules */
.tab-town .stat {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; margin: 14px 0 8px; padding: 10px 0;
  border-top: calc(var(--rule-w) * 2.5) solid var(--rule-2); border-bottom: var(--rule-w) solid var(--rule-2);
}
.tab-town .stat div { padding: 2px 8px; background: none; border-radius: 0; box-shadow: none; text-align: center; }
.tab-town .stat div + div { border-left: var(--rule-w) solid var(--rule); }
.tab-town .stat b {
  display: block; font-family: var(--f-head); font-weight: var(--head-w); font-size: calc(28px * var(--head-scale)); line-height: 1.05;
  letter-spacing: -.02em; color: var(--ink); font-variant-numeric: tabular-nums lining-nums;
}
.tab-town .stat span { display: block; margin-top: 5px; font: 600 9.5px/1.3 var(--f-ui); letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); }

/* a reference row: the fact, its checked-on date, its source, between hairlines */
.tab-town .refs { margin: 0 var(--gutter); display: flex; flex-direction: column; gap: 0; }
.tab-town .ref { padding: 13px 0 12px; background: none; border-radius: 0; box-shadow: none; border-bottom: var(--rule-w) solid var(--rule); }
.tab-town .ref:last-child { border-bottom: 0; }
.tab-town .ref .kicker { margin-bottom: 5px; }
.tab-town .ref .hed {
  margin: 0; font-family: var(--f-head); font-weight: var(--head-w); font-style: var(--head-style); text-transform: var(--head-tt);
  font-size: calc(18px * var(--head-scale)); line-height: 1.2; letter-spacing: var(--head-ls);
}
.tab-town .ref .hed a { color: inherit; }
.tab-town .ref .line { margin: 4px 0 0; font: 400 14.5px/1.45 var(--f-body); color: var(--ink-2); }
.tab-town .ref .who { margin: 4px 0 0; font: 700 10.5px/1.35 var(--f-ui); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); }
.tab-town .ref .lines { margin-top: 8px; }
.tab-town .ref .meta { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; margin-top: 8px; }
.tab-town .ref.issue .meta { justify-content: space-between; }

/* the checked-on date and the source, a quiet italic line */
.tab-town .srcstamp { display: inline-flex; flex-wrap: wrap; gap: 4px 8px; align-items: baseline; font: italic 400 12px/1.3 var(--f-body); letter-spacing: 0; text-transform: none; color: var(--ink-3); }
.tab-town .srcstamp .checked { text-transform: none; letter-spacing: 0; }
.tab-town .src { font: italic 400 12px/1.3 var(--f-body); letter-spacing: 0; text-transform: none; color: var(--ink-2); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 2px; overflow-wrap: anywhere; }
.tab-town .fact b { flex: 0 1 auto; min-width: 0; }
.tab-town .fact span { min-width: 0; overflow-wrap: anywhere; font-variant-numeric: tabular-nums; }
.tab-town .fact .srcstamp { display: flex; justify-content: flex-end; margin-top: 3px; max-width: 100%; }
.tab-town .fact.col { flex-direction: column; gap: 3px; }
.tab-town .fact.col span { text-align: left; }
.tab-town .fact.col .srcstamp, .tab-town .fact.col .checked { justify-content: flex-start; text-align: left; }
.tab-town .fact a { color: inherit; }
.tab-town .page .meta { margin: 8px 0 12px; display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; }

/* sections drawn inside a .page already sit in the gutter */
html:root[data-look] .tab-town .page .sec-h { margin-left: 0; margin-right: 0; }
.tab-town .page .sec .refs { margin: 0; }

/* the address page */
.tab-town .town-h {
  margin: 0; font-family: var(--f-head); font-weight: var(--head-w); font-style: var(--head-style); text-transform: var(--head-tt);
  font-size: calc(28px * var(--head-scale)); line-height: 1.05; letter-spacing: -.015em; color: var(--ink);
}
.tab-town .town-follow { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 16px 0 6px; }
.tab-town .town-last { font: italic 400 14px/1.3 var(--f-body); color: var(--ink-3); }
.tab-town .town-ban { margin: 14px 0; padding: 16px; border-radius: 0; }
.tab-town .town-ban .hed { font-family: var(--f-head); font-weight: var(--head-w); font-size: calc(22px * var(--head-scale)); line-height: 1.15; color: var(--paper); }
.tab-town .town-ban .line { color: var(--paper); opacity: .85; margin-top: 6px; }
.tab-town .town-address .sec { margin-top: 22px; }
.tab-town .town-address .sec .rows, .tab-town .town-address .sec .feedlist { margin: 0; }
.tab-town .town-address .pills { padding: 0; margin: 10px 0; gap: 6px; }
.tab-town .page .pills { padding: 0; }
.tab-town .page .btnrow { gap: 6px; }

/* the council and project pages */
.tab-town .town-top {
  margin: 6px 0 12px; font-family: var(--f-head); font-weight: var(--head-w); font-style: var(--head-style); text-transform: var(--head-tt);
  font-size: calc(24px * var(--head-scale)); line-height: 1.15; letter-spacing: var(--head-ls); color: var(--ink);
}
.tab-town .town-desc { margin: 8px 0 14px; font: 400 16px/1.5 var(--f-body); color: var(--ink-2); }
.tab-town .town-desc::first-letter { float: left; margin: 3px 6px 0 0; font: var(--head-w) 44px/.82 var(--f-head); color: var(--ink); }
.tab-town .town-project .hero-pic { margin-top: 0; }
.tab-town .town-council > .kicker { margin-top: 8px; }

/* the count card: its lines are rows, not pills */
.tab-town .card .lines.rows { display: block; }
.tab-town .card .lines li { border-radius: 0; }

/* the new-here checklist */
.tab-town .facts .toggle { padding: 12px 0; border-bottom: var(--rule-w) solid var(--rule); }
.tab-town .facts .toggle:last-child { border-bottom: 0; }
.tab-town .facts .toggle a { color: inherit; }

@media (max-width: 360px) {
  .tab-town .stat b { font-size: 22px; }
}

/* a boxed notice after another card keeps its top rule (app.css drops it for the old look) */
html:root[data-look] .tab-town :is(.card.porch, .card.ev, .card.tonight, .card.game):not(.invite):not(.maple) { border-top: calc(var(--rule-w) * 1.5) solid var(--rule-2); }

/* the full paper (Nov 15 2026): the New here count */
.tab-town .town-done { margin: 4px 0 10px; font: 700 10.5px/1.2 var(--f-ui); letter-spacing: .12em; text-transform: uppercase; color: var(--accent); }

/* Church Street's camera at the top of Now (Nov 15): the picture full width, its label under it */
.tab-town .tn-cam { margin: 12px 0 0; }
.tab-town .tn-cam a { display: block; aspect-ratio: 16 / 9; overflow: hidden; background: var(--paper-2); }
.tab-town .tn-cam img { display: block; width: 100%; height: 100%; object-fit: cover; }
.tab-town .tn-cam figcaption { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; margin: 0 var(--gutter); padding: 7px 0 8px; border-bottom: var(--rule-w) solid var(--rule-2); font: 700 10px/1.3 var(--f-ui); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); }
.tab-town .tn-cam figcaption b { color: var(--ink); }
.tab-town .tn-cam figcaption span:nth-of-type(1) { color: var(--accent); }

/* ===================== mix4 (Nov 20): Town as a section of News's one long screen (town.js flowSection).
   The same pieces as Town Now, set the same way inside the News feed. */
html[data-flow] .tab-news .flsec .town-sub { margin: 4px var(--gutter) 0; border-bottom: var(--rule-w) solid var(--rule-2); }
html:root[data-look][data-flow] .tab-news .flsec .town-sub .chips {
  display: flex; flex-wrap: nowrap; gap: 0; overflow-x: auto; scrollbar-width: none; margin: 0; padding: 9px 0 8px;
  background: none; border: 0; border-radius: 0; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none;
}
html[data-flow] .tab-news .flsec .town-sub .chips::-webkit-scrollbar { display: none; }
html:root[data-look][data-flow] .tab-news .flsec .town-sub .chip {
  flex: none; padding: 3px 11px 2px; border: 0; border-radius: 0; background: none; white-space: nowrap;
  font: 700 10.5px/1.3 var(--f-ui); letter-spacing: .1em; text-transform: uppercase; color: var(--ink-2);
}
html:root[data-look][data-flow] .tab-news .flsec .town-sub .chip:first-child { padding-left: 0; }
html:root[data-look][data-flow] .tab-news .flsec .town-sub .chip + .chip { border-left: var(--rule-w) solid var(--rule); }
html:root[data-look][data-flow] .tab-news .flsec .town-sub .chip.on { background: none; color: var(--accent); text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 4px; }
html[data-flow] .tab-news .flsec .tn-cam { margin: 12px 0 0; }
html[data-flow] .tab-news .flsec .tn-cam a { display: block; aspect-ratio: 16 / 9; overflow: hidden; background: var(--paper-2); }
html[data-flow] .tab-news .flsec .tn-cam img { display: block; width: 100%; height: 100%; object-fit: cover; }
html[data-flow] .tab-news .flsec .tn-cam figcaption { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; margin: 0 var(--gutter); padding: 7px 0 8px; border-bottom: var(--rule-w) solid var(--rule-2); font: 700 10px/1.3 var(--f-ui); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); }
html[data-flow] .tab-news .flsec .tn-cam figcaption b { color: var(--ink); }
html[data-flow] .tab-news .flsec .tn-cam figcaption span:nth-of-type(1) { color: var(--accent); }
html[data-flow] .tab-news .flsec .ftiles:empty { display: none; }
