/* =========================================================
   JASA POWER - style.css
   1. Variables  2. Base  3. Header  4. Hero  5. Experiencia
   6. Álbumes  7. WhatsApp  8. Footer  9. Responsive
   ========================================================= */

/* ---------- 1. VARIABLES ---------- */
:root {
  --orange: #FF4500;
  --orange-dark: #D93A00;
  --black: #111111;
  --gray-dark: #333333;
  --gray-light: #F8F9FA;
  --white: #FFFFFF;
  --radius: 8px;
  --radius-pill: 25px;
  --shadow: 0 6px 22px rgba(0, 0, 0, .09);
  --font-title: 'Barlow Condensed', 'Oswald', 'Montserrat', sans-serif;
  --font-body: 'Inter', 'Roboto', sans-serif;
  --header-h: 84px;
}

/* ---------- 2. BASE ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--gray-dark);
  background: var(--white);
  line-height: 1.6;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
ul { list-style: none; margin: 0; padding: 0; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 {
  font-family: var(--font-title);
  font-style: italic;
  font-weight: 800;
  text-transform: uppercase;
  line-height: 1;
  margin: 0;
  color: var(--black);
}
.container { width: min(1200px, 92%); margin-inline: auto; }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 3px; }

/* Botones */
.btn {
  display: inline-flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px 22px;
  font-family: var(--font-title); font-style: italic; font-weight: 700;
  font-size: 1.2rem; text-transform: uppercase; letter-spacing: .3px;
  border-radius: var(--radius); border: 2px solid var(--orange);
  cursor: pointer; transition: transform .2s, background .2s, color .2s, box-shadow .2s;
}
.btn:hover { transform: translateY(-3px); box-shadow: 0 8px 18px rgba(255, 69, 0, .3); }
.btn-primary { background: var(--orange); color: var(--white); }
.btn-primary:hover { background: var(--orange-dark); border-color: var(--orange-dark); }
.btn-outline { background: var(--white); color: var(--black); }
.btn-outline:hover { background: var(--orange); color: var(--white); }

/* Título de sección con líneas naranja a los lados */
.section-title {
  display: flex; align-items: center; gap: 24px;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  margin-bottom: 36px;
}
.section-title::before, .section-title::after {
  content: ""; flex: 1; height: 3px; background: var(--orange);
  transform: skewX(-40deg);
}
.section-title em { color: var(--orange); }

/* ---------- 3. HEADER ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: var(--white);
  box-shadow: 0 2px 12px rgba(0, 0, 0, .06);
}
.site-header::after { /* trazo diagonal de marca en la esquina */
  content: ""; position: absolute; top: 0; right: -20px;
  width: 170px; height: 100%;
  background: linear-gradient(115deg, transparent 40%, var(--orange) 40%, var(--orange) 52%, transparent 52%, transparent 62%, var(--orange) 62%, var(--orange) 70%, transparent 70%);
  pointer-events: none;
}
.header-inner { display: flex; align-items: center; justify-content: space-between; min-height: var(--header-h); }
.logo img { max-height: 70px; width: auto; }

.main-nav > ul { display: flex; align-items: center; gap: 30px; margin-right: 150px; }
.main-nav a, .dropdown-toggle {
  position: relative;
  font-family: var(--font-title); font-style: italic; font-weight: 700;
  font-size: 1.15rem; text-transform: uppercase; color: var(--black);
  background: none; border: 0; padding: 8px 0; cursor: pointer;
}
.main-nav > ul > li > a::after, .dropdown-toggle::before {
  content: ""; position: absolute; left: 0; bottom: 0; width: 100%; height: 3px;
  background: var(--orange); transform: scaleX(0); transform-origin: left; transition: transform .25s;
}
.main-nav a:hover::after, .main-nav a.active::after, .dropdown-toggle:hover::before { transform: scaleX(1); }
.main-nav a:hover, .dropdown-toggle:hover { color: var(--orange); }

/* Dropdown */
.has-dropdown { position: relative; }
.caret { display: inline-block; width: 7px; height: 7px; margin-left: 6px; border: solid currentColor; border-width: 0 2px 2px 0; transform: rotate(45deg) translateY(-2px); }
.dropdown {
  position: absolute; top: 100%; left: -16px; min-width: 230px;
  background: var(--white); border-top: 3px solid var(--orange);
  box-shadow: var(--shadow); border-radius: 0 0 var(--radius) var(--radius);
  opacity: 0; visibility: hidden; transform: translateY(8px);
  transition: opacity .2s, transform .2s, visibility .2s;
}
.dropdown a { display: block; padding: 12px 18px; }
.dropdown a:hover { background: var(--gray-light); }
.has-dropdown:hover .dropdown,
.has-dropdown.open .dropdown { opacity: 1; visibility: visible; transform: none; }

/* Hamburguesa */
.nav-toggle { display: none; background: none; border: 0; padding: 10px; cursor: pointer; z-index: 2; }
.nav-toggle span { display: block; width: 26px; height: 3px; margin: 5px 0; background: var(--black); border-radius: 2px; transition: transform .25s, opacity .25s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ---------- 4. HERO ---------- */
.hero { position: relative; padding: 48px 0 56px; overflow: hidden; }
.hero::before, .hero::after { /* pinceladas diagonales */
  content: ""; position: absolute; pointer-events: none; background: var(--orange);
}
.hero::before { top: 40px; left: -60px; width: 220px; height: 10px; transform: skewX(-45deg) rotate(-12deg); opacity: .9; box-shadow: 30px 18px 0 -2px var(--orange); }
.hero-inner { position: relative; display: grid; grid-template-columns: 0.8fr 1.5fr; align-items: center; gap: 24px; z-index: 1; width: min(1440px, 96%); }
.hero-text h1 { font-size: clamp(3.6rem, 7vw, 6.5rem); font-weight: 900; }
.hero-sub { font-family: var(--font-title); font-style: italic; font-weight: 800; text-transform: uppercase; font-size: clamp(1.8rem, 3.6vw, 2.9rem); line-height: 1.05; margin: 14px 0 18px; color: var(--black); }
.hero-sub span { color: var(--orange); }
.hero-slogan { font-weight: 500; font-size: 1.15rem; padding-top: 16px; border-top: 3px solid var(--orange); width: fit-content; margin: 0 0 24px; }
.hero-buttons { display: flex; flex-direction: column; gap: 14px; max-width: 390px; }
.hero-photo { position: relative; }
.hero-photo img {
  width: 100%; aspect-ratio: 4 / 3; object-fit: cover; background: #ddd;
  clip-path: polygon(12% 0, 100% 0, 100% 100%, 0 100%);
  border-bottom: 8px solid var(--orange);
}
.dots {
  position: absolute; left: 14px; bottom: 14px; width: 90px; height: 60px; opacity: .8;
  background-image: radial-gradient(var(--black) 2px, transparent 2.5px);
  background-size: 15px 15px;
}

/* ---------- 5. EXPERIENCIA ---------- */
.experience { padding: 56px 0; }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.card {
  display: grid; grid-template-columns: 1fr 1fr; overflow: hidden;
  background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow);
  transition: transform .25s, box-shadow .25s;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 12px 30px rgba(0, 0, 0, .14); }
.card-body { padding: 24px 8px 24px 22px; display: flex; flex-direction: column; justify-content: center; gap: 10px; }
.icon { display: grid; place-items: center; width: 58px; height: 58px; border-radius: 50%; background: var(--orange); }
.icon svg { width: 30px; height: 30px; }
.card h3 { font-size: 1.6rem; }
.card p { margin: 0; font-size: .95rem; }
.card-img { overflow: hidden; clip-path: polygon(22% 0, 100% 0, 100% 100%, 0 100%); border-right: 8px solid var(--orange); background: #ccc; min-height: 160px; }
.card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.card:hover .card-img img { transform: scale(1.08); }

/* ---------- 6. ÁLBUMES ---------- */
.albums { background: var(--gray-light); padding: 64px 0; background-image: radial-gradient(#d9dcdf 1.5px, transparent 2px); background-size: 20px 20px; }
.album-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.album { position: relative; display: block; aspect-ratio: 4 / 5; overflow: hidden; border-radius: var(--radius); background: var(--black); box-shadow: var(--shadow); }
.album img { width: 100%; height: 100%; object-fit: cover; opacity: .85; transition: transform .4s, opacity .3s; }
.album:hover img { transform: scale(1.08); opacity: 1; }
.album::after { content: ""; position: absolute; left: 0; bottom: 0; width: 100%; height: 6px; background: var(--orange); }
.album-label {
  position: absolute; inset: auto 0 6px 0; padding: 40px 16px 14px;
  background: linear-gradient(transparent, rgba(0, 0, 0, .85));
  color: var(--white); font-family: var(--font-title); font-style: italic; font-weight: 800;
  text-transform: uppercase; font-size: 1.35rem; line-height: 1.1;
}
.album-label small { display: block; margin-top: 4px; font-size: 1rem; font-weight: 700; color: var(--orange); }

/* ---------- 7. WHATSAPP ---------- */
.cta-whatsapp { background: var(--black); color: var(--white); padding: 48px 0; position: relative; overflow: hidden; }
.cta-whatsapp::before { content: ""; position: absolute; right: -40px; top: 0; width: 200px; height: 100%; background: var(--orange); transform: skewX(-20deg); opacity: .9; }
.cta-inner { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.cta-whatsapp h2 { color: var(--white); font-size: clamp(1.8rem, 4vw, 2.6rem); }
.cta-whatsapp p { margin: 8px 0 0; color: #ddd; }
.btn-wa { background: #25D366; border-color: #25D366; color: var(--black); gap: 10px; }
.btn-wa svg { width: 26px; height: 26px; }
.btn-wa:hover { background: #1fb858; border-color: #1fb858; }
.wa-float {
  position: fixed; right: 20px; bottom: 20px; z-index: 90;
  width: 58px; height: 58px; border-radius: 50%; background: #25D366;
  display: grid; place-items: center; box-shadow: 0 6px 18px rgba(0, 0, 0, .3);
  transition: transform .2s;
}
.wa-float:hover { transform: scale(1.1); }
.wa-float svg { width: 32px; height: 32px; }

/* ---------- 8. FOOTER ---------- */
.site-footer { background: #1a1a1a; color: #cfcfcf; padding-top: 40px; border-top: 6px solid var(--orange); }
.footer-inner { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 28px; align-items: start; }
.footer-brand { display: flex; align-items: center; gap: 14px; }
.footer-brand p { margin: 0; font-weight: 600; }
.footer-links, .socials { display: grid; gap: 6px; }
.site-footer a:hover { color: var(--orange); }
.copy { text-align: center; margin: 32px 0 0; padding: 18px 12px; font-size: .85rem; border-top: 1px solid #333; }

/* ---------- 9. RESPONSIVE ---------- */
@media (max-width: 1100px) {
  .cards { grid-template-columns: 1fr; }
  .album-grid { grid-template-columns: repeat(2, 1fr); }
  .main-nav > ul { gap: 20px; margin-right: 110px; }
}

@media (max-width: 900px) {
  .nav-toggle { display: block; margin-right: 10px; }
  .site-header::after { width: 90px; }
  .main-nav {
    position: absolute; top: 100%; left: 0; right: 0;
    background: var(--white); box-shadow: 0 12px 20px rgba(0, 0, 0, .1);
    max-height: 0; overflow: hidden; transition: max-height .35s ease;
  }
  .main-nav.open { max-height: 80vh; overflow-y: auto; border-top: 3px solid var(--orange); }
  .main-nav > ul { flex-direction: column; align-items: stretch; gap: 0; margin: 0; padding: 8px 6%; }
  .main-nav li { border-bottom: 1px solid #eee; }
  .main-nav a, .dropdown-toggle { display: block; width: 100%; text-align: left; padding: 14px 0; }
  .dropdown { position: static; box-shadow: none; border-top: 0; min-width: 0; opacity: 1; visibility: visible; transform: none; max-height: 0; overflow: hidden; transition: max-height .3s; }
  .has-dropdown:hover .dropdown { max-height: 0; }
  .has-dropdown.open .dropdown { max-height: 220px; }
  .dropdown a { padding-left: 16px; }

  .hero-inner { grid-template-columns: 1fr; }
  .hero-photo { order: -1; }
  .hero-buttons { max-width: none; }
  .footer-inner { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .album-grid { grid-template-columns: 1fr; }
  .album { aspect-ratio: 16 / 10; }
  .card { grid-template-columns: 1.2fr 1fr; }
  .section-title::before, .section-title::after { display: none; }
  .btn { font-size: 1.05rem; padding: 12px 16px; }
}


/* ---------- SUBMENÚ (Carrera 5K > Edición 4/20) ---------- */
.has-submenu { position: relative; }
.dropdown .submenu-toggle {
  display: flex; align-items: center; justify-content: space-between;
  width: 100%; padding: 12px 18px; text-align: left;
  font-family: var(--font-title); font-style: italic; font-weight: 700;
  font-size: 1.15rem; text-transform: uppercase; color: var(--black);
  background: none; border: 0; cursor: pointer;
}
.dropdown .submenu-toggle:hover, .has-submenu:hover > .submenu-toggle { background: var(--gray-light); color: var(--orange); }
.caret-right { transform: rotate(-45deg); }
.submenu {
  position: absolute; top: -3px; left: 100%; min-width: 190px;
  background: var(--white); border-top: 3px solid var(--orange);
  box-shadow: var(--shadow); border-radius: 0 var(--radius) var(--radius) 0;
  opacity: 0; visibility: hidden; transform: translateX(8px);
  transition: opacity .2s, transform .2s, visibility .2s;
}
.has-submenu:hover > .submenu, .has-submenu.open > .submenu { opacity: 1; visibility: visible; transform: none; }

@media (max-width: 900px) {
  .dropdown .submenu-toggle { padding: 14px 0 14px 16px; }
  .has-dropdown.open .dropdown { max-height: 340px; }
  .submenu { position: static; box-shadow: none; border-top: 0; min-width: 0; opacity: 1; visibility: visible; transform: none; max-height: 0; overflow: hidden; transition: max-height .3s; }
  .has-submenu:hover > .submenu { max-height: 0; }
  .has-submenu.open > .submenu { max-height: 120px; }
  .submenu a { padding-left: 32px; }
}

/* ---------- INSCRIPCIÓN 5K ---------- */
.page-banner { position: relative; overflow: hidden; background: var(--black); color: var(--white); padding: 56px 0 48px; }
.page-banner::after { content: ""; position: absolute; right: -40px; top: 0; width: 200px; height: 100%; background: var(--orange); transform: skewX(-20deg); opacity: .9; }
.page-banner .container { position: relative; z-index: 1; }
.page-banner h1 { color: var(--white); font-size: clamp(2.4rem, 6vw, 4.5rem); font-weight: 900; }
.page-banner h1 span { color: var(--orange); }
.page-banner p { margin: 14px 0 0; max-width: 620px; color: #ddd; font-size: 1.05rem; }

.signup { padding: 56px 0 72px; background: var(--gray-light); background-image: radial-gradient(#d9dcdf 1.5px, transparent 2px); background-size: 20px 20px; }
.signup-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 28px; align-items: start; }
.panel { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); border-top: 6px solid var(--orange); padding: 28px; }
.panel h2 { font-size: 1.8rem; margin-bottom: 20px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field.full { grid-column: 1 / -1; }
.field label { font-weight: 600; font-size: .92rem; color: var(--black); }
.field input[type="text"], .field input[type="email"], .field input[type="tel"], .field select {
  width: 100%; padding: 12px 14px; font: inherit; color: var(--black);
  background: var(--white); border: 2px solid #d5d8dc; border-radius: var(--radius);
  transition: border-color .2s, box-shadow .2s;
}
.field input:focus, .field select:focus { outline: none; border-color: var(--orange); box-shadow: 0 0 0 3px rgba(255, 69, 0, .18); }
.field .hint { font-size: .82rem; color: #666; }
.field .error { display: none; font-size: .82rem; color: #c0200a; font-weight: 600; }
.field.invalid input, .field.invalid select, .field.invalid .upload { border-color: #c0200a; }
.field.invalid .error { display: block; }
.hp { position: absolute; left: -9999px; height: 0; overflow: hidden; }

.upload-wrap { position: relative; }
.upload { display: grid; place-items: center; gap: 8px; text-align: center; padding: 22px; border: 2px dashed var(--orange); border-radius: var(--radius); background: #fff7f3; cursor: pointer; transition: background .2s; }
.upload:hover, .upload.drag { background: #ffece3; }
.upload input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.upload strong { font-family: var(--font-title); font-style: italic; text-transform: uppercase; font-size: 1.25rem; color: var(--black); }
.upload img { max-height: 220px; width: auto; border-radius: var(--radius); box-shadow: var(--shadow); }

.form-actions { margin-top: 26px; }
.form-actions .btn { width: 100%; max-width: 360px; }
.form-actions .btn:disabled { opacity: .6; cursor: wait; transform: none; box-shadow: none; }
.form-msg { display: none; margin-top: 18px; padding: 14px 16px; border-radius: var(--radius); font-weight: 600; }
.form-msg.ok { display: block; background: #e8f7ee; color: #12683a; border-left: 6px solid #1fb858; }
.form-msg.fail { display: block; background: #fdecea; color: #9b1c0c; border-left: 6px solid #c0200a; }

.pay-card { text-align: center; position: sticky; top: calc(var(--header-h) + 16px); }
.pay-card .qr { width: min(260px, 100%); margin: 0 auto 16px; aspect-ratio: 1; display: grid; place-items: center; padding: 12px; background: var(--white); border: 2px solid #e5e7ea; border-radius: var(--radius); overflow: hidden; color: #777; font-size: .9rem; }
.pay-card .qr img { width: 100%; height: 100%; object-fit: contain; }
.pay-data { text-align: left; display: grid; gap: 10px; margin: 0; }
.pay-data div { padding-bottom: 10px; border-bottom: 1px solid #eee; }
.pay-data dt { font-size: .8rem; color: #666; }
.pay-data dd { margin: 0; font-weight: 700; color: var(--black); }
.pay-price { font-family: var(--font-title); font-style: italic; font-weight: 900; font-size: 2.6rem; color: var(--orange); line-height: 1; margin: 6px 0 14px; }

@media (max-width: 1100px) { .signup-grid { grid-template-columns: 1fr; } .pay-card { position: static; } }
@media (max-width: 560px) { .form-grid { grid-template-columns: 1fr; } .panel { padding: 20px; } }

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}