/* unslop -- mobile only (loaded with media="(max-width: 980px)" from base.html).
   Full unslop direction for the phone version of the app:
     Product   a law office's daily tool: cases, sessions, deadlines, clients.
     Character exact, calm, a little formal.
     World     case files and dossiers -- paper, ink, filing stamps.
     Moments   the figures that matter (KPI numbers, the next-session countdown).
     Signature case and file numbers set as a docket stamp.
   Surfaces come from one neutral graphite ramp; the accent stays the theme's
   primary colour from the Appearance settings. Gradients are flattened by
   unslop-mobile.generated.css (regenerate with scripts/gen_unslop_mobile.py).
   unslop by Damir Sokolovsky (@heydamir), CC BY 4.0. */
/* IBM Plex Sans Arabic 400/500/600 + IBM Plex Mono 500, self-hosted (SIL Open Font License).
   Arabic and Latin subsets only; generated from Google Fonts' css2 API. */
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(../fonts/ibm-plex/ibm-plex-mono-500-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'IBM Plex Sans Arabic';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(../fonts/ibm-plex/ibm-plex-sans-arabic-400-arabic.woff2) format('woff2');
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC, U+102E0-102FB, U+10E60-10E7E, U+10EC2-10EC7, U+10EC9-10EEE, U+10EF0-10EFF, U+1EE00-1EE03, U+1EE05-1EE1F, U+1EE21-1EE22, U+1EE24, U+1EE27, U+1EE29-1EE32, U+1EE34-1EE37, U+1EE39, U+1EE3B, U+1EE42, U+1EE47, U+1EE49, U+1EE4B, U+1EE4D-1EE4F, U+1EE51-1EE52, U+1EE54, U+1EE57, U+1EE59, U+1EE5B, U+1EE5D, U+1EE5F, U+1EE61-1EE62, U+1EE64, U+1EE67-1EE6A, U+1EE6C-1EE72, U+1EE74-1EE77, U+1EE79-1EE7C, U+1EE7E, U+1EE80-1EE89, U+1EE8B-1EE9B, U+1EEA1-1EEA3, U+1EEA5-1EEA9, U+1EEAB-1EEBB, U+1EEF0-1EEF1;
}
@font-face {
  font-family: 'IBM Plex Sans Arabic';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(../fonts/ibm-plex/ibm-plex-sans-arabic-400-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'IBM Plex Sans Arabic';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(../fonts/ibm-plex/ibm-plex-sans-arabic-500-arabic.woff2) format('woff2');
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC, U+102E0-102FB, U+10E60-10E7E, U+10EC2-10EC7, U+10EC9-10EEE, U+10EF0-10EFF, U+1EE00-1EE03, U+1EE05-1EE1F, U+1EE21-1EE22, U+1EE24, U+1EE27, U+1EE29-1EE32, U+1EE34-1EE37, U+1EE39, U+1EE3B, U+1EE42, U+1EE47, U+1EE49, U+1EE4B, U+1EE4D-1EE4F, U+1EE51-1EE52, U+1EE54, U+1EE57, U+1EE59, U+1EE5B, U+1EE5D, U+1EE5F, U+1EE61-1EE62, U+1EE64, U+1EE67-1EE6A, U+1EE6C-1EE72, U+1EE74-1EE77, U+1EE79-1EE7C, U+1EE7E, U+1EE80-1EE89, U+1EE8B-1EE9B, U+1EEA1-1EEA3, U+1EEA5-1EEA9, U+1EEAB-1EEBB, U+1EEF0-1EEF1;
}
@font-face {
  font-family: 'IBM Plex Sans Arabic';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(../fonts/ibm-plex/ibm-plex-sans-arabic-500-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'IBM Plex Sans Arabic';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(../fonts/ibm-plex/ibm-plex-sans-arabic-600-arabic.woff2) format('woff2');
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC, U+102E0-102FB, U+10E60-10E7E, U+10EC2-10EC7, U+10EC9-10EEE, U+10EF0-10EFF, U+1EE00-1EE03, U+1EE05-1EE1F, U+1EE21-1EE22, U+1EE24, U+1EE27, U+1EE29-1EE32, U+1EE34-1EE37, U+1EE39, U+1EE3B, U+1EE42, U+1EE47, U+1EE49, U+1EE4B, U+1EE4D-1EE4F, U+1EE51-1EE52, U+1EE54, U+1EE57, U+1EE59, U+1EE5B, U+1EE5D, U+1EE5F, U+1EE61-1EE62, U+1EE64, U+1EE67-1EE6A, U+1EE6C-1EE72, U+1EE74-1EE77, U+1EE79-1EE7C, U+1EE7E, U+1EE80-1EE89, U+1EE8B-1EE9B, U+1EEA1-1EEA3, U+1EEA5-1EEA9, U+1EEAB-1EEBB, U+1EEF0-1EEF1;
}
@font-face {
  font-family: 'IBM Plex Sans Arabic';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(../fonts/ibm-plex/ibm-plex-sans-arabic-600-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ── Neutral ramp (overrides the light/dark surface settings on mobile) ── */
:root {
  --bg-page: #fafafa !important; --bg-card: #ffffff !important; --bg-soft: #f4f4f5 !important;
  --border: rgba(23,23,23,.09) !important; --border-strong: rgba(23,23,23,.17) !important;
  --text: #171717 !important; --text-soft: #525252 !important; --text-fade: #737373 !important;
  --accent-grad: var(--accent) !important; --accent-grad-blue: var(--accent) !important;
  --gold-grad: var(--accent) !important; --topbar-bg: var(--bg-card) !important;
  --shadow-xs: none !important; --shadow-sm: 0 1px 2px rgba(0,0,0,.05) !important;
  --shadow-md: 0 8px 24px rgba(0,0,0,.06) !important; --shadow-lg: 0 8px 24px rgba(0,0,0,.06) !important;
  --accent-glow: 0 0 0 2px color-mix(in oklab, var(--accent), transparent 70%) !important;
  --theme-font: "IBM Plex Sans Arabic", system-ui, sans-serif !important;
}
html.dark-mode, html[data-theme="dark"] {
  --bg-page: #141415 !important; --bg-card: #19191b !important; --bg-soft: #232325 !important;
  --border: rgba(237,237,237,.09) !important; --border-strong: rgba(237,237,237,.17) !important;
  --text: #ededed !important; --text-soft: #a1a1a6 !important; --text-fade: #85858b !important;
  --dm-bg: #141415 !important; --dm-card: #19191b !important; --dm-soft: #232325 !important;
  --dm-text: #ededed !important; --dm-border: rgba(237,237,237,.09) !important; --dm-border-strong: rgba(237,237,237,.17) !important;
}
html body { background-color: var(--bg-page) !important; background-image: none !important; }

/* ── Type: one family, three weights at most, sentence case ── */
html body, html body :is(input, select, textarea, button) {
  font-family: "IBM Plex Sans Arabic", system-ui, sans-serif !important;
  letter-spacing: 0 !important; font-style: normal !important;
}
html body :is(h1, h2, h3, h4, h5, h6, b, strong, th) { font-weight: 500 !important; }
html body [style*="font-weight"], html body :is(.btn, button, label, .tab-link, .chip, .badge) { font-weight: 500 !important; }
html body :is(td, .count-up, .lp-kpi-value, .cd-info-value, .kpi b, [class*="amount"], [class*="total"], [class*="value"]) { font-variant-numeric: tabular-nums; }

/* ── Colour: no glows, coloured shadows, glass or text glow ── */
html body *:not(.lp-ai-insight-card):not(.lp-ai-insight-card *) { text-shadow: none !important; }
html body *:not(.bottom-nav *) { box-shadow: none !important; -webkit-backdrop-filter: none !important; backdrop-filter: none !important; }
html body *:not(img):not(video):not(canvas):not(svg):not(svg *) { filter: none !important; }
[role="dialog"], [class*="modal"] > [class*="box"], [class*="dropdown"], [class*="popover"], [class*="toast"], .nb-notif-panel, .nb-drawer {
  box-shadow: 0 8px 24px rgba(0,0,0,.08) !important;
}
html.dark-mode :is([role="dialog"], [class*="dropdown"], [class*="toast"]) { box-shadow: 0 8px 24px rgba(0,0,0,.4) !important; }
:focus-visible { outline: 2px solid var(--accent) !important; outline-offset: 2px !important; }

/* decoration that says nothing about the product */
.geo-shapes, .geo-float, .geo-rotate, .nb-geo, [class*="geo-deco"], [class*="sidebar-blob"], .lp-kpi-spark,
.backups-hero::before, .backups-hero::after { display: none !important; }

/* ── Chrome stays quiet: neutral surfaces, hairlines ── */
html body :is(.card, .soft-card, .cd-card, .lp-card, .lp-kpi-card, .kpi, .section-card, .stat-card, .info-card, .case-card, .invoice-card, .task-card, .kb-task, .appointment-card-expandable, .timeline-card, .fm-item, .data-row, .user-card-mob, [class*="-card"]:not([class*="-card-"])) {
  border-color: var(--border) !important;
}
.lp-kpi-card--gold-light, .lp-kpi-card--gold, .lp-kpi-card--dark, .lp-kpi-card--accent {
  background-color: var(--bg-card) !important; border: 1px solid var(--border) !important; color: var(--text) !important;
}
:is(.lp-kpi-card--gold-light, .lp-kpi-card--gold, .lp-kpi-card--dark, .lp-kpi-card--accent) :is(.lp-kpi-label, .lp-kpi-value, .lp-kpi-trend, span, div) { color: inherit !important; }
.lp-kpi-icon { background: var(--bg-soft) !important; color: var(--text-soft) !important; }
.nb-drawer-head { background: var(--accent) !important; }

/* status pills: quiet outline with a dot, colour only for meaning */
.case-card-pill, .case-status-pill, .status-badge, .badge, .fin-badge, .tl-badge {
  background: transparent !important; border: 1px solid var(--border-strong) !important; color: var(--text-soft) !important;
}
.case-card-pill.status-active, .case-status-pill.status-active, .status-badge.active, .fin-badge.success { color: #16a34a !important; }
.case-card-pill.status-ended, .case-status-pill.status-ended, .status-badge.ended, .fin-badge.danger { color: #dc2626 !important; }
.case-card-pill.status-new, .case-status-pill.status-new, .status-badge.new { color: #a16207 !important; }
html.dark-mode :is(.case-card-pill.status-active, .status-badge.active, .fin-badge.success) { color: #4cc38a !important; }
html.dark-mode :is(.case-card-pill.status-ended, .status-badge.ended, .fin-badge.danger) { color: #e5484d !important; }
.case-card-pill::before { content: ""; display: inline-block; width: 6px; height: 6px; margin-inline-end: 6px; border-radius: 50%; background: currentColor; }

/* bottom navigation: designed on its own in bottom-nav.css, left out of the rules here */

/* ── Copy: the page name is the title, no greeting ── */
.nb-dash-greeting, .nb-welcome-text, .nb-welcome-pill { display: none !important; }

/* ── Motion: no loops or entrance on every list item; live status keeps moving ── */
/* (the motions asked for on purpose -- tab tiles, the
   "Current" blink, the flip countdown, the timeline badges -- are left out) */
html body *:not([class*="spin"]):not([class*="loader"]):not([class*="loading"]):not(.pl-box):not(.stt-running):not(.recording):not(.ws-dot-yellow):not(.skeleton):not(.lp-sk):not(.cd-next-dot):not(:is(.bn-tile, .sx2-tab, .legend-tab-blink, .fd-h, .tlx-arc, .tlx-fill, .tlx-check, .tlx-pop, .nb-drawer-link)),
html body *::before, html body *::after {
  /* finish every animation instantly instead of cancelling it: entrance
     animations (e.g. the drawer links, which start at opacity 0) land on
     their visible end state, loops play once in no time and stop */
  animation-duration: 0s !important; animation-delay: 0s !important; animation-iteration-count: 1 !important;
}
.reveal-up, .reveal-up.is-visible, .animate-rise, .animate-fadeUp, .page-enter { opacity: 1 !important; transform: none !important; }
html body :is(a, button, .btn, [class*="card"]):not(.bottom-nav *):hover { transform: none !important; }
html body :is(button, .btn):not(.bottom-nav *):active { transform: scale(.98) !important; }

/* ── Signature: case and file numbers as a docket stamp ── */
.case-file-number-badge, .case-meta-number, .cd-info-value span[dir="ltr"], .case-number-stamp {
  font-family: "IBM Plex Mono", ui-monospace, monospace !important; font-size: 12px !important; font-weight: 500 !important;
  background: transparent !important; color: var(--accent) !important;
  border: 1px solid currentColor !important; border-radius: 4px !important; padding: 1px 6px !important;
}

/* ── Long lists: off-screen cards skip layout and paint until scrolled near
   (light virtualization; the DOM, search and filters are unchanged) ── */
.appointment-card-expandable:not(.expanded):not(.is-open),
.task-card,
.financial-root .case-card,
.user-card-mob {
  content-visibility: auto;
  contain-intrinsic-size: auto 140px;
}

/* ── Moving between pages: the new page rises in (cross-document View
   Transitions; browsers without them just navigate as before) ── */
@view-transition { navigation: auto; }
@keyframes nbVtOut { to { opacity: 0; } }
@keyframes nbVtIn { from { opacity: 0; translate: 0 26px; } to { opacity: 1; translate: 0 0; } }
::view-transition-old(root) { animation: nbVtOut .16s ease both !important; }
::view-transition-new(root) { animation: nbVtIn .34s cubic-bezier(.22,1,.36,1) both !important; }
@media (prefers-reduced-motion: reduce) {
  ::view-transition-old(root), ::view-transition-new(root) { animation: none !important; }
}
