/* Se7ti Admin — the apps' look: a green hero, a soft page with a green tint, white floating
   cards with big corners, and a floating bar for the pages (a rail here, the bottom bar on phones). */
:root {
  --green: #4CAF50;
  --green-deep: #2E7D32;
  --green-dark: #1B5E20;
  --green-light: #78DC77;
  --green-soft: #E8F5E9;
  --teal: #26A69A;
  --blue: #3B82F6;
  --purple: #A855F7;
  --orange: #FB923C;
  --amber: #F59E0B;
  --amber-ink: #B45309;
  --red: #FF5252;
  --slate: #64748B;
  --ink: #0F172A;
  --ink2: #434940;
  --muted: #6B7168;
  --line: #E2E5ED;
  --track: #EEF1EE;
  --page: #F7F8F7;
  --card: #FFFFFF;
  --shadow: 0 10px 30px rgba(46, 125, 50, .08), 0 2px 6px rgba(15, 23, 42, .04);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", Roboto, "Segoe UI", "Noto Sans Arabic", sans-serif;
  color: var(--ink);
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; background:
  radial-gradient(900px 420px at 18% -8%, rgba(76, 175, 80, .16), transparent 70%),
  radial-gradient(700px 380px at 96% 0%, rgba(38, 166, 154, .10), transparent 70%), var(--page);
  background-attachment: fixed; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
code { background: var(--track); padding: 1px 6px; border-radius: 6px; font-size: .9em; }
.hidden { display: none !important; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.error { color: #D32F2F; font-size: 14px; min-height: 1em; }
svg.i { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; flex: none; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: 24px; box-shadow: var(--shadow); padding: 18px 20px; min-width: 0; }
.card h3 { margin: 0; font-size: 16px; letter-spacing: -.1px; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.row { display: flex; align-items: center; gap: 12px; }
.row.wrap { flex-wrap: wrap; }
.row.wrap input { flex: 1; min-width: 200px; }
.label { font-size: 11px; font-weight: 700; letter-spacing: 1.4px; text-transform: uppercase; color: var(--muted); }
.head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; flex-wrap: wrap; }
.head .sub { color: var(--muted); font-size: 12.5px; }
.head .more { margin-inline-start: auto; border: 0; font-size: 12.5px; font-weight: 600; color: var(--green-deep); background: var(--green-soft); padding: 5px 11px; border-radius: 999px; }
.head .more:hover { background: #D7EEDA; }

.btn { border: 1px solid var(--line); background: #fff; border-radius: 14px; padding: 11px 16px; font-weight: 600; white-space: nowrap; }
.btn:hover { border-color: #cfd5cc; }
.btn.primary { background: linear-gradient(135deg, var(--green), var(--green-deep)); border-color: transparent; color: #fff; box-shadow: 0 8px 18px rgba(76, 175, 80, .30); }
.btn.primary:hover { filter: brightness(.96); }
.btn.ghost { background: transparent; border-color: transparent; color: var(--muted); }
.btn.wide { width: 100%; }
.btn.small { padding: 6px 10px; font-size: 12px; flex: none; border-radius: 10px; }
.btn.danger { color: #D32F2F; }
.btn:disabled { opacity: .5; cursor: default; }

input, select, textarea { border: 1px solid var(--line); border-radius: 14px; padding: 11px 14px; background: #fff; outline: none; width: 100%; }
input:focus, textarea:focus, select:focus { border-color: var(--green); box-shadow: 0 0 0 3px rgba(76, 175, 80, .14); }
label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; color: var(--muted); }
label input, label select { font-weight: 400; font-size: 15px; color: var(--ink); }

.brand { display: flex; align-items: center; gap: 12px; }
.brand img { width: 44px; height: 44px; border-radius: 14px; box-shadow: 0 6px 16px rgba(0, 0, 0, .22); flex: none; }
.brand b { display: block; font-size: 17px; letter-spacing: -.2px; }
.brand small { color: var(--muted); font-size: 12px; }
.logo { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; color: #fff; font-weight: 800; flex: none; }
.logo.warn { background: linear-gradient(135deg, #FBBF24, #EA580C); }

/* Sign in */
.center { min-height: 100vh; display: grid; place-items: center; padding: 16px; }
.signin-card { width: min(410px, 100%); display: flex; flex-direction: column; gap: 14px; padding: 26px; border-radius: 28px; }
.signin-card .brand img { width: 56px; height: 56px; border-radius: 17px; }
.or { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 12px; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }

/* The shell: a floating rail and the page */
#app { display: grid; grid-template-columns: 248px 1fr; gap: 20px; padding: 20px; max-width: 1480px; margin: 0 auto; }
#app > * { min-width: 0; }
.rail { position: sticky; top: 20px; height: calc(100vh - 40px); background: rgba(255, 255, 255, .86); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  border: 1px solid var(--line); border-radius: 28px; box-shadow: var(--shadow); padding: 18px 14px; display: flex; flex-direction: column; gap: 18px; }
.rail .brand { padding: 2px 6px; }
.rail .label { padding: 0 12px; }
nav { display: flex; flex-direction: column; gap: 4px; }
.nav { display: flex; align-items: center; gap: 12px; border: 0; background: transparent; padding: 11px 12px; border-radius: 16px; font-weight: 600; font-size: 14.5px; color: var(--ink2); text-align: start; }
.nav:hover { background: rgba(76, 175, 80, .08); }
.nav.active, .nav.active:hover { background: linear-gradient(135deg, var(--green), var(--green-deep)); color: #fff; box-shadow: 0 8px 18px rgba(76, 175, 80, .35); }
.nav em { margin-inline-start: auto; font-style: normal; font-size: 11px; font-weight: 700; background: var(--red); color: #fff; border-radius: 999px; padding: 2px 8px; }
.nav em:empty { display: none; }
.me { margin-top: auto; display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 18px; background: var(--green-soft); }
.me > div { min-width: 0; flex: 1; }
.me b { font-size: 13.5px; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.me small { font-size: 11.5px; color: var(--muted); display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.me .out { border: 0; background: #fff; width: 34px; height: 34px; border-radius: 12px; display: grid; place-items: center; color: var(--ink2); flex: none; }
.me .out:hover { color: #D32F2F; }
.avatar { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-weight: 700; text-transform: uppercase;
  background: linear-gradient(135deg, var(--green-light), var(--green-deep)); border: 2px solid #fff; flex: none; }

main.view { display: flex; flex-direction: column; gap: 18px; min-width: 0; padding-bottom: 30px; }
.pagehead h2 { margin: 6px 0 4px; font-size: 26px; letter-spacing: -.4px; }
.pagehead p { margin: 0; color: var(--muted); max-width: 760px; }
.narrow { max-width: 780px; }

/* The hero, as on the app's Home */
.hero { position: relative; overflow: hidden; border-radius: 28px; padding: 26px 28px; color: #fff;
  background: linear-gradient(120deg, var(--green-dark) 0%, var(--green-deep) 45%, var(--green) 100%); box-shadow: 0 18px 40px rgba(46, 125, 50, .28); }
.hero::before, .hero::after { content: ""; position: absolute; border-radius: 50%; background: rgba(255, 255, 255, .09); pointer-events: none; }
.hero::before { width: 380px; height: 380px; right: -90px; top: -190px; }
.hero::after { width: 300px; height: 300px; right: 190px; bottom: -220px; }
.hero > * { position: relative; }
.hero .top { display: flex; align-items: center; gap: 16px; }
.hero small { opacity: .85; font-size: 14px; }
.hero h1 { margin: 2px 0 0; font-size: 30px; letter-spacing: -.5px; }
.hero .avatar { width: 56px; height: 56px; font-size: 20px; }
.hero .round { margin-inline-start: auto; width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: rgba(255, 255, 255, .16); border: 1px solid rgba(255, 255, 255, .3); }
.hero .round:hover { background: rgba(255, 255, 255, .26); }
.hero .round.busy svg { animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.glasses { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.glass { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px; font-size: 13px; font-weight: 600; color: #fff;
  background: rgba(255, 255, 255, .16); border: 1px solid rgba(255, 255, 255, .28); }
button.glass:hover { background: rgba(255, 255, 255, .26); }
.glass i { width: 8px; height: 8px; border-radius: 50%; background: var(--green-light); }
.glass i.warn { background: #FFD54F; }

/* Numbers */
.kpis { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.kpis.four { grid-template-columns: repeat(4, 1fr); }
.kpis.five { grid-template-columns: repeat(5, 1fr); }
.kpi { padding: 16px; display: flex; flex-direction: column; gap: 8px; text-align: start; font: inherit; color: inherit; }
button.kpi:hover { box-shadow: 0 14px 34px rgba(46, 125, 50, .14), 0 2px 6px rgba(15, 23, 42, .05); }
.kpi .top { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.kpi .ico { width: 38px; height: 38px; border-radius: 13px; display: grid; place-items: center; flex: none; }
.kpi b { font-size: 28px; letter-spacing: -.6px; line-height: 1.05; }
.kpi > span { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.kpi.alert b { color: #E53935; }
.delta { font-size: 11.5px; font-weight: 700; padding: 3px 8px; border-radius: 999px; background: var(--green-soft); color: var(--green-deep); white-space: nowrap; }
.delta.down { background: #FFF1F0; color: #D32F2F; }
.delta.flat { background: #F0F2F5; color: var(--muted); }
.spark { width: 100%; height: 30px; display: block; margin-top: auto; }
.t-green { background: var(--green-soft); color: var(--green-deep); }
.t-blue { background: #EAF2FF; color: var(--blue); }
.t-purple { background: #F5EAFF; color: var(--purple); }
.t-orange { background: #FFF2E5; color: #E06B10; }
.t-teal { background: #E0F2F1; color: #00897B; }
.t-red { background: #FFECEC; color: #E53935; }
.t-slate { background: #EEF1F5; color: var(--slate); }

.grid2 { display: grid; grid-template-columns: 1.7fr 1fr; gap: 18px; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 18px; }
.legend { display: flex; gap: 14px; font-size: 12.5px; color: var(--muted); font-weight: 600; margin-inline-start: auto; }
.legend i { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-inline-end: 6px; }
.chart { width: 100%; height: 210px; display: block; }
.chart.short { height: 130px; }
.axis { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); margin-top: 4px; }
.emptyline { color: var(--muted); font-size: 13px; padding: 6px 0; }

.mini { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 12px; }
.mini.four { grid-template-columns: repeat(4, 1fr); }
.mini div { background: var(--page); border-radius: 14px; padding: 10px 12px; min-width: 0; }
.mini b { display: block; font-size: 18px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini small { font-size: 11px; color: var(--muted); }

.donut { display: flex; align-items: center; gap: 18px; }
.donut svg { width: 116px; height: 116px; flex: none; }
.keys { display: flex; flex-direction: column; gap: 9px; flex: 1; min-width: 0; }
.key { display: flex; align-items: center; gap: 8px; font-size: 13.5px; min-width: 0; }
.key i { width: 10px; height: 10px; border-radius: 4px; flex: none; }
.key span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.key b { margin-inline-start: auto; }
.key em { font-style: normal; color: var(--muted); font-size: 12px; width: 38px; text-align: end; flex: none; }
.rings { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; text-align: center; }
.rings svg { width: 82px; height: 82px; }
.rings b { display: block; font-size: 13px; margin-top: 4px; }
.rings small { color: var(--muted); font-size: 11.5px; }
.note { display: flex; gap: 10px; align-items: flex-start; background: #FFF8E1; color: #7A5200; border-radius: 16px; padding: 10px 12px; font-size: 12.5px; margin-top: 12px; }
.note.calm { background: var(--green-soft); color: var(--green-dark); }
.note svg.i { width: 18px; height: 18px; }

.bars { display: flex; flex-direction: column; gap: 11px; margin-top: 4px; }
.bar { display: grid; grid-template-columns: minmax(90px, 36%) 1fr auto; gap: 10px; align-items: center; font-size: 13.5px; }
.bar span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar div { height: 9px; border-radius: 6px; background: var(--track); overflow: hidden; }
.bar div i { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--green), var(--teal)); min-width: 3px; }
.bar em { font-style: normal; color: var(--muted); font-size: 12.5px; text-align: end; white-space: nowrap; }
.bar.rest span, .bar.rest em { color: var(--muted); }
.bar.rest div i { background: var(--line); }
.triple { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.triple .bars { margin-top: 10px; }

.rows { display: flex; flex-direction: column; }
.rows > .line { display: flex; align-items: center; gap: 12px; padding: 11px 0; border-top: 1px solid var(--line); font-size: 14px; min-width: 0; }
.rows > .line:first-child { border-top: 0; }
.rows .line > div { flex: 1; min-width: 0; }
.rows .line b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rows .line small { color: var(--muted); display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rows .line span.value { color: var(--ink); font-weight: 600; text-align: end; }
.rows .line.link { cursor: pointer; }
.rows .line .sq { width: 36px; height: 36px; border-radius: 12px; display: grid; place-items: center; flex: none; }
.tag { font-size: 11px; font-weight: 700; border-radius: 999px; padding: 3px 9px; color: var(--green-deep); background: var(--green-soft); flex: none; }
.tag.warn { color: #B45309; background: rgba(245, 158, 11, .16); }

/* Tickets */
#inbox { display: grid; grid-template-columns: minmax(300px, 400px) 1fr; gap: 18px; height: calc(100vh - 40px); padding-bottom: 0; position: sticky; top: 20px; }
#inbox > * { min-width: 0; }
.list-pane, .detail-pane { background: var(--card); border: 1px solid var(--line); border-radius: 24px; box-shadow: var(--shadow); display: flex; flex-direction: column; min-height: 0; overflow: hidden; }
.toolbar { padding: 16px; display: flex; flex-direction: column; gap: 10px; border-bottom: 1px solid var(--line); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 6px 12px; font-size: 13px; font-weight: 600; color: var(--muted); }
.chip.active { background: var(--green); border-color: var(--green); color: #fff; }
.list { overflow-y: auto; padding: 12px; display: flex; flex-direction: column; gap: 10px; }
.item { background: #fff; border-radius: 18px; padding: 14px; cursor: pointer; border: 1.5px solid var(--line); display: flex; flex-direction: column; gap: 6px; }
.item:hover { border-color: #cfd5cc; }
.item.active { border-color: var(--green); background: #FAFDFA; box-shadow: 0 6px 16px rgba(76, 175, 80, .14); }
.item .top { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.item .num { font-weight: 800; color: var(--slate); }
.item .subject { font-weight: 700; font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.item .last { font-size: 13px; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.item .foot { display: flex; justify-content: space-between; font-size: 11px; color: var(--slate); }
.dot { width: 9px; height: 9px; border-radius: 50%; background: var(--red); display: inline-block; }
.pill { font-size: 11px; font-weight: 700; border-radius: 999px; padding: 3px 9px; margin-left: auto; }
.pill.open { color: var(--amber-ink); background: rgba(245, 158, 11, .14); }
.pill.answered { color: var(--green-deep); background: var(--green-soft); }
.pill.closed { color: var(--slate); background: rgba(100, 116, 139, .12); }
.list .none { color: var(--muted); text-align: center; padding: 40px 12px; }
.empty { margin: auto; color: var(--muted); }
.ticket-head { padding: 18px 24px; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 10px; }
.ticket-head h2 { margin: 0; font-size: 20px; }
.meta { display: flex; flex-wrap: wrap; gap: 8px; }
.meta span { background: var(--page); border-radius: 10px; padding: 4px 10px; font-size: 12px; color: var(--muted); }
.meta span b { color: var(--ink); font-weight: 600; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; }
.actions .btn { padding: 8px 12px; font-size: 13px; }
.thread { flex: 1; overflow-y: auto; padding: 20px 24px; display: flex; flex-direction: column; gap: 12px; background: var(--page); }
.msg { max-width: 72%; display: flex; flex-direction: column; gap: 4px; }
.msg p { margin: 0; padding: 10px 14px; border-radius: 18px; white-space: pre-wrap; line-height: 1.45; font-size: 14px; }
.msg small { font-size: 11px; color: var(--slate); padding: 0 6px; }
.msg.user { align-self: flex-start; }
.msg.user p { background: #fff; border: 1px solid var(--line); border-bottom-left-radius: 5px; }
.msg.support { align-self: flex-end; align-items: flex-end; }
.msg.support p { background: linear-gradient(135deg, var(--green), var(--green-deep)); color: #fff; border-bottom-right-radius: 5px; }
details.ai { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 12px 14px; }
details.ai summary { cursor: pointer; font-weight: 600; font-size: 13px; color: var(--green-deep); }
details.ai pre { white-space: pre-wrap; font-family: inherit; font-size: 13px; color: var(--muted); margin: 10px 0 0; }
.composer { border-top: 1px solid var(--line); padding: 14px 24px 18px; display: flex; flex-direction: column; gap: 10px; background: #fff; }
.composer textarea { min-height: 84px; resize: vertical; }
.composer .row { flex-wrap: wrap; }
.canned { display: flex; flex-wrap: wrap; gap: 6px; }
.canned button { border: 0; background: var(--green-soft); color: var(--green-deep); border-radius: 999px; padding: 5px 10px; font-size: 12px; font-weight: 600; }
.back { display: none; }

/* Settings */
.choices { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.choice { flex-direction: row; align-items: flex-start; gap: 10px; border: 1.5px solid var(--line); border-radius: 18px; padding: 12px 14px; cursor: pointer; background: #fff; }
.choice:has(input:checked) { border-color: var(--green); background: #FAFDFA; box-shadow: 0 6px 16px rgba(76, 175, 80, .14); }
.choice input { width: auto; margin: 3px 0 0; accent-color: var(--green); }
.choice span { display: flex; flex-direction: column; gap: 2px; }
.choice b { color: var(--ink); font-size: 15px; }
.choice small { font-weight: 400; }
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.hint { font-weight: 500; font-size: 12px; color: var(--amber-ink); min-height: 1em; }
.hint.ok { color: var(--muted); }
/* Partners */
label.check { flex-direction: row; align-items: center; gap: 10px; color: var(--ink); }
label.check input { width: 18px; height: 18px; accent-color: var(--green); }
.rows .line .counts { flex: none; display: flex; gap: 14px; text-align: center; }
.rows .line .counts span { display: block; font-weight: 700; font-size: 14px; }
.rows .line .counts small { font-size: 10px; }
.pill.off { color: var(--slate); background: rgba(100, 116, 139, .12); }
.pill.on { color: var(--green-deep); background: var(--green-soft); }
.pill.soon { color: var(--amber-ink); background: rgba(245, 158, 11, .14); }
.rows .line .pill { margin-left: 0; flex: none; }
.preview { white-space: pre-wrap; font-family: inherit; background: var(--page); border-radius: 14px; padding: 12px 14px; margin: 10px 0 0; font-size: 14px; }

.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 14px; font-size: 14px; box-shadow: var(--shadow); z-index: 20; }

/* Phones: the app's floating bottom bar; one column; a ticket opens over the list. */
.tabbar, .moremenu { display: none; }
@media (max-width: 1180px) {
  .kpis, .kpis.five { grid-template-columns: repeat(3, 1fr); }
  .grid2, .grid3 { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  #app { display: block; padding: 12px 12px 112px; }
  .rail { display: none; }
  main.view { gap: 14px; padding-bottom: 0; }
  .hero { padding: 20px; border-radius: 26px; }
  .hero h1 { font-size: 24px; }
  .pagehead h2 { font-size: 22px; }
  .kpis, .kpis.four, .kpis.five { grid-template-columns: 1fr 1fr; gap: 10px; }
  .kpi b { font-size: 24px; }
  .cards, .triple { grid-template-columns: 1fr; gap: 14px; }
  .grid2, .grid3 { gap: 14px; }
  .legend { display: none; }
  .choices, .pair { grid-template-columns: 1fr; }
  /* A partner's row: its name on a line of its own, the numbers under it. */
  #partnerList .line { flex-wrap: wrap; row-gap: 8px; }
  #partnerList .line > div:not(.counts) { flex: 1 1 calc(100% - 60px); }
  #partnerList .line .counts { margin-left: 48px; margin-right: auto; }
  .mini.four { grid-template-columns: 1fr 1fr; }
  .narrow { max-width: none; }

  .tabbar { display: flex; position: fixed; left: 14px; right: 14px; bottom: 14px; z-index: 9; background: rgba(255, 255, 255, .92); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
    border: 1px solid var(--line); border-radius: 999px; box-shadow: 0 14px 34px rgba(15, 23, 42, .16); padding: 8px 10px; justify-content: space-around; align-items: center; }
  .tab { border: 0; background: transparent; display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 10px; font-weight: 700; letter-spacing: .6px; text-transform: uppercase; color: var(--ink2); min-width: 54px; padding: 2px 0; }
  .tab.active { color: var(--green-deep); }
  .tab .ball { width: 54px; height: 54px; margin-top: -26px; border-radius: 50%; display: grid; place-items: center; color: #fff;
    background: linear-gradient(180deg, var(--green-light), var(--green)); box-shadow: 0 10px 22px rgba(76, 175, 80, .45); position: relative; }
  .tab .ball em { position: absolute; top: -2px; right: -4px; font-style: normal; background: var(--red); color: #fff; font-size: 10px; border-radius: 999px; padding: 1px 6px; border: 2px solid #fff; letter-spacing: 0; }
  .tab .ball em:empty { display: none; }
  .moremenu { position: fixed; right: 14px; bottom: 92px; z-index: 10; background: #fff; border: 1px solid var(--line); border-radius: 22px; box-shadow: 0 18px 40px rgba(15, 23, 42, .2); padding: 8px; flex-direction: column; min-width: 210px; }
  .moremenu.open { display: flex; }
  .moremenu button { display: flex; align-items: center; gap: 12px; border: 0; background: transparent; padding: 12px; border-radius: 14px; font-weight: 600; text-align: start; }
  .moremenu button.active { background: var(--green-soft); color: var(--green-deep); }
  .moremenu small { padding: 8px 12px 4px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 240px; }

  #inbox { display: block; height: auto; position: static; }
  #inbox .list-pane { overflow: visible; }
  .list { overflow: visible; }
  #inbox .detail-pane { display: none; }
  #inbox.reading .list-pane { display: none; }
  #inbox.reading .detail-pane { display: flex; min-height: calc(100vh - 24px); overflow: visible; }
  #app:has(#inbox.reading) { padding-bottom: 12px; }
  #app:has(#inbox.reading) .tabbar { display: none; }
  .back { display: inline-flex; align-self: flex-start; }
  .ticket-head, .thread { padding: 14px 12px; }
  .thread { overflow: visible; }
  .composer { padding: 12px; position: sticky; bottom: 0; border-radius: 0 0 24px 24px; }
  .msg { max-width: 90%; }
  .toast { bottom: 96px; max-width: calc(100vw - 24px); }
}
