.m.ai { max-width: none; white-space: normal; display: flex; flex-direction: column; gap: 10px; font-size: 14px; line-height: 1.7; }
.m.ai > .say { white-space: pre-wrap; font-size: 15px; line-height: 1.8; max-width: 800px; color: var(--heading); }
.m.ai > .say.err { color: var(--err); font-size: 13px; }
.m.u .bub .ent { vertical-align: baseline; }

.steps { display: flex; flex-direction: column; gap: 2px; color: var(--muted); font-size: 12.5px; }
.step { position: relative; padding-left: 14px; }
.step::before { content: ""; position: absolute; left: 0; top: .65em; width: 6px; height: 6px; border-radius: 50%; background: var(--line-strong); }
.step.live::before { background: var(--accent); animation: pulse 1s ease-in-out infinite; }
.step .w { color: var(--fg); }
@keyframes pulse { 50% { opacity: .25; } }

.tbl-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; }
table.tbl { border-collapse: collapse; width: 100%; min-width: 560px; }
.tbl th, .tbl td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--paper-line); }
.tbl tr:last-child td { border-bottom: 0; }
.tbl th { position: static; font-weight: 600; font-size: 12.5px; color: var(--muted); background: var(--chip); white-space: nowrap; }
.tbl tbody tr { cursor: pointer; }
.tbl tbody tr:hover { background: var(--hover); }
.who { position: relative; }
.who .whor { display: flex; gap: 10px; align-items: flex-start; }
.who .whot > b { display: block; color: var(--heading); font-weight: 600; white-space: nowrap; }
.who .whot > span { color: var(--muted); font-size: 12px; white-space: nowrap; }
.who .whot > .fls { display: block; margin-top: 3px; }
.who .lrec { position: absolute; right: 8px; top: 10px; opacity: 0; }
.tbl tr:hover .who .lrec, .who .lrec:focus { opacity: 1; }
.tbl td.who { padding-right: 44px; }
.tbl.jt .mins { white-space: nowrap; font-size: 12.5px; }
.mk { display: inline-flex; width: 22px; height: 22px; align-items: center; justify-content: center; border-radius: 50%; font-size: 13px; font-weight: 700; border: 1px solid; margin-right: 6px; flex: none; }
.mk.ok { color: var(--v-ok); background: var(--v-ok-bg); border-color: var(--v-ok-line); }
.mk.partial { color: var(--v-partial); background: var(--v-partial-bg); border-color: var(--v-partial-line); }
.mk.ng { color: var(--v-ng); background: var(--v-ng-bg); border-color: var(--v-ng-line); }
.mk.unknown { color: var(--v-na); background: var(--v-na-bg); border-color: var(--v-na-line); }
.mk.hit { width: auto; padding: 0 6px; border-radius: 6px; font-size: 11px; font-weight: 700; }
.cell { display: flex; align-items: flex-start; }
.why { font-size: 12.5px; line-height: 1.5; padding-top: 2px; }
.cell.unknown .why { color: var(--accent-dark); }
.legend { color: var(--subtle); font-size: 12px; display: flex; gap: 14px; flex-wrap: wrap; }
.legend .mk { width: 16px; height: 16px; font-size: 10px; margin-right: 4px; }
.legend span { display: inline-flex; align-items: center; }

.kd { font-size: 11px; border-radius: 4px; padding: 0 5px; margin-right: 5px; border: 1px solid; font-weight: 600; }
.kd.must { color: var(--v-ok); border-color: var(--v-ok-line); background: var(--v-ok-bg); }
.kd.nice { color: var(--info-ink); border-color: var(--info-line); background: var(--info-bg); }
.kd.ng { color: var(--v-ng); border-color: var(--v-ng-line); background: var(--v-ng-bg); }

.fl { display: inline-block; font-size: 11px; font-weight: 600; border: 1px solid var(--line-strong); border-radius: 4px; padding: 0 5px; margin-right: 4px; color: var(--muted); background: var(--chip); white-space: nowrap; }
.fl.no_intro, .fl.no_contact { color: var(--v-ng); border-color: var(--v-ng-line); background: var(--v-ng-bg); }
.fl.caution { color: var(--v-partial); border-color: var(--v-partial-line); background: var(--v-partial-bg); }

.m.ai .acts { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

.m.ai .acts > button { border: 1px dashed var(--line); background: var(--bg); border-radius: 999px; padding: 4px 12px; font-size: 13px; font-weight: 400; color: var(--muted); }
.m.ai .acts > button:hover:not(:disabled) { border-color: var(--accent); color: var(--accent-dark); background: var(--warm); }
body.pubtry .m.ai .acts { display: none; }
body.has-job .mkjob { display: none; }

.m.ai > .ecard, .m.ai > .rec { max-width: 860px; }
.ecard.pop { animation: pop .9s ease-out; }
@keyframes pop { 0% { box-shadow: 0 0 0 0 var(--v-ok-line); } 40% { box-shadow: 0 0 0 8px var(--v-ok-line); } 100% { box-shadow: 0 0 0 0 transparent; } }
.job .cid, .job .jf .cid { width: 100%; }
.job .jf { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.job-msg { margin-left: auto; font-size: 12px; }
.newcl { display: flex; flex-direction: column; gap: 6px; padding: 10px; border: 1px dashed var(--line-strong); border-radius: 10px; }
.newcl button, .radd { align-self: flex-start; }
.reqs { display: flex; flex-direction: column; gap: 6px; }
.req { display: flex; gap: 6px; align-items: center; }
.job .req .rk { width: 84px; flex: none; font-weight: 600; }
.req[data-kind="must"] .rk { color: var(--v-ok); border-color: var(--v-ok-line); background: var(--v-ok-bg); }
.req[data-kind="nice"] .rk { color: var(--info-ink); border-color: var(--info-line); background: var(--info-bg); }
.req[data-kind="ng"] .rk { color: var(--v-ng); border-color: var(--v-ng-line); background: var(--v-ng-bg); }
.orig summary { cursor: pointer; font-size: 12px; color: var(--muted); }
.orig p { font-size: 12px; color: var(--muted); padding: 6px 0 0; white-space: pre-wrap; }

.rec-edit .cwho .cx, .rec-edit .cwho .cid { display: none; }

.jnews { align-self: flex-start; max-width: 640px; animation: pop .9s ease-out; }
.jnews .mv { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; }
.jnews .mv s { color: var(--muted); }
.jnews .mv b { font-size: 16px; }
.jnews .ppl { display: flex; flex-wrap: wrap; gap: 6px 14px; }
.jnews .ppl > span { display: inline-flex; align-items: center; gap: 6px; }
.jnews .ppl .lrec { margin-left: 0; }

.donenote { align-self: center; display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--v-ok-line); background: var(--v-ok-bg); color: var(--v-ok); border-radius: 999px; padding: 3px 16px; font-weight: 600; animation: pop .9s ease-out; }
.waynote { align-self: flex-start; display: inline-flex; align-items: center; gap: 10px; border: 1px solid var(--accent-tint-line); background: var(--warm); color: var(--accent-dark); border-radius: 10px; padding: 5px 12px; font-size: 13px; }
.waynote.off { border-color: var(--line); background: var(--chip); color: var(--muted); text-decoration: line-through; }

#sugs button.due { border-color: var(--accent-tint-line); background: var(--warm); border-style: solid; color: var(--fg); display: inline-flex; align-items: center; gap: 4px; }
#sugs button.due small { color: var(--muted); margin-left: 6px; }
#sugs button.due .ent { border: 0; background: none; padding: 0; margin: 0; }

#sugs button { display: inline-flex; align-items: center; gap: 1px; line-height: 1.5; }
#sugs button .ent { vertical-align: middle; line-height: 1.5; margin-right: 1px; }
#cost { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
#cost .priv { color: var(--subtle); }

#try-cta { display: flex; align-items: center; gap: 6px; margin-left: 4px; white-space: nowrap; }
#try-cta a, #side-cta a { text-decoration: none; font-size: 12.5px; border-radius: 999px; padding: 3px 12px; border: 1px solid var(--line-strong); color: var(--fg); background: var(--bg); }
#try-cta a.cta-consult, #side-cta a.cta-consult { background: var(--accent); border-color: var(--accent); color: var(--bg); font-weight: 600; }
#try-cta a:hover, #side-cta a:hover { border-color: var(--accent); }
#side-cta { display: grid; gap: 6px; margin: 8px 4px; padding: 10px; border: 1px solid var(--line); border-radius: 10px; }
#side-cta .cap { font-size: 12px; color: var(--muted); }
#side-cta a { text-align: center; padding: 6px 12px; font-size: 13px; }
#try-over { position: fixed; inset: 0; z-index: 9100; background: var(--scrim); display: grid; place-items: center; }
#try-over .demo-pop { position: static; }

#composer { align-items: center; padding: 4px 5px 4px 14px; border-radius: 22px; }
#input { line-height: 1.6; padding: 4px 0; }

@media (max-width: 640px) {
  body.pubtry #try-cta { display: none; }
  body.pubtry #cost { display: none; }

  #composer { align-items: center; gap: 4px; padding: 3px 4px 3px 6px; border-radius: 22px; }
  #input { min-height: 0; font-size: 16px; line-height: 1.5; padding: 6px 0; max-height: 120px; }
  #attach { width: 32px; height: 32px; }
  #send { width: 32px; height: 32px; font-size: 15px; }
  #input.blank::before { content: "人・案件について聞く"; }

  #sugs, body.empty #sugs { flex-wrap: nowrap; justify-content: flex-start; overflow-x: auto; gap: 6px; margin: 8px -10px 0; padding: 0 10px 2px;
    scrollbar-width: none; -webkit-mask-image: linear-gradient(to right, var(--fg) 82%, transparent); mask-image: linear-gradient(to right, var(--fg) 82%, transparent); }
  #sugs::-webkit-scrollbar { display: none; }
  #sugs button { flex: none; white-space: nowrap; font-size: 12.5px; padding: 5px 11px; }
  #sugs .ent small { display: none; }

  #top { padding-left: 10px; }
  #side-open { width: 40px; height: 40px; font-size: 22px; color: var(--heading); display: grid; place-items: center; }
  #side-open[data-n]::after { top: 1px; right: 0; }
  table.tbl { min-width: 0; }
  .tbl th, .tbl td { padding: 8px; }
  .tbl td { min-width: 128px; }
  .tbl td.who { padding-right: 8px; min-width: 0; }
  .who .whor { gap: 6px; }
  .who .lrec { display: none; }
}

@media (min-width: 641px) { #side-cta { display: none; } }

#top-new { display: grid; place-items: center; color: var(--muted); }
#top-new:hover { color: var(--heading); background: var(--hover); }
@media (max-width: 640px) { #top-new { width: 40px; height: 40px; color: var(--heading); } }

@keyframes ag-pop { from { opacity: 0; transform: translateY(8px) scale(.985); } to { opacity: 1; transform: none; } }
@keyframes ag-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes ag-slide { from { transform: translateX(-100%); } to { transform: none; } }
#pop:not([hidden]) { animation: ag-fade .18s ease-out; }
#pop:not([hidden]) .pop-card { animation: ag-pop .24s ease-out; }
#notice-pop:not([hidden]), #todo-pop:not([hidden]), #recwin:not([hidden]), #mention:not([hidden]), #attach-menu:not([hidden]) { animation: ag-pop .2s ease-out; }
#flow > .m, #flow > .donenote { animation: ag-pop .28s ease-out both; }
#sugs button { animation: ag-fade .3s ease-out both; }
#try-over { animation: ag-fade .3s ease-out; }
@media (max-width: 820px) { body:not(.side-off) #side { animation: ag-slide .22s ease-out; } }
@media (prefers-reduced-motion: reduce) { #pop, #pop .pop-card, #notice-pop, #todo-pop, #recwin, #mention, #flow > .m, #sugs button, #side, #try-over { animation: none !important; } }
