/* Lou's paper, type and illustration palette follow the reading experience. */
.chat-offer, .memory-page { color:var(--ink); overflow-wrap:anywhere; }
.chat-offer { display:grid; grid-template-columns:minmax(0,.94fr) minmax(0,1fr); align-items:center; gap:clamp(36px,6vw,86px); width:min(calc(100% - 48px),1040px); margin:clamp(56px,8vw,106px) auto; }
.chat-offer h1, .memory-head h1 { margin:0; font:700 clamp(3rem,6.3vw,5.2rem)/.99 var(--display); letter-spacing:-.055em; color:var(--ink); text-align:start; }
.chat-offer-intro { max-width:34ch; margin:20px 0 26px; color:var(--muted); font-size:clamp(1.05rem,2vw,1.2rem); line-height:1.55; }
.chat-offer-action { scroll-margin-top:90px; }
.chat-offer-action .button { min-height:50px; padding-inline:24px; border-radius:99px; }
.chat-offer-action p { margin:16px 0 0; font-size:.92rem; color:var(--muted); }
.chat-offer-action strong { color:var(--ink); }
.memory-legal { display:flex; align-items:center; flex-wrap:wrap; gap:0 18px; margin-top:7px; font-size:.83rem; }
.memory-legal a { display:inline-flex; align-items:center; min-height:36px; color:var(--muted); }
.chat-sample { position:relative; isolation:isolate; overflow:hidden; display:flex; flex-direction:column; align-items:flex-start; gap:17px; min-height:400px; margin:0; padding:24px 26px 74px; background:#ecdfef; border-radius:23px; border:1px solid #dfcde2; }
.chat-sample figcaption, .memory-author, .memory-compose-scope, .memory-option small { display:flex; align-items:center; gap:7px; }
.chat-sample figcaption { font-size:.81rem; font-weight:650; color:var(--prune); }
.chat-sample figcaption svg { width:16px; height:16px; }
.chat-sample-question, .memory-question { background:var(--prune); color:var(--surface); border-radius:17px 17px 4px 17px; }
.chat-sample-question { align-self:flex-end; max-width:88%; margin:8px 0 0; padding:11px 16px; font-size:1.01rem; }
.chat-sample-answer { position:relative; z-index:1; width:76%; margin:0; padding:16px 18px; background:var(--surface); border-radius:17px 17px 17px 4px; }
.chat-sample-answer b, .memory-author { font-size:.83rem; font-weight:700; color:var(--prune); }
.chat-sample-answer p { margin-top:4px; font:500 clamp(1.1rem,2vw,1.35rem)/1.36 var(--display); letter-spacing:-.015em; }
.chat-sample-art { width:33%; height:48%; object-fit:contain; object-position:center bottom; position:absolute; z-index:0; inset-inline-end:1.5%; bottom:1%; pointer-events:none; }

.memory-page { width:min(calc(100% - 48px),1070px); margin:28px auto 60px; }
.memory-head { position:relative; isolation:isolate; display:flex; align-items:center; min-height:128px; padding:16px 26px; margin-bottom:24px; background:var(--lilac); border:1px solid #dfcde2; border-radius:18px; overflow:hidden; }
.memory-head h1 { font-size:clamp(2rem,5vw,3.2rem); }
.memory-head>div { flex:1; min-width:0; }
.memory-head p { color:#554358; margin-top:8px; }
.memory-avatar { flex:none; width:110px; height:100px; object-fit:contain; }
.memory-layout { display:grid; grid-template-columns:minmax(205px,260px) minmax(0,1fr); gap:clamp(22px,3.2vw,46px); align-items:start; }
.memory-sources, .memory-thread, .memory-empty, .memory-dialog { min-width:0; }
.memory-sources h2, .memory-thread h2, .memory-empty h2, .report-chat-offer h2 { color:var(--ink); margin:0; font:650 clamp(1.3rem,2.4vw,1.65rem)/1.18 var(--display); letter-spacing:-.034em; text-align:start; }
.memory-sources h2 { margin:6px 0 12px; }
.memory-options { display:grid; gap:7px; max-height:48vh; overflow:auto; padding:2px; }
.memory-option, .memory-cross, .memory-consent { display:flex; align-items:center; gap:10px; cursor:pointer; }
.memory-option { min-height:57px; padding:9px 12px; border:1px solid var(--edge); border-radius:11px; background:var(--surface); }
.memory-option:has(input:checked) { border-color:var(--prune); background:#f4edf5; box-shadow:inset 0 0 0 .5px var(--prune); }
.memory-option:focus-within { outline:2px solid var(--prune); outline-offset:-3px; }
.memory-page input:is([type=checkbox],[type=radio]) { width:16px; height:16px; min-height:16px; flex:0 0 16px; margin:0; padding:0; accent-color:var(--prune); }
.memory-option span { min-width:0; }
.memory-option strong { display:block; color:var(--ink); font-size:.93rem; line-height:1.28; }
.memory-option small { gap:4px; color:var(--muted); font-size:.76rem; margin-top:3px; line-height:1.25; }
.memory-option small svg { width:13px; height:13px; color:var(--prune); }
.memory-cross { min-height:44px; font-size:.88rem; font-weight:600; padding-inline:3px; }
.memory-selection-hint { display:block; color:var(--muted); margin:0 0 6px; }
.memory-sub { padding:0; margin:0; background:transparent; border:0; border-top:1px solid var(--edge); border-radius:0; color:var(--muted); font-size:.85rem; }
.memory-sub summary, .memory-thread summary { min-height:44px; cursor:pointer; padding:12px 2px; font-weight:600; line-height:1.4; }
.memory-sub p { margin:0 0 5px; }
.memory-sub .text-button { font-size:.84rem; }
.memory-thread { padding:clamp(16px,2.6vw,28px); border:1px solid var(--edge); border-radius:18px; background:var(--surface); min-width:0; }
.memory-thread-title { padding-bottom:14px; border-bottom:1px solid var(--edge); }
.memory-starters { margin:19px 0; }
.memory-starters p { margin:0 0 9px; font-size:.93rem; color:var(--muted); }
.memory-starters .button { display:inline-flex; justify-content:flex-start; min-height:42px; margin:2px 4px 2px 0; padding:7px 13px; border-radius:99px; color:var(--prune); font-size:.84rem; text-align:start; }
.memory-empty { display:flex; gap:clamp(16px,4vw,40px); align-items:center; padding:clamp(20px,5vw,50px); max-width:720px; margin:30px auto; background:var(--surface); border:1px solid var(--edge); border-radius:18px; }
.memory-empty p { color:var(--muted); margin:9px 0 18px; }
.memory-empty-art { width:clamp(80px,19vw,155px); height:auto; flex:none; }
.memory-gate, .memory-pending { margin:16px 0; padding:16px 18px; border:1px solid var(--edge); border-radius:12px; background:var(--paper); }
.memory-gate h3 { margin:0; display:flex; align-items:center; gap:7px; font:650 1.16rem/1.3 var(--display); }
.memory-gate h3 svg { flex:none; color:var(--prune); width:17px; height:17px; }
.memory-gate p, .memory-dialog p, .memory-pending p { margin:8px 0 11px; }
.memory-price { font-weight:700; }
.memory-price small { font-weight:400; }
.memory-test, .memory-pending small, .memory-turn>small, .memory-evidence>small { font-size:.8rem; line-height:1.4; color:var(--muted); }
.memory-test { display:block; color:#694c57; margin:6px 0; }
.memory-turn { margin:20px 0; }
.memory-turn>small { display:block; text-align:end; }
.memory-question { width:fit-content; max-width:91%; margin:5px 0 13px auto; padding:10px 15px; }
.memory-answer { scroll-margin-top:74px; max-width:96%; padding:14px 17px 15px; background:#f5eff5; color:var(--ink); border-radius:17px 17px 17px 4px; }
.memory-author { gap:6px; }
.memory-author-avatar { width:26px; height:26px; object-fit:contain; }
.memory-answer>p { margin:6px 0 0; line-height:1.58; }
.memory-evidence { margin-top:12px; border-top:1px solid #dfd3e0; padding-top:8px; }
.memory-citations { display:flex; flex-wrap:wrap; gap:4px 8px; }
.memory-citations .button { min-height:36px; padding:3px 0; font-size:.8rem; line-height:1.35; text-align:start; white-space:normal; }
.memory-pending .button, .memory-dialog .button { margin:3px 6px 3px 0; }
.memory-working .memory-author { color:var(--muted); }
form.memory-compose:not([method=dialog]) { max-width:none; display:grid; grid-template-columns:auto minmax(0,1fr); gap:8px; align-items:center; width:100%; margin-top:20px; padding-top:17px; border-top:1px solid var(--edge); scroll-margin-top:80px; }
.memory-compose>label:first-child { font-size:1rem; font-weight:650; }
.memory-compose-scope { justify-self:end; min-width:0; text-align:end; font-size:.8rem; line-height:1.3; color:var(--muted); }
.memory-compose-scope svg { width:15px; height:15px; flex:none; }
.memory-compose textarea { grid-column:1/-1; box-sizing:border-box; width:100%; font:inherit; min-height:70px; resize:vertical; border:1px solid #ae9cad; border-radius:11px; padding:10px 12px; background:var(--surface); color:inherit; }
.memory-compose .memory-consent { grid-column:1/-1; display:flex; align-items:flex-start; font-size:.8rem; font-weight:450; line-height:1.4; color:var(--muted); gap:8px; padding:5px 0; }
.memory-consent input { transform:translateY(1px); }
.memory-compose .button { grid-column:1/-1; justify-self:end; border-radius:99px; }
.memory-notice { color:var(--prune); font-size:.94rem; }
.memory-notice:not(:empty) { margin-top:12px; }
.memory-dialog { width:min(450px,calc(100% - 24px)); padding:23px; border-radius:18px; background:var(--surface); overflow-wrap:anywhere; }
.memory-dialog .memory-legal { margin:1px 0 10px; }
.memory-quotes { margin:12px 0; padding:0; list-style:none; display:grid; gap:8px; max-height:52vh; overflow:auto; }
.memory-quotes li { padding:10px 12px; background:var(--paper); border-radius:10px; }
.memory-quotes .memory-focus { border-inline-start:4px solid var(--prune); background:var(--lilac); }
.memory-quotes p { margin:3px 0 0; }
.report-chat-offer { display:flex; align-items:flex-start; gap:15px; margin:25px auto; width:min(100%,var(--reading-width,680px)); padding:20px; border:1px solid #dfcde2; border-radius:15px; background:var(--lilac); }
.chat-offer-avatar { width:54px; height:54px; object-fit:contain; flex:none; }
.report-chat-offer p { margin:6px 0 12px; }

@media(max-width:760px){
  .chat-offer { grid-template-columns:1fr; gap:25px; width:min(calc(100% - 36px),520px); margin:30px auto 48px; }
  .chat-offer h1 { font-size:clamp(2.9rem,11vw,4rem); }
  .chat-offer-intro { margin:12px 0 18px; }
  .chat-sample { min-height:330px; gap:12px; padding:18px 18px 62px; }
  .chat-sample-question { margin-top:3px; }
  .chat-sample-answer { width:74%; padding:12px 14px; }
  .chat-sample-art { width:34%; height:42%; }
  .memory-page { width:min(calc(100% - 24px),600px); margin:13px auto 36px; }
  .memory-head { min-height:86px; padding:12px 16px; margin-bottom:14px; border-radius:14px; }
  .memory-head p { font-size:.9rem; line-height:1.35; margin-top:4px; }
  .memory-avatar { width:61px; height:62px; }
  .memory-layout { grid-template-columns:minmax(0,1fr); gap:11px; }
  .memory-sources h2 { margin:0 2px 5px; font-size:1.12rem; }
  .memory-options { display:flex; overflow:auto; max-height:none; padding:3px 2px; gap:6px; }
  .memory-option { min-width:0; width:max-content; max-width:70%; flex:none; min-height:45px; padding:7px 10px; gap:7px; }
  .memory-option strong { font-size:.84rem; }
  .memory-option small { font-size:.72rem; }
  .memory-cross { min-height:44px; padding:5px 3px; }
  .memory-sub { margin:0 2px; }
  .memory-sub summary { min-height:44px; padding:11px 0; }
  .memory-thread { border-radius:14px; padding:15px; }
  .memory-thread-title { padding-bottom:10px; }
  .memory-starters, .memory-turn { margin:13px 0; }
  .memory-starters .button { min-height:44px; padding:7px 11px; }
  form.memory-compose:not([method=dialog]) { margin-top:14px; padding-top:12px; }
  .memory-answer { max-width:98%; padding:12px 13px; }
  .memory-empty { margin:10px 0; }
}
@media(max-width:370px){
  .memory-empty { flex-direction:column; align-items:flex-start; }
  .memory-thread { padding:12px; }
  .memory-compose .button { width:100%; }
  .chat-sample-answer { width:80%; }
}
