/* Womark A80 — interface upgrade layer.
   Loaded last. Visual only: no element, route, permission, form field or flow
   depends on anything in this file. Removing the <link> restores A79.2 exactly. */

/* ---------- Bundled fonts (served from /static/fonts; CSP font-src 'self') ---------- */
@font-face{font-family:"Inter A80";font-style:normal;font-weight:100 900;font-display:swap;
  src:url(/static/fonts/inter-latin-wght-normal.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:"Inter A80";font-style:normal;font-weight:100 900;font-display:swap;
  src:url(/static/fonts/inter-latin-ext-wght-normal.woff2) format("woff2");
  unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}
@font-face{font-family:"Plex Arabic A80";font-style:normal;font-weight:400;font-display:swap;
  src:url(/static/fonts/ibm-plex-sans-arabic-arabic-400-normal.woff2) format("woff2");unicode-range:U+0600-06FF,U+0750-077F,U+0870-08FF,U+200C-200E,U+2010-2011,U+204F,U+2E41,U+FB50-FDFF,U+FE70-FEFC}
@font-face{font-family:"Plex Arabic A80";font-style:normal;font-weight:500;font-display:swap;
  src:url(/static/fonts/ibm-plex-sans-arabic-arabic-500-normal.woff2) format("woff2");unicode-range:U+0600-06FF,U+0750-077F,U+0870-08FF,U+200C-200E,U+2010-2011,U+204F,U+2E41,U+FB50-FDFF,U+FE70-FEFC}
@font-face{font-family:"Plex Arabic A80";font-style:normal;font-weight:600;font-display:swap;
  src:url(/static/fonts/ibm-plex-sans-arabic-arabic-600-normal.woff2) format("woff2");unicode-range:U+0600-06FF,U+0750-077F,U+0870-08FF,U+200C-200E,U+2010-2011,U+204F,U+2E41,U+FB50-FDFF,U+FE70-FEFC}
@font-face{font-family:"Plex Arabic A80";font-style:normal;font-weight:700 900;font-display:swap;
  src:url(/static/fonts/ibm-plex-sans-arabic-arabic-700-normal.woff2) format("woff2");unicode-range:U+0600-06FF,U+0750-077F,U+0870-08FF,U+200C-200E,U+2010-2011,U+204F,U+2E41,U+FB50-FDFF,U+FE70-FEFC}

/* ---------- Tokens ---------- */
:root{
  --a80-font:"Inter A80","Plex Arabic A80",ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Tahoma,Arial,sans-serif;
  --a80-mono:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;
  --a80-bg:#f4f5f2;--a80-panel:#fff;--a80-ink:#141714;--a80-ink-2:#3c433d;--a80-muted:#6b736c;
  --a80-line:#e2e6e0;--a80-line-strong:#cfd5cd;--a80-soft:#f8f9f6;--a80-hover:#f1f3ef;
  --a80-accent:#167451;--a80-accent-ink:#0f5a3e;--a80-accent-soft:#e7f4ec;
  --a80-focus:0 0 0 3px rgba(22,116,81,.18);
  --a80-radius:14px;--a80-radius-sm:10px;--a80-control-h:40px;
  --a80-shadow:0 1px 2px rgba(16,24,18,.04),0 6px 20px rgba(16,24,18,.045);
}

/* ---------- Typography ---------- */
html body,html body button,html body input,html body select,html body textarea{font-family:var(--a80-font)}
html body code,html body kbd,html body .mono,html body pre{font-family:var(--a80-mono)}
html body{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-rendering:optimizeLegibility}
/* Letter-spacing and forced caps break Arabic letter joining. */
html[dir=rtl] body *{letter-spacing:0!important}
html[dir=rtl] body .section-kicker,html[dir=rtl] body .topbar-eyebrow,html[dir=rtl] body th,html[dir=rtl] body .nav-group-toggle{text-transform:none!important}

/* Small UI text was 8–10px: lift it to readable sizes. Arabic glyphs need one step more. */
html body .nav-group-toggle{font-size:11px!important;font-weight:700!important;color:#6a726b!important}
html body .section-kicker{font-size:10.5px!important}
html body .table th,html body table th{font-size:10.5px!important}
html body .table td,html body table td{font-size:12.5px}
html body .btn{font-size:12.5px}
html[dir=rtl] body{font-size:14.5px}
html[dir=rtl] body .nav-group-toggle{font-size:12px!important}
html[dir=rtl] body .nav{font-size:13.5px!important}
html[dir=rtl] body .section-kicker,html[dir=rtl] body .topbar-eyebrow{font-size:11.5px!important}
html[dir=rtl] body .section-title{font-size:16px}
html[dir=rtl] body .page-title{font-size:23px;line-height:1.35}
html[dir=rtl] body .table th,html[dir=rtl] body table th{font-size:12px!important;font-weight:700!important}
html[dir=rtl] body .table td,html[dir=rtl] body table td{font-size:13.5px}
html[dir=rtl] body .btn{font-size:13px}
html[dir=rtl] body .muted,html[dir=rtl] body small{line-height:1.6}

/* Readability floor. Many layers set helper text at 8–10px, which is unreadable in Arabic.
   Dense POS order-queue rows keep their compact sizes. */
html body small:not(.pos-orders-grid *):not(.bulk-table-wrap *){font-size:max(10px,.8em)}
html[dir=rtl] body small:not(.pos-orders-grid *):not(.bulk-table-wrap *){font-size:max(11px,.82em);line-height:1.55}
html body .pos-smart-brand span,html body .pos-smart-brand small,html body .settings-menu-title span,html body .settings-menu-title small,html body .pos-document-head .live-status,html body .opscmd-kicker,html body .opscmd-kpi span,html body .opscmd-kpi small,html body .opscmd-today,html body .opscmd-side-card small,html body .opscmd-result,html body .opscmd-result span,html body .opscmd-clear,html body .center-check span,html body .webhook-setup-head .setup-step,html body .webhook-meta span,html body .bosta-mirror-data-head span,html body .return-divider span,html body .trend-day small{font-size:12px!important}
html body .pos-mode-segmented button,html body .center-tabs button,html body .opscmd-saved-views button{font-size:11.5px!important}
html body .pos-workspace .empty span,html body .pos-workspace .muted,html body .exchange-rule span,html body .pos-exchange-empty-list span,html body .return-safe-note span,html body .webhook-rule span,html body .webhook-setup-head p,html body .metric-card span,html body .metric-card small,html body .report-context-kicker,html body .finance-eyebrow,html body .finance-period-label,html body .finance-basis span,html body .finance-action-copy small,html body .report-capabilities span,html body .opscmd-side-title{font-size:11px!important}
html[dir=rtl] body .pos-smart-brand span,html[dir=rtl] body .pos-smart-brand small,html[dir=rtl] body .settings-menu-title span,html[dir=rtl] body .settings-menu-title small,html[dir=rtl] body .pos-document-head .live-status,html[dir=rtl] body .opscmd-kicker,html[dir=rtl] body .opscmd-kpi span,html[dir=rtl] body .opscmd-kpi small,html[dir=rtl] body .opscmd-today,html[dir=rtl] body .opscmd-side-card small,html[dir=rtl] body .opscmd-result,html[dir=rtl] body .opscmd-result span,html[dir=rtl] body .opscmd-clear,html[dir=rtl] body .center-check span,html[dir=rtl] body .webhook-setup-head .setup-step,html[dir=rtl] body .webhook-meta span,html[dir=rtl] body .bosta-mirror-data-head span,html[dir=rtl] body .return-divider span,html[dir=rtl] body .trend-day small{font-size:12px!important}
html[dir=rtl] body .pos-mode-segmented button,html[dir=rtl] body .center-tabs button,html[dir=rtl] body .opscmd-saved-views button{font-size:12.5px!important}
html[dir=rtl] body .pos-workspace .empty span,html[dir=rtl] body .pos-workspace .muted,html[dir=rtl] body .exchange-rule span,html[dir=rtl] body .pos-exchange-empty-list span,html[dir=rtl] body .return-safe-note span,html[dir=rtl] body .webhook-rule span,html[dir=rtl] body .webhook-setup-head p,html[dir=rtl] body .metric-card span,html[dir=rtl] body .metric-card small,html[dir=rtl] body .report-context-kicker,html[dir=rtl] body .finance-eyebrow,html[dir=rtl] body .finance-period-label,html[dir=rtl] body .finance-basis span,html[dir=rtl] body .finance-action-copy small,html[dir=rtl] body .report-capabilities span,html[dir=rtl] body .opscmd-side-title{font-size:12px!important}

html body .sidebar .nav small{font-size:10.5px!important}
html[dir=rtl] body .sidebar .nav small{font-size:11px!important}
html body .opscmd-today span,html body .opscmd-side-title span,html body .bosta-mirror-progress-meta span,html body .webhook-meta b,
html body .invx-popover-grid span,html body .invx-popover-grid b,html body .finance-link,html body .finance-footnote,
html body .opscmd-side-card b,html body .bosta-mirror-data em{font-size:11px!important}
html[dir=rtl] body .opscmd-today span,html[dir=rtl] body .opscmd-side-title span,html[dir=rtl] body .bosta-mirror-progress-meta span,html[dir=rtl] body .webhook-meta b,
html[dir=rtl] body .invx-popover-grid span,html[dir=rtl] body .invx-popover-grid b,html[dir=rtl] body .finance-link,html[dir=rtl] body .finance-footnote,
html[dir=rtl] body .opscmd-side-card b,html[dir=rtl] body .bosta-mirror-data em{font-size:12px!important}

/* ---------- Shell ---------- */
html body .sidebar{border-inline-end:1px solid var(--a80-line)!important}
html body .nav{border-radius:12px!important}
html body .nav:hover{background:var(--a80-hover)!important}
html[dir=rtl] body .nav:hover{transform:translateX(-1px)}
html body .nav.active{background:#1a1e1b!important;color:#fff!important}
html body .nav.active:hover{background:#1a1e1b!important}
html body .nav-group-toggle:hover{color:var(--a80-ink)!important;background:var(--a80-hover)!important}
html body .topbar{border-bottom:1px solid var(--a80-line)!important}

/* ---------- Surfaces ---------- */
html body .table-wrap{border-color:var(--a80-line)!important;box-shadow:var(--a80-shadow)}

/* ---------- Controls ---------- */
html body input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=file]):not([type=color]),html body select,html body textarea{
  border-color:var(--a80-line-strong);transition:border-color .15s ease,box-shadow .15s ease}
html body input:not([type=checkbox]):not([type=radio]):hover,html body select:hover,html body textarea:hover{border-color:#b9c1b8}
html body input:not([type=checkbox]):not([type=radio]):focus,html body select:focus,html body textarea:focus{
  border-color:var(--a80-accent)!important;box-shadow:var(--a80-focus)!important;outline:none}
html body input::placeholder,html body textarea::placeholder{color:#8a918a;opacity:1}
html body input[type=checkbox],html body input[type=radio]{accent-color:var(--a80-accent)}
html body .btn{transition:background-color .15s ease,border-color .15s ease,box-shadow .15s ease,transform .08s ease}
html body .btn:not(:disabled):active{transform:translateY(1px)}
html body .btn:disabled,html body .btn[disabled]{opacity:.5;cursor:not-allowed}
html body .btn:not(.primary):not(.danger):not(:disabled):hover{border-color:#bfc6be;background:var(--a80-soft)}
html body :focus-visible{outline:2px solid var(--a80-accent);outline-offset:2px}
html body .btn:focus-visible,html body .nav:focus-visible{outline:2px solid var(--a80-accent)!important;outline-offset:2px}

/* ---------- Tables ---------- */
html body .table tbody tr,html body table.table tr{transition:background-color .12s ease}
html body .table tbody tr:hover td{background:#fafbf9}
html body .table td{border-color:#edf0ec}

/* ---------- Badges ---------- */


/* ---------- Scrollbars (desktop) ---------- */
@media (hover:hover){
  html body *::-webkit-scrollbar{width:10px;height:10px}
  html body *::-webkit-scrollbar-thumb{background:#d3d8d1;border-radius:10px;border:2px solid transparent;background-clip:padding-box}
  html body *::-webkit-scrollbar-thumb:hover{background:#b9c0b7;background-clip:padding-box}
  html body *::-webkit-scrollbar-track{background:transparent}
}

/* ---------- Phone ---------- */
@media (max-width:700px){
  html body .topbar .page-subtitle{font-size:11px!important;letter-spacing:0!important}
  html body .top-actions .user-pill{display:flex!important;align-items:center;justify-content:center}
  html body .top-actions .user-pill:before{line-height:1;display:block}
  html body .table td{font-size:13px}
  html[dir=rtl] body .table td{font-size:13.5px}
}

/* ---------- Motion ---------- */
@media (prefers-reduced-motion:reduce){
  html body *,html body *:before,html body *:after{transition:none!important;animation-duration:.01ms!important;animation-iteration-count:1!important;scroll-behavior:auto!important}
}
