/*
Theme Name:  Media Digital Studio
Theme URI:   https://mediadigitalstudio.online
Author:      Media Digital Studio
Author URI:  https://mediadigitalstudio.online
Description: Tema de WordPress que replica exactamente el diseño de Media Digital Studio. 100% compatible con Elementor.
Version:     2.0.0
Requires at least: 6.0
Tested up to: 6.6
Requires PHP: 7.4
License:     GNU General Public License v2 or later
Text Domain: mds
Tags:        elementor, page-builder, full-width-template
*/

/* ══════════════════════════════════════════
   VARIABLES & RESET
══════════════════════════════════════════ */
:root {
  --pink:    #E6007E;
  --navy:    #2A2C62;
  --white:   #FFFFFF;
  --gray:    #EDEDED;
  --trans:   0.25s ease;
}
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Montserrat', sans-serif;
  background: var(--white);
  color: var(--navy);
  overflow-x: hidden;
}
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--navy); }
::-webkit-scrollbar-thumb { background: var(--pink); }
img { max-width: 100%; }
a { text-decoration: none; }
ul { list-style: none; }

/* ══════════════════════════════════════════
   NAV FIJA
══════════════════════════════════════════ */
.mds-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 5vw;
  background: rgba(42,44,98,.97);
  border-bottom: 2px solid var(--pink);
  transition: padding .3s;
}
.mds-logo {
  display: inline-flex;
  align-items: center;
  line-height: 1;
  flex-shrink: 0;
}
.mds-logo img,
.mds-logo svg {
  height: 36px;
  width: auto;
}
/* Forzar logo personalizado al tamaño correcto */
.mds-logo .custom-logo { height: 36px; width: auto; display: block; }

.mds-nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
  list-style: none;
  margin: 0 auto;
  padding: 0 2vw;
}
.mds-nav-links li { display: flex; align-items: center; }
.mds-nav-links a {
  color: var(--white);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  position: relative;
  padding: 6px 10px;
  transition: color var(--trans);
  white-space: nowrap;
}
.mds-nav-links a::after {
  content: '';
  position: absolute;
  bottom: 2px; left: 10px; right: 10px;
  height: 2px;
  background: var(--pink);
  transform: scaleX(0);
  transition: transform .3s;
}
.mds-nav-links a:hover { color: var(--pink); }
.mds-nav-links a:hover::after { transform: scaleX(1); }
/* Link activo (Inicio resaltado como en la imagen) */
.mds-nav-links .current-menu-item a,
.mds-nav-links a.active { color: var(--pink); }
.mds-nav-links .current-menu-item a::after,
.mds-nav-links a.active::after { transform: scaleX(1); }

.mds-nav-cta {
  color: var(--white) !important;
  background: var(--pink) !important;
  padding: 10px 24px !important;
  border: 2px solid var(--pink);
  border-radius: 2px;
  font-size: 10.5px !important;
  font-weight: 800 !important;
  letter-spacing: 2px !important;
  text-transform: uppercase !important;
  transition: all var(--trans);
  white-space: nowrap;
}
.mds-nav-cta::after { display: none !important; }
.mds-nav-cta:hover {
  background: transparent !important;
  color: var(--pink) !important;
}

.mds-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  flex-shrink: 0;
}
.mds-hamburger span {
  width: 24px; height: 2px;
  background: white;
  display: block;
}

/* ══════════════════════════════════════════
   MENÚ MÓVIL
══════════════════════════════════════════ */
.mds-mob-menu {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9998;
  background: var(--navy);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 32px;
}
.mds-mob-menu.open { display: flex; }
.mds-mob-menu a {
  color: white;
  font-size: 24px;
  font-weight: 900;
  letter-spacing: 2px;
  text-transform: uppercase;
  transition: color var(--trans);
}
.mds-mob-menu a:hover { color: var(--pink); }
.mds-mob-close {
  position: absolute;
  top: 20px; right: 6vw;
  background: none;
  border: none;
  color: white;
  font-size: 30px;
  cursor: pointer;
}

/* ══════════════════════════════════════════
   BODY OFFSET (para la nav fija)
══════════════════════════════════════════ */
body { padding-top: 62px; }

/* ══════════════════════════════════════════
   HERO / INICIO
══════════════════════════════════════════ */
#inicio {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  background-color: var(--navy);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  padding: 110px 6vw 90px;
}
#inicio::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(42,44,98,.82);
  z-index: 1;
}
.hero-shapes { position: absolute; inset: 0; pointer-events: none; z-index: 1; }
.hs { position: absolute; opacity: .05; border-radius: 12px; }
.hs1 { width: 380px; height: 380px; border: 55px solid var(--pink); transform: rotate(18deg); top: -80px; right: -60px; animation: fl 9s ease-in-out infinite; }
.hs2 { width: 220px; height: 220px; border: 36px solid var(--pink); transform: rotate(-12deg); bottom: 80px; right: 22vw; animation: fl2 12s ease-in-out infinite; }
.hs3 { width: 110px; height: 110px; background: var(--pink); transform: rotate(30deg); bottom: -20px; left: 35vw; animation: fl 15s ease-in-out infinite reverse; }
@keyframes fl  { 0%,100%{transform:rotate(18deg) translateY(0)} 50%{transform:rotate(18deg) translateY(-18px)} }
@keyframes fl2 { 0%,100%{transform:rotate(-12deg) translateY(0)} 50%{transform:rotate(-12deg) translateY(16px)} }
.hero-inner {
  position: relative;
  z-index: 2;
  max-width: 680px;
  animation: fadeUp .9s cubic-bezier(.16,1,.3,1) both;
}
@keyframes fadeUp { from{opacity:0;transform:translateY(36px)} to{opacity:1;transform:translateY(0)} }
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(230,0,126,.15);
  border: 1px solid var(--pink);
  color: var(--pink);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 2px;
  margin-bottom: 28px;
}
.hero-badge::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--pink);
  animation: pulse 1.5s infinite;
}
@keyframes pulse { 0%,100%{opacity:1} 50%{opacity:.2} }
.hero-h1 {
  font-size: clamp(36px,5.5vw,78px);
  font-weight: 900;
  line-height: 1.05;
  color: white;
  margin-bottom: 22px;
  letter-spacing: -1px;
}
.hero-h1 em { font-style: normal; color: var(--pink); border-bottom: 4px solid var(--pink); }
.hero-p {
  font-size: clamp(13px,1.3vw,17px);
  color: rgba(255,255,255,.7);
  line-height: 1.75;
  max-width: 500px;
  margin-bottom: 40px;
}
.hero-btns { display: flex; gap: 14px; flex-wrap: wrap; }
.btn-fill {
  background: var(--pink);
  color: white;
  padding: 15px 34px;
  border: 2px solid var(--pink);
  border-radius: 2px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  transition: all var(--trans);
  box-shadow: 0 0 28px rgba(230,0,126,.4);
}
.btn-fill:hover { background: transparent; color: var(--pink); box-shadow: none; }
.btn-ghost {
  background: transparent;
  color: white;
  padding: 15px 34px;
  border: 2px solid rgba(255,255,255,.3);
  border-radius: 2px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  transition: border-color var(--trans);
}
.btn-ghost:hover { border-color: white; }
.hero-stats {
  position: absolute;
  bottom: 48px; right: 6vw;
  z-index: 2;
  display: flex;
  gap: 40px;
  animation: fadeUp 1s .3s cubic-bezier(.16,1,.3,1) both;
}
.stat { text-align: center; }
.stat-n { font-size: clamp(26px,3vw,44px); font-weight: 900; color: var(--pink); line-height: 1; }
.stat-l { font-size: 9px; font-weight: 700; letter-spacing: 2px; text-transform: uppercase; color: rgba(255,255,255,.45); margin-top: 4px; }
.scroll-hint {
  position: absolute; bottom: 44px; left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  animation: bounce 2s infinite;
}
.scroll-hint span { font-size: 8px; font-weight: 700; letter-spacing: 3px; color: rgba(255,255,255,.35); text-transform: uppercase; }
.scroll-arr { width: 16px; height: 16px; border-right: 2px solid rgba(255,255,255,.3); border-bottom: 2px solid rgba(255,255,255,.3); transform: rotate(45deg); }
@keyframes bounce { 0%,100%{transform:translateX(-50%) translateY(0)} 50%{transform:translateX(-50%) translateY(8px)} }

/* ══════════════════════════════════════════
   SECCIONES COMUNES
══════════════════════════════════════════ */
section { padding: 110px 6vw 90px; }
.tag { display: inline-block; font-size: 10px; font-weight: 800; letter-spacing: 4px; text-transform: uppercase; color: var(--pink); margin-bottom: 12px; }
.title { font-size: clamp(30px,4vw,58px); font-weight: 900; line-height: 1.08; letter-spacing: -1px; margin-bottom: 16px; }
.sub { font-size: 14px; font-weight: 400; line-height: 1.75; color: #666; max-width: 500px; margin-bottom: 52px; }

/* ══════════════════════════════════════════
   SERVICIOS
══════════════════════════════════════════ */
#servicios { background: white; }
.srv-header { display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; gap: 20px; margin-bottom: 52px; }
.srv-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 2px; }
.srv-card {
  background: var(--gray);
  padding: 44px 32px;
  position: relative;
  overflow: hidden;
  cursor: default;
  transition: box-shadow .35s;
}
.srv-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--navy);
  transform: translateY(102%);
  transition: transform .4s cubic-bezier(.4,0,.2,1);
}
.srv-card:hover::before { transform: translateY(0); }
.srv-card:hover { box-shadow: 0 16px 50px rgba(42,44,98,.25); }
.srv-card > * { position: relative; z-index: 1; }
.srv-num { position: absolute; top: 20px; right: 24px; font-size: 10px; font-weight: 800; letter-spacing: 2px; color: rgba(0,0,0,.1); transition: color .35s; }
.srv-card:hover .srv-num { color: rgba(255,255,255,.1); }
.srv-ico { width: 50px; height: 50px; background: var(--pink); border-radius: 4px; display: flex; align-items: center; justify-content: center; margin-bottom: 24px; transition: transform .35s; }
.srv-card:hover .srv-ico { transform: rotate(-8deg) scale(1.1); }
.srv-ico svg { width: 24px; height: 24px; stroke: white; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.srv-name { font-size: 17px; font-weight: 800; margin-bottom: 10px; transition: color .35s; }
.srv-card:hover .srv-name { color: white; }
.srv-desc { font-size: 12.5px; line-height: 1.65; color: #777; transition: color .35s; }
.srv-card:hover .srv-desc { color: rgba(255,255,255,.65); }

/* ══════════════════════════════════════════
   PORTAFOLIO
══════════════════════════════════════════ */
#portafolio { background: var(--navy); }
#portafolio .title { color: white; }
#portafolio .sub   { color: rgba(255,255,255,.5); }
.port-grid { display: grid; grid-template-columns: repeat(12,1fr); gap: 14px; }
.port-item { position: relative; overflow: hidden; border-radius: 2px; cursor: pointer; }
.port-item.a { grid-column: span 7; height: 360px; }
.port-item.b { grid-column: span 5; height: 360px; }
.port-item.c { grid-column: span 4; height: 230px; }
.port-item.d { grid-column: span 4; height: 230px; }
.port-item.e { grid-column: span 4; height: 230px; }
.port-media { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s cubic-bezier(.4,0,.2,1); }
.port-item:hover .port-media { transform: scale(1.06); }
.port-ph { width: 100%; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; border: 2px dashed rgba(255,255,255,.2); transition: transform .5s cubic-bezier(.4,0,.2,1); }
.port-item:hover .port-ph { transform: scale(1.03); }
.ph-bg1 { background: linear-gradient(135deg, #1a1c42, #2A2C62); }
.ph-bg2 { background: linear-gradient(135deg, #3d0030, #E6007E22); }
.ph-bg3 { background: linear-gradient(135deg, #111, #1a1c42); }
.ph-bg4 { background: linear-gradient(135deg, #2A2C62, #111); }
.ph-bg5 { background: linear-gradient(135deg, #1a003a, #E6007E18); }
.port-ov { position: absolute; inset: 0; background: linear-gradient(to top, rgba(42,44,98,.95) 0%, transparent 55%); opacity: 0; transition: opacity .35s; display: flex; align-items: flex-end; padding: 24px; }
.port-item:hover .port-ov { opacity: 1; }
.p-cat { font-size: 9px; font-weight: 700; letter-spacing: 3px; text-transform: uppercase; color: var(--pink); margin-bottom: 5px; }
.p-ttl { font-size: 17px; font-weight: 800; color: white; }

/* ══════════════════════════════════════════
   CONTACTOS
══════════════════════════════════════════ */
#contactos { background: var(--gray); }
.ct-wrap { display: grid; grid-template-columns: 1fr 1.3fr; gap: 72px; align-items: start; }
.ct-info { display: flex; flex-direction: column; gap: 18px; margin-top: 40px; }
.ci-block { display: flex; align-items: flex-start; gap: 14px; }
.ci-ico { width: 42px; height: 42px; flex-shrink: 0; background: var(--navy); border-radius: 3px; display: flex; align-items: center; justify-content: center; }
.ci-ico svg { width: 18px; height: 18px; stroke: var(--pink); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.ci-lbl { font-size: 9px; font-weight: 700; letter-spacing: 2px; text-transform: uppercase; color: #999; margin-bottom: 3px; }
.ci-val { font-size: 13px; font-weight: 600; color: var(--navy); }
.wa-btn { display: inline-flex; align-items: center; gap: 12px; background: #25D366; color: white; padding: 14px 24px; border-radius: 4px; font-size: 13px; font-weight: 700; letter-spacing: 1px; transition: background var(--trans), transform var(--trans); box-shadow: 0 4px 20px rgba(37,211,102,.35); margin-top: 4px; }
.wa-btn:hover { background: #1ebe5d; transform: translateY(-2px); }
.wa-btn svg { width: 22px; height: 22px; fill: white; flex-shrink: 0; }
.wa-badge { font-size: 9px; font-weight: 800; letter-spacing: 2px; text-transform: uppercase; color: rgba(255,255,255,.7); margin-bottom: 8px; display: block; }

/* ══════════════════════════════════════════
   FORMULARIO MULTI-PASO
══════════════════════════════════════════ */
.form-box { background: white; padding: 44px; border-radius: 4px; box-shadow: 0 16px 50px rgba(0,0,0,.08); }
.steps { display: flex; align-items: center; margin-bottom: 28px; }
.step { display: flex; flex-direction: column; align-items: center; flex: 1; position: relative; }
.step:not(:last-child)::after { content: ''; position: absolute; top: 14px; left: 50%; right: -50%; height: 2px; background: var(--gray); z-index: 0; }
.step.done::after { background: var(--pink); }
.step-dot { width: 28px; height: 28px; border-radius: 50%; border: 2px solid var(--gray); background: white; display: flex; align-items: center; justify-content: center; font-size: 10px; font-weight: 800; color: #bbb; position: relative; z-index: 1; transition: all .3s; }
.step.active .step-dot { border-color: var(--pink); color: var(--pink); }
.step.done   .step-dot { border-color: var(--pink); background: var(--pink); color: white; }
.step-lbl { font-size: 8px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; color: #bbb; margin-top: 6px; text-align: center; transition: color .3s; }
.step.active .step-lbl { color: var(--pink); }
.step.done   .step-lbl { color: var(--navy); }
.prog-bar { height: 3px; background: var(--gray); border-radius: 2px; margin-bottom: 28px; overflow: hidden; }
.prog-fill { height: 100%; background: var(--pink); border-radius: 2px; transition: width .6s cubic-bezier(.4,0,.2,1); width: 0%; }
.alert-box { background: rgba(230,0,126,.07); border: 1px solid var(--pink); border-radius: 2px; padding: 12px 16px; font-size: 12px; font-weight: 600; color: var(--pink); margin-bottom: 16px; display: none; align-items: center; gap: 10px; }
.alert-box.show { display: flex; }
.alert-box::before { content: '⚠'; font-size: 16px; }
.f-panel { display: none; }
.f-panel.active { display: block; }
.f-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.fg { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.fg label { font-size: 9px; font-weight: 800; letter-spacing: 2px; text-transform: uppercase; color: #888; }
.fg input, .fg select, .fg textarea { padding: 12px 14px; border: 2px solid var(--gray); border-radius: 2px; font-family: 'Montserrat', sans-serif; font-size: 13px; font-weight: 500; color: var(--navy); outline: none; transition: border-color .2s, box-shadow .2s; background: white; }
.fg input:focus, .fg select:focus, .fg textarea:focus { border-color: var(--pink); box-shadow: 0 0 0 4px rgba(230,0,126,.07); }
.fg textarea { resize: vertical; min-height: 90px; }
.fg.err input, .fg.err select, .fg.err textarea { border-color: var(--pink); }
.err-msg { font-size: 10px; font-weight: 700; color: var(--pink); display: none; }
.fg.err .err-msg { display: block; }
.f-btn { width: 100%; padding: 15px; background: var(--pink); color: white; border: 2px solid var(--pink); border-radius: 2px; font-family: 'Montserrat', sans-serif; font-size: 11px; font-weight: 800; letter-spacing: 3px; text-transform: uppercase; cursor: pointer; transition: all .25s; box-shadow: 0 6px 24px rgba(230,0,126,.28); margin-top: 8px; }
.f-btn:hover { background: var(--navy); border-color: var(--navy); box-shadow: none; }
.sending-steps { display: flex; flex-direction: column; gap: 14px; padding: 10px 0; }
.send-step { display: flex; align-items: center; gap: 14px; padding: 12px 16px; border-radius: 3px; background: var(--gray); opacity: .4; transition: all .4s; }
.send-step.active { background: rgba(42,44,98,.06); opacity: 1; }
.send-step.done   { background: rgba(230,0,126,.08); opacity: 1; }
.send-icon { width: 32px; height: 32px; border-radius: 50%; background: var(--gray); display: flex; align-items: center; justify-content: center; font-size: 15px; flex-shrink: 0; transition: background .4s; }
.send-step.active .send-icon { background: var(--navy); }
.send-step.done   .send-icon { background: var(--pink); }
.send-lbl { font-size: 11px; font-weight: 700; color: var(--navy); }
.send-sub { font-size: 10px; color: #999; }
.success-screen { text-align: center; padding: 24px 0; }
.success-check { width: 70px; height: 70px; background: var(--pink); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 32px; color: white; margin: 0 auto 20px; animation: popIn .4s cubic-bezier(.175,.885,.32,1.275) both; }
@keyframes popIn { from{transform:scale(0)} to{transform:scale(1)} }
.success-title { font-size: 22px; font-weight: 900; color: var(--navy); margin-bottom: 10px; }
.success-sub   { font-size: 13px; color: #888; line-height: 1.6; }

/* ══════════════════════════════════════════
   FOOTER
══════════════════════════════════════════ */
footer { background: var(--navy); padding: 56px 6vw 28px; }
.ft-top { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 36px; padding-bottom: 36px; border-bottom: 1px solid rgba(255,255,255,.1); margin-bottom: 24px; }
.ft-brand p { font-size: 12px; color: rgba(255,255,255,.45); max-width: 260px; line-height: 1.65; margin-top: 14px; }
.ft-col h4  { font-size: 9px; font-weight: 700; letter-spacing: 3px; text-transform: uppercase; color: white; margin-bottom: 16px; }
.ft-col ul  { list-style: none; display: flex; flex-direction: column; gap: 9px; }
.ft-col a   { color: rgba(255,255,255,.45); font-size: 12px; font-weight: 500; transition: color var(--trans); }
.ft-col a:hover { color: var(--pink); }
.socials { display: flex; gap: 8px; }
.soc-btn { width: 36px; height: 36px; border: 1px solid rgba(255,255,255,.15); border-radius: 3px; display: flex; align-items: center; justify-content: center; color: rgba(255,255,255,.45); transition: all var(--trans); }
.soc-btn:hover { border-color: var(--pink); color: var(--pink); }
.soc-btn svg { width: 15px; height: 15px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.ft-bottom { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; font-size: 10px; color: rgba(255,255,255,.3); }
.ft-bottom span { color: var(--pink); }

/* ══════════════════════════════════════════
   REVEAL ANIMATION
══════════════════════════════════════════ */
.srv-card, .port-item, .ci-block { opacity: 0; transform: translateY(28px); transition: opacity .55s ease, transform .55s ease; }
.srv-card.revealed, .port-item.revealed, .ci-block.revealed { opacity: 1; transform: translateY(0); }

/* ══════════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════════ */
@media (max-width: 1024px) {
  .srv-grid { grid-template-columns: repeat(2,1fr); }
  .port-item.a, .port-item.b { grid-column: span 12; height: 260px; }
  .port-item.c, .port-item.d, .port-item.e { grid-column: span 12; height: 210px; }
  .ct-wrap { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  .mds-nav-links, .mds-nav-cta { display: none; }
  .mds-hamburger { display: flex; }
  .srv-grid { grid-template-columns: 1fr; }
  .f-row { grid-template-columns: 1fr; }
  .form-box { padding: 24px; }
  .hero-stats { position: relative; bottom: auto; right: auto; margin-top: 40px; flex-wrap: wrap; }
  #inicio { padding-bottom: 60px; flex-direction: column; justify-content: center; }
  .scroll-hint { display: none; }
}

/* ══════════════════════════════════════════
   ELEMENTOR / ADMIN
══════════════════════════════════════════ */
.admin-bar .mds-nav { top: 32px; }
@media (max-width: 782px) { .admin-bar .mds-nav { top: 46px; } }
