/* PIA Conecta — demo. Solo modo claro (marca del cliente). */
:root {
  --brand: #68A1C0;
  --brand-chip: #61A1C2;
  --brand-ink: #3F7FA3;      /* texto azul sobre blanco (AA) */
  --brand-soft: #EAF3F8;
  --quote: #9ECDDD;
  --bday: #DEF0FE;
  --accent: #4371C4;         /* botón Reconocer */
  --bg: #FAFAFB;
  --card: #FFFFFF;
  --ink: #15171A;
  --ink-2: #4B5058;
  --muted: #6E737B;
  --line: #ECEDF0;
  --red: #E5484D;
  --ok: #2E8B57;
  --shadow: 0 1px 2px rgba(20, 30, 45, .04), 0 4px 16px rgba(20, 30, 45, .06);
  --shadow-lg: 0 8px 30px rgba(20, 30, 45, .14);
  --r: 16px;
  --r-lg: 20px;
  --pad: 16px;
  --hh: 64px;
  --tabh: 62px;
  --st: env(safe-area-inset-top, 0px);
  --sb: env(safe-area-inset-bottom, 0px);
  --maxw: 430px;
  color-scheme: light;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: #E7EAEE; }
body {
  margin: 0; background: #E7EAEE; color: var(--ink);
  font-family: 'Montserrat', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 15px; line-height: 1.4; -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent; overflow-x: hidden;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; color: inherit; }
button { background: none; border: 0; padding: 0; cursor: pointer; }
h1, h2, h3, h4, p { margin: 0; }
[hidden] { display: none !important; }
.ic { width: 24px; height: 24px; flex: none; }
:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; border-radius: 8px; }

.app {
  position: relative; max-width: var(--maxw); margin: 0 auto; min-height: 100vh; min-height: 100dvh;
  background: var(--bg); overflow-x: clip;
}
@media (min-width: 431px) { .app { box-shadow: 0 0 0 1px rgba(0,0,0,.04), 0 10px 40px rgba(0,0,0,.08); } }

/* ---------- Header ---------- */
.topbar {
  position: sticky; top: 0; z-index: 30; height: calc(var(--hh) + var(--st)); padding: var(--st) 8px 0;
  display: grid; grid-template-columns: 48px 1fr 48px 48px; align-items: center; gap: 2px;
  background: rgba(250, 250, 251, .94); backdrop-filter: saturate(1.6) blur(12px); -webkit-backdrop-filter: saturate(1.6) blur(12px);
  border-bottom: 2px solid var(--line);
}
.hbtn { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 50%; position: relative; color: var(--ink); }
.hbtn .ic { width: 26px; height: 26px; stroke-width: 1.7; }
#btnMenu .ic { width: 28px; height: 28px; stroke-width: 1.8; }
.hbtn:active { background: rgba(0,0,0,.05); }
.bell-dot { position: absolute; top: 11px; right: 12px; width: 8px; height: 8px; border-radius: 50%; background: var(--red); border: 1.5px solid var(--bg); }
.brand { display: flex; align-items: center; justify-content: center; gap: 10px; min-width: 0; padding-left: 8px; }
.brand img { width: 46px; height: 46px; }
.brand-t { font-weight: 800; color: var(--brand); font-size: 21px; letter-spacing: .2em; line-height: 1; margin-top: 4px; }
@media (max-width: 370px) { .brand-t { font-size: 18px; letter-spacing: .16em; } .brand img { width: 40px; height: 40px; } }

/* ---------- View ---------- */
.view { padding: 0 0 calc(var(--tabh) + var(--sb) + 24px); outline: none; }
.view.enter { animation: enter .22s ease-out; }
@keyframes enter { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.screen { padding: 14px var(--pad) 0; }
.page-t { font-size: 29px; font-weight: 800; letter-spacing: -.01em; margin: 14px 4px 6px; }
.page-sub { color: var(--muted); font-size: 16px; line-height: 1.35; margin: 0 4px 16px; }
.sec-t { font-size: 17px; font-weight: 700; margin: 4px 0 10px; }
.mt { margin-top: 22px; }
.muted { color: var(--muted); font-size: 14px; }
.empty { text-align: center; color: var(--muted); padding: 30px 10px; }
.card { background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); }

/* ---------- Tabbar ---------- */
.tabbar {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); z-index: 30; width: 100%; max-width: var(--maxw);
  height: calc(var(--tabh) + var(--sb)); padding: 4px 4px var(--sb); display: grid; grid-template-columns: repeat(5, 1fr);
  background: rgba(250, 250, 251, .96); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-top: 2px solid var(--line);
}
.tab { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; color: #5E636B; font-size: 12.5px; font-weight: 500; min-height: 48px; }
.tab-ic .ic { width: 26px; height: 26px; stroke-width: 1.6; }
.tab.active { color: var(--brand); font-weight: 600; }
.tab.active .ic { fill: currentColor; }
.tab.active .ic .in { stroke: #fff; }
.tab:active .tab-ic { transform: scale(.9); }
.tab-ic { transition: transform .15s; display: block; height: 26px; }

/* ---------- Chips / botones ---------- */
.chips { display: flex; gap: 10px; margin: 0 0 14px; overflow-x: auto; scrollbar-width: none; padding: 2px 0; margin-inline: calc(-1 * var(--pad)); padding-inline: var(--pad); scroll-padding-inline: var(--pad); }
.chips::-webkit-scrollbar { display: none; }
.chips.three { display: grid; grid-template-columns: repeat(3, 1fr); overflow: visible; margin-inline: 0; padding-inline: 0; }
.chip {
  flex: none; height: 40px; padding: 0 18px; border-radius: 999px; background: #fff; color: #555A62; font-weight: 600; font-size: 13.5px;
  box-shadow: 0 1px 6px rgba(20,30,45,.05); display: inline-flex; align-items: center; justify-content: center; gap: 6px; white-space: nowrap;
  transition: background .15s, color .15s;
}
.chip.on { background: var(--brand-chip); color: #fff; box-shadow: none; }
.chip.on { background: #5C9BBC; } /* AA para texto blanco 13.5px semibold */
.chip .ic { width: 16px; height: 16px; }
.chip.sel { position: relative; padding: 0 12px; min-width: 0; }
.chip.sel span { overflow: hidden; text-overflow: ellipsis; }
.chip.sel select { position: absolute; inset: 0; opacity: 0; width: 100%; font-size: 16px; cursor: pointer; }
.chips.three .chip { padding: 0 8px; height: 44px; font-size: 14px; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 20px; border-radius: 999px; font-weight: 700; font-size: 15px; transition: transform .12s, background .15s; }
.btn:active { transform: scale(.97); }
.btn .ic { width: 20px; height: 20px; }
.btn-primary { background: #4F8FB1; color: #fff; }
.btn-ghost { background: #fff; color: var(--ink-2); box-shadow: inset 0 0 0 1.5px var(--line); }
.btn-done { background: #E5F3EA; color: #1E6B40; }
.btn-block { width: 100%; }
.btn-lg { min-height: 52px; font-size: 16px; }
.btn-sm { min-height: 40px; padding: 0 14px; font-size: 14px; }
.btn[disabled] { opacity: .5; cursor: default; }
.icon-btn { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; color: var(--muted); flex: none; }
.icon-btn.brand { color: var(--brand); }
.icon-btn.brand .ic { width: 26px; height: 26px; stroke-width: 1.8; }
.pill-link { white-space: nowrap; flex: none; display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: 999px; background: #F0F6FA; color: var(--brand-ink); font-weight: 600; font-size: 13.5px; margin-left: auto; }
.pill-link .ic { width: 16px; height: 16px; }
.pill-link.white { background: #fff; margin-left: 0; box-shadow: 0 1px 4px rgba(0,0,0,.04); }
.link { color: var(--brand-ink); font-weight: 600; font-size: 14px; display: inline-flex; align-items: center; gap: 4px; }
.link .ic { width: 16px; height: 16px; }
.back { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 12px 0 4px; margin: 0 0 6px -4px; color: var(--brand-ink); font-weight: 600; }
.back .ic { width: 22px; height: 22px; }
.tag { display: inline-block; padding: 4px 9px; border-radius: 999px; font-size: 11px; font-weight: 600; letter-spacing: .02em; }
.tag-azul { background: #E6F0FA; color: #2D6BA8; }
.tag-morado { background: #F0E9FB; color: #7240C2; }
.tag-verde { background: #E3F4E8; color: #23824A; }
.tag-naranjo { background: #FDEEE3; color: #C2531A; }
.tag-gris { background: #EBEEF2; color: #4B5563; }

/* ---------- Inicio ---------- */
.composer { display: flex; align-items: center; gap: 4px; margin-bottom: 10px; }
.composer > .av { margin-right: 6px; }
.comp-field { flex: 1; min-width: 0; background: #F0F1F3; border-radius: 12px; border: 1px solid #E6E7EA; }
.comp-field textarea { display: block; width: 100%; border: 0; background: transparent; resize: none; font-size: 16px; line-height: 22px; padding: 9px 12px; min-height: 40px; outline: none; color: var(--ink); }
.comp-field textarea::placeholder { color: #7A7F87; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.comp-field textarea:placeholder-shown { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.comp-field:focus-within { border-color: var(--brand); background: #fff; }
.comp-prev { position: relative; padding: 0 8px 8px; }
.comp-prev img { width: 100%; max-height: 160px; object-fit: cover; border-radius: 10px; }
.comp-prev .icon-btn { position: absolute; top: 4px; right: 12px; background: rgba(0,0,0,.55); color: #fff; width: 32px; height: 32px; }
.comp-prev .icon-btn .ic { width: 18px; height: 18px; }
.composer .icon-btn { width: 40px; }
.composer label.icon-btn { cursor: pointer; }

.hero-banner, .car-slide { position: relative; display: block; min-height: 150px; border-radius: var(--r); overflow: hidden; background: #3F7EA3; color: #fff; }
.hero-banner img, .car-slide img { position: absolute; right: 0; top: 0; height: 100%; width: 66%; object-fit: cover; object-position: left center; }
.hero-banner::before, .car-slide::before { content: ''; position: absolute; inset: 0; z-index: 1; background: linear-gradient(90deg, #3E7EA4 0%, #4683A8 36%, rgba(80,138,172,.82) 50%, rgba(98,150,182,.18) 72%, rgba(98,150,182,0) 85%); }
.hb-txt { position: relative; z-index: 2; padding: 14px 16px; min-height: 150px; display: flex; flex-direction: column; align-items: flex-start; justify-content: center; max-width: 64%; }
.badge-dark { background: rgba(20, 35, 50, .72); color: #fff; font-size: 10.5px; font-weight: 600; letter-spacing: .04em; padding: 4px 9px; border-radius: 999px; margin-bottom: 5px; }
.hb-txt h2 { font-size: 21px; font-weight: 700; line-height: 1.08; margin-bottom: 4px; text-shadow: 0 1px 8px rgba(0,0,0,.12); }
.hb-txt p { font-size: 13px; line-height: 1.25; opacity: .96; }
.btn-white { display: inline-flex; align-items: center; gap: 8px; margin-top: 10px; height: 32px; padding: 0 16px; border-radius: 999px; background: #fff; color: #2D6E96; font-weight: 700; font-size: 13.5px; }
.btn-white .ic { width: 16px; height: 16px; }
.inicio .chips { margin-top: 10px; margin-bottom: 10px; }
.inicio .chip { height: 38px; min-width: 92px; }

.feed { display: flex; flex-direction: column; gap: 10px; }
.post { padding: 14px 16px 12px; }
.post.is-new { animation: newpost .5s ease-out; }
@keyframes newpost { from { box-shadow: 0 0 0 3px rgba(104,161,192,.5), var(--shadow); transform: translateY(-4px); } }
.p-head { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.p-who { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.p-name { font-weight: 600; font-size: 15px; }
.p-sub { color: #80858D; font-size: 13px; }
.p-more { margin-right: -10px; }
.p-split { display: grid; grid-template-columns: 1fr 108px; gap: 12px; align-items: start; }
.p-img { width: 108px; height: 68px; object-fit: cover; border-radius: 8px; margin-top: -2px; }
.p-title { font-size: 14.5px; font-weight: 700; line-height: 1.25; margin-bottom: 4px; }
.p-text { font-size: 13.5px; color: var(--ink-2); line-height: 1.4; }
.p-gal { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; margin-top: 10px; }
.p-gal img { width: 100%; aspect-ratio: 1.6; object-fit: cover; border-radius: 6px; }
.reacts { display: flex; align-items: center; gap: 2px; margin-top: 8px; }
.rx { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 8px; margin-left: -4px; color: var(--ink-2); font-size: 13px; border-radius: 999px; }
.rx b { font-weight: 500; min-width: 18px; }
.rx-ic { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; color: #fff; }
.rx-ic .ic { width: 13px; height: 13px; fill: #fff; stroke-width: 2.2; }
.rx-heart .rx-ic { background: #F04B54; }
.rx-like .rx-ic { background: #2F8FE6; }
.rx-like .rx-ic .ic { fill: none; }
.rx-com .ic { width: 22px; height: 22px; stroke-width: 1.7; }
.rx.on b { font-weight: 700; color: var(--ink); }
.rx.on .rx-ic { box-shadow: 0 0 0 3px rgba(240,75,84,.18); }
.rx-like.on .rx-ic { box-shadow: 0 0 0 3px rgba(47,143,230,.2); }
.rx-like.on .rx-ic .ic { fill: #fff; stroke: #2F8FE6; stroke-width: 1.4; }
.rx.pop .rx-ic { animation: pop .3s ease-out; }
@keyframes pop { 40% { transform: scale(1.3); } }
.recon-post { display: flex; gap: 12px; align-items: center; background: #F2F6FC; border-radius: 12px; padding: 10px 12px; margin-bottom: 8px; }
.recon-star { width: 40px; height: 40px; flex: none; border-radius: 50%; background: var(--accent); display: grid; place-items: center; color: #fff; }
.recon-star .ic { width: 20px; height: 20px; fill: #fff; }
.rp-t { font-size: 14px; margin-bottom: 4px; }
.rp-t a { font-weight: 600; color: var(--brand-ink); }

.cumple { position: relative; overflow: hidden; background: var(--bday); box-shadow: none; padding: 16px; display: grid; grid-template-columns: 1fr; gap: 12px; }
.confetti i { position: absolute; width: 6px; height: 3px; border-radius: 2px; opacity: .9; }
.cumple > * { position: relative; }
.kicker { display: flex; align-items: center; gap: 10px; font-size: 12px; letter-spacing: .04em; color: #4B5563; font-weight: 500; }
.kicker .ic { width: 20px; height: 20px; color: #3A84C9; }
.cumple h3 { font-size: 18px; font-weight: 700; margin: 6px 0 2px; }
.c-sub { font-size: 13.5px; color: #5A6069; }
.c-people { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; }
.c-people a { display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; font-size: 11.5px; line-height: 1.15; color: #2B2F35; }
.c-people .av { box-shadow: 0 0 0 2px #fff; }
.cumple .pill-link { justify-self: start; }

/* ---------- Avatares ---------- */
.av { width: var(--s); height: var(--s); border-radius: 50%; overflow: hidden; flex: none; display: inline-grid; place-items: center; background: #E8ECF0; }
.av img { width: 100%; height: 100%; object-fit: cover; }
.av-ini { font-weight: 700; font-size: calc(var(--s) * .36); letter-spacing: .02em; }
.av-pia { background: #fff; }

/* ---------- Detalles comunes ---------- */
.article { display: flex; flex-direction: column; gap: 12px; padding-bottom: 8px; }
.article > p { color: var(--ink-2); font-size: 15px; line-height: 1.55; }
.art-img { width: 100%; aspect-ratio: 16/10; object-fit: cover; border-radius: var(--r); }
.art-t { font-size: 24px; font-weight: 800; line-height: 1.15; }
.art-lead { font-size: 16px !important; color: var(--ink) !important; font-weight: 500; }
.ni-meta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.ni-date { color: #80858D; font-size: 12px; }
.steps { margin: 0; padding-left: 0; list-style: none; counter-reset: s; display: flex; flex-direction: column; gap: 10px; }
.steps li { counter-increment: s; display: flex; gap: 12px; align-items: flex-start; font-size: 15px; color: var(--ink-2); }
.steps li::before { content: counter(s); flex: none; width: 28px; height: 28px; border-radius: 50%; background: var(--brand-soft); color: var(--brand-ink); font-weight: 700; display: grid; place-items: center; font-size: 14px; }
.post.detail { margin-bottom: 12px; }
.comments { padding: 14px 16px; }
.cmt { display: flex; gap: 10px; margin-bottom: 12px; }
.cmt > div { background: #F3F4F6; border-radius: 14px; padding: 8px 12px; }
.cmt b { font-size: 13.5px; }
.cmt p { font-size: 14px; color: var(--ink-2); }
.cmt-form { display: flex; gap: 8px; align-items: center; margin-top: 4px; }
.cmt-form input { flex: 1; min-width: 0; height: 44px; border-radius: 999px; border: 1px solid var(--line); background: #F6F7F8; padding: 0 14px; font-size: 16px; outline: none; }
.cmt-form input:focus { border-color: var(--brand); background: #fff; }
.empty-box { text-align: center; padding: 36px 20px; color: var(--muted); display: flex; flex-direction: column; align-items: center; gap: 12px; }
.empty-box > .ic { width: 40px; height: 40px; color: #B5BAC1; }

/* ---------- Noticias ---------- */
.carousel { position: relative; margin-bottom: 12px; }
.car-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; border-radius: var(--r); scrollbar-width: none; overscroll-behavior-x: contain; }
.car-track::-webkit-scrollbar { display: none; }
.car-slide { flex: 0 0 100%; scroll-snap-align: start; min-height: 172px; border-radius: 0; }
.car-slide .hb-txt { min-height: 172px; padding-bottom: 18px; }
.car-slide img { width: 62%; }
.car-slide .hb-txt { max-width: 66%; }
.car-slide .hb-txt h2 { font-size: 19px; }
.car-slide .hb-txt p { font-size: 12.5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.dots { position: absolute; right: 8px; bottom: 4px; display: flex; z-index: 3; }
.dot { width: 22px; height: 28px; display: grid; place-items: center; }
.dot::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: rgba(255,255,255,.55); transition: background .2s, transform .2s; }
.dot.on::before { background: #fff; transform: scale(1.1); }
.news-list { display: flex; flex-direction: column; gap: 8px; }
.news-item { display: grid; grid-template-columns: 112px 1fr 40px; gap: 12px; align-items: center; padding: 6px; border-radius: 14px; }
.news-item img { width: 112px; height: 78px; object-fit: cover; border-radius: 10px; }
.ni-body { min-width: 0; padding: 4px 0; }
.ni-body h3 { font-size: 14.5px; font-weight: 700; line-height: 1.2; margin: 6px 0 3px; }
.ni-body p { font-size: 12px; color: #6A6F77; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.ni-body .tag { font-size: 10px; padding: 3px 8px; }
.ni-body .ni-date { font-size: 10.5px; }
.ni-body .ni-meta { gap: 6px; }
.arrow-c { width: 34px; height: 34px; border-radius: 50%; background: #EEF3FB; color: #2F6DB5; display: grid; place-items: center; }
.arrow-c .ic { width: 18px; height: 18px; }

/* ---------- Beneficios ---------- */
.ben-dest { position: relative; display: block; min-height: 150px; border-radius: var(--r-lg); overflow: hidden; background: #FCEFE6; box-shadow: var(--shadow); margin-bottom: 14px; }
.ben-dest img { position: absolute; right: 0; top: 0; height: 100%; width: 60%; object-fit: cover; }
.ben-dest::before { content: ''; position: absolute; inset: 0; z-index: 1; background: linear-gradient(90deg, #FDF2EA 0%, #FCEFE6 42%, rgba(252,239,230,.75) 52%, rgba(252,239,230,0) 68%); }
.bd-txt { position: relative; z-index: 2; padding: 13px 16px; display: flex; flex-direction: column; align-items: flex-start; max-width: 64%; }
.bd-k { display: flex; align-items: center; gap: 6px; color: #3F7FA3; font-weight: 600; font-size: 12.5px; }
.bd-k .ic { width: 18px; height: 18px; fill: var(--brand); stroke: var(--brand); }
.bd-txt h2 { font-size: 17px; font-weight: 700; color: #1C2A4A; margin: 8px 0 3px; letter-spacing: -.01em; }
.bd-txt p { font-size: 12px; color: #4B5563; line-height: 1.35; }
.bd-txt .btn { min-height: 34px; padding: 0 18px; font-size: 13.5px; margin-top: 10px; }
.bd-arrow { position: absolute; z-index: 2; top: 10px; right: 10px; width: 34px; height: 34px; border-radius: 50%; background: #fff; display: grid; place-items: center; color: var(--brand); box-shadow: 0 2px 8px rgba(0,0,0,.08); }
.bd-arrow .ic { width: 18px; height: 18px; }
.ben-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 14px; }
.ben { position: relative; display: flex; flex-direction: column; min-height: 144px; padding: 10px 10px 50px 12px; border-radius: var(--r-lg); }
.ben-durazno { background: #FDF1EC; } .ben-lila { background: #F4F1FC; } .ben-celeste { background: #EDF3FC; } .ben-verde { background: #EFF6F1; } .ben-azul { background: #DCEAF2; }
.ben-ic { width: 42px; height: 42px; border-radius: 10px; display: grid; place-items: center; margin-bottom: 14px; }
.ben-ic svg { width: 28px; height: 28px; }
.ben-durazno .ben-ic { background: #FCDCCB; } .ben-lila .ben-ic { background: #E9DDFB; } .ben-celeste .ben-ic { background: #D9E8FB; } .ben-verde .ben-ic { background: #D8EFDF; }
.ben h3 { font-size: 13.5px; font-weight: 700; margin-bottom: 4px; }
.ben p { font-size: 11.5px; color: #555B63; line-height: 1.3; }
.ben-go { position: absolute; right: 10px; bottom: 8px; width: 30px; height: 30px; border-radius: 50%; background: #fff; display: grid; place-items: center; color: #2B2F35; box-shadow: 0 1px 4px rgba(0,0,0,.05); }
.ben-go .ic { width: 20px; height: 20px; }
.ben-wide { position: relative; display: flex; align-items: center; gap: 18px; min-height: 70px; padding: 6px 54px 6px 8px; background: #DCEAF2; border-radius: var(--r); }
.bw-ic { width: 58px; height: 58px; flex: none; border-radius: 12px; background: #A9CDDF; display: grid; place-items: center; }
.bw-ic svg { width: 40px; height: 40px; }
.ben-wide h3 { font-size: 16px; font-weight: 700; }
.ben-wide p { font-size: 12.5px; color: #4B5563; }
.ben-wide .ben-go { top: 50%; bottom: auto; transform: translateY(-50%); }
.ben-hero { height: 140px; border-radius: var(--r); display: grid; place-items: center; }
.ben-ic.big { width: 72px; height: 72px; border-radius: 18px; margin: 0; }
.ben-ic.big svg { width: 44px; height: 44px; }
.ben-azul .ben-ic { background: #A9CDDF; }

/* ---------- Eventos ---------- */
.ev-list { display: flex; flex-direction: column; gap: 12px; }
.ev { position: relative; display: grid; grid-template-columns: 126px 1fr; gap: 14px; padding: 6px 48px 6px 6px; border-radius: var(--r); align-items: center; }
.ev-img { position: relative; width: 126px; aspect-ratio: 367 / 319; border-radius: 12px; overflow: hidden; background: #E8ECF0; }
.ev-img img { width: 100%; height: 100%; object-fit: cover; }
.ev-img.big { width: 100%; border-radius: var(--r); }
.ev-img { container-type: inline-size; }
.date-badge { position: absolute; top: 2px; left: 2px; width: 44%; height: 54%; min-width: 50px; border-radius: 10px; background: #fff; color: #4E8DB0; display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1; box-shadow: 0 2px 6px rgba(0,0,0,.12); }
.date-badge b { font-size: 25px; font-weight: 800; letter-spacing: -.02em; }
.date-badge span { font-size: 11.5px; font-weight: 700; margin-top: 2px; }
.date-badge.blue { background: #5E9CBE; color: #fff; }
.date-badge b { font-size: 20cqw; }
.date-badge span { font-size: 9cqw; }
.ev-img.big .date-badge { top: 1%; left: 1%; border-radius: 16px; }
.ev-body { min-width: 0; display: flex; flex-direction: column; gap: 5px; }
.ev-body h3 { font-size: 15px; font-weight: 700; line-height: 1.2; margin-bottom: 2px; }
.ev-body p { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: #4E5560; }
.ev-body p .ic { width: 16px; height: 16px; color: #3B4250; stroke-width: 1.8; }
.ev .arrow-c { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); background: #EEF0FC; color: #3B49C4; }
.ev-ok { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 700; color: var(--ok); }
.ev-ok .ic { width: 14px; height: 14px; stroke-width: 3; }
.ev-facts { display: flex; flex-direction: column; gap: 8px; background: #fff; border-radius: var(--r); padding: 14px; box-shadow: var(--shadow); }
.ev-facts p { display: flex; align-items: center; gap: 10px; font-size: 15px; color: var(--ink-2); }
.ev-facts .ic { width: 20px; height: 20px; color: var(--brand-ink); }
.cupos { display: flex; align-items: center; gap: 8px; font-size: 14px; color: #8A5A10; background: #FFF4DE; padding: 10px 14px; border-radius: 12px; }
.cupos .ic { width: 18px; height: 18px; }

/* ---------- Mi perfil ---------- */
.perfil { position: relative; }
.search-fab { position: absolute; top: 10px; right: 14px; width: 48px; height: 48px; border-radius: 50%; background: #5E9CBE; color: #fff; display: grid; place-items: center; z-index: 2; }
.search-fab .ic { width: 26px; height: 26px; stroke-width: 2.2; }
.me-head { display: flex; align-items: center; gap: 18px; padding: 22px 0 12px 4px; }
.me-av { position: relative; flex: none; }
.me-av .av { box-shadow: 0 2px 10px rgba(0,0,0,.08); }
.cam { position: absolute; right: -2px; bottom: 6px; width: 36px; height: 36px; border-radius: 50%; background: #0F1720; color: #fff; display: grid; place-items: center; border: 3px solid var(--bg); }
.cam .ic { width: 17px; height: 17px; }
.me-id { min-width: 0; }
.me-id h1 { font-size: 22px; font-weight: 800; letter-spacing: -.01em; margin-bottom: 6px; }
.me-id p { color: #5A6069; font-size: 14px; margin-bottom: 6px; display: flex; align-items: center; gap: 4px; }
.me-id .loc .ic { width: 16px; height: 16px; fill: #A0A6AE; stroke: #A0A6AE; }
.me-id .loc .ic circle { fill: #fff; stroke: #fff; }
.quote { position: relative; display: flex; align-items: center; gap: 10px; background: var(--quote); border-radius: var(--r); padding: 14px 14px 14px 18px; min-height: 68px; }
.q-mark { font-family: Georgia, serif; font-size: 48px; line-height: 0; color: #5F95B3; font-weight: 700; margin-top: 20px; flex: none; }
.quote p { flex: 1; font-size: 16px; font-weight: 600; color: #2B4A5C; line-height: 1.25; }
.q-edit { width: 44px; height: 44px; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex: none; background: radial-gradient(circle at center, #fff 0 14px, transparent 14.5px); }
.q-edit .ic { position: relative; width: 15px; height: 15px; color: #3B4250; }
.quote.editing { display: block; padding: 12px; }
.stats { display: grid; grid-template-columns: 1fr 1fr 1.3fr; margin: 12px 0 14px; padding: 12px 0; }
.stats > div { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.stats > div + div { border-left: 1px solid var(--line); }
.stats b { font-size: 17px; font-weight: 700; }
.stats span { font-size: 12px; color: #6A6F77; }
.utabs { display: grid; grid-template-columns: 1fr 1fr 1.4fr; border-bottom: 1px solid var(--line); margin: 0 calc(-1 * var(--pad)); padding: 0 var(--pad); }
.utabs button { min-height: 46px; font-size: 14.5px; color: #5A6069; font-weight: 500; position: relative; border-radius: 10px 10px 0 0; }
.utabs button.on { color: var(--brand-ink); font-weight: 700; background: #fff; }
.utabs button.on::after { content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 3px; background: var(--brand); border-radius: 2px; }
.ptab { background: #fff; margin: 0 calc(-1 * var(--pad)); padding: 18px 20px 26px; min-height: 260px; }
.ptab .rec { margin-bottom: 10px; }
.sobre-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.sobre-h h3 { font-size: 15px; font-weight: 700; }
.sobre-h .h-lg { font-size: 18px; }
.btn-edit { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 16px; border-radius: 999px; background: #F5F6F8; box-shadow: 0 1px 3px rgba(0,0,0,.06); font-size: 13px; font-weight: 500; }
.btn-edit .ic { width: 16px; height: 16px; }
.sobre { font-size: 13.5px; color: #4B5058; line-height: 1.5; }
.info { margin: 18px 0 0; display: flex; flex-direction: column; gap: 14px; }
.info > div { display: grid; grid-template-columns: 22px 92px 1fr; gap: 8px; align-items: center; font-size: 13.5px; }
.info .ic { width: 18px; height: 18px; color: #3B4250; }
.info dt { color: #6A6F77; }
.info dd { margin: 0; color: #3B4048; }
.team { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding-top: 4px; }
.team-add { width: 44px; height: 44px; border-radius: 50%; background: #ECEEF1; display: grid; place-items: center; color: #2B2F35; }
.team-add .ic { width: 22px; height: 22px; stroke-width: 2.4; }
.act { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.act > .ic { width: 20px; height: 20px; color: var(--brand-ink); }
.act div { display: flex; flex-direction: column; min-width: 0; }
.act b { font-size: 14px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.act small { color: var(--muted); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rec { display: flex; gap: 14px; align-items: center; padding: 14px; }
.rec-star { width: 52px; height: 52px; flex: none; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; }
.rec-star .ic { width: 26px; height: 26px; fill: #fff; }
.rec h4 { font-size: 15px; font-weight: 700; margin-bottom: 2px; }
.rec p { font-size: 13.5px; color: var(--ink-2); line-height: 1.35; }
.rec small { display: block; margin-top: 4px; font-size: 11.5px; color: var(--muted); }
.inline-ed textarea { width: 100%; border-radius: 12px; border: 1.5px solid var(--brand); padding: 10px 12px; font-size: 16px; line-height: 1.4; resize: vertical; outline: none; background: #fff; }
.ie-actions { display: flex; gap: 8px; justify-content: flex-end; align-items: center; margin-top: 8px; }
.ie-actions .count { margin-right: auto; font-size: 12px; color: var(--muted); }
.on-quote .count { color: #2B4A5C; }

/* ---------- Contactos ---------- */
.search { position: relative; display: flex; align-items: center; margin-top: 2px; }
.search input { flex: 1; height: 44px; border-radius: 10px 999px 999px 10px; border: 0; background: #fff; padding: 0 56px 0 12px; font-size: 16px; outline: none; box-shadow: 0 1px 4px rgba(0,0,0,.03); -webkit-appearance: none; appearance: none; }
.search input::placeholder { color: #80858D; }
.search input:focus { box-shadow: 0 0 0 2px var(--brand); }
.search-btn { position: absolute; right: -6px; width: 50px; height: 50px; border-radius: 50%; background: #5E9CBE; color: #fff; display: grid; place-items: center; }
.search-btn .ic { width: 26px; height: 26px; stroke-width: 2.2; }
.contactos .page-t { margin-top: 12px; }
.contactos .chips.three { padding-bottom: 14px; border-bottom: 2px solid var(--line); margin-bottom: 0; }
.clist { display: flex; flex-direction: column; }
.crow { display: flex; align-items: center; gap: 8px; padding: 12px 0; border-bottom: 2px solid var(--line); }
.crow-main { flex: 1; min-width: 0; display: flex; align-items: center; gap: 14px; }
.crow-main div { min-width: 0; display: flex; flex-direction: column; }
.crow-main b { font-size: 17px; font-weight: 700; line-height: 1.2; }
.crow-main span { font-size: 15px; color: #2B2F35; }
.crow-main small { font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.btn-conn { flex: none; display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 14px; border-radius: 999px; background: #fff; border: 1.5px solid #ECEDF0; font-weight: 700; font-size: 13px; align-self: flex-end; margin-bottom: 2px; transition: background .15s, color .15s; }
.btn-conn .ic { width: 20px; height: 20px; stroke-width: 1.7; }
.btn-conn.on { background: #E5F3EA; border-color: #E5F3EA; color: #1E6B40; }
.btn-conn.on .ic { stroke-width: 2.6; width: 16px; height: 16px; }
.count-line { text-align: center; font-size: 12.5px; color: var(--muted); padding: 14px 0 0; }

/* ---------- Perfil de otra persona ---------- */
.persona .back { margin-bottom: 4px; }
.cover { height: 78px; border-radius: 12px; overflow: hidden; }
.cover img { width: 100%; height: 100%; object-fit: cover; object-position: center 60%; }
.pp-head { display: flex; gap: 10px; align-items: flex-start; margin-top: -46px; padding-left: 2px; }
.pp-av { border: 3px solid #fff; box-shadow: 0 2px 10px rgba(0,0,0,.08); }
.pp-id { padding-top: 52px; min-width: 0; }
.pp-id h1 { font-size: 21px; font-weight: 700; line-height: 1.1; margin-bottom: 6px; }
.pp-id p { display: flex; align-items: center; gap: 6px; font-size: 13.5px; color: #2B2F35; margin-bottom: 5px; }
.pp-id p .ic { width: 16px; height: 16px; stroke-width: 1.5; color: #4B5058; }
.pp-actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 14px 0 16px; }
.pbtn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 44px; border-radius: 999px; background: #fff; box-shadow: 0 2px 6px rgba(20,30,45,.14); font-weight: 600; font-size: 13.5px; color: #4B5058; transition: transform .12s, background .15s; white-space: nowrap; }
.pbtn:active { transform: scale(.96); }
.pbtn.primary { background: var(--accent); color: #fff; }
.pbtn.primary .ic { width: 18px; height: 18px; fill: #fff; }
.pb-ic { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; color: #fff; }
.pb-ic .ic { width: 14px; height: 14px; stroke-width: 2.6; }
.pb-ic.chat { background: none; color: #4E9AD6; }
.pb-ic.chat .ic { width: 22px; height: 22px; fill: #4E9AD6; stroke: #4E9AD6; stroke-width: 1.4; }
.pb-ic.chat .ic path + path, .pb-ic.chat .ic path ~ path { stroke: #fff; stroke-width: 2.6; }
.pb-ic.add { background: #4E9AD6; }
.pbtn.done { background: #E5F3EA; color: #1E6B40; box-shadow: none; }
.pbtn.done .pb-ic.add { background: #2E8B57; }
.pp-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 18px; }
.pc { border-radius: var(--r-lg); padding: 10px 12px 14px; }
.pc-blue { background: #E8F0FB; } .pc-lila { background: #F1EDF9; }
.pc-ic { width: 28px; height: 28px; margin-bottom: 8px; }
.pc h3 { font-size: 13.5px; font-weight: 700; line-height: 1.2; margin-bottom: 6px; }
.pc p { font-size: 12px; line-height: 1.3; color: #1F2329; }
.pp-team { padding: 12px 14px 14px; margin-bottom: 18px; box-shadow: 0 2px 8px rgba(20,30,45,.12); }
.pp-team .sobre-h h3 { font-size: 17px; }
.persona .sobre-h { padding: 0 2px; }
.persona .rec { margin-bottom: 10px; box-shadow: 0 2px 8px rgba(20,30,45,.12); }

/* ---------- Cumpleaños ---------- */
.list-card { background: #fff; border-radius: var(--r); box-shadow: var(--shadow); padding: 4px 14px; }
.row { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.row:last-child { border-bottom: 0; }
.row-main { flex: 1; min-width: 0; display: flex; align-items: center; gap: 12px; }
.row-main div { display: flex; flex-direction: column; min-width: 0; }
.row-main b { font-size: 15px; }
.row-main span { font-size: 12.5px; color: var(--muted); }

/* ---------- Sheet / drawer / toast ---------- */
.overlay { position: fixed; inset: 0; bottom: var(--kb, 0px); z-index: 60; background: rgba(15, 22, 32, 0); transition: background .22s; display: flex; align-items: flex-end; justify-content: center; }
.overlay.open { background: rgba(15, 22, 32, .42); }
.sheet { width: 100%; max-width: var(--maxw); max-height: calc(88vh - var(--kb, 0px)); max-height: calc(88dvh - var(--kb, 0px)); overflow: auto; background: #fff; border-radius: 22px 22px 0 0; padding: 8px 18px calc(18px + var(--sb)); transform: translateY(100%); transition: transform .26s cubic-bezier(.2,.8,.2,1); display: flex; flex-direction: column; gap: 12px; overscroll-behavior: contain; }
.overlay.open .sheet { transform: none; }
:root[style*="--kb"]:not([style*="--kb: 0px"]) .sheet { padding-bottom: 14px; }
.grab { width: 40px; height: 5px; border-radius: 3px; background: #DADDE2; margin: 0 auto 2px; flex: none; }
.sheet-h { display: flex; align-items: center; justify-content: space-between; }
.sheet-h h2 { font-size: 19px; font-weight: 700; }
.sheet textarea { width: 100%; border: 1.5px solid var(--line); border-radius: 14px; padding: 12px; font-size: 16px; resize: none; outline: none; }
.sheet textarea:focus { border-color: var(--brand); }
.sheet form { display: flex; flex-direction: column; gap: 12px; }
.notifs { list-style: none; margin: 0; padding: 0; }
.notifs li { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.notifs li:last-child { border: 0; }
.n-ic { width: 40px; height: 40px; flex: none; border-radius: 50%; background: var(--brand-soft); color: var(--brand-ink); display: grid; place-items: center; }
.n-ic .ic { width: 20px; height: 20px; }
.notifs small { color: var(--muted); font-size: 12px; }
.valores { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.valor { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; padding: 12px; border-radius: 14px; background: #F5F7FA; border: 2px solid transparent; text-align: left; min-height: 88px; transition: border-color .15s, background .15s; }
.valor .ic { width: 22px; height: 22px; color: var(--accent); }
.valor b { font-size: 14.5px; }
.valor small { font-size: 12px; color: var(--muted); line-height: 1.25; }
.valor.on { border-color: var(--accent); background: #EEF3FC; }
.toggles { display: flex; flex-direction: column; }
.toggle { display: flex; align-items: center; justify-content: space-between; min-height: 52px; border-bottom: 1px solid var(--line); font-size: 15px; cursor: pointer; }
.toggle input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.toggle i { width: 48px; height: 28px; border-radius: 999px; background: #D5D9DF; position: relative; transition: background .2s; flex: none; }
.toggle i::after { content: ''; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: transform .2s; }
.toggle input:checked + i { background: var(--brand); }
.toggle input:checked + i::after { transform: translateX(20px); }
.toggle input:focus-visible + i { outline: 3px solid var(--brand); outline-offset: 2px; }
.fine { text-align: center; font-size: 12px; color: var(--muted); }

.drawer-ov { position: fixed; inset: 0; z-index: 50; background: rgba(15,22,32,.4); opacity: 0; pointer-events: none; transition: opacity .22s; }
.drawer-ov.open { opacity: 1; pointer-events: auto; }
.drawer { position: fixed; top: 0; bottom: 0; z-index: 55; width: min(300px, 82vw); left: max(0px, calc(50vw - var(--maxw) / 2)); background: #fff; transform: translateX(-105%); visibility: hidden; transition: transform .26s cubic-bezier(.2,.8,.2,1), visibility 0s .26s; display: flex; flex-direction: column; padding: calc(var(--st) + 18px) 0 calc(var(--sb) + 16px); box-shadow: var(--shadow-lg); }
.drawer.open { transform: none; visibility: visible; transition: transform .26s cubic-bezier(.2,.8,.2,1); }
.dr-head { display: flex; align-items: center; gap: 12px; padding: 0 20px 18px; border-bottom: 1px solid var(--line); }
.dr-head div { display: flex; flex-direction: column; }
.dr-head b { font-size: 15px; }
.dr-head span { font-size: 12px; color: var(--muted); }
.dr-nav { display: flex; flex-direction: column; padding: 10px 8px; }
.dr-nav a, .dr-nav button { display: flex; align-items: center; gap: 14px; min-height: 50px; padding: 0 14px; border-radius: 12px; font-size: 15.5px; font-weight: 500; text-align: left; }
.dr-nav a:active, .dr-nav button:active { background: var(--brand-soft); }
.dr-nav .ic { width: 22px; height: 22px; color: var(--brand-ink); }
.dr-nav button { color: #B4232A; margin-top: 8px; border-top: 1px solid var(--line); border-radius: 0 0 12px 12px; }
.dr-nav button .ic { color: #B4232A; }
.dr-foot { margin-top: auto; padding: 0 20px; font-size: 12px; color: var(--muted); }

.toast { position: fixed; left: 50%; bottom: calc(var(--tabh) + var(--sb) + 14px); transform: translate(-50%, 20px); z-index: 80; background: #1D232B; color: #fff; padding: 12px 18px; border-radius: 14px; font-size: 14px; font-weight: 500; max-width: min(400px, calc(100vw - 32px)); width: max-content; text-align: center; opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; box-shadow: var(--shadow-lg); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Bienvenida ---------- */
.welcome { position: fixed; inset: 0; z-index: 100; display: flex; justify-content: center; background: #E7EAEE; transition: opacity .3s; }
.welcome.out { opacity: 0; }
.w-in { width: 100%; max-width: var(--maxw); height: 100%; background: linear-gradient(180deg, #FFFFFF 0%, #EAF3F8 60%, #D6E8F1 100%); display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: calc(var(--st) + 24px) 28px calc(var(--sb) + 24px); gap: 14px; }
.w-logo { width: 132px; height: 132px; margin-bottom: 8px; animation: wlogo .6s cubic-bezier(.2,.8,.2,1); }
@keyframes wlogo { from { transform: scale(.85); opacity: 0; } }
.welcome h1 { font-size: 26px; font-weight: 700; line-height: 1.2; }
.welcome h1 span { display: inline-block; font-weight: 800; color: var(--brand-ink); font-size: 30px; letter-spacing: .02em; }
.w-sub { color: var(--muted); font-size: 15px; margin-bottom: 18px; }
.welcome .btn { gap: 10px; padding: 0 22px 0 8px; width: 100%; max-width: 320px; min-height: 56px; }
.w-hint { display: flex; gap: 8px; align-items: flex-start; text-align: left; font-size: 12.5px; color: #5A6069; margin-top: 18px; max-width: 320px; line-height: 1.4; }
.w-hint .ic { width: 18px; height: 18px; color: var(--brand-ink); margin-top: 1px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
@media (max-width: 370px) {
  .hb-txt h2 { font-size: 18px; }
  .news-item { grid-template-columns: 96px 1fr 36px; gap: 10px; }
  .news-item img { width: 96px; height: 72px; }
  .ev { grid-template-columns: 108px 1fr; padding-right: 44px; }
  .ev-img { width: 108px; }
  .pbtn { font-size: 12.5px; gap: 4px; }
  .pp-head .av { --s: 104px !important; }
  .chip { padding: 0 14px; }
  .crow-main b { font-size: 15.5px; }
  .btn-conn { padding: 0 10px; }
  .rx { padding: 0 5px; gap: 5px; }
  .pill-link { padding: 0 10px; font-size: 13px; }
  .bd-txt { max-width: 68%; }
}

/* Pantallas angostas: el composer prioriza el texto sobre el botón de mención */
@media (max-width: 380px) { #compAt { display: none; } }
