/* This stylesheet is requested only at phone widths. Desktop keeps its complete view. */
:root{color-scheme:light;--bg:#f5f7fa;--panel:#fff;--border:#dbe3ed;--text:#182d46;--muted:#586b80;--green:#157c67;--red:#bb4056;--blue:#24659b;--amber:#93631d;--fa-chat-font:16px}
html.fa-mobile-active,html.fa-mobile-active body{height:100%;overflow:hidden;background:#f5f7fa;color:var(--text);overscroll-behavior-y:none}
[hidden]{display:none!important}
.fa-mobile-active body>header,.fa-mobile-active body>main{display:none!important}
.fa-mobile-shell{width:100%;height:100dvh;display:flex;flex-direction:column;background:#f5f7fa;overflow:hidden}
.fa-mobile-head{display:flex;flex-direction:row;direction:ltr;align-items:center;gap:5px;flex:none;min-height:62px;padding:8px 10px;border-bottom:1px solid #e1e7ee;background:#fff}
.fa-mobile-title{min-width:0;flex:1;line-height:1.35;text-align:left}
.fa-mobile-title small{display:block;font:650 8px/1.6 "TW Arabic",system-ui;letter-spacing:.12em;color:#687d91}
.fa-mobile-title strong{display:block;white-space:nowrap;font:700 13px/1.4 "TW Arabic",system-ui;color:#172e47}
.fa-icon-button{display:grid;place-items:center;width:36px;height:42px;padding:0;flex:none;border:0;border-radius:10px;background:transparent;color:#3b5671;font:650 15px "TW Arabic",system-ui;text-decoration:none}
.fa-icon-button svg{width:19px;height:19px}.fa-icon-button:hover{background:#edf3f8;text-decoration:none}
.fa-icon-button[aria-pressed=true]{background:#e1f3eb;color:#14705c}
.fa-mobile-shell .chat{display:flex;flex-direction:column;flex:1;width:100%;min-height:0;max-height:none;position:static;overflow:hidden;margin:0;padding:0;border:0;border-radius:0;background:#f5f7fa}
.fa-mobile-shell .chat>.section-head{display:none}
.fa-mobile-shell #conversation{order:0;flex:1;min-height:70px;max-height:none;height:auto;overflow:auto;padding:14px 14px 6px;scroll-behavior:smooth;overscroll-behavior:contain}
.fa-mobile-shell .message{font-size:var(--fa-chat-font);line-height:1.85;padding:13px 15px;margin:0 0 12px;background:#fff;border:1px solid #e1e7ee;color:#182d46;box-shadow:0 3px 12px -10px #223b5a33;border-radius:16px;white-space:pre-wrap}
.fa-mobile-shell .message.assistant{margin-right:0;margin-left:12px}
.fa-mobile-shell .message.user{margin-left:0;margin-right:24px;background:#e2f2eb;border-color:#c7e5d8}
.fa-mobile-shell #proposal,.fa-mobile-shell #reminderProposal{order:1;flex:none;max-height:32dvh;overflow:auto;padding:0 12px;background:#fff}
.fa-mobile-shell .proposal{margin:8px 0;padding:12px;background:#fff6dd;border-color:#c9a65f;font-size:15px}
.fa-mobile-shell .proposal button{min-height:42px;margin-top:8px;background:#fff;color:#172e47;border-color:#c7d4df}
.fa-mobile-shell .chat>.quick{
  order:2;
  flex:none;
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:8px;
  width:100%;
  margin:0;
  padding:8px max(12px,env(safe-area-inset-right)) 10px max(12px,env(safe-area-inset-left));
  background:#f5f7fa;
}
.fa-mobile-shell .chat>.quick button{
  min-width:0;
  min-height:54px;
  margin:0;
  padding:7px 4px;
  border-radius:14px;
  border-color:var(--quick-line);
  background:var(--quick-fill);
  color:var(--quick-ink);
  font-family: "TW Arabic",inherit;
  font-size:14px;
  font-weight:700;
  line-height:1.35;
  text-align:center;
  white-space:normal;
}
.fa-mobile-shell .quick #assistantAsk{--quick-line:#c6d9ed;--quick-fill:#e8f1fb;--quick-ink:#25496c}
.fa-mobile-shell .quick #cashMode{--quick-line:#beded2;--quick-fill:#e2f3ed;--quick-ink:#15584b}
.fa-mobile-shell .quick #paymentMode{--quick-line:#e7d3af;--quick-fill:#fff0da;--quick-ink:#704617}
/* 14 Nov 2026 — the selected shortcut used to flood with its own ink, which put a dark block at
   the bottom of a light phone screen. It now keeps its light fill and is marked by a heavier
   border, bolder ink and an underline, so the selection is just as plain without the dark slab. */
.fa-mobile-shell .chat>.quick button[aria-pressed="true"]{
  background:var(--quick-fill);
  border-color:var(--quick-ink);
  border-width:2px;
  color:var(--quick-ink);
  font-weight:800;
  box-shadow:inset 0 -3px 0 var(--quick-ink);
}
.fa-mobile-shell .chat>.quick button:focus-visible{outline:2px solid var(--quick-ink);outline-offset:2px}
.fa-mobile-shell #ask{order:3;position:static;flex:none;display:grid;grid-template-columns:48px minmax(0,1fr) 42px;direction:rtl;gap:7px;align-items:center;margin:0;padding:10px 12px max(10px,env(safe-area-inset-bottom));border-top:1px solid #e0e7ef;background:#fff}
.fa-mobile-shell #ask .voice-composer,.fa-mobile-shell #ask .voice-composer>div{display:contents}
.fa-mobile-shell .voice-composer strong{display:none}
.fa-mobile-shell #ask #question{grid-row:1;grid-column:2;direction:rtl;resize:none;min-height:48px;height:48px;max-height:110px;margin:0;padding:11px 12px;border-radius:15px;border-color:#d7e1eb;background:#f6f8fb;color:#172e47;font-size:16px;line-height:1.5}
.fa-mobile-shell #ask #question::placeholder{color:#63768a;font-size:13px}
.fa-mobile-shell #mic{grid-row:1;grid-column:1;width:48px;height:48px;margin:0;display:grid;place-items:center;padding:0;border-radius:16px;background:#157e71;color:#fff;border:0;box-shadow:none;font-size:0}
.fa-mobile-shell #mic::before{content:'';display:block;width:22px;height:24px;background:currentColor;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cg fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round'%3E%3Crect x='9' y='3' width='6' height='11' rx='3'/%3E%3Cpath d='M6 11v1a6 6 0 0 0 12 0v-1M12 18v3M9 21h6'/%3E%3C/g%3E%3C/svg%3E") center/contain no-repeat}
.fa-mobile-shell #mic.recording{background:#bb4056;box-shadow:0 0 0 4px #bb40561a}
.fa-mobile-shell #mic.recording::before{mask:none;width:16px;height:16px;border-radius:3px}
.fa-mobile-shell #ask #send{grid-row:1;grid-column:3;width:42px;height:44px;padding:0;border-radius:14px;background:#203d57;border-color:#203d57;color:white;font-size:0}
.fa-mobile-shell #ask #send::before{content:'↑';font:600 25px/1 "TW Arabic",system-ui}
.fa-mobile-shell #ask #heard{grid-row:2;grid-column:1/-1;margin:0;padding:6px 10px;max-height:60px;font-size:12px;background:#edf5fb;border-color:#6b9dbf;color:#33516a}
.fa-mobile-shell #chatStatus{grid-row:3;grid-column:1/-1;min-height:0;margin:0;font-size:11px;line-height:1.5;color:#526b80}
.fa-mobile-shell #cancelVoice{grid-row:4;grid-column:1/-1;font-size:12px;padding:5px;background:#fff1f3;border-color:#e4b9c3;color:#a2364c}
.fa-mobile-proofs{white-space:normal;margin-top:10px;border-top:1px solid #e1e7ee;padding-top:8px}
.fa-mobile-proofs summary{font:600 12px/1.5 "TW Arabic",system-ui;color:#376b98}
.fa-mobile-proofs button{display:block;width:100%;text-align:right;padding:8px 10px;margin:7px 0;border:1px solid #d3e1ec;background:#f0f6fb;color:#315575;font-size:12px;white-space:normal}
dialog{background:#fff;color:#182d46;border-color:#cbd9e5;padding:18px;max-height:85dvh;width:calc(100vw - 24px);border-radius:20px;font-size:15px}
dialog::backdrop{background:#142c4870}
dialog button,dialog input,dialog textarea{background:#f4f7fa;border-color:#cbd9e5;color:#182d46;font-size:15px}
dialog .section-head h2{font-size:17px;margin:0}dialog .help-grid{grid-template-columns:1fr;gap:12px}dialog pre{background:#eef3f8;color:#243e59}
.fa-mobile-sheet{padding:0;overflow:auto;max-height:88dvh;width:calc(100vw - 20px)}
.fa-sheet-head{display:flex;direction:ltr;align-items:center;justify-content:space-between;padding:14px 16px;border-bottom:1px solid #e1e7ee}
.fa-sheet-head strong{font:700 16px "TW Arabic",system-ui}.fa-sheet-head button{width:36px;height:36px;padding:0;border:0;background:#f0f4f8;font:24px "TW Arabic",system-ui}
.fa-sheet-tabs{display:flex;flex-wrap:nowrap;gap:5px;padding:12px 14px 6px;direction:ltr}
.fa-sheet-tabs button{flex:1;padding:7px 10px;border-radius:12px;font:600 12px "TW Arabic",system-ui;background:#f3f6fa;color:#526a80;border-color:transparent}
.fa-sheet-tabs button[aria-pressed=true]{background:#e2f2eb;color:#166c57}
.fa-sheet-actions{display:flex;flex-wrap:wrap;gap:6px;padding:8px 14px 14px;border-bottom:1px solid #e1e7ee;direction:ltr}
.fa-sheet-actions button{font:500 11px "TW Arabic",system-ui;padding:7px 9px;border-radius:10px}
#faMobileSheetContent{padding:14px}
#faMobileSheetContent .toolbar{gap:7px;margin-bottom:14px}#faMobileSheetContent .toolbar label{font-size:12px}#faMobileSheetContent .toolbar button,#faMobileSheetContent .toolbar input{padding:6px 8px;font-size:12px;background:#f4f7fa;color:#243e59;border-color:#cbd9e5}
#faMobileSheetContent .panel{padding:14px;margin:0 0 12px;border-radius:14px;background:#fff}
#faMobileSheetContent .panel>p.muted{font-size:12px}
#faMobileSheetContent .kpis{grid-template-columns:1fr;gap:8px;margin:10px 0}
#faMobileSheetContent .kpi{min-height:0;display:flex;flex-direction:row;gap:10px;padding:10px 12px;font-size:12px;background:#f1f6fa}
#faMobileSheetContent .kpi strong{font-size:16px;margin:0}
#faMobileSheetContent button{background:#f0f5fa;color:#234663;border-color:#ceddea}
#faMobileSheetContent .notice{font-size:13px;background:#fff7e5}#faMobileSheetContent .notice.danger{background:#fff0f3}
#faMobileSheetContent .due-row,#faMobileSheetContent .source-row{flex-wrap:wrap;gap:8px;font-size:13px}
#faMobileSheetContent .reminder-row{flex-wrap:wrap;font-size:14px}
#faMobileSheetContent #financialFollowups>p{font-size:12px}
.fa-mobile-sheet[data-view=report] #financialFollowups,.fa-mobile-sheet[data-view=alerts] .toolbar,.fa-mobile-sheet[data-view=alerts] #financialFollowups,.fa-mobile-sheet[data-view=alerts] #faMobileSheetContent>section>.panel:not(:nth-child(2)),.fa-mobile-sheet[data-view=reminders] .toolbar,.fa-mobile-sheet[data-view=reminders] #faMobileSheetContent>section:not(#financialFollowups){display:none!important}
@media(max-width:360px){.fa-mobile-head{gap:2px;padding-inline:6px}.fa-mobile-title strong{font-size:12px}.fa-icon-button{width:30px}}
@media(prefers-reduced-motion:reduce){.fa-mobile-shell #conversation{scroll-behavior:auto}.fa-mobile-shell #mic{animation:none}}
/* Embedded legacy rules must not move the phone header below the conversation. */
.fa-mobile-shell .chat{order:1}
.fa-mobile-shell .fa-mobile-head{order:0}
.fa-mobile-shell .fa-mobile-head>.fa-mobile-title{display:block}

/* One notification action in the phone tools; the original remains the event owner. */
.fa-mobile-active #faMobileSheetContent #notify{display:none!important}
.fa-sheet-tabs,.fa-sheet-actions,.fa-sheet-head{direction:rtl}

/* === phone colour tokens · generated · do not edit by hand === */
:root{
 --p-bg-08131f:#f6f8fb;
 --p-bg-0a1926:#f6f8fb;
 --p-bg-0d1d2b:#f6f8fb;
 --p-bg-132637:#f6f8fb;
 --p-bg-152c3c:#f6f8fb;
 --p-bg-192f40:#f6f8fb;
 --p-bg-193447:#eef3f8;
 --p-bg-204357:#eef3f8;
 --p-bg-24505a:#eef3f8;
 --p-bg-344555:#eef3f8;
 --p-bg-49391d44:#f4eee444;
 --p-line-1d3242:#cad8e2;
 --p-line-22554f:#cae2e0;
}
/* === end phone colour tokens === */

/* hand-matched to the amber notice above it */
.notice.danger{background:#fdeef1}

 .fr-headline{background:#ffffff!important;border-color:#d7e1ea!important}
 .fr-headline h3{color:#4b6579!important}
 .fr-headline-line{background:#f6f8fb!important;color:#16293f!important}
 .fr-headline-line:hover{background:#eef3f8!important}
