/* Staffroom. No inline styles anywhere (strict CSP): everything lives here. */
:root {
  --bg: #f6f5f1; --panel: #ffffff; --ink: #1c1a24; --muted: #6b6878; --line: #e6e3dc; --soft: #efede7;
  --brand: #5b4bdb; --brand-ink: #ffffff; --brand-soft: #ece9ff; --ok: #1f8a5b; --ok-soft: #e3f5ec;
  --warn: #b26b00; --warn-soft: #fff3dc; --bad: #c0392b; --bad-soft: #fde8e6;
  --radius: 14px; --shadow: 0 1px 2px rgba(20, 16, 40, .06), 0 4px 16px rgba(20, 16, 40, .05);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #14131a; --panel: #1d1c25; --ink: #eceaf3; --muted: #9c98ab; --line: #2e2c39; --soft: #25232f;
    --brand: #8b7dff; --brand-ink: #14131a; --brand-soft: #2b2650; --ok: #4cc38a; --ok-soft: #173327;
    --warn: #f0b04a; --warn-soft: #3a2c12; --bad: #ff7b6e; --bad-soft: #3d1c19;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 4px 16px rgba(0, 0, 0, .25);
    color-scheme: dark;
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body { background: var(--bg); color: var(--ink); font: 15px/1.55 var(--font); -webkit-font-smoothing: antialiased; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: 28px; } h2 { font-size: 20px; } h3 { font-size: 16px; }
p { margin: 0 0 .8em; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.hidden { display: none !important; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.row.end { justify-content: flex-end; }
.row.center { justify-content: center; }
.section-title { margin: 28px 0 12px; }
.spacer { flex: 1; }
.stack > * + * { margin-top: 14px; }

/* Buttons and forms */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; border: 1px solid var(--line); background: var(--panel);
  color: var(--ink); font: inherit; font-weight: 600; font-size: 14px; padding: 9px 14px; border-radius: 10px; cursor: pointer; text-decoration: none; white-space: nowrap; }
.btn:hover { border-color: var(--muted); text-decoration: none; }
.btn.primary { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.btn.primary:hover { filter: brightness(1.08); }
.btn.danger { color: var(--bad); }
.btn.ghost { border-color: transparent; background: transparent; }
.btn.small { padding: 5px 10px; font-size: 13px; border-radius: 8px; }
.btn.big { padding: 13px 22px; font-size: 16px; border-radius: 12px; }
.btn:disabled { opacity: .55; cursor: default; }
label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 5px; }
.hint { font-weight: 400; color: var(--muted); font-size: 13px; }
input[type=text], input[type=email], input[type=password], input[type=url], select, textarea {
  width: 100%; font: inherit; color: var(--ink); background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
textarea { resize: vertical; min-height: 80px; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--brand); outline-offset: -1px; border-color: transparent; }
.field { margin-bottom: 14px; }
.field.error input, .field.error textarea, .field.error select { border-color: var(--bad); }
.form-error { color: var(--bad); background: var(--bad-soft); border-radius: 10px; padding: 9px 12px; font-size: 14px; margin-bottom: 12px; }
.check { display: flex; gap: 8px; align-items: center; font-weight: 500; cursor: pointer; }
.check input { width: 17px; height: 17px; accent-color: var(--brand); }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }

/* Cards and panels */
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); }
.card + .card { margin-top: 16px; }
.card h2 { font-size: 17px; }
.empty { text-align: center; color: var(--muted); padding: 28px 12px; }
.badge { display: inline-block; min-width: 20px; padding: 1px 7px; border-radius: 99px; background: var(--brand); color: var(--brand-ink); font-size: 12px; font-weight: 700; text-align: center; }
.pill { display: inline-block; padding: 2px 9px; border-radius: 99px; font-size: 12px; font-weight: 600; background: var(--soft); color: var(--muted); }
.pill.review { background: var(--warn-soft); color: var(--warn); }
.pill.approved { background: var(--brand-soft); color: var(--brand); }
.pill.done { background: var(--ok-soft); color: var(--ok); }
.pill.paused, .pill.error { background: var(--bad-soft); color: var(--bad); }
.notice { border-radius: 12px; padding: 12px 14px; background: var(--warn-soft); color: var(--warn); font-size: 14px; margin-bottom: 16px; }

/* Avatars: one colour per team member */
.av { flex: none; width: 40px; height: 40px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 17px; color: #fff; background: var(--brand); }
.av.sm { width: 28px; height: 28px; font-size: 13px; }
.av.lg { width: 64px; height: 64px; font-size: 26px; }
.av.xl { width: 88px; height: 88px; font-size: 36px; }
.av-maya { background: linear-gradient(135deg, #ff8a5c, #e8505b); }
.av-leo { background: linear-gradient(135deg, #3bb2a0, #1d7f8c); }
.av-zara { background: linear-gradient(135deg, #f06bc4, #a04ee0); }
.av-sam { background: linear-gradient(135deg, #4f8cff, #2f5bd3); }
.av-iris { background: linear-gradient(135deg, #f7b733, #e57b20); }
.av-theo { background: linear-gradient(135deg, #6c7a89, #34495e); }
.av-nina { background: linear-gradient(135deg, #7bd389, #2f9e5b); }

/* Signed-in layout */
.shell { display: grid; grid-template-columns: 248px 1fr; min-height: 100vh; }
.side { background: var(--panel); border-right: 1px solid var(--line); padding: 18px 12px; position: sticky; top: 0; height: 100vh; overflow-y: auto; display: flex; flex-direction: column; }
.logo { display: flex; align-items: center; gap: 9px; font-weight: 800; font-size: 18px; color: var(--ink); padding: 4px 8px 16px; letter-spacing: -.02em; }
.logo:hover { text-decoration: none; }
.logo img { width: 30px; height: 30px; }
.nav a { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 10px; color: var(--ink); font-weight: 500; }
.nav a:hover { background: var(--soft); text-decoration: none; }
.nav a.on { background: var(--brand-soft); color: var(--brand); font-weight: 650; }
.nav a .badge { margin-left: auto; }
.nav .ico { width: 28px; text-align: center; font-size: 16px; }
.nav-label { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; padding: 16px 10px 6px; }
.nav .who { line-height: 1.2; }
.nav .who small { display: block; color: var(--muted); font-size: 12px; font-weight: 400; }
.side-foot { margin-top: auto; padding: 14px 10px 0; font-size: 13px; color: var(--muted); }
.meter { height: 6px; background: var(--soft); border-radius: 99px; overflow: hidden; margin-top: 6px; }
.meter i { display: block; height: 100%; background: var(--brand); width: 0; }
.main { min-width: 0; }
.page { max-width: 1060px; margin: 0 auto; padding: 28px 28px 60px; }
.page.wide { max-width: none; padding: 0; }
.page-head { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; flex-wrap: wrap; }
.page-head h1 { margin: 0; }
.topbar { display: none; }

/* Team grid */
.team-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.member { display: flex; flex-direction: column; gap: 8px; color: var(--ink); }
.member:hover { text-decoration: none; border-color: var(--brand); }
.member .role { color: var(--muted); font-size: 13px; margin-top: -4px; }
.member p { font-size: 14px; color: var(--muted); margin: 0; flex: 1; }

/* Lists */
.list { list-style: none; margin: 0; padding: 0; }
.list li { display: flex; gap: 12px; align-items: center; padding: 11px 4px; border-top: 1px solid var(--line); }
.list li:first-child { border-top: 0; }
.list .grow { flex: 1; min-width: 0; }
.list .title { font-weight: 600; color: var(--ink); display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.list a.title:hover { color: var(--brand); text-decoration: none; }
.list .sub { color: var(--muted); font-size: 13px; }
.cols { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.cols > .card + .card { margin-top: 0; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 18px; overflow-x: auto; }
.tabs a { padding: 9px 14px; color: var(--muted); font-weight: 600; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tabs a:hover { color: var(--ink); text-decoration: none; }
.tabs a.on { color: var(--brand); border-bottom-color: var(--brand); }
.checklist li .tick { width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--line); display: inline-flex; align-items: center; justify-content: center; font-size: 13px; flex: none; }
.checklist li.done .tick { background: var(--ok); border-color: var(--ok); color: #fff; }
.checklist li.done .title { text-decoration: line-through; color: var(--muted); }

/* Employee page + chat */
.emp-head { display: flex; gap: 16px; align-items: center; padding: 22px 28px 0; flex-wrap: wrap; }
.emp-head h1 { margin: 0; font-size: 24px; }
.emp-head > div:nth-child(2) { flex: 1; min-width: 220px; }
.chat-page { display: flex; flex-direction: column; height: 100vh; height: 100dvh; }
.chat-page .chat-wrap { flex: 1; min-height: 0; height: auto; }
.emp-head .tabs { flex-basis: 100%; margin: 6px 0 0; }
.chat-wrap { display: grid; grid-template-columns: 240px 1fr; height: calc(100vh - 138px); border-top: 1px solid var(--line); margin-top: -1px; }
.chat-list { border-right: 1px solid var(--line); overflow-y: auto; padding: 12px 10px; }
.chat-list a { display: block; padding: 8px 10px; border-radius: 9px; color: var(--ink); font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat-list a:hover { background: var(--soft); text-decoration: none; }
.chat-list a.on { background: var(--brand-soft); color: var(--brand); font-weight: 600; }
.chat-list .btn { width: 100%; margin-bottom: 10px; }
.chat-main { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.msgs { flex: 1; overflow-y: auto; padding: 24px 28px; }
.msgs-inner { max-width: 780px; margin: 0 auto; }
.msg { display: flex; gap: 12px; margin-bottom: 22px; }
.msg.user { justify-content: flex-end; }
.msg.user .bubble { background: var(--brand); color: var(--brand-ink); border-radius: 16px 16px 4px 16px; padding: 10px 14px; max-width: 80%; white-space: pre-wrap; }
.msg.model .body { flex: 1; min-width: 0; }
.msg.model .name { font-weight: 700; font-size: 14px; margin-bottom: 2px; }
.msg-actions { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.thinking { color: var(--muted); font-style: italic; }
.thinking::after { content: '…'; animation: dots 1.2s steps(3) infinite; display: inline-block; width: 1em; overflow: hidden; vertical-align: bottom; }
@keyframes dots { from { width: 0; } to { width: 1em; } }
.sources { margin-top: 8px; font-size: 13px; }
.sources a { display: inline-block; max-width: 260px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: bottom; background: var(--soft); border-radius: 6px; padding: 1px 8px; margin: 3px 4px 0 0; color: var(--muted); }
.composer { border-top: 1px solid var(--line); padding: 14px 28px 18px; background: var(--panel); }
.composer-inner { max-width: 780px; margin: 0 auto; }
.composer textarea { min-height: 52px; max-height: 260px; resize: none; }
.composer .row { margin-top: 8px; }
.hello { text-align: center; padding: 40px 10px 10px; }
.hello .av { margin-bottom: 12px; }
.starters { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 18px; }
.starters button { border: 1px solid var(--line); background: var(--panel); color: var(--ink); border-radius: 99px; padding: 8px 14px; font: inherit; font-size: 14px; cursor: pointer; }
.starters button:hover { border-color: var(--brand); color: var(--brand); }
.emp-body { padding: 24px 28px 60px; max-width: 1000px; }

/* Markdown output */
.md { overflow-wrap: anywhere; }
.md h1 { font-size: 22px; margin: .2em 0 .6em; } .md h2 { font-size: 18px; margin: 1.2em 0 .5em; } .md h3, .md h4 { font-size: 16px; margin: 1em 0 .4em; }
.md p, .md ul, .md ol, .md blockquote, .md pre, .md table { margin: 0 0 .85em; }
.md ul, .md ol { padding-left: 1.4em; }
.md li { margin: .2em 0; }
.md blockquote { border-left: 3px solid var(--line); padding-left: 12px; color: var(--muted); }
.md code { background: var(--soft); padding: 1px 5px; border-radius: 5px; font-size: .92em; }
.md pre { background: var(--soft); padding: 12px; border-radius: 10px; overflow-x: auto; }
.md pre code { background: none; padding: 0; }
.md table { border-collapse: collapse; width: 100%; font-size: 14px; display: block; overflow-x: auto; }
.md th, .md td { border: 1px solid var(--line); padding: 6px 9px; text-align: left; vertical-align: top; }
.md th { background: var(--soft); }
.md hr { border: 0; border-top: 1px solid var(--line); margin: 1.2em 0; }

/* Work detail */
.doc { font-size: 15.5px; }
.doc-edit textarea { min-height: 460px; font: 14px/1.6 ui-monospace, SFMono-Regular, Menlo, monospace; }
.work-meta { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
.side-card { position: sticky; top: 20px; }
.work-layout { display: grid; grid-template-columns: 1fr 280px; gap: 18px; align-items: start; }
.work-layout .side-card .btn { width: 100%; margin-bottom: 8px; }
.preview-text { color: var(--muted); font-size: 14px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* Jobs */
.job-ideas { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.job-idea { display: flex; gap: 10px; align-items: flex-start; }
.job-idea .grow { flex: 1; }
.job-idea p { margin: 2px 0 8px; font-size: 13px; color: var(--muted); }
.when { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 12px; }

/* Toasts and overlays */
.toasts { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); z-index: 50; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast { background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 10px; font-size: 14px; box-shadow: var(--shadow); animation: up .2s ease-out; }
.toast.bad { background: var(--bad); color: #fff; }
.toast a { color: inherit; text-decoration: underline; margin-left: 8px; }
@keyframes up { from { transform: translateY(8px); opacity: 0; } }
.working { display: flex; gap: 12px; align-items: center; padding: 18px; background: var(--brand-soft); border-radius: 12px; color: var(--brand); font-weight: 600; margin-top: 14px; }
.spin { width: 18px; height: 18px; border: 2.5px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .8s linear infinite; flex: none; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Signed-out pages */
.public { min-height: 100vh; }
.pub-nav { display: flex; align-items: center; gap: 10px; max-width: 1100px; margin: 0 auto; padding: 18px 24px; }
.hero { max-width: 1100px; margin: 0 auto; padding: 50px 24px 30px; text-align: center; }
.hero h1 { font-size: 52px; letter-spacing: -.03em; max-width: 820px; margin: 0 auto 18px; }
.hero h1 em { font-style: normal; color: var(--brand); }
.hero .lead { font-size: 19px; color: var(--muted); max-width: 640px; margin: 0 auto 28px; }
.hero-team { display: flex; justify-content: center; margin: 34px 0 0; }
.hero-team .av { margin-left: -12px; border: 3px solid var(--bg); }
.section { max-width: 1100px; margin: 0 auto; padding: 40px 24px; }
.section > h2 { text-align: center; font-size: 30px; margin-bottom: 8px; }
.section > .lead { text-align: center; color: var(--muted); margin-bottom: 28px; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.steps .num { width: 34px; height: 34px; border-radius: 50%; background: var(--brand-soft); color: var(--brand); display: inline-flex; align-items: center; justify-content: center; font-weight: 800; margin-bottom: 10px; }
.auth { max-width: 420px; margin: 30px auto 60px; padding: 0 20px; }
.auth .card { padding: 26px; }
.auth h1 { font-size: 24px; }
.foot { text-align: center; color: var(--muted); font-size: 13px; padding: 30px 20px 40px; }

/* Phones */
@media (max-width: 860px) {
  .shell { display: block; }
  .side { position: fixed; inset: 0 auto 0 0; width: 270px; z-index: 40; transform: translateX(-105%); transition: transform .2s; box-shadow: var(--shadow); }
  .side.open { transform: none; }
  .topbar { display: flex; align-items: center; gap: 10px; padding: 10px 14px; background: var(--panel); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 30; }
  .topbar .logo { padding: 0; }
  .page { padding: 20px 16px 50px; }
  .cols, .grid2, .steps, .work-layout { grid-template-columns: 1fr; }
  .emp-head { padding: 16px 16px 0; }
  .chat-wrap { grid-template-columns: 1fr; height: calc(100vh - 190px); }
  .chat-list { display: none; }
  .msgs { padding: 16px; }
  .composer { padding: 10px 14px 14px; }
  .emp-body { padding: 18px 16px 50px; }
  .chat-page { height: calc(100dvh - 53px); }
  .emp-head .muted { font-size: 13px; }
  .hero h1 { font-size: 36px; }
  .when { grid-template-columns: 1fr 1fr; }
  .side-card { position: static; }
}
hr.sep { border: 0; border-top: 1px solid var(--line); margin: 12px 0; }
.page-head h1 { overflow-wrap: anywhere; }

/* ===== Marblism-style chat, work items and guidelines (13 Nov 2026) ===== */
.shell { grid-template-columns: 300px 1fr; }
.dm { align-items: flex-start !important; padding: 9px 10px !important; }
.dm .av { width: 38px; height: 38px; font-size: 16px; }
.dm-text { flex: 1; min-width: 0; display: block; line-height: 1.3; }
.dm-top { display: flex; align-items: baseline; gap: 6px; }
.dm-top small { color: var(--muted); font-size: 12px; font-weight: 400; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dm-top time { font-size: 11px; color: var(--muted); font-weight: 400; flex: none; }
.dm-last { display: block; font-size: 13px; color: var(--muted); font-weight: 400; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 2px; }
.dm.unread .dm-last { color: var(--ink); font-weight: 600; }
.nav a.dm .badge { margin-left: 6px; align-self: center; }
.saved { display: block; color: var(--ink); margin-bottom: 10px; }
.saved:hover { text-decoration: none; }
.saved strong { display: block; font-size: 24px; letter-spacing: -.02em; }
.saved span { font-size: 12px; color: var(--muted); }

.emp-page { display: flex; flex-direction: column; }
.emp-bar { display: flex; align-items: center; gap: 14px; padding: 8px 10px 8px 12px; margin: 12px auto 0; background: var(--panel); border: 1px solid var(--line); border-radius: 99px; box-shadow: var(--shadow); max-width: calc(100% - 32px); flex-wrap: wrap; position: relative; z-index: 2; }
.emp-id { display: flex; align-items: center; gap: 9px; line-height: 1.15; }
.emp-id small { display: block; color: var(--muted); font-size: 12px; }
.emp-tabs { display: flex; gap: 2px; overflow-x: auto; }
.emp-tabs a { padding: 6px 12px; border-radius: 99px; color: var(--muted); font-weight: 600; font-size: 14px; white-space: nowrap; }
.emp-tabs a:hover { color: var(--ink); background: var(--soft); text-decoration: none; }
.emp-tabs a.on { background: var(--soft); color: var(--ink); }
.chat-page .chat-main { flex: 1; min-height: 0; }
.msg.user { justify-content: flex-start; }
.msg .body { flex: 1; min-width: 0; }
.msg .who { display: flex; align-items: baseline; gap: 8px; margin-bottom: 2px; }
.msg .who .time { color: var(--muted); font-size: 12px; }
.msg .text { white-space: pre-wrap; }
.av-me { background: var(--brand); }
.day { text-align: center; margin: 18px 0 14px; position: relative; }
.day::before { content: ''; position: absolute; left: 0; right: 0; top: 50%; border-top: 1px solid var(--line); }
.day span { position: relative; background: var(--bg); padding: 0 12px; font-size: 12px; color: var(--muted); font-weight: 600; }
.status { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 14px; font-style: italic; margin-top: 6px; }
.status .spin { width: 14px; height: 14px; border-width: 2px; }
.cards { display: grid; gap: 8px; margin-top: 10px; max-width: 580px; }
.cards:empty { display: none; }
.wcard { display: flex; gap: 12px; align-items: center; padding: 10px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); color: var(--ink); }
.wcard:hover { border-color: var(--brand); text-decoration: none; }
.wcard img { width: 96px; height: 64px; object-fit: cover; border-radius: 8px; flex: none; }
.wcard.kind-social_post img { width: 64px; }
.wcard-ico { width: 64px; height: 64px; border-radius: 8px; background: var(--soft); display: flex; align-items: center; justify-content: center; font-size: 26px; flex: none; }
.wcard-body { flex: 1; min-width: 0; }
.wcard-kind { font-size: 11.5px; color: var(--muted); font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.wcard-title { font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wcard-prev { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wcard-open { font-size: 13px; color: var(--brand); font-weight: 600; flex: none; }
.plats { display: inline-flex; gap: 3px; vertical-align: middle; }
.plat { display: inline-flex; align-items: center; justify-content: center; min-width: 20px; height: 18px; padding: 0 4px; border-radius: 5px; font-size: 10px; font-weight: 800; color: #fff; text-transform: none; letter-spacing: 0; }
.plat-instagram { background: linear-gradient(135deg, #f58529, #dd2a7b, #8134af); }
.plat-facebook { background: #1877f2; } .plat-linkedin { background: #0a66c2; } .plat-tiktok { background: #111; } .plat-x { background: #000; }
details.sources summary { cursor: pointer; color: var(--muted); font-size: 13px; }
.composer { background: transparent; border-top: 0; padding: 8px 20px 12px; }
.chips { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 8px; }
.chips button { flex: none; border: 1px solid var(--line); background: var(--panel); color: var(--muted); border-radius: 99px; padding: 5px 12px; font: inherit; font-size: 13px; cursor: pointer; }
.chips button:hover { color: var(--ink); border-color: var(--muted); }
.input-row { display: flex; gap: 8px; align-items: flex-end; background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 6px 6px 6px 14px; box-shadow: var(--shadow); }
.input-row:focus-within { border-color: var(--brand); }
.input-row textarea { border: 0; padding: 8px 0; min-height: 0; max-height: 220px; background: transparent; resize: none; }
.input-row textarea:focus { outline: none; }
.send { width: 36px; height: 36px; border-radius: 50%; border: 0; background: var(--brand); color: var(--brand-ink); font-size: 18px; font-weight: 800; cursor: pointer; flex: none; }
.send:disabled { opacity: .4; cursor: default; }
.disclaimer { text-align: center; font-size: 11.5px; color: var(--muted); margin-top: 6px; }

.post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.post-tile { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; color: var(--ink); display: flex; flex-direction: column; }
.post-tile:hover { border-color: var(--brand); text-decoration: none; }
.post-tile img, .post-tile-blank { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; display: flex; align-items: center; justify-content: center; font-size: 34px; background: var(--soft); }
.post-tile-body { padding: 12px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.cal-nav { margin-bottom: 12px; }
.cal { display: grid; grid-template-columns: repeat(8, minmax(150px, 1fr)); gap: 8px; overflow-x: auto; padding-bottom: 8px; }
.cal-col { background: var(--soft); border-radius: 12px; padding: 8px; min-height: 320px; display: flex; flex-direction: column; gap: 8px; }
.cal-col.today { outline: 2px solid var(--brand); }
.cal-col.drafts { background: transparent; border: 1px dashed var(--line); }
.cal-head { font-size: 13px; font-weight: 700; color: var(--muted); text-align: center; padding: 2px 0 4px; }
.cal-post { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 8px; color: var(--ink); font-size: 12.5px; }
.cal-post:hover { border-color: var(--brand); text-decoration: none; }
.cal-post p { margin: 6px 0; line-height: 1.35; }
.cal-post img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 7px; display: block; }
.thumb { width: 54px; height: 40px; border-radius: 7px; object-fit: cover; flex: none; }
.thumb.ico { display: inline-flex; align-items: center; justify-content: center; background: var(--soft); font-size: 18px; }

.gl-section h3 { margin-bottom: 10px; }
.gl-list { margin: 0 0 10px; padding-left: 22px; }
.gl-list li { padding: 3px 0; }
.gl-list li span { margin-right: 6px; }
.gl-list li .btn { padding: 0 6px; }
.gl-ideas { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.gl-ideas button { border: 1px dashed var(--line); background: transparent; color: var(--muted); border-radius: 99px; padding: 5px 11px; font: inherit; font-size: 13px; cursor: pointer; }
.gl-ideas button:hover { color: var(--brand); border-color: var(--brand); }
.gl-section .row input { flex: 1; width: auto; }

.doc-page { display: flex; flex-direction: column; height: 100vh; height: 100dvh; }
.doc-top { display: flex; align-items: center; gap: 8px; padding: 10px 16px; border-bottom: 1px solid var(--line); background: var(--panel); flex-wrap: wrap; }
.doc-top-title { min-width: 0; line-height: 1.25; }
.doc-top-title strong { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 42vw; }
.doc-top-title small { color: var(--muted); font-size: 12px; }
.doc-scroll { flex: 1; overflow-y: auto; padding: 28px 20px 40px; }
.doc { max-width: 760px; margin: 0 auto; }
.doc-title { font-size: 34px; letter-spacing: -.02em; margin: 18px 0 12px; }
.doc-pic { position: relative; border-radius: 14px; overflow: hidden; background: var(--soft); }
.doc-pic img { width: 100%; display: block; }
.doc-pic.kind-social_post { max-width: 440px; }
.doc-pic-blank { aspect-ratio: 16 / 9; display: flex; align-items: center; justify-content: center; color: var(--muted); }
.pic-btn { position: absolute; top: 10px; right: 10px; opacity: .92; }
.doc-pic .working { position: absolute; left: 10px; bottom: 10px; margin: 0; padding: 10px 14px; }
.doc-facts { margin-bottom: 12px; }
.date-pick { font-weight: 500; display: inline-flex; align-items: center; gap: 4px; margin: 0; }
.date-pick input { width: auto; padding: 4px 8px; font-size: 14px; }
.meta-desc { background: var(--soft); border-radius: 10px; padding: 10px 12px; font-size: 14px; color: var(--muted); }
.doc-body { font-size: 16.5px; line-height: 1.7; }
.doc-edit textarea { min-height: 55vh; font: 14px/1.6 ui-monospace, SFMono-Regular, Menlo, monospace; }
.doc-title-input { font-size: 22px !important; font-weight: 700; margin: 14px 0 6px; }
.doc-ask { padding: 8px 20px 12px; border-top: 1px solid var(--line); background: var(--bg); }
.doc-ask-inner { max-width: 760px; margin: 0 auto; }
.doc-ask .about { font-size: 12px; color: var(--muted); margin-bottom: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
details.more { position: relative; }
details.more summary { list-style: none; }
details.more summary::-webkit-details-marker { display: none; }
.menu { position: absolute; right: 0; top: calc(100% + 6px); background: var(--panel); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); padding: 6px; min-width: 210px; z-index: 20; }
.menu button { display: block; width: 100%; text-align: left; border: 0; background: none; color: var(--ink); font: inherit; font-size: 14px; padding: 8px 10px; border-radius: 8px; cursor: pointer; }
.menu button:hover { background: var(--soft); }
.menu button.danger { color: var(--bad); }

@media (max-width: 860px) {
  .side { width: 300px; }
  .emp-bar { border-radius: 16px; margin-top: 10px; }
  .chat-page, .doc-page { height: calc(100dvh - 53px); }
  .cal { grid-template-columns: 1fr; }
  .cal-col { min-height: 0; }
  .doc-title { font-size: 26px; }
  .doc-top-title strong { max-width: 60vw; }
  .composer { padding: 6px 12px 10px; }
}
.av { overflow: hidden; }
.av img { width: 100%; height: 100%; object-fit: cover; display: block; }
.emp-tabs a { display: inline-flex; gap: 5px; }

/* ===== Looks, round 2 (13 Nov 2026): rail + messages panel, portraits, display type ===== */
:root { --display: "Avenir Next Condensed", "Avenir Next", "Helvetica Neue", "Arial Narrow", system-ui, sans-serif; }
@media (prefers-color-scheme: dark) {
  :root { --bg: #141416; --panel: #1c1c20; --soft: #26262c; --line: #2f2f37; --ink: #f1f0f5; --muted: #a09fae; }
}
h1, .doc-title, .hero h1, .section > h2, .stat strong, .member h3, .saved-num { font-family: var(--display); font-weight: 800; letter-spacing: -.01em; }
h1 { font-size: 32px; }
.av { border-radius: 30%; }
.av.sm { border-radius: 30%; }

/* Rail + panel */
.shell { grid-template-columns: 372px 1fr; }
.side { display: grid; grid-template-columns: 72px 1fr; padding: 0; border-right: 1px solid var(--line); background: var(--panel); }
.rail { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 14px 0; border-right: 1px solid var(--line); background: var(--bg); height: 100vh; position: sticky; top: 0; }
.rail-logo img { width: 36px; height: 36px; display: block; margin-bottom: 12px; }
.rail-link { position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px; width: 60px; padding: 8px 0 6px; border-radius: 12px; color: var(--muted); }
.rail-link:hover { background: var(--soft); color: var(--ink); text-decoration: none; }
.rail-link.on { background: var(--brand-soft); color: var(--brand); }
.rail-link .ico { font-size: 19px; line-height: 1; }
.rail-link small { font-size: 10.5px; font-weight: 600; }
.rail-link .dot { position: absolute; top: 3px; right: 8px; background: var(--bad); color: #fff; font-size: 10px; font-weight: 800; min-width: 17px; height: 17px; border-radius: 9px; display: flex; align-items: center; justify-content: center; padding: 0 4px; }
.rail .spacer { flex: 1; }
.panel { display: flex; flex-direction: column; min-height: 0; height: 100vh; position: sticky; top: 0; padding: 14px 10px 12px; overflow: hidden; }
.panel-head { padding: 4px 8px 6px; line-height: 1.2; }
.panel-head strong { display: block; font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.panel-head small { color: var(--muted); font-size: 12px; }
.nav.dms { flex: 1; overflow-y: auto; margin: 0 -4px; padding: 0 4px; }
.dm .av { width: 44px; height: 44px; }
.dm-top strong { font-size: 14px; }
.saved { margin-top: 10px; padding: 14px; border-radius: 14px; background: linear-gradient(135deg, var(--brand-soft), transparent 70%), var(--soft); display: grid; gap: 2px; }
.saved-num { font-size: 26px; line-height: 1; }
.saved-sub { font-size: 12px; color: var(--muted); }
.saved-meta { font-size: 11.5px; color: var(--muted); margin-top: 6px; }
.saved .meter { display: block; }

/* Profile popover on a team member's page */
details.profile { position: relative; }
details.profile summary { list-style: none; cursor: pointer; border-radius: 99px; padding: 2px 8px 2px 2px; }
details.profile summary::-webkit-details-marker { display: none; }
details.profile summary:hover { background: var(--soft); }
.profile-card { position: absolute; top: calc(100% + 10px); left: 0; width: 300px; background: var(--panel); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); padding: 20px; z-index: 30; text-align: center; }
.profile-card .av { margin: 0 auto 10px; }
.profile-card h3 { margin: 0; font-size: 20px; }
.profile-card p { margin: 10px 0; font-size: 14px; }
.facts { display: flex; flex-wrap: wrap; gap: 6px; }
.profile-card .facts { justify-content: center; }
.facts span { font-size: 12px; padding: 3px 9px; border-radius: 99px; background: var(--soft); color: var(--muted); font-weight: 600; }

/* Team cards */
.team-grid { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.member { gap: 10px; }
.member-top { display: flex; gap: 14px; align-items: center; }
.member-top .av.xl { width: 76px; height: 76px; }
.member h3 { margin: 0; font-size: 22px; }
.member p { color: var(--muted); }
.member-cta { color: var(--brand); font-weight: 600; }

/* Home stats */
.stats { display: grid; grid-template-columns: 1fr 1fr 1.4fr; gap: 14px; margin-bottom: 16px; }
.stats .card + .card { margin-top: 0; }
.stat { display: flex; flex-direction: column; gap: 2px; }
.stat small { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.stat strong { font-size: 34px; line-height: 1.05; }
.eotm { flex-direction: row; align-items: center; gap: 14px; color: var(--ink); background: linear-gradient(135deg, rgba(255, 196, 0, .16), transparent 65%), var(--panel); border-color: rgba(255, 196, 0, .45); }
.eotm:hover { text-decoration: none; border-color: #ffc400; }
.eotm small { color: #c99a00; }
.eotm strong { font-size: 26px; }

/* Landing */
.hero { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; text-align: left; padding-top: 40px; }
.hero h1 { margin: 0 0 18px; font-size: 60px; line-height: 1; }
.hero .lead { margin: 0 0 26px; }
.eyebrow { display: inline-block; font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--brand); background: var(--brand-soft); padding: 5px 10px; border-radius: 99px; margin-bottom: 16px; }
.hero-team { justify-content: flex-start; align-items: center; gap: 0; margin-top: 30px; flex-wrap: wrap; }
.hero-team .av { margin-left: -10px; border: 3px solid var(--bg); width: 56px; height: 56px; }
.hero-team .av:first-child { margin-left: 0; }
.hero-team .muted { margin-left: 12px; }
.hero-demo { background: var(--panel); border: 1px solid var(--line); border-radius: 20px; box-shadow: 0 20px 60px rgba(20, 16, 40, .18); padding: 16px 18px 6px; }
.hero-demo .msg { margin-bottom: 16px; font-size: 14.5px; }
.demo-bar { display: flex; gap: 6px; margin-bottom: 14px; }
.demo-bar span { width: 10px; height: 10px; border-radius: 50%; background: var(--line); }
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.features .card + .card { margin-top: 0; }
.feature-ico { font-size: 26px; display: block; margin-bottom: 8px; }
.cta { text-align: center; }
.section > h2 { font-size: 38px; }

/* Integrations */
.int-bar { display: flex; gap: 12px; align-items: center; margin-bottom: 16px; flex-wrap: wrap; }
.int-bar input { max-width: 420px; }
.pillbtn { border: 1px solid var(--line); background: var(--panel); color: var(--muted); font: inherit; font-weight: 600; font-size: 14px; padding: 6px 14px; border-radius: 99px; cursor: pointer; }
.pillbtn.on { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.int-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-items: start; }
.int-grid .card + .card { margin-top: 0; }
.int-head { display: flex; gap: 14px; align-items: flex-start; }
.int-head p { margin: 2px 0 0; font-size: 13.5px; color: var(--muted); }
.int-icon { width: 44px; height: 44px; border-radius: 12px; display: flex; align-items: center; justify-content: center; font-weight: 900; font-size: 20px; color: #fff; background: var(--soft); flex: none; }
.int-wordpress { background: #21759b; } .int-slack { background: #4a154b; } .int-discord { background: #5865f2; } .int-zapier { background: #ff4f00; }
.int-meta { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); display: grid; gap: 8px; }
.int-form { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.int-form .hint { margin: 0 0 8px; }
.int-card.open { border-color: var(--brand); }

/* One-click share bar on a piece of work */
.share { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 18px; padding: 10px; border-radius: 12px; background: var(--soft); }

@media (max-width: 1100px) {
  .stats { grid-template-columns: 1fr 1fr; }
  .stats .eotm { grid-column: 1 / -1; }
}
@media (max-width: 860px) {
  .side { width: 340px; display: grid; }
  .rail, .panel { height: 100dvh; }
  .hero { grid-template-columns: 1fr; text-align: left; }
  .hero h1 { font-size: 40px; }
  .features, .int-grid, .stats { grid-template-columns: 1fr; }
  .profile-card { width: min(300px, calc(100vw - 40px)); }
}
.eotm > div { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
input[type=search] { width: 100%; font: inherit; color: var(--ink); background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 9px 12px; }
input[type=search]:focus { outline: 2px solid var(--brand); outline-offset: -1px; border-color: transparent; }
.int-bar .spacer { min-width: 220px; }
.int-email { background: #ea4335; } .int-telegram { background: #229ed9; } .int-google_chat { background: #00ac47; } .int-teams { background: #5059c9; } .int-notion { background: #111; } .int-ghost { background: #15171a; }
.tg-code .code { font: 800 28px/1 ui-monospace, Menlo, monospace; letter-spacing: .2em; padding: 10px 14px; background: var(--soft); border-radius: 10px; justify-self: start; }
.send-form { margin: -8px 0 18px; }

/* Inbox */
.inbox-empty { text-align: center; padding: 36px 20px; }
.inbox-empty .av { margin: 0 auto 12px; }
.inbox-empty p { max-width: 560px; margin: 0 auto 18px; }
.card.inbox { padding: 6px 10px; }
.list li.mail { display: block; padding: 0; }
.mail-head { display: flex; gap: 12px; align-items: flex-start; width: 100%; padding: 12px 6px; background: none; border: 0; color: var(--ink); font: inherit; text-align: left; cursor: pointer; border-radius: 10px; }
.mail-head:hover { background: var(--soft); }
.mail-dot { width: 8px; height: 8px; border-radius: 50%; margin-top: 7px; flex: none; background: transparent; }
.mail.high .mail-dot { background: var(--bad); }
.mail-main { flex: 1; min-width: 0; display: grid; gap: 1px; }
.mail-top { display: flex; gap: 8px; align-items: baseline; }
.mail-top time { color: var(--muted); font-size: 12px; flex: none; }
.mail-subject { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mail-summary { color: var(--muted); font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mail.done .mail-subject, .mail.done strong { color: var(--muted); }
.mail-body { padding: 0 6px 16px 26px; display: grid; gap: 10px; }
.mail-text { white-space: pre-wrap; background: var(--soft); border-radius: 10px; padding: 12px 14px; font-size: 14.5px; max-height: 360px; overflow-y: auto; overflow-wrap: anywhere; }

/* Hiring */
.av-plus { background: var(--soft); color: var(--muted); font-weight: 400; }
.dm.hire .av { width: 44px; height: 44px; font-size: 22px; }
.dm.hire strong { font-size: 14px; }
.hire-card { align-items: flex-start; border-style: dashed; }
.hire-card .av { margin-bottom: 4px; font-size: 34px; }
.hire-ideas { display: flex; flex-wrap: wrap; gap: 6px; margin: -4px 0 16px; }
.hire-ideas button { border: 1px solid var(--line); background: var(--panel); color: var(--ink); border-radius: 99px; padding: 6px 12px; font: inherit; font-size: 13.5px; cursor: pointer; }
.hire-ideas button:hover { border-color: var(--brand); color: var(--brand); }
.hire-top { display: flex; gap: 18px; align-items: flex-start; }
.hire-top .av { width: 96px; height: 96px; font-size: 40px; }
.profile-actions { margin-top: 12px; }
.notice.archived { margin: 12px 20px 0; }
@media (max-width: 860px) { .hire-top { flex-direction: column; } }

/* Attachments, voice, hand-offs, triggers, library */
.icon-btn { width: 36px; height: 36px; border-radius: 50%; border: 0; background: transparent; font-size: 17px; cursor: pointer; flex: none; color: var(--muted); }
.icon-btn:hover { background: var(--soft); }
.icon-btn.on { background: var(--bad-soft); animation: pulse 1.2s infinite; }
@keyframes pulse { 50% { opacity: .55; } }
.input-row { padding-left: 6px; }
.attach-row { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 6px; }
.attach-chip { display: inline-flex; align-items: center; gap: 6px; background: var(--soft); border-radius: 10px; padding: 4px 6px 4px 4px; font-size: 13px; max-width: 240px; }
.attach-chip img { width: 28px; height: 28px; object-fit: cover; border-radius: 6px; }
.attach-chip button { border: 0; background: none; color: var(--muted); cursor: pointer; }
.msg-files { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 6px; }
.msg-files:empty { display: none; }
.msg-files img { max-width: 220px; max-height: 160px; border-radius: 10px; display: block; }
.file-chip { background: var(--soft); border-radius: 8px; padding: 4px 10px; font-size: 13px; color: var(--ink); }
.handoff-form { margin: -8px 0 18px; }
.trigger-box { background: var(--soft); border-radius: 10px; padding: 12px !important; }
.trigger-box .hint { margin: 4px 0 8px; }
.btn.on { border-color: var(--brand); color: var(--brand); }
.list.lib select { width: auto; max-width: 160px; padding: 6px 8px; font-size: 13px; }

/* Onboarding panel */
details.onboard { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 12px 14px; margin: 4px 0 18px; box-shadow: var(--shadow); }
details.onboard summary { display: flex; align-items: center; gap: 10px; cursor: pointer; list-style: none; }
details.onboard summary::-webkit-details-marker { display: none; }
details.onboard summary small { display: block; color: var(--muted); font-size: 12px; }
details.onboard .meter { width: 90px; flex: none; }
details.onboard.complete { border-color: var(--ok); }
.onboard-tip { margin: 12px 0 8px; font-size: 14px; background: var(--soft); border-radius: 10px; padding: 10px 12px; }
.onboard-steps { list-style: none; margin: 0; padding: 0; }
.onboard-steps li { display: flex; align-items: center; gap: 10px; padding: 8px 2px; border-top: 1px solid var(--line); font-size: 14.5px; }
.onboard-steps li:first-child { border-top: 0; }
.onboard-steps .tick { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--line); display: inline-flex; align-items: center; justify-content: center; font-size: 12px; flex: none; }
.onboard-steps li.done .tick { background: var(--ok); border-color: var(--ok); color: #fff; }
.onboard-steps li.done .grow { color: var(--muted); text-decoration: line-through; }

/* Rooms */
.stack { display: inline-flex; flex: none; }
.stack .av { border: 2px solid var(--panel); margin-left: -10px; }
.stack .av:first-child { margin-left: 0; }
.dm.room .stack .av { width: 26px; height: 26px; font-size: 11px; }
.dm.room .stack { width: 44px; flex-wrap: wrap; }
.stack.big { justify-content: center; margin-bottom: 12px; }
.stack.big .av { width: 64px; height: 64px; }
.room-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; }
.room-person { display: flex; align-items: center; gap: 10px; border: 1px solid var(--line); border-radius: 12px; padding: 8px 10px; cursor: pointer; font-weight: 500; margin: 0; }
.room-person.on { border-color: var(--brand); background: var(--brand-soft); }
.room-person input { accent-color: var(--brand); }
.room-person small { display: block; color: var(--muted); font-size: 12px; font-weight: 400; }
.room-ideas { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 14px; }
.room-ideas button { border: 1px dashed var(--line); background: transparent; color: var(--ink); border-radius: 99px; padding: 6px 12px; font: inherit; font-size: 13.5px; cursor: pointer; }
.room-ideas button:hover { border-color: var(--brand); color: var(--brand); }

/* Quick tools */
.tool-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px; }
.tool-grid .card + .card { margin-top: 0; }
.card.tool { display: flex; flex-direction: column; gap: 6px; }
.card.tool p { margin: 0; flex: 1; }
.card.tool .btn { align-self: flex-start; }
.tool-ico { font-size: 20px; }
.tool-form { margin-top: 6px; }
.quick-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px; }
.quick-row .tool-grid { display: contents; }

/* Search */
.panel-search { padding: 2px 4px 6px; }
.panel-search input { padding: 7px 10px; font-size: 13.5px; border-radius: 9px; }
.search-form { margin-bottom: 16px; }
mark { background: rgba(255, 196, 0, .35); color: inherit; border-radius: 3px; padding: 0 2px; }
.int-grid.read-only .int-head .btn, .int-grid.read-only .int-meta .row { display: none; }
.meet-text { margin-top: 12px; }
.pic-edit { margin: 10px 0 4px; }
.autopilot { margin-bottom: 16px; } .autopilot .check { margin: 8px 0; }

/* Calendar */
.cal-title { min-width: 140px; text-align: center; }
.legend { margin-bottom: 10px; gap: 12px; }
.month { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.cal-dow { font-size: 12px; font-weight: 700; color: var(--muted); text-align: center; text-transform: uppercase; letter-spacing: .05em; }
.cal-day { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; min-height: 104px; padding: 6px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.cal-day.empty { background: transparent; border: 0; }
.cal-day.past { opacity: .6; }
.cal-day.today { outline: 2px solid var(--brand); }
.cal-num { font-size: 12px; font-weight: 700; color: var(--muted); }
.cal-item { display: flex; align-items: center; gap: 4px; font-size: 11.5px; line-height: 1.25; padding: 2px 4px; border-radius: 6px; color: var(--ink); min-width: 0; }
.cal-item span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal-item .av.sm { width: 16px; height: 16px; font-size: 8px; }
.cal-item.work { background: var(--brand-soft); }
.cal-item.task { background: var(--soft); }
.cal-item:hover { text-decoration: none; filter: brightness(.95); }
@media (max-width: 860px) { .month { grid-template-columns: 1fr; } .cal-dow, .cal-day.empty { display: none; } .cal-day { min-height: 0; } }

.bulk-bar { padding-bottom: 8px; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.list li .pick { width: 17px; height: 17px; accent-color: var(--brand); flex: none; }

/* Printing a piece of work: just the document */
@media print {
  .side, .topbar, .doc-top, .doc-ask, .share, .pic-btn, .pic-edit, .handoff-form, .send-form, .toasts, .sources { display: none !important; }
  .shell { display: block; }
  body, .doc-page, .doc-scroll { background: #fff !important; color: #000 !important; height: auto !important; overflow: visible !important; }
  .doc-scroll { padding: 0; }
  .doc { max-width: none; }
  .md a { color: #000; }
}

/* Admin */
.wide-page { max-width: 1300px; }
.admin-stats { grid-template-columns: repeat(4, 1fr); }
.table-card { overflow-x: auto; padding: 6px; }
.admin-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.admin-table th { text-align: left; font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; padding: 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.admin-table td { padding: 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.admin-table tr.paused td { opacity: .55; }
@media (max-width: 860px) { .admin-stats { grid-template-columns: 1fr 1fr; } }

details.rules summary { cursor: pointer; list-style: none; }
details.rules summary::-webkit-details-marker { display: none; }
.rule-form { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.when3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 12px; }
.history { margin-bottom: 16px; }
@media (max-width: 860px) { .when3 { grid-template-columns: 1fr; } }

/* Website (Wren) */
.designs { display: flex; gap: 8px; flex-wrap: wrap; margin: 6px 0 14px; }
.design { border: 2px solid var(--line); border-radius: 12px; padding: 10px 14px; text-align: left; cursor: pointer; background: var(--panel); color: var(--ink); font: inherit; min-width: 150px; }
.design small { display: block; color: var(--muted); font-size: 12px; }
.design.on { border-color: var(--brand); }
.design.d-bold { background: #16161a; color: #fff; } .design.d-bold small { color: #aaa; }
.design.d-warm { background: #fdf0de; color: #4a3520; } .design.d-warm small { color: #8a6a4a; }
.site-bar { margin-bottom: 12px; }
.site-ask { margin: 12px 0; }
.site-tools .designs { margin: 0; }
.site-tools .design { min-width: 0; padding: 6px 10px; }
.slug-form input { width: 160px; padding: 6px 8px; font-size: 13px; }
.site-frame { width: 100%; height: 70vh; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.vm { padding: 4px 0; font-size: 14px; } .vm.iris strong { color: var(--brand); }
.domain-box { margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--line); }
.domain-box summary { cursor: pointer; font-weight: 600; list-style: none; }
.domain-box summary::-webkit-details-marker { display: none; }
.domain-box form { margin: 10px 0; }
.dns { display: flex; gap: 18px; flex-wrap: wrap; margin: 8px 0; font-family: ui-monospace, Menlo, monospace; font-size: 13.5px; }

/* Manual light/dark choice (Account → Appearance) beats the device setting */
:root[data-theme="light"] { --bg: #f6f5f1; --panel: #ffffff; --ink: #1c1a24; --muted: #6b6878; --line: #e6e3dc; --soft: #efede7; --brand: #5b4bdb; --brand-ink: #ffffff; --brand-soft: #ece9ff; --ok: #1f8a5b; --ok-soft: #e3f5ec; --warn: #b26b00; --warn-soft: #fff3dc; --bad: #c0392b; --bad-soft: #fde8e6; --shadow: 0 1px 2px rgba(20, 16, 40, .06), 0 4px 16px rgba(20, 16, 40, .05); color-scheme: light; }
:root[data-theme="dark"] { --bg: #141416; --panel: #1c1c20; --ink: #f1f0f5; --muted: #a09fae; --line: #2f2f37; --soft: #26262c; --brand: #8b7dff; --brand-ink: #14131a; --brand-soft: #2b2650; --ok: #4cc38a; --ok-soft: #173327; --warn: #f0b04a; --warn-soft: #3a2c12; --bad: #ff7b6e; --bad-soft: #3d1c19; --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 4px 16px rgba(0, 0, 0, .25); color-scheme: dark; }
.contact-history { margin-top: 12px; display: grid; gap: 4px; }

/* Business switcher */
.biz-switch { position: relative; }
.biz-switch summary { list-style: none; display: flex; align-items: center; gap: 6px; cursor: pointer; border-radius: 10px; padding: 4px 6px; margin: -4px -6px; }
.biz-switch summary::-webkit-details-marker { display: none; }
.biz-switch summary:hover { background: var(--soft); }
.biz-switch .caret { color: var(--muted); font-size: 12px; }
.biz-menu { position: absolute; left: 0; right: 0; top: calc(100% + 6px); background: var(--panel); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); padding: 6px; z-index: 40; }
.biz-menu button, .biz-add { display: flex; align-items: center; gap: 8px; width: 100%; text-align: left; border: 0; background: none; color: var(--ink); font: inherit; font-size: 14px; padding: 8px; border-radius: 8px; cursor: pointer; }
.biz-menu button:hover, .biz-add:hover { background: var(--soft); text-decoration: none; }
.biz-menu button.on { font-weight: 700; }
.biz-menu small { display: block; color: var(--muted); font-size: 11px; font-weight: 400; }
.biz-dot { width: 26px; height: 26px; border-radius: 8px; background: var(--brand-soft); color: var(--brand); display: inline-flex; align-items: center; justify-content: center; font-weight: 800; flex: none; }
.biz-add { color: var(--brand); font-weight: 600; border-top: 1px solid var(--line); border-radius: 0 0 8px 8px; margin-top: 4px; }
