/* CENTRO look — Gancio 2 / Vuetify 3. !important is deliberate: /custom_css has
   to beat the bundled Vuetify CSS (see docs/usage/custom_css.md). Hooks used here
   exist in this checkout: nav#AppBar, #title, #navbar, footer#footer, .event,
   .event-title, #announcements .v-alert-title. */

/* CENTRO body font — stop `sans-serif` from ever being the effective value.
   Gancio ships no body webfont, so Vuetify's `font-family: "Roboto", sans-serif`
   (pinned on html and on all 78 .text-* typography classes) resolves to a
   font the visitor happens to have installed. Without Roboto the fallback lands on
   Noto Sans CJK / Noto Color Emoji — LibreWolf does exactly this — whose digit and
   space advances are far wider and whose digits are colour-bitmap glyphs. Naming
   installed families keeps normal font matching, so bold still finds a real bold.
   !important is required because /custom_css is served *before* Vuetify's own CSS and
   nothing here uses cascade layers. This block sits above the display-font rules so
   those keep winning the ties against .text-h* / .text-body-*. */
html,
.text-h1,
.text-h2,
.text-h3,
.text-h4,
.text-h5,
.text-h6,
.text-subtitle-1,
.text-subtitle-2,
.text-body-1,
.text-body-2,
.text-button,
.text-caption,
.text-overline,
.text-sm-h1,
.text-sm-h2,
.text-sm-h3,
.text-sm-h4,
.text-sm-h5,
.text-sm-h6,
.text-sm-subtitle-1,
.text-sm-subtitle-2,
.text-sm-body-1,
.text-sm-body-2,
.text-sm-button,
.text-sm-caption,
.text-sm-overline,
.text-md-h1,
.text-md-h2,
.text-md-h3,
.text-md-h4,
.text-md-h5,
.text-md-h6,
.text-md-subtitle-1,
.text-md-subtitle-2,
.text-md-body-1,
.text-md-body-2,
.text-md-button,
.text-md-caption,
.text-md-overline,
.text-lg-h1,
.text-lg-h2,
.text-lg-h3,
.text-lg-h4,
.text-lg-h5,
.text-lg-h6,
.text-lg-subtitle-1,
.text-lg-subtitle-2,
.text-lg-body-1,
.text-lg-body-2,
.text-lg-button,
.text-lg-caption,
.text-lg-overline,
.text-xl-h1,
.text-xl-h2,
.text-xl-h3,
.text-xl-h4,
.text-xl-h5,
.text-xl-h6,
.text-xl-subtitle-1,
.text-xl-subtitle-2,
.text-xl-body-1,
.text-xl-body-2,
.text-xl-button,
.text-xl-caption,
.text-xl-overline,
.text-xxl-h1,
.text-xxl-h2,
.text-xxl-h3,
.text-xxl-h4,
.text-xxl-h5,
.text-xxl-h6,
.text-xxl-subtitle-1,
.text-xxl-subtitle-2,
.text-xxl-body-1,
.text-xxl-body-2,
.text-xxl-button,
.text-xxl-caption,
.text-xxl-overline {
  font-family: Roboto, "DejaVu Sans", "Liberation Sans", "Noto Sans", Arial, sans-serif !important;
}

/* 1 ─ display font (file must be served by this instance, see notes) */
@font-face {
  font-family: 'centrofont';
  src: url('/gelinox.woff2') format('woff2');
  font-display: swap;
}
#title,
#announcements .v-alert-title,
.event-title,
#navbar,
.v-main h1, .v-main h2, .v-main h3 {
  font-family: 'centrofont', 'Roboto', sans-serif !important;
}
/* Whole UI, exactly like the live site (212 glyphs / 1 weight → busy for body text):
.v-application { font-family: 'centrofont', 'Roboto', sans-serif !important; } */

/* 2 ─ hero header */
nav#AppBar {
  background-size: 100% 300px !important;
}
.v-theme--light nav#AppBar {          /* live site paints the photo with no tint */
  background-image: url('/1.jpg') !important;
}
#title {
  font-size: 3rem !important;         /* live: 3rem mobile, 6rem desktop */
  font-weight: 600;
  word-break: normal !important;      /* live uses break-all; break-word is safer */
  overflow-wrap: break-word;
  color: rgb(var(--v-theme-primary));
}
@media (min-width: 1000px) { #title { font-size: 6rem !important; } }
.v-theme--light #title { text-shadow: 0 1px 10px rgba(255, 255, 255, .75); }
.v-theme--dark  #title { text-shadow: 0 1px 10px rgba(0, 0, 0, .85); }

/* 3 ─ orange band (live: .theme--light .v-footer { background: #f69704 }) */
footer#footer.v-footer { background-color: #f69704 !important; border-color: #f69704 !important; }
.v-theme--dark footer#footer.v-footer { background-color: #111 !important; border-color: #333 !important; }
.v-theme--dark #footer .v-btn { color: #f69704 !important; }

/* 4 ─ flat event cards (live: square, no shadow, 1px border, 3-line title) */
.event { background-color: #fbfbfb !important; border: 1px solid #e9e9e9 !important; border-radius: 0 !important; }
.v-theme--dark .event { background-color: #1e1e1e !important; border-color: #333 !important; }
.event .event-card { background: transparent; border: 0 !important; border-radius: 0 !important; box-shadow: none !important; flex: 1 1 auto; }
.event .event-title {
  font-size: 1.1em !important;
  line-height: 1.2em !important;
  margin: .5rem 1rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}
.event a { text-decoration: none; }
.event a:hover, .event a:focus { text-decoration: underline; }

/* 5 ─ small v1 details */
html { scrollbar-color: #ff4511 #111; scrollbar-width: thin; }
.v-application blockquote { font-style: italic; padding: 15px; }

/* Footer link bar on top (v1 look). .v-application__wrap is already a flex
   column (Vuetify VApp), so `order` raises #footer above the header with no DOM
   move. Do NOT relocate nodes with JS: a node pulled out of an element Vue is
   still hydrating is deleted by the mismatch handler — which is why the controls
   group in this bar is rendered by Core/Footer.vue instead of carried there at
   runtime. */
footer#footer { order: -1; padding: .4rem .75rem !important; gap: .25rem; }
footer#footer .v-btn { text-transform: none; font-size: .95rem; }

/* Application background */
.v-application,
body {
  background-color: #fa9800 !important;
}

/* Event description renders like a v-card */
.p-description {
  background-color: rgb(var(--v-theme-surface));
  color: rgba(var(--v-theme-on-surface), var(--v-high-emphasis-opacity));
  border-radius: 4px;
  padding: 1rem;
}

.v-theme--light .p-description {
  border: thin solid rgba(0, 0, 0, 0.12);
}

.v-theme--dark .p-description {
  border: thin solid #333;
}

/* scoped CSS already gives inner <p> a bottom margin: drop it on the last one
   so the padding isn't doubled */
.p-description > :last-child {
  margin-bottom: 0;
}
/* 6 ─ event detail: align description with the info card. The description carries
   Vuetify's `my-4` (margin-top: 16px !important) while the card has no margin, so
   the two boxes in the same row start 16px apart. 960px is Vuetify's md breakpoint,
   where md="8"/md="4" actually go side by side. :first-child limits this to events
   whose description tops the column, so a flyer above it keeps its 16px gap. */
@media (min-width: 960px) {
  .p-description:first-child {
    margin-top: 0 !important;
  }
}

/* 7 ─ no header search (the v1 site has none). Do NOT hide `#navsearch`: that wrapper also
   carries the collections buttons and the inline calendar. Vuetify renders id="main-search"
   on the inner <input>, so the thing to remove is the .v-input root that owns it. */
#navsearch .v-text-field,
#navsearch .v-input:has(#main-search) {
  display: none !important;
}

/* Only if the leftover gap bothers you: the emptied wrapper keeps Vuetify's own
   .mt-2 / .mt-sm-4 (8px / 16px), which are !important and survive at id level too.
#navsearch { margin-top: 0 !important; }
*/

/* CENTRO navbar — replaces the three stock buttons (add event / calendar / share)
   with the two links of the live site, /add and /participate.
   This file goes into Admin → Theme → custom_css, after the existing Centro rules.
   It replaces the old "#navbar .v-btn" chip block, which can be deleted:
     #navbar .v-btn { background-color / border-radius / font-size }
     @media (max-width: 999px) { #navbar .v-btn { font-size } }
     .v-theme--dark #navbar .v-btn { background-color }
   The two <a> elements are rendered by app/components/NavBar.vue, so they are in the
   server markup and need no gate class: the stock buttons are simply switched off
   here, and deleting the rule below brings them back.
   !important is deliberate: /custom_css is linked before Vuetify's bundle.
   Design measured from the v1 header tabs (.v-tab): #F8F8F8,
   24px / 500 / .089em uppercase, 48px high, square, inactive rgba(0,0,0,.54),
   active text = primary with a 2px bottom slider. */

#navbar .v-btn { display: none !important; }

#navbar { gap: 10px !important; }                /* the tabs touch each other */
@media (max-width: 999px) {
  #navbar { flex-direction: column; align-items: center; gap: 4px !important; }
}
@media (min-width: 1000px) {
  #navbar { justify-content: center !important; }   /* v1: v-tabs--centered */
}

.centro-nav-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: #f8f8f8 !important;
  color: rgba(0, 0, 0, .54) !important;
  border-radius: 0 !important;
  text-decoration: none !important;
  text-align: center;
}
.centro-nav-link:hover,
.centro-nav-link:focus { text-decoration: underline !important; }

@media (min-width: 1000px) {
  .centro-nav-link {
    height: 48px;
    min-width: 90px;
    max-width: 360px;
    padding: 0 16px;
    font-size: 24px !important;
    font-weight: 500;
    letter-spacing: .089em;
    text-transform: uppercase;
  }
  .centro-nav-link--active {
    color: rgb(var(--v-theme-primary)) !important;
    box-shadow: inset 0 -2px 0 currentColor;                  /* the v1 tabs slider */
  }
}

/* live mobile variant: 18px, not uppercased */
@media (max-width: 999px) {
  .centro-nav-link { font-size: 18px !important; padding: .25rem .5rem; }
  .centro-nav-link--active { color: rgb(var(--v-theme-primary)) !important; text-decoration: underline !important; }
}

/* the live site only ships its light theme; keep the chips usable in dark */
.v-theme--dark .centro-nav-link { background-color: rgba(30, 30, 30, .8) !important; color: hsla(0, 0, 100%, .7) !important; }
.v-theme--dark .centro-nav-link--active { color: #f69704 !important; }


/* CENTRO footer controls — the account and display controls (recurring switch, about,
   dark mode, language, account/login) that app/components/Core/Footer.vue renders in
   this bar, which the rule above raises to the top of the page. It goes at the end of
   Admin → Theme → custom_css, next to the CENTRO navbar rules.
   They used to live in NavHeader.vue and be carried into #footer > .v-spacer by a
   custom_js mover, which is what warned about a child-count mismatch on NavHeader's
   root. The markup is in the footer now, so both the mover and its harbour are gone:
   the group is a plain child of #footer, sitting after the <v-spacer /> that pushes it
   to the right, and .25rem matches the gap footer#footer already uses.
   THE TWO EXTRAS ARE HIDDEN, NOT REMOVED, and that is a real trade, not an
   oversight: the bar shows only theme + language + account, so the recurring-events
   switch (the repeat icon, home-only by design) and the about button are gone from
   the page entirely. About costs nothing — footerLinks already links /about, and
   hiding this copy cannot hide the footer's own link because the selector is scoped
   inside the group. The switch costs the filter itself: while hidden, nobody
   can toggle "show recurring events" (allow_recurrent_event is on, so it renders
   today on the home page). To bring it back, delete its line and nothing else.
   Colour: the dark theme is handled by `.v-theme--dark #footer .v-btn` above; the
   light theme has to be stated per button, otherwise the plain/text variants keep
   the header's on-surface colour and sit on the orange band as ghosts.
   Not measured on screen: no browser engine on this box, so treat the numbers below
   as a first pass to eyeball in the admin preview. */
footer#footer .centro-controls { flex: 0 0 auto; margin: 0; gap: .25rem; align-items: center; }
.v-theme--light footer#footer .centro-controls .v-btn { color: rgb(var(--v-theme-primary)) !important; }

/* extras the bar must not show. The switch's id lands on its inner <input>, not on
   the .v-switch wrapper, so the wrapper is matched by :has() — with a plain
   .v-footer .v-switch fallback for an engine without it (the footer holds no other
   switch, so the fallback cannot hide anything else). */
footer#footer #show_recurrent_switch,
footer#footer .v-switch,
footer#footer .centro-controls :has(#show_recurrent_switch),
footer#footer .centro-controls a[href="/about"] { display: none !important; }

/* CENTRO always light — the light/dark toggle is removed and the instance is
   pinned to light. Pairs with the always-light block at the end of custom_js, which is
   what makes the hiding safe: that block stamps .centro-light-forced on <html> only
   after it has actually forced light, and every rule here is scoped under it. So if the
   block ever fails — renamed Vuetify internals, a page that never hydrated, a script
   error before it ran — the button stays visible instead of removing the only exit from
   a dark theme that is still being shown. Hiding unconditionally is the trap this avoids.
   Which button: the toggle is the only control in the bar that carries a weather icon
   (the other mdi-weather user, the admin ThemeColorsPicker, is not in it), and the icon
   flips with the theme, so both names are matched. The recurring switch and about stay
   hidden by their own rules above.
   Colour rules keyed to .v-theme--dark elsewhere in this file are now dead code rather
   than wrong: nothing renders dark, so they simply stop matching. Nothing here restates
   them. Not measured on screen — no browser engine on this box. */
.centro-light-forced #footer .centro-controls .v-btn:has(.mdi-weather-sunny),
.centro-light-forced #footer .centro-controls .v-btn:has(.mdi-weather-night) { display: none !important; }

/* CENTRO header row — NavHeader's top row (app/components/NavHeader.vue, the root
   <div class="d-flex pa-3 pa-sm-4">) is a leftover: its controls group renders in the
   footer bar now, so the row only holds the logo button and the pa-3 / pa-sm-4 padding
   it adds above the title. Hiding the row takes the logo with it — that is the point.
   To keep the logo and lose only the padding, change the declaration to
   "padding: 0 !important".
   Vuetify ships .d-flex as display:flex !important, so only a higher-specificity
   !important wins: hence nav#AppBar (id) plus !important.
   Not measured on screen — no browser engine on this box. */
nav#AppBar > .d-flex.pa-3.pa-sm-4 { display: none !important; }

/* CENTRO hide location — the place page header, which the API strip cannot reach.
   Event location is no longer serialised by mapEvent(), so cards, the event page,
   the admin tables and every event list lost their location by themselves. The
   place page is the one surface that still asks for it: /api/events/place/:id
   returns the Place model next to the events, so the page renders the name and
   the address from that. Both are hidden here.
   The scoping matters: .text-underline is also the tag page and the collection
   page heading, and those must keep showing their own name. Only the place page
   puts an address <span class="text-subtitle"> immediately after the h1, so the
   :has() on that sibling is what separates it. Verified against the served markup
   of /tag/… and /place/… on this instance.
   The map rule is insurance, not a fix for something visible today: the map is
   behind settings.allow_geolocation, which is false on this instance, so nothing
   renders. If geolocation is ever switched on, the place page would grow a map
   and a "how to arrive" block right under the header hidden above — this catches
   it without touching the leaflet map any other page might show.
   display:none on nodes Vue owns is deliberate: nothing is removed or moved, so
   there is no child-count mismatch for the hydration patch to sweep away. */
#home h1.text-underline:has(+ span.text-subtitle),
#home h1.text-underline + span.text-subtitle {
  display: none !important;
}
#home h1.text-underline:has(+ span.text-subtitle) ~ div.position-relative:has(#leaflet-map) {
  display: none !important;
}

/* CENTRO info pages — the partner block to the CENTRO info pages heading in custom_js.
   That script stamps the event description's own two classes (p-description, text-body-1)
   onto the content of /about, /we, /history, /participate, /rooms and /imprint, so the card
   (background, border, radius, padding, text colour) and the typography stay defined once
   each: the .p-description rules and Vuetify's .text-body-1 above. Nothing here repeats a
   value they already own — that duplication is how the two definitions would drift apart.
   Only the two things a class stamp cannot produce:
   1. display:block. The info pages render their content in a <span>, and an inline box
      cannot carry a bordered, padded card: the background breaks at every line box and the
      left/right padding is ignored. On the event page the same content sits in a <div>,
      block by default, so this rule is what makes the two equal rather than decorating one.
   2. the paragraph rhythm. [slug].vue's `margin-bottom: .5lh` is inside that component's
      scoped stylesheet, compiled to `.p-description[data-v-…] p`, which no global selector
      can borrow. It is restated here with the same value, the same descendant scope, and a
      selector built to carry the same specificity as the scoped one (two classes plus one
      type), so the two pages resolve every tie the same way — including against the
      `.p-description > :last-child { margin-bottom: 0 }` rule above, which at one class
      plus one pseudo-class is the weaker of the three and so does not drop the trailing
      margin on a paragraph on either page. Same look, same unfinished edge; fixing that one
      would move the event description too, which was not asked for.
   No !important on purpose. /custom_css is linked before Vuetify's bundle, but Vuetify has
   no rule for a bare <p> or for the display of a span, and the scoped rule these replace is
   unimportant as well — matching the event page is the requirement, not outranking it.
   The centro-info-body gate keeps this off every other .p-description in the app, notably
   the admin Settings page (components/Core/Settings/Settings.vue), which is not an info
   page and was not asked to change. */
.p-description.centro-info-body {
  display: block;
}
.p-description.centro-info-body p {
  margin-bottom: .5lh;
}

/* CENTRO responsive — window-size adaptation, ported from the live site. Production groups all
   of its mobile rules in a single step (@media only screen and (max-width:999px), with
   (min-width:1000px) as the other side), and this file already uses that step for #title
   (3rem/6rem) and for the navbar tabs, so everything below uses it too: the page keeps one
   breakpoint, exactly like the live site.
   Selector differences between the two instances: production's event grid is `#events`, here it
   is `section.events` (app/assets/css/main.css). Production's announcement text is an <h3>
   inside .v-alert__content and inherits from it; here Announcement.vue passes the string through
   v-alert's :title, which renders .v-alert-title with its own font-size that inheritance from
   the content cannot reach — so both are stated.
   !important plus the #announcements / #home / .v-main prefixes are deliberate: /custom_css is
   linked before the Vuetify bundle, and that bundle ships its helpers as `.text-h4 { font-size:
   2.125rem !important }`, which an unimportant or equal-specificity earlier rule cannot beat.
   Not measured on screen — no browser engine on this box.

   Two production rules are deliberately NOT ported: .largeScreenOnly and .smallScreenOnly. On
   the live site they wrap the two navbar variants (v-tabs on desktop, one inline-styled 18px
   /add link on mobile). This instance already renders one navbar and switches it with the media
   queries under #navbar above, so those classes match nothing here — dead CSS is not
   parity. */
@media (max-width: 999px) {
  /* prod: #events { gap: 8px } — the card grid drops its 16px gutter on a narrow window. */
  .events { gap: 8px !important; }

  /* prod: .v-alert__content { font-size: 10pt } — the announcement strip above the grid. */
  #announcements .v-alert__content,
  #announcements .v-alert-title { font-size: 10pt !important; }

  /* prod: h2 { font-size: 1rem }. On the live site this lands on "past events" — its card
     titles are h2 as well, but .event .title outranks this rule there with !important, so they
     keep 1.1em. Here the card titles are h3 and already sized, so only the section headings
     move. Scoped to .v-main because Vuetify teleports dialogs and menus to <body>, and a bare
     element selector would follow them out of the page content. */
  .v-main h2 { font-size: 1rem !important; }

  /* NOT a port — a local gap that production does not have. Its tag/place heading is text-h4
     (2.125rem) at every width and text-h3 (3rem) appears only on the collection page; this
     checkout puts text-h3 on collections too and sets font-weight-black + text-uppercase on
     both, which overflows a phone. 1.5rem is the size the event page already uses for its own
     narrow headline (text-h5, stepping up to text-md-h4 at Vuetify's 960px), so this borrows
     the mobile step the app already ships instead of inventing a new one. Desktop is untouched:
     the rule stops at 999px. Vuetify's line-heights on these helpers are unitless, so they
     follow the new size on their own. */
  #home h1.text-h3,
  #home h1.text-h4 { font-size: 1.5rem !important; }
}

/* CENTRO calendar — mark the days that carry events. Vuetify's VCalendar renders every
   day label as a labs VIconBtn with `active: day.present`, and it only sets .v-present
   on days holding an event, so .v-icon-btn--active is exactly "this day has events".
   No other VIconBtn reaches this page (the only other producer is labs VVideo, unused
   here), so the selector needs no calendar scope.
   !important because the button is variant-outlined, which paints
   `background: transparent` at the same specificity, and /custom_css is served *before*
   Vuetify's own CSS. The day number keeps its text-surface-variant (#424242) foreground:
   that is 4.5:1 on this orange, where white would only reach 2.2:1. */
.v-icon-btn--active {
  background: #f69704 !important;
}
/** no custom.css file **/