/*
Theme Name: Noticias MYD
Theme URI: https://somosmyd.com
Author: Studios M&D
Description: Blog de noticias SomosMYD — tema espacial 3D negro + cian #00FFE0
Version: 1.0.0
Text Domain: noticias-myd
*/

/* ============================================================
   DESIGN SYSTEM — idéntico al panel SomosMYD
   ============================================================ */
:root {
  --myd-bg:        #000000;
  --myd-bg-card:   #0d0d0d;
  --myd-bg-nav:    #050505;
  --myd-cyan:      #00FFE0;
  --myd-cyan-dim:  rgba(0,255,224,0.12);
  --myd-cyan-glow: rgba(0,255,224,0.35);
  --myd-text:      #ffffff;
  --myd-muted:     #8899aa;
  --myd-border:    rgba(0,255,224,0.2);
  --myd-radius:    10px;
  --myd-transition: 0.2s ease;
  --myd-font: 'Inter', 'Segoe UI', sans-serif;
  --max-width: 1180px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--myd-bg);
  color: var(--myd-text);
  font-family: var(--myd-font);
  font-size: 16px;
  line-height: 1.6;
  min-height: 100vh;
}

/* Scrollbar */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: #000; }
::-webkit-scrollbar-thumb { background: var(--myd-cyan); border-radius: 3px; }

a { color: var(--myd-cyan); text-decoration: none; transition: color var(--myd-transition); }
a:hover { color: #fff; }

img { max-width: 100%; height: auto; }

/* ── Canvas 3D (Three.js) ── */
#myd-canvas {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* ── Navbar ── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 200;
  background: rgba(0,0,0,0.88);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--myd-border);
}
.myd-nav {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 2rem;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}
.myd-nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.25rem;
  font-weight: 800;
  color: #fff !important;
  letter-spacing: -0.5px;
  flex-shrink: 0;
}
.myd-nav-brand .accent { color: var(--myd-cyan); }

/* Nav menu WordPress */
.main-navigation { display: flex; align-items: center; }
.main-navigation ul {
  display: flex;
  gap: 0.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.main-navigation ul li a {
  color: var(--myd-muted);
  padding: 0.4rem 0.85rem;
  border-radius: 6px;
  font-size: 0.88rem;
  font-weight: 500;
  transition: all var(--myd-transition);
  display: block;
}
.main-navigation ul li a:hover,
.main-navigation ul li.current-menu-item a {
  color: var(--myd-cyan);
  background: var(--myd-cyan-dim);
}

/* ── Layout principal ── */
.site-content-wrap {
  position: relative;
  z-index: 10;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 3rem 2rem 5rem;
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 3rem;
  align-items: start;
}
.site-content-wrap.no-sidebar {
  grid-template-columns: 1fr;
  max-width: 820px;
}

/* ── Hero del blog ── */
.blog-hero {
  position: relative;
  z-index: 10;
  text-align: center;
  padding: 5rem 2rem 4rem;
  max-width: var(--max-width);
  margin: 0 auto;
}
.blog-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--myd-cyan-dim);
  border: 1px solid var(--myd-border);
  color: var(--myd-cyan);
  padding: 0.3rem 1rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}
.blog-hero h1 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 1rem;
}
.blog-hero h1 .accent { color: var(--myd-cyan); }
.blog-hero p {
  font-size: 1.1rem;
  color: var(--myd-muted);
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.7;
}

/* ── Grid de artículos ── */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
  margin-bottom: 3rem;
}

/* ── Card de artículo ── */
.post-card {
  background: var(--myd-bg-card);
  border: 1px solid var(--myd-border);
  border-radius: var(--myd-radius);
  overflow: hidden;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  position: relative;
}
.post-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: var(--myd-cyan);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}
.post-card:hover {
  border-color: rgba(0,255,224,0.5);
  transform: translateY(-5px);
  box-shadow: 0 16px 40px rgba(0,0,0,0.6), 0 0 0 1px rgba(0,255,224,0.1);
}
.post-card:hover::before { transform: scaleX(1); }

.post-card-thumb {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
}
.post-card-thumb-placeholder {
  width: 100%;
  height: 200px;
  background: linear-gradient(135deg, #0d0d0d 0%, #111820 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  color: var(--myd-cyan);
  opacity: 0.5;
}

.post-card-body { padding: 1.5rem; flex: 1; display: flex; flex-direction: column; }

.post-card-cat {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--myd-cyan);
  margin-bottom: 0.6rem;
}
.post-card-title {
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: 0.6rem;
}
.post-card-title a { color: var(--myd-text); }
.post-card-title a:hover { color: var(--myd-cyan); }
.post-card-excerpt {
  font-size: 0.85rem;
  color: var(--myd-muted);
  line-height: 1.65;
  flex: 1;
  margin-bottom: 1.2rem;
}
.post-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 0.8rem;
  border-top: 1px solid rgba(255,255,255,0.05);
  font-size: 0.75rem;
  color: var(--myd-muted);
}
.post-card-read-more {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--myd-cyan);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.post-card-read-more:hover { color: #fff; }

/* ── Single post ── */
.single-post-wrap {
  position: relative;
  z-index: 10;
  max-width: 820px;
  margin: 0 auto;
  padding: 3rem 2rem 5rem;
}

.single-post-header { margin-bottom: 2.5rem; }
.single-post-cat {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--myd-cyan);
  margin-bottom: 0.75rem;
  display: block;
}
.single-post-title {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 1rem;
}
.single-post-meta {
  font-size: 0.82rem;
  color: var(--myd-muted);
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--myd-border);
  margin-bottom: 2rem;
}
.single-post-meta span::before { content: '· '; }
.single-post-meta span:first-child::before { content: ''; }

.single-post-thumb {
  width: 100%;
  max-height: 460px;
  object-fit: cover;
  border-radius: var(--myd-radius);
  margin-bottom: 2.5rem;
  border: 1px solid var(--myd-border);
}

/* ── Contenido del artículo ── */
.entry-content {
  font-size: 1.05rem;
  line-height: 1.8;
  color: rgba(255,255,255,0.88);
}
.entry-content h2 {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--myd-text);
  margin: 2.5rem 0 1rem;
  padding-left: 1rem;
  border-left: 3px solid var(--myd-cyan);
}
.entry-content h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--myd-text);
  margin: 2rem 0 0.75rem;
}
.entry-content p { margin-bottom: 1.5rem; }
.entry-content ul, .entry-content ol {
  padding-left: 1.5rem;
  margin-bottom: 1.5rem;
}
.entry-content li { margin-bottom: 0.5rem; color: rgba(255,255,255,0.82); }
.entry-content li::marker { color: var(--myd-cyan); }
.entry-content a { color: var(--myd-cyan); border-bottom: 1px solid rgba(0,255,224,0.3); }
.entry-content a:hover { color: #fff; border-color: #fff; }
.entry-content blockquote {
  border-left: 3px solid var(--myd-cyan);
  background: var(--myd-bg-card);
  padding: 1.2rem 1.5rem;
  margin: 2rem 0;
  border-radius: 0 var(--myd-radius) var(--myd-radius) 0;
  font-style: italic;
  color: var(--myd-muted);
}
.entry-content code {
  background: #111;
  color: var(--myd-cyan);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  font-size: 0.88em;
  font-family: 'Courier New', monospace;
}
.entry-content pre {
  background: #0a0a0a;
  border: 1px solid var(--myd-border);
  border-radius: var(--myd-radius);
  padding: 1.5rem;
  overflow-x: auto;
  margin-bottom: 1.5rem;
}
.entry-content pre code { background: none; padding: 0; }
.entry-content strong { color: var(--myd-cyan); font-weight: 700; }
.entry-content img { border-radius: var(--myd-radius); border: 1px solid var(--myd-border); }
.entry-content table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.5rem;
  font-size: 0.9rem;
}
.entry-content th {
  background: var(--myd-bg-card);
  color: var(--myd-cyan);
  padding: 0.6rem 1rem;
  text-align: left;
  border-bottom: 2px solid var(--myd-border);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.entry-content td {
  padding: 0.6rem 1rem;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  color: rgba(255,255,255,0.8);
}

/* ── Sidebar ── */
.sidebar {
  position: sticky;
  top: 90px;
}
.sidebar-widget {
  background: var(--myd-bg-card);
  border: 1px solid var(--myd-border);
  border-radius: var(--myd-radius);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}
.sidebar-widget-title {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--myd-cyan);
  margin-bottom: 1rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--myd-border);
}
.sidebar-widget ul { list-style: none; padding: 0; }
.sidebar-widget ul li {
  padding: 0.4rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  font-size: 0.88rem;
}
.sidebar-widget ul li:last-child { border: none; }
.sidebar-widget ul li a { color: var(--myd-muted); }
.sidebar-widget ul li a:hover { color: var(--myd-cyan); }

/* Search form */
.search-form { display: flex; gap: 0.5rem; }
.search-form input {
  flex: 1;
  background: #111;
  border: 1px solid var(--myd-border);
  color: var(--myd-text);
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  font-size: 0.88rem;
  outline: none;
}
.search-form input:focus { border-color: var(--myd-cyan); box-shadow: 0 0 0 2px rgba(0,255,224,0.15); }
.search-form button {
  background: var(--myd-cyan);
  color: #000;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
}
.search-form button:hover { background: #fff; }

/* ── CTA Banner ── */
.cta-banner {
  position: relative;
  z-index: 10;
  background: linear-gradient(135deg, #0d0d0d 0%, rgba(0,255,224,0.06) 100%);
  border: 1px solid var(--myd-border);
  border-radius: 16px;
  padding: 4rem 2rem;
  text-align: center;
  max-width: var(--max-width);
  margin: 0 auto 5rem;
}
.cta-banner h2 {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 800;
  margin-bottom: 0.75rem;
}
.cta-banner h2 .accent { color: var(--myd-cyan); }
.cta-banner p { color: var(--myd-muted); margin-bottom: 2rem; }
.myd-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1.8rem;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  border: none;
  transition: all var(--myd-transition);
  text-decoration: none;
}
.myd-btn-primary { background: var(--myd-cyan); color: #000; }
.myd-btn-primary:hover { background: #fff; color: #000; box-shadow: 0 0 24px var(--myd-cyan-glow); }
.myd-btn-outline { background: transparent; color: var(--myd-cyan); border: 1px solid var(--myd-cyan); }
.myd-btn-outline:hover { background: var(--myd-cyan-dim); color: #fff; }

/* ── Paginación ── */
.pagination {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin: 3rem 0;
  position: relative;
  z-index: 10;
}
.page-numbers {
  width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  background: var(--myd-bg-card);
  border: 1px solid var(--myd-border);
  border-radius: 6px;
  font-size: 0.88rem;
  color: var(--myd-muted);
  transition: all var(--myd-transition);
}
.page-numbers:hover, .page-numbers.current {
  background: var(--myd-cyan);
  color: #000;
  border-color: var(--myd-cyan);
  font-weight: 700;
}

/* ── Footer ── */
.site-footer {
  position: relative;
  z-index: 10;
  background: var(--myd-bg-nav);
  border-top: 1px solid var(--myd-border);
  padding: 3rem 2rem 1.5rem;
}
.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.8fr 1fr 1fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2.5rem;
}
.footer-brand { font-size: 1.2rem; font-weight: 800; margin-bottom: 0.75rem; }
.footer-brand .accent { color: var(--myd-cyan); }
.footer-desc { color: var(--myd-muted); font-size: 0.88rem; line-height: 1.7; }
.footer-col h4 {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--myd-muted);
  margin-bottom: 1rem;
}
.footer-col ul { list-style: none; padding: 0; }
.footer-col ul li { margin-bottom: 0.5rem; }
.footer-col ul li a { color: var(--myd-muted); font-size: 0.88rem; }
.footer-col ul li a:hover { color: var(--myd-cyan); }
.footer-bottom {
  padding-top: 1.5rem;
  border-top: 1px solid var(--myd-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--myd-muted);
}
.footer-bottom a { color: var(--myd-cyan); }

/* ── No results ── */
.no-results {
  text-align: center;
  padding: 5rem 2rem;
  color: var(--myd-muted);
  position: relative;
  z-index: 10;
}
.no-results h2 { color: var(--myd-text); margin-bottom: 1rem; }

/* ── Responsive ── */
@media (max-width: 900px) {
  .site-content-wrap { grid-template-columns: 1fr; }
  .sidebar { position: static; }
  .footer-grid { grid-template-columns: 1fr 1fr 1fr; }
}
@media (max-width: 640px) {
  .myd-nav { padding: 0 1rem; height: 60px; }
  .posts-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 2rem; }
  .blog-hero { padding: 3rem 1rem 2rem; }
  .single-post-wrap { padding: 2rem 1rem 4rem; }
  .footer-bottom { flex-direction: column; text-align: center; }
  .cta-banner { padding: 2.5rem 1rem; margin-bottom: 3rem; }
}

/* Sin sidebar — ancho completo */
.site-content-full {
  grid-template-columns: 1fr;
}
.site-content-full main {
  max-width: 100%;
}

.single-post-cat-links a {
  color: var(--myd-cyan);
  text-transform: uppercase;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-decoration: none;
  border-bottom: 1px solid var(--myd-cyan);
  padding-bottom: 1px;
}
.single-post-cat-links a:hover { opacity: 0.75; }


/* ─── Botones compartir ─────────────────────────────────── */
.share-buttons {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin: 2rem 0 1.5rem;
  padding: 1.2rem 1.4rem;
  background: rgba(0,255,224,0.05);
  border: 1px solid rgba(0,255,224,0.15);
  border-radius: 10px;
}
.share-label {
  font-size: 0.82rem;
  color: var(--myd-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-right: 0.3rem;
}
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.42rem 0.9rem;
  border-radius: 6px;
  font-size: 0.82rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: transform 0.15s ease, opacity 0.15s ease;
  line-height: 1;
}
.share-btn svg {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
}
.share-btn:hover { transform: translateY(-2px); opacity: 0.88; }
.share-facebook  { background: #1877F2; color: #fff; }
.share-x         { background: #000;    color: #fff; }
.share-whatsapp  { background: #25D366; color: #fff; }
.share-linkedin  { background: #0A66C2; color: #fff; }
.share-copy      { background: rgba(0,255,224,0.12); color: var(--myd-cyan); border: 1px solid rgba(0,255,224,0.3); }
