/* ===========================================================
   Pinamar 2050 — capa estética futurista
   (se carga DESPUÉS de styles.css; reutiliza fondo, nav y footer)
   =========================================================== */

:root {
  --cyan: #22d3ee;
  --cyan-soft: rgba(34, 211, 238, 0.15);
}

/* Fondo más profundo para la sensación 2050 */
body.p50 { background: #02100a; overflow-x: hidden; }

/* ===== HERO ===== */
.p50-hero {
  position: relative;
  z-index: 1;
  min-height: 74vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 58px 24px 18px;
  overflow: hidden;
}

/* Grid en perspectiva (horizonte futurista) */
.p50-grid3d {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
  perspective: 420px;
}
.p50-grid3d::before {
  content: '';
  position: absolute;
  left: -60%;
  right: -60%;
  bottom: -10%;
  height: 130%;
  background-image:
    linear-gradient(rgba(34, 211, 238, 0.18) 1px, transparent 1px),
    linear-gradient(90deg, rgba(74, 222, 128, 0.14) 1px, transparent 1px);
  background-size: 44px 44px;
  transform: rotateX(66deg);
  transform-origin: bottom center;
  animation: p50-grid-move 7s linear infinite;
  -webkit-mask-image: linear-gradient(to top, #000 5%, transparent 65%);
  mask-image: linear-gradient(to top, #000 5%, transparent 65%);
}
@keyframes p50-grid-move { to { background-position: 0 44px; } }

/* Halo superior */
.p50-hero::after {
  content: '';
  position: absolute;
  top: -30%;
  left: 50%;
  width: 900px;
  height: 600px;
  transform: translateX(-50%);
  background: radial-gradient(ellipse at center, rgba(34, 211, 238, 0.16) 0%, transparent 60%);
  pointer-events: none;
  z-index: 0;
}

.p50-hero > * { position: relative; z-index: 1; }

.p50-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--cyan);
  border: 1px solid rgba(34, 211, 238, 0.35);
  background: rgba(34, 211, 238, 0.06);
  padding: 8px 18px;
  border-radius: 100px;
  margin-bottom: 28px;
  backdrop-filter: blur(4px);
}
.p50-badge-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 10px var(--cyan); animation: pulse 2s infinite; }

.p50-title {
  font-weight: 700;
  font-size: clamp(56px, 15vw, 150px);
  line-height: 0.92;
  letter-spacing: -0.05em;
  margin: 0;
  background: linear-gradient(100deg, #4ade80 0%, #22d3ee 45%, #a7f3d0 70%, #4ade80 100%);
  background-size: 220% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: p50-shine 6s linear infinite;
  text-shadow: 0 0 80px rgba(34, 211, 238, 0.25);
}
@keyframes p50-shine { to { background-position: 220% center; } }

.p50-tagline {
  font-family: var(--font-mono);
  font-size: clamp(14px, 2.4vw, 20px);
  letter-spacing: 0.45em;
  text-transform: uppercase;
  color: rgba(232, 245, 236, 0.7);
  margin: 14px 0 0;
  padding-left: 0.45em;
}

.p50-hero-sub {
  max-width: 560px;
  margin: 26px auto 34px;
  font-size: 17px;
  line-height: 1.7;
  color: var(--text-muted);
  font-weight: 300;
}

.p50-hero-actions { display: flex; gap: 14px; flex-wrap: wrap; justify-content: center; }
.p50-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 26px; border-radius: 10px; font-size: 14px; font-weight: 600;
  font-family: var(--font-main); text-decoration: none; cursor: pointer; transition: all 0.25s;
}
.p50-btn-primary {
  background: linear-gradient(100deg, var(--green-mid), var(--cyan));
  color: #04140a; border: none;
}
.p50-btn-primary:hover { box-shadow: 0 0 30px rgba(34, 211, 238, 0.4); transform: translateY(-2px); }
.p50-btn-ghost { background: transparent; border: 1px solid rgba(34, 211, 238, 0.3); color: var(--cyan); }
.p50-btn-ghost:hover { background: rgba(34, 211, 238, 0.1); border-color: var(--cyan); }

.p50-scroll-hint { margin-top: 24px; font-size: 22px; color: var(--cyan); animation: p50-bounce 2s infinite; }
@keyframes p50-bounce { 0%,100%{ transform: translateY(0);} 50%{ transform: translateY(8px);} }

/* ===== STATS ===== */
.p50-stats {
  position: relative; z-index: 1;
  max-width: 1180px; margin: -16px auto 50px; padding: 0 24px;
  display: flex; flex-wrap: wrap; gap: 14px; justify-content: center;
}
.p50-stat {
  flex: 1 1 170px; max-width: 220px;
  background: rgba(8, 22, 13, 0.7);
  border: 1px solid rgba(34, 211, 238, 0.18);
  border-radius: 16px; padding: 22px 18px; text-align: center;
  backdrop-filter: blur(8px);
}
.p50-stat-num { font-family: var(--font-mono); font-size: 30px; font-weight: 700; color: var(--cyan); letter-spacing: -0.02em; }
.p50-stat-label { font-size: 11px; color: var(--text-faint); text-transform: uppercase; letter-spacing: 0.07em; margin-top: 6px; }

/* ===== LAYOUT con sidebar derecha ===== */
.p50-layout {
  position: relative; z-index: 1;
  max-width: 1280px; margin: 0 auto; padding: 0 40px 80px;
  display: grid; grid-template-columns: minmax(0, 1fr) 250px; gap: 56px; align-items: start;
}

/* ===== SIDEBAR DERECHA ===== */
.p50-sidebar { position: sticky; top: 88px; }
.p50-sidebar-title {
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--text-faint); margin: 0 0 12px 14px;
}
.p50-nav { display: flex; flex-direction: column; gap: 2px; border-left: 1px solid rgba(34, 197, 94, 0.12); }
.p50-nav-link {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 16px; margin-left: -1px;
  font-size: 13.5px; color: var(--text-muted); text-decoration: none;
  border-left: 2px solid transparent; transition: all 0.2s;
}
.p50-nav-link:hover { color: var(--text-primary); }
.p50-nav-link.active { color: var(--cyan); border-left-color: var(--cyan); background: linear-gradient(90deg, var(--cyan-soft), transparent); }
.p50-nav-link .ico { font-size: 15px; width: 18px; text-align: center; }

/* ===== SECCIONES ===== */
.p50-section { padding: 56px 0 8px; scroll-margin-top: 80px; }
.p50-section-head { margin-bottom: 28px; }
.p50-eyebrow { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--cyan); }
.p50-h2 { font-size: clamp(24px, 4vw, 34px); font-weight: 700; letter-spacing: -0.02em; color: #fff; margin: 8px 0 0; }
.p50-lead { font-size: 16px; line-height: 1.75; color: rgba(232, 245, 236, 0.7); max-width: 760px; margin-top: 14px; }
.p50-lead strong { color: var(--cyan); font-weight: 600; }

/* Reveal on scroll */
.p50-reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.6s ease, transform 0.6s ease; }
.p50-reveal.in { opacity: 1; transform: none; }

/* ===== EJES (cards) ===== */
.p50-grid-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.p50-card {
  position: relative; overflow: hidden;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(34, 197, 94, 0.18);
  border-radius: 16px; padding: 26px; transition: all 0.3s;
}
.p50-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, transparent, var(--cyan), transparent); opacity: 0; transition: opacity 0.3s;
}
.p50-card:hover { transform: translateY(-4px); border-color: rgba(34, 211, 238, 0.5); box-shadow: 0 14px 40px rgba(0, 0, 0, 0.4), 0 0 30px rgba(34, 211, 238, 0.12); }
.p50-card:hover::before { opacity: 1; }
.p50-card-ico { font-size: 30px; margin-bottom: 14px; display: block; }
.p50-card h3 { font-size: 18px; font-weight: 600; color: #fff; margin: 0 0 8px; }
.p50-card p { font-size: 14px; line-height: 1.6; color: rgba(232, 245, 236, 0.55); margin: 0; }
a.p50-card { text-decoration: none; color: inherit; display: block; }
.p50-card-more { display: inline-block; margin-top: 14px; font-family: var(--font-mono); font-size: 12px; color: var(--cyan); opacity: 0.75; transition: opacity 0.2s; }
a.p50-card:hover .p50-card-more { opacity: 1; }

/* ===== TIMELINE FASES ===== */
.p50-timeline { position: relative; margin-top: 10px; padding-left: 30px; }
.p50-timeline::before { content: ''; position: absolute; left: 9px; top: 6px; bottom: 6px; width: 2px; background: linear-gradient(to bottom, var(--cyan), rgba(34, 197, 94, 0.15)); }
.p50-fase { position: relative; padding: 0 0 26px 26px; }
.p50-fase::before {
  content: ''; position: absolute; left: -26px; top: 3px; width: 20px; height: 20px; border-radius: 50%;
  background: #02100a; border: 2px solid var(--cyan); box-shadow: 0 0 12px rgba(34, 211, 238, 0.5);
}
.p50-fase.done::before { background: var(--cyan); }
.p50-fase-tag { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; padding: 3px 9px; border-radius: 100px; }
.p50-fase-tag.done { color: var(--green-bright); background: rgba(34, 197, 94, 0.12); border: 1px solid rgba(34, 197, 94, 0.3); }
.p50-fase-tag.curso { color: var(--cyan); background: rgba(34, 211, 238, 0.1); border: 1px solid rgba(34, 211, 238, 0.3); }
.p50-fase h3 { font-size: 17px; color: #fff; margin: 10px 0 4px; }
.p50-fase p { font-size: 14px; color: rgba(232, 245, 236, 0.55); line-height: 1.6; margin: 0; }

/* ===== PLANES DIRECTORES ===== */
.p50-plan {
  display: flex; align-items: center; gap: 16px;
  background: rgba(255, 255, 255, 0.02); border: 1px solid rgba(34, 197, 94, 0.15);
  border-radius: 14px; padding: 18px 20px; margin-bottom: 12px; transition: all 0.25s;
}
.p50-plan:hover { border-color: rgba(34, 211, 238, 0.4); background: rgba(34, 211, 238, 0.04); transform: translateX(4px); }
.p50-plan-ico { font-size: 26px; flex-shrink: 0; width: 46px; height: 46px; display: flex; align-items: center; justify-content: center; background: rgba(34, 211, 238, 0.08); border: 1px solid rgba(34, 211, 238, 0.2); border-radius: 12px; }
.p50-plan h3 { font-size: 16px; color: #fff; margin: 0 0 3px; }
.p50-plan p { font-size: 13px; color: rgba(232, 245, 236, 0.5); margin: 0; }

/* ===== LOCALIDADES (chips) ===== */
.p50-locs { display: flex; flex-wrap: wrap; gap: 10px; }
.p50-loc {
  font-family: var(--font-mono); font-size: 13px; color: var(--text-primary);
  padding: 10px 18px; border-radius: 100px; border: 1px solid rgba(34, 197, 94, 0.2); background: rgba(34, 197, 94, 0.04);
}
.p50-loc span { color: var(--cyan); }

/* ===== HISTORIA (línea de tiempo horizontal) ===== */
.p50-hist { display: flex; gap: 0; overflow-x: auto; padding: 12px 0 6px; }
.p50-hist-item { flex: 1 0 130px; position: relative; padding: 22px 12px 0; text-align: center; }
.p50-hist-item::before { content: ''; position: absolute; top: 6px; left: 0; right: 0; height: 2px; background: rgba(34, 211, 238, 0.25); }
.p50-hist-item::after { content: ''; position: absolute; top: 1px; left: 50%; transform: translateX(-50%); width: 11px; height: 11px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 10px var(--cyan); }
.p50-hist-item.future::after { background: #fff; box-shadow: 0 0 14px #fff; }
.p50-hist-year { font-family: var(--font-mono); font-size: 18px; font-weight: 700; color: var(--cyan); }
.p50-hist-item.future .p50-hist-year { color: #fff; }
.p50-hist-txt { font-size: 12px; color: rgba(232, 245, 236, 0.55); margin-top: 4px; line-height: 1.4; }

/* ===== DOCUMENTOS / CTA ===== */
.p50-docs { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.p50-doc {
  display: flex; align-items: center; gap: 12px; text-decoration: none;
  background: rgba(255, 255, 255, 0.02); border: 1px solid rgba(34, 197, 94, 0.15);
  border-radius: 12px; padding: 16px; transition: all 0.25s; color: inherit;
}
.p50-doc:hover { border-color: rgba(34, 211, 238, 0.4); background: rgba(34, 211, 238, 0.05); }
.p50-doc-ico { font-size: 22px; }
.p50-doc-name { font-size: 14px; color: #fff; font-weight: 500; }
.p50-doc-sub { font-size: 11px; color: var(--text-faint); }

.p50-cta {
  margin-top: 20px; text-align: center;
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.08), rgba(34, 197, 94, 0.05));
  border: 1px solid rgba(34, 211, 238, 0.25); border-radius: 20px; padding: 40px 28px;
}
.p50-cta h2 { font-size: 26px; color: #fff; margin: 0 0 10px; }
.p50-cta p { color: var(--text-muted); margin: 0 0 22px; font-size: 15px; }

/* Fases clickeables (llevan al resumen) */
a.p50-fase { display: block; text-decoration: none; color: inherit; transition: all 0.25s; border-radius: 12px; }
a.p50-fase:hover { background: rgba(34, 211, 238, 0.05); box-shadow: -10px 0 0 rgba(34, 211, 238, 0.05); }
a.p50-fase:hover h3 { color: var(--cyan); }
.p50-fase-arrow { font-size: 12px; color: var(--cyan); opacity: 0; transition: opacity 0.2s; margin-left: 6px; }
a.p50-fase:hover .p50-fase-arrow { opacity: 1; }

/* ===== DETALLE DE DOCUMENTO (plan.html) ===== */
.plan-hero { padding: 30px 0 6px; }
.plan-estado { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.08em; text-transform: uppercase; padding: 3px 9px; border-radius: 100px; margin-left: 10px; }
.plan-estado.done { color: var(--green-bright); background: rgba(34, 197, 94, 0.12); border: 1px solid rgba(34, 197, 94, 0.3); }
.plan-estado.curso { color: var(--cyan); background: rgba(34, 211, 238, 0.1); border: 1px solid rgba(34, 211, 238, 0.3); }
.plan-block { border-left: 2px solid rgba(34, 211, 238, 0.3); padding: 2px 0 2px 22px; margin: 0 0 26px; }
.plan-block h3 { font-size: 18px; color: #fff; margin: 0 0 10px; }
.plan-block p { font-size: 15px; line-height: 1.7; color: rgba(232, 245, 236, 0.7); margin: 0 0 10px; }
.plan-items { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 0; list-style: none; padding: 0; }
.plan-items li { font-family: var(--font-mono); font-size: 12px; color: var(--cyan); background: rgba(34, 211, 238, 0.07); border: 1px solid rgba(34, 211, 238, 0.2); padding: 6px 12px; border-radius: 100px; }
.plan-pdf-cta {
  margin-top: 32px; display: flex; flex-wrap: wrap; gap: 16px; align-items: center;
  padding: 26px; border: 1px solid rgba(34, 211, 238, 0.25); border-radius: 18px;
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.07), rgba(34, 197, 94, 0.04));
}
.plan-pdf-cta .info { flex: 1 1 220px; }
.plan-pdf-cta .info strong { color: #fff; font-size: 16px; display: block; margin-bottom: 2px; }
.plan-pdf-cta .info span { font-size: 13px; color: var(--text-muted); }

/* ===== RESPONSIVE ===== */
@media (max-width: 920px) {
  .p50-layout { grid-template-columns: minmax(0, 1fr); gap: 0; padding: 0 20px 60px; }
  .p50-sidebar { display: none; }
}
@media (max-width: 768px) {
  .p50-hero { min-height: 66vh; padding: 44px 20px 16px; }
  .p50-stats { margin: -8px auto 40px; }
  .p50-stat { flex: 1 1 130px; padding: 16px 12px; }
  .p50-stat-num { font-size: 24px; }
  .p50-section { padding: 40px 0 4px; }

  /* Evitar desbordamiento horizontal: cards en columna única */
  .p50-grid-cards { grid-template-columns: 1fr; }

  /* Asegurar que nada exceda el ancho de pantalla */
  .p50-hero,
  .p50-stats,
  .p50-layout,
  .p50-section { max-width: 100%; overflow-x: hidden; }

  /* Badge en un solo renglón */
  .p50-badge { font-size: 9px; letter-spacing: 0.08em; padding: 6px 12px; }
  /* Título principal más grande */
  .p50-title { font-size: clamp(52px, 15vw, 80px); }
  .p50-card p, .p50-lead { overflow-wrap: break-word; }
}
