﻿/* ===== PÁGINA DE EVENTO ===== */

/* ---------- HERO BANNER ---------- */
.ev-hero {
  position: relative;
  width: 100%;
  height: 420px;
  overflow: hidden;
  background: linear-gradient(135deg, #052e16 0%, #065f46 100%);
}

.ev-hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  filter: brightness(0.75);
}

/* Gradiente suave embaixo para transição com o fundo */
.ev-hero-fade {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 180px;
  background: linear-gradient(to bottom, transparent, var(--bg));
  pointer-events: none;
}

/* ---------- CONTAINER ---------- */
.ev-container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 2rem 4rem;
}

/* ---------- BOTÃO VOLTAR ---------- */
.ev-back-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 1.25rem;
  margin-bottom: 0.25rem;
  padding: 0.45rem 0.9rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-sec);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition: border-color .15s, color .15s, background .15s;
}

.ev-back-btn:hover {
  border-color: var(--green);
  color: var(--green);
  background: var(--green-bg);
}

/* ---------- BREADCRUMB ---------- */
.ev-breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 1.2rem 0;
  font-size: 0.82rem;
  color: var(--text-sec);
}

.ev-breadcrumb a {
  color: var(--text-sec);
  transition: color .15s;
}

.ev-breadcrumb a:hover {
  color: var(--green);
}

.ev-bread-current {
  color: var(--text);
  max-width: 320px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ev-breadcrumb svg {
  opacity: 0.4;
  flex-shrink: 0;
}

/* ---------- LAYOUT GRID ---------- */
.ev-layout {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 3rem;
  align-items: start;
}

/* ---------- TÍTULO ---------- */
.ev-title-block {
  margin-bottom: 1.25rem;
}

.ev-title {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.5px;
  color: var(--text);
}

/* ---------- CHIPS RÁPIDOS ---------- */
.ev-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 2rem;
}

.ev-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.35rem 0.75rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 0.82rem;
  color: var(--text-sec);
}

.ev-chip svg {
  color: var(--green);
  flex-shrink: 0;
}

/* ---------- SEÇÕES ---------- */
.ev-section {
  border-bottom: 1px solid var(--border);
  padding: 1.75rem 0;
  margin-bottom: 0;
}

.ev-section-h {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 1rem;
}

/* ---------- DESCRIÇÃO ---------- */
.ev-desc {
  font-size: 0.95rem;
  color: var(--text-sec);
  line-height: 1.75;
}

.ev-desc p + p {
  margin-top: 0.85rem;
}

/* ---------- INFO ROWS (data, local) ---------- */
.ev-info-row {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.ev-info-icon {
  width: 44px;
  height: 44px;
  background: var(--green-bg);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--green);
}

.ev-info-text {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding-top: 0.1rem;
}

.ev-info-text strong {
  font-size: 0.95rem;
  color: var(--text);
}

.ev-info-text span {
  font-size: 0.85rem;
  color: var(--text-sec);
}

/* Placeholder de mapa */
.ev-map-placeholder {
  margin-top: 1rem;
  height: 140px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  color: var(--text-sec);
  font-size: 0.82rem;
}

/* ---------- ORGANIZER ---------- */
.ev-organizer {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.ev-org-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--green-bg);
  border: 1px solid rgba(22,163,74,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--green);
  flex-shrink: 0;
}

.badge-verified {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.78rem;
  color: var(--green);
  background: var(--green-bg);
  padding: 0.2rem 0.6rem;
  border-radius: 20px;
}

.badge-produtor {
  font-size: 0.78rem;
  color: var(--text-sec);
}

/* ===== SIDEBAR: INGRESSOS ===== */
.ev-sidebar {
  position: sticky;
  top: 80px;
}

.ev-ingresso-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
}

.ev-ingresso-h {
  font-size: 1rem;
  font-weight: 700;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border);
}

.ev-ingresso-list {
  display: flex;
  flex-direction: column;
}

/* Cada tipo de ingresso */
.ev-ingresso-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.1rem 1.5rem;
  border-bottom: 1px solid var(--border);
  transition: background .15s;
}

.ev-ingresso-item:hover {
  background: var(--surface2);
}

.ev-ingresso-info {
  flex: 1;
  min-width: 0;
}

.ev-ingresso-nome {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 0.2rem;
}

.ev-ingresso-desc {
  display: block;
  font-size: 0.78rem;
  color: var(--text-sec);
  margin-bottom: 0.2rem;
}

.ev-ingresso-meia {
  display: inline-block;
  font-size: 0.75rem;
  color: var(--green);
  background: var(--green-bg);
  padding: 0.1rem 0.5rem;
  border-radius: 20px;
}

.ev-ingresso-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.5rem;
  flex-shrink: 0;
}

.ev-ingresso-preco {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text);
  white-space: nowrap;
}

/* Seletor de quantidade */
.qty-selector {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.qty-btn {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  cursor: pointer;
  font-size: 1.1rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color .15s, color .15s, background .15s;
  user-select: none;
}

.qty-btn:hover:not(:disabled) {
  border-color: var(--green);
  color: var(--green);
  background: var(--green-bg);
}

.qty-btn:disabled {
  opacity: 0.3;
  cursor: default;
}

.qty-num {
  min-width: 20px;
  text-align: center;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
}

.qty-num.active {
  color: var(--green);
}

/* ---------- BOTÃO COMPRAR ---------- */
.ev-ingresso-actions {
  padding: 1.25rem 1.5rem;
}

.ev-btn-comprar {
  width: 100%;
  padding: 0.85rem 1rem;
  background: var(--green);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  transition: opacity .2s, transform .1s;
  letter-spacing: 0.01em;
}

.ev-btn-comprar:hover:not(:disabled) {
  opacity: 0.9;
  transform: translateY(-1px);
}

.ev-btn-comprar:disabled {
  background: var(--surface2);
  color: var(--text-sec);
  cursor: not-allowed;
  border: 1px solid var(--border);
  transform: none;
}

.ev-taxa {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  margin-top: 0.75rem;
  font-size: 0.75rem;
  color: var(--text-sec);
}

.ev-taxa svg {
  color: var(--green);
  flex-shrink: 0;
}

/* ===== MODAL ===== */
.ev-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(4px);
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.ev-modal-overlay[hidden] {
  display: none;
}

.ev-modal {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  width: 100%;
  max-width: 460px;
  overflow: hidden;
  animation: modal-in .2s ease;
}

@keyframes modal-in {
  from { opacity: 0; transform: translateY(20px) scale(.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.ev-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border);
}

.ev-modal-header h3 {
  font-size: 1rem;
  font-weight: 700;
}

.ev-modal-close {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .15s;
}

.ev-modal-close:hover {
  background: var(--border);
}

.ev-modal-body {
  padding: 1.5rem;
}

.modal-evento-nome {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}

.modal-itens {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.modal-item {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  color: var(--text-sec);
}

.modal-item span:last-child {
  font-weight: 600;
  color: var(--text);
}

.modal-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  font-size: 1rem;
}

.modal-total strong:last-child {
  color: var(--green);
  font-size: 1.2rem;
}

.ev-modal-footer {
  padding: 1.25rem 1.5rem;
  border-top: 1px solid var(--border);
  background: rgba(0,0,0,0.02);
}

.ev-btn-finalizar {
  width: 100%;
  padding: 0.85rem;
  background: var(--green);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  transition: opacity .2s;
}

.ev-btn-finalizar:hover {
  opacity: 0.9;
}

.ev-modal-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  margin-top: 0.75rem;
  font-size: 0.75rem;
  color: var(--text-sec);
}

.ev-modal-note svg {
  color: var(--green);
  flex-shrink: 0;
}

/* ===== BARRA MOBILE (sticky bottom) ===== */
.ev-mobile-bar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 200;
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 0.85rem 1.25rem;
  align-items: center;
  gap: 1rem;
  backdrop-filter: blur(8px);
}

.ev-mobile-info {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.ev-mobile-preco {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
}

.ev-mobile-sub {
  font-size: 0.75rem;
  color: var(--text-sec);
}

.ev-mobile-btn {
  width: auto !important;
  padding: 0.75rem 1.5rem !important;
  white-space: nowrap;
}

/* ===== RESPONSIVO ===== */
@media (max-width: 900px) {
  .ev-hero {
    height: 260px;
  }

  .ev-layout {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .ev-sidebar {
    position: static;
    order: -1; /* Ingressos acima no mobile */
    margin-bottom: 2rem;
  }

  .ev-title {
    font-size: 1.5rem;
  }

  /* Sidebar de ingressos fica visível no topo no mobile (order: -1 já definido acima) */
  /* Barra mobile não é necessária — sidebar aparece no topo */
  .ev-mobile-bar {
    display: none;
  }
}

@media (max-width: 600px) {
  .ev-container { padding: 0 1rem 4rem; }
  .ev-hero { height: 200px; }
  .ev-title { font-size: 1.3rem; }
  .ev-chips { gap: 0.4rem; }
  .ev-chip { font-size: 0.78rem; padding: 0.3rem 0.6rem; }

  /* Botões de quantidade maiores para toque */
  .qty-btn { width: 36px; height: 36px; font-size: 1.2rem; }
  .qty-num { font-size: 1rem; min-width: 24px; }

  /* Mobile bar mais polida */
  .ev-mobile-bar { padding: .75rem 1rem; gap: .75rem; }
  .ev-mobile-preco { font-size: 1.05rem; }
  .ev-mobile-btn { padding: .7rem 1.25rem !important; }

  /* Info rows no mobile */
  .ev-info-icon { width: 38px; height: 38px; }

  /* Breadcrumb oculto no mobile */
  .ev-breadcrumb { display: none; }
}
