:root{
  --purple1:#5a189a;
  --purple2:#7b2cbf;
  --purple3:#9d4edd;

  --bg:#ffffff;
  --ink:rgba(20,20,28,.92);
  --muted:rgba(20,20,28,.62);
  --stroke:rgba(90,24,154,.20);
  --stroke2:rgba(20,20,28,.10);

  --shadow: 0 10px 30px rgba(12,12,18,.08);
  --shadow2: 0 14px 40px rgba(12,12,18,.12);
}

*{ box-sizing:border-box; }
html,body{ height:100%; }
body{
  margin:0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji","Segoe UI Emoji";
  background: var(--bg);
  color: var(--ink);
  overflow-x:hidden;
}

a{ color:inherit; text-decoration:none; }
img{ max-width:100%; display:block; }

.hidden{ display:none !important; }

.muted{ color: var(--muted); }
.small{ font-size: 12px; }

.header{
  position: sticky;
  top:0;
  z-index: 50;
  background: #fff;
  border-bottom: 1px solid var(--stroke2);
}

.topbar{
  background: linear-gradient(90deg, rgba(90,24,154,.98), rgba(123,44,191,.96));
  color:#fff;
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding: 10px 12px;
  position:relative;
}

.icon-btn{
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.20);
  color:#fff;
  display:flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
}
.icon-btn:hover{ background: rgba(255,255,255,.18); }

.icon-lines{
  width: 18px;
  height: 2px;
  background:#fff;
  position:relative;
  border-radius: 2px;
}
.icon-lines::before,
.icon-lines::after{
  content:"";
  position:absolute;
  left:0;
  width: 18px;
  height: 2px;
  background:#fff;
  border-radius: 2px;
}
.icon-lines::before{ top:-6px; }
.icon-lines::after{ top:6px; }

.brand{
  display:flex;
  align-items:center;
  justify-content:center;
  gap: 10px;
  position:absolute;
  left:50%;
  transform: translateX(-50%);
  padding: 4px 8px;
  border-radius: 12px;
}
.brand-logo{
  height: 30px;
  width: auto;
}

.chip{
  display:flex;
  align-items:center;
  gap: 8px;
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.22);
  color:#fff;
  border-radius: 999px;
  padding: 10px 12px;
  font-weight: 900;
  cursor:pointer;
}
.chip:hover{ background: rgba(255,255,255,.18); }
.chip-caret{ opacity: .9; }

.lang-menu{
  position:absolute;
  right: 12px;
  top: 56px;
  background:#fff;
  color: var(--ink);
  border:1px solid var(--stroke2);
  border-radius: 14px;
  box-shadow: var(--shadow2);
  overflow:hidden;
  min-width: 140px;
}
.lang-menu a{
  display:flex;
  gap: 10px;
  padding: 12px 12px;
  font-weight: 900;
}
.lang-menu a:hover{
  background: rgba(90,24,154,.06);
}

.nav{
  background: linear-gradient(90deg, rgba(90,24,154,.94), rgba(123,44,191,.92));
  padding: 0;
}
.nav-inner{
  max-width: 1180px;
  margin: 0 auto;
  padding: 10px 12px;
  display:flex;
  gap: 10px;
  align-items:center;

  /* ✅ CAMBIO: ahora se alinea a la derecha */
  justify-content:flex-end;

  flex-wrap:wrap;
}
.nav-link{
  color:#fff;
  font-weight: 900;
  padding: 10px 12px;
  border-radius: 999px;
  transition: background .18s ease;
}
.nav-link:hover{ background: rgba(255,255,255,.10); }

.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap: 10px;
  border-radius: 999px;
  padding: 10px 12px;
  font-weight: 1000;
  border:1px solid rgba(255,255,255,.24);
  color:#fff;
  background: rgba(255,255,255,.10);
}
.btn:hover{ background: rgba(255,255,255,.16); }

.btn.ghost{
  background: rgba(255,255,255,.06);
}

.btn.whatsapp{
  background: rgba(37,211,102,.18);
  border-color: rgba(37,211,102,.32);
}
.btn.whatsapp:hover{ background: rgba(37,211,102,.24); }
.wa-dot{
  width:10px; height:10px;
  border-radius: 50%;
  background: #25D366;
  box-shadow: 0 0 0 6px rgba(37,211,102,.18);
}

.infobar{
  display:flex;
  gap: 10px;
  padding: 10px 12px;
  border-top: 1px solid rgba(90,24,154,.10);
  background: #fff;
  flex-wrap:wrap;
}
.info-pill{
  display:flex;
  align-items:center;
  gap: 10px;
  border:1px solid var(--stroke2);
  border-radius: 999px;
  padding: 8px 10px;
  box-shadow: var(--shadow);
  background:#fff;
}
.info-pill.grow{ flex: 1 1 260px; }
.info-pill .label{
  font-weight: 1000;
  color: rgba(90,24,154,.92);
}
.info-pill .value{
  font-weight: 900;
  color: rgba(20,20,28,.86);
}

.site-banner img{
  width: 100%;
  height: auto;
  display:block;
}

.main{ padding-bottom: 40px; }

.wrap{
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 12px;
}

.hero{
  max-width: 1180px;
  margin: 0 auto;
  padding: 18px 12px 8px;
}
.hero-inner{
  border:1px solid var(--stroke2);
  background: linear-gradient(135deg, rgba(90,24,154,.08), rgba(123,44,191,.04));
  border-radius: 24px;
  padding: 18px 16px;
  box-shadow: var(--shadow);
}
.hero h1{
  margin:0;
  font-size: clamp(20px, 4.6vw, 34px);
  line-height: 1.15;
}
.hero-sub{
  margin: 8px 0 0;
  color: var(--muted);
  font-weight: 800;
}

.layout{
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 12px;
  display:grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.sidebar{ display:none; }
.content{ min-width: 0; }

@media (min-width: 1000px){
  .layout{
    grid-template-columns: 300px 1fr 300px;
    align-items:start;
  }
  .sidebar{ display:block; }
}

.section-head{
  margin: 14px 0 10px;
}
.section-head h2{
  margin:0;
  font-size: 22px;
}
.section-head p{ margin: 4px 0 0; }

.filterbar{
  display:flex;
  flex-wrap:wrap;
  gap: 8px;
  margin: 10px 0 14px;
}
.filter{
  padding: 8px 10px;
  border-radius: 999px;
  border: 1px solid var(--stroke2);
  background: #fff;
  font-weight: 900;
  color: rgba(20,20,28,.78);
}
.filter:hover{ background: rgba(90,24,154,.06); }
.filter.active{
  background: rgba(90,24,154,.10);
  border-color: rgba(90,24,154,.22);
  color: rgba(90,24,154,.92);
}

.empty{
  border:1px dashed rgba(90,24,154,.26);
  border-radius: 24px;
  padding: 18px;
  background: rgba(90,24,154,.04);
}

.news-top{
  display:grid;
  grid-template-columns: 1fr;
  gap: 12px;
}
@media (min-width: 860px){
  .news-top{
    grid-template-columns: 1.35fr .65fr;
  }
}

.featured{
  border-radius: 24px;
  overflow:hidden;
  border: 1px solid var(--stroke2);
  box-shadow: var(--shadow2);
  cursor:pointer;
}
.featured-media{
  position:relative;
  aspect-ratio: 16/9;
  background: linear-gradient(135deg, rgba(90,24,154,.12), rgba(123,44,191,.06));
}
.featured-media img,
.featured-media video{
  width:100%;
  height:100%;
  object-fit:cover;
}
.featured-overlay{
  position:absolute;
  inset:0;
  background: linear-gradient(180deg, rgba(0,0,0,.05), rgba(0,0,0,.70));
}
.featured-content{
  position:absolute;
  inset:0;
  display:flex;
  flex-direction:column;
  justify-content:flex-end;
  padding: 14px;
  color:#fff;
}
.cat-pill{
  display:inline-flex;
  align-self:flex-start;
  background: rgba(255,255,255,.16);
  border:1px solid rgba(255,255,255,.22);
  padding: 8px 10px;
  border-radius: 999px;
  font-weight:1000;
  margin-bottom: 10px;
}
.featured-content h3{
  margin:0;
  font-size: clamp(18px, 3.4vw, 30px);
}
.featured-content p{
  margin: 6px 0 10px;
  color: rgba(255,255,255,.88);
  font-weight: 800;
  max-width: 60ch;
}
.meta{
  display:flex;
  gap: 8px;
  align-items:center;
  font-weight: 900;
  font-size: 12px;
  color: rgba(255,255,255,.86);
}

.play-badge{
  position:absolute;
  left: 12px;
  top: 12px;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display:flex;
  align-items:center;
  justify-content:center;
  background: rgba(0,0,0,.45);
  color:#fff;
  font-weight: 1000;
  border:1px solid rgba(255,255,255,.18);
}

.rail{
  border: 1px solid var(--stroke2);
  border-radius: 24px;
  background:#fff;
  box-shadow: var(--shadow);
  padding: 12px;
}
.rail-title{
  font-weight: 1000;
  color: rgba(90,24,154,.92);
  margin-bottom: 8px;
}
.rail-item{
  display:flex;
  gap: 10px;
  padding: 10px;
  border-radius: 18px;
  cursor:pointer;
}
.rail-item:hover{ background: rgba(90,24,154,.06); }
.rail-thumb{
  width: 78px;
  height: 58px;
  border-radius: 14px;
  overflow:hidden;
  border:1px solid var(--stroke2);
  background: rgba(90,24,154,.06);
  flex: 0 0 auto;
}
.rail-thumb img{ width:100%; height:100%; object-fit:cover; }
.thumb-video,
.thumb-fallback{
  width:100%; height:100%;
  display:flex; align-items:center; justify-content:center;
  font-weight: 1000;
  color: rgba(90,24,154,.92);
}
.rail-text{ min-width:0; }
.rail-cat{
  font-weight: 1000;
  color: rgba(90,24,154,.92);
  font-size: 12px;
}
.rail-head{
  font-weight: 1000;
  color: rgba(20,20,28,.88);
  margin-top: 2px;
  line-height: 1.2;
}
.rail-date{
  margin-top: 6px;
  font-weight: 900;
  font-size: 12px;
  color: rgba(20,20,28,.62);
}

.rail-ad{ margin-top: 12px; }

.news-grid{
  display:grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-top: 14px;
}
@media (min-width: 720px){
  .news-grid{ grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1040px){
  .news-grid{ grid-template-columns: repeat(3, 1fr); }
}

.card{
  background:#fff;
  border:1px solid var(--stroke2);
  border-radius: 22px;
  overflow:hidden;
  box-shadow: var(--shadow);
  cursor:pointer;
}
.card-media{
  position:relative;
  aspect-ratio: 16/10;
  background: rgba(90,24,154,.06);
}
.card-media img,
.card-media video{
  width:100%;
  height:100%;
  object-fit:cover;
}
.media-fallback{
  width:100%;
  height:100%;
  background: linear-gradient(135deg, rgba(90,24,154,.14), rgba(123,44,191,.06));
}
.card-cat{
  position:absolute;
  left: 10px;
  bottom: 10px;
  background: rgba(255,255,255,.92);
  border:1px solid rgba(20,20,28,.10);
  padding: 8px 10px;
  border-radius: 999px;
  font-weight: 1000;
  color: rgba(90,24,154,.92);
  font-size: 12px;
}
.card-body{
  padding: 12px 12px 14px;
}
.card-title{
  margin:0;
  font-size: 16px;
  line-height: 1.2;
}
.card-excerpt{
  margin: 8px 0 10px;
  color: rgba(20,20,28,.70);
  font-weight: 800;
}
.card-meta{
  display:flex;
  gap: 8px;
  align-items:center;
  font-weight: 900;
  font-size: 12px;
  color: rgba(20,20,28,.62);
}

/* Micro-interacciones (más pro) */
.card, .featured, .rail-item{
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, background .18s ease;
}
.card:hover, .featured:hover{
  transform: translateY(-2px);
  box-shadow: 0 16px 50px rgba(12,12,18,.14);
}
.card:active, .featured:active{
  transform: translateY(0) scale(.99);
}
.rail-item:hover{
  transform: translateY(-1px);
}

.infeed-ad{ grid-column: 1 / -1; }
.bottom-ad{ margin-top: 14px; }

.footer{
  border-top: 1px solid var(--stroke2);
  background: linear-gradient(90deg, rgba(90,24,154,.98), rgba(123,44,191,.96));
  color:#fff;
  padding: 16px 12px;
}
.footer-inner{
  max-width: 1180px;
  margin: 0 auto;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 14px;
  flex-wrap:wrap;
}
.footer-logo{ height: 24px; width:auto; opacity:.95; }
.footer-links a{
  color:#fff;
  font-weight: 900;
  opacity:.92;
}
.footer-links a:hover{ opacity:1; }

/* ADS */
.ad{
  border: 1px solid var(--stroke2);
  border-radius: 22px;
  overflow:hidden;
  background:#fff;
  box-shadow: var(--shadow);
}
.ad--sticky{
  position: sticky;
  top: 116px;
}
.ad-link{ display:block; }
.ad-img{
  width:100%;
  height:auto;
  display:block;
}
.ad--placeholder{
  background: linear-gradient(135deg, rgba(90,24,154,.08), rgba(123,44,191,.04));
  min-height: 120px;
  position:relative;
}
.ad--placeholder::before{
  content:"";
  display:block;
  aspect-ratio: var(--arM, 3.2);
}
@media(min-width: 700px){
  .ad--placeholder::before{ aspect-ratio: var(--arD, 3.88); }
}
.ad-ph-inner{
  position:absolute;
  inset:0;
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:center;
  padding: 14px;
  text-align:center;
}
.ad-ph-title{
  font-weight: 1000;
  color: rgba(90,24,154,.92);
}
.ad-ph-hint{
  margin-top: 6px;
  color: rgba(20,20,28,.62);
  font-weight: 900;
  font-size: 12px;
}
.ad-ph-mini{
  margin-top: 10px;
  font-weight: 900;
  font-size: 12px;
  color: rgba(20,20,28,.58);
}

/* MODAL */
.modal{
  position:fixed; inset:0;
  background: rgba(10,10,14,.62);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 9999;
  display:flex; align-items:center; justify-content:center;
  padding: 18px;

  opacity: 0;
  pointer-events: none;
  transition: opacity .22s ease;
}
.modal.is-open{
  opacity: 1;
  pointer-events: auto;
}
.modal-card{
  width:min(720px, 95vw);
  background: #fff;
  border:1px solid var(--stroke2);
  border-radius: 22px;
  box-shadow: 0 18px 60px rgba(0,0,0,.35);
  position:relative;

  overflow:auto;
  max-height: 88vh;

  transform: translateY(12px) scale(.985);
  opacity: 0;
  transition: transform .26s cubic-bezier(.2,.8,.2,1), opacity .26s ease;
}
.modal.is-open .modal-card{
  transform: translateY(0) scale(1);
  opacity: 1;
}
.modal-wide{ width:min(980px, 96vw); }

.modal-top{
  position: sticky;
  top: 0;
  z-index: 20;
  padding: 10px 10px 8px;
  background: rgba(255,255,255,.72);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(20,20,28,.06);
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap: 10px;
}
.modal-progress{
  height: 3px;
  flex: 1 1 auto;
  background: rgba(90,24,154,.10);
  border-radius: 999px;
  overflow:hidden;
  margin-top: 12px;
}
.modal-progress span{
  display:block;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--purple3), var(--purple2));
}
.modal-close{
  width: 40px; height:40px;
  border-radius: 12px;
  border:1px solid var(--stroke2);
  background: rgba(20,20,28,.04);
  color: rgba(20,20,28,.80);
  cursor:pointer;
  font-weight:1000;
  flex: 0 0 auto;
}
.modal-close:hover{ background: rgba(90,24,154,.08); }

.news-modal-card{ padding: 0; }

/* Toast */
.toast{
  position: fixed;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  background: rgba(20,20,28,.92);
  color: #fff;
  padding: 10px 12px;
  border-radius: 999px;
  font-weight: 900;
  box-shadow: 0 10px 30px rgba(0,0,0,.25);
  z-index: 10000;
  opacity: 0;
  pointer-events: none;
  transition: opacity .18s ease, transform .18s ease;
}
.toast.show{
  opacity: 1;
  transform: translateX(-50%) translateY(-2px);
}

@media (prefers-reduced-motion: reduce){
  .modal{ transition:none; }
  .modal-card{ transition:none; transform:none; }
  .toast{ transition:none; }
}

/* NEWS MODAL */

.news-hero{
  position:relative;
  overflow:hidden;
}
.news-hero-media{
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, rgba(90,24,154,.16), rgba(123,44,191,.08));
}
.news-hero-media img,
.news-hero-media video{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}
.hero-skeleton{
  width:100%;
  height:100%;
  background: linear-gradient(90deg, rgba(90,24,154,.10), rgba(123,44,191,.06), rgba(90,24,154,.10));
  background-size: 200% 100%;
  animation: shimmer 1.2s linear infinite;
}
@keyframes shimmer{
  0%{ background-position: 0% 0; }
  100%{ background-position: 200% 0; }
}

.news-hero-overlay{
  position:absolute; inset:0;
  display:flex;
  flex-direction:column;
  justify-content:flex-end;
  padding: 14px 14px 14px;
  background: linear-gradient(180deg, rgba(0,0,0,.05), rgba(0,0,0,.70));
  color:#fff;
}
.news-hero .news-cat{
  display:inline-flex;
  align-self:flex-start;
  background: rgba(255,255,255,.16);
  border:1px solid rgba(255,255,255,.22);
  padding: 8px 10px;
  border-radius: 999px;
  font-weight:1000;
  margin-bottom: 10px;
  color:#fff;
}
.news-hero .news-title{
  margin:0 0 6px;
  color:#fff;
  font-size: clamp(18px, 2.8vw, 30px);
}
.news-hero .news-meta{
  color: rgba(255,255,255,.86);
  font-weight:800;
  font-size: 12px;
  margin-bottom: 10px;
}
.news-actions{
  display:flex;
  gap: 10px;
  flex-wrap:wrap;
}
.news-actions .gc-btn{
  border-color: rgba(255,255,255,.22);
  background: rgba(255,255,255,.12);
  color:#fff;
}
.news-actions .gc-btn:hover{ background: rgba(255,255,255,.18); }

.news-head{ padding-right: 46px; }
.news-cat{
  display:inline-flex;
  align-items:center;
  gap: 8px;
  background: rgba(90,24,154,.10);
  color: rgba(90,24,154,.92);
  border:1px solid rgba(90,24,154,.18);
  padding: 8px 10px;
  border-radius: 999px;
  font-weight:1000;
  font-size: 12px;
}
.news-title{
  margin: 10px 0 6px;
  font-size: 22px;
  line-height: 1.15;
}
.news-meta{
  color: rgba(20,20,28,.62);
  font-weight: 900;
  font-size: 12px;
}

.news-gallery{ margin:0; padding: 14px 14px 0; }

.gallery-main{
  border:1px solid var(--stroke2);
  border-radius: 18px;
  overflow:hidden;
  background: rgba(90,24,154,.06);
}
.gallery-main img{
  width:100%;
  height:auto;
  display:block;
}
.gallery-thumbs{
  display:flex;
  gap: 10px;
  margin-top: 10px;
  overflow:auto;
  padding-bottom: 6px;
}
.thumb{
  width: 72px;
  height: 54px;
  border-radius: 14px;
  overflow:hidden;
  border:1px solid var(--stroke2);
  background:#fff;
  cursor:pointer;
  flex: 0 0 auto;
}
.thumb img{ width:100%; height:100%; object-fit:cover; }
.thumb.active{
  border-color: rgba(90,24,154,.42);
  box-shadow: 0 10px 20px rgba(90,24,154,.18);
}
.video-wrap{
  border:1px solid var(--stroke2);
  border-radius: 18px;
  overflow:hidden;
  background: rgba(90,24,154,.06);
}
.video-wrap video{
  width:100%;
  height:auto;
  display:block;
}

.gc-btn{
  border:1px solid var(--stroke2);
  background:#fff;
  border-radius: 999px;
  padding: 10px 12px;
  font-weight: 1000;
  cursor:pointer;
}
.gc-btn:hover{ background: rgba(90,24,154,.06); }

.news-content{
  padding: 14px 14px 18px;
  color: rgba(20,20,28,.86);
  font-weight:700;
  line-height: 1.62;
  font-size: 15px;
}
@media (min-width: 760px){
  .news-content{ font-size: 16px; }
  .news-content:first-letter{
    float:left;
    font-size: 3.1em;
    line-height: 1;
    padding: 0 10px 0 0;
    font-weight:1000;
    color: rgba(90,24,154,.92);
  }
}
.news-content img{ max-width:100%; height:auto; }

/* Dashboard */
.admin-wrap{
  max-width: 1100px;
  margin: 0 auto;
  padding: 14px 12px 34px;
}
.admin-top{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 12px;
  flex-wrap:wrap;
}
.admin-card{
  background:#fff;
  border:1px solid var(--stroke2);
  border-radius: 24px;
  padding: 14px;
  box-shadow: var(--shadow);
  margin-top: 12px;
}
.form-row{
  display:grid;
  grid-template-columns: 1fr;
  gap: 10px;
}
@media(min-width: 760px){
  .form-row{ grid-template-columns: 1fr 1fr; }
}
label{
  display:block;
  font-weight: 1000;
  color: rgba(20,20,28,.78);
  margin-bottom: 6px;
}
input,select,textarea{
  width:100%;
  border:1px solid var(--stroke2);
  border-radius: 16px;
  padding: 12px;
  font-weight: 800;
  font-family: inherit;
  outline:none;
}
textarea{ min-height: 120px; resize: vertical; }
input:focus,select:focus,textarea:focus{
  border-color: rgba(90,24,154,.42);
  box-shadow: 0 0 0 4px rgba(90,24,154,.10);
}
.primary{
  background: linear-gradient(90deg, rgba(90,24,154,.98), rgba(123,44,191,.96));
  color:#fff;
  border: none;
}
.primary:hover{ opacity:.95; }

.table{
  width:100%;
  border-collapse: collapse;
  margin-top: 10px;
}
.table th, .table td{
  text-align:left;
  padding: 10px;
  border-bottom: 1px solid var(--stroke2);
  font-weight: 800;
}
.table th{ font-weight: 1000; color: rgba(20,20,28,.70); }
.badge{
  display:inline-flex;
  align-items:center;
  padding: 6px 10px;
  border-radius: 999px;
  border:1px solid var(--stroke2);
  background: rgba(90,24,154,.06);
  font-weight: 1000;
  font-size: 12px;
}
