/* Home: one prompt box in the middle (LD-1). The side menu around it is shell.js and brings its own styles.
   Colours: "Mist", a very light cool blue, and its dark (the frame says which: html[data-ladelo-theme]). */
:root { --page: #F5F8FC; --card: #FFFFFF; --soft: #DFE8F2; --line: #D3DEEA; --fg: #26303B; --muted: #5D6B7A; --faint: #8493A3; --a: #2B7FD9; --b: #7A5BD6; --spark: #37B6C9; --a-soft: #DCEBFB; --a-line: #A7CDF1; --a2: #1F6BC0; }
html[data-ladelo-theme="dark"] { --page: #0E0F12; --card: #16181D; --soft: #1C1E24; --line: #2A2D35; --fg: #ECEDF0; --muted: #A4A8B3; --faint: #7B7F8A; --a: #3D8DE6; --b: #C04F9C; --spark: #E6B450; --a-soft: #15273B; --a-line: #2C4F78; --a2: #7DB9F5; color-scheme: dark; }
* { box-sizing: border-box; }
body { margin: 0; min-height: calc(100vh - var(--ladelo-top, 0px)); background: var(--page); color: var(--fg); font: 15px/1.45 Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
a { color: inherit; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--a); outline-offset: 2px; }
.home { max-width: 900px; margin: 0 auto; padding: 0 24px 56px; }
.center { display: flex; flex-direction: column; align-items: center; gap: 18px; padding-top: 22vh; text-align: center; }
h1 { margin: 0; font-size: 30px; font-weight: 500; letter-spacing: -0.025em; line-height: 1.2; text-wrap: balance; }
.lead { margin: 0; color: var(--muted); }
/* the box (KB-6-1): two or three lines, a slowly moving edge of colour, a white inside; the clock and Send inside it at
   the bottom right */
.ask { display: flex; flex-direction: column; gap: 4px; width: min(680px, 100%); padding: 14px 10px 10px 20px; border-radius: 22px; border: 2px solid transparent; text-align: left;
  background: linear-gradient(var(--card), var(--card)) padding-box, linear-gradient(90deg, var(--a), var(--b), var(--spark), var(--a)) border-box;
  background-size: 100% 100%, 300% 100%; animation: drift 7s linear infinite; box-shadow: 0 4px 18px rgba(20, 40, 70, 0.08); }
@keyframes drift { to { background-position: 0 0, 300% 0; } }
.ask textarea { width: 100%; min-height: 3.2em; max-height: 9em; padding: 0 10px 0 0; border: 0; outline: 0; background: none; color: var(--fg); font: inherit; font-size: 16px; line-height: 1.55; resize: none; field-sizing: content; }
.ask textarea::placeholder { color: var(--faint); }
.boxrow { display: flex; align-items: center; gap: 6px; }
.ib { width: 34px; height: 34px; flex: none; padding: 0; border: 0; border-radius: 50%; background: none; color: var(--muted); display: grid; place-items: center; cursor: pointer; }
.ib:hover, .ib[aria-expanded="true"] { background: var(--soft); color: var(--fg); }
.ib[hidden] { display: none; }
.push { margin-left: auto; }
/* KB-6-5: the files chosen with ＋, and the box while files are dragged over it */
.boxrow .count { padding: 2px 9px; border-radius: 11px; background: var(--soft); color: var(--muted); font-size: 12px; white-space: nowrap; }
.boxrow .count[hidden] { display: none; }
.ask.drop { outline: 2px dashed var(--a); outline-offset: 3px; }
.send { width: 36px; height: 36px; flex: none; padding: 0; border: 0; border-radius: 50%; background: var(--fg); color: var(--page); display: grid; place-items: center; cursor: pointer; }
.boxrow .send:only-child, .boxrow #clock[hidden] + .send { margin-left: auto; }
/* under the box: "Response" on the left (KB-6-1), the recent questions as a small list under the clock */
.under { position: relative; display: flex; width: min(680px, 100%); margin-top: -8px; padding: 0 12px; }
.resp { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); font-size: 13px; }
.resp select { height: 28px; padding: 0 4px; border: 0; border-radius: 6px; background: none; color: var(--fg); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.resp select:hover { background: var(--soft); }
.resp select:focus-visible { outline: 2px solid var(--a); outline-offset: 1px; }
.recent { position: absolute; right: 0; top: 2px; z-index: 5; width: min(340px, 100%); padding: 6px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); box-shadow: 0 10px 28px rgba(20, 40, 70, 0.16); text-align: left; }
.recent[hidden] { display: none; }
.recent h2 { margin: 4px 8px 6px; font-size: 11px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; color: var(--faint); }
.recent button { display: flex; align-items: baseline; gap: 10px; width: 100%; padding: 7px 8px; border: 0; border-radius: 8px; background: none; color: var(--fg); font: inherit; font-size: 13.5px; text-align: left; cursor: pointer; }
.recent button:hover, .recent button:focus-visible { background: var(--soft); }
.recent button span { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.recent button small { flex: none; color: var(--faint); font-size: 11.5px; }
.chips { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; max-width: 720px; }
.chip { height: 32px; padding: 0 14px; border: 1px solid var(--line); border-radius: 16px; background: var(--card); color: var(--fg); font: inherit; font-size: 14px; white-space: nowrap; max-width: 100%; overflow: hidden; text-overflow: ellipsis; cursor: pointer; }
.chip:hover { background: var(--soft); }
.wait { display: flex; align-items: center; gap: 8px; min-height: 32px; padding: 0 10px; border-radius: 8px; color: var(--muted); text-decoration: none; white-space: nowrap; }
.wait:hover { background: var(--soft); color: var(--fg); }
.wait b { min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: var(--a); color: #fff; font-size: 12px; font-weight: 600; display: grid; place-items: center; }
.button { display: inline-flex; align-items: center; height: 36px; padding: 0 16px; border-radius: 8px; background: var(--fg); color: var(--page); font-weight: 500; text-decoration: none; }
.home.out { max-width: 520px; padding-top: 96px; }
.home.out h1 { margin-bottom: 10px; }
@media (max-width: 720px) { .center { padding-top: 12vh; } h1 { font-size: 24px; } }
@media (prefers-reduced-motion: reduce) { .ask { animation: none; } }
/* KB-L1: the menu's place is painted before the frame script draws the menu into it, in the same colours */
html[data-ladelo]::before { content: ""; position: fixed; top: 0; bottom: 0; left: 0; width: var(--ladelo-left, 0px); background: #EAF0F7; box-shadow: inset -1px 0 0 #D3DEEA; }
html[data-ladelo-theme="dark"]::before { background: #08090B; box-shadow: inset -1px 0 0 #2A2D35; }
html { background: var(--page); }
/* KB-L3: from Home to an application under the same address, a short cross-fade in place of a blank moment */
@view-transition { navigation: auto; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: 0.14s; }
@media (prefers-reduced-motion: reduce) { ::view-transition-old(root), ::view-transition-new(root) { animation: none; } }

/* PL-1: a page of the launch site with a list (Projects). The same calm manner: a title, lines on the page, quiet marks. */
.page { max-width: 1100px; margin: 0 auto; padding: 28px 32px 56px; }
.page .head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.page h1 { font-size: 24px; font-weight: 600; letter-spacing: -0.02em; }
.page .lead { margin-top: 6px; }
.list { overflow-x: auto; }
.list table { width: 100%; border-collapse: collapse; white-space: nowrap; }
.list th { text-align: left; font-weight: 500; color: var(--muted); font-size: 13px; padding: 8px 10px; border-bottom: 1px solid var(--line); }
.list td { padding: 11px 10px; border-bottom: 1px solid var(--soft); }
.list tr:hover td { background: color-mix(in srgb, var(--soft) 55%, transparent); }
.list td.cut { max-width: 420px; overflow: hidden; text-overflow: ellipsis; }
.list .muted { color: var(--muted); }
.list a.strong { font-weight: 600; color: var(--fg); text-decoration: none; }
.list a.strong:hover { text-decoration: underline; }
.hint { color: var(--muted); margin: 12px 2px 0; }
@media (max-width: 720px) { .page { padding: 18px 16px 40px; } }
.quietlink { color: var(--a); text-decoration: none; }
.quietlink:hover { text-decoration: underline; }
/* PL-4b: the two doors of a project: open the application set up for it, or Add */
.door { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 9px 0 7px; border: 1px solid var(--line); border-radius: 8px; background: var(--card, transparent); color: var(--fg); font-size: 13px; font-weight: 500; text-decoration: none; }
.door:hover { background: var(--soft); }
.door .mk { flex: none; }
.door .ext { color: var(--muted); font-size: 12px; }
.add { display: inline-flex; align-items: center; gap: 5px; height: 28px; padding: 0 11px 0 8px; border: 1px dashed color-mix(in srgb, var(--muted) 55%, transparent); border-radius: 8px; color: var(--muted); font-size: 13px; text-decoration: none; }
a.add:hover { border-style: solid; border-color: var(--a); color: var(--a); }
.add.later { opacity: 0.6; cursor: default; }
/* PL-4d: a conversation with an agent on the left, the sheet it fills in on the right */
.page .head .grow { flex: 1; }
.tag { font-size: 12px; color: var(--muted); border: 1px solid var(--line); border-radius: 10px; padding: 1px 8px; }
.quietbutton { display: inline-flex; align-items: center; height: 36px; padding: 0 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--card); color: var(--fg); font-weight: 500; text-decoration: none; }
.quietbutton:hover { background: var(--soft); }
button.button { border: 0; font: inherit; font-weight: 500; cursor: pointer; }
.problem { margin: 0 0 12px; padding: 8px 12px; border-radius: 8px; background: color-mix(in srgb, #d1496b 12%, var(--card)); color: var(--fg); }
.agentduo { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr); gap: 24px; align-items: start; }
.talk { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.talkbox { display: flex; align-items: flex-end; gap: 6px; margin: 0; padding: 10px 10px 10px 18px; border-radius: 18px; border: 2px solid transparent;
  background: linear-gradient(var(--card), var(--card)) padding-box, linear-gradient(90deg, var(--a), var(--b), var(--spark), var(--a)) border-box; box-shadow: 0 6px 22px rgba(35, 131, 226, 0.12); }
.talkin { flex: 1; min-width: 0; border: 0; outline: 0; background: none; color: var(--fg); font: inherit; font-size: 15px; line-height: 1.45; resize: none; padding: 2px 0; }
.talkin::placeholder { color: var(--faint); }
.thread { display: flex; flex-direction: column; gap: 10px; }
.say { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.say.person { align-items: flex-end; }
.bubble { max-width: min(82%, 560px); padding: 10px 15px; border-radius: 18px; white-space: pre-wrap; overflow-wrap: anywhere; }
.say.agent .bubble { background: var(--a-soft); border-top-left-radius: 6px; }
.say.person .bubble { background: linear-gradient(120deg, var(--a), var(--b)); color: #fff; border-top-right-radius: 6px; }
.say .chips { justify-content: flex-start; margin: 0; }
form.chips, form.inline { margin: 0; }
.agentcard { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; max-width: min(82%, 560px); padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); }
.agentcard > div { flex: 1 1 220px; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.agentcard span { color: var(--muted); font-size: 13px; }
.say .row { display: flex; gap: 8px; flex-wrap: wrap; }
.muted.small { font-size: 13px; color: var(--muted); }
.projsheet { position: sticky; top: calc(var(--ladelo-top, 0px) + 16px); border: 1px solid var(--line); border-radius: 12px; background: var(--card); padding: 12px 14px; display: flex; flex-direction: column; gap: 2px; }
.shead { display: flex; align-items: center; gap: 8px; padding-bottom: 8px; margin-bottom: 4px; border-bottom: 1px solid var(--line); }
.shead b { flex: 1; font-size: 14px; }
.state { font-size: 12px; padding: 1px 9px; border-radius: 10px; background: var(--soft); color: var(--muted); }
.state.made { background: color-mix(in srgb, #3f8a63 18%, var(--card)); color: #2f7350; }
.srow { display: flex; flex-direction: column; gap: 1px; padding: 6px; border-radius: 6px; }
.srow span { color: var(--muted); font-size: 12px; }
.srow b { font-weight: 500; font-size: 13.5px; overflow-wrap: anywhere; }
.srow.empty b { color: var(--faint); font-weight: 400; font-style: italic; }
.srow.changed { animation: lit 2.4s ease forwards; }
@keyframes lit { from { background: color-mix(in srgb, var(--spark) 32%, transparent); } to { background: transparent; } }
.sfoot { margin: 8px 0 0; color: var(--muted); font-size: 12px; }
@media (prefers-reduced-motion: reduce) { .srow.changed { animation: none; background: color-mix(in srgb, var(--spark) 18%, transparent); } }
@media (max-width: 860px) { .agentduo { grid-template-columns: minmax(0, 1fr); } .projsheet { position: static; } }
/* the owner, 2026-12-02: Home's bell, under the box at the right of the Response line */
.under .grow { flex: 1; }
.hbell { position: relative; }
.hbell > summary { list-style: none; position: relative; width: 32px; height: 32px; margin-right: 2px; border-radius: 8px; display: grid; place-items: center; color: var(--muted); cursor: pointer; }
.hbell > summary::-webkit-details-marker { display: none; }
.hbell > summary:hover, .hbell[open] > summary { background: var(--soft); color: var(--fg); }
.hbell .badge { position: absolute; top: -2px; right: -3px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 999px; background: var(--a); color: #fff; font-size: 10.5px; font-weight: 600; line-height: 16px; text-align: center; }
.hbellpop { position: absolute; right: 0; top: 36px; z-index: 6; width: min(320px, 80vw); padding: 6px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); box-shadow: 0 10px 28px rgba(20, 40, 70, 0.16); text-align: left; }
.hbellpop h2 { margin: 0; padding: 8px 10px; font-size: 13px; font-weight: 600; color: var(--muted); }
.hbellpop a, .hbellpop p { display: flex; align-items: center; min-height: 40px; margin: 0; padding: 6px 10px; border-radius: 8px; color: var(--fg); text-decoration: none; }
.hbellpop a:hover { background: var(--soft); }
.hbellpop p { color: var(--muted); }

/* LI-1: Settings, its tabs and the Appearance choices */
.tabs { display: flex; flex-wrap: wrap; gap: 2px; border-bottom: 1px solid var(--line); margin: 0 0 16px; }
.tab { height: 34px; display: inline-flex; align-items: center; padding: 0 12px; border-bottom: 2px solid transparent; margin-bottom: -1px; color: var(--muted); font-weight: 500; text-decoration: none; }
.tab:hover { color: var(--fg); }
.tab.on { color: var(--fg); font-weight: 600; border-bottom-color: var(--fg); }
.list td.num { text-align: right; font-variant-numeric: tabular-nums; }
.looks { display: flex; flex-wrap: wrap; gap: 10px; margin: 0; }
.look { display: flex; align-items: center; gap: 10px; height: 46px; padding: 0 16px 0 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--card); color: var(--fg); font: inherit; font-weight: 500; cursor: pointer; }
.look small { color: var(--faint); font-weight: 400; }
.look.on { border-color: var(--fg); box-shadow: 0 0 0 1px var(--fg); }
.look .sw { width: 22px; height: 22px; border-radius: 50%; border: 1px solid var(--line); }
.look .sw.light { background: linear-gradient(135deg, #F5F8FC 50%, #2B7FD9 50%); }
.look .sw.dark { background: linear-gradient(135deg, #0E0F12 50%, #3D8DE6 50%); }
.page h2.sub { margin: 22px 0 10px; font-size: 14px; font-weight: 600; color: var(--muted); }
.page h2.sub:first-of-type { margin-top: 4px; }

/* LD-B: Ladelo's own sign-in (app.ladelo.ai) and the Sign-in tab of Settings */
.signin { max-width: 420px; }
.signform { display: flex; flex-direction: column; gap: 14px; margin: 16px 0 0; max-width: 360px; }
.signform label { display: flex; flex-direction: column; gap: 6px; font-weight: 500; }
.signform input { font: inherit; padding: 9px 11px; border: 1px solid var(--line); border-radius: 8px; background: var(--card); color: var(--fg); }
.signform input:focus { outline: 2px solid color-mix(in srgb, var(--a, #2b7fd9) 45%, transparent); outline-offset: 1px; }
.signform .button { align-self: flex-start; }
.setupkey code { display: inline-block; padding: 10px 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--card); font: 600 17px/1.4 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .06em; word-break: break-all; }
