/* ==========================================================================
   OliMedia — Landing "Gestión de Campañas de Paid Media" (/paid-media/)
   Hoja de estilos EXCLUSIVA de esta página. Solo se carga aquí (ver
   inc/paid-media.php → pm_assets). Todas las clases usan el prefijo
   .pm- para no chocar con el resto del tema.
   Reutiliza a propósito los tokens y componentes globales de style.css
   (--green, --ink, .btn, .form, .grid-3, .info-card, .reveal, .cta-final…)
   para mantener coherencia visual total con olimedia.es.
   ========================================================================== */

.pm-page { background: var(--bg); }
.pm-page section { position: relative; }

/* ---------- Header minimalista ---------- */
.pm-header .header__inner {
  padding-block: 16px;
  justify-content: space-between;
  flex-wrap: nowrap;
}
.pm-header__cta {
  flex: none;
  margin-left: auto;
  padding: 11px 20px;
  font-size: .86rem;
}
@media (max-width: 560px) {
  .pm-header__cta span { display: none; }
  .pm-header__cta::after { content: "Info"; }
}

/* ---------- Hero ---------- */
.pm-hero { padding-top: clamp(48px, 8vw, 88px); }
.pm-hero h1 { margin: 14px 0 6px; }
.pm-hero__line2 {
  display: block;
  color: var(--green);
}
.pm-hero__sub {
  font-size: 1.12rem;
  color: var(--text-muted);
  max-width: 46em;
  margin: 18px 0 30px;
}
.pm-cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 22px;
}
.pm-cta-row .btn--text {
  font-weight: 600;
  color: var(--brown);
  border-bottom: 1.5px solid var(--border);
  padding-bottom: 2px;
  transition: color var(--t), border-color var(--t);
}
.pm-cta-row .btn--text:hover { color: var(--green); border-color: var(--green); }
.pm-micro {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: .86rem;
  color: var(--text-muted);
  margin-top: 20px;
}
.pm-micro svg { flex: none; color: var(--green); }

/* ---------- Visual conceptual del hero (dashboard de campaña, estilo "tarjeta 3D") ---------- */
.pm-dashvisual-wrap {
  position: relative;
  width: 100%;
  max-width: 360px;
}
.pm-dashvisual-wrap::before {
  content: "";
  position: absolute;
  inset: 14px -14px -14px 14px;
  border: 1.5px solid rgba(72,51,51,.14);
  border-radius: 22px;
  z-index: 0;
}
.pm-dashvisual {
  position: relative;
  z-index: 1;
  width: 100%;
  background: linear-gradient(165deg, #1c1b1a 0%, #262220 55%, var(--brown) 140%);
  border-radius: 22px;
  padding: 24px 24px 26px;
  box-shadow: 0 30px 60px -22px rgba(20,20,20,.45);
  color: #fff;
}
.pm-dashvisual__dot { width: 9px; height: 9px; border-radius: 50%; background: rgba(255,255,255,.25); display: inline-block; }
.pm-dashvisual__dots { display: flex; gap: 6px; margin-bottom: 20px; }
.pm-dashvisual__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 20px;
}
.pm-dashvisual__label {
  font-size: .92rem;
  font-weight: 600;
  letter-spacing: -.01em;
  color: rgba(255,255,255,.9);
}
.pm-dashvisual__delta {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: .8rem;
  font-weight: 700;
  color: #fff;
  background: var(--green);
  padding: 6px 12px;
  border-radius: 999px;
  box-shadow: 0 8px 18px -8px rgba(99,142,118,.7);
}
.pm-dashvisual__chart {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  height: 96px;
  padding: 0 2px;
}
.pm-dashvisual__chart span {
  position: relative;
  flex: 1;
  height: var(--h);
  border-radius: 6px;
  background:
    linear-gradient(100deg, rgba(255,255,255,.5) 0%, rgba(255,255,255,0) 22%),
    linear-gradient(180deg, #a9d4bb 0%, var(--green) 55%, #3f6b52 100%);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.6),
    inset -3px 0 6px rgba(20,20,20,.18),
    0 10px 14px -8px rgba(20,20,20,.55);
}
.pm-dashvisual__channels {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}
.pm-dashvisual__channel {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: .74rem;
  font-weight: 600;
  letter-spacing: .01em;
  color: rgba(255,255,255,.85);
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.14);
  padding: 6px 11px 6px 8px;
  border-radius: 999px;
}
.pm-dashvisual__channel-icon { flex: none; display: block; }
.pm-dashvisual__slot {
  margin-top: 20px;
  border: 1.5px dashed rgba(255,255,255,.32);
  border-radius: 13px;
  padding: 14px 16px;
  background: rgba(255,255,255,.04);
}
.pm-dashvisual__slot-top {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}
.pm-dashvisual__slot-icon {
  flex: none; width: 30px; height: 30px; border-radius: 8px;
  background: var(--green); color: #fff;
  display: grid; place-items: center;
}
.pm-dashvisual__slot-tag {
  font-size: .68rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: rgba(255,255,255,.85);
}
.pm-dashvisual__track {
  display: flex;
  align-items: center;
  gap: 3px;
}
.pm-dashvisual__node {
  flex: none;
  width: 15px; height: 15px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--green);
}
.pm-dashvisual__node.is-current {
  width: 11px; height: 11px;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(255,255,255,.22);
}
.pm-dashvisual__node.is-pending {
  width: 7px; height: 7px;
  background: rgba(255,255,255,.28);
}
.pm-dashvisual__connector {
  flex: 1;
  height: 2px;
  background: rgba(255,255,255,.18);
}
.pm-dashvisual__connector.is-done { background: var(--green); }
@media (max-width: 768px) {
  .pm-dashvisual-wrap { max-width: 400px; margin: 0 auto; }
}

/* ---------- Frase de impacto ---------- */
.pm-impact {
  background: var(--ink);
  color: #fff;
  text-align: center;
  padding: clamp(56px, 9vw, 100px) 0;
}
.pm-impact__quote {
  color: #fff;
  font-size: clamp(1.7rem, 3.8vw, 2.7rem);
  font-weight: 700;
  letter-spacing: -.02em;
  line-height: 1.25;
  max-width: 20em;
  margin: 0 auto;
}
.pm-impact__sub {
  color: rgba(255,255,255,.72);
  font-size: 1.05rem;
  max-width: 34em;
  margin: 20px auto 34px;
}

/* ---------- Proceso: auditoría / lanzamiento / optimización ---------- */
.pm-flow {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
  max-width: 760px;
  margin: 0 auto;
}
.pm-flow__step {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
  width: 168px;
}
.pm-flow__icon {
  width: 62px; height: 62px; border-radius: 50%;
  background: var(--green-soft); color: var(--green);
  display: grid; place-items: center;
}
.pm-flow__step strong { font-size: 1.02rem; color: var(--brown); }
.pm-flow__step span { font-size: .88rem; color: var(--text-muted); }
.pm-flow__arrow { color: var(--gray); flex: none; }
@media (max-width: 680px) {
  .pm-flow { flex-direction: column; gap: 26px; }
  .pm-flow__arrow { transform: rotate(90deg); }
}

/* ---------- Inversión ---------- */
.pm-invest { text-align: center; }
.pm-invest__card {
  max-width: 560px;
  margin: 0 auto;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  padding: clamp(30px, 5vw, 46px);
}
.pm-invest__text {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--brown);
  line-height: 1.5;
}
.pm-invest__note {
  font-size: .88rem;
  color: var(--text-muted);
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

/* ---------- Formulario ---------- */
.pm-form-section .section-head { margin-bottom: 30px; }
.pm-form-wrap { max-width: 640px; margin: 0 auto; }
.pm-form-wrap .form__row--3 { grid-template-columns: 1fr 1fr; }
.pm-form-counter {
  display: block;
  text-align: right;
  font-size: .78rem;
  color: var(--text-muted);
  margin-top: 6px;
}
.pm-form-counter.is-max { color: var(--green-dark); font-weight: 600; }

.pm-form-note {
  text-align: center;
  font-size: .85rem;
  color: var(--text-muted);
  margin-top: 14px;
}

/* Franja de prueba social, justo encima del formulario */
.pm-proof {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 14px;
  text-align: center;
  font-size: .88rem;
  color: var(--text-muted);
  margin: 0 auto 34px;
}
.pm-proof strong { color: var(--brown); }

/* Éxito tras enviar */
.pm-success {
  max-width: 560px;
  margin: 0 auto;
  text-align: center;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: clamp(36px, 5vw, 54px) clamp(24px, 5vw, 40px);
}
.pm-success__icon {
  width: 72px; height: 72px; margin: 0 auto 22px;
  border-radius: 50%;
  background: var(--green-soft); color: var(--green);
  display: grid; place-items: center;
  animation: pmSuccessPop .5s cubic-bezier(.2,.8,.2,1) both;
}
@keyframes pmSuccessPop { 0% { transform: scale(.6); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
.pm-success p { color: var(--text-muted); margin-top: 10px; }
@media (prefers-reduced-motion: reduce) { .pm-success__icon { animation: none; } }

/* Honeypot: oculto para personas, visible para bots que ignoran CSS */
.pm-hp { position: absolute; left: -9999px; top: -9999px; }

/* ---------- Footer minimalista ---------- */
.pm-footer {
  border-top: 1px solid var(--border);
  padding: 26px 0;
}
.pm-footer .container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 20px;
  font-size: .84rem;
  color: var(--text-muted);
}
.pm-footer__legal { display: flex; gap: 18px; flex-wrap: wrap; }
.pm-footer__legal a { color: var(--text-muted); transition: color var(--t); }
.pm-footer__legal a:hover { color: var(--green); }

/* ---------- Popup de cierre ---------- */
.pm-popup {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.pm-popup.is-open { display: flex; }
.pm-popup__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(20,20,20,.6);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
}
.pm-popup__dialog {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 520px;
  max-height: 92vh;
  overflow: auto;
  text-align: center;
  background: linear-gradient(160deg, var(--ink) 0%, #262220 60%, var(--brown) 130%);
  color: #fff;
  border-radius: 20px;
  padding: clamp(32px, 5vw, 48px) clamp(24px, 5vw, 40px);
  box-shadow: 0 40px 90px -30px rgba(20,20,20,.6);
  animation: pmPopupIn .3s cubic-bezier(.2,.8,.2,1);
}
@keyframes pmPopupIn { from { opacity: 0; transform: translateY(16px) scale(.98); } to { opacity: 1; transform: none; } }
.pm-popup__dialog h2 {
  color: #fff;
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  margin: 0 0 14px;
}
.pm-popup__dialog p {
  color: rgba(255,255,255,.76);
  font-size: 1rem;
  margin: 0 0 26px;
}
.pm-popup__x {
  position: absolute;
  top: 14px; right: 14px;
  width: 38px; height: 38px;
  border-radius: 50%;
  background: rgba(255,255,255,.1);
  color: #fff;
  display: grid;
  place-items: center;
  transition: background var(--t);
}
.pm-popup__x:hover { background: rgba(255,255,255,.22); }
body.pm-popup-open { overflow: hidden; }
@media (prefers-reduced-motion: reduce) { .pm-popup__dialog { animation: none; } }

/* ---------- Barra CTA fija (móvil) ---------- */
.pm-stickybar {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 40;
  background: #fff;
  border-top: 1px solid var(--border);
  box-shadow: 0 -12px 30px -18px rgba(20,20,20,.25);
  padding: 12px 16px;
  padding-bottom: max(12px, env(safe-area-inset-bottom));
  transform: translateY(110%);
  transition: transform .3s ease;
  display: none;
}
.pm-stickybar.is-visible { transform: translateY(0); }
.pm-stickybar .btn { width: 100%; justify-content: center; }
@media (max-width: 760px) {
  .pm-stickybar { display: block; }
}

/* ---------- Ajustes responsive generales de la landing ---------- */
@media (max-width: 768px) {
  .pm-form-wrap .form__row--3 { grid-template-columns: 1fr; }
}
