/* ===========================================================
   Curionex Magazine — hoja de estilos principal
   Diseño moderno tipo app · blanco + púrpura · mobile first
   =========================================================== */

:root{
  --primary:#6B21A8;
  --primary-light:#9333EA;
  --primary-gradient:linear-gradient(135deg,#6B21A8,#9333EA);
  --white:#FFFFFF;
  --gray-light:#F8F7FF;
  --gray:#6B7280;
  --dark:#1F1033;
  --radius:16px;
  --radius-sm:12px;
  --shadow-sm:0 2px 10px rgba(31,16,51,.06);
  --shadow:0 8px 30px rgba(107,33,168,.10);
  --shadow-lg:0 16px 50px rgba(107,33,168,.18);
  --maxw:1180px;
}

*{box-sizing:border-box;margin:0;padding:0}
html{scroll-behavior:smooth}
body{
  font-family:'Inter',-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;
  font-size:17px;
  line-height:1.6;
  color:var(--dark);
  background:var(--white);
  -webkit-font-smoothing:antialiased;
}
img{max-width:100%;display:block}
a{color:inherit;text-decoration:none}

/* ---------- HEADER ---------- */
.site-header{
  position:sticky;top:0;z-index:100;
  background:rgba(255,255,255,.92);
  backdrop-filter:saturate(180%) blur(12px);
  box-shadow:var(--shadow-sm);
  border-bottom:1px solid #eee9f7;
}
.header-inner{
  max-width:var(--maxw);margin:0 auto;
  display:flex;align-items:center;justify-content:space-between;
  padding:14px 20px;
}
.brand-logo{height:38px;width:auto}
.cat-nav{
  max-width:var(--maxw);margin:0 auto;
  display:flex;gap:10px;padding:0 20px 14px;
  overflow-x:auto;scrollbar-width:none;
}
.cat-nav::-webkit-scrollbar{display:none}
.chip{
  display:inline-flex;align-items:center;gap:6px;white-space:nowrap;
  padding:9px 16px;border-radius:999px;
  background:var(--gray-light);color:var(--dark);
  font-size:14.5px;font-weight:600;
  border:1.5px solid transparent;transition:.2s;
}
.chip:hover{border-color:var(--primary-light);color:var(--primary);transform:translateY(-1px)}
.chip-active{background:var(--primary-gradient);color:#fff}
.chip-ico{font-size:15px}

/* ---------- MAIN ---------- */
.site-main{max-width:var(--maxw);margin:0 auto;padding:28px 20px 40px}

/* ---------- HERO ---------- */
.hero{margin-bottom:14px}
.hero-card{
  display:block;position:relative;border-radius:var(--radius);
  overflow:hidden;min-height:420px;
  background-size:cover;background-position:center;background-color:#2a1447;
  box-shadow:var(--shadow-lg);
}
.hero-overlay{
  position:absolute;inset:0;
  display:flex;flex-direction:column;justify-content:flex-end;
  padding:40px;
  background:linear-gradient(0deg,rgba(43,20,71,.92) 0%,rgba(107,33,168,.55) 55%,rgba(107,33,168,.15) 100%);
}
.hero-title{color:#fff;font-size:34px;font-weight:900;line-height:1.15;margin:14px 0 10px;max-width:760px}
.hero-summary{color:rgba(255,255,255,.9);font-size:17px;max-width:640px;margin-bottom:20px}
.btn-hero{
  display:inline-block;align-self:flex-start;
  background:#fff;color:var(--primary);
  padding:13px 26px;border-radius:12px;font-weight:700;transition:.2s;
}
.hero-card:hover .btn-hero{transform:translateX(4px)}

/* ---------- BADGES ---------- */
.badge{
  display:inline-flex;align-items:center;gap:5px;
  background:var(--badge-color,var(--primary));color:#fff;
  font-size:12.5px;font-weight:700;letter-spacing:.3px;
  padding:5px 12px;border-radius:999px;text-transform:uppercase;
}
.badge-hero{align-self:flex-start}

/* ---------- SECTIONS ---------- */
.section{margin:44px 0}
.section-title{font-size:24px;font-weight:800;margin-bottom:22px;color:var(--dark)}

/* ---------- GRID ---------- */
.grid{display:grid;gap:26px}
.grid-3{grid-template-columns:repeat(3,1fr)}

/* ---------- CARDS ---------- */
.card{
  background:#fff;border-radius:var(--radius);overflow:hidden;
  box-shadow:var(--shadow-sm);border:1px solid #f0ecf9;
  display:flex;flex-direction:column;transition:transform .3s,box-shadow .3s;
}
.card:hover{transform:translateY(-6px);box-shadow:var(--shadow-lg)}
.card-img-link{position:relative;display:block;aspect-ratio:16/10;background:var(--gray-light);overflow:hidden}
.card-img{width:100%;height:100%;object-fit:cover;transition:transform .5s}
.card:hover .card-img{transform:scale(1.06)}
.card-img-link .badge{position:absolute;top:12px;left:12px}
.card-body{padding:20px;display:flex;flex-direction:column;flex:1}
.card-title{font-size:19px;font-weight:800;line-height:1.3;margin-bottom:10px}
.card-title a:hover{color:var(--primary)}
.card-summary{color:var(--gray);font-size:15.5px;flex:1;
  display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}
.card-foot{display:flex;align-items:center;justify-content:space-between;margin-top:16px}
.card-date{font-size:13px;color:var(--gray)}
.btn-read{color:var(--primary);font-weight:700;font-size:14.5px;transition:.2s}
.btn-read:hover{transform:translateX(3px)}

/* ---------- ADSENSE ---------- */
.ad-wrap{display:flex;justify-content:center;margin:30px 0}
.ad-inline{margin:36px 0}
.ad-placeholder{
  display:flex;align-items:center;justify-content:center;
  background:repeating-linear-gradient(45deg,#f6f2fd,#f6f2fd 10px,#efe8fb 10px,#efe8fb 20px);
  color:var(--gray);font-size:13px;font-weight:600;border-radius:10px;
  border:1px dashed #d9c9f0;
}
.ad-728{width:728px;max-width:100%;height:90px}
.ad-300{width:300px;height:250px}

/* ---------- POST ---------- */
.post{max-width:820px;margin:0 auto}
.post-hero{
  width:100%;height:min(60vh,600px);border-radius:var(--radius);
  background-size:cover;background-position:center;background-color:#2a1447;
  box-shadow:var(--shadow);position:relative;margin-bottom:28px;
}
.post-body{}
.badge-post{margin-bottom:18px}
.post-title{font-size:34px;font-weight:900;line-height:1.15;margin-bottom:16px}
.post-meta{display:flex;gap:18px;flex-wrap:wrap;color:var(--gray);font-size:14.5px;margin-bottom:24px}
.post-lead{font-size:20px;font-weight:600;color:var(--dark);line-height:1.6;margin-bottom:28px;
  padding-left:18px;border-left:4px solid var(--primary-light)}
.post-content{font-size:18px;line-height:1.8;color:#2b2340}
.post-content p{margin-bottom:22px}
.post-content h2{font-size:24px;font-weight:800;margin:34px 0 14px;color:var(--primary)}
.post-content h3{font-size:20px;font-weight:700;margin:26px 0 12px}
.post-content ul,.post-content ol{margin:0 0 22px 24px}
.post-content li{margin-bottom:8px}
.post-content blockquote{border-left:4px solid var(--primary-light);padding-left:18px;color:var(--gray);font-style:italic;margin:0 0 22px}
.post-source-link{margin:24px 0;color:var(--gray);font-size:15px}
.post-source-link a{color:var(--primary);font-weight:600}

/* ---------- BOTONES ---------- */
.btn-back{
  display:inline-block;margin-top:20px;
  background:var(--gray-light);color:var(--primary);
  padding:12px 24px;border-radius:12px;font-weight:700;transition:.2s;
}
.btn-back:hover{background:var(--primary-gradient);color:#fff}

/* ---------- CATEGORÍA HERO ---------- */
.cat-hero{
  text-align:center;padding:44px 20px;border-radius:var(--radius);
  background:var(--gray-light);margin-bottom:14px;
  border-top:5px solid var(--cat-color,var(--primary));
}
.cat-hero-icon{font-size:52px;display:block;margin-bottom:10px}
.cat-hero-title{font-size:32px;font-weight:900}
.cat-hero-count{color:var(--gray);margin-top:6px}

/* ---------- PAGINACIÓN ---------- */
.pagination{display:flex;gap:8px;justify-content:center;flex-wrap:wrap;margin:36px 0}
.page-link{padding:10px 16px;border-radius:10px;background:var(--gray-light);font-weight:600;transition:.2s}
.page-link:hover{background:var(--primary-light);color:#fff}
.page-active{background:var(--primary-gradient);color:#fff}

/* ---------- NOTICE ---------- */
.notice{
  text-align:center;padding:60px 24px;background:var(--gray-light);
  border-radius:var(--radius);margin:20px 0;
}
.notice h2{font-size:26px;margin-bottom:10px}
.notice code{background:#fff;padding:2px 8px;border-radius:6px;color:var(--primary);font-weight:600}

/* ---------- FOOTER ---------- */
.site-footer{background:var(--dark);color:#cfc4e0;margin-top:40px}
.footer-inner{
  max-width:var(--maxw);margin:0 auto;padding:48px 20px 30px;
  display:grid;grid-template-columns:1.4fr 1fr 1.4fr;gap:36px;
}
.footer-logo{height:34px;background:#fff;padding:8px 12px;border-radius:10px;margin-bottom:14px}
.footer-tag{font-size:15px}
.footer-cats h4,.footer-about h4{color:#fff;font-size:16px;margin-bottom:14px}
.footer-cats ul{list-style:none}
.footer-cats li{margin-bottom:9px}
.footer-cats a:hover{color:#fff}
.footer-about p{font-size:15px;line-height:1.7}
.footer-bottom{
  border-top:1px solid rgba(255,255,255,.12);
  max-width:var(--maxw);margin:0 auto;padding:20px;
  display:flex;justify-content:space-between;flex-wrap:wrap;gap:10px;
  font-size:14px;
}
.powered{color:var(--primary-light);font-weight:700}

/* ---------- REVEAL ANIM ---------- */
.reveal{opacity:0;transform:translateY(24px);transition:opacity .6s ease,transform .6s ease}
.reveal.in{opacity:1;transform:none}

/* ---------- RESPONSIVE ---------- */
@media(max-width:900px){
  .grid-3{grid-template-columns:repeat(2,1fr)}
  .footer-inner{grid-template-columns:1fr 1fr}
}
@media(max-width:640px){
  body{font-size:16px}
  .grid-3{grid-template-columns:1fr}
  .hero-card{min-height:340px}
  .hero-overlay{padding:24px}
  .hero-title{font-size:25px}
  .post-title{font-size:26px}
  .post-hero{height:44vh}
  .post-content{font-size:17px}
  .footer-inner{grid-template-columns:1fr;gap:24px}
}
