/* ==========================================================================
   Event detail view — rendered inside index.php?page=event&id=…
   Category colour vars (--c / --tint) come from components/ev-categories.css
   via the .pb-evcat--<key> class on .pb-evd.
   ========================================================================== */

.pb-evd { display: flex; flex-direction: column; gap: 16px; min-width: 0; }

.pb-evd__back {
  align-self: flex-start; display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--pb-font-head); font-weight: 800; font-size: 14.5px; color: var(--pb-link);
}
.pb-evd__back:hover { color: var(--pb-link-hover); }
.pb-evd__back i { font-size: 12px; }

/* ── Hero ───────────────────────────────────────────────────────────────── */
.pb-evd__hero {
  position: relative; display: flex; align-items: flex-end; min-height: 220px; overflow: hidden;
  border-radius: var(--pb-r-xl); color: #fff;
  background: radial-gradient(circle at 75% 30%, #6b5a18 0, rgba(107, 90, 24, 0) 55%), linear-gradient(120deg, #22180a 0%, #3a2c0e 60%, #4b3b12 100%);
}
.pb-evd__hero.has-img { min-height: 280px; }
.pb-evd__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.pb-evd__hero.has-img::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(0deg, rgba(34, 24, 10, .92) 0%, rgba(34, 24, 10, .55) 50%, rgba(34, 24, 10, .1) 100%);
}
.pb-evd__paw { position: absolute; right: 24px; top: 20px; font-size: 96px; color: rgba(255, 255, 255, .08); transform: rotate(18deg); }
.pb-evd__heroin { position: relative; z-index: 1; width: 100%; padding: 22px 20px; }
.pb-evd__cat {
  display: inline-flex; align-items: center; gap: 7px; height: 28px; padding: 0 12px; border-radius: var(--pb-r-pill);
  background: var(--tint); color: var(--c); font-family: var(--pb-font-head); font-weight: 800; font-size: 12.5px; letter-spacing: .04em; text-transform: uppercase;
}
.pb-evd__cat i { font-size: 11px; }
.pb-evd__hero h1 {
  margin-top: 12px; font-family: var(--pb-font-head); font-weight: 900; font-size: 28px; line-height: 1.12; letter-spacing: -.01em; color: #fff;
  overflow-wrap: anywhere; text-wrap: balance;
}
.pb-evd__hero p { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin-top: 10px; font-size: 15px; line-height: 1.4; color: rgba(255, 255, 255, .92); }
.pb-evd__hero p i { font-size: 13px; color: var(--pb-amber); }
.pb-evd__dot { width: 4px; height: 4px; margin: 0 4px; border-radius: 50%; background: rgba(255, 255, 255, .55); }

/* ── Countdown ──────────────────────────────────────────────────────────── */
.pb-evd__count {
  padding: 18px 20px; border-radius: var(--pb-r-xl); text-align: center;
  background: linear-gradient(135deg, var(--pb-amber-soft) 0%, var(--pb-amber-tint) 100%); border: 1px solid var(--pb-border-3);
}
.pb-evd__countlbl { font-family: var(--pb-font-head); font-weight: 800; font-size: 12.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--pb-link); }
.pb-evd__countnums { display: flex; justify-content: center; gap: 12px; margin-top: 10px; }
.pb-evd__countnums[hidden], .pb-evd__countmsg[hidden] { display: none; }
.pb-evd__countnums > div {
  display: flex; flex-direction: column; align-items: center; min-width: 78px; padding: 10px 12px;
  border-radius: var(--pb-r-md); background: var(--pb-surface); box-shadow: var(--pb-shadow-card);
}
.pb-evd__countnums b { font-family: var(--pb-font-head); font-weight: 900; font-size: 30px; line-height: 1; color: var(--pb-text); font-variant-numeric: tabular-nums; }
.pb-evd__countnums span { margin-top: 4px; font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--pb-text-muted); }
.pb-evd__countmsg { margin-top: 8px; font-family: var(--pb-font-head); font-weight: 900; font-size: 22px; color: var(--pb-text); }

/* ── Info grid ──────────────────────────────────────────────────────────── */
.pb-evd__info { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.pb-evd__item {
  display: grid; grid-template-columns: 40px minmax(0, 1fr); grid-template-areas: "ico lbl" "ico val"; column-gap: 12px; align-items: center;
  padding: 14px; border: 1px solid var(--pb-border); border-radius: var(--pb-r-lg); background: var(--pb-surface); box-shadow: var(--pb-shadow-card);
}
.pb-evd__ico {
  grid-area: ico; display: flex; align-items: center; justify-content: center; width: 40px; height: 40px;
  border-radius: var(--pb-r-md); background: var(--tint); color: var(--c); font-size: 16px;
}
.pb-evd__lbl { grid-area: lbl; align-self: end; font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--pb-text-faint); }
.pb-evd__val { grid-area: val; align-self: start; font-family: var(--pb-font-head); font-weight: 800; font-size: 15.5px; line-height: 1.3; color: var(--pb-text); overflow-wrap: anywhere; }
.pb-evd__val.is-free { color: var(--pb-green); }
.pb-evd__val.is-paid { color: var(--pb-link); }

/* ── Actions ────────────────────────────────────────────────────────────── */
.pb-evd__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.pb-evd__actions .pb-btn { flex: 1 1 140px; height: 46px; border-radius: 23px; font-size: 15px; }
.pb-evd__register { flex-grow: 2; }

/* ── Sections ───────────────────────────────────────────────────────────── */
.pb-evd__sec { padding: 20px; }
.pb-evd__sec h2 { display: flex; align-items: center; gap: 10px; font-family: var(--pb-font-head); font-weight: 900; font-size: 19px; color: var(--pb-text); }
.pb-evd__sec h2 i { font-size: 15px; color: var(--c); }
.pb-evd__desc { margin-top: 12px; font-size: 16px; line-height: 1.65; color: var(--pb-text-2); white-space: pre-line; overflow-wrap: anywhere; }
.pb-evd__loc { margin-top: 12px; font-family: var(--pb-font-head); font-weight: 800; font-size: 16.5px; color: var(--pb-text); }
.pb-evd__addr { margin-top: 4px; font-size: 15px; line-height: 1.5; color: var(--pb-text-muted); overflow-wrap: anywhere; }

.pb-evd__org { display: flex; align-items: center; gap: 14px; margin-top: 14px; }
.pb-evd__orgav {
  flex: none; display: flex; align-items: center; justify-content: center; width: 52px; height: 52px; border-radius: 50%;
  background: var(--c); color: #fff; font-family: var(--pb-font-head); font-weight: 900; font-size: 22px;
}
.pb-evd__orgname { font-family: var(--pb-font-head); font-weight: 800; font-size: 16.5px; color: var(--pb-text); }
.pb-evd__orgline { display: flex; align-items: center; gap: 8px; margin-top: 4px; font-size: 14.5px; color: var(--pb-text-muted); overflow-wrap: anywhere; }
.pb-evd__orgline i { width: 14px; font-size: 12px; text-align: center; color: var(--pb-text-faint); }
a.pb-evd__orgline { color: var(--pb-link); }
a.pb-evd__orgline:hover { color: var(--pb-link-hover); text-decoration: none; }

.pb-evd__views { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 4px 0 8px; font-size: 13.5px; color: var(--pb-text-faint); }

/* ── Not found / no id ──────────────────────────────────────────────────── */
.pb-evd-missing { display: flex; flex-direction: column; align-items: center; gap: 14px; padding: 48px 20px; text-align: center; }
.pb-evd-missing > i { font-size: 44px; color: var(--pb-text-faint); }
.pb-evd-missing h1 { font-family: var(--pb-font-head); font-weight: 900; font-size: 22px; color: var(--pb-text); }

/* ── Wider screens ──────────────────────────────────────────────────────── */
@media (min-width: 700px) {
  .pb-evd__hero { min-height: 260px; }
  .pb-evd__hero.has-img { min-height: 340px; }
  .pb-evd__heroin { padding: 30px 32px; }
  .pb-evd__hero h1 { font-size: 38px; }
  .pb-evd__info { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pb-evd__sec { padding: 26px 28px; }
}

@media (max-width: 389px) {
  .pb-evd__countnums { gap: 8px; }
  .pb-evd__countnums > div { min-width: 68px; padding: 8px; }
  .pb-evd__info { grid-template-columns: minmax(0, 1fr); }
}
