/* لایهٔ اختیاری ظاهر؛ همهٔ قواعد بصری فقط در Glass و روی صفحه فعال‌اند. */
@layer we-appearance;
@layer we-appearance {
@media screen {
  .we-appearance-control {
    display: inline-flex; align-items: center; gap: 8px; flex: 0 0 auto;
    padding: 4px 6px 4px 10px; border: 1px solid #bac9db;
    border-radius: 10px; background: #edf4ff; color: #13233d;
    font: 12px/1.4 "Segoe UI", Tahoma, sans-serif; box-shadow: none;
    max-width: 100%; position: relative;
  }
  .we-appearance-control label {margin: 0; color: inherit; font: inherit;}
  .we-appearance-control select {
    appearance: auto; min-width: 85px; width: auto; max-width: 100%; min-height: 44px;
    padding: 4px 7px; margin: 0; border: 1px solid #a8b8d3; border-radius: 7px;
    font: 600 12px/1.4 "Segoe UI", Tahoma, sans-serif; color: #13233d;
    background: #f7faff; cursor: pointer;
  }
  .we-appearance-control select:focus-visible {outline: 3px solid #55709d; outline-offset: 3px;}
  .we-appearance-announcement {position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap;}
  .we-appearance-floating {position:fixed;inset-inline-end:16px;bottom:calc(88px + env(safe-area-inset-bottom));z-index:1040;}
  .we-appearance-nav-item {display:flex;align-items:center;padding:4px;}
  /* Mouse panning and explicit touch panning, without capturing page scrolling. */
  .we-dashboard #routes-map.we-map-can-drag {cursor:grab !important;}
  .we-dashboard #routes-map.we-map-touch-pan {touch-action:none !important;}
  .we-dashboard #routes-map .leaflet-control-zoom > a {width:48px !important;height:48px !important;line-height:48px !important;}
  .we-dashboard #routes-map .we-map-pan-toggle {display:flex;align-items:center;justify-content:center;flex-direction:column;width:48px;height:52px;padding:3px;gap:1px;border:0;border-top:1px solid #bbcbd9;border-radius:0 0 6px 6px;background:#edf4ff;color:#17344e;font:600 11px/1.2 system-ui,sans-serif;cursor:pointer;touch-action:manipulation;}
  .we-dashboard #routes-map .we-map-pan-toggle span:first-child {font-size:22px;line-height:24px;}
  .we-dashboard #routes-map .we-map-pan-toggle[aria-pressed="true"] {background:#bee749 !important;color:#142b3f !important;box-shadow:inset 0 0 0 2px #71931d;}
  .we-dashboard #routes-map .we-map-pan-toggle:focus-visible {outline:3px solid #238bc2 !important;outline-offset:2px;}
  html[data-we-appearance="glass"] .we-dashboard #routes-map .we-map-pan-toggle {background:#234361e8;color:#dfedff;border-color:#cde5ff38;}
  html[data-we-appearance="glass"] .we-dashboard #routes-map .we-map-pan-toggle:focus-visible {outline-color:#bcdefc !important;}
  /* Reserve real space for the selector and wrap before the title is squeezed. */
  .we-dashboard .topbar {flex-wrap:wrap !important;}
  .we-dashboard .topbar .top-title {flex:1 1 220px !important;min-width:200px !important;}
  .we-dashboard .topbar .topbar-actions {flex:0 1 auto !important;max-width:100%;flex-wrap:wrap;}
  @media (max-width:1700px) { .we-dashboard .topbar .command-search {order:5;flex:1 0 100% !important;} }
  @media (max-width:1150px) { .we-dashboard .topbar .topbar-actions {flex-basis:100% !important;justify-content:flex-start;} }
  html[data-we-appearance="glass"] {
    color-scheme: dark !important;
    --wg-canvas: #071323; --wg-surface: #13233d; --wg-well: #0b172b;
    --wg-text: #edf4ff; --wg-muted: #b4c3d8; --wg-accent: #a2c1f6;
    --wg-line: rgba(189,209,232,.24); --wg-edge: rgba(237,244,255,.34);
    --wg-panel: linear-gradient(135deg,rgba(237,244,255,.12),rgba(117,147,199,.055) 60%,rgba(189,209,232,.10));
    --wg-solid: #172940; --wg-input: rgba(4,14,31,.46);
    --wg-shadow: 0 12px 35px rgba(0,7,24,.22),inset 0 1px rgba(237,244,255,.16);
    --wg-radius: 18px; --wg-control-radius: 9px;
  }
  html[data-we-appearance="glass"] body {
    --we-ink:var(--wg-text) !important;--we-muted:var(--wg-muted) !important;
    --we-line:var(--wg-line) !important;--we-paper:var(--wg-canvas) !important;
    --we-card:var(--wg-surface) !important;--we-navy:var(--wg-surface) !important;
    --we-navy-2:var(--wg-well) !important;--we-cyan:var(--wg-accent) !important;
    --we-lime:var(--wg-text) !important;--we-shadow:var(--wg-shadow) !important;
    --ink:var(--wg-text) !important;--muted:var(--wg-muted) !important;--line:var(--wg-line) !important;
    --bs-body-color:var(--wg-text) !important;--bs-body-bg:var(--wg-surface) !important;
    --bs-secondary-color:var(--wg-muted) !important;--bs-border-color:var(--wg-line) !important;
    --bs-emphasis-color:var(--wg-text) !important;--bs-secondary-bg:var(--wg-well) !important;
    --bs-tertiary-bg:var(--wg-well) !important;
    color:var(--wg-text) !important;
    background:radial-gradient(ellipse at 10% 4%,rgba(85,112,157,.38),transparent 42%),radial-gradient(ellipse at 90% 45%,rgba(70,94,135,.32),transparent 45%),linear-gradient(125deg,#071323,#172940 58%,#0b192b) !important;
    background-attachment:scroll !important; min-height:100vh;
  }
  html[data-we-appearance="glass"] :is(h1,h2,h3,h4,h5,h6,label,legend,.fw-bold,.fw-semibold,.text-dark,.text-body,.text-black,.text-black-50) {color:var(--wg-text) !important;}
  html[data-we-appearance="glass"] :is(.icon-btn,.command-search) {background:var(--wg-solid) !important;color:var(--wg-text) !important;border-color:var(--wg-line) !important;}
  html[data-we-appearance="glass"] .icon-btn :is(i,svg) {color:inherit !important;}
  html[data-we-appearance="glass"] .command-search input {background:transparent !important;box-shadow:none !important;}
  html[data-we-appearance="glass"] .we-notice-line {background:var(--wg-solid) !important;color:var(--wg-text) !important;border-color:var(--wg-line) !important;}
  html[data-we-appearance="glass"] :is(.text-muted,.text-secondary,.small.text-muted,.help,.help-block,.helptext,.form-text,.description,.muted,.chat-list-time,.cc-muted,.we-page-kicker,.eyebrow) {color:var(--wg-muted) !important;}
  html[data-we-appearance="glass"] a:not(.btn):not(.badge):not(.nav-link):not(.dropdown-item) {color:var(--wg-accent) !important;}
  html[data-we-appearance="glass"] :is(.navbar,.topbar,.rail,.limited-nav,.app-header,.main-header,.app-sidebar,.main-sidebar,.app-footer,.main-footer) {
    background:var(--wg-panel) !important; color:var(--wg-text) !important;
    border-color:var(--wg-line) !important;box-shadow:var(--wg-shadow) !important;
    backdrop-filter:blur(22px) saturate(135%);-webkit-backdrop-filter:blur(22px) saturate(135%);
  }
  html[data-we-appearance="glass"] :is(.app-main,.content-wrapper,.app-wrapper,.content,.main-content,.container-fluid.main-content) {background:transparent !important;color:var(--wg-text) !important;}
  html[data-we-appearance="glass"] :is(.card,.surface,.we-panel,.department-panel,.workspace-card,.command-stage,.daily-brief,.we-page-head,.we-stat-card,.stat-card,.stat-box,.module,.inline-group,.submit-row,.portal-hero,.portal-route-panel,.case-card,.case-detail-hero,.case-panel,.case-section,.portal-card,.portal-document-card,.soa-hero,.soa-card,.soa-stat,.soa-summary,.agency .panel,.agency .metric,.agency>header,.mail-card,.mail-center .mail-note,.limited-card,.chat-list,.chat-shell,.chat-container,.chat-member-picker,.job-profit-confirm-card) {
    color:var(--wg-text) !important;background:var(--wg-panel) !important;
    border:1px solid var(--wg-line) !important;border-top-color:var(--wg-edge) !important;
    border-radius:var(--wg-radius) !important;box-shadow:var(--wg-shadow) !important;
    backdrop-filter:blur(18px) saturate(130%);-webkit-backdrop-filter:blur(18px) saturate(130%);
  }
  html[data-we-appearance="glass"] :is(.card-header,.surface-head,.module>h2,.module>caption,.fieldset-heading,.inline-related>h3,.portal-booking-header,.case-card-head) {
    color:var(--wg-text) !important;background:rgba(237,244,255,.055) !important;
    border-color:var(--wg-line) !important;box-shadow:none !important;
    border-start-start-radius:inherit;border-start-end-radius:inherit;
  }
  html[data-we-appearance="glass"] :is(.card-body,.card-footer,.card .card,.module .module,.agency .panel .table td,.mail-center .mail-card td,.mail-center .mail-card h1,.mail-center .mail-card h2,.agency .panel h2,.agency .panel h3) {
    color:var(--wg-text) !important;background-color:transparent !important;border-color:var(--wg-line) !important;
  }
  html[data-we-appearance="glass"] :is(.card .card,.module .module) {box-shadow:none !important;backdrop-filter:none;-webkit-backdrop-filter:none;}
  html[data-we-appearance="glass"] :is(.receipt-card,.receipt-hero,.portal-panel,.rt-panel,.fq-panel,.jw-card,.jw-hero,.jw-step-card,.we-score-panel,.quotation-rate-card,.voy-hero,.voy-card,.bl-panel,.health-card,.export-tracking-card,.we-pc-panel,.case-timeline-panel,.portal-vessel-link-panel,.portal-free-time-panel,.contact-panel,.booking-case-card,.security-card,.nav-sub-panel,.nav-big-card,.sg-card,.payroll-card,.payroll-summary) {
    background:var(--wg-panel) !important;color:var(--wg-text) !important;border-color:var(--wg-line) !important;
    border-radius:var(--wg-radius) !important;box-shadow:var(--wg-shadow) !important;
  }
  html[data-we-appearance="glass"] :is(.receipt-card,.portal-panel,.rt-panel,.fq-panel,.jw-card,.health-card,.booking-case-card) :is(h1,h2,h3,p,small,label,span) {color:inherit !important;}
  html[data-we-appearance="glass"] :is([style*="background:#fff"],[style*="background: #fff"],[style*="background-color:#fff"],[style*="background-color: #fff"],[style*="background:#f8f9fa"],[style*="background: #f8f9fa"],[style*="background:#f1f5f9"]) {background:var(--wg-well) !important;}
  html[data-we-appearance="glass"] :is([style*="color:#003366"],[style*="color: #003366"],[style*="color:#212529"],[style*="color: #212529"],[style*="color:#18394a"],[style*="color:#333"]) {color:var(--wg-text) !important;}
  html[data-we-appearance="glass"] :is(.bg-white,.bg-light,.bg-body,.bg-body-tertiary,.bg-secondary-subtle,.bg-primary-subtle,.bg-info-subtle) {background-color:var(--wg-well) !important;color:var(--wg-text) !important;}
  html[data-we-appearance="glass"] :is(.border,.border-top,.border-bottom,.border-start,.border-end,hr) {border-color:var(--wg-line) !important;}
  html[data-we-appearance="glass"] :is(input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="color"]):not([type="submit"]):not([type="button"]):not([type="hidden"]),select,textarea,.form-control,.form-select,.input-group-text,.vTextField,.vLargeTextField,.select2-selection,.select2-search__field) {
    color:var(--wg-text) !important;background:var(--wg-input) !important;
    border-color:var(--wg-line) !important;border-radius:var(--wg-control-radius) !important;
    box-shadow:inset 0 1px 4px rgba(0,7,24,.14) !important;caret-color:var(--wg-accent);
  }
  html[data-we-appearance="glass"] :is(input,textarea)::placeholder {color:var(--wg-muted) !important;opacity:.85;}
  html[data-we-appearance="glass"] :is(option,optgroup) {background:var(--wg-solid) !important;color:var(--wg-text) !important;}
  html[data-we-appearance="glass"] :is(input,select,textarea):disabled {opacity:.6;cursor:not-allowed;}
  html[data-we-appearance="glass"] [readonly] {background:rgba(237,244,255,.035) !important;}
  html[data-we-appearance="glass"] :is(input[type="checkbox"],input[type="radio"],input[type="range"]) {accent-color:var(--wg-accent);}
  html[data-we-appearance="glass"] :is(a,button,input,select,textarea,summary,[tabindex]):focus-visible {
    outline:3px solid var(--wg-accent) !important;outline-offset:3px !important;
  }
  html[data-we-appearance="glass"] :is(.btn,.button,input[type="submit"],input[type="button"],.object-tools a,.page-link) {
    background:rgba(117,147,199,.13) !important;color:var(--wg-text) !important;
    border:1px solid var(--wg-line) !important;border-radius:var(--wg-control-radius) !important;
    box-shadow:inset 0 1px rgba(237,244,255,.10) !important;
  }
  html[data-we-appearance="glass"] :is(.btn-primary,.btn-portal,.button.default,input.default,.primary-action,.submit-row input[name="_save"]) {
    background:linear-gradient(145deg,#55709d,#3a4e70) !important;color:var(--wg-text) !important;border-color:rgba(162,193,246,.55) !important;
  }
  html[data-we-appearance="glass"] :is(.btn,.button,.page-link,.object-tools a):hover {background-color:rgba(162,193,246,.22) !important;border-color:var(--wg-accent) !important;}
  html[data-we-appearance="glass"] :is(.btn,.button):disabled {opacity:.5;cursor:not-allowed;}
  html[data-we-appearance="glass"] :is(.nav-link,.nav-item>a,.sidebar-menu a,.nav-sidebar a,.breadcrumb-item) {color:var(--wg-muted) !important;}
  html[data-we-appearance="glass"] :is(.nav-link.active,.nav-link:hover,.rail-btn.active,.rail-btn:hover,.saved-view.active,.page-item.active .page-link,.nav-sidebar .nav-link.active,.sidebar-menu .nav-link.active) {
    background:rgba(162,193,246,.17) !important;color:var(--wg-text) !important;border-color:var(--wg-line) !important;
  }
  html[data-we-appearance="glass"] :is(.dropdown-menu,.popover,.tooltip-inner,.select2-dropdown,.autocomplete-suggestions,.dsc-search-results,.dsc-notif-dropdown,.cc-more nav) {
    color:var(--wg-text) !important;background:var(--wg-solid) !important;border:1px solid var(--wg-line) !important;border-radius:12px !important;
  }
  html[data-we-appearance="glass"] :is(.dropdown-item,.select2-results__option) {color:var(--wg-text) !important;}
  html[data-we-appearance="glass"] :is(.dropdown-item:hover,.dropdown-item:focus,.select2-results__option--highlighted) {background:#3a4e70 !important;color:var(--wg-text) !important;}
  html[data-we-appearance="glass"] :is(.modal-content,.drawer,.module-preview,dialog,.mail-center .mail-envelope,.pc-panel,.checklist-panel,.dsc-chat-widget) {
    color:var(--wg-text) !important;background:var(--wg-solid) !important;border:1px solid var(--wg-edge) !important;border-radius:var(--wg-radius) !important;box-shadow:0 20px 60px rgba(0,7,24,.45) !important;
  }
  html[data-we-appearance="glass"] :is(.modal-header,.modal-footer,.drawer-header,.mail-line) {border-color:var(--wg-line) !important;background:rgba(237,244,255,.035) !important;color:var(--wg-text) !important;}
  html[data-we-appearance="glass"] .btn-close {filter:invert(1) grayscale(1);}
  html[data-we-appearance="glass"] table {
    --bs-table-bg:transparent !important;--bs-table-color:var(--wg-text) !important;
    --bs-table-border-color:var(--wg-line) !important;--bs-table-striped-bg:rgba(237,244,255,.035) !important;
    --bs-table-striped-color:var(--wg-text) !important;--bs-table-hover-bg:rgba(162,193,246,.10) !important;
    --bs-table-hover-color:var(--wg-text) !important;color:var(--wg-text) !important;
    background:transparent !important;
  }
  html[data-we-appearance="glass"] :is(table th,table td,.table td,.table th,.mail-center td,.agency .panel .table td,#result_list td,#result_list th) {
    color:var(--wg-text) !important;background:transparent !important;border-color:var(--wg-line) !important;
  }
  html[data-we-appearance="glass"] :is(table thead th,table caption,table tfoot th,table tfoot td,.results thead th) {background:var(--wg-solid) !important;color:var(--wg-text) !important;}
  html[data-we-appearance="glass"] table tbody tr:nth-child(even) {background:rgba(237,244,255,.025) !important;}
  html[data-we-appearance="glass"] table tbody tr:hover {background:rgba(162,193,246,.08) !important;}
  html[data-we-appearance="glass"] :is(.badge,.pill,.status-badge,.module-state,.mail-status,.workspace-tags span) {
    color:var(--wg-text) !important;background:rgba(162,193,246,.13) !important;border:1px solid var(--wg-line) !important;
  }
  /* وضعیت‌ها علاوه بر رنگ، برچسب متنی موجود را حفظ می‌کنند. */
  html[data-we-appearance="glass"] :is(.alert-danger,.errornote,.errorlist,.mail-error,.invalid-feedback,.text-danger) {color:#ffd7dc !important;}
  html[data-we-appearance="glass"] :is(.alert-danger,.errornote,.mail-error) {background:#472a39 !important;border-color:#b36f81 !important;}
  html[data-we-appearance="glass"] :is(.btn-danger,.deletelink,.badge-danger,.bg-danger) {background:#672e40 !important;color:#fff0f3 !important;border-color:#b36f81 !important;}
  html[data-we-appearance="glass"] :is(.alert-warning,.mail-warning,.bg-warning,.text-bg-warning) {background:#423826 !important;color:#ffe7b8 !important;border-color:#ac9061 !important;}
  html[data-we-appearance="glass"] :is(.text-warning,.mail-status-uncertain) {color:#ffe7b8 !important;}
  html[data-we-appearance="glass"] :is(.alert-success,.alert-info,.mail-note,.mail-confirm) {background:#1b3545 !important;color:#d4efff !important;border-color:#557f97 !important;}
  html[data-we-appearance="glass"] :is(.text-success,.text-info,.text-primary,.mail-status-sent,.paid) {color:#b8dfef !important;}
  html[data-we-appearance="glass"] :is(.map-panel,.port-panel,.clock-zone,.portal-port-clock,.portal-map-tools,.portal-map-note,.case-detail-meta>div,.kpi-icon,.workspace-icon,.launch-icon,.launch,.route-tabs,.route-tab,.saved-view,.pulse-metrics>div,.portal-hero-stats>div,.portal-route-counter,.soa-hero-icon,.soa-metric,.soa-summary-item,.agency .note,.agency .metric,.mail-file,.mail-empty) {
    background:rgba(237,244,255,.055) !important;color:var(--wg-text) !important;border-color:var(--wg-line) !important;box-shadow:inset 0 1px rgba(237,244,255,.10) !important;
  }
  html[data-we-appearance="glass"] :is(.workspace-card,.workspace-card.sales,.workspace-card.docs,.workspace-card.finance) {--dept:var(--wg-accent) !important;}
  html[data-we-appearance="glass"] :is(.workspace-card p,.workspace-card span,.queue-main span,.queue-route span,.port-now .digital,.weather-copy strong,.weather-copy .weather,.portal-hero p,.portal-route-heading p,.portal-hero-stats span,.case-meta,.case-detail-subtitle,.soa-subtitle,.mail-small,.limited-nav .identity) {color:var(--wg-muted) !important;}
  html[data-we-appearance="glass"] :is(.workspace-card h3,.workspace-metric b,.kpi b,.portal-hero-stats strong,.portal-route-counter strong,.case-title,.soa-total,.agency .metric strong) {color:var(--wg-text) !important;}
  html[data-we-appearance="glass"] :is(.portal-workspace,.agency,.mail-center,.soa-shell,.chat-list-row,.chat-list-title,.chat-room-header,.chat-room-title,.chat-header,.chat-input-area,.chat-composer,.chat-list-subtitle) {color:var(--wg-text) !important;}
  html[data-we-appearance="glass"] :is(.chat-list-row,.chat-room-header,.chat-header,.chat-input-area,.chat-composer,.chat-date-separator span,.chat-day-separator span,.chat-member-picker,.search-all-result-item) {background:var(--wg-input) !important;border-color:var(--wg-line) !important;}
  html[data-we-appearance="glass"] :is(.chat-list-row:hover,.chat-list-row.active,.chat-msg,.msg-bubble,.message-bubble,.chat-bubble) {background:#233c59 !important;color:var(--wg-text) !important;border-color:var(--wg-line) !important;}
  html[data-we-appearance="glass"] :is(.chat-msg.mine,.message-bubble.mine,.msg-bubble.mine,.chat-bubble.sent) {background:#3a4e70 !important;}
  html[data-we-appearance="glass"] :is(.chat-msg-bubble,.dsc-chat-msg-bubble,.ai-msg-bubble,.portal-message) {background:#233c59 !important;color:var(--wg-text) !important;border-color:var(--wg-line) !important;}
  html[data-we-appearance="glass"] :is(.portal-message-own,.chat-msg-own .chat-msg-bubble) {background:#3a4e70 !important;}
  html[data-we-appearance="glass"] :is(.dsc-chat-panel,.dsc-chat-messages,.portal-chat-messages,.dsc-chat-panel-header,.dsc-ai-panel-header,.offline-composer) {background:var(--wg-solid) !important;color:var(--wg-text) !important;border-color:var(--wg-line) !important;}
  html[data-we-appearance="glass"] :is(.soa-tab-btn,.soa-tabs) {background:var(--wg-input) !important;color:var(--wg-muted) !important;border-color:var(--wg-line) !important;}
  html[data-we-appearance="glass"] .soa-tab-btn.active {background:#3a4e70 !important;color:var(--wg-text) !important;}
  html[data-we-appearance="glass"] :is(.user-dot,.key,.cbm-result-box,.case-status,.booking-route,.booking-meta-grid>div,.portal-vessel-finder,.portal-vessel-finder-body,.portal-vessel-foot,.portal-vessel-controls) {background:var(--wg-solid) !important;color:var(--wg-text) !important;border-color:var(--wg-line) !important;}
  html[data-we-appearance="glass"] :is(.user-dot,.primary-action,.primary-action-label,.btn-open-case) {color:var(--wg-text) !important;}
  html[data-we-appearance="glass"] .btn-open-case {background:linear-gradient(145deg,#55709d,#3a4e70) !important;border-color:var(--wg-line) !important;}
  html[data-we-appearance="glass"] :is(.booking-contact-row strong,.mini-timeline-step small,.portal-vessel-finder-body p,.portal-vessel-foot) {color:var(--wg-muted) !important;}
  html[data-we-appearance="glass"] details.surface>summary {border-top-left-radius:var(--wg-radius) !important;border-top-right-radius:var(--wg-radius) !important;}
  html[data-we-appearance="glass"] :is(.booking-route strong,.booking-meta-grid strong,.btn-open-case,.btn-open-case span) {color:var(--wg-text) !important;}
  html[data-we-appearance="glass"] :is(.breadcrumb,.ledger-tools,.ledger-tools .field,.density) {background:var(--wg-well) !important;border-color:var(--wg-line) !important;}
  html[data-we-appearance="glass"] :is(.density button,.row-open) {background:var(--wg-solid) !important;color:var(--wg-text) !important;border:1px solid var(--wg-line) !important;border-radius:var(--wg-control-radius) !important;}
  html[data-we-appearance="glass"] .saved-view b {color:var(--wg-text) !important;}
  html[data-we-appearance="glass"] .actions {padding:12px !important;}
  html[data-we-appearance="glass"] :is(.health-guide,.health-chart-card,.case-facts>div,.document-empty,.document-row,.portal-chat-actions .btn-attach) {background:var(--wg-solid) !important;color:var(--wg-text) !important;border-color:var(--wg-line) !important;}
  html[data-we-appearance="glass"] :is(.health-history-note,.health-guide p,.team-contact strong,.case-facts strong) {color:var(--wg-text) !important;}
  html[data-we-appearance="glass"] :is(.btn-cancel,.portal-chat-actions button,.health-check-button) {background:#3a4e70 !important;color:var(--wg-text) !important;border:1px solid var(--wg-line) !important;border-radius:var(--wg-control-radius) !important;}
  html[data-we-appearance="glass"] .job-close-card {overflow:hidden;}
  html[data-we-appearance="glass"] .job-close-table thead th:first-child {border-top-left-radius:var(--wg-radius) !important;}
  html[data-we-appearance="glass"] .job-close-table tbody tr:last-child {border-bottom-left-radius:var(--wg-radius) !important;}
  html[data-we-appearance="glass"] .job-close-table tbody tr:last-child td:first-child {border-bottom-left-radius:var(--wg-radius) !important;}
  html[data-we-appearance="glass"] :is(.we-auth-card,.login-card) {background:rgba(19,35,61,.79) !important;backdrop-filter:blur(24px);-webkit-backdrop-filter:blur(24px);}
  html[data-we-appearance="glass"] :is(.we-appearance-control,.we-appearance-control select) {color:var(--wg-text) !important;background:var(--wg-solid) !important;border-color:var(--wg-line) !important;box-shadow:none !important;}
  html[data-we-appearance="glass"] .we-appearance-control label {color:var(--wg-muted) !important;}
  html[data-we-appearance="glass"] #we-appearance-select {border-radius:6px !important;}

  /* Reading surfaces keep the same translucent material; meaning lives in text. */
  html[data-we-appearance="glass"] {--wg-muted:#d0dced;--wg-reading:linear-gradient(135deg,#e6f2ff14,#bdd3ff05 60%,#d1e3ff0d);}
  html[data-we-appearance="glass"] :is(.we-personal-metric,.queue-action,.department-panel-close,.jw-progress-step,.alert-secondary,.bg-success-subtle,.bg-danger-subtle,.we-slogan,.we-slogan .sg-head,.we-slogan .sg-prize,.we-slogan blockquote,.we-slogan .sg-confirm,.we-slogan .sg-tag) {
    background:var(--wg-reading) !important;color:var(--wg-text) !important;border:1px solid var(--wg-line) !important;border-top-color:var(--wg-edge) !important;box-shadow:inset 0 1px #f4faff20 !important;
  }
  html[data-we-appearance="glass"] #we-salary-privacy .we-personal-metric {background:var(--wg-reading) !important;border-radius:12px !important;}
  html[data-we-appearance="glass"] #we-salary-privacy .we-personal-metric :is(.fw-bold,.text-muted) {color:#edf4ff !important;}
  html[data-we-appearance="glass"] #we-salary-privacy .we-personal-metric--benefit .fw-bold {color:#c3f7de !important;}
  html[data-we-appearance="glass"] #we-salary-privacy .we-personal-metric--deduction .fw-bold {color:#ffd4de !important;}
  html[data-we-appearance="glass"] #we-salary-privacy .we-personal-metric--pending .fw-bold {color:#ffe6b7 !important;}
  html[data-we-appearance="glass"] :is(#we-salary-content .text-success,.we-score-live,.we-score-total.is-positive,.we-score-stat bdi) {color:#c3f7de !important;}
  html[data-we-appearance="glass"] :is(.we-score-total.is-negative,.we-score-stat.correction bdi,.queue .countdown strong) {color:#ffd4de !important;}
  html[data-we-appearance="glass"] :is(.we-eyebrow,.launch-description,.panel-title small,.pulse-metrics span,.kpi span,.jw-mini-label,.jw-progress-checked,.jw-job-list .jw-card p,.we-slogan .sg-muted,.weather-copy small,.port-watch span,.health-unit) {color:var(--wg-muted) !important;}
  html[data-we-appearance="glass"] :is(.queue-action,.department-panel-close,.jw-progress-step a,.jw-progress-status,.we-slogan .sg-prize,.we-slogan .sg-tag,.health-number) {color:var(--wg-text) !important;}
  html[data-we-appearance="glass"] .jw-mini .jw-progress-step {--jw-progress-color:#d0dced;}
  html[data-we-appearance="glass"] .jw-mini .jw-progress-done {--jw-progress-color:#c3f7de;}
  html[data-we-appearance="glass"] .jw-mini :is(.jw-progress-review,.jw-progress-partial) {--jw-progress-color:#ffe6b7;}
  html[data-we-appearance="glass"] .jw-mini .jw-progress-step a {color:var(--jw-progress-color) !important;}
  html[data-we-appearance="glass"] table :is(tbody,tfoot,tr.table-success,tr.table-danger,tr.table-warning) {background-color:transparent !important;}
  html[data-we-appearance="glass"] :is(table,#result_list) .text-success {color:#c3f7de !important;}
  html[data-we-appearance="glass"] :is(table,#result_list) .text-danger {color:#ffd4de !important;}
  html[data-we-appearance="glass"] :is(table,#result_list) .text-warning {color:#ffe6b7 !important;}
  html[data-we-appearance="glass"] .we-slogan {--sg-ink:var(--wg-text);--sg-muted:var(--wg-muted);--sg-line:var(--wg-line);}
  @media (prefers-reduced-transparency:reduce) {
    html[data-we-appearance="glass"] {--wg-reading:var(--wg-solid);}
  }
  @media (forced-colors:active) {
    html[data-we-appearance="glass"] {--wg-reading:Canvas;}
    html[data-we-appearance="glass"] #we-salary-privacy .we-personal-metric :is(.fw-bold,.text-muted) {color:CanvasText !important;}
  }

  html[data-we-appearance="glass"] :is(.fin-cur-usd,.fin-bal-zero) {color:#c3f7de !important;}
  html[data-we-appearance="glass"] .fin-bal-pos {color:#ffd4de !important;}
  html[data-we-appearance="glass"] .fin-cur-irr {color:#c2e2ff !important;}
  html[data-we-appearance="glass"] .fin-cur-aed {color:#ffe6b7 !important;}
  /* Reference materials: cool translucent layers, luminous edges and a blue world map. */
  html[data-we-appearance="glass"] body {
    background:radial-gradient(ellipse at 12% 8%,#3670b05a,transparent 36%),radial-gradient(ellipse at 84% 34%,#7762b650,transparent 39%),radial-gradient(ellipse at 29% 78%,#237b8752,transparent 38%),linear-gradient(135deg,#081629,#172640 62%,#0c2031) !important;
    background-attachment:fixed !important;
    --wg-panel:linear-gradient(132deg,rgba(230,242,255,.14),rgba(189,211,255,.065) 36%,rgba(115,149,203,.035) 70%,rgba(209,227,255,.095));
    --wg-shadow:inset 0 1px rgba(239,249,255,.37),inset 0 -1px #020b1b32,0 18px 50px rgba(0,6,22,.24);
  }
  html[data-we-appearance="glass"] .we-dashboard :is(.map-panel,.port-panel) {
    background:linear-gradient(140deg,#0a1b322e,#d7eaff04) !important;
    border:1px solid #d5e9ff2a !important;border-radius:21px !important;
    box-shadow:inset 0 1px #e9f7ff26 !important;
  }
  html[data-we-appearance="glass"] .we-dashboard :is(.map-copy,.map-status,.map-mode-summary,.route-tabs) {
    background:linear-gradient(135deg,#d1e9ff18,#10253b95) !important;
    border:1px solid #e0f1ff2a !important;box-shadow:inset 0 1px #f2faff27,0 12px 26px #02081a18 !important;
    backdrop-filter:blur(18px) saturate(140%);-webkit-backdrop-filter:blur(18px) saturate(140%);
    color:#dbeaff !important;
  }
  html[data-we-appearance="glass"] .we-dashboard .map-copy {border-radius:16px !important;}
  html[data-we-appearance="glass"] .we-dashboard .map-copy h2 span {color:#e5f1ff !important;}
  html[data-we-appearance="glass"] .we-dashboard :is(.map-copy .overline,.map-copy p,.map-status>div,.map-mode-summary,.stage-label,.shift,.map-attribution) {color:#bfd5ef !important;}
  html[data-we-appearance="glass"] .we-dashboard #routes-map {
    background-color:#0a1c34 !important;
    background-image:radial-gradient(ellipse at 50% 45%,#244970a6,#0a1c341a 75%),linear-gradient(#669fc51a 1px,transparent 1px),linear-gradient(90deg,#669fc51a 1px,transparent 1px) !important;
    background-size:auto,35px 35px,35px 35px !important;
  }
  html[data-we-appearance="glass"] .we-dashboard .world-map .leaflet-tile-pane {filter:brightness(.36) sepia(.65) saturate(.7) hue-rotate(160deg) !important;}
  html[data-we-appearance="glass"] .we-dashboard #routes-map .booking-route {stroke:#7eaaff;stroke-width:2;stroke-dasharray:none;animation:none !important;filter:drop-shadow(0 0 3px #8abaff66) !important;}
  html[data-we-appearance="glass"] .we-dashboard #routes-map .booking-route-open-invoice {stroke:#69e1df;stroke-dasharray:5 8;}
  html[data-we-appearance="glass"] .we-dashboard #routes-map .booking-route-glow {stroke:#87bfff;stroke-width:5;stroke-opacity:.15;filter:blur(3px);}
  html[data-we-appearance="glass"] .we-dashboard #routes-map .booking-port-point {fill:#8de9ef;stroke:#092136;stroke-width:1.5;filter:drop-shadow(0 0 4px #6fc9ff66) !important;animation:none !important;}
  html[data-we-appearance="glass"] .we-glass-port-marker {background:transparent !important;border:0 !important;border-radius:50%;}
  html[data-we-appearance="glass"] .we-glass-port-dot {position:absolute;left:18px;top:18px;width:8px;height:8px;border:1.5px solid #092136;border-radius:50%;background:#b1ecff;box-shadow:0 0 0 7px #7fc7ff0d,0 0 7px #93d7ff66;pointer-events:none;transition:box-shadow .16s ease;}
  html[data-we-appearance="glass"] .we-glass-port-marker:focus-visible {outline:2px solid #bcdefc !important;outline-offset:1px;}
  html[data-we-appearance="glass"] .we-glass-port-marker:focus-visible .we-glass-port-dot {box-shadow:0 0 0 11px #8acbff25,0 0 22px 7px #8acbff80;}
  html[data-we-appearance="glass"] .we-dashboard #routes-map .we-glass-port-label {padding:0 3px !important;background:transparent !important;border:0 !important;box-shadow:none !important;color:#d8eafa !important;font-size:11px;line-height:1.2;text-shadow:0 1px 3px #03152d,0 0 5px #03152d;font-weight:500 !important;}
  html[data-we-appearance="glass"] .we-dashboard #routes-map .we-glass-port-label::before {display:none !important;}
  html[data-we-appearance="glass"] :is(.workspace-card,.workspace-item,.route-tab,.rail-btn,.btn,.we-appearance-control) {transition:box-shadow .16s ease,border-color .16s ease;}
  html[data-we-appearance="glass"] :is(.workspace-card,.workspace-item,.route-tab,.rail-btn,.btn):focus-visible {outline:2px solid #c1e5ff !important;outline-offset:3px;box-shadow:0 0 20px #8acbff40 !important;}
  @media (hover:hover) and (pointer:fine) {
    html[data-we-appearance="glass"] .we-glass-port-marker:hover .we-glass-port-dot {box-shadow:0 0 0 11px #8acbff25,0 0 22px 7px #8acbff80;}
    html[data-we-appearance="glass"] .we-dashboard #routes-map .booking-route:hover {stroke:#c1eaff !important;filter:drop-shadow(0 0 5px #8acbffb3) !important;}
    html[data-we-appearance="glass"] :is(.workspace-card,.workspace-item,.route-tab,.rail-btn,.btn,.we-appearance-control):hover {border-color:#b9ddff85 !important;box-shadow:inset 0 1px #eff8ff4d,0 0 0 1px #8acbff26,0 0 24px #8acbff30 !important;}
  }
  html[data-we-appearance="glass"] .we-dashboard #routes-map :is(.leaflet-tooltip,.leaflet-popup-content-wrapper,.leaflet-popup-tip) {color:#dbeaff !important;background:#142b44ed !important;border-color:#b8d8fc38 !important;}
  html[data-we-appearance="glass"] .we-dashboard #routes-map .leaflet-tooltip {font-weight:500 !important;}
  html[data-we-appearance="glass"] .we-dashboard #routes-map .leaflet-popup-content b {color:#a9d5ff !important;}
  html[data-we-appearance="glass"] .we-dashboard #routes-map .port-count-marker span {color:#e5f1ff !important;background:#365b82 !important;border-color:#a8d5ee !important;}
  html[data-we-appearance="glass"] .we-dashboard #routes-map .leaflet-control-zoom {border:1px solid #cde5ff60 !important;box-shadow:inset 0 1px #fff3,0 8px 22px #02081940 !important;}
  html[data-we-appearance="glass"] .we-dashboard #routes-map .leaflet-control-zoom a {color:#dfedff !important;background:#234361e8 !important;border-color:#cde5ff38 !important;}
  html[data-we-appearance="glass"] .we-dashboard #routes-map .leaflet-control-zoom a:hover {background:#385f85 !important;}
  html[data-we-appearance="glass"] .we-dashboard #routes-map .leaflet-control-zoom a.leaflet-disabled {color:#879cb8 !important;background:#1b304a !important;}
  html[data-we-appearance="glass"] .we-dashboard .route-tab.active {background:linear-gradient(135deg,#e4f1ff25,#bedaff12) !important;border-color:#d9ecff60 !important;color:#e0eeff !important;}
  html[data-we-appearance="glass"] .we-dashboard :is(.port-weather,.pulse-metrics>div) {background:#d5eaff08 !important;border-color:#d9edff30 !important;box-shadow:inset 0 1px #eff8ff12 !important;}
  html[data-we-appearance="glass"] .we-dashboard .clock-zone {background:transparent !important;box-shadow:none !important;}
  html[data-we-appearance="glass"] .we-dashboard .clock {border-color:#d3ecff4d !important;box-shadow:inset 0 1px #e2f5ff26,0 7px 20px #0000001b !important;}
  html[data-we-appearance="glass"] .we-dashboard .clock::after {background:radial-gradient(circle at 30% 20%,#51749730,#18304a29) !important;}
  html[data-we-appearance="glass"] .we-dashboard :is(.clock .second,.clock .pin,.stage-label::before) {background:#b1d8fc !important;box-shadow:none !important;}
  html[data-we-appearance="glass"] .we-dashboard :is(.port-now .digital,.weather-copy strong,.pulse-metrics b) {color:#e8f3ff !important;}
  html[data-we-appearance="glass"] .we-dashboard .health {color:#c1d8f4 !important;background:#d8eaff10 !important;}
  html[data-we-appearance="glass"] .we-dashboard .kpi-ribbon {background:#e4f3ff04 !important;border-color:#dfedff22 !important;}
  html[data-we-appearance="glass"] .we-dashboard .workspace-card.sales {--dept:#b7d8ff !important;background:linear-gradient(130deg,#bfdcff1c,#d1e7ff06 56%,#86b6ed13) !important;}
  html[data-we-appearance="glass"] .we-dashboard .workspace-card.docs {--dept:#d1c7ff !important;background:linear-gradient(130deg,#dfd6ff1c,#d5cbff06 56%,#c0a5f915) !important;}
  html[data-we-appearance="glass"] .we-dashboard .workspace-card.finance {--dept:#b4e7dc !important;background:linear-gradient(130deg,#c2f2e51a,#d4f9eb06 56%,#80c8bf13) !important;}
  html[data-we-appearance="glass"] .we-dashboard .workspace-card[aria-expanded="true"] {outline:1px solid var(--dept) !important;outline-offset:3px;}
  html[data-we-appearance="glass"] .we-dashboard .workspace-arrow {color:#d3e8ff !important;background:#e4f4ff12 !important;border:1px solid #e6f4ff40 !important;}
  html[data-we-appearance="glass"] .we-dashboard .workspace-icon {color:var(--dept) !important;}
  html[data-we-appearance="glass"] .we-dashboard .workspace-card::before {background:radial-gradient(ellipse at 22% 0%,#eff8ff21,transparent 65%) !important;filter:none !important;}
  html[data-we-appearance="glass"] .we-dashboard .topbar {flex-wrap:wrap;}
  html[data-we-appearance="glass"] .we-dashboard .topbar-actions {max-width:100%;flex-wrap:wrap;}
  @media (max-width:760px) {
    html[data-we-appearance="glass"] body {background-attachment:scroll !important;background-size:100% 1200px !important;background-repeat:repeat-y !important;}
    html[data-we-appearance="glass"] .we-dashboard #routes-map .leaflet-control-zoom {margin-right:52px !important;}
  }
  @media (prefers-reduced-transparency:reduce) {
    html[data-we-appearance="glass"] .we-dashboard :is(.map-copy,.map-status,.map-mode-summary,.route-tabs,.workspace-card.sales,.workspace-card.docs,.workspace-card.finance) {background:var(--wg-solid) !important;backdrop-filter:none !important;-webkit-backdrop-filter:none !important;}
  }

  @media (max-width:760px) {
    html[data-we-appearance="glass"] .rail-btn {border-radius:12px !important;}
    html[data-we-appearance="glass"] #chat-mobile-header .text-truncate {white-space:normal !important;text-overflow:clip !important;overflow:visible !important;overflow-wrap:anywhere;}
    .we-appearance-control label {display:none !important;}
    #chat-mobile-header .text-truncate {min-width:0;}
    .we-appearance-control {padding:2px 4px;gap:0;}
    .we-appearance-control select {min-height:44px;min-width:89px;font-size:16px;}
    .we-appearance-floating {bottom:calc(84px + env(safe-area-inset-bottom));inset-inline-end:12px;}
    html[data-we-appearance="glass"] :is(input,select,textarea,.form-control,.form-select) {font-size:16px !important;}
    html[data-we-appearance="glass"] :is(.topbar-actions,.navbar-portal,.limited-nav) {flex-wrap:wrap;}
    html[data-we-appearance="glass"] :is(.card,.surface,.we-panel,.portal-route-panel,.workspace-card) {backdrop-filter:blur(8px) !important;-webkit-backdrop-filter:blur(8px) !important;}
  }
  @media (prefers-reduced-transparency:reduce) {
    html[data-we-appearance="glass"] :is(.card,.surface,.we-panel,.navbar,.topbar,.rail,.workspace-card,.portal-hero,.portal-route-panel,.agency .panel,.mail-card) {background:var(--wg-solid) !important;backdrop-filter:none !important;-webkit-backdrop-filter:none !important;}
  }
  @supports not ((backdrop-filter:blur(1px)) or (-webkit-backdrop-filter:blur(1px))) {
    html[data-we-appearance="glass"] :is(.card,.surface,.we-panel,.navbar,.topbar,.rail,.workspace-card,.portal-hero,.portal-route-panel,.agency .panel,.mail-card) {background:var(--wg-solid) !important;}
  }
  @media (max-width:480px) {html[data-we-appearance="glass"] #we-salary-privacy .col-6 {width:100% !important;}}
  @media (prefers-reduced-motion:reduce) {
    html[data-we-appearance="glass"] :is(.card,.workspace-card,.workspace-item,.route-tab,.we-appearance-control,.we-glass-port-dot,.btn,.nav-link,.rail-btn) {transition:none !important;animation:none !important;}
  }
  @media (forced-colors:active) {
    html[data-we-appearance="glass"] body {background:Canvas !important;color:CanvasText !important;}
    html[data-we-appearance="glass"] :is(.card,.surface,.btn,.navbar,.topbar,input,select,textarea) {background:Canvas !important;color:CanvasText !important;border-color:CanvasText !important;box-shadow:none !important;}
  }
}
@media print {.we-appearance-control,.we-appearance-nav-item {display:none !important;}}
}
