/* =====================================================================
   Jostino seller panel (/panel) theme.
   Minimal and flat: neutral gray surfaces, one brand color (green) only for
   the active state, the primary action and focus. RTL, responsive.
   Loaded only by AppPanelProvider (STYLES_AFTER, versioned by filemtime),
   after tables.css and dashboards.css, so its tokens win.
   ===================================================================== */

:root {
    --jp-brand: #00A651;
    --jp-brand-hover: #008C44;
    --jp-brand-soft: #E8F6EE;
    --jp-brand-ring: rgba(0, 166, 81, .22);
    /* Filled buttons with white text: deeper brand shade so text passes WCAG AA (>= 4.5:1) */
    --jp-action: #007F3E;
    --jp-action-hover: #006B34;

    --jp-bg: #FAFAFA;
    --jp-surface: #FFFFFF;
    --jp-soft: #F5F5F5;
    --jp-border: #E5E5E5;
    --jp-border-strong: #D4D4D4;
    --jp-text: #262626;
    --jp-text-2: #525252;
    --jp-muted: #8A8A8A;

    --jp-success: #16A34A;
    --jp-warning: #D97706;
    --jp-danger: #DC2626;

    --jp-radius: 14px;
    --jp-radius-sm: 10px;
    --jp-shadow: 0 1px 2px rgba(0, 0, 0, .04);
    --jp-shadow-pop: 0 12px 32px -8px rgba(0, 0, 0, .16), 0 2px 6px rgba(0, 0, 0, .05);
    --jp-topbar-h: 64px;
    --jp-ease: cubic-bezier(.2, .7, .2, 1);

    /* Shared table tokens (tables.css) follow the same neutral palette */
    --jt-primary: var(--jp-brand);
    --jt-primary-hover: var(--jp-brand-hover);
    --jt-primary-soft: var(--jp-brand-soft);
    --jt-radius: var(--jp-radius);
}

.dark {
    --jp-brand-soft: rgba(0, 166, 81, .14);
    --jp-bg: #111111;
    --jp-surface: #18181B;
    --jp-soft: rgba(255, 255, 255, .04);
    --jp-border: rgba(255, 255, 255, .09);
    --jp-border-strong: rgba(255, 255, 255, .16);
    --jp-text: #E5E5E5;
    --jp-text-2: #C4C4C4;
    --jp-muted: #8F8F8F;
}

/* ===================== Base ===================== */

body.fi-body {
    background: var(--jp-bg);
    color: var(--jp-text);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

.fi-body ::selection {
    background: var(--jp-brand-soft);
    color: var(--jp-text);
}

/* Numbers line up in cards, tables and stats */
.fi-body .fi-wi-stats-overview-stat-value,
.fi-body .fi-ta-text-item,
.fi-body .jp-num {
    font-variant-numeric: tabular-nums;
}

/* Keyboard focus is always visible, in the brand color */
.fi-body :focus-visible {
    outline: 2px solid var(--jp-brand);
    outline-offset: 2px;
}

/* ===================== Topbar ===================== */

.fi-topbar-ctn {
    position: sticky;
    top: 0;
    z-index: 30;
}

.fi-topbar {
    min-height: var(--jp-topbar-h);
    background: color-mix(in oklab, var(--jp-surface) 88%, transparent) !important;
    background-image: none !important;
    -webkit-backdrop-filter: saturate(180%) blur(10px);
    backdrop-filter: saturate(180%) blur(10px);
    border-bottom: 1px solid var(--jp-border);
    box-shadow: none !important;
    padding-inline: 16px;
}

.fi-topbar .fi-icon-btn {
    border-radius: var(--jp-radius-sm);
    color: var(--jp-text-2);
}

.fi-topbar .fi-icon-btn:hover {
    background: var(--jp-soft);
}

.fi-topbar .fi-logo {
    height: 2rem !important;
}

/* Letter avatar (DefaultAvatarProvider): no frame, a soft ring on hover / open */
.fi-user-menu-trigger .fi-user-avatar {
    width: 36px;
    height: 36px;
    border: 0;
    border-radius: 9999px;
    transition: box-shadow .15s var(--jp-ease);
}

.fi-user-menu-trigger:hover .fi-user-avatar,
.fi-user-menu-trigger[aria-expanded="true"] .fi-user-avatar {
    box-shadow: 0 0 0 3px var(--jp-brand-soft);
}

.fi-user-menu-trigger:focus-visible {
    outline: none;
}

.fi-user-menu-trigger:focus-visible .fi-user-avatar {
    box-shadow: 0 0 0 2px var(--jp-surface), 0 0 0 4px var(--jp-action);
}

/* ===================== Layout ===================== */

.fi-layout {
    background: transparent;
}

.fi-main-ctn {
    min-width: 0;
}

.fi-main {
    background: transparent;
    padding-inline: 16px;
    padding-block: 20px 40px;
    /* One content width for every page (beats Filament's per-page fi-width-* classes) */
    max-width: 1320px !important;
    margin-inline: auto;
}

@media (min-width: 1024px) {
    .fi-main {
        padding-inline: 32px;
        padding-block: 28px 56px;
    }
}

/* ===================== Sidebar ===================== */

.fi-sidebar {
    background: var(--jp-surface) !important;
    border-inline-end: 1px solid var(--jp-border);
}

.fi-sidebar-nav {
    background: transparent;
    padding: 16px 12px 24px;
    gap: 6px;
    scrollbar-width: thin;
}

.fi-sidebar-group-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--jp-muted);
    letter-spacing: 0;
}

.fi-sidebar-group-btn {
    padding-inline: 12px;
}

.fi-sidebar-item-btn {
    min-height: 42px;
    padding: 8px 12px;
    border-radius: var(--jp-radius-sm);
    background: transparent !important;
    color: var(--jp-text-2);
    transition: background-color .15s var(--jp-ease), color .15s var(--jp-ease);
}

.fi-sidebar-item-btn > .fi-icon {
    width: 20px;
    height: 20px;
    color: var(--jp-muted);
}

.fi-sidebar-item-label {
    font-size: 14px;
    font-weight: 500;
    color: inherit;
}

.fi-sidebar-item-btn:hover {
    background: var(--jp-soft) !important;
    color: var(--jp-text);
}

.fi-sidebar-item.fi-active > .fi-sidebar-item-btn {
    background: var(--jp-brand-soft) !important;
    color: var(--jp-brand);
}

.fi-sidebar-item.fi-active > .fi-sidebar-item-btn > .fi-icon,
.fi-sidebar-item.fi-active > .fi-sidebar-item-btn > .fi-sidebar-item-label {
    color: var(--jp-brand) !important;
    font-weight: 600;
}

.fi-sidebar-item-grouped-border-part {
    background: var(--jp-border) !important;
}

/* Mobile drawer: full height, soft overlay */
.fi-sidebar-close-overlay {
    background: rgba(0, 0, 0, .32) !important;
    -webkit-backdrop-filter: blur(2px);
    backdrop-filter: blur(2px);
}

@media (max-width: 1023px) {
    .fi-sidebar {
        width: min(86vw, 320px);
        box-shadow: var(--jp-shadow-pop);
    }
}


/* ===================== User menu header ===================== */

/* Custom identity block (USER_MENU_PROFILE_BEFORE hook) replaces Filament's plain header */
.jp-um-head ~ .fi-dropdown-header {
    display: none;
}

.jp-um-head {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 14px 12px;
    border-bottom: 1px solid var(--jp-border);
}

.jp-um-avatar {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    border-radius: 9999px;
    object-fit: cover;
    border: 0;
    background: var(--jp-soft);
}

.jp-um-main {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.jp-um-name {
    font-size: 14px;
    font-weight: 700;
    color: var(--jp-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.jp-um-mobile {
    font-size: 12px;
    color: var(--jp-muted);
    font-variant-numeric: tabular-nums;
    letter-spacing: .02em;
}

.jp-um-wallet {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin: 8px 8px 0;
    padding: 10px 12px;
    border-radius: var(--jp-radius-sm);
    background: var(--jp-soft);
    font-size: 12px;
    color: var(--jp-muted);
}

.jp-um-wallet b {
    font-size: 13px;
    font-weight: 800;
    color: var(--jp-text);
    font-variant-numeric: tabular-nums;
}

.jp-um-wallet.is-empty b {
    color: var(--jp-danger);
}

/* The row is a link to the top-up modal; the "+" shows it is actionable */
a.jp-um-wallet {
    text-decoration: none;
    transition: background-color .15s var(--jp-ease);
}

a.jp-um-wallet:hover {
    background: color-mix(in srgb, var(--jp-text) 7%, transparent);
}

a.jp-um-wallet:focus-visible {
    outline: none;
    box-shadow: 0 0 0 2px var(--jp-action);
}

.jp-um-wallet em {
    display: inline-grid;
    place-items: center;
    width: 18px;
    height: 18px;
    margin-inline-start: 6px;
    border-radius: 6px;
    background: var(--jp-action);
    color: #fff;
    font-style: normal;
    font-weight: 700;
    font-size: 13px;
    line-height: 1;
    vertical-align: middle;
}

.fi-user-menu .fi-dropdown-panel,
.fi-dropdown-panel:has(.jp-um-head) {
    min-width: 248px;
}

/* Logout: neutral at rest, red only on hover so it is clearly the "leave" action */
/* Logout posts a form, the other items are links: that tells them apart */
.fi-dropdown-panel:has(.jp-um-head) form .fi-dropdown-list-item:hover {
    color: var(--jp-danger);
    background: rgba(220, 38, 38, .06);
}

.fi-dropdown-panel:has(.jp-um-head) form .fi-dropdown-list-item:hover .fi-icon {
    color: var(--jp-danger);
}


/* ===================== Page header ===================== */

.fi-header {
    gap: 12px;
    margin-bottom: 4px;
}

.fi-header-heading {
    font-size: 22px;
    font-weight: 700;
    line-height: 1.5;
    letter-spacing: 0;
    color: var(--jp-text);
}

.fi-header-subheading {
    margin-top: 4px;
    font-size: 13px;
    line-height: 1.9;
    color: var(--jp-muted);
    max-width: 60ch;
}

.fi-breadcrumbs {
    font-size: 12px;
}

.fi-breadcrumbs a,
.fi-breadcrumbs span {
    color: var(--jp-muted);
}

@media (max-width: 640px) {
    .fi-header-heading {
        font-size: 19px;
    }

    /* Header actions take the full width on phones */
    .fi-header-actions-ctn,
    .fi-header-actions-ctn .fi-ac {
        width: 100%;
    }

    .fi-header-actions-ctn .fi-btn {
        flex: 1 1 auto;
    }
}

/* ===================== Sections / cards ===================== */

.fi-section:not(.fi-section-not-contained) {
    background: var(--jp-surface);
    border: 1px solid var(--jp-border);
    border-radius: var(--jp-radius);
    box-shadow: none !important;
    --tw-ring-color: transparent !important;
}

.fi-section-header {
    padding: 16px 20px;
    gap: 12px;
}

.fi-section-has-header:not(.fi-section-not-contained) > .fi-section-content-ctn {
    border-top: 1px solid var(--jp-border) !important;
}

.fi-section-header-heading {
    font-size: 15px;
    font-weight: 700;
    color: var(--jp-text);
}

.fi-section-header-description {
    margin-top: 2px;
    font-size: 12.5px;
    line-height: 1.8;
    color: var(--jp-muted);
}

.fi-section-header > .fi-icon {
    width: 36px;
    height: 36px;
    padding: 8px;
    border-radius: var(--jp-radius-sm);
    background: var(--jp-soft);
    color: var(--jp-text-2);
}

.fi-section-content {
    padding: 20px;
}

@media (max-width: 640px) {
    .fi-section-header {
        padding: 14px 16px;
    }

    .fi-section-content {
        padding: 16px;
    }
}

/* ===================== Form fields ===================== */

.fi-fo-field-label-content {
    font-size: 13px;
    font-weight: 600;
    color: var(--jp-text);
}

.fi-fo-field-label-required-mark {
    color: var(--jp-danger);
}

.fi-input-wrp {
    min-height: 44px;
    border-radius: var(--jp-radius-sm) !important;
    background: var(--jp-surface) !important;
    box-shadow: none !important;
    border: 1px solid var(--jp-border-strong);
    --tw-ring-color: transparent !important;
    transition: border-color .15s var(--jp-ease), box-shadow .15s var(--jp-ease);
}

.fi-input-wrp:hover {
    border-color: color-mix(in oklab, var(--jp-text) 30%, var(--jp-border-strong));
}

.fi-input-wrp:focus-within {
    border-color: var(--jp-brand) !important;
    box-shadow: 0 0 0 3px var(--jp-brand-ring) !important;
}

.fi-input-wrp input,
.fi-input-wrp textarea,
.fi-input-wrp select {
    font-size: 14px;
    color: var(--jp-text);
}

.fi-input-wrp input::placeholder,
.fi-input-wrp textarea::placeholder {
    color: var(--jp-muted);
    opacity: 1;
}

.fi-input-wrp-prefix,
.fi-input-wrp-suffix {
    color: var(--jp-muted);
}

/* Error state stays red, never the brand color */
.fi-fo-field:has(.fi-fo-field-wrp-error-message) .fi-input-wrp {
    border-color: var(--jp-danger) !important;
}

.fi-fo-field:has(.fi-fo-field-wrp-error-message) .fi-input-wrp:focus-within {
    box-shadow: 0 0 0 3px rgba(220, 38, 38, .18) !important;
}

.fi-fo-field-wrp-error-message {
    font-size: 12px;
    color: var(--jp-danger);
}

/* Helper text under a field */
.fi-fo-field-content-col > .fi-sc-text,
.fi-fo-field .fi-fo-field-content-col p {
    color: var(--jp-muted);
}

/* File upload drop zone */
.fi-fo-file-upload .filepond--root {
    margin-bottom: 0;
    font-family: inherit;
}

.fi-fo-file-upload .filepond--panel-root {
    background: var(--jp-bg) !important;
    border: 1px dashed var(--jp-border-strong);
    border-radius: var(--jp-radius) !important;
}

.fi-fo-file-upload .filepond--drop-label {
    color: var(--jp-muted);
    min-height: 120px;
}

.fi-fo-file-upload .filepond--drop-label label {
    font-size: 13px;
    line-height: 2;
}

.fi-fo-file-upload .filepond--label-action {
    color: var(--jp-brand);
    text-decoration: none;
    font-weight: 600;
}

/* ===================== Buttons ===================== */

.fi-btn {
    min-height: 40px;
    padding-inline: 16px;
    border-radius: var(--jp-radius-sm) !important;
    font-size: 14px;
    font-weight: 600;
    box-shadow: none !important;
    transition: background-color .15s var(--jp-ease), border-color .15s var(--jp-ease), color .15s var(--jp-ease);
}

.fi-btn.fi-color-primary:not(.fi-outlined) {
    background: var(--jp-brand) !important;
    color: #fff !important;
}

.fi-btn.fi-color-primary:not(.fi-outlined):hover {
    background: var(--jp-brand-hover) !important;
}

/* Gray / secondary buttons: outlined neutral */
.fi-btn.fi-color-gray {
    background: var(--jp-surface) !important;
    border: 1px solid var(--jp-border-strong);
    color: var(--jp-text) !important;
    --tw-ring-color: transparent !important;
}

.fi-btn.fi-color-gray:hover {
    background: var(--jp-soft) !important;
}

.fi-btn .fi-icon {
    width: 18px;
    height: 18px;
}

/* Form footer: primary action is easy to reach on phones */
.fi-sc-actions,
.fi-form-actions {
    gap: 8px;
}

@media (max-width: 640px) {
    .fi-form-actions .fi-btn,
    .fi-sc-actions .fi-ac .fi-btn {
        width: 100%;
        min-height: 46px;
    }
}

/* Icon buttons (table row actions, topbar) */
.fi-icon-btn {
    border-radius: var(--jp-radius-sm);
    transition: background-color .15s var(--jp-ease), color .15s var(--jp-ease);
}

.fi-ta .fi-icon-btn {
    width: 34px;
    height: 34px;
    color: var(--jp-muted);
}

.fi-ta .fi-icon-btn:hover {
    background: var(--jp-soft);
    color: var(--jp-text);
}

.fi-ta .fi-icon-btn.fi-color-primary:hover,
.fi-ta .fi-icon-btn.fi-color-success:hover {
    color: var(--jp-brand);
}

.fi-ta .fi-icon-btn.fi-color-danger:hover {
    color: var(--jp-danger);
}

/* ===================== Badges ===================== */

.fi-badge {
    border-radius: 9999px;
    padding: 2px 10px;
    font-size: 12px;
    font-weight: 600;
    box-shadow: none !important;
    --tw-ring-color: transparent !important;
}

/* ===================== Tabs ===================== */

.fi-tabs {
    background: var(--jp-soft);
    border-radius: var(--jp-radius-sm);
    padding: 4px;
    box-shadow: none !important;
    --tw-ring-color: transparent !important;
    gap: 2px;
    overflow-x: auto;
    scrollbar-width: none;
}

.fi-tabs-item {
    border-radius: 8px;
    font-size: 13px;
    white-space: nowrap;
}

.fi-tabs-item.fi-active {
    background: var(--jp-surface);
    box-shadow: var(--jp-shadow);
}

.fi-tabs-item.fi-active .fi-tabs-item-label,
.fi-tabs-item.fi-active .fi-icon {
    color: var(--jp-text) !important;
}

/* ===================== Invoices ===================== */

/* Invoice number reads as a code: LTR, tabular, a little tracking */
.ji-num {
    font-variant-numeric: tabular-nums;
    letter-spacing: .02em;
    text-align: start;
}

.ji-amount {
    font-variant-numeric: tabular-nums;
}

/* Row "پرداخت": compact, the only filled button in the row, AA-contrast green */
/* Row buttons: same size, text only. "پرداخت" filled, "جزئیات" outlined neutral */
.fi-btn.ji-pay,
.fi-btn.ji-view {
    min-height: 32px;
    min-width: 72px;
    padding-inline: 14px;
    justify-content: center;
    border-radius: 8px !important;
    font-size: 12.5px;
}

.fi-btn.ji-pay {
    background: var(--jp-action) !important;
    color: #fff !important;
}

.fi-btn.ji-pay:hover {
    background: var(--jp-action-hover) !important;
}

.fi-btn.ji-view {
    background: var(--jp-surface) !important;
    border: 1px solid var(--jp-border-strong) !important;
    color: var(--jp-text-2) !important;
    box-shadow: none !important;
    --tw-ring-color: transparent !important;
}

.fi-btn.ji-view:hover {
    background: var(--jp-soft) !important;
    color: var(--jp-text) !important;
}

/* Invoice page bar: same width as the sheet, back link on the start side, pay on the end side */
.ji-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    width: 100%;
    max-width: 820px;
    margin: 0 auto;
}

.ji-back {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    min-height: 40px;
    padding-inline: 8px 12px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    color: var(--jp-text-2);
}

.ji-back svg {
    width: 18px;
    height: 18px;
}

.ji-back:hover {
    background: var(--jp-soft);
    color: var(--jp-text);
}

.ji-bar-pay {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding-inline: 22px;
    border-radius: 10px;
    background: var(--jp-action);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    transition: background-color .15s var(--jp-ease);
}

.ji-bar-pay:hover {
    background: var(--jp-action-hover);
}

.ji-bar-pay:focus-visible,
.ji-back:focus-visible {
    outline: none;
    box-shadow: 0 0 0 2px var(--jp-surface), 0 0 0 4px var(--jp-action);
}

/* Row actions: even gaps, the icon buttons quiet until hovered */
.fi-ta-ctn .fi-ta-actions {
    gap: 6px;
    align-items: center;
}

.fi-ta-ctn .fi-ta-actions .fi-icon-btn.fi-color-gray {
    color: var(--jp-muted);
}

.fi-ta-ctn .fi-ta-actions .fi-icon-btn.fi-color-gray:hover {
    color: var(--jp-text);
    background: var(--jp-soft);
}

.ji-note {
    max-width: 820px;
    width: 100%;
    margin: 0 auto;
    padding: 12px 16px;
    border-radius: var(--jp-radius-sm);
    background: rgba(217, 119, 6, .08);
    color: #92400E;
    font-size: 13px;
}

.ji-note--ok {
    background: rgba(22, 163, 74, .08);
    color: #166534;
}

.ji-note--bad {
    background: rgba(220, 38, 38, .07);
    color: #991B1B;
}

/* ===================== Widgets ===================== */

.fi-wi-stats-overview-stat,
.fi-wi-chart > .fi-section {
    border: 1px solid var(--jp-border);
    border-radius: var(--jp-radius);
    box-shadow: none !important;
    --tw-ring-color: transparent !important;
}

.fi-wi-stats-overview-stat-label {
    font-size: 13px;
    color: var(--jp-muted);
}

.fi-wi-stats-overview-stat-value {
    font-size: 24px;
    font-weight: 700;
    color: var(--jp-text);
}

/* ===================== Seller dashboard (SellerDashboardWidget) =====================
   Torob-style and calm: 3 summary cards, one chart, one table. Neutral cards, no colored
   stripes; color only for the top-up "+", the chart bars and status chips. */

.jsd {
    display: flex;
    flex-direction: column;
    gap: 16px;
    transition: opacity .15s var(--jp-ease);
}

.jsd--busy { opacity: .6; }

.jsd-cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.jsd-card,
.jsd-panel {
    min-width: 0;
    border: 1px solid var(--jp-border);
    border-radius: var(--jp-radius);
    background: var(--jp-surface);
}

.jsd-card {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 16px 18px;
}

.jsd-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 32px;
}

.jsd-label {
    font-size: 13px;
    font-weight: 600;
    color: var(--jp-muted);
}

.jsd-value {
    display: flex;
    align-items: baseline;
    gap: 6px;
    color: var(--jp-text);
}

.jsd-value bdi {
    font-size: 26px;
    font-weight: 800;
    letter-spacing: -.01em;
    font-variant-numeric: tabular-nums;
}

.jsd-value span {
    font-size: 13px;
    color: var(--jp-muted);
}

.jsd-wallet.is-empty .jsd-value bdi { color: var(--jp-danger); }

.jsd-sub {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    min-height: 22px;
    font-size: 12px;
    color: var(--jp-muted);
}

.jsd-bad { color: var(--jp-danger); }

.jsd-chip {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    line-height: 18px;
    color: var(--jp-text-2);
    background: var(--jp-soft);
}

.jsd-ltr { direction: ltr; }
.jsd-chip.is-ok { color: #15803D; background: rgba(22, 163, 74, .1); }
.jsd-chip.is-warn { color: #B45309; background: rgba(217, 119, 6, .1); }
.jsd-chip.is-bad { color: #B91C1C; background: rgba(220, 38, 38, .08); }

/* Torob-style "+" next to the balance: the one filled brand element on the page */
.jsd-plus {
    display: inline-grid;
    place-items: center;
    width: 36px;
    height: 32px;
    border: 0;
    border-radius: 9px;
    background: var(--jp-action);
    color: #fff;
    cursor: pointer;
    transition: background-color .15s var(--jp-ease);
}

.jsd-plus svg { width: 18px; height: 18px; }
.jsd-plus:hover { background: var(--jp-action-hover); }
.jsd-plus:focus-visible { outline: none; box-shadow: 0 0 0 2px var(--jp-surface), 0 0 0 4px var(--jp-action); }

/* Panels (chart, table) */
.jsd-panel { padding: 16px 18px 18px; }

.jsd-panel-h {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 14px;
}

.jsd-title {
    margin: 0;
    font-size: 15px;
    font-weight: 700;
    color: var(--jp-text);
}

.jsd-desc {
    margin: 2px 0 0;
    font-size: 12px;
    color: var(--jp-muted);
}

.jsd-tools {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Segmented control (week / two weeks) */
.jsd-seg {
    display: inline-flex;
    padding: 3px;
    border-radius: 10px;
    background: var(--jp-soft);
    border: 1px solid var(--jp-border);
}

.jsd-seg button {
    min-height: 30px;
    padding-inline: 12px;
    border: 0;
    border-radius: 7px;
    background: transparent;
    font-size: 12px;
    font-weight: 600;
    color: var(--jp-muted);
    cursor: pointer;
}

.jsd-seg button.is-on {
    background: var(--jp-surface);
    color: var(--jp-text);
    box-shadow: 0 1px 2px rgba(0, 0, 0, .08);
}

.jsd-icon-btn {
    display: inline-grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border: 1px solid var(--jp-border);
    border-radius: 10px;
    background: var(--jp-surface);
    color: var(--jp-muted);
    cursor: pointer;
}

.jsd-icon-btn svg { width: 16px; height: 16px; }
.jsd-icon-btn:hover { background: var(--jp-soft); color: var(--jp-text); }
.jsd--busy .jsd-icon-btn svg { animation: jd-spin .8s linear infinite; }

/* Chart: dates run left -> right like Torob */
.jsd-chart {
    display: block;
    width: 100%;
    height: 200px;
}

.jsd-grid { stroke: var(--jp-border); stroke-width: 1; stroke-dasharray: 3 4; vector-effect: non-scaling-stroke; }
.jsd-axis { stroke: var(--jp-border-strong); stroke-width: 1; vector-effect: non-scaling-stroke; }
.jsd-bar { fill: var(--jp-brand); opacity: .85; }
.jsd-bar:hover { opacity: 1; }
.jsd-line { fill: none; stroke: #D97706; stroke-width: 2; stroke-linejoin: round; }

.jsd-x {
    direction: ltr;
    display: flex;
    margin-top: 6px;
}

.jsd-x span {
    flex: 1;
    text-align: center;
    font-size: 11px;
    color: var(--jp-muted);
    white-space: nowrap;
}

.jsd-legend {
    display: flex;
    justify-content: center;
    gap: 18px;
    margin-top: 12px;
    font-size: 12px;
    color: var(--jp-muted);
}

.jsd-legend i {
    display: inline-block;
    margin-inline-end: 6px;
    vertical-align: middle;
}

.jsd-legend i.is-bar { width: 10px; height: 10px; border-radius: 3px; background: var(--jp-brand); }
.jsd-legend i.is-line { width: 14px; height: 2px; border-radius: 2px; background: #D97706; }

/* Table */
.jsd-table-wrap { overflow-x: auto; }

.jsd-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.jsd-table th {
    padding: 10px 12px;
    border-bottom: 1px solid var(--jp-border);
    font-size: 12px;
    font-weight: 600;
    color: var(--jp-muted);
    text-align: start;
    white-space: nowrap;
}

.jsd-table td {
    padding: 12px;
    border-bottom: 1px solid var(--jp-border);
    color: var(--jp-text);
}

.jsd-table tbody tr:last-child td { border-bottom: 0; }
.jsd-table tbody tr:hover td { background: var(--jp-soft); }

.jsd-table .is-rank { width: 56px; color: var(--jp-muted); }
.jsd-table .is-num { width: 110px; text-align: end; font-variant-numeric: tabular-nums; white-space: nowrap; }
.jsd-table td.is-title { max-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.jsd-empty {
    padding: 28px 16px;
    border-radius: var(--jp-radius-sm);
    background: var(--jp-soft);
    text-align: center;
    font-size: 13px;
    color: var(--jp-muted);
}

@media (max-width: 1023px) {
    .jsd-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .jsd-wallet { grid-column: 1 / -1; }
}

@media (max-width: 640px) {
    .jsd { gap: 12px; }
    .jsd-cards { grid-template-columns: minmax(0, 1fr); gap: 12px; }
    .jsd-card, .jsd-panel { padding: 14px; }
    .jsd-value bdi { font-size: 22px; }
    .jsd-chart { height: 160px; }
    .jsd-tools { width: 100%; justify-content: space-between; }
    .jsd-plus { width: 44px; height: 40px; }
    .jsd-table .is-num { width: 72px; }
    .jsd-table th, .jsd-table td { padding: 10px 8px; }
}

/* ===================== Dropdowns, modals, notifications ===================== */

.fi-dropdown-panel {
    border-radius: var(--jp-radius) !important;
    border: 1px solid var(--jp-border);
    box-shadow: var(--jp-shadow-pop) !important;
    --tw-ring-color: transparent !important;
}

.fi-dropdown-list-item {
    border-radius: 8px;
    font-size: 13px;
}

.fi-modal-window {
    border-radius: 18px !important;
    border: 1px solid var(--jp-border);
    box-shadow: var(--jp-shadow-pop) !important;
}

.fi-modal-heading {
    font-size: 16px;
    font-weight: 700;
}

/* ---------- Toast notifications ----------
   Below the sticky topbar (it used to sit on it), white card with a status stripe on the start
   edge, a tinted round icon and a soft lift. Status classes come from Filament (fi-status-*). */
.fi-no.fi-vertical-align-start {
    top: calc(var(--jp-topbar-h) + 12px) !important;
}

.fi-no-notification {
    --nc: var(--jp-text-2);
    --ns: var(--jp-soft);
    position: relative;
    /* icon, text and close button share one centre line */
    align-items: center !important;
    gap: 12px !important;
    padding: 14px 14px 14px 16px !important;
    padding-inline-start: 18px !important;
    border: 1px solid var(--jp-border) !important;
    border-radius: 16px !important;
    background: var(--jp-surface) !important;
    box-shadow: 0 18px 40px -18px rgba(0, 0, 0, .28), 0 2px 6px rgba(0, 0, 0, .05) !important;
    --tw-ring-color: transparent !important;
    overflow: hidden;
}

.fi-no-notification.fi-status-success { --nc: #15803D; --ns: #E8F6EE; }
.fi-no-notification.fi-status-danger  { --nc: #DC2626; --ns: #FDECEC; }
.fi-no-notification.fi-status-warning { --nc: #B45309; --ns: #FFF4E5; }
.fi-no-notification.fi-status-info    { --nc: #2563EB; --ns: #EFF4FF; }

/* Status stripe */
.fi-no-notification::before {
    content: "";
    position: absolute;
    inset-block: 0;
    inset-inline-start: 0;
    width: 4px;
    background: var(--nc);
}

/* Icon in a tinted circle */
.fi-no-notification .fi-no-notification-icon {
    flex-shrink: 0;
    width: 34px !important;
    height: 34px !important;
    padding: 7px;
    border-radius: 50%;
    background: var(--ns);
    color: var(--nc) !important;
}

.fi-no-notification .fi-no-notification-main {
    gap: 8px;
    margin-top: 0 !important;
    align-self: center;
}

.fi-no-notification .fi-no-notification-text {
    gap: 2px;
}

.fi-no-notification .fi-no-notification-title {
    font-size: 14px;
    font-weight: 700;
    line-height: 1.6;
    color: var(--jp-text);
}

.fi-no-notification .fi-no-notification-body {
    font-size: 12.5px;
    line-height: 1.9;
    color: var(--jp-muted) !important;
}

/* Close: quiet round button */
.fi-no-notification .fi-icon-btn {
    align-self: center;
    border-radius: 50%;
    color: var(--jp-muted);
}

.fi-no-notification .fi-icon-btn:hover {
    background: var(--jp-soft);
    color: var(--jp-text);
}

/* Slide down from under the topbar instead of sliding in sideways */
.fi-no .fi-no-notification.fi-transition-enter-start {
    transform: translateY(-10px) scale(.98) !important;
    opacity: 0;
}

.fi-no-notification.fi-transition-leave-end {
    transform: scale(.96) !important;
    opacity: 0;
}

@media (max-width: 640px) {
    .fi-no.fi-vertical-align-start {
        top: calc(var(--jp-topbar-h) + 8px) !important;
    }
}

/* ===================== Pagination ===================== */

.fi-pagination-item-btn {
    border-radius: 8px;
}

.fi-pagination-item.fi-active .fi-pagination-item-label {
    color: var(--jp-action);
}

/* "در هر صفحه": one compact pill. Only the wrapper draws the frame (the inner <select> got
   its own green focus box), label as a muted prefix, our own chevron instead of the native one */
.fi-pagination-records-per-page-select .fi-input-wrp {
    min-height: 38px !important;
    border: 1px solid var(--jp-border-strong) !important;
    border-radius: 10px !important;
    background: var(--jp-surface) !important;
    box-shadow: none !important;
    overflow: hidden;
}

.fi-pagination-records-per-page-select .fi-input-wrp:hover {
    border-color: var(--jp-muted) !important;
}

.fi-pagination-records-per-page-select .fi-input-wrp:focus-within {
    border-color: var(--jp-action) !important;
    box-shadow: 0 0 0 3px var(--jp-brand-ring) !important;
}

.fi-pagination-records-per-page-select .fi-input-wrp-prefix {
    padding-inline: 12px 10px;
    border-inline-end: 1px solid var(--jp-border);
    background: var(--jp-bg);
    font-size: 12.5px;
    color: var(--jp-muted);
    white-space: nowrap;
}

.fi-pagination-records-per-page-select select.fi-select-input,
.fi-pagination-records-per-page-select select.fi-select-input:focus {
    min-width: 72px;
    height: 36px;
    padding-block: 0 !important;
    padding-inline: 14px 34px !important;
    border: 0 !important;
    outline: none !important;
    box-shadow: none !important;
    --tw-ring-shadow: 0 0 #0000 !important;
    background-color: transparent !important;
    /* chevron on the end side (left in RTL) */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%23737373'%3E%3Cpath fill-rule='evenodd' d='M5.23 7.21a.75.75 0 0 1 1.06.02L10 11.17l3.71-3.94a.75.75 0 1 1 1.08 1.04l-4.25 4.5a.75.75 0 0 1-1.08 0l-4.25-4.5a.75.75 0 0 1 .02-1.06Z' clip-rule='evenodd'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: left 10px center !important;
    background-size: 16px 16px !important;
    -webkit-appearance: none;
    appearance: none;
    font-size: 13px;
    font-weight: 700;
    color: var(--jp-text);
    font-variant-numeric: tabular-nums;
    cursor: pointer;
}

/* The open list is drawn by the browser; these are the parts it lets us style */
.fi-pagination-records-per-page-select select.fi-select-input option {
    background: var(--jp-surface);
    color: var(--jp-text);
    font-weight: 600;
}

.fi-pagination-records-per-page-select select.fi-select-input option:checked {
    background: var(--jp-brand-soft);
    color: var(--jp-action);
}

/* ===================== Store cards (Stores list) ===================== */

.fi-ta-content-grid .fi-ta-record {
    border: 1px solid var(--jp-border) !important;
    border-radius: var(--jp-radius) !important;
    background: var(--jp-surface) !important;
    box-shadow: none !important;
    --tw-ring-color: transparent !important;
    overflow: hidden;
    transition: border-color .15s var(--jp-ease), box-shadow .15s var(--jp-ease);
}

.fi-ta-content-grid .fi-ta-record:hover {
    border-color: var(--jp-border-strong) !important;
    box-shadow: 0 6px 20px -12px rgba(0, 0, 0, .18) !important;
}

/* Card body (resources/views/filament/app/stores/card.blade.php) */
.jsc {
    display: flex;
    flex-direction: column;
    gap: 14px;
    width: 100%;
}

.jsc-head {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

/* Logo tile: real logo on white, or a tinted monogram (no generic avatar) */
.jsc-logo {
    display: grid;
    place-items: center;
    flex-shrink: 0;
    width: 52px;
    height: 52px;
    overflow: hidden;
    border: 1px solid var(--jp-border);
    border-radius: 14px;
    background: var(--bg, var(--jp-brand-soft));
}

.jsc-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 6px;
    background: #fff;
}

.jsc-logo span {
    font-size: 22px;
    font-weight: 800;
    line-height: 1;
    color: var(--fg, var(--jp-action));
}

.jsc-id {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
    min-width: 0;
}

.jsc-title {
    margin: 0;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    font-size: 15px;
    font-weight: 700;
    color: var(--jp-text);
}

.jsc-domain {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    font-size: 12.5px;
    color: var(--jp-muted);
    text-align: right;
}

.jsc-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
    align-self: flex-start;
    padding: 2px 10px;
    border-radius: 999px;
    background: var(--jp-soft);
    font-size: 11.5px;
    font-weight: 700;
    line-height: 20px;
    color: var(--jp-muted);
}

.jsc-status::before {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #A3A3A3;
}

.jsc-status.is-on {
    background: rgba(22, 163, 74, .1);
    color: #15803D;
}

.jsc-status.is-on::before {
    background: #16A34A;
}

.jsc-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    border: 1px solid var(--jp-border);
    border-radius: 12px;
    background: var(--jp-bg);
}

.jsc-stats > div {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 10px 14px;
}

.jsc-stats > div + div {
    border-inline-start: 1px solid var(--jp-border);
}

.jsc-stat-l {
    font-size: 11.5px;
    color: var(--jp-muted);
}

.jsc-stat-v {
    font-size: 20px;
    font-weight: 800;
    color: var(--jp-text);
    font-variant-numeric: tabular-nums;
}

.jsc-stat-v.is-warn {
    color: #B45309;
}

.jsc-meta {
    font-size: 12px;
    color: var(--jp-muted);
}

/* Card footer: Filament's action row, separated by a hairline */
.fi-ta-content-grid .fi-ta-record .fi-ta-actions {
    justify-content: space-between;
    margin-top: 2px;
    padding-top: 12px;
    border-top: 1px solid var(--jp-border);
}

.fi-btn.jsc-edit {
    min-height: 34px;
    padding-inline: 16px;
    border-radius: 9px !important;
    background: var(--jp-surface) !important;
    border: 1px solid var(--jp-border-strong) !important;
    color: var(--jp-text) !important;
    box-shadow: none !important;
}

.fi-btn.jsc-edit:hover {
    background: var(--jp-soft) !important;
}

.jsc-visit {
    font-size: 12.5px;
    font-weight: 600;
    color: var(--jp-action) !important;
}

.jsc-visit .fi-icon {
    width: 16px;
    height: 16px;
    color: currentColor !important;
}

/* "افزودن فروشگاه": the page's one primary action, AA-contrast green */
.fi-btn.jsc-add {
    min-height: 42px;
    padding-inline: 18px 20px;
    background: var(--jp-action) !important;
    color: #fff !important;
}

.fi-btn.jsc-add:hover {
    background: var(--jp-action-hover) !important;
}

.fi-btn.jsc-add .fi-icon {
    color: #fff !important;
}

/* ===================== Store create / edit page ===================== */

.jp-steps {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.jp-steps li {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.jp-steps-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 26px;
    height: 26px;
    border-radius: 9999px;
    border: 1px solid var(--jp-border-strong);
    font-size: 12px;
    font-weight: 700;
    color: var(--jp-text-2);
    font-variant-numeric: tabular-nums;
}

.jp-steps li:first-child .jp-steps-num {
    border-color: var(--jp-brand);
    background: var(--jp-brand);
    color: #fff;
}

.jp-steps-title {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--jp-text);
}

.jp-steps-desc {
    display: block;
    margin-top: 2px;
    font-size: 12px;
    line-height: 1.8;
    color: var(--jp-muted);
}

.jp-status {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
}

.jp-status::before {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 9999px;
    background: currentColor;
}

.jp-status.is-on {
    color: var(--jp-success);
}

.jp-status.is-off {
    color: var(--jp-warning);
}

.jp-note {
    font-size: 12px;
    line-height: 1.9;
    color: var(--jp-muted);
}

/* ===================== Footer ===================== */

.jp-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    max-width: 1320px;
    width: 100%;
    margin: auto auto 0;
    padding: 16px;
    border-top: 1px solid var(--jp-border);
    font-size: 12px;
    color: var(--jp-muted);
}

.jp-footer a {
    color: var(--jp-text-2);
    font-weight: 600;
    text-decoration: none;
}

.jp-footer a:hover {
    color: var(--jp-brand);
}

@media (min-width: 1024px) {
    .jp-footer {
        padding-inline: 32px;
    }
}

/* ===================== SPA navigation progress ===================== */

/* Livewire's own thin progress bar replaces the old full-screen preloader */
#nprogress .bar {
    background: var(--jp-brand) !important;
    height: 2px !important;
}

#nprogress .peg {
    box-shadow: 0 0 8px var(--jp-brand), 0 0 4px var(--jp-brand) !important;
}

/* ===================== Motion ===================== */

@media (prefers-reduced-motion: reduce) {
    .fi-body *,
    .fi-body *::before,
    .fi-body *::after {
        transition-duration: 0s !important;
        animation-duration: 0s !important;
    }
}

/* ===================== Announcements (seller bell, inbox, pinned banner) =====================
   Ported from Persis Payam. Neutral cards; the tone colour is used only on the icon tile,
   the chip and the active marker. Views: filament/app/pages/announcements, announcements/{bell,banner}. */

.jan-tone-info    { --tone: #2563EB; --tone-soft: #EFF4FF; }
.jan-tone-tariff  { --tone: #B45309; --tone-soft: #FFF4E5; }
.jan-tone-warning { --tone: #DC2626; --tone-soft: #FDECEC; }
.jan-tone-success { --tone: #15803D; --tone-soft: #E8F6EE; }
.jan-tone-feature { --tone: #7C3AED; --tone-soft: #F3EEFF; }

/* Bell */
.jan-bell {
    position: relative;
    display: inline-grid;
    place-items: center;
    width: 40px;
    height: 40px;
    margin-inline-end: 4px;
    border-radius: 12px;
    color: var(--jp-text-2);
    transition: background-color .15s var(--jp-ease), color .15s var(--jp-ease);
}

.jan-bell:hover { background: var(--jp-soft); color: var(--jp-text); }
.jan-bell:focus-visible { outline: none; box-shadow: 0 0 0 2px var(--jp-action); }
.jan-bell-ic { width: 22px; height: 22px; }
.jan-bell.has-unread .jan-bell-ic { animation: jan-ring 2.4s ease-in-out 1; transform-origin: 50% 10%; }

.jan-bell-badge {
    position: absolute;
    top: 3px;
    inset-inline-end: 2px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 999px;
    background: #DC2626;
    color: #fff;
    font-size: 10.5px;
    font-weight: 800;
    line-height: 18px;
    text-align: center;
    box-shadow: 0 0 0 2px var(--jp-surface);
}

@keyframes jan-ring {
    0%, 60%, 100% { transform: rotate(0); }
    10%, 30% { transform: rotate(12deg); }
    20%, 40% { transform: rotate(-12deg); }
}

/* Pinned banner above every page */
.jan-banner {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 20px;
    padding: 12px 14px;
    border: 1px solid var(--jp-border);
    border-inline-start: 4px solid var(--tone);
    border-radius: var(--jp-radius);
    background: var(--jp-surface);
}

.jan-banner-icon { display: inline-grid; place-items: center; flex-shrink: 0; width: 38px; height: 38px; border-radius: 11px; background: var(--tone-soft); color: var(--tone); }
.jan-banner-icon svg { width: 20px; height: 20px; }
.jan-banner-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.jan-banner-text b { font-size: 14px; color: var(--jp-text); }
.jan-banner-text span { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 12.5px; color: var(--jp-muted); }
.jan-banner-btn { flex-shrink: 0; display: inline-flex; align-items: center; min-height: 36px; padding-inline: 14px; border-radius: 10px; background: var(--jp-action); color: #fff; font-size: 13px; font-weight: 700; }
.jan-banner-btn:hover { background: var(--jp-action-hover); }
.jan-banner-close { display: inline-grid; place-items: center; flex-shrink: 0; width: 34px; height: 34px; border: 0; border-radius: 9px; background: transparent; color: var(--jp-muted); cursor: pointer; }
.jan-banner-close:hover { background: var(--jp-soft); color: var(--jp-text); }
.jan-banner-close svg { width: 18px; height: 18px; }

/* Page */
.fi-page:has(.jan) .fi-page-header-main-ctn { padding-block: 0; gap: 0; }
.jan { display: flex; flex-direction: column; gap: 20px; }
.jan-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.jan-h1 { margin: 0; font-size: 22px; font-weight: 800; color: var(--jp-text); }
.jan-lead { margin: 4px 0 0; font-size: 13px; color: var(--jp-muted); }
.jan-ic { width: 18px; height: 18px; }

.jan-mark-all {
    display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding-inline: 14px;
    border: 1px solid var(--jp-border-strong); border-radius: 10px; background: var(--jp-surface);
    font-size: 13px; font-weight: 600; color: var(--jp-text-2); cursor: pointer;
}
.jan-mark-all:hover { background: var(--jp-soft); color: var(--jp-text); }

.jan-shell {
    display: grid;
    grid-template-columns: 380px minmax(0, 1fr);
    align-items: start;
    border: 1px solid var(--jp-border);
    border-radius: var(--jp-radius);
    background: var(--jp-surface);
    overflow: hidden;
}

.jan-list { border-inline-end: 1px solid var(--jp-border); min-height: 100%; }
.jan-list-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; border-bottom: 1px solid var(--jp-border); font-size: 13px; font-weight: 700; color: var(--jp-text); }
.jan-list-head em { font-style: normal; font-size: 11.5px; font-weight: 700; padding: 1px 8px; border-radius: 999px; background: rgba(220, 38, 38, .08); color: #B91C1C; }
.jan-list ul { margin: 0; padding: 0; list-style: none; max-height: calc(100dvh - 300px); overflow-y: auto; }

.jan-item {
    position: relative; display: flex; align-items: flex-start; gap: 12px; width: 100%;
    padding: 14px 16px; border: 0; border-bottom: 1px solid var(--jp-border); background: transparent;
    text-align: start; cursor: pointer; transition: background-color .12s var(--jp-ease);
}
.jan-item:hover { background: var(--jp-soft); }
.jan-item:focus-visible { outline: none; box-shadow: inset 0 0 0 2px var(--jp-action); }
.jan-item.is-active { background: var(--jp-bg); }
.jan-item.is-active::before { content: ""; position: absolute; inset-block: 10px; inset-inline-start: 0; width: 3px; border-radius: 0 3px 3px 0; background: var(--tone); }

.jan-item-icon, .jan-hero-icon { display: inline-grid; place-items: center; flex-shrink: 0; border-radius: 11px; background: var(--tone-soft); color: var(--tone); }
.jan-item-icon { width: 36px; height: 36px; }
.jan-item-icon svg { width: 19px; height: 19px; }
.jan-item-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.jan-item-top { display: flex; align-items: center; gap: 6px; font-size: 11.5px; color: var(--jp-muted); }
.jan-item-top time { margin-inline-start: auto; white-space: nowrap; }
.jan-item-title { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 13.5px; font-weight: 600; color: var(--jp-text-2); }
.jan-item.is-unread .jan-item-title { font-weight: 800; color: var(--jp-text); }
.jan-item-summary { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-size: 12.5px; line-height: 1.8; color: var(--jp-muted); }
.jan-dot { display: none; flex-shrink: 0; width: 8px; height: 8px; margin-top: 6px; border-radius: 50%; background: #DC2626; }
.jan-item.is-unread .jan-dot { display: block; }

.jan-chip { padding: 0 8px; border-radius: 999px; background: var(--tone-soft); color: var(--tone); font-size: 11px; font-weight: 700; line-height: 20px; }
.jan-pin { padding: 0 8px; border-radius: 999px; background: var(--jp-soft); color: var(--jp-text-2); font-size: 11px; font-weight: 600; line-height: 20px; }

/* Reading pane */
.jan-reader { padding: 26px 30px 24px; min-width: 0; }
.jan-hero { display: flex; gap: 16px; align-items: flex-start; padding-bottom: 18px; border-bottom: 1px solid var(--jp-border); }
.jan-hero-icon { width: 48px; height: 48px; border-radius: 14px; }
.jan-hero-icon svg { width: 24px; height: 24px; }
.jan-hero-meta { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--jp-muted); }
.jan-hero h2 { margin: 8px 0 0; font-size: 20px; font-weight: 800; line-height: 1.6; color: var(--jp-text); }
.jan-hero p { margin: 6px 0 0; font-size: 14px; line-height: 1.9; color: var(--jp-text-2); }

.jan-content { padding-top: 18px; font-size: 14.5px; line-height: 2.1; color: var(--jp-text); overflow-wrap: anywhere; }
.jan-content > :first-child { margin-top: 0; }
.jan-content h2 { margin: 20px 0 8px; font-size: 17px; font-weight: 800; }
.jan-content h3 { margin: 16px 0 6px; font-size: 15px; font-weight: 700; }
.jan-content p { margin: 0 0 12px; }
.jan-content ul, .jan-content ol { margin: 0 0 12px; padding-inline-start: 22px; }
.jan-content ul { list-style: disc; }
.jan-content ol { list-style: decimal; }
.jan-content a { color: var(--jp-action); text-decoration: underline; text-underline-offset: 3px; }
.jan-content blockquote { margin: 0 0 12px; padding: 10px 14px; border-inline-start: 3px solid var(--tone, var(--jp-border-strong)); border-radius: 0 10px 10px 0; background: var(--jp-bg); color: var(--jp-text-2); }
.jan-content table { width: 100%; margin: 0 0 14px; border-collapse: collapse; font-size: 13.5px; }
.jan-content th, .jan-content td { padding: 8px 12px; border: 1px solid var(--jp-border); text-align: start; }
.jan-content th { background: var(--jp-bg); font-weight: 700; }

.jan-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 22px; padding: 14px 16px; border-radius: 12px; background: var(--jp-bg); font-size: 13px; color: var(--jp-text-2); }
.jan-foot-btn { display: inline-flex; align-items: center; gap: 6px; min-height: 38px; padding-inline: 14px; border: 1px solid var(--jp-border-strong); border-radius: 10px; background: var(--jp-surface); font-weight: 700; color: var(--jp-text); }
.jan-foot-btn:hover { background: var(--jp-soft); }

/* Empty */
.jan-empty { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 56px 24px; border: 1px solid var(--jp-border); border-radius: var(--jp-radius); background: var(--jp-surface); text-align: center; }
.jan-empty-icon { display: inline-grid; place-items: center; width: 64px; height: 64px; margin-bottom: 8px; border-radius: 50%; background: var(--jp-soft); color: var(--jp-muted); }
.jan-empty-icon svg { width: 30px; height: 30px; }
.jan-empty b { font-size: 15px; color: var(--jp-text); }
.jan-empty p { margin: 0; max-width: 420px; font-size: 13px; line-height: 1.9; color: var(--jp-muted); }

@media (max-width: 1023px) {
    .jan-shell { grid-template-columns: minmax(0, 1fr); }
    .jan-list { border-inline-end: 0; border-bottom: 1px solid var(--jp-border); }
    .jan-list ul { max-height: 340px; }
    .jan-reader { padding: 20px 16px; }
}

@media (max-width: 640px) {
    .jan-lead { display: none; }
    .jan-banner { flex-wrap: wrap; }
    .jan-banner-text { flex-basis: calc(100% - 100px); }
    .jan-banner-btn { flex: 1; justify-content: center; }
    .jan-hero h2 { font-size: 18px; }
}

@media (prefers-reduced-motion: reduce) {
    .jan-bell.has-unread .jan-bell-ic { animation: none; }
}

/* ===================== Store profile (approved store, read-only) =====================
   resources/views/filament/app/stores/view.blade.php. Reuses .jsc-logo from the store cards. */

.fi-page:has(.jsv) .fi-page-header-main-ctn { padding-block: 0; gap: 0; }
.jsv { display: flex; flex-direction: column; gap: 16px; width: 100%; max-width: 820px; margin: 0 auto; }
.jsv > .ji-back { align-self: flex-start; }

.jsv-card {
    position: relative;
    overflow: hidden;
    border: 1px solid var(--jp-border);
    border-radius: 18px;
    background: var(--jp-surface);
}

.jsv-card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; background: var(--jp-brand); }

.jsv-hero { display: flex; align-items: center; gap: 16px; padding: 28px 28px 22px; }
.jsv-logo { width: 72px; height: 72px; border-radius: 18px; }
.jsv-logo span { font-size: 30px; }
.jsv-id { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.jsv-id h1 { margin: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 21px; font-weight: 800; color: var(--jp-text); }
.jsv-id bdi { font-size: 13.5px; color: var(--jp-muted); text-align: right; }

.jsv-badge {
    display: inline-flex; align-items: center; gap: 6px; flex-shrink: 0; align-self: flex-start;
    padding: 4px 12px 4px 10px; border-radius: 999px; background: rgba(22, 163, 74, .1);
    color: #15803D; font-size: 12.5px; font-weight: 700;
}
.jsv-badge svg { width: 18px; height: 18px; }

.jsv-stats { display: grid; grid-template-columns: repeat(3, 1fr); margin: 0 28px; border: 1px solid var(--jp-border); border-radius: 14px; background: var(--jp-bg); }
.jsv-stats > div { display: flex; flex-direction: column; gap: 2px; padding: 12px 16px; }
.jsv-stats > div + div { border-inline-start: 1px solid var(--jp-border); }
.jsv-stats span { font-size: 12px; color: var(--jp-muted); }
.jsv-stats b { font-size: 19px; font-weight: 800; color: var(--jp-text); font-variant-numeric: tabular-nums; }

.jsv-info { display: grid; margin: 8px 0 0; padding: 8px 28px 22px; }
.jsv-info > div { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 12px; padding: 14px 0; border-bottom: 1px dashed var(--jp-border); }
.jsv-info > div:last-child { border-bottom: 0; }
.jsv-info dt { font-size: 13px; color: var(--jp-muted); }
.jsv-info dd { margin: 0; display: flex; flex-wrap: wrap; gap: 6px 12px; font-size: 14px; font-weight: 600; color: var(--jp-text); overflow-wrap: anywhere; }
.jsv-url { font-weight: 500; }
.jsv-link { color: var(--jp-action); font-weight: 700; }

.jsv-lock {
    display: flex; align-items: center; gap: 14px; padding: 16px 18px;
    border: 1px solid var(--jp-border); border-radius: 16px; background: var(--jp-surface);
}
.jsv-lock-ic { display: inline-grid; place-items: center; flex-shrink: 0; width: 44px; height: 44px; border-radius: 12px; background: var(--jp-soft); color: var(--jp-text-2); }
.jsv-lock-ic svg { width: 22px; height: 22px; }
.jsv-lock-text { flex: 1; min-width: 0; }
.jsv-lock-text b { font-size: 14px; color: var(--jp-text); }
.jsv-lock-text p { margin: 4px 0 0; font-size: 12.5px; line-height: 1.9; color: var(--jp-muted); }
.jsv-request {
    display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; min-height: 42px; padding-inline: 18px;
    border-radius: 10px; background: var(--jp-action); color: #fff; font-size: 13.5px; font-weight: 700;
    transition: background-color .15s var(--jp-ease);
}
.jsv-request:hover { background: var(--jp-action-hover); }
.jsv-request:focus-visible { outline: none; box-shadow: 0 0 0 2px var(--jp-surface), 0 0 0 4px var(--jp-action); }

@media (max-width: 640px) {
    .jsv-hero { flex-wrap: wrap; padding: 22px 16px 16px; }
    .jsv-badge { order: 3; }
    .jsv-stats { grid-template-columns: 1fr 1fr; margin: 0 16px; }
    .jsv-stats > div:nth-child(3) { grid-column: 1 / -1; border-inline-start: 0; border-top: 1px solid var(--jp-border); }
    .jsv-info { padding: 4px 16px 16px; }
    .jsv-info > div { grid-template-columns: 1fr; gap: 4px; }
    .jsv-lock { flex-wrap: wrap; }
    .jsv-request { width: 100%; }
}

/* ===================== Seller product page (sub-products/{id}/edit) =====================
   resources/views/filament/app/sub-products/edit.blade.php */

.fi-page:has(.jpd) .fi-page-header-main-ctn { padding-block: 0; gap: 0; }
.jpd { display: flex; flex-direction: column; gap: 16px; width: 100%; max-width: 960px; margin: 0 auto; }
.jpd > .ji-back { align-self: flex-start; }

.jpd-card { display: flex; gap: 22px; padding: 22px; border: 1px solid var(--jp-border); border-radius: 18px; background: var(--jp-surface); }
.jpd-media { display: grid; place-items: center; flex-shrink: 0; width: 168px; height: 168px; overflow: hidden; border: 1px solid var(--jp-border); border-radius: 14px; background: #fff; font-size: 12px; color: var(--jp-muted); }
.jpd-media img { width: 100%; height: 100%; object-fit: contain; }
.jpd-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.jpd-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.jpd-store { font-size: 12.5px; color: var(--jp-muted); }
.jpd-title { margin: 0; font-size: 18px; font-weight: 800; line-height: 1.8; color: var(--jp-text); }

.jpd-state { display: inline-flex; align-items: center; gap: 6px; padding: 2px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; line-height: 20px; }
.jpd-state::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.jpd-state.is-ok { color: #15803D; background: rgba(22, 163, 74, .1); }
.jpd-state.is-warn { color: #B45309; background: rgba(217, 119, 6, .1); }
.jpd-state.is-bad { color: #B91C1C; background: rgba(220, 38, 38, .08); }
.jpd-state.is-info { color: #1D4ED8; background: rgba(37, 99, 235, .08); }

.jpd-price { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.jpd-price b { font-size: 22px; font-weight: 800; color: var(--jp-text); font-variant-numeric: tabular-nums; }
.jpd-price b.is-muted { font-size: 15px; color: var(--jp-muted); }
.jpd-price > span:not(.jpd-stock) { font-size: 13px; color: var(--jp-muted); }
.jpd-price del { font-size: 13px; color: var(--jp-muted); }
.jpd-stock { margin-inline-start: 6px; padding: 1px 9px; border-radius: 999px; background: rgba(22, 163, 74, .1); color: #15803D; font-size: 12px; font-weight: 700; }
.jpd-stock.is-out { background: rgba(220, 38, 38, .08); color: #B91C1C; }

.jpd-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 18px; margin: 0; }
.jpd-facts > div { display: flex; flex-direction: column; gap: 2px; }
.jpd-facts dt { font-size: 12px; color: var(--jp-muted); }
.jpd-facts dd { margin: 0; font-size: 13.5px; font-weight: 600; color: var(--jp-text); }

.jpd-links { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 2px; }
.jpd-btn {
    display: inline-flex; align-items: center; justify-content: center; min-height: 36px; padding-inline: 14px;
    border: 1px solid var(--jp-border-strong); border-radius: 10px; background: var(--jp-surface);
    font-size: 13px; font-weight: 700; color: var(--jp-text); white-space: nowrap; cursor: pointer;
    transition: background-color .15s var(--jp-ease);
}
.jpd-btn:hover { background: var(--jp-soft); }
.jpd-btn.is-primary { border-color: var(--jp-action); background: var(--jp-action); color: #fff; }
.jpd-btn.is-primary:hover { background: var(--jp-action-hover); }
.jpd-btn[disabled] { opacity: .6; }
.jpd-btn:focus-visible { outline: none; box-shadow: 0 0 0 2px var(--jp-surface), 0 0 0 4px var(--jp-action); }

/* Review steps */
.jpd-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 14px 18px; border: 1px solid var(--jp-border); border-radius: 16px; background: var(--jp-surface); }
.jpd-step { position: relative; display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--jp-muted); }
.jpd-step-dot { display: inline-grid; place-items: center; flex-shrink: 0; width: 28px; height: 28px; border: 1.5px solid var(--jp-border-strong); border-radius: 50%; background: var(--jp-surface); font-size: 12px; font-weight: 800; }
.jpd-step.is-done { color: var(--jp-text); font-weight: 600; }
.jpd-step.is-done .jpd-step-dot { border-color: var(--jp-action); background: var(--jp-action); color: #fff; }
.jpd-step.is-bad .jpd-step-dot { border-color: #DC2626; background: #DC2626; }

.jpd-note { padding: 12px 16px; border-radius: 12px; background: rgba(217, 119, 6, .08); color: #92400E; font-size: 13px; line-height: 1.9; }
.jpd-note.is-bad { background: rgba(220, 38, 38, .07); color: #991B1B; }

/* Similar products */
.jpd-similar { border: 1px solid var(--jp-border); border-radius: 18px; background: var(--jp-surface); overflow: hidden; }
.jpd-similar-h { padding: 16px 20px; border-bottom: 1px solid var(--jp-border); }
.jpd-similar-h h2 { margin: 0; font-size: 15px; font-weight: 800; color: var(--jp-text); }
.jpd-similar-h p { margin: 4px 0 0; font-size: 12.5px; line-height: 1.8; color: var(--jp-muted); }

.jpd-match { display: flex; align-items: center; gap: 14px; padding: 14px 20px; border-bottom: 1px solid var(--jp-border); }
.jpd-match:last-child { border-bottom: 0; }
.jpd-match:hover { background: var(--jp-bg); }
.jpd-match-img { flex-shrink: 0; width: 64px; height: 64px; overflow: hidden; border: 1px solid var(--jp-border); border-radius: 12px; background: #fff; }
.jpd-match-img img { width: 100%; height: 100%; object-fit: contain; }
.jpd-match-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.jpd-match-title { overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; font-size: 13.5px; font-weight: 700; line-height: 1.8; color: var(--jp-text); }
.jpd-match-title:hover { color: var(--jp-action); }
.jpd-match-meta { display: flex; gap: 4px 12px; flex-wrap: wrap; font-size: 12px; color: var(--jp-muted); }
.jpd-reasons { display: flex; gap: 4px; flex-wrap: wrap; }
.jpd-reasons span { padding: 0 8px; border-radius: 999px; background: var(--jp-soft); font-size: 11px; line-height: 20px; color: var(--jp-text-2); }
.jpd-match-side { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; flex-shrink: 0; }

.jpd-score { padding: 1px 10px; border-radius: 999px; font-size: 12px; font-weight: 800; line-height: 22px; font-variant-numeric: tabular-nums; }
.jpd-score.is-high { color: #15803D; background: rgba(22, 163, 74, .1); }
.jpd-score.is-mid { color: #B45309; background: rgba(217, 119, 6, .1); }
.jpd-score.is-low { color: var(--jp-text-2); background: var(--jp-soft); }
.jpd-requested { font-size: 12.5px; font-weight: 700; color: #15803D; }
.jpd-empty { padding: 28px 20px; text-align: center; font-size: 13px; color: var(--jp-muted); }

/* Table hints (SubProductsTable) */
.jpd-tbl-hint { color: #B45309; font-weight: 700; }
.jpd-tbl-bad { color: #DC2626; }

@media (max-width: 720px) {
    .jpd-card { flex-direction: column; padding: 16px; }
    .jpd-media { width: 100%; height: 220px; }
    .jpd-steps { grid-template-columns: 1fr; }
    .jpd-match { flex-wrap: wrap; padding: 14px 16px; }
    .jpd-match-side { flex-direction: row; align-items: center; justify-content: space-between; width: 100%; }
}

/* ===================== Seller products tabs (status cards) =====================
   resources/views/filament/app/sub-products/tabs.blade.php — replaces Filament's tab bar
   on "محصولات من". Each card: tinted icon, label, count, share of all listings as a bar. */

.jst {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 4px;
}

.jst-all  { --c: #262626; --s: #F2F2F2; }
.jst-ok   { --c: #15803D; --s: #E8F6EE; }
.jst-warn { --c: #B45309; --s: #FFF4E5; }
.jst-info { --c: #1D4ED8; --s: #EFF4FF; }
.jst-bad  { --c: #B91C1C; --s: #FDECEC; }

.jst-card {
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
    padding: 14px 14px 18px;
    border: 1px solid var(--jp-border);
    border-radius: 16px;
    background: var(--jp-surface);
    text-align: start;
    cursor: pointer;
    overflow: hidden;
    transition: border-color .15s var(--jp-ease), box-shadow .15s var(--jp-ease), transform .15s var(--jp-ease);
}

.jst-card:hover {
    border-color: var(--jp-border-strong);
    transform: translateY(-1px);
}

.jst-card:focus-visible {
    outline: none;
    box-shadow: 0 0 0 2px var(--jp-surface), 0 0 0 4px var(--c);
}

/* Active: the card takes its own colour — tinted surface, coloured frame and a tick notch */
.jst-card.is-on {
    border-color: var(--c);
    background: linear-gradient(180deg, var(--s), var(--jp-surface) 70%);
    box-shadow: 0 8px 22px -14px var(--c);
}

.jst-card.is-on::after {
    content: "";
    position: absolute;
    top: 10px;
    inset-inline-end: 10px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--c);
    box-shadow: 0 0 0 4px var(--s);
}

.jst-card.is-empty:not(.is-on) { opacity: .62; }
.jst-card.is-busy { cursor: progress; }

.jst-ic {
    display: inline-grid;
    place-items: center;
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: var(--s);
    color: var(--c);
    transition: background-color .15s var(--jp-ease), color .15s var(--jp-ease);
}

.jst-ic svg { width: 20px; height: 20px; }
.jst-card.is-on .jst-ic { background: var(--c); color: #fff; }

.jst-body { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.jst-label { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 12.5px; font-weight: 600; color: var(--jp-muted); }
.jst-card.is-on .jst-label { color: var(--c); }
.jst-n { font-size: 21px; font-weight: 800; line-height: 1.3; color: var(--jp-text); font-variant-numeric: tabular-nums; }

.jst-share {
    align-self: flex-start;
    margin-inline-start: auto;
    padding: 0 7px;
    border-radius: 999px;
    background: var(--s);
    font-size: 11px;
    font-weight: 800;
    line-height: 20px;
    color: var(--c);
    font-variant-numeric: tabular-nums;
}

.jst-card.is-on .jst-share { visibility: hidden; }

/* Share of all listings, along the bottom edge */
.jst-bar {
    position: absolute;
    inset-inline: 14px;
    bottom: 8px;
    height: 4px;
    border-radius: 99px;
    background: var(--jp-soft);
    overflow: hidden;
}

.jst-bar i {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: var(--c);
    opacity: .55;
    transition: width .4s var(--jp-ease);
}

.jst-card.is-on .jst-bar i { opacity: 1; }

@media (max-width: 1279px) {
    .jst { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Phones: one swipeable row instead of a tall grid */
@media (max-width: 720px) {
    .jst {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        padding-bottom: 4px;
        margin-inline: -4px;
        padding-inline: 4px;
    }

    .jst-card {
        flex: 0 0 168px;
        scroll-snap-align: start;
    }
}

@media (prefers-reduced-motion: reduce) {
    .jst-card, .jst-bar i { transition: none; }
}

/* ===================== Invoice transactions (under the invoice sheet) ===================== */

.ji-tx {
    width: 100%;
    max-width: 820px;
    margin: 0 auto;
    border: 1px solid var(--jp-border);
    border-radius: 16px;
    background: var(--jp-surface);
    overflow: hidden;
}

.ji-tx-h {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 18px;
    border-bottom: 1px solid var(--jp-border);
}

.ji-tx-h h2 { margin: 0; font-size: 14.5px; font-weight: 800; color: var(--jp-text); }
.ji-tx-h span { font-size: 12px; color: var(--jp-muted); }

.ji-tx-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px;
    border-bottom: 1px solid var(--jp-border);
}

.ji-tx-row:last-child { border-bottom: 0; }
.ji-tx-row:hover { background: var(--jp-bg); }

.ji-tx-dot { flex-shrink: 0; width: 9px; height: 9px; border-radius: 50%; }
.ji-tx-dot.is-ok { background: #16A34A; box-shadow: 0 0 0 4px rgba(22, 163, 74, .12); }
.ji-tx-dot.is-wait { background: #D97706; box-shadow: 0 0 0 4px rgba(217, 119, 6, .12); }
.ji-tx-dot.is-bad { background: #A3A3A3; box-shadow: 0 0 0 4px rgba(0, 0, 0, .05); }

.ji-tx-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.ji-tx-main b { font-size: 13.5px; color: var(--jp-text); }
.ji-tx-main span { font-size: 12px; color: var(--jp-muted); font-variant-numeric: tabular-nums; }

.ji-tx-ref { padding: 1px 8px; border-radius: 6px; background: var(--jp-soft); font-size: 11.5px; color: var(--jp-text-2); font-variant-numeric: tabular-nums; }
.ji-tx-amount { font-size: 13.5px; font-weight: 800; color: var(--jp-text); white-space: nowrap; font-variant-numeric: tabular-nums; }

.ji-tx-state { flex-shrink: 0; min-width: 104px; padding: 1px 10px; border-radius: 999px; font-size: 11.5px; font-weight: 700; line-height: 22px; text-align: center; }
.ji-tx-state.is-ok { color: #15803D; background: rgba(22, 163, 74, .1); }
.ji-tx-state.is-wait { color: #B45309; background: rgba(217, 119, 6, .1); }
.ji-tx-state.is-bad { color: var(--jp-muted); background: var(--jp-soft); }

.ji-tx-empty { padding: 22px 18px; text-align: center; font-size: 13px; color: var(--jp-muted); }

@media (max-width: 640px) {
    .ji-tx-row { flex-wrap: wrap; padding: 12px 14px; }
    .ji-tx-main { flex-basis: calc(100% - 30px); }
    .ji-tx-ref { order: 5; }
    .ji-tx-amount { margin-inline-start: 21px; }
    .ji-tx-state { margin-inline-start: auto; }
}
