/* ================================================================
   Sorteos Tec – Segunda Oportunidad a la Suerte
   Custom Styles – SOE-51
   ================================================================ */

/* ── Variables ─────────────────────────────────────────────────── */
:root {
  --naranja       : #EA7021;
  --naranja-dark  : #c45c15;
  --naranja-light : #f5a263;
  --morado        : #6B21A8;
  --morado-light  : #9333EA;
  --cafe          : #7C5A2E;
  --cafe-light    : #a07840;
  --blanco        : #ffffff;
  --gris-claro    : #f8f9fa;
  --gris          : #6c757d;
  --dark-bg       : #1a1a2e;
  --naranja-other : #FD7E14;
  --font-main     : 'Montserrat', sans-serif;
}

/* ── Reset & Base ───────────────────────────────────────────────── */
* { box-sizing: border-box; }

body {
  font-family: var(--font-main);
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

/* ── NAVBAR ─────────────────────────────────────────────────────── */
#mainNav {
  background-color: #FD7E14;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 0.5rem 1rem;
  transition: background-color 0.35s ease;
  z-index: 1040;
}

#mainNav.scrolled {
  background-color: FD7E14;
  box-shadow: 0 2px 12px rgba(0,0,0,0.4);
}

#mainNav .container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
}

.navbar-brand {
  margin-right: auto;
}

.navbar-brand img {
  max-height: 45px;
  width: auto;
}

.navbar-nav .nav-link {
  color: rgba(255,255,255,0.9) !important;
  font-weight: 600;
  font-size: 0.88rem;
  letter-spacing: 0.04em;
  padding: 0.5rem 0.9rem;
  transition: color 0.2s;
}

.navbar-nav .nav-link:hover {
  color: var(--naranja) !important;
}

.btn-nav-participar {
  background-color: var(--naranja) !important;
  border-radius: 20px !important;
  padding: 0.4rem 1.3rem !important;
  color: #fff !important;
  margin-left: 0.4rem;
  border: 2px solid transparent;
  transition: background-color 0.2s, border-color 0.2s !important;
}

.btn-nav-participar:hover {
  background-color: var(--naranja-dark) !important;
  color: #fff !important;
}

/* ── HERO ───────────────────────────────────────────────────────── */
.hero-section {
  position: relative;
  min-height: 100vh;
  background: linear-gradient(135deg, #1a0533 0%, #3d1264 45%, #7c2a00 100%);
  background-image: url('../img/hero_bg.jpg');
  background-size: cover;
  background-position: center top;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(15, 3, 35, 0.68);
  z-index: 1;
}

.video-header {
  position: relative;
  z-index: 2;
  width: 100%;
  display: block;
}

.hero-overlay {
  position: relative;
  z-index: 2;
  width: 100%;
  padding: 110px 20px 90px;
}

.hero-title {
  font-size: clamp(2rem, 5vw, 4rem);
  font-weight: 800;
  color: #fff;
  text-shadow: 0 3px 16px rgba(0,0,0,0.55);
  line-height: 1.15;
  margin-bottom: 1rem;
}

.hero-title span {
  color: var(--naranja);
}

.hero-subtitle {
  font-size: clamp(1rem, 2.2vw, 1.3rem);
  color: rgba(255,255,255,0.88);
  font-weight: 400;
  margin-bottom: 2.2rem;
  line-height: 1.6;
}

.hero-prize-badge {
  display: inline-block;
  background: linear-gradient(135deg, var(--cafe), var(--cafe-light));
  color: #fff;
  border-radius: 12px;
  padding: 1rem 2rem;
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 800;
  letter-spacing: 0.02em;
  box-shadow: 0 6px 25px rgba(0,0,0,0.35);
  margin-top: 0.5rem;
}

.hero-prize-label {
  font-size: 0.85rem;
  font-weight: 600;
  opacity: 0.85;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  display: block;
  margin-bottom: 0.2rem;
}

.scroll-down-arrow {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  color: rgba(255,255,255,0.75);
  text-decoration: none;
  animation: bounce 2.2s ease-in-out infinite;
  transition: color 0.2s;
}

.scroll-down-arrow:hover { color: var(--naranja); }

.scroll-down-arrow .material-icons { font-size: 3rem; }

@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50%       { transform: translateX(-50%) translateY(12px); }
}

/* ── PREMIOS ────────────────────────────────────────────────────── */
.premios-section {
  background-color: #fff;
}

.section-title {
  font-size: clamp(1.7rem, 3vw, 2.4rem);
  font-weight: 800;
  color: var(--cafe);
  margin-bottom: 0.5rem;
}

.section-subtitle {
  font-size: 1.08rem;
  color: #555;
  line-height: 1.7;
}

.prize-amount {
  color: var(--naranja);
  font-weight: 800;
}

.premio-img {
  border-radius: 14px;
  box-shadow: 0 10px 35px rgba(0,0,0,0.14);
  max-height: 320px;
  width: 100%;
  object-fit: contain;
}

.prize-card-main {
  background: linear-gradient(135deg, var(--cafe) 0%, var(--cafe-light) 100%);
  border-radius: 18px;
  padding: 2.2rem 2rem;
  color: #fff;
  text-align: center;
  box-shadow: 0 10px 40px rgba(124, 90, 46, 0.35);
}

.prize-number {
  font-size: 0.95rem;
  font-weight: 700;
  opacity: 0.8;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.prize-value {
  font-size: clamp(2.5rem, 5vw, 3.8rem);
  font-weight: 800;
  line-height: 1.1;
  margin: 0.25rem 0;
}

.prize-currency {
  font-size: 1.4rem;
  font-weight: 700;
  opacity: 0.88;
}

.prize-desc {
  margin-top: 0.6rem;
  font-size: 1rem;
  opacity: 0.82;
}

/* Swiper – premios carousel */
.carousel-title {
  font-size: 1.45rem;
  font-weight: 700;
  color: #333;
}

.prizes-carousel {
  padding-bottom: 2.5rem !important;
}

.prizes-carousel .swiper-slide {
  padding: 8px;
}

.prizes-carousel .swiper-slide img {
  border-radius: 12px;
  box-shadow: 0 5px 18px rgba(0,0,0,0.1);
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
}

.prizes-carousel .swiper-button-next,
.prizes-carousel .swiper-button-prev {
  background: var(--naranja);
  color: #fff;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  transition: background-color 0.2s;
}

.prizes-carousel .swiper-button-next::after,
.prizes-carousel .swiper-button-prev::after {
  font-size: 1rem;
  font-weight: 900;
}

.prizes-carousel .swiper-button-next:hover,
.prizes-carousel .swiper-button-prev:hover {
  background: var(--naranja-dark);
}

.prizes-carousel .swiper-pagination-bullet-active {
  background: var(--naranja);
}

/* ── INFO CARDS (fecha / emisión / permiso) ─────────────────────── */
.info-row { margin-top: 1rem; }

.info-card {
  background: var(--gris-claro);
  border-radius: 14px;
  padding: 1.4rem 1.2rem 1.2rem;
  border-left: 0px solid var(--morado);
  height: 100%;
}

.info-icon {
  font-size: 2rem;
  color: var(--naranja-dark);
  display: block;
  margin-bottom: 0.35rem;
}

.info-label {
  font-size: 0.78rem;
  color: #888;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.info-value {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--morado);
  margin-top: 0.25rem;
}

/* ── CAUSA SOCIAL ───────────────────────────────────────────────── */
.causa-section {
  background: linear-gradient(135deg, #7c2a00 0%, var(--naranja) 60%, #c45c15 100%);
}

.form-card {
  background: #fff;
  border-radius: 18px;
  padding: 2.5rem 2.8rem;
  box-shadow: 0 12px 50px rgba(0,0,0,0.22);
}

.form-title {
  color: var(--naranja);
  font-weight: 800;
  font-size: 1.75rem;
}

.form-subtitle {
  font-size: 0.95rem;
  color: #666;
}

.form-control {
  border-radius: 8px;
  border: 1.5px solid #ddd;
  padding: 0.6rem 1rem;
  font-size: 0.94rem;
  transition: border-color 0.2s, box-shadow 0.2s;
  font-family: var(--font-main);
}

.form-control:focus {
  border-color: var(--naranja);
  box-shadow: 0 0 0 3px rgba(234,112,33,0.18);
  outline: none;
}

label {
  font-weight: 600;
  font-size: 0.88rem;
  color: #444;
  margin-bottom: 0.3rem;
}

.required-star {
  color: var(--naranja);
}

.btn-participar {
  background-color: var(--naranja);
  color: #fff;
  border: none;
  border-radius: 30px;
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.04em;
  transition: background-color 0.2s, transform 0.12s, box-shadow 0.2s;
  box-shadow: 0 5px 18px rgba(234,112,33,0.45);
  font-family: var(--font-main);
}

.btn-participar:hover {
  background-color: var(--naranja-dark);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(234,112,33,0.5);
}

.btn-participar:active {
  transform: translateY(0);
}

.terms-note {
  font-size: 0.82rem;
  color: #888;
}

.terms-link {
  color: var(--naranja);
  font-weight: 600;
  text-decoration: none;
}

.terms-link:hover {
  color: var(--naranja-dark);
  text-decoration: underline;
}

/* jQuery Validate error messages */
label.error {
  color: #dc3545;
  font-size: 0.78rem;
  font-weight: 500;
  margin-top: 2px;
  display: block;
}

input.error,
select.error {
  border-color: #dc3545 !important;
  box-shadow: 0 0 0 3px rgba(220,53,69,0.12) !important;
}

/* ── FOOTER ─────────────────────────────────────────────────────── */
.footer-section {
  /* background-color: var(--naranja); */
  background: linear-gradient(135deg, #7c2a00 0%, var(--naranja) 60%, #c45c15 100%);  
  border-top: 4px solid var(--naranja);
}

.footer-logo {
  max-height: 48px;
  width: auto;
  filter: brightness(0) invert(1);
  opacity: 0.85;
}

.footer-icon {
  vertical-align: middle;
  color: var(--naranja);
  font-size: 1.25rem;
  margin-right: 4px;
}

.footer-phone {
  color: #fff;
  font-weight: 600;
  font-size: 0.98rem;
}

.footer-link {
  color: rgba(255,255,255,0.65);
  font-size: 0.86rem;
  text-decoration: none;
  transition: color 0.2s;
  display: inline-block;
  margin-bottom: 0.2rem;
}

.footer-link:hover {
  color: var(--naranja);
  text-decoration: none;
}

.footer-copy {
  color: rgba(255,255,255,0.4);
  font-size: 0.78rem;
  line-height: 1.5;
}

/* ── LOADING OVERLAY ─────────────────────────────────────────────── */
#loading_overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 2, 25, 0.65);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
}

#loading_overlay.active {
  display: flex;
}

/* ── GANADORES PAGE ──────────────────────────────────────────────── */
.ganadores-header {
  background: linear-gradient(135deg, var(--naranja) 0%, var(--naranja-dark) 100%);
  padding: 120px 0 60px;
  text-align: center;
}

.ganadores-title {
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 800;
  color: #fff;
  text-shadow: 0 2px 12px rgba(0,0,0,0.3);
}

.no-ganadores-box {
  background: #fff;
  border-radius: 16px;
  padding: 3rem 2rem;
  text-align: center;
  max-width: 520px;
  margin: 0 auto;
  box-shadow: 0 8px 30px rgba(0,0,0,0.12);
}

.btn-download-pdf {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background-color: var(--naranja);
  color: #fff;
  border: none;
  border-radius: 50px;
  padding: 0.85rem 1.8rem;
  font-weight: 700;
  font-size: 0.95rem;
  box-shadow: 0 6px 20px rgba(234,112,33,0.5);
  z-index: 999;
  transition: background-color 0.2s, transform 0.12s;
  cursor: pointer;
  font-family: var(--font-main);
}

.btn-download-pdf:hover {
  background-color: var(--naranja-dark);
  transform: translateY(-2px);
}

.lista_ganadores {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 0 auto 1.5rem;
  border-radius: 10px;
}

/* ── PURCHASE / CONFIRMATION PAGE ────────────────────────────────── */
.purchase-wrapper {
  min-height: 100vh;
  background: linear-gradient(135deg, #1a0533, #3d1264);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.purchase-card {
  background: #fff;
  border-radius: 20px;
  padding: 3rem 2.5rem;
  max-width: 560px;
  width: 100%;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.purchase-icon {
  font-size: 5rem;
  color: var(--naranja);
  margin-bottom: 1rem;
}

.purchase-title {
  font-size: 1.9rem;
  font-weight: 800;
  color: var(--cafe);
  margin-bottom: 1rem;
}

.purchase-msg {
  font-size: 1.05rem;
  color: #555;
  line-height: 1.7;
}

/* ── PAYMENT PAGE ────────────────────────────────────────────────── */
.payment-wrapper {
  min-height: 100vh;
  background: var(--gris-claro);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.payment-header {
  text-align: center;
  margin-bottom: 1.5rem;
}

/* ── GENERAL PAGE WRAPPER ────────────────────────────────────────── */
.page-hero {
  padding: 130px 0 70px;
  background: linear-gradient(135deg, #1a0533 0%, #3d1264 50%, #7c2a00 100%);
}

.page-hero h1 {
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 800;
  color: #fff;
  text-shadow: 0 2px 12px rgba(0,0,0,0.35);
}

/* ── TYC TABLE ───────────────────────────────────────────────────── */
.tyc-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
  color: #333;
}

.tyc-table th {
  background-color: var(--naranja);
  color: #fff;
  padding: 10px 14px;
  font-weight: 700;
  text-align: left;
  vertical-align: top;
}

.tyc-table td {
  padding: 9px 14px;
  border-bottom: 1px solid #eee;
  vertical-align: top;
}

.tyc-table tr:nth-child(even) td {
  background-color: #fafafa;
}

/* ── RESPONSIVE ──────────────────────────────────────────────────── */
@media (max-width: 767.98px) {
  .form-card  { padding: 1.5rem 1.2rem; }
  .hero-title { font-size: 2rem; }
  .prize-value { font-size: 2.6rem; }
  .info-card  { margin-bottom: 1rem; }
  .btn-download-pdf {
    bottom: 16px;
    right: 16px;
    padding: 0.7rem 1.3rem;
    font-size: 0.85rem;
  }
  .purchase-card { padding: 2rem 1.2rem; }
}

@media (max-width: 575.98px) {
  .navbar-brand img { max-height: 36px; }
  .hero-prize-badge { font-size: 1.5rem; padding: 0.75rem 1.2rem; }
}
