:root{
  --violet-950:#1d0b43;--violet-900:#2b105f;--violet-800:#3d1682;--violet-700:#5c25bb;
  --violet-600:#7138db;--blue:#2f6fec;--cyan:#31c7e8;--ink:#191428;--muted:#716b80;
  --line:#ebe7f2;--surface:#fff;--soft:#f6f3fb;--success:#1abb82;
  --shadow:0 28px 80px rgba(24,10,57,.22);--safe-bottom:env(safe-area-inset-bottom,0px)
}
*{box-sizing:border-box}html{height:100%;background:#170a35}body{min-height:100%;margin:0;font-family:Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:var(--ink);background:linear-gradient(135deg,#1b0a3d,#351176 55%,#173d80);overflow-x:hidden}
button,input{font:inherit}.background-grid{position:fixed;inset:0;pointer-events:none;opacity:.13;background-image:linear-gradient(rgba(255,255,255,.18) 1px,transparent 1px),linear-gradient(90deg,rgba(255,255,255,.18) 1px,transparent 1px);background-size:42px 42px;mask-image:linear-gradient(to bottom,black,transparent 75%)}
.glow{position:fixed;border-radius:50%;filter:blur(90px);pointer-events:none;opacity:.35}.glow-a{width:420px;height:420px;background:#8957ff;top:-180px;left:20%}.glow-b{width:380px;height:380px;background:#18bde8;right:-150px;bottom:-170px}
.app-shell{position:relative;z-index:1;width:min(1440px,100%);height:100vh;min-height:0;margin:auto;padding:26px;display:grid;grid-template-columns:minmax(310px,390px) minmax(0,1fr);gap:22px}
.showcase{min-height:calc(100vh - 52px);padding:34px;display:flex;flex-direction:column;justify-content:space-between;color:#fff;border:1px solid rgba(255,255,255,.13);border-radius:32px;background:linear-gradient(155deg,rgba(255,255,255,.15),rgba(255,255,255,.055));box-shadow:inset 0 1px 0 rgba(255,255,255,.12);backdrop-filter:blur(22px);overflow:hidden;position:relative}
.showcase:after{content:"";position:absolute;width:260px;height:260px;border:1px solid rgba(255,255,255,.08);border-radius:50%;right:-130px;top:27%;box-shadow:0 0 0 34px rgba(255,255,255,.025),0 0 0 68px rgba(255,255,255,.02)}
.logo-lockup{display:flex;align-items:center;gap:15px}.logo-mark{width:64px;height:64px;display:grid;place-items:center;color:#fff;border-radius:21px;background:linear-gradient(145deg,#8e5cff,#3e8cff);box-shadow:0 16px 34px rgba(8,4,30,.3),inset 0 1px 0 rgba(255,255,255,.35)}.logo-mark svg{width:45px;height:45px}.eyebrow{display:block;font-size:9px;font-weight:800;letter-spacing:.22em;color:#cfc0ff;margin-bottom:5px}.logo-lockup h1{font-size:24px;line-height:1.05;margin:0;font-weight:600;letter-spacing:-.04em}.logo-lockup h1 strong{display:block;font-size:31px;font-weight:900;background:linear-gradient(90deg,#fff,#98eaff);background-clip:text;-webkit-background-clip:text;color:transparent}
.hero-copy{margin-top:64px;position:relative;z-index:1}.hero-badge{width:max-content;display:flex;align-items:center;gap:8px;padding:8px 12px;border:1px solid rgba(255,255,255,.16);border-radius:999px;background:rgba(255,255,255,.08);font-size:10px;font-weight:800;letter-spacing:.12em}.hero-badge i{width:7px;height:7px;border-radius:50%;background:#50f0b0;box-shadow:0 0 0 5px rgba(80,240,176,.12)}.hero-copy h2{font-size:clamp(30px,3.1vw,47px);line-height:1.03;letter-spacing:-.055em;margin:24px 0 18px;max-width:330px}.hero-copy p{color:#d9d0ef;line-height:1.7;font-size:14px;margin:0;max-width:325px}
.feature-list{display:grid;gap:10px;position:relative;z-index:1;margin:40px 0}.feature{display:flex;align-items:center;gap:13px;padding:13px;border:1px solid rgba(255,255,255,.1);border-radius:17px;background:rgba(255,255,255,.06)}.feature-icon{width:38px;height:38px;display:grid;place-items:center;flex:0 0 auto;border-radius:12px;background:rgba(255,255,255,.12);font-size:10px;font-weight:900;color:#b9f5ff}.feature b,.feature small{display:block}.feature b{font-size:12px;margin-bottom:3px}.feature small{font-size:10px;color:#c9bddf}.showcase-footer{display:flex;align-items:center;gap:8px;font-size:10px;color:#cbbfe0}.status-dot{width:8px;height:8px;border-radius:50%;background:#42e9a4;box-shadow:0 0 0 6px rgba(66,233,164,.1)}
.workspace{min-width:0;height:calc(100vh - 52px);min-height:0;padding:0 4px;display:flex;flex-direction:column;overflow:hidden}.topbar{height:72px;display:flex;align-items:center;justify-content:space-between;padding:0 4px;color:#fff}.assistant-heading{display:flex;align-items:center;gap:12px}.assistant-avatar{position:relative;width:46px;height:46px;display:grid;place-items:center;border-radius:16px;background:linear-gradient(145deg,#8a56f0,#3175eb);font-weight:900;box-shadow:0 10px 25px rgba(20,6,55,.25)}.assistant-avatar span{position:absolute;right:-1px;bottom:-1px;width:13px;height:13px;border:3px solid #361375;border-radius:50%;background:#29df98}.assistant-heading b,.assistant-heading span,.mobile-brand b,.mobile-brand span{display:block}.assistant-heading b{font-size:14px}.assistant-heading>div>span{font-size:10px;color:#d6cae9;margin-top:3px}.restart-btn{display:flex;align-items:center;gap:8px;height:42px;padding:0 14px;border:1px solid rgba(255,255,255,.16);border-radius:14px;color:#fff;background:rgba(255,255,255,.09);cursor:pointer;transition:.2s;backdrop-filter:blur(10px)}.restart-btn:hover{background:rgba(255,255,255,.16);transform:translateY(-1px)}.restart-btn svg{width:18px}.restart-btn span{font-size:11px;font-weight:700}.mobile-brand{display:none}
.chat-card{flex:1;min-height:0;max-height:100%;display:flex;flex-direction:column;background:rgba(255,255,255,.98);border:1px solid rgba(255,255,255,.72);border-radius:30px;box-shadow:var(--shadow);overflow:hidden}.chat{flex:1;min-height:0;padding:32px 34px;overflow-y:auto;overscroll-behavior:contain;display:flex;flex-direction:column;gap:16px;scroll-behavior:smooth;background:radial-gradient(circle at 90% 0,rgba(108,64,211,.06),transparent 30%),linear-gradient(#fff,#fdfcff)}.chat::-webkit-scrollbar{width:8px}.chat::-webkit-scrollbar-thumb{background:#dcd5e8;border-radius:99px;border:2px solid #fff}
.row{display:flex;gap:11px;align-items:flex-end;animation:rise .28s ease}.row.user{justify-content:flex-end}.avatar{width:34px;height:34px;flex:0 0 34px;border-radius:12px;display:grid;place-items:center;font-size:10px;font-weight:900;letter-spacing:.03em;color:#fff;background:linear-gradient(145deg,var(--violet-700),var(--blue));box-shadow:0 7px 18px rgba(82,35,173,.22)}.bubble{max-width:min(670px,82%);padding:15px 17px;border-radius:20px;line-height:1.58;font-size:13px;box-shadow:0 6px 20px rgba(31,17,59,.055)}.bot .bubble{background:var(--soft);border:1px solid #eee9f6;border-bottom-left-radius:6px}.user .bubble{color:#fff;background:linear-gradient(135deg,var(--violet-800),var(--violet-600) 55%,var(--blue));border-bottom-right-radius:6px;box-shadow:0 10px 25px rgba(75,29,164,.2)}.bubble strong{font-weight:800}.factor-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:11px;margin-top:15px}.factor{position:relative;overflow:hidden;background:#fff;border:1px solid #e7e0f1;padding:16px;border-radius:17px;box-shadow:0 8px 20px rgba(37,19,71,.05)}.factor:after{content:"";position:absolute;inset:auto -18px -30px auto;width:75px;height:75px;border-radius:50%;background:rgba(100,48,202,.07)}.factor span{display:block;color:var(--muted);font-size:9px;font-weight:800;text-transform:uppercase;letter-spacing:.14em}.factor b{display:block;margin-top:5px;font-size:27px;color:var(--violet-700);letter-spacing:-.04em}
.quick-actions{display:flex;gap:9px;flex-wrap:wrap;padding:14px 28px 2px;background:#fff}.quick-actions:empty{display:none}.chip{min-height:42px;border:1px solid #d9cbed;background:#faf8fd;color:var(--violet-700);border-radius:13px;padding:10px 15px;font:700 11px Inter;cursor:pointer;transition:.18s}.chip:hover{transform:translateY(-2px);border-color:#a98ada;background:#f1eafb;box-shadow:0 8px 18px rgba(71,35,137,.1)}
.composer{display:flex;gap:10px;padding:18px 20px calc(18px + var(--safe-bottom));border-top:1px solid var(--line);background:#fff}.input-wrap{flex:1;min-width:0;height:52px;display:flex;align-items:center;gap:11px;padding:0 15px;border:1px solid #ded8e8;border-radius:16px;background:#fbfafd;transition:.2s}.input-wrap:focus-within{border-color:#8e68cf;box-shadow:0 0 0 4px rgba(112,52,202,.09);background:#fff}.input-wrap svg{width:18px;color:#9a8baa;flex:0 0 auto}.composer input{width:100%;min-width:0;border:0;outline:0;background:transparent;color:var(--ink);font-size:13px;font-weight:500}.composer input::placeholder{color:#aaa0b4}.composer button{height:52px;display:flex;align-items:center;justify-content:center;gap:8px;border:0;border-radius:16px;padding:0 21px;background:linear-gradient(135deg,var(--violet-800),var(--violet-600),var(--blue));color:#fff;font-size:12px;font-weight:800;cursor:pointer;box-shadow:0 11px 24px rgba(79,31,174,.22);transition:.18s}.composer button:hover{transform:translateY(-1px);box-shadow:0 14px 28px rgba(79,31,174,.28)}.composer button svg{width:18px}.composer button:disabled,.composer input:disabled{opacity:.55;cursor:not-allowed}.typing{display:flex;gap:5px}.typing i{width:7px;height:7px;background:#8d83a1;border-radius:50%;animation:dot 1s infinite}.typing i:nth-child(2){animation-delay:.15s}.typing i:nth-child(3){animation-delay:.3s}.legal-note{min-height:40px;display:flex;align-items:center;justify-content:center;gap:7px;color:#d8cce9;font-size:9px;text-align:center;padding:9px}.legal-note svg{width:14px;flex:0 0 auto}
@keyframes dot{0%,60%,100%{transform:translateY(0);opacity:.45}30%{transform:translateY(-4px);opacity:1}}@keyframes rise{from{opacity:0;transform:translateY(7px)}to{opacity:1;transform:none}}
@media(max-width:980px){.app-shell{grid-template-columns:280px minmax(0,1fr);padding:16px;gap:15px}.showcase{min-height:calc(100vh - 32px);padding:25px}.hero-copy h2{font-size:34px}.feature-list{margin:26px 0}.feature{padding:10px}.workspace{height:calc(100vh - 32px);min-height:0}}
@media(max-width:760px){html,body{height:100%;overflow:hidden}.background-grid{opacity:.08}.app-shell{height:100dvh;min-height:100dvh;padding:0;display:block}.showcase{display:none}.workspace{height:100dvh;min-height:0;padding:0;background:linear-gradient(135deg,#251050,#4b1d91 55%,#23539d)}.topbar{height:68px;padding:8px 13px;flex:0 0 auto}.assistant-heading{display:none}.mobile-brand{display:flex;align-items:center;gap:10px}.mobile-mark{width:42px;height:42px;display:grid;place-items:center;border-radius:14px;background:linear-gradient(145deg,#a371ff,#3c8fff);font-size:12px;font-weight:900;box-shadow:0 8px 20px rgba(12,4,40,.24)}.mobile-brand b{font-size:13px}.mobile-brand span{font-size:9px;color:#d8ccec;margin-top:2px}.restart-btn{width:42px;height:42px;padding:0;justify-content:center}.restart-btn span{display:none}.chat-card{height:calc(100dvh - 68px);min-height:0;border:0;border-radius:24px 24px 0 0;box-shadow:0 -10px 40px rgba(18,4,48,.18)}.chat{min-height:0;padding:19px 13px 14px;gap:13px}.bubble{max-width:88%;padding:13px 14px;font-size:12.5px;line-height:1.52}.avatar{width:30px;height:30px;flex-basis:30px;border-radius:10px;font-size:9px}.quick-actions{padding:10px 12px 2px;gap:7px;max-height:145px;overflow-y:auto}.chip{flex:1 1 auto;min-height:42px;padding:9px 12px;font-size:10.5px}.composer{padding:12px 11px calc(11px + var(--safe-bottom));gap:8px}.input-wrap{height:49px;border-radius:15px;padding:0 12px}.composer input{font-size:16px}.composer button{width:49px;height:49px;padding:0;border-radius:15px}.composer button span{display:none}.composer button svg{width:19px}.factor-grid{gap:8px}.factor{padding:13px}.factor b{font-size:23px}.legal-note{display:none}}
@media(max-width:380px){.mobile-brand b{font-size:12px}.mobile-brand span{font-size:8px}.chat{padding-left:9px;padding-right:9px}.bubble{max-width:91%;font-size:12px}.quick-actions{padding-left:9px;padding-right:9px}.composer{padding-left:8px;padding-right:8px}.factor-grid{grid-template-columns:1fr}}
@media(orientation:landscape) and (max-height:560px) and (max-width:900px){.topbar{height:55px}.mobile-mark{width:36px;height:36px}.chat-card{height:calc(100dvh - 55px);border-radius:18px 18px 0 0}.chat{padding-top:12px}.composer{padding-top:8px;padding-bottom:calc(8px + var(--safe-bottom))}.input-wrap,.composer button{height:44px}.quick-actions{max-height:92px}}

/* Instalación PWA */
.topbar-actions{display:flex;align-items:center;gap:10px}
.install-app-btn{border:1px solid rgba(91,44,160,.18);background:#fff;color:#5b2ca0;border-radius:12px;padding:10px 14px;font-weight:800;display:inline-flex;align-items:center;gap:7px;cursor:pointer;box-shadow:0 6px 18px rgba(50,20,111,.08);transition:.18s ease}
.install-app-btn:hover{transform:translateY(-1px);box-shadow:0 9px 22px rgba(50,20,111,.13)}
.install-app-btn.ready{background:linear-gradient(135deg,#5b2ca0,#7c3aed);color:white;border-color:transparent}
@media(max-width:600px){.install-app-btn{padding:9px 10px}.install-app-btn span:last-child{display:none}.topbar-actions{gap:7px}}
