/*
 * Modal de Vetlify: porte a CSS puro de VetlifyCarta y NotificacionesNoche
 * (C:\motion-architect-main\web, React + Framer Motion). Mismos estilos; las
 * animaciones de Framer se reemplazan por keyframes que corren con el modal abierto
 * (.am.is-open) y por assets/vetlify-modal.js.
 */
@font-face { font-family: "Armin Grotesk"; font-weight: 400; src: url("vetlify/ArminGrotesk-Regular.woff2") format("woff2"); font-display: swap; }
@font-face { font-family: "Armin Grotesk"; font-weight: 600; src: url("vetlify/ArminGrotesk-SemiBold.woff2") format("woff2"); font-display: swap; }
@font-face { font-family: "Armin Grotesk"; font-weight: 800; src: url("vetlify/ArminGrotesk-UltraBold.woff2") format("woff2"); font-display: swap; }

#vet-modal .vc-carta {
  --noche: #0c1a3d; --azul: #3459c7; --primario: #4661e8; --celeste: #7cb1ff; --marcador: #ffd643;
  border: 1px solid rgba(124, 177, 255, 0.22);
  background:
    radial-gradient(900px 500px at 50% 55%, rgba(70, 97, 232, 0.28), transparent 70%),
    radial-gradient(600px 400px at 85% 10%, rgba(124, 177, 255, 0.12), transparent 70%),
    linear-gradient(180deg, #0f1f4a 0%, var(--noche) 60%, #081230 100%);
  color: #fff; font-family: "Armin Grotesk", system-ui, sans-serif;
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.55);
}
#vet-modal .vc-carta h2, #vet-modal .vc-carta h3, #vet-modal .vc-carta p { font-family: inherit; }
.vc-particulas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }
.vc-cerrar { color: #fff; background: rgba(255, 255, 255, 0.06); border: 1px solid rgba(255, 255, 255, 0.25); }
.vc-logo { position: absolute; top: 26px; left: 28px; height: 30px; opacity: 0.95; z-index: 2; }

/* ---------- Bloque 1: NotificacionesNoche (problema → giro) ---------- */
.nn-seccion { position: relative; color: #fff; padding: 72px 0 24px; }
.nn-sticky { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 56px; max-width: 1040px; margin: 0 auto; padding: 0 40px; box-sizing: border-box; }
.nn-textos { position: relative; min-height: 260px; }
.nn-texto { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: center; transition: opacity .35s ease; }
.nn-eyebrow { margin: 0 0 14px; font: 600 13px ui-monospace, monospace; letter-spacing: 0.14em; color: #7cb1ff; }
.nn-texto h2 { margin: 0; font-weight: 800; font-size: clamp(30px, 3.6vw, 48px); line-height: 1.08; letter-spacing: -0.02em; }
.nn-mano { display: block; font-family: "Caveat", cursive; font-weight: 600; color: #7cb1ff; font-size: 1.15em; letter-spacing: 0; margin-top: 6px; }
.nn-sub { margin: 18px 0 0; max-width: 460px; font-size: 18px; line-height: 1.45; color: rgba(255, 255, 255, 0.72); }
.nn-telefono {
  position: relative; width: 320px; height: 640px; border-radius: 48px; overflow: hidden; isolation: isolate;
  background: radial-gradient(420px 360px at 50% 22%, #3a1218, #120609 70%);
  border: 10px solid #1d2233; box-shadow: 0 40px 100px rgba(0, 0, 0, 0.6), 0 0 0 2px #2c3247;
}
.nn-fondo-azul { position: absolute; inset: 0; z-index: -1; opacity: 0; background: radial-gradient(420px 360px at 50% 22%, #1f3d8f, #0a1636 70%); }
.nn-isla { position: absolute; top: 12px; left: 50%; transform: translateX(-50%); width: 110px; height: 32px; border-radius: 99px; background: #05060a; }
.nn-barra { display: flex; justify-content: space-between; padding: 18px 28px 0; font-size: 14px; font-weight: 600; }
.nn-fecha { margin: 40px 0 0; text-align: center; color: rgba(255, 255, 255, 0.7); font-weight: 600; font-size: 16px; }
.nn-hora { margin: 0; text-align: center; font-weight: 800; font-size: 74px; line-height: 1.05; letter-spacing: -0.02em; }
.nn-valentina { display: flex; align-items: center; justify-content: center; gap: 10px; margin: 10px 0 0; font-size: 13px; color: #dbe7ff; opacity: 0; transform: scale(.6); }
.nn-valentina img { width: 34px; height: 34px; filter: drop-shadow(0 0 10px rgba(124, 177, 255, 0.8)); }
.nn-lista { list-style: none; margin: 14px 0 0; padding: 0 12px; display: flex; flex-direction: column; gap: 8px; }
.nn-noti { display: flex; gap: 10px; padding: 11px 13px; border-radius: 20px; background: rgba(44, 44, 74, 0.82); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border: 1px solid transparent; transition: background .4s, border-color .4s, box-shadow .4s; }
.nn-noti.nn-ok { background: rgba(12, 26, 61, 0.78); border-color: rgba(124, 177, 255, 0.7); box-shadow: 0 0 18px rgba(124, 177, 255, 0.3); }
.nn-noti svg { flex: none; margin-top: 2px; }
.nn-cuerpo { flex: 1; min-width: 0; }
.nn-fila { display: flex; justify-content: space-between; gap: 8px; font-size: 12px; }
.nn-app { color: rgba(255, 255, 255, 0.6); }
.nn-estado { color: #ff6b6b; display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.nn-noti.nn-ok .nn-estado { color: #a9c8ff; font-weight: 600; }
.nn-punto { width: 7px; height: 7px; border-radius: 99px; background: #ff5a5a; display: inline-block; }
.nn-noti.nn-ok .nn-punto { display: none; }
.nn-noti p { margin: 3px 0 0; font-size: 14px; line-height: 1.3; font-weight: 600; }

/* ---------- Bloque 2: VetlifyCarta ---------- */
.vc-cabeza { text-align: center; padding: 72px 24px 0; }
.vc-eyebrow { margin: 0; font: 600 13px/1 ui-monospace, monospace; letter-spacing: 0.14em; color: var(--celeste); }
.vc-cabeza h2 { margin: 14px 0 0; font-weight: 800; font-size: clamp(30px, 4vw, 48px); letter-spacing: -0.02em; line-height: 1.1; }
.vc-rotativo { display: block; height: 1.35em; overflow: hidden; margin-top: 2px; }
.vc-mano { display: inline-block; font-family: "Caveat", cursive; font-weight: 600; color: var(--celeste); font-size: 1.25em; line-height: 1.1; position: relative;
  transition: opacity .45s cubic-bezier(.22,1,.36,1), transform .45s cubic-bezier(.22,1,.36,1), filter .45s cubic-bezier(.22,1,.36,1); }
.vc-mano.is-out { opacity: 0; transform: translateY(-60%); filter: blur(8px); }
.vc-mano.is-in { opacity: 0; transform: translateY(60%); filter: blur(8px); transition: none; }
.vc-sub { max-width: 620px; margin: 12px auto 0; color: rgba(255, 255, 255, 0.72); font-size: 17px; line-height: 1.45; }

.vc-escena { position: relative; height: 540px; display: grid; place-items: center; }
.vc-nucleo { position: relative; width: 170px; height: 170px; display: grid; place-items: center; }
.vc-nucleo-etiqueta { position: absolute; top: -26px; font: 500 12px ui-monospace, monospace; color: rgba(169, 200, 255, 0.8); letter-spacing: 0.05em; }
.vc-halo { position: absolute; inset: -110px; border-radius: 50%; background: radial-gradient(circle, rgba(124, 177, 255, 0.5), rgba(70, 97, 232, 0.2) 45%, transparent 70%); filter: blur(18px); opacity: .7; pointer-events: none; }
.vc-disco { position: relative; width: 150px; height: 150px; border-radius: 50%; display: grid; place-items: center;
  background: radial-gradient(circle at 40% 30%, #1b2f6e, #0a1636 70%); border: 2px solid rgba(124, 177, 255, 0.55);
  box-shadow: 0 0 0 10px rgba(70, 97, 232, 0.12), 0 0 50px rgba(124, 177, 255, 0.45), inset 0 0 30px rgba(124, 177, 255, 0.18); }
.vc-isotipo { width: 92px; height: 95px; background: linear-gradient(160deg, #ffffff, #a9c8ff);
  -webkit-mask: url("vetlify/isotipo-blanco.svg") center / contain no-repeat; mask: url("vetlify/isotipo-blanco.svg") center / contain no-repeat;
  filter: drop-shadow(0 0 10px rgba(124, 177, 255, 0.6)); }
/* Valentina: esfera fija superpuesta al disco del isotipo */
.vc-valentina { position: absolute; right: -22px; bottom: -14px; z-index: 2; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.vc-valentina img { width: 64px; height: 64px; filter: drop-shadow(0 0 14px rgba(124, 177, 255, 0.75)) drop-shadow(0 6px 14px rgba(0, 0, 0, 0.45)); }
.vc-valentina span { font: 600 11px ui-monospace, monospace; color: #dbe7ff; white-space: nowrap; padding: 2px 8px; border-radius: 99px; background: rgba(12, 26, 61, 0.85); border: 1px solid rgba(124, 177, 255, 0.4); }
#vet-modal.is-open .vc-valentina { animation: vc-pop .6s 1.1s cubic-bezier(.34,1.56,.64,1) both; }
#vet-modal.is-open .vc-valentina img { animation: vc-respira 3.2s 1.7s ease-in-out infinite; }
.vc-tarjeta { position: absolute; width: 290px; padding: 16px; border-radius: 18px; background: rgba(12, 26, 61, 0.55); border: 1px solid rgba(124, 177, 255, 0.35);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); box-shadow: 0 0 30px rgba(124, 177, 255, 0.15), inset 0 0 24px rgba(124, 177, 255, 0.05);
  transition: transform .3s ease, border-color .3s ease; }
.vc-tarjeta:hover { transform: translateY(-4px); border-color: rgba(124, 177, 255, .85); }
.vc-flota { display: flex; gap: 14px; align-items: flex-start; }
.vc-icono { flex: none; width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; color: var(--celeste); background: rgba(70, 97, 232, 0.25); border: 1px solid rgba(124, 177, 255, 0.35); }
.vc-tarjeta h3 { margin: 2px 0 4px; font-size: 17px; font-weight: 600; }
.vc-tarjeta p { margin: 0; font-size: 14px; line-height: 1.4; color: rgba(255, 255, 255, 0.7); }
.vc-arriba-izq { top: 40px; left: 10%; } .vc-arriba-der { top: 24px; right: 10%; }
.vc-abajo-izq { bottom: 16px; left: 5%; } .vc-abajo-der { bottom: 34px; right: 5%; }
.vc-modulos { position: absolute; top: calc(50% + 128px); display: flex; gap: 8px; list-style: none; margin: 0; padding: 0; flex-wrap: wrap; justify-content: center; }
.vc-modulos li { font: 600 12px ui-monospace, monospace; padding: 6px 12px; border-radius: 99px; color: #dbe7ff; background: rgba(12, 26, 61, 0.7); border: 1px solid rgba(124, 177, 255, 0.4); }
.vc-pie { display: flex; justify-content: space-between; align-items: center; gap: 24px; padding: 22px 28px 26px; border-top: 1px solid rgba(124, 177, 255, 0.15); background: rgba(8, 18, 48, 0.55); }
.vc-flujo { margin: 0; font: 600 13px ui-monospace, monospace; color: #dbe7ff; }
.vc-flujo em { font-style: normal; color: var(--celeste); }
.vc-sep { color: rgba(255, 255, 255, 0.4); }
.vc-nota { margin: 8px 0 0; font-size: 13px; color: rgba(255, 255, 255, 0.55); }
.vc-botones { display: flex; gap: 10px; flex: none; }
.vc-btn { padding: 12px 20px; border-radius: 99px; font-weight: 600; font-size: 15px; text-decoration: none; color: #fff; border: 1px solid rgba(255, 255, 255, 0.35); background: transparent; cursor: pointer; font-family: inherit; }
.vc-btn-claro { background: #fff; color: var(--noche); border-color: #fff; }
#vet-modal .vc-btn:focus-visible, #vet-modal .vc-cerrar:focus-visible { outline: 2px solid var(--marcador); outline-offset: 3px; }

/* ---------- Animaciones (equivalentes a las de Framer Motion) ---------- */
@keyframes vc-aparecer { from { opacity: 0; transform: translateY(24px); filter: blur(8px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes vc-pop { from { opacity: 0; transform: scale(.6); } 70% { transform: scale(1.04); } to { opacity: 1; transform: none; } }
@keyframes vc-tarjeta-in { from { opacity: 0; transform: scale(.9); filter: blur(10px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes vc-girar { to { transform: rotate(360deg); } }
@keyframes vc-girar-inv { to { transform: rotate(-360deg); } }
@keyframes vc-respira-halo { 0%,100% { transform: scale(1); opacity: .55; } 50% { transform: scale(1.08); opacity: .9; } }
@keyframes vc-respira { 0%,100% { transform: scale(1); } 50% { transform: scale(1.03); } }
@keyframes vc-flotar { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
@keyframes vc-fade { to { opacity: 1; } }

#vet-modal.is-open .vc-eyebrow, #vet-modal.is-open .vc-cabeza h2, #vet-modal.is-open .vc-sub, #vet-modal.is-open .vc-modulos li, #vet-modal.is-open .vc-pie { animation: vc-aparecer .7s cubic-bezier(.22,1,.36,1) both; }
#vet-modal.is-open .vc-eyebrow { animation-delay: .15s; } #vet-modal.is-open .vc-cabeza h2 { animation-delay: .27s; } #vet-modal.is-open .vc-sub { animation-delay: .39s; }
#vet-modal.is-open .vc-modulos li:nth-child(1) { animation-delay: .87s; } #vet-modal.is-open .vc-modulos li:nth-child(2) { animation-delay: .94s; }
#vet-modal.is-open .vc-modulos li:nth-child(3) { animation-delay: 1.02s; } #vet-modal.is-open .vc-modulos li:nth-child(4) { animation-delay: 1.09s; }
#vet-modal.is-open .vc-modulos li:nth-child(5) { animation-delay: 1.16s; } #vet-modal.is-open .vc-pie { animation-delay: 1.35s; }
#vet-modal.is-open .vc-nucleo { animation: vc-pop .7s .5s cubic-bezier(.34,1.56,.64,1) both; }
#vet-modal.is-open .vc-halo { animation: vc-respira-halo 3.2s ease-in-out infinite; }
#vet-modal.is-open .vc-isotipo { animation: vc-respira 3.2s ease-in-out infinite; }
#vet-modal.is-open .vc-tarjeta { animation: vc-tarjeta-in .6s cubic-bezier(.22,1,.36,1) both; }
#vet-modal.is-open .vc-tarjeta:nth-of-type(1) { animation-delay: .8s; } #vet-modal.is-open .vc-tarjeta:nth-of-type(2) { animation-delay: .95s; }
#vet-modal.is-open .vc-tarjeta:nth-of-type(3) { animation-delay: 1.1s; } #vet-modal.is-open .vc-tarjeta:nth-of-type(4) { animation-delay: 1.25s; }
#vet-modal.is-open .vc-flota { animation: vc-flotar 5s ease-in-out infinite; }
#vet-modal.is-open .vc-tarjeta:nth-of-type(2) .vc-flota { animation-duration: 6s; animation-delay: .4s; }
#vet-modal.is-open .vc-tarjeta:nth-of-type(3) .vc-flota { animation-duration: 7s; animation-delay: .8s; }
#vet-modal.is-open .vc-tarjeta:nth-of-type(4) .vc-flota { animation-duration: 8s; animation-delay: 1.2s; }

@media (max-width: 900px) {
  .nn-sticky { grid-template-columns: 1fr; gap: 16px; padding: 0 16px; justify-items: center; }
  .nn-textos { min-height: 200px; width: 100%; text-align: center; }
  .nn-texto { align-items: center; }
  .nn-texto h2 { font-size: 28px; }
  .nn-sub { font-size: 15px; margin-top: 10px; }
  .nn-telefono { width: 290px; height: 580px; border-radius: 44px; }
  .nn-hora { font-size: 60px; }
  .vc-escena { height: auto; display: flex; flex-direction: column; gap: 14px; padding: 40px 16px 24px; }
  .vc-logo { height: 24px; top: 22px; left: 22px; }
  .vc-nucleo { margin-bottom: 70px; }
  .vc-modulos { position: static; order: 1; margin-bottom: 10px; }
  .vc-tarjeta { position: static; width: 100%; max-width: 420px; order: 2; }
  .vc-pie { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  #vet-modal * { animation: none !important; transition: none !important; }
}

/* ---------- Módulos (bento inspirado en diarium.fi) ---------- */
.vm-modulos { padding: 24px 40px 56px; text-align: center; }
.vm-pill { display: inline-block; padding: 5px 12px; border-radius: 99px; background: #fff; color: #0c1a3d; font: 600 12px "Armin Grotesk", system-ui, sans-serif; }
.vm-titulo { margin: 14px auto 32px; max-width: 560px; font-weight: 600; font-size: clamp(26px, 3vw, 36px); line-height: 1.15; letter-spacing: -.01em; }
.vm-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; max-width: 980px; margin: 0 auto; text-align: left; }
.vm-card { grid-column: span 2; display: flex; flex-direction: column; gap: 6px; min-height: 260px; padding: 20px; border-radius: 22px; color: #0c1a3d;
  background: linear-gradient(180deg, #ffffff 0%, #eef2fb 100%); box-shadow: 0 10px 30px rgba(3, 10, 40, .25); transition: transform .3s ease, box-shadow .3s ease; }
.vm-card:hover { transform: translateY(-4px); box-shadow: 0 18px 40px rgba(3, 10, 40, .35); }
.vm-card h3 { margin: 0; font-size: 20px; font-weight: 600; letter-spacing: -.01em; }
.vm-card p { margin: 0; font-size: 13.5px; line-height: 1.4; color: #3b4a6b; }
.vm-card.is-ancha { grid-column: span 3; min-height: 140px; display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 16px; }
.vm-card.is-ancha > div:first-child { display: flex; flex-direction: column; gap: 6px; }
.vm-card.is-destacada { color: #fff; background: linear-gradient(160deg, #1b2f6e 0%, #3459c7 60%, #4661e8 100%); }
.vm-card.is-destacada p { color: rgba(255, 255, 255, .78); }
.vm-ilus { margin-top: auto; align-self: center; width: 100%; max-width: 230px; padding-top: 14px; }
.vm-card.is-ancha .vm-ilus { margin: 0; padding: 0; justify-self: end; }
/* piezas de las ilustraciones */
.vm-panel { border-radius: 14px; padding: 10px; background: #fff; box-shadow: 0 8px 24px rgba(52, 89, 199, .18); }
.vm-azul { background: linear-gradient(160deg, #c9d8ff, #9fb7ff); }
.vm-bar { display: block; height: 7px; border-radius: 4px; background: #dfe6f7; }
.vm-bar.is-oscura { background: #0c1a3d; } .vm-bar.is-azul { background: #4661e8; }
.vm-cal { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; }
.vm-cal i { height: 16px; border-radius: 4px; background: #eef2fb; }
.vm-cal i.on { background: #4661e8; } .vm-cal i.soft { background: #a9c3ff; }
.vm-ficha { display: flex; gap: 10px; align-items: center; }
.vm-ficha .vm-avatar { flex: none; width: 34px; height: 34px; border-radius: 50%; background: #dbe5ff; -webkit-mask: none; display: grid; place-items: center; }
.vm-ficha .vm-avatar span { width: 20px; height: 20px; background: #4661e8; -webkit-mask: url("vetlify/isotipo-blanco.svg") center / contain no-repeat; mask: url("vetlify/isotipo-blanco.svg") center / contain no-repeat; }
.vm-monitor { position: relative; height: 70px; border-radius: 14px; background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .25); overflow: hidden; }
.vm-monitor svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.vm-monitor path { stroke-dasharray: 260; stroke-dashoffset: 260; }
#vet-modal.is-open .vm-monitor path { animation: vm-trazo 3s linear infinite; }
@keyframes vm-trazo { to { stroke-dashoffset: 0; } }
.vm-chip { display: inline-block; margin-top: 8px; padding: 3px 9px; border-radius: 99px; font-size: 11px; font-weight: 600; background: rgba(255, 255, 255, .18); color: #fff; }
.vm-barras { display: flex; align-items: flex-end; gap: 6px; height: 60px; }
.vm-barras i { flex: 1; border-radius: 5px 5px 2px 2px; background: #a9c3ff; }
.vm-barras i.on { background: #4661e8; }
.vm-chat { display: flex; flex-direction: column; gap: 6px; }
.vm-burbuja { max-width: 85%; padding: 7px 10px; border-radius: 12px 12px 12px 3px; background: #eef2fb; font-size: 11.5px; color: #0c1a3d; }
.vm-burbuja.is-val { align-self: flex-end; border-radius: 12px 12px 3px 12px; background: #4661e8; color: #fff; display: flex; align-items: center; gap: 6px; }
.vm-burbuja.is-val img { width: 16px; height: 16px; }
@media (max-width: 900px) {
  .vm-modulos { padding: 16px 16px 40px; }
  .vm-grid { grid-template-columns: 1fr; }
  .vm-card, .vm-card.is-ancha { grid-column: auto; min-height: 0; grid-template-columns: 1fr; }
  .vm-card.is-ancha .vm-ilus { justify-self: center; }
}
