/* =============================================
   style-public.css — Identidade Visual Sinodal
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;600;700;800;900&family=Playfair+Display:wght@700;800&display=swap');

:root {
  --teal: #2ABFBF;
  --teal-dark: #1E9898;
  --teal-light: #5DD4D4;
  --lime: #BACE2A;
  --lime-dark: #9AAD1E;
  --white: #FFFFFF;
  --cream: #F7FAF7;
  --text: #1A2A2A;
  --text-muted: #5A7070;
  --card-bg: #FFFFFF;
  --shadow: 0 4px 24px rgba(42, 191, 191, .15);
  --shadow-hover: 0 12px 40px rgba(42, 191, 191, .28);
  --radius: 16px;
}

/* ══ BACK NAV ════════════════════════════════════════ */
.back-nav {
  position: fixed;
  top: 1.2rem;
  left: 1.4rem;
  z-index: 999;
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  background: rgba(10, 50, 50, 0.55);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .04em;
  padding: .45rem 1rem .45rem .8rem;
  border-radius: 50px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  transition: background .2s, color .2s, transform .2s;
  opacity: 0;
  animation: fadeUp .5s ease .1s both;
}

.back-nav:hover {
  background: rgba(42, 191, 191, 0.35);
  color: var(--white);
  transform: translateX(-2px);
}

.back-nav i {
  font-size: .78rem;
  opacity: .8;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Nunito', sans-serif;
  background: var(--cream);
  color: var(--text);
  overflow-x: hidden;
}

/* ══ HERO ════════════════════════════════════════════ */
.hero {
  position: relative;
  background: linear-gradient(160deg, #0a3232 0%, #135050 50%, #0a3232 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3.5rem 2rem 2.5rem;
  overflow: hidden;
  min-height: 100vh;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, rgba(42, 191, 191, .06) 0%, transparent 70%);
  pointer-events: none;
}

/* ── Stage: logos nas laterais + cartaz absoluto no centro ── */
.hero__stage {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 1200px;
  display: flex;
  margin-bottom: 30px;
  align-items: center;
  justify-content: space-between;
  padding: 0 3rem;
  animation: fadeUp .9s ease both;
  min-height: 360px;
}

/* Colunas laterais */
.hero__side {
  display: flex;
  align-items: center;
}

.hero__side--left {
  justify-content: flex-end;
  animation: slideInLeft .8s ease .2s both;
}

.hero__side--right {
  justify-content: flex-start;
  animation: slideInRight .8s ease .2s both;
}

.hero__side-logo {
  width: clamp(140px, 18vw, 220px);
  object-fit: contain;
  filter: drop-shadow(0 4px 20px rgba(0, 0, 0, .35));
  animation: fadeUp .9s .1s ease both;
}

/* Cartaz central — fixo no meio da stage via absolute */
.hero__center {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.hero__event-img {
  width: clamp(200px, 26vw, 340px);
  border-radius: 18px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, .55), 0 0 0 1px rgba(255, 255, 255, .08);
  display: block;
  animation: fadeUp .9s .05s ease both;
}

/* ── Texto abaixo do stage ──────────────────────────── */
.hero__footer-text {
  position: relative;
  z-index: 2;
  text-align: center;
  margin-top: 2.5rem;
  animation: fadeUp .9s .25s ease both;
}

.hero__title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.5rem, 3.5vw, 2.4rem);
  font-weight: 800;
  color: var(--white);
  line-height: 1.2;
  margin-bottom: .5rem;
}

.hero__title span {
  color: var(--lime);
}

.hero__subtitle {
  font-size: .95rem;
  color: rgba(255, 255, 255, .75);
  margin-bottom: 1.8rem;
}

.hero__scroll-btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  background: var(--lime);
  color: var(--text);
  font-weight: 800;
  font-size: .95rem;
  padding: .85rem 2rem;
  border-radius: 50px;
  text-decoration: none;
  transition: transform .2s, box-shadow .2s, background .2s;
}

.hero__scroll-btn:hover {
  background: var(--teal-light);
  color: var(--white);
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(42, 191, 191, .4);
}

/* Scroll indicator */
.hero__arrow {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  animation: bounce 2s infinite;
  color: rgba(255, 255, 255, .55);
  font-size: 1.5rem;
}

/* ══ RESPONSIVO MOBILE ═══════════════════════════════ */
@media (max-width: 680px) {
  .hero {
    padding: 2.5rem 1.2rem 2rem;
    min-height: auto;
  }

  /* Esconde as logos laterais no celular */
  .hero__side {
    display: none;
  }

  /* Stage vira coluna única com só o cartaz */
  .hero__stage {
    grid-template-columns: 1fr;
    gap: 0;
    justify-items: center;
  }

  .hero__event-img {
    width: min(85vw, 300px);
  }

  .hero__footer-text {
    margin-top: 1.8rem;
  }

  .hero__title {
    font-size: clamp(1.3rem, 6vw, 1.8rem);
  }
}

/* ══ SECTION NOTICIAS ════════════════════════════════ */
.section-noticias {
  padding: 5rem 1.5rem;
  max-width: 1100px;
  margin: 0 auto;
}

.section-header {
  text-align: center;
  margin-bottom: 3rem;
}

.section-header__tag {
  display: inline-block;
  background: var(--teal);
  color: var(--white);
  font-size: .8rem;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
  padding: .4rem 1.2rem;
  border-radius: 50px;
  margin-bottom: 1rem;
}

.section-header h2 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  color: var(--text);
  line-height: 1.2;
}

.section-header h2 span {
  color: var(--teal);
}

/* ══ NEWS GRID ═══════════════════════════════════════ */
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2rem;
}

.news-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform .3s, box-shadow .3s, opacity .55s ease;
  cursor: pointer;
  opacity: 0;
  transform: translateY(28px);
  transition: transform .3s, box-shadow .3s, opacity .55s ease, transform .55s ease;
}

.news-card.visible {
  opacity: 1;
  transform: translateY(0);
}

.news-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
}

/* Carousel */
.card-carousel {
  position: relative;
  height: 220px;
  overflow: hidden;
  background: #0d3d3d;
}

.card-carousel__slides {
  display: flex;
  height: 100%;
  transition: transform .4s ease;
}

.card-carousel__slide {
  min-width: 100%;
  height: 100%;
}

.card-carousel__slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.card-carousel__btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, .45);
  border: none;
  color: #fff;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .2s;
  z-index: 3;
}

.card-carousel__btn:hover {
  background: var(--teal);
}

.card-carousel__btn--prev {
  left: .6rem;
}

.card-carousel__btn--next {
  right: .6rem;
}

.card-carousel__dots {
  position: absolute;
  bottom: .5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: .35rem;
  z-index: 3;
}

.card-carousel__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .5);
  border: none;
  cursor: pointer;
  transition: background .2s, transform .2s;
}

.card-carousel__dot.active {
  background: var(--lime);
  transform: scale(1.25);
}

/* Placeholder sem foto */
.card-no-img {
  height: 220px;
  background: linear-gradient(135deg, var(--teal-dark), var(--teal));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: rgba(255, 255, 255, .3);
}

/* Conteúdo do card */
.card-body {
  padding: 1.4rem 1.5rem 1.6rem;
}

.card-date {
  font-size: .78rem;
  font-weight: 700;
  color: var(--teal);
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: .5rem;
}

.card-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
  margin-bottom: 1rem;
}

.card-speaker {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .75rem 1rem;
  background: var(--cream);
  border-radius: 10px;
  margin-bottom: .9rem;
}

.card-speaker__avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--teal);
  flex-shrink: 0;
}

.card-speaker__info {
  flex: 1;
  min-width: 0;
}

.card-speaker__titulo {
  font-size: .7rem;
  color: var(--text-muted);
  font-weight: 600;
}

.card-speaker__nome {
  font-size: .88rem;
  font-weight: 800;
  color: var(--teal-dark);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-desc {
  font-size: .88rem;
  color: var(--text-muted);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ══ ESTADO VAZIO ════════════════════════════════════ */
.empty-state {
  text-align: center;
  padding: 4rem 1rem;
  color: var(--text-muted);
}

.empty-state .icon {
  font-size: 3.5rem;
  margin-bottom: 1rem;
}

.empty-state p {
  font-size: 1.05rem;
}

/* ══ LOADING ═════════════════════════════════════════ */
.loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem;
  gap: 1rem;
  color: var(--text-muted);
}

.spinner {
  width: 48px;
  height: 48px;
  border: 4px solid rgba(42, 191, 191, .2);
  border-top-color: var(--teal);
  border-radius: 50%;
  animation: spin .8s linear infinite;
}

/* ══ FOOTER ══════════════════════════════════════════ */
.footer {
  background: #0d3d3d;
  color: rgba(255, 255, 255, .7);
  text-align: center;
  padding: 2rem 1rem;
  font-size: .85rem;
}

.footer img {
  height: 40px;
  object-fit: contain;
  margin-bottom: .75rem;
  filter: brightness(1.2);
}

/* ══ ANIMATIONS ══════════════════════════════════════ */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes bounce {

  0%,
  100% {
    transform: translateX(-50%) translateY(0);
  }

  50% {
    transform: translateX(-50%) translateY(-10px);
  }
}

@keyframes slideInLeft {
  from { opacity: 0; transform: translateX(-50px); }
  to   { opacity: 1; transform: translateX(0); }
}

@keyframes slideInRight {
  from { opacity: 0; transform: translateX(50px); }
  to   { opacity: 1; transform: translateX(0); }
}

@keyframes dividerFlow {
  0%   { background-position: 0% 50%; }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* Scroll reveal */
.enei-reveal {
  opacity: 0;
  transform: translateY(36px);
  transition: opacity .7s ease, transform .7s ease;
}
.enei-reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Animated divider */
.animated-divider {
  width: 100%;
  height: 45px;
  background: linear-gradient(45deg, transparent 45%, var(--teal) 50%, transparent 55%);
  background-size: 200% 200%;
  animation: dividerFlow 7s linear infinite;
  opacity: 0.3;
  margin: 20px 0;
}

/* ══ MODAL PÚBLICO (Desktop) ═════════════════════════ */
.public-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 50, 50, 0.8);
  backdrop-filter: blur(4px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  animation: fadeUp 0.3s ease both;
}

.public-modal {
  background: var(--card-bg);
  width: 100%;
  max-width: 600px;
  border-radius: var(--radius);
  box-shadow: var(--shadow-hover);
  overflow: hidden;
  position: relative;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
}

.public-modal__close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: var(--white);
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 1.2rem;
  font-weight: bold;
  color: var(--teal-dark);
  cursor: pointer;
  z-index: 10;
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s;
}
.public-modal__close:hover {
  transform: scale(1.1);
}

.public-modal__content {
  overflow-y: auto;
  padding: 0;
}

/* ══ RESPONSIVO GERAL ════════════════════════════════ */
@media (max-width: 600px) {
  .news-grid {
    grid-template-columns: 1fr;
  }

  .section-noticias {
    padding: 3rem 1rem;
  }

  .card-desc {
    -webkit-line-clamp: 3;
    
  }
}

/* ══ MODAL MOBILE ════════════════════════════════════ */
@media (max-width: 600px) {
  .public-modal-overlay {
    padding: 0;
    align-items: flex-end;
  }

  .public-modal {
    max-width: 100%;
    border-radius: var(--radius) var(--radius) 0 0;
    max-height: 92vh;
  }
}