/* Portal Eventos CBMTO — design próprio (não depende do Bootstrap legado) */

:root {
  --ink: #141a24;
  --ink-soft: #3a4454;
  --paper: #f3f5f8;
  --paper-elevated: #ffffff;
  --line: rgba(20, 26, 36, 0.1);
  --accent: #c8102e;
  --accent-deep: #9a0c24;
  --gold: #b8953e;
  --hero-veil: linear-gradient(
    115deg,
    rgba(12, 16, 24, 0.88) 0%,
    rgba(12, 16, 24, 0.62) 48%,
    rgba(12, 16, 24, 0.45) 100%
  );
  --shadow-soft: 0 12px 32px rgba(20, 26, 36, 0.08);
  --radius: 14px;
  --font-display: "Barlow Condensed", "Arial Narrow", sans-serif;
  --font-body: "Figtree", "Segoe UI", sans-serif;
  --max: 1120px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.55;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
}

/* ── Hero ─────────────────────────────────────────────── */

.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  color: #fff;
  overflow: hidden;
}

.hero__media {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  transform: scale(1.06);
  animation: heroKen 28s var(--ease) infinite alternate;
}

@keyframes heroKen {
  from { transform: scale(1.06) translate3d(0, 0, 0); }
  to { transform: scale(1.12) translate3d(-1.5%, -1%, 0); }
}

.hero__veil {
  position: absolute;
  inset: 0;
  background: var(--hero-veil);
  z-index: 1;
}

.hero__veil::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 50% at 80% 20%, rgba(200, 16, 46, 0.22), transparent 55%),
    linear-gradient(to top, rgba(12, 16, 24, 0.55), transparent 35%);
}

.hero__inner {
  position: relative;
  z-index: 2;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: min(100% - 2rem, var(--max));
  margin: 0 auto;
  padding: 4.5rem 0 5rem;
}

.hero__brand {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
  opacity: 0;
  animation: rise 0.9s var(--ease) 0.1s forwards;
}

.hero__brand img {
  width: clamp(72px, 14vw, 110px);
  height: auto;
  filter: drop-shadow(0 8px 20px rgba(0, 0, 0, 0.35));
}

.hero__brand-text {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.hero__brand-text strong {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.6rem, 4vw, 2.35rem);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1;
}

.hero__brand-text span {
  font-size: 0.85rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.72);
}

.hero__title {
  margin: 0 0 0.85rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.4rem, 7vw, 4.4rem);
  line-height: 0.95;
  letter-spacing: 0.02em;
  max-width: 12ch;
  opacity: 0;
  animation: rise 0.9s var(--ease) 0.25s forwards;
}

.hero__lede {
  margin: 0 0 2rem;
  max-width: 34ch;
  font-size: clamp(1rem, 2.2vw, 1.2rem);
  color: rgba(255, 255, 255, 0.82);
  opacity: 0;
  animation: rise 0.9s var(--ease) 0.4s forwards;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  opacity: 0;
  animation: rise 0.9s var(--ease) 0.55s forwards;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 3rem;
  padding: 0 1.35rem;
  border-radius: 10px;
  border: 1px solid transparent;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.2s var(--ease), background 0.2s ease, border-color 0.2s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn--primary {
  background: var(--accent);
  color: #fff;
}

.btn--primary:hover {
  background: var(--accent-deep);
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.35);
  color: #fff;
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.55);
}

.hero__scroll {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  width: 1.5rem;
  height: 2.4rem;
  border: 1.5px solid rgba(255, 255, 255, 0.45);
  border-radius: 999px;
  opacity: 0;
  animation: rise 0.8s var(--ease) 0.8s forwards;
}

.hero__scroll span {
  display: block;
  width: 4px;
  height: 4px;
  margin: 0.45rem auto 0;
  border-radius: 50%;
  background: #fff;
  animation: scrollDot 1.6s ease-in-out infinite;
}

@keyframes scrollDot {
  0% { transform: translateY(0); opacity: 1; }
  100% { transform: translateY(12px); opacity: 0; }
}

@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  .hero__media img,
  .hero__brand,
  .hero__title,
  .hero__lede,
  .hero__actions,
  .hero__scroll,
  .hero__scroll span,
  .evento {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
}

/* ── Lista ────────────────────────────────────────────── */

.lista {
  padding: clamp(3rem, 8vw, 5rem) 0 4rem;
}

.lista__inner {
  width: min(100% - 2rem, var(--max));
  margin: 0 auto;
}

.lista__head {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.75rem;
}

.lista__eyebrow {
  margin: 0 0 0.35rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}

.lista__title {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 650;
  letter-spacing: 0.02em;
  line-height: 1;
  color: var(--ink);
}

.lista__count {
  font-size: 0.9rem;
  color: var(--ink-soft);
}

.eventos-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 640px) {
  .eventos-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 980px) {
  .eventos-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.15rem;
  }
}

.evento {
  display: none;
  flex-direction: column;
  height: 100%;
  text-decoration: none;
  background: var(--paper-elevated);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), border-color 0.25s ease;
}

.evento.is-visible {
  display: flex;
  animation: cardIn 0.45s var(--ease) both;
}

@keyframes cardIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

.evento:hover,
.evento:focus-visible {
  transform: translateY(-4px);
  border-color: rgba(200, 16, 46, 0.35);
  box-shadow: 0 18px 40px rgba(20, 26, 36, 0.12);
  outline: none;
}

.evento__thumb {
  aspect-ratio: 16 / 10;
  background: #dfe3ea center / cover no-repeat;
  position: relative;
}

.evento__thumb::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 40%;
  background: linear-gradient(to top, rgba(20, 26, 36, 0.35), transparent);
}

.evento__body {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  padding: 1rem 1.05rem 1.15rem;
  flex: 1;
}

.evento__data {
  font-size: 0.78rem;
  font-weight: 650;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent);
}

.evento__titulo {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.28rem;
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: 0.01em;
  color: var(--ink);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.evento__cta {
  margin-top: auto;
  padding-top: 0.65rem;
  font-size: 0.85rem;
  font-weight: 650;
  color: var(--ink-soft);
}

.evento:hover .evento__cta,
.evento:focus-visible .evento__cta {
  color: var(--accent);
}

.lista__empty {
  padding: 2.5rem 1.5rem;
  text-align: center;
  color: var(--ink-soft);
  background: var(--paper-elevated);
  border: 1px dashed var(--line);
  border-radius: var(--radius);
}

.paginacao {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.85rem;
  margin-top: 2rem;
}

.paginacao[hidden] {
  display: none !important;
}

.paginacao__btn {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--paper-elevated);
  color: var(--ink);
  font-size: 1rem;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.paginacao__btn:hover:not(:disabled) {
  border-color: rgba(200, 16, 46, 0.4);
  background: #fff;
}

.paginacao__btn:disabled {
  opacity: 0.35;
  cursor: default;
}

.paginacao__info {
  min-width: 5.5rem;
  text-align: center;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--ink-soft);
}

/* ── Rodapé ───────────────────────────────────────────── */

.rodape {
  border-top: 1px solid var(--line);
  background: #eef1f5;
  padding: 1.75rem 0 2rem;
}

.rodape__inner {
  width: min(100% - 2rem, var(--max));
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.rodape__brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--ink-soft);
  font-size: 0.88rem;
}

.rodape__brand img {
  width: 36px;
  height: auto;
}

.rodape__social {
  display: flex;
  gap: 0.5rem;
}

.rodape__social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  text-decoration: none;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.rodape__social a:hover {
  border-color: var(--accent);
  color: var(--accent);
}
