/* Rodando en Familia — paleta sacada del logo y de las miniaturas del canal */
:root {
  --navy: #0b2d52;      /* RODANDO, fondos fuertes */
  --navy-900: #061a31;
  --azul: #468ac0;      /* "en familia" */
  --celeste: #74acdf;   /* bandera */
  --cielo: #e3effa;
  --sol: #f6b40e;       /* sol de mayo */
  --amarillo: #fcdc28;  /* títulos de las miniaturas */
  --rojo: #d6311f;      /* el colectivo */
  --crema: #fbf7f2;     /* cinta del logo */
  --blanco: #ffffff;
  --tinta: #14243a;
  --gris: #51627a;

  --font-display: "Archivo Black", "Arial Black", system-ui, sans-serif;
  --font-script: "Pacifico", cursive;
  --font-body: "Nunito", system-ui, sans-serif;

  --radius: 18px;
  --shadow: 0 10px 30px rgb(6 26 49 / 0.18);
  --wrap: 1180px;

  /* Pincelada de fondo de los títulos, como en las miniaturas */
  --brush: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 100' preserveAspectRatio='none'%3E%3Cpath d='M10 16 L38 6 L52 11 L120 7 L170 12 L215 3 L262 9 L318 5 L392 8 L384 26 L398 44 L389 63 L397 90 L330 94 L300 89 L240 97 L190 91 L120 98 L70 92 L18 96 L22 84 L4 70 L13 52 L3 34 Z' fill='black'/%3E%3C/svg%3E");
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body {
  margin: 0;
  background: var(--crema);
  color: var(--tinta);
  font: 400 1.0625rem/1.6 var(--font-body);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
[hidden] { display: none !important; }
a { color: inherit; }
.wrap { width: min(var(--wrap), 100% - 32px); margin-inline: auto; }

/* ---------- tipografía ---------- */
.display {
  font-family: var(--font-display);
  font-weight: 400;
  text-transform: uppercase;
  line-height: 1.02;
  letter-spacing: 0.01em;
  color: var(--navy);
  margin: 0;
}
.display--light { color: var(--blanco); }
.hl { color: var(--amarillo); }
.script { font-family: var(--font-script); color: var(--azul); font-size: 1.35rem; }
.kicker {
  font-family: var(--font-script);
  color: var(--azul);
  font-size: 1.4rem;
  margin: 0 0 0.4rem;
}

.brush {
  display: inline-block;
  position: relative;
  padding: 0.18em 0.45em 0.12em;
  z-index: 0;
}
.brush::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  -webkit-mask: var(--brush) center / 100% 100% no-repeat;
  mask: var(--brush) center / 100% 100% no-repeat;
  transform: rotate(-1.5deg);
}
.brush--navy::before { background: var(--navy); }
.brush--yellow::before { background: var(--amarillo); }
.brush--yellow { color: var(--navy); }
.brush--red::before { background: var(--rojo); }

/* ---------- botones ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  border: 0;
  border-radius: 999px;
  padding: 0.85em 1.5em;
  font: 800 1rem/1 var(--font-body);
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s;
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.btn:disabled { opacity: 0.6; cursor: default; transform: none; box-shadow: none; }
.btn svg { width: 1.2em; height: 1.2em; fill: currentColor; }
.btn--red { background: var(--rojo); color: var(--blanco); }
.btn--yt { background: var(--rojo); color: var(--blanco); }
.btn--ghost { background: transparent; color: var(--navy); box-shadow: inset 0 0 0 2px var(--navy); }
.btn--ig { background: linear-gradient(45deg, #f9a825, #e1306c 50%, #833ab4); color: var(--blanco); }
.btn--sm { padding: 0.6em 1.1em; font-size: 0.92rem; }
:focus-visible { outline: 3px solid var(--sol); outline-offset: 3px; }

/* ---------- barra superior ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgb(255 255 255 / 0.88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgb(11 45 82 / 0.08);
}
.topbar__inner { display: flex; align-items: center; gap: 1.5rem; height: 64px; }
.brand { display: flex; align-items: center; gap: 0.6rem; text-decoration: none; }
.brand__name, .footer__name {
  font-family: var(--font-display);
  text-transform: uppercase;
  color: var(--navy);
  font-size: 1.05rem;
  white-space: nowrap;
}
.brand__name em, .footer__name em {
  font: 400 1.05em var(--font-script);
  text-transform: none;
  color: var(--azul);
  margin-left: 0.15em;
}
.nav { display: flex; gap: 1.4rem; margin-left: auto; }
.nav a { text-decoration: none; font-weight: 700; color: var(--navy); }
.nav a:hover { color: var(--rojo); }
@media (max-width: 860px) {
  .nav { display: none; }
  .topbar .btn { margin-left: auto; }
}
@media (max-width: 420px) {
  .brand__name { font-size: 0.9rem; }
}

/* ---------- hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  background:
    repeating-conic-gradient(from 0deg at 22% 46%, rgb(246 180 14 / 0.12) 0 6deg, transparent 6deg 15deg),
    linear-gradient(180deg, #5ba3da 0%, #9ccbf0 45%, var(--cielo) 80%);
  padding: 3rem 0 7rem;
}
.hero__grid {
  display: grid;
  grid-template-columns: minmax(260px, 440px) 1fr;
  gap: 3rem;
  align-items: center;
}
.hero__logo img {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 18px 30px rgb(6 26 49 / 0.3));
  animation: rodar 6s ease-in-out infinite;
}
@keyframes rodar {
  50% { transform: translateY(-8px) rotate(-1deg); }
}
.hero .display { font-size: clamp(2rem, 4.6vw, 3.6rem); display: grid; gap: 0.25em; justify-items: start; }
.lead { font-size: 1.15rem; color: var(--tinta); max-width: 38em; margin: 1.4rem 0 1.8rem; }
.actions { display: flex; flex-wrap: wrap; gap: 0.8rem; }
.actions--center { justify-content: center; margin-top: 2rem; }
.flag { position: absolute; left: 0; right: 0; bottom: -1px; width: 100%; height: 90px; }
@media (max-width: 760px) {
  .hero { padding-top: 1.5rem; }
  .hero__grid { grid-template-columns: 1fr; gap: 1.5rem; text-align: left; }
  .hero__logo { width: min(70vw, 320px); margin-inline: auto; }
}
@media (prefers-reduced-motion: reduce) {
  .hero__logo img { animation: none; }
  html { scroll-behavior: auto; }
}

/* ---------- secciones ---------- */
.section { padding: 4.5rem 0; }
.section--navy { background: var(--navy); color: var(--blanco); }
.section--deep { background: var(--navy-900); color: var(--blanco); }
.section--sky { background: var(--cielo); }
.section--cream { background: var(--crema); }
.section__head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.6rem 1.4rem; margin-bottom: 2rem; }
.section__head .display { font-size: clamp(1.9rem, 4vw, 2.8rem); }
.section__sub { margin: 0; color: var(--gris); font-size: 1.1rem; }
.section--navy .section__sub, .section--deep .section__sub { color: rgb(255 255 255 / 0.75); }
.section__sub.script { color: var(--azul); font-size: 1.4rem; }
.more { margin: 2rem 0 0; text-align: right; font-weight: 800; }
.more a { text-decoration: none; color: var(--amarillo); }
.more--dark a { color: var(--navy); }
.more a:hover { text-decoration: underline; }

/* ---------- tarjetas de video ---------- */
.grid { display: grid; gap: 1.5rem; }
.grid--chapters { grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); }
@media (min-width: 900px) {
  .grid--chapters .card--featured { grid-column: span 2; grid-row: span 2; }
}
.card {
  position: relative;
  display: flex;
  flex-direction: column;
  border-radius: var(--radius);
  overflow: hidden;
  background: rgb(255 255 255 / 0.06);
  border: 0;
  padding: 0;
  text-align: left;
  color: inherit;
  font: inherit;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 16px 40px rgb(0 0 0 / 0.35); }
.card__thumb { position: relative; aspect-ratio: 16 / 9; background: var(--navy-900); }
.card__thumb img { width: 100%; height: 100%; object-fit: cover; }
.card__play {
  position: absolute;
  inset: 50% auto auto 50%;
  translate: -50% -50%;
  width: 64px;
  height: 46px;
  border-radius: 14px;
  background: var(--rojo);
  display: grid;
  place-items: center;
  box-shadow: 0 6px 18px rgb(0 0 0 / 0.35);
  transition: scale 0.2s;
}
.card:hover .card__play { scale: 1.1; }
.card__play svg { width: 26px; fill: var(--blanco); }
.card__body { padding: 1rem 1.2rem 1.3rem; display: grid; gap: 0.45rem; }
.card__tag {
  justify-self: start;
  font: 400 0.85rem var(--font-display);
  text-transform: uppercase;
  color: var(--navy);
  background: var(--amarillo);
  padding: 0.25em 0.7em;
  transform: skew(-8deg);
}
.card__tag--new { background: var(--rojo); color: var(--blanco); }
.card__title { margin: 0; font-weight: 800; font-size: 1.12rem; line-height: 1.3; }
.card--featured .card__title { font-size: clamp(1.25rem, 2.2vw, 1.6rem); }
.card__meta { margin: 0; font-size: 0.92rem; opacity: 0.7; }
.card--skeleton { aspect-ratio: 16 / 11; cursor: default; background: rgb(255 255 255 / 0.08); animation: pulso 1.4s ease-in-out infinite; }
@keyframes pulso { 50% { opacity: 0.5; } }

/* ---------- shorts ---------- */
.shorts {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(180px, 220px);
  gap: 1.2rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 0.8rem;
}
.shorts .card { scroll-snap-align: start; background: var(--blanco); color: var(--tinta); box-shadow: var(--shadow); }
.shorts .card__thumb { aspect-ratio: 9 / 16; }
.shorts .card__body { padding: 0.8rem 0.9rem 1rem; }
.shorts .card__title { font-size: 0.98rem; }

/* ---------- instagram ---------- */
.ig { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 1.5rem; justify-items: center; }
.ig:empty { display: none; }
.ig .instagram-media { min-width: 0 !important; width: 100% !important; }

/* ---------- el colectivo ---------- */
.facts {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
  gap: 1.2rem;
}
.facts li {
  border-radius: var(--radius);
  background: rgb(255 255 255 / 0.05);
  border: 1px solid rgb(255 255 255 / 0.1);
  padding: 1.4rem 1.5rem;
  display: grid;
  gap: 0.3rem;
}
.facts strong { font: 400 2rem/1 var(--font-display); color: var(--amarillo); }
.facts span { color: rgb(255 255 255 / 0.8); }
.soon__title { margin: 3rem 0 1rem; font: 400 1.2rem var(--font-script); color: var(--celeste); }
.soon { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.7rem; }
.soon li {
  border: 2px dashed rgb(116 172 223 / 0.6);
  border-radius: 999px;
  padding: 0.45em 1.1em;
  font-weight: 700;
  color: rgb(255 255 255 / 0.85);
}

/* ---------- footer ---------- */
.footer { background: var(--crema); padding: 2.5rem 0; border-top: 6px solid var(--celeste); }
.footer__inner { display: flex; align-items: center; gap: 1.5rem; }
.footer__inner p { margin: 0.15rem 0; }
.footer__links { display: flex; gap: 1.2rem; font-weight: 800; }
.footer__links a { color: var(--navy); }
.footer__legal { font-size: 0.9rem; color: var(--gris); }

/* ---------- reproductor ---------- */
.player {
  border: 0;
  padding: 0;
  background: transparent;
  width: min(1100px, 100vw - 32px);
  overflow: visible;
}
.player--short { width: min(420px, 100vw - 32px); }
.player::backdrop { background: rgb(6 26 49 / 0.85); backdrop-filter: blur(4px); }
.player__frame { aspect-ratio: 16 / 9; border-radius: 14px; overflow: hidden; background: #000; box-shadow: var(--shadow); }
.player--short .player__frame { aspect-ratio: 9 / 16; max-height: 85vh; margin-inline: auto; }
.player__frame iframe { width: 100%; height: 100%; border: 0; display: block; }
.player__close {
  position: absolute;
  top: -48px;
  right: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 0;
  background: var(--blanco);
  color: var(--navy);
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
}
