/* ============================================================
   HORIZONTE EVENTOS GRANADA — Estilos públicos
   ============================================================ */

:root {
  --primary:      #1a1a3e;
  --primary-light:#2d2d6b;
  --gold:         #c9a84c;
  --gold-light:   #e8c56a;
  --gold-pale:    #fdf6e3;
  --white:        #ffffff;
  --bg:           #f8f7f2;
  --card:         #ffffff;
  --text:         #1a1a2e;
  --text-mid:     #555577;
  --text-muted:   #888899;
  --success:      #27ae60;
  --error:        #e74c3c;
  --border:       #e8e0d0;
  --shadow:       0 4px 24px rgba(26,26,62,.10);
  --shadow-hover: 0 8px 32px rgba(26,26,62,.18);
  --radius:       14px;
  --transition:   all .28s ease;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: 'Lato', sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.65;
}

img { max-width: 100%; height: auto; display: block; }
a   { color: var(--gold); text-decoration: none; }

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ── Flash ─────────────────────────────────────────────── */
.flash-error {
  background: #fdecea;
  color: #c0392b;
  border-left: 4px solid #e74c3c;
  padding: 14px 20px;
  font-size: 14px;
}

/* ── HERO ───────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero-img-wrap {
  position: absolute; inset: 0; z-index: 0;
}
.hero-img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center top;
}
.hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(
    170deg,
    rgba(10,10,30,.72) 0%,
    rgba(26,26,62,.85) 55%,
    rgba(10,10,20,.9)  100%
  );
}

.hero-content {
  position: relative; z-index: 1;
  text-align: center;
  padding: 60px 24px 100px;
  max-width: 780px;
}

.hero-pre {
  font-family: 'Lato', sans-serif;
  font-size: 12px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 18px;
  opacity: .9;
}

.hero-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  font-weight: 700;
  color: var(--white);
  line-height: 1.12;
  margin-bottom: 16px;
  text-shadow: 0 2px 24px rgba(0,0,0,.4);
}

.hero-subtitle {
  font-size: 18px;
  color: rgba(255,255,255,.78);
  margin-bottom: 36px;
  letter-spacing: .5px;
}

.hero-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--gold);
  color: var(--primary);
  font-family: 'Lato', sans-serif;
  font-weight: 700;
  font-size: 16px;
  padding: 16px 38px;
  border-radius: 50px;
  text-decoration: none;
  transition: var(--transition);
  box-shadow: 0 4px 20px rgba(201,168,76,.35);
}
.hero-btn:hover {
  background: var(--gold-light);
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(201,168,76,.45);
}

.hero-scroll {
  position: absolute;
  bottom: 32px; left: 50%;
  transform: translateX(-50%);
  z-index: 1;
  color: rgba(255,255,255,.5);
  font-size: 20px;
  animation: bounce 2s infinite;
}
@keyframes bounce {
  0%,100% { transform: translateX(-50%) translateY(0); }
  50%      { transform: translateX(-50%) translateY(8px); }
}

/* ── DESCRIPCIÓN ───────────────────────────────────────── */
.event-desc {
  background: var(--primary);
  padding: 36px 0;
}
.event-desc .container {
  max-width: 720px;
  text-align: center;
}
.event-desc p {
  color: rgba(255,255,255,.78);
  font-size: 17px;
  line-height: 1.75;
}

/* ── ENTRADAS ──────────────────────────────────────────── */
.tickets-section {
  padding: 80px 0;
  background: var(--bg);
}

.section-header {
  text-align: center;
  margin-bottom: 52px;
}
.section-header h2 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  color: var(--primary);
  margin-bottom: 10px;
}
.section-header p {
  color: var(--text-mid);
  font-size: 16px;
}

.tickets-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 28px;
  max-width: 960px;
  margin: 0 auto;
}

.ticket-card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 32px 28px 28px;
  position: relative;
  transition: var(--transition);
  border: 2px solid transparent;
  display: flex;
  flex-direction: column;
}
.ticket-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(201,168,76,.3);
}
.ticket-card.featured {
  border-color: var(--gold);
  background: linear-gradient(180deg, #fffdf5 0%, #fff 100%);
}
.ticket-card.sold-out { opacity: .65; pointer-events: none; }

.card-badge {
  position: absolute;
  top: -14px; left: 50%;
  transform: translateX(-50%);
  background: var(--gold);
  color: var(--primary);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 5px 18px;
  border-radius: 20px;
  white-space: nowrap;
}
.card-badge.badge-sold {
  background: var(--error);
  color: #fff;
}

.card-header { text-align: center; margin-bottom: 20px; }
.card-icon {
  width: 56px; height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 14px;
  color: var(--gold);
  font-size: 22px;
}
.featured .card-icon { background: linear-gradient(135deg, var(--gold), var(--gold-light)); color: var(--primary); }

.card-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.4rem;
  color: var(--primary);
  margin-bottom: 6px;
}
.card-date {
  font-size: 13px;
  color: var(--text-muted);
}
.card-date i { margin-right: 4px; }

.card-price {
  text-align: center;
  margin: 16px 0 24px;
  color: var(--primary);
}
.price-amount {
  font-family: 'Playfair Display', serif;
  font-size: 3.2rem;
  font-weight: 700;
  line-height: 1;
  color: var(--primary);
}
.price-currency { font-size: 1.4rem; font-weight: 700; vertical-align: super; }
.price-label    { font-size: 13px; color: var(--text-muted); display: block; margin-top: 4px; }

/* Selector cantidad */
.qty-selector {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-bottom: 14px;
  border: 2px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}
.qty-btn {
  background: var(--bg);
  border: none;
  padding: 12px 18px;
  cursor: pointer;
  font-size: 16px;
  color: var(--primary);
  transition: var(--transition);
}
.qty-btn:hover { background: var(--gold-pale); color: var(--gold); }
.qty-input {
  border: none;
  width: 56px;
  text-align: center;
  font-size: 18px;
  font-weight: 700;
  color: var(--primary);
  background: var(--white);
  outline: none;
  padding: 10px 0;
  -moz-appearance: textfield;
}
.qty-input::-webkit-inner-spin-button,
.qty-input::-webkit-outer-spin-button { -webkit-appearance: none; }

.card-total {
  text-align: center;
  font-size: 14px;
  color: var(--text-mid);
  margin-bottom: 16px;
}
.total-display {
  font-size: 18px;
  font-weight: 700;
  color: var(--primary);
}

.btn-buy {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  background: var(--primary);
  color: var(--white);
  border: none;
  padding: 15px 20px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  font-family: 'Lato', sans-serif;
}
.btn-buy:hover {
  background: var(--gold);
  color: var(--primary);
  transform: translateY(-1px);
}
.featured .btn-buy {
  background: var(--gold);
  color: var(--primary);
}
.featured .btn-buy:hover {
  background: var(--primary);
  color: var(--white);
}

.sold-out-msg {
  text-align: center;
  padding: 16px;
  color: var(--text-muted);
  font-size: 14px;
}

.capacity-bar {
  margin-top: 16px;
  background: var(--bg);
  border-radius: 6px;
  height: 6px;
  overflow: hidden;
  position: relative;
}
.capacity-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--gold), var(--gold-light));
  border-radius: 6px;
  transition: width .4s ease;
}
.capacity-text {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 5px;
  text-align: center;
}

/* ── GARANTÍAS ──────────────────────────────────────────── */
.guarantees {
  background: var(--primary);
  padding: 56px 0;
}
.guarantees-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 32px;
}
.guarantee-item {
  text-align: center;
  color: rgba(255,255,255,.85);
}
.guarantee-item i {
  font-size: 32px;
  color: var(--gold);
  margin-bottom: 12px;
}
.guarantee-item h4 {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--white);
}
.guarantee-item p { font-size: 13px; opacity: .7; }

/* ── SIN EVENTO ─────────────────────────────────────────── */
.no-event {
  min-height: 80svh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary);
}
.no-event-inner {
  text-align: center;
  color: var(--white);
  padding: 40px 24px;
}
.no-event-inner i { font-size: 56px; color: var(--gold); margin-bottom: 20px; }
.no-event-inner h2 { font-family: 'Playfair Display', serif; font-size: 1.8rem; margin-bottom: 12px; }
.no-event-inner p  { color: rgba(255,255,255,.65); }

/* ── CHECKOUT ───────────────────────────────────────────── */
.checkout-page { min-height: 100svh; display: flex; flex-direction: column; }

.checkout-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 32px;
  background: var(--primary);
  color: var(--white);
}
.back-link { color: rgba(255,255,255,.65); font-size: 13px; transition: var(--transition); }
.back-link:hover { color: var(--gold); }
.back-link i { margin-right: 6px; }
.checkout-logo { font-family: 'Playfair Display', serif; font-size: 16px; color: var(--gold); letter-spacing: 1px; }
.checkout-secure { font-size: 12px; color: rgba(255,255,255,.6); }
.checkout-secure i { margin-right: 4px; color: var(--success); }

.checkout-container {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 0;
  flex: 1;
  max-width: 1000px;
  margin: 0 auto;
  width: 100%;
  padding: 40px 24px;
  gap: 40px;
  align-items: start;
}

.order-summary { position: sticky; top: 24px; }
.order-summary h2 {
  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  color: var(--primary);
  margin-bottom: 16px;
}
.order-summary h2 i { color: var(--gold); margin-right: 8px; }

.summary-card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px;
  border: 1px solid var(--border);
}
.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}
.summary-row:last-child { border-bottom: none; }
.summary-label { font-size: 13px; color: var(--text-muted); white-space: nowrap; }
.summary-value { font-size: 14px; text-align: right; }
.summary-event .summary-value { font-family: 'Playfair Display', serif; font-size: 15px; color: var(--primary); }
.summary-divider { height: 1px; background: var(--border); margin: 4px 0; }
.summary-total .summary-label { font-weight: 700; font-size: 14px; color: var(--primary); }
.summary-total .total-price {
  font-family: 'Playfair Display', serif;
  font-size: 22px;
  font-weight: 700;
  color: var(--primary);
}

.summary-notice {
  margin-top: 16px;
  background: #f0f4ff;
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 12px;
  color: #444466;
  line-height: 1.55;
}
.summary-notice i { color: var(--gold); margin-right: 6px; }

/* Formulario checkout */
.checkout-form-wrap h2 {
  font-family: 'Playfair Display', serif;
  font-size: 1.3rem;
  color: var(--primary);
  margin-bottom: 24px;
}
.checkout-form-wrap h2 i { color: var(--gold); margin-right: 8px; }

.form-errors {
  background: #fdecea;
  border: 1px solid #e74c3c;
  border-radius: 8px;
  padding: 14px 18px;
  margin-bottom: 20px;
  font-size: 13px;
  color: #c0392b;
}
.form-errors ul { margin: 8px 0 0 18px; }
.form-errors li { margin-bottom: 4px; }

.checkout-form .form-group { margin-bottom: 20px; }
.checkout-form label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 7px;
  letter-spacing: .3px;
}
.required { color: var(--error); }

.checkout-form input[type="text"],
.checkout-form input[type="email"],
.checkout-form input[type="tel"] {
  width: 100%;
  padding: 13px 16px;
  border: 2px solid var(--border);
  border-radius: 10px;
  font-size: 15px;
  font-family: 'Lato', sans-serif;
  color: var(--text);
  background: var(--white);
  transition: var(--transition);
  outline: none;
}
.checkout-form input:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201,168,76,.15);
}
.checkout-form small { display: block; font-size: 12px; color: var(--text-muted); margin-top: 5px; }

.form-notice {
  background: #f0f9f4;
  border: 1px solid #a8d5b5;
  border-radius: 8px;
  padding: 14px 18px;
  font-size: 13px;
  color: #2d6a4f;
  margin-bottom: 24px;
  line-height: 1.55;
}
.form-notice i { margin-right: 6px; }

.btn-pay {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: var(--primary);
  color: var(--white);
  border: none;
  padding: 18px 24px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 700;
  font-family: 'Lato', sans-serif;
  cursor: pointer;
  transition: var(--transition);
  letter-spacing: .3px;
}
.btn-pay:hover {
  background: var(--gold);
  color: var(--primary);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(201,168,76,.3);
}

/* ── RESULTADO (success / error) ──────────────────────── */
.result-page {
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
}
.success-page { background: linear-gradient(135deg, #f0fdf4 0%, #f8f7f2 100%); }
.error-page   { background: linear-gradient(135deg, #fff5f5 0%, #f8f7f2 100%); }

.result-card {
  background: var(--card);
  border-radius: 20px;
  box-shadow: 0 8px 40px rgba(26,26,62,.12);
  padding: 52px 48px;
  max-width: 520px;
  width: 100%;
  text-align: center;
}
.result-icon { font-size: 64px; margin-bottom: 20px; }
.success-icon { color: var(--success); }
.error-icon   { color: var(--error); }
.result-card h1 {
  font-family: 'Playfair Display', serif;
  font-size: 1.8rem;
  color: var(--primary);
  margin-bottom: 10px;
}
.result-subtitle { color: var(--text-mid); margin-bottom: 28px; }

.result-details { text-align: left; margin-bottom: 24px; }
.result-ref {
  background: var(--primary);
  border-radius: 10px;
  padding: 16px 20px;
  margin-bottom: 16px;
}
.ref-label { font-size: 11px; color: rgba(255,255,255,.6); text-transform: uppercase; letter-spacing: 1px; display: block; }
.ref-value { font-size: 22px; font-weight: 700; color: var(--gold); letter-spacing: 2px; }

.result-table {
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}
.rt-row {
  display: flex;
  justify-content: space-between;
  padding: 11px 16px;
  font-size: 14px;
  border-bottom: 1px solid var(--border);
}
.rt-row:last-child { border-bottom: none; }
.rt-row span:first-child { color: var(--text-muted); }
.total-rt-row { background: var(--gold-pale); font-weight: 700; }
.total-rt-row span:last-child { color: var(--primary); font-size: 16px; }

.result-notice {
  background: #f0f9f4;
  border-radius: 8px;
  padding: 14px 18px;
  font-size: 13px;
  color: #2d6a4f;
  margin-bottom: 28px;
  line-height: 1.6;
}
.error-notice { background: #fff5f5; color: #7b2020; }
.result-notice i { margin-right: 6px; }

.btn-back-home {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--primary);
  color: var(--white);
  padding: 14px 32px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 15px;
  transition: var(--transition);
}
.btn-back-home:hover { background: var(--gold); color: var(--primary); }
.btn-retry { background: var(--error); }
.btn-retry:hover { background: #c0392b; color: var(--white); }

/* ── FOOTER ─────────────────────────────────────────────── */
.site-footer {
  background: var(--primary);
  color: rgba(255,255,255,.6);
  padding: 40px 0 0;
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px 32px;
  gap: 32px;
  flex-wrap: wrap;
}
.footer-logo {
  display: block;
  font-family: 'Playfair Display', serif;
  font-size: 18px;
  color: var(--gold);
  margin-bottom: 8px;
}
.footer-brand p, .footer-info p {
  font-size: 13px;
  margin-bottom: 6px;
}
.footer-info i { margin-right: 6px; color: var(--gold); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  padding: 16px 24px;
  text-align: center;
  font-size: 12px;
}

/* ── RESPONSIVE ─────────────────────────────────────────── */
@media (max-width: 768px) {
  .checkout-container {
    grid-template-columns: 1fr;
    padding: 24px 16px;
    gap: 28px;
  }
  .order-summary { position: static; }
  .result-card   { padding: 36px 24px; }

  .tickets-grid { grid-template-columns: 1fr; max-width: 380px; }
  .hero-content { padding-bottom: 80px; }
}
