/* ==========================================================
   RIZOMA LAB — estilos compartidos (v5)
   Paleta: turquesa #4DAABB · morado #791865 · fucsia #D21E79
           coral #F07355 · amarillo #F0D77D · fondo #F7F8F6
   Titulares: Nunito (redondeada) · Texto: Figtree
   Formas: orgánicas (blobs y raíces, como el logo)
   ========================================================== */

:root {
  --ice: #F7F8F6;
  --blush: #EFE6E7;
  --turq: #4DAABB;
  --turq-dark: #1F7A8A;
  --plum: #791865;
  --pink: #D21E79;
  --coral: #F07355;
  --yellow: #F0D77D;
  --ink: #27222A;
  --muted: #5F5963;
  --line: #E7E3E6;

  --display: 'Nunito', 'Figtree', system-ui, sans-serif;
  --body: 'Figtree', system-ui, sans-serif;

  --radius: 28px;
  --shadow-sm: 0 2px 6px rgba(39, 34, 42, .05), 0 10px 24px rgba(39, 34, 42, .06);
  --shadow-md: 0 4px 10px rgba(39, 34, 42, .05), 0 24px 48px rgba(39, 34, 42, .10);
  --shadow-lg: 0 10px 20px rgba(39, 34, 42, .08), 0 40px 70px rgba(39, 34, 42, .18);

  --wrap: 1240px;
  --gutter: clamp(20px, 5vw, 56px);
  --section: clamp(104px, 13vw, 180px);
  --header-h: 88px;

  --org-a: 58% 42% 63% 37% / 45% 55% 45% 55%;
  --org-b: 42% 58% 38% 62% / 56% 40% 60% 44%;
  --org-c: 63% 37% 48% 52% / 38% 58% 42% 62%;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--ice); color: var(--ink); font-family: var(--body); font-size: 17px; line-height: 1.6; -webkit-font-smoothing: antialiased; }
main { overflow-x: clip; }
img { max-width: 100%; display: block; }
a { color: inherit; }
button, input, textarea, select { font: inherit; }
h1, h2, h3, h4 { font-family: var(--display); font-weight: 700; margin: 0; letter-spacing: -0.03em; line-height: 1.02; }
p { margin: 0; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding-top: var(--section); position: relative; isolation: isolate; }
.section--last { padding-bottom: var(--section); }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 8px; z-index: 100; }

/* ---------- Tipografía utilitaria ---------- */
.eyebrow { display: inline-flex; align-items: center; gap: 12px; font-size: 13px; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; color: var(--plum); }
.eyebrow::before { content: ""; width: 30px; height: 3px; border-radius: 3px; background: var(--coral); }
.eyebrow--pink { color: var(--pink); }
.eyebrow--light { color: var(--yellow); }
.eyebrow--light::before { background: var(--yellow); }
.h-xl { font-size: clamp(48px, 7vw, 104px); }
.h-lg { font-size: clamp(38px, 4.8vw, 68px); }
.h-md { font-size: clamp(28px, 3vw, 40px); }
.lead { font-size: clamp(18px, 1.6vw, 21px); color: var(--muted); line-height: 1.65; max-width: 540px; }
.hl-pink { color: var(--pink); }
.section-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 28px 48px; margin-bottom: 64px; }
.section-head h2 { margin-top: 20px; max-width: 760px; }
.section-head p { max-width: 420px; color: var(--muted); }

/* ---------- Botones ---------- */
.btn { display: inline-flex; align-items: center; gap: 12px; min-height: 52px; padding: 0 28px; border-radius: 999px; font-weight: 800; font-size: 15px; text-decoration: none; border: 2px solid transparent; cursor: pointer; transition: transform .25s ease, background .25s ease, color .25s ease, box-shadow .25s ease; }
.btn:hover { transform: translateY(-2px); }
.btn--primary { background: var(--pink); color: #fff; box-shadow: 0 10px 24px rgba(210, 30, 121, .28); }
.btn--primary:hover { background: var(--plum); box-shadow: 0 12px 28px rgba(121, 24, 101, .3); }
.btn--outline { border-color: var(--plum); color: var(--plum); background: transparent; }
.btn--outline:hover { background: var(--plum); color: #fff; }
.btn--light { background: #fff; color: var(--plum); }
.btn--light:hover { background: var(--yellow); }
.btn .arrow { transition: transform .25s ease; }
.btn:hover .arrow { transform: translateX(4px); }
.btn-row { display: flex; flex-wrap: wrap; gap: 14px; }
.link-arrow { font-weight: 800; color: var(--pink); text-decoration: none; display: inline-flex; gap: 8px; align-items: center; }
.link-arrow:hover { color: var(--plum); }

/* ---------- Barra superior y header ---------- */
.topbar { background: var(--plum); color: #fff; text-align: center; font-size: 12px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; padding: 12px 16px; }
.topbar b { color: var(--yellow); }
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(247, 248, 246, .92); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: var(--header-h); }
.logo { display: inline-flex; align-items: center; text-decoration: none; flex-shrink: 0; }
.logo img { height: 48px; width: auto; }
.nav { display: flex; align-items: center; gap: 32px; }
.nav a { text-decoration: none; font-weight: 700; font-size: 15px; position: relative; padding: 8px 0; }
.nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; border-radius: 3px; background: var(--pink); transform: scaleX(0); transform-origin: left; transition: transform .3s ease; }
.nav a:hover::after, .nav a[aria-current="page"]::after { transform: scaleX(1); }
.nav a[aria-current="page"] { color: var(--plum); }
.header-cta { display: flex; align-items: center; gap: 10px; }
.menu-btn { display: none; width: 48px; height: 48px; border-radius: 50%; border: 2px solid var(--line); background: #fff; cursor: pointer; align-items: center; justify-content: center; }
.menu-btn span, .menu-btn span::before, .menu-btn span::after { display: block; width: 18px; height: 2px; background: var(--ink); border-radius: 2px; position: relative; transition: transform .25s ease; }
.menu-btn span::before, .menu-btn span::after { content: ""; position: absolute; left: 0; }
.menu-btn span::before { top: -6px; } .menu-btn span::after { top: 6px; }
.menu-open .menu-btn span { background: transparent; }
.menu-open .menu-btn span::before { transform: translateY(6px) rotate(45deg); }
.menu-open .menu-btn span::after { transform: translateY(-6px) rotate(-45deg); }

/* ---------- Formas orgánicas ---------- */
.org { border-radius: var(--org-a); }
@keyframes morph {
  0% { border-radius: var(--org-a); }
  50% { border-radius: var(--org-b); }
  100% { border-radius: var(--org-c); }
}
@keyframes drift {
  from { transform: translate(0, 0) rotate(0deg); }
  to { transform: translate(var(--dx, 40px), var(--dy, -50px)) rotate(var(--rot, 8deg)); }
}
/* Una sola forma de fondo por sección */
.bg { position: absolute; z-index: -1; pointer-events: none; }
.bg--blob { background: var(--c); aspect-ratio: 1; border-radius: var(--org-a); animation: morph 16s ease-in-out infinite alternate, drift var(--t, 26s) ease-in-out infinite alternate; }
/* Raíz: línea como las del logo. Va en su propia franja para que no la tapen tarjetas.
   Cada trazo es invisible hasta que empieza a dibujarse (así no aparecen puntos en los nodos). */
.root path { fill: none; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1 1; stroke-dashoffset: 1; opacity: 0; }
.root-band { position: relative; height: clamp(150px, 18vw, 260px); margin: clamp(40px, 6vw, 80px) 0 calc(var(--section) * -0.5); pointer-events: none; }
.root-band svg { position: absolute; left: 0; top: 0; width: 100%; height: 100%; overflow: visible; }
.root-band--flip svg { transform: scaleX(-1); }
.js .root.reveal { opacity: 1; transform: none; }
.root.in path, .compo .root path { animation: draw 2.6s cubic-bezier(.4, 0, .2, 1) both; }
.root.in path:nth-child(2), .compo .root path:nth-child(2) { animation-delay: 1.5s; }
.root.in path:nth-child(3), .compo .root path:nth-child(3) { animation-delay: .9s; animation-duration: 1.2s; }
.root.in path:nth-child(4), .compo .root path:nth-child(4) { animation-delay: 1.3s; animation-duration: 1.2s; }
.root.in path:nth-child(5), .compo .root path:nth-child(5) { animation-delay: 2.6s; animation-duration: 1.2s; }
.root.in path:nth-child(6), .compo .root path:nth-child(6) { animation-delay: 1.1s; animation-duration: 1s; }
@keyframes draw { 0% { stroke-dashoffset: 1; opacity: 0; } 1% { opacity: 1; } 100% { stroke-dashoffset: 0; opacity: 1; } }

/* ---------- Hero del inicio ---------- */
.home-hero { padding-top: clamp(20px, 3vw, 40px); position: relative; }
.wrap-wide { max-width: 1480px; margin: 0 auto; padding: 0 clamp(16px, 3vw, 40px); }
.home-hero .hero-text { padding-top: clamp(72px, 9vw, 130px); }
.home-hero h1 { margin-top: 26px; }
.home-hero .hero-sub { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 28px 56px; margin-top: 40px; }

/* ---------- Composición orgánica (solo inicio) ---------- */
.compo { position: relative; width: 100%; aspect-ratio: 16 / 8; border-radius: 44px; overflow: hidden; background: var(--blush); isolation: isolate; }
.compo .blob-a { position: absolute; width: 54%; aspect-ratio: 1; right: -8%; top: -34%; background: var(--turq); border-radius: var(--org-a); animation: morph 14s ease-in-out infinite alternate; }
.compo .blob-b { position: absolute; width: 32%; aspect-ratio: 1; left: -7%; bottom: -42%; background: var(--yellow); border-radius: var(--org-b); animation: morph 17s ease-in-out infinite alternate-reverse; }
.compo .root { position: absolute; left: 0; width: 100%; bottom: 4%; animation: sway 12s ease-in-out infinite; }
.compo .book {
  position: absolute; left: 19%; top: 13%; width: 30%; aspect-ratio: 1 / .86;
  background: var(--plum); color: #fff; border-radius: 8px 14px 14px 8px;
  padding: 6% 4% 5% 7%; display: flex; flex-direction: column; justify-content: center;
  --r: -10deg; transform: rotate(var(--r)); box-shadow: var(--shadow-lg);
  animation: floatY 8s ease-in-out infinite;
}
.compo .book::before { content: ""; position: absolute; left: 6%; top: 0; bottom: 0; width: 3px; background: rgba(255, 255, 255, .22); }
.compo .book small, .compo .book em { white-space: nowrap; font-style: normal; font-size: clamp(9px, .9vw, 14px); font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.compo .book strong { font-family: var(--display); font-weight: 800; font-size: clamp(24px, 3.2vw, 50px); line-height: .95; letter-spacing: -.02em; margin: 6% 0; text-transform: uppercase; }
.compo .ring {
  position: absolute; width: 16%; right: 20%; bottom: 16%; aspect-ratio: 1; border-radius: 50%;
  border: clamp(12px, 1.9vw, 30px) solid var(--coral);
  box-shadow: 0 10px 20px rgba(39, 34, 42, .10), 0 34px 60px rgba(39, 34, 42, .20), inset 0 4px 10px rgba(39, 34, 42, .10);
  animation: swayX 6.5s ease-in-out infinite;
}
@keyframes floatY { 0%, 100% { transform: translateY(0) rotate(var(--r)); } 50% { transform: translateY(-16px) rotate(calc(var(--r) + 1.5deg)); } }
@keyframes swayX { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(-46px); } }
@keyframes sway { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(8px); } }

/* ---------- Páginas interiores: hero ---------- */
.page-hero { padding-top: clamp(80px, 10vw, 140px); position: relative; isolation: isolate; }
.page-hero h1 { margin: 26px 0 30px; max-width: 920px; }
.page-hero .lead { margin-bottom: 36px; }

/* ---------- Pasos ---------- */
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.step { background: #fff; border-radius: 22px; padding: 30px; box-shadow: var(--shadow-sm); display: flex; gap: 18px; align-items: flex-start; }
.num { flex-shrink: 0; width: 46px; height: 46px; border-radius: var(--org-a); display: grid; place-items: center; font-family: var(--display); font-weight: 800; font-size: 19px; }
.step h3, .how b { font-family: var(--body); font-size: 18px; letter-spacing: -.01em; line-height: 1.3; margin-bottom: 6px; display: block; }
.step p { font-size: 15px; color: var(--muted); line-height: 1.55; }

/* ---------- Tarjetas de pilares ---------- */
.pillars { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.pillar { position: relative; background: #fff; border-radius: var(--radius); padding: 44px 38px 38px; box-shadow: var(--shadow-md); overflow: hidden; display: flex; flex-direction: column; text-decoration: none; color: var(--ink); min-height: 360px; transition: transform .35s cubic-bezier(.2, .7, .2, 1), box-shadow .35s ease; }
.pillar:hover { transform: translateY(-8px); box-shadow: var(--shadow-lg); }
.pillar .shape { position: absolute; right: -46px; top: -50px; width: 160px; height: 150px; border-radius: var(--org-a); transition: border-radius .8s ease, transform .6s ease; }
.pillar:hover .shape { border-radius: var(--org-c); transform: scale(1.08) rotate(-8deg); }
.pillar .n { font-family: var(--display); font-weight: 800; font-size: 16px; color: var(--muted); letter-spacing: .08em; }
.pillar h3 { font-size: 46px; margin: 12px 0 16px; }
.pillar p { color: var(--muted); font-size: 17px; margin-bottom: 30px; }
.pillar .link-arrow { margin-top: auto; }

/* ---------- Banda destacada (inicio) ---------- */
.feature-band { background: #fff; border-radius: 36px; box-shadow: var(--shadow-md); padding: clamp(40px, 6vw, 72px); display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 48px; align-items: center; position: relative; overflow: hidden; }
.feature-band h2 { margin: 18px 0 20px; }
.feature-band .lead { margin-bottom: 30px; }
.avatar-cloud { position: relative; min-height: 280px; }
.avatar-cloud span { position: absolute; display: grid; place-items: center; background: #DEDAD5; color: var(--muted); font-size: 12px; font-weight: 700; border: 6px solid #fff; box-shadow: var(--shadow-md); border-radius: var(--org-b); }

/* ---------- Caminos "para quién" ---------- */
.paths { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 24px; }
.path { grid-column: span 2; position: relative; background: #fff; border-radius: 26px; padding: 34px 30px 30px; box-shadow: var(--shadow-md); display: flex; flex-direction: column; text-decoration: none; color: var(--ink); overflow: hidden; transition: transform .35s cubic-bezier(.2, .7, .2, 1), box-shadow .35s ease; }
.path:nth-child(n+4) { grid-column: span 3; }
.path:hover { transform: translateY(-8px); box-shadow: var(--shadow-lg); }
.path .blob { position: absolute; right: -36px; top: -40px; width: 120px; height: 112px; border-radius: var(--org-b); background: var(--pc); }
.path .who { position: relative; align-self: flex-start; max-width: calc(100% - 80px); font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; padding: 7px 12px; border-radius: 999px; background: var(--ice); border: 1px solid var(--line); margin-bottom: 28px; }
.path .if { font-size: 14px; font-weight: 700; color: var(--muted); }
.path h3 { font-size: 28px; margin: 6px 0 16px; }
.path p { font-size: 15px; color: var(--muted); margin-bottom: 24px; }
.path .link-arrow { margin-top: auto; font-size: 15px; }

/* ---------- Pestañas (Propuesta) ---------- */
.tabs-bar { position: sticky; top: var(--header-h); z-index: 20; background: rgba(247, 248, 246, .94); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); margin-top: clamp(56px, 7vw, 96px); }
.tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.tab { background: none; border: 0; border-bottom: 5px solid transparent; cursor: pointer; color: var(--muted); padding: 26px 8px 21px; display: flex; align-items: center; justify-content: center; gap: 14px; transition: color .25s, border-color .25s; }
.tab .tn { font-weight: 800; font-size: 13px; letter-spacing: .1em; }
.tab .tt { font-family: var(--display); font-weight: 700; font-size: clamp(22px, 2.6vw, 34px); line-height: 1; }
.tab .td { width: 16px; height: 15px; border-radius: var(--org-a); background: var(--tc); flex-shrink: 0; }
.tab:hover { color: var(--ink); }
.tab[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--tc); }
.panel { padding-top: clamp(72px, 9vw, 120px); position: relative; isolation: isolate; }
.panel[hidden] { display: none; }
.panel.is-in { animation: panelIn .5s ease; }
@keyframes panelIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.panel-intro { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 32px 72px; align-items: end; margin-bottom: 64px; }
.panel-intro h2 { margin-top: 18px; }

/* ---------- Tarjetas de oferta / actividades ---------- */
.offer-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 24px; }
.offer { background: #fff; border-radius: 24px; padding: 36px 32px; box-shadow: var(--shadow-sm); transition: transform .3s ease, box-shadow .3s ease; display: flex; flex-direction: column; }
.offer:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.offer .ico { width: 50px; height: 48px; border-radius: var(--org-a); margin-bottom: 26px; display: grid; place-items: center; }
.offer .ico svg { width: 22px; height: 22px; }
.offer h3 { font-size: 26px; margin-bottom: 12px; line-height: 1.08; }
.offer p { color: var(--muted); font-size: 16px; }
.offer .meta { margin-top: auto; padding-top: 20px; display: flex; flex-wrap: wrap; gap: 8px; }
.offer .meta span { font-size: 13px; font-weight: 700; padding: 6px 12px; border-radius: 999px; background: var(--ice); border: 1px solid var(--line); }
.offer--feature { background: var(--plum); color: #fff; }
.offer--feature p { color: #EBD3E5; }
.offer--feature .meta span { background: rgba(255, 255, 255, .12); border-color: rgba(255, 255, 255, .25); }

/* ---------- Bloques divididos ---------- */
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(40px, 6vw, 96px); align-items: center; }
.split h2 { margin: 20px 0 24px; }
.split .lead { margin-bottom: 32px; }
.how { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 16px; }
.how li { display: flex; gap: 18px; align-items: flex-start; background: #fff; border-radius: 20px; padding: 22px 24px; box-shadow: var(--shadow-sm); }
.how .num { width: 42px; height: 40px; font-size: 17px; }
.how span { color: var(--muted); font-size: 15px; }
.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip { font-size: 15px; font-weight: 700; padding: 12px 18px; border-radius: 999px; background: #fff; box-shadow: var(--shadow-sm); }
.ph { background: #DEDAD5; border-radius: var(--radius); min-height: 420px; display: grid; place-items: center; color: var(--muted); font-size: 14px; font-weight: 600; text-align: center; padding: 24px; position: relative; overflow: hidden; }

/* ---------- Directorio (Explora) ---------- */
.dir-tools { display: flex; flex-wrap: wrap; gap: 16px 24px; align-items: center; justify-content: space-between; margin-bottom: 44px; }
.search { position: relative; flex: 1 1 320px; max-width: 460px; }
.search svg { position: absolute; left: 20px; top: 50%; width: 20px; height: 20px; transform: translateY(-50%); color: var(--muted); }
.search input { width: 100%; min-height: 56px; border-radius: 999px; border: 2px solid var(--line); background: #fff; padding: 0 22px 0 52px; font-size: 16px; color: var(--ink); }
.search input:focus { border-color: var(--plum); outline: none; }
.filters { display: flex; flex-wrap: wrap; gap: 10px; }
.filter { min-height: 46px; padding: 0 18px; border-radius: 999px; border: 2px solid #D8D3D7; background: transparent; font-weight: 700; font-size: 14px; cursor: pointer; transition: background .25s, color .25s, border-color .25s; display: inline-flex; align-items: center; gap: 8px; }
.filter i { width: 11px; height: 10px; border-radius: var(--org-a); background: var(--fc, var(--ink)); }
.filter:hover { border-color: var(--plum); }
.filter[aria-pressed="true"] { background: var(--plum); border-color: var(--plum); color: #fff; }
.dir-count { font-size: 14px; font-weight: 700; color: var(--muted); margin-bottom: 22px; }
.profiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.profile { background: #fff; border-radius: 24px; overflow: hidden; box-shadow: var(--shadow-sm); transition: transform .3s, box-shadow .3s; display: flex; flex-direction: column; }
.profile[hidden] { display: none; }
.profile:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.profile .ph { border-radius: 0; min-height: 240px; }
.profile .tag { position: absolute; top: 16px; left: 16px; font-size: 12px; font-weight: 800; padding: 7px 12px; border-radius: 8px; letter-spacing: .04em; }
.profile .body { padding: 26px 26px 28px; display: flex; flex-direction: column; flex: 1; }
.profile .name { font-size: 19px; font-weight: 800; }
.profile .role { color: var(--muted); font-size: 14px; margin-top: 4px; }
.profile .ob { margin: 18px 0 22px; display: flex; flex-direction: column; gap: 8px; font-size: 15px; }
.profile .ob b.o { color: var(--turq-dark); } .profile .ob b.b { color: var(--pink); }
.profile .link-arrow { margin-top: auto; font-size: 15px; }
.empty { display: none; text-align: center; padding: 60px 20px; color: var(--muted); font-weight: 600; }
.empty.show { display: block; }

/* ---------- Formulario de inscripción ---------- */
.form-wrap { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.form-card { background: #fff; border-radius: 32px; box-shadow: var(--shadow-md); padding: clamp(28px, 4vw, 52px); }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 22px; }
.field { display: flex; flex-direction: column; gap: 8px; }
.field--full { grid-column: 1 / -1; }
.field label, .field legend { font-weight: 700; font-size: 15px; padding: 0; }
.field input, .field select, .field textarea { min-height: 52px; border-radius: 14px; border: 2px solid var(--line); background: var(--ice); padding: 0 16px; font-size: 16px; color: var(--ink); }
.field textarea { padding: 14px 16px; min-height: 110px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--plum); background: #fff; }
fieldset.field { border: 0; margin: 0; padding: 0; }
.checks { display: flex; flex-wrap: wrap; gap: 10px; }
.check { position: relative; }
.check input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.check span { display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border-radius: 999px; border: 2px solid var(--line); font-weight: 700; font-size: 14px; cursor: pointer; transition: background .2s, border-color .2s, color .2s; }
.check input:checked + span { background: var(--plum); border-color: var(--plum); color: #fff; }
.check input:focus-visible + span { outline: 3px solid var(--pink); outline-offset: 2px; }
.consent { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; color: var(--muted); }
.consent input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--plum); flex-shrink: 0; }
.form-ok { display: none; margin-top: 18px; background: var(--yellow); color: var(--plum); font-weight: 800; padding: 16px 20px; border-radius: 14px; }
form.sent .form-ok { display: block; }

/* ---------- Misión / visión ---------- */
.mv { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px; }
.mv article { background: #fff; border-radius: var(--radius); padding: 48px 44px; box-shadow: var(--shadow-sm); }
.mv p { font-size: clamp(20px, 1.8vw, 24px); line-height: 1.45; font-weight: 500; margin-top: 20px; }

/* ---------- CTA ---------- */
.join { background: var(--plum); color: #fff; border-radius: 40px; padding: clamp(48px, 7vw, 96px) clamp(28px, 6vw, 80px); display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 40px 56px; align-items: center; position: relative; overflow: hidden; isolation: isolate; }
.join .deco { position: absolute; width: 380px; aspect-ratio: 1; background: var(--pink); right: -130px; top: -170px; z-index: -1; border-radius: var(--org-a); }
.join .join-logo { width: min(240px, 60%); height: auto; margin-bottom: 30px; }
.join h2 { margin: 0 0 18px; }
.join p { color: #EBD3E5; font-size: 18px; max-width: 520px; }
.join form { display: flex; flex-direction: column; gap: 12px; }
.join label { font-weight: 700; font-size: 15px; }
.join input, .join textarea { min-height: 56px; border: 0; border-radius: 999px; padding: 0 24px; font-size: 16px; color: var(--ink); }
.join textarea { border-radius: 22px; padding: 16px 24px; resize: vertical; min-height: 120px; }
.join input:focus-visible, .join textarea:focus-visible { outline: 3px solid var(--yellow); outline-offset: 2px; }
.join .row { display: flex; flex-wrap: wrap; gap: 12px; }
.join .ok { display: none; background: var(--yellow); color: var(--plum); font-weight: 800; padding: 14px 20px; border-radius: 14px; }
.join form.sent .ok { display: block; }
.join--form { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }

/* ---------- Footer ---------- */
.site-footer { padding: 72px 0 48px; }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 24px; color: var(--muted); font-size: 15px; }
.site-footer .logo img { height: 44px; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 26px; font-weight: 700; }
.site-footer nav a { color: var(--ink); text-decoration: none; }
.site-footer nav a:hover { color: var(--pink); }

/* ---------- Animación de entrada (solo bloques principales) ---------- */
.js .reveal { opacity: 0; transform: translateY(36px); transition: opacity .9s ease, transform 1s cubic-bezier(.2, .7, .2, 1); }
.js .reveal.in { opacity: 1; transform: none; }
:focus-visible { outline: 3px solid var(--pink); outline-offset: 3px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; }
  .root path { stroke-dashoffset: 0 !important; opacity: 1 !important; }
  html { scroll-behavior: auto; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .pillars, .profiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .paths { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .path, .path:nth-child(n+4) { grid-column: span 1; }
  .path:last-child { grid-column: 1 / -1; }
  .nav { gap: 22px; }
}
@media (max-width: 1100px) {
  .menu-btn { display: inline-flex; }
  .nav { position: absolute; top: var(--header-h); left: 0; right: 0; background: var(--ice); flex-direction: column; align-items: flex-start; gap: 6px; padding: 18px var(--gutter) 28px; border-bottom: 1px solid var(--line); box-shadow: var(--shadow-md); display: none; }
  .menu-open .nav { display: flex; }
  .nav a { font-size: 18px; padding: 10px 0; }
  .header-cta .btn--outline { display: none; }
  .split, .join, .join--form, .panel-intro, .feature-band, .form-wrap { grid-template-columns: 1fr; }
  .steps, .mv { grid-template-columns: 1fr; }
  .tab { flex-direction: column; gap: 6px; padding: 18px 4px 14px; }
  .tab .td { display: none; }
}
@media (max-width: 640px) {
  :root { --header-h: 76px; }
  .logo img { height: 40px; }
  .pillars, .profiles, .paths, .form-grid { grid-template-columns: 1fr; }
  .header-cta .btn { padding: 0 20px; min-height: 46px; }
  .mv article { padding: 34px 28px; }
  .ph { min-height: 280px; }
  .tab .tn { display: none; }
  .tab .tt { font-size: 22px; }
  .compo { aspect-ratio: 1 / 1; border-radius: 30px; }
  .compo .blob-a { width: 95%; right: -34%; top: -16%; }
  .compo .blob-b { width: 62%; left: -22%; bottom: -26%; }
  .compo .book { width: 56%; left: 9%; top: 14%; }
  .compo .ring { width: 30%; right: 9%; bottom: 14%; }
  .compo .root { width: 180%; left: -40%; }
  .bg { opacity: .55; }
}

/* ==========================================================
   v5 — sistema: cuentas, perfiles, panel, chat, noticias, admin
   ========================================================== */
.flash { border-radius: 14px; padding: 14px 18px; font-weight: 700; margin-bottom: 16px; }
.flash--ok { background: #E3F2F4; color: #134E58; }
.flash--info { background: #FBF3D6; color: var(--plum); }
.flash--error { background: #FBE4EF; color: #8A0F4B; }
.flash-zone { max-width: var(--wrap); margin: 24px auto 0; padding: 0 var(--gutter); }
.stack { display: flex; flex-direction: column; gap: 18px; }
.field small { color: var(--muted); font-size: 13px; }
.field input[type="file"] { padding: 12px; min-height: auto; }
code { background: var(--blush); padding: 2px 6px; border-radius: 6px; font-size: .9em; }

/* Avatares */
.avatar { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.avatar--ini { display: inline-grid; place-items: center; font-weight: 800; font-size: 16px; }
.avatar--lg { width: 132px; height: 132px; font-size: 40px; border-radius: var(--org-a); border: 6px solid #fff; box-shadow: var(--shadow-md); }
.avatar--sm { width: 36px; height: 36px; font-size: 13px; }
.profile .ph img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ph-ini { font-family: var(--display); font-size: 64px; font-weight: 800; color: var(--muted); }
.stars { color: #E2A400; font-size: 17px; letter-spacing: 2px; display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.stars small { color: var(--muted); font-size: 13px; letter-spacing: 0; font-weight: 600; }
.profile .stars { margin-top: 10px; }

/* Ingresar / activar */
.auth-wrap { min-height: 70vh; display: grid; place-items: center; padding: clamp(48px, 8vw, 120px) var(--gutter); position: relative; isolation: isolate; overflow: hidden; }
.auth-card { width: 100%; max-width: 520px; background: #fff; border-radius: 32px; box-shadow: var(--shadow-md); padding: clamp(32px, 5vw, 56px); }
.auth-card--wide { max-width: 860px; }
.auth-card h1 { margin: 16px 0 10px; }
.auth-card .lead { margin-bottom: 28px; }
.auth-card .alt { margin-top: 22px; font-size: 15px; color: var(--muted); }

/* Perfil público */
.pf-hero { padding-top: clamp(64px, 8vw, 110px); position: relative; isolation: isolate; }
.pf-head { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 32px; align-items: center; }
.pf-head h1 { font-size: clamp(38px, 5vw, 64px); margin: 12px 0 8px; }
.pf-head .role { color: var(--muted); font-size: 18px; }
.pf-head .tag { position: static; display: inline-block; font-size: 12px; font-weight: 800; padding: 7px 12px; border-radius: 8px; }
.pf-actions { display: flex; flex-direction: column; gap: 10px; align-items: stretch; }
.pf-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 28px; margin-top: 56px; align-items: start; }
.card { background: #fff; border-radius: 26px; box-shadow: var(--shadow-sm); padding: clamp(26px, 3vw, 40px); }
.card + .card { margin-top: 24px; }
.card h2 { font-size: 26px; margin-bottom: 18px; }
.card .ob2 { display: grid; gap: 18px; }
.card .ob2 b { display: block; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; margin-bottom: 6px; }
.works { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 18px; }
.work { border-radius: 18px; overflow: hidden; background: var(--ice); display: flex; flex-direction: column; }
.work .wimg { aspect-ratio: 4 / 3; background: #DEDAD5; display: grid; place-items: center; color: var(--muted); font-size: 13px; font-weight: 700; }
.work .wimg img { width: 100%; height: 100%; object-fit: cover; }
.work .wb { padding: 16px 18px 18px; }
.work h3 { font-size: 19px; margin-bottom: 6px; }
.work p { font-size: 14px; color: var(--muted); }
.work a { font-size: 14px; }
.collabs { display: flex; flex-wrap: wrap; gap: 12px; }
.collab { display: flex; align-items: center; gap: 10px; text-decoration: none; background: var(--ice); padding: 6px 14px 6px 6px; border-radius: 999px; font-weight: 700; font-size: 14px; }
.collab:hover { background: var(--blush); }
.reviews { display: flex; flex-direction: column; gap: 18px; }
.review { border-top: 1px solid var(--line); padding-top: 18px; }
.review:first-child { border-top: 0; padding-top: 0; }
.review .who { display: flex; align-items: center; gap: 12px; font-weight: 700; margin-bottom: 8px; }
.review .who small { display: block; color: var(--muted); font-weight: 500; font-size: 13px; }
.review p { color: var(--muted); font-size: 15px; }
.muted { color: var(--muted); }

/* Panel */
.panel-shell { max-width: 1320px; margin: 0 auto; padding: clamp(32px, 4vw, 56px) var(--gutter) var(--section); display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 32px; align-items: start; }
.side { position: sticky; top: calc(var(--header-h) + 20px); background: #fff; border-radius: 26px; box-shadow: var(--shadow-sm); padding: 24px; }
.side .me { display: flex; gap: 12px; align-items: center; padding-bottom: 18px; margin-bottom: 14px; border-bottom: 1px solid var(--line); }
.side .me b { display: block; line-height: 1.2; }
.side .me small { color: var(--muted); font-size: 13px; }
.side nav { display: flex; flex-direction: column; gap: 4px; }
.side nav a { display: flex; justify-content: space-between; align-items: center; text-decoration: none; padding: 12px 14px; border-radius: 14px; font-weight: 700; font-size: 15px; }
.side nav a:hover { background: var(--ice); }
.side nav a[aria-current="page"] { background: var(--plum); color: #fff; }
.badge { min-width: 22px; height: 22px; border-radius: 999px; background: var(--pink); color: #fff; font-size: 12px; display: inline-grid; place-items: center; padding: 0 6px; }
.panel-main h1 { font-size: clamp(32px, 3.6vw, 46px); margin-bottom: 8px; }
.panel-main > .lead { margin-bottom: 30px; }
.form-grid .actions { grid-column: 1 / -1; display: flex; gap: 12px; flex-wrap: wrap; }
.list { display: flex; flex-direction: column; gap: 12px; }
.item { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 18px; background: #fff; border-radius: 20px; padding: 18px 22px; box-shadow: var(--shadow-sm); }
.item .grow { flex: 1 1 240px; min-width: 0; }
.item .grow b { display: block; }
.item .grow small { color: var(--muted); }
.item form { display: inline; }
.btn--sm { min-height: 40px; padding: 0 18px; font-size: 14px; }
.btn--ghost { background: transparent; color: var(--muted); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--pink); color: var(--pink); }
.pill { font-size: 12px; font-weight: 800; padding: 5px 11px; border-radius: 999px; background: var(--ice); border: 1px solid var(--line); text-transform: uppercase; letter-spacing: .06em; }
.pill--ok { background: #E3F2F4; border-color: #BFE2E8; color: #134E58; }
.pill--wait { background: #FBF3D6; border-color: #F0E2A8; color: var(--plum); }
.pill--no { background: #FBE4EF; border-color: #F3C2DA; color: #8A0F4B; }

/* Chat */
.chat { display: grid; grid-template-columns: 300px minmax(0, 1fr); background: #fff; border-radius: 26px; box-shadow: var(--shadow-md); overflow: hidden; min-height: 600px; }
.chat-list { border-right: 1px solid var(--line); overflow-y: auto; max-height: 72vh; }
.chat-list a { display: flex; gap: 12px; align-items: center; padding: 16px 18px; text-decoration: none; border-bottom: 1px solid var(--line); }
.chat-list a:hover { background: var(--ice); }
.chat-list a[aria-current="true"] { background: var(--blush); }
.chat-list .grow { min-width: 0; flex: 1; }
.chat-list b { display: block; font-size: 15px; }
.chat-list small { display: block; color: var(--muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat-win { display: flex; flex-direction: column; min-height: 600px; max-height: 72vh; }
.chat-top { display: flex; align-items: center; gap: 14px; padding: 16px 22px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.chat-top .grow { flex: 1; min-width: 160px; }
.chat-top b { display: block; }
.chat-top small { color: var(--muted); }
.chat-msgs { flex: 1; overflow-y: auto; padding: 24px; display: flex; flex-direction: column; gap: 10px; background: var(--ice); }
.msg { max-width: 72%; padding: 12px 16px; border-radius: 20px 20px 20px 6px; background: #fff; box-shadow: var(--shadow-sm); font-size: 15px; white-space: pre-wrap; overflow-wrap: anywhere; }
.msg time { display: block; font-size: 11px; color: var(--muted); margin-top: 4px; }
.msg--me { align-self: flex-end; background: var(--plum); color: #fff; border-radius: 20px 20px 6px 20px; }
.msg--me time { color: #EBD3E5; }
.chat-form { display: flex; gap: 10px; padding: 16px; border-top: 1px solid var(--line); }
.chat-form textarea { flex: 1; min-height: 52px; max-height: 160px; border-radius: 18px; border: 2px solid var(--line); padding: 12px 16px; resize: none; font-size: 15px; }
.chat-form textarea:focus { outline: none; border-color: var(--plum); }
.chat-empty { flex: 1; display: grid; place-items: center; text-align: center; color: var(--muted); padding: 40px; }
.notice { background: #FBF3D6; color: var(--plum); padding: 14px 22px; font-weight: 600; font-size: 14px; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; justify-content: space-between; }

/* Calificar */
.rate { display: inline-flex; flex-direction: row-reverse; gap: 2px; }
.rate input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.rate label { font-size: 30px; color: #D8D3D7; cursor: pointer; line-height: 1; }
.rate input:checked ~ label, .rate label:hover, .rate label:hover ~ label { color: #E2A400; }
.rate input:focus-visible + label { outline: 3px solid var(--pink); border-radius: 6px; }

/* Noticias */
.news-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.news-card { background: #fff; border-radius: 24px; overflow: hidden; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; text-decoration: none; color: var(--ink); transition: transform .3s, box-shadow .3s; }
.news-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.news-card .nimg { aspect-ratio: 16 / 10; background: #DEDAD5; display: grid; place-items: center; color: var(--muted); font-weight: 700; font-size: 13px; }
.news-card .nimg img { width: 100%; height: 100%; object-fit: cover; }
.news-card .nb { padding: 26px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.news-card .nmeta { font-size: 13px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--plum); }
.news-card h3 { font-size: 24px; line-height: 1.12; }
.news-card p { color: var(--muted); font-size: 15px; }
.news-card .link-arrow { margin-top: auto; padding-top: 8px; }
.news-card--lead { grid-column: 1 / -1; display: grid; grid-template-columns: 1.2fr 1fr; }
.news-card--lead .nimg { aspect-ratio: auto; min-height: 340px; }
.news-card--lead h3 { font-size: clamp(28px, 3vw, 40px); }
.article { max-width: 780px; margin: 0 auto; }
.article .nimg { border-radius: 28px; overflow: hidden; margin: 40px 0; }
.article .body { font-size: 19px; line-height: 1.75; }
.article .body p + p { margin-top: 1.1em; }

/* Admin */
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 36px; }
.stat { background: #fff; border-radius: 22px; padding: 22px; box-shadow: var(--shadow-sm); }
.stat b { display: block; font-family: var(--display); font-size: 40px; line-height: 1; }
.stat span { color: var(--muted); font-size: 14px; font-weight: 600; }
.detail { background: var(--ice); border-radius: 14px; padding: 14px 16px; font-size: 14px; color: var(--muted); width: 100%; }
.detail b { color: var(--ink); }
.tabs-mini { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 24px; }
.tabs-mini a { text-decoration: none; padding: 10px 16px; border-radius: 999px; border: 2px solid var(--line); font-weight: 700; font-size: 14px; }
.tabs-mini a[aria-current="page"] { background: var(--plum); border-color: var(--plum); color: #fff; }

@media (max-width: 960px) {
  .pf-head { grid-template-columns: auto minmax(0, 1fr); }
  .pf-actions { grid-column: 1 / -1; flex-direction: row; flex-wrap: wrap; }
  .pf-grid, .panel-shell { grid-template-columns: 1fr; }
  .side { position: static; }
  .side nav { flex-direction: row; flex-wrap: wrap; }
  .chat { grid-template-columns: 1fr; }
  .chat-list { max-height: 220px; border-right: 0; border-bottom: 1px solid var(--line); }
  .news-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .news-card--lead { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .pf-head { grid-template-columns: 1fr; }
  .news-grid { grid-template-columns: 1fr; }
  .msg { max-width: 88%; }
}
a.filter { text-decoration: none; color: var(--ink); }
a.filter[aria-pressed="true"] { color: #fff; }
