/* LilyAI brand theme — loaded last; overrides legacy blue/pink tokens */
html:root{
  --primary:#FF289D;--primary-600:#E0157F;--primary-50:#FFF0F7;--primary-100:#FFD6EB;
  --blue:#FF289D;
  --lily-grad:linear-gradient(135deg,#FF289D 0%,#FF289D 60%,#FF4FAF 100%);
  --lily-ink:#1F1B2E;--lily-shadow:0 10px 30px rgba(255,40,157,.14);
}
@media (max-width:767.98px){html:root{--primary:#FF289D;--primary-600:#E0157F;--primary-50:#FFF0F7;--primary-100:#FFD6EB}}
[data-theme="dark"]{--primary-50:#3A1E2E;--primary-100:#4A2238}
::selection{background:#FFD6EB}
.btn-primary,.btn.btn-primary{background:var(--lily-grad)!important;border-color:transparent!important;color:#fff!important;box-shadow:0 6px 18px rgba(255,40,157,.28)}
.btn-primary:hover{filter:brightness(1.05);transform:translateY(-1px)}
.btn-outline:hover{border-color:var(--primary)!important;color:var(--primary)!important}
a{accent-color:var(--primary)}
input:focus,textarea:focus,select:focus{outline-color:var(--primary)}
/* wordmark: "Lily" ink + "AI" gradient */
.entry-brand b,.brand,.hub-wordmark{color:var(--lily-ink)}
.entry-brand b span,.brand span,.hub-wordmark>span{background:var(--lily-grad);-webkit-background-clip:text;background-clip:text;color:transparent!important}
[data-theme="dark"] .entry-brand b,[data-theme="dark"] .brand,[data-theme="dark"] .hub-wordmark{color:#fff}
.brand-logo{border-radius:10px}

/* ---------- Landing (logged-out home) ---------- */
.entry-header{max-width:1200px;margin:0 auto;padding:20px 32px}
.entry-home{max-width:1200px;margin:0 auto;padding:24px 32px 40px}
.entry-hero{display:grid;grid-template-columns:1.05fr .95fr;gap:56px;align-items:center;min-height:min(72vh,640px)}
.entry-copy h1{font-size:clamp(40px,4.6vw,64px)!important;line-height:1.12!important;letter-spacing:-1.5px;font-weight:800;color:var(--lily-ink)}
.entry-copy h1 br+*,.entry-copy h1 em{background:var(--lily-grad);-webkit-background-clip:text;color:transparent}
.entry-copy>p:not(.entry-eyebrow):not(.entry-dl-label){font-size:18px!important;line-height:1.7;color:#5B5670;max-width:40em}
.entry-eyebrow{display:inline-block;background:var(--primary-50)!important;color:var(--primary)!important;border:1px solid var(--primary-100);font-weight:600}
.entry-copy .btn-row .btn{height:52px;padding:0 28px;font-size:16px;border-radius:999px}
.dl-row{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;max-width:520px}
.dl-btn{border-radius:14px!important;transition:border-color .15s,box-shadow .15s,transform .15s}
.dl-btn:hover{border-color:var(--primary-100)!important;box-shadow:var(--lily-shadow);transform:translateY(-1px)}
.entry-demo{position:relative}
.entry-demo:before{content:"";position:absolute;inset:-40px -30px;background:radial-gradient(closest-side,rgba(255,40,157,.18),transparent 70%),radial-gradient(closest-side at 80% 80%,rgba(255,79,175,.16),transparent 70%);z-index:-1;filter:blur(8px)}
.demo-card{border-radius:22px!important;box-shadow:0 20px 50px rgba(31,27,46,.10)!important;border:1px solid #F8E6EF!important}
.demo-me{background:var(--lily-grad)!important;color:#fff!important}
.demo-tip .btn,.demo-tip a,.demo-tip button{background:var(--lily-grad)!important;color:#fff!important}
.demo-stats b,.demo-stats strong{color:var(--lily-ink)}
.entry-features{display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr));gap:20px;margin-top:64px}
.entry-feature{border-radius:20px!important;padding:26px 22px!important;border:1px solid #F8E6EF!important;transition:box-shadow .2s,transform .2s,border-color .2s}
.entry-feature:hover{box-shadow:var(--lily-shadow);transform:translateY(-3px);border-color:var(--primary-100)!important}
.entry-feature h3,.entry-feature h2{font-size:18px!important;color:var(--lily-ink)}
.entry-feature p{font-size:14px!important;line-height:1.65;color:#6B6680}
.entry-feature svg,.entry-feature i,.entry-feature .ico,.entry-feature>span:first-child{color:var(--primary)!important}
.entry-feature>span:first-child,.entry-feature .ico{background:var(--primary-50)!important;border-color:var(--primary-100)!important}
.entry-footnote{margin-top:40px;color:#8A85A0}
@media (max-width:1023.98px){
  .entry-hero{grid-template-columns:1fr;gap:36px;min-height:0}
  .entry-features{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media (max-width:767.98px){
  .entry-header{padding:14px 18px}
  .entry-home{padding:8px 18px 32px}
  .entry-copy{text-align:left}
  .entry-copy h1{font-size:clamp(32px,9vw,40px)!important;letter-spacing:-.8px}
  .entry-copy>p:not(.entry-eyebrow):not(.entry-dl-label){font-size:15.5px!important}
  .entry-copy .btn-row{display:flex;flex-direction:column;gap:10px}
  .entry-copy .btn-row .btn{width:100%;justify-content:center}
  .dl-row{grid-template-columns:repeat(2,minmax(0,1fr));max-width:none}
  .entry-demo:before{inset:-20px -10px}
  .entry-features{grid-template-columns:1fr;gap:12px;margin-top:36px}
  .entry-feature{padding:18px!important;display:grid;grid-template-columns:44px 1fr;column-gap:14px;align-items:start}
  .entry-feature>*:not(:first-child){grid-column:2}
}


/* ---------- Logged-in app shell ---------- */
#nav{background:#FFF7FB!important}
[data-theme="dark"] #nav{background:#1E1B26!important}
.sb-conv{border-radius:16px!important;transition:background .15s}
.sb-conv:hover{background:rgba(255,40,157,.06)}
.sb-conv.active{background:#fff!important;box-shadow:0 4px 14px rgba(31,27,46,.07)}
[data-theme="dark"] .sb-conv.active{background:#2A2536!important}
.sb-foot{gap:10px!important}
.sb-searchbox{flex:1 1 auto!important;min-width:0!important;width:auto!important;max-width:none!important}
.sb-searchbox input{min-width:0;width:100%}
.ui-round:hover{color:var(--primary)}

/* chat */
.chatg-msgs .msg-row{width:100%;max-width:880px;margin-left:auto!important;margin-right:auto!important}
.msg-row .bubble{font-size:15.5px;line-height:1.72;border-radius:20px;padding:11px 16px;max-width:640px}
.msg-row.me .bubble{background:var(--lily-grad)!important;color:#fff!important;border-bottom-right-radius:6px;box-shadow:0 6px 16px rgba(255,40,157,.18)}
.msg-row.ai .bubble{background:#F3F1F8!important;color:var(--lily-ink);border-bottom-left-radius:6px}
[data-theme="dark"] .msg-row.ai .bubble{background:#2A2536!important;color:#ECEAF3}
.message-copy{opacity:0;transition:opacity .15s;font-size:12px}
.msg-col:hover .message-copy,.message-copy:focus-visible{opacity:.75}
@media (hover:none){.message-copy{opacity:.55}}
.chatg-inputbar{max-width:880px;margin-left:auto;margin-right:auto;box-shadow:0 8px 28px rgba(31,27,46,.08),0 0 0 1px #ECE8F6!important}
.chatg-inputbar:focus-within{box-shadow:0 8px 28px rgba(255,40,157,.16),0 0 0 2px rgba(255,40,157,.35)!important}
.composer-dock{background:linear-gradient(rgba(252,252,252,0),var(--bg,#fcfcfc) 38%)!important}
.chat-model{border-radius:999px!important;padding:0 14px!important;white-space:nowrap}
.chat-model:hover{color:var(--primary);border-color:var(--primary-100)}

/* display-size launcher: keep it out of the way */
#display-controls{opacity:.55;transition:opacity .15s}
#display-controls:hover,#display-controls:focus-within{opacity:1}
@media (max-width:767.98px){
  #display-controls{top:auto!important;bottom:calc(150px + env(safe-area-inset-bottom))!important;right:6px!important}
  .display-launcher{transform:scale(.82);transform-origin:right bottom}
  .msg-row .bubble{max-width:84%;font-size:15px}
  .chatg-msgs{padding-left:12px!important;padding-right:12px!important}
  .chat-model{max-width:132px;overflow:hidden;text-overflow:ellipsis}
  .sb-foot{padding-left:14px!important;padding-right:14px!important}
}

@media (max-width:767.98px){
  .msg-row .bubble{max-width:100%!important}
  .chatg-head .chat-model,.chat-toolbar .chat-model{max-width:none!important;width:auto!important;font-size:13px;padding:0 12px!important}
}

/* hide 经营 entry when the whole business section is off in admin */
body.lily-no-biz #sb-biz{display:none!important}

/* 2026-11-08 brand red #FF289D */
html:root{--brand:#FF289D;--accent:#FF289D}
.msg-row.me .bubble{background:#FF289D!important}
