/* ============================================================
   Mejor Digital · cáscara compartida (header píldora + footer)
   Fuente de verdad: la home estática (index.html). Se carga en
   WordPress con el snippet "MD · Cáscara" (Code Snippets).
   Versión: 2026.10.15.5
   ============================================================ */

/* --- 1. Ocultar header y footer del theme bezel-wp --- */
body.md-shell nav#navbar,
body.md-shell footer#footer,
body.md-shell .footer-spacer { display: none !important; }

/* Tarjetas del blog y categorías (foto de fondo): título y resumen siempre en blanco */
body.md-shell .card-post .post-body h3,
body.md-shell .card-post .post-body h3 a,
body.md-shell .card-post .post-body p { color: #ffffff !important; }

/* --- 2. Base --- */
.mdsh { box-sizing: border-box; -webkit-font-smoothing: antialiased; }
.mdsh *, .mdsh *::before, .mdsh *::after { box-sizing: border-box; }
.mdsh a { color: inherit; }
.mdsh a:focus-visible, .mdsh button:focus-visible { outline: 3px solid #d9de70; outline-offset: 3px; border-radius: 8px; }
.mdsh-btn { transition: transform .2s ease, box-shadow .2s ease, filter .2s ease; }
.mdsh-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0,0,0,.18); filter: brightness(1.05); }
.mdsh-arrow { display: inline-block; vertical-align: middle; }

/* --- 3. Header píldora --- */
.mdsh-header {
  position: fixed; top: 16px; left: 50%; transform: translateX(-50%); z-index: 100000;
  width: min(1160px, calc(100% - 32px));
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 8px 8px 8px 24px; border-radius: 999px;
  background: rgba(255,255,255,0); border: 1px solid rgba(255,255,255,0); box-shadow: none;
  -webkit-backdrop-filter: blur(0px); backdrop-filter: blur(0px);
  transition: background .35s ease, border-color .35s ease, box-shadow .35s ease;
  font-family: Poppins, sans-serif;
}
body.admin-bar .mdsh-header { top: 48px; }
.mdsh-header.mdsh-scrolled, .mdsh-header.mdsh-solid {
  background: rgba(255,255,255,.9); border-color: rgba(0,0,0,.08);
  box-shadow: 0 10px 30px rgba(0,0,0,.08);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
}
.mdsh-logo { display: flex; align-items: center; min-height: 44px; transition: opacity .2s ease; }
.mdsh-logo:hover { opacity: .8; }
.mdsh-logo img { height: 40px; width: 176px; filter: invert(1) brightness(2); transition: filter .35s ease; display: block; }
.mdsh-header.mdsh-scrolled .mdsh-logo img, .mdsh-header.mdsh-solid .mdsh-logo img { filter: none; }
.mdsh-nav { display: flex; gap: 4px; align-items: center; font-size: 14px; font-weight: 600; white-space: nowrap; }
.mdsh-nav a { text-decoration: none; padding: 8px 12px; border-radius: 999px; color: #ffffff; transition: color .3s ease, background .2s ease; }
.mdsh-nav a:hover { background: rgba(155,155,155,.18); color: #ffffff; }
.mdsh-nav a[aria-current="page"] { color: #d9de70; }
.mdsh-header.mdsh-scrolled .mdsh-nav a, .mdsh-header.mdsh-solid .mdsh-nav a { color: #111111; }
.mdsh-header.mdsh-scrolled .mdsh-nav a:hover, .mdsh-header.mdsh-solid .mdsh-nav a:hover,
.mdsh-header.mdsh-scrolled .mdsh-nav a[aria-current="page"], .mdsh-header.mdsh-solid .mdsh-nav a[aria-current="page"] { color: #000000; background: rgba(217,222,112,.55); }
.mdsh-hcta {
  font-family: Poppins, sans-serif; font-weight: 700; font-size: 14px; background: #d9de70; color: #000000;
  text-decoration: none; padding: 0 22px; border-radius: 999px; min-height: 46px;
  display: flex; align-items: center; white-space: nowrap;
}
.mdsh-cta-s { display: none; }
/* Texto negro en los botones amarillos (le gana a ".mdsh a { color: inherit }") */
.mdsh .mdsh-hcta, .mdsh .mdsh-chip-y, .mdsh .mdsh-btn-y { color: #000000; }
/* Etiquetas desactivadas: no se muestran en las notas */
body.md-shell .post-tags { display: none !important; }
.mdsh-burger {
  display: none; width: 44px; height: 44px; border-radius: 999px; border: 1px solid rgba(128,128,128,.35);
  background: transparent; cursor: pointer; align-items: center; justify-content: center; color: #ffffff; margin-left: auto; padding: 0;
}
.mdsh-header.mdsh-scrolled .mdsh-burger, .mdsh-header.mdsh-solid .mdsh-burger { color: #000000; }

/* --- 4. Menú móvil (pantalla completa, negro) --- */
.mdsh-menu {
  position: fixed; inset: 0; z-index: 100001; background: #000000; color: #ffffff;
  display: none; flex-direction: column; padding: 16px 20px 28px; overflow: auto; font-family: Poppins, sans-serif;
}
.mdsh-menu.mdsh-open { display: flex; }
.mdsh-menu-top { display: flex; justify-content: space-between; align-items: center; min-height: 64px; }
.mdsh-menu-top img { height: 32px; width: 141px; filter: invert(1) brightness(2); }
.mdsh-close { width: 44px; height: 44px; border-radius: 999px; border: 1px solid rgba(255,255,255,.3); background: transparent; cursor: pointer; color: #fff; display: inline-flex; align-items: center; justify-content: center; padding: 0; }
.mdsh-menu nav { display: flex; flex-direction: column; margin: 18px 0 0; }
.mdsh-menu-l {
  display: flex; justify-content: space-between; align-items: center; font-weight: 800; font-size: 28px; letter-spacing: -.02em;
  color: #fff; text-decoration: none; padding: 14px 0; border-bottom: 1px solid rgba(255,255,255,.12);
  transition: color .2s ease, padding-left .2s ease;
}
.mdsh-menu-l:hover { color: #d9de70; padding-left: 6px; }
.mdsh-menu-l span:last-child { font-weight: 600; font-size: 12px; color: #9bd4be; letter-spacing: .08em; }
.mdsh-menu-b { margin-top: auto; padding-top: 24px; display: flex; flex-direction: column; gap: 10px; }
.mdsh-menu-b .mdsh-btn { font-weight: 700; font-size: 16px; text-decoration: none; padding: 0 24px; border-radius: 999px; min-height: 54px; display: flex; align-items: center; justify-content: center; gap: 10px; }
.mdsh-menu-b .mdsh-btn-y { background: #d9de70; color: #000; }
.mdsh-menu-b .mdsh-btn-wa { background: #25d366; color: #fff; }
.mdsh-menu-b .mdsh-menu-s { text-align: center; font-weight: 600; font-size: 14px; color: rgba(255,255,255,.75); text-decoration: none; padding: 10px; }
body.mdsh-noscroll { overflow: hidden !important; }

/* --- 5. Footer --- */
.mdsh-footer {
  background: #000000; color: #ffffff; padding: 96px 0 36px; position: relative; overflow: hidden;
  font-family: 'Source Sans Pro', 'Source Sans 3', system-ui, sans-serif; font-size: 16px; line-height: 1.5;
}
.mdsh-footer p { margin: 0; }
.mdsh-waves { position: absolute; left: 0; right: 0; top: 0; height: 220px; overflow: hidden; pointer-events: none; opacity: .45;
  -webkit-mask-image: linear-gradient(180deg,#000 0,#000 40%,transparent 100%); mask-image: linear-gradient(180deg,#000 0,#000 40%,transparent 100%); }
.mdsh-waves svg { position: absolute; left: 0; top: -60px; width: 200%; height: 220px; }
@keyframes mdsh-wave-x { 0% { transform: translateX(0) } 100% { transform: translateX(-50%) } }
.mdsh-wave1 { animation: mdsh-wave-x 14s linear infinite; }
.mdsh-wave2 { animation: mdsh-wave-x 22s linear infinite reverse; }
.mdsh-wave3 { animation: mdsh-wave-x 30s linear infinite; }
.mdsh-glow { position: absolute; right: -120px; bottom: -160px; width: 420px; height: 420px; border-radius: 999px; background: radial-gradient(circle, rgba(80,63,107,.55), rgba(0,0,0,0) 70%); pointer-events: none; }
.mdsh-wm { position: absolute; right: -30px; bottom: -46px; font-family: Poppins, sans-serif; font-weight: 800; font-size: 190px; line-height: 1; letter-spacing: -.05em; color: rgba(255,255,255,.035); white-space: nowrap; pointer-events: none; user-select: none; }
.mdsh-wrap { position: relative; max-width: 1296px; margin: 0 auto; padding: 0 48px; }

.mdsh-ftcta { display: grid; grid-template-columns: minmax(0,1.1fr) minmax(0,.9fr); gap: 32px; align-items: center; background: #111111; border: 1px solid rgba(255,255,255,.1); border-radius: 28px; padding: 36px 40px; margin: 0 0 56px; }
.mdsh-ftcta-t { font-family: Poppins, sans-serif; font-weight: 800; font-size: 30px; line-height: 1.15; letter-spacing: -.02em; margin: 0 0 8px; color: #fff; }
.mdsh-ftcta-p { font-size: 17px; line-height: 1.55; color: rgba(255,255,255,.75); max-width: 520px; }
.mdsh-ftcta-b { display: flex; gap: 12px; flex-wrap: wrap; justify-content: flex-end; }
.mdsh-ftcta-b a { font-family: Poppins, sans-serif; font-weight: 700; font-size: 16px; text-decoration: none; padding: 0 26px; border-radius: 999px; min-height: 54px; display: inline-flex; align-items: center; gap: 10px; }
.mdsh-ftcta-b .mdsh-btn-y { background: #d9de70; color: #000000; }
.mdsh-ftcta-b .mdsh-btn-o { background: transparent; color: #ffffff; border: 1px solid rgba(255,255,255,.35); padding: 0 22px; }

.mdsh-ft { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 32px; margin: 0 0 40px; }
.mdsh-ft-brand { display: flex; flex-direction: column; gap: 14px; }
.mdsh-ft-brand img { height: 34px; width: 150px; filter: invert(1) brightness(2); display: block; }
.mdsh-ft-brand p { font-size: 15.5px; line-height: 1.6; color: rgba(255,255,255,.75); max-width: 400px; }
.mdsh-office { display: flex; gap: 12px; align-items: flex-start; background: #111111; border: 1px solid rgba(255,255,255,.1); border-radius: 16px; padding: 12px 14px; text-decoration: none; color: #ffffff; max-width: 400px; transition: border-color .2s ease, transform .2s ease; }
.mdsh-office:hover { border-color: #d9de70; transform: translateY(-2px); }
.mdsh-office > span:first-child { font-size: 20px; line-height: 1; flex: none; }
.mdsh-office b { display: block; font-family: Poppins, sans-serif; font-weight: 700; font-size: 14px; line-height: 1.3; }
.mdsh-office small { display: block; font-size: 13.5px; line-height: 1.45; color: rgba(255,255,255,.75); }
.mdsh-office em { display: inline-flex; align-items: center; gap: 5px; margin-top: 4px; font-family: Poppins, sans-serif; font-style: normal; font-weight: 700; font-size: 13px; color: #d9de70; }
.mdsh-social { display: flex; gap: 5px; flex-wrap: wrap; margin-top: 4px; }
.mdsh-soc { width: 36px; height: 36px; border-radius: 999px; border: 1px solid rgba(255,255,255,.25); display: inline-flex; align-items: center; justify-content: center; color: #fff; transition: all .25s; }
.mdsh-soc:hover { background: #d9de70; color: #000; border-color: #d9de70; transform: translateY(-2px); }
.mdsh-ft-h { margin: 0 0 14px; font-family: Poppins, sans-serif; font-weight: 700; font-size: 15px; color: #d9de70; }
.mdsh-ft-col > div { display: flex; flex-direction: column; gap: 2px; }
.mdsh-flink { font-size: 15.5px; color: rgba(255,255,255,.82); text-decoration: none; display: inline-block; padding: 7px 0; transition: color .2s ease, transform .2s ease; }
.mdsh-flink:hover, .mdsh-flink:focus-visible { color: #d9de70; transform: translateX(4px); }
.mdsh-flink-u:hover { transform: none; }

.mdsh-svc { border-top: 1px solid rgba(255,255,255,.14); padding-top: 26px; margin: 0 0 36px; }
.mdsh-svc-h { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 18px; margin: 0 0 12px; }
.mdsh-svc-h a { font-family: Poppins, sans-serif; font-weight: 600; font-size: 14px; color: #ffffff; text-decoration: none; display: inline-flex; align-items: center; min-height: 40px; }
.mdsh-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.mdsh-chip { font-family: Poppins, sans-serif; font-weight: 600; font-size: 13.5px; padding: 9px 14px; border-radius: 999px; border: 1px solid rgba(255,255,255,.22); text-decoration: none; color: #ffffff; background: transparent; min-height: 40px; display: inline-flex; align-items: center; transition: background .2s ease, border-color .2s ease, color .2s ease; }
.mdsh-chip:hover { background: #d9de70; border-color: #d9de70; color: #000000; }
.mdsh-chip-y { background: #d9de70; border-color: #d9de70; color: #000000; font-weight: 700; }
.mdsh-chip-y:hover { background: #ffffff; border-color: #ffffff; }

.mdsh-bottom { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; border-top: 1px solid rgba(255,255,255,.14); padding-top: 22px; font-size: 14px; color: rgba(255,255,255,.72); }
.mdsh-bottom > span:first-child { display: flex; flex-direction: column; gap: 6px; }
.mdsh-badges { display: flex; gap: 0 14px; flex-wrap: wrap; align-items: center; font-family: Poppins, sans-serif; font-weight: 600; font-size: 13px; color: rgba(255,255,255,.8); }
.mdsh-badges a, .mdsh-legal a { color: inherit; text-decoration: none; display: inline-flex; align-items: center; min-height: 44px; }
.mdsh-legal { display: flex; gap: 4px 16px; flex-wrap: wrap; }

/* --- 6. Volver arriba --- */
.mdsh-top {
  position: fixed; right: 20px; bottom: 86px; z-index: 99990; width: 46px; height: 46px; border-radius: 999px;
  background: #ffffff; color: #000; border: 1px solid #ddd; box-shadow: 0 8px 24px rgba(0,0,0,.18);
  display: none; align-items: center; justify-content: center; text-decoration: none; transition: background .2s ease, transform .2s ease;
}
.mdsh-top:hover { background: #d9de70; }
body.mdsh-deep .mdsh-top { display: flex; }

/* --- 7. Responsive --- */
@media (max-width: 1180px) {
  .mdsh-nav { display: none; }
  .mdsh-burger { display: inline-flex; }
}
@media (max-width: 1024px) {
  .mdsh-ftcta { grid-template-columns: 1fr; padding: 28px; }
  .mdsh-ftcta-b { justify-content: flex-start; }
  .mdsh-wm { font-size: 110px; bottom: -26px; }
  .mdsh-ft { grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 900px) {
  .mdsh-header { padding-left: 16px; }
  .mdsh-logo img { height: 26px; width: 115px; }
  .mdsh-hcta { display: none; }
  .mdsh-wrap { padding-left: 20px; padding-right: 20px; }
  .mdsh-ft { grid-template-columns: minmax(0,1fr); }
  .mdsh-top { bottom: 80px; right: 12px; width: 40px; height: 40px; opacity: .9; }
  body.admin-bar .mdsh-header { top: 62px; }
}
@media (max-width: 600px) { .mdsh-wm { display: none; } }
@media (prefers-reduced-motion: reduce) { .mdsh-wave1, .mdsh-wave2, .mdsh-wave3 { animation: none; } }
