/* WeEdit phone — "indigo night" colours (dark mode, screens ≤ 760px). Colours only: layout, buttons and features are unchanged.
   Number tiles get a tinted glass background in their own colour with a big faint icon (see phone-theme.js). */
/* extras that only exist in the phone dark theme */
.kwm,.dtot,.dpct{display:none}
.pl-ic{display:inline-flex;vertical-align:middle;margin-inline-end:8px}.pl-ic svg{width:16px;height:16px}
@media (max-width: 760px) {
  html body.dark:not(#pt):not(#pt) {
    --pt-bg: #030409; --pt-card: rgba(22, 26, 52, .78); --pt-card2: rgba(30, 35, 68, .85); --pt-line: rgba(140, 150, 255, .14); --pt-line2: rgba(255, 255, 255, .07);
    --pt-ink: #f3f4ff; --pt-ink2: #a3a8c9; --pt-ink3: #7d82a8; --pt-accent: #7c5cff; --pt-accent2: #5b47d6; --pt-accent-ink: #b9a9ff; --pt-teal: #2dd4bf;
    --ink: var(--pt-ink); --muted: var(--pt-ink2); --line: var(--pt-line); --paper: var(--pt-bg); --white: #141831; --navy: #030409;
    background: radial-gradient(130% 50% at 50% -14%, rgba(28, 21, 64, .55) 0%, rgba(28, 21, 64, .12) 38%, transparent 68%), var(--pt-bg) !important;
    background-attachment: fixed !important; color: var(--pt-ink) !important;
  }
  html body.dark:not(#pt):not(#pt) :is(.main, .layout, .section) { background: transparent !important; }

  /* top bar + bottom tab bar: dark glass */
  html body.dark:not(#pt):not(#pt) .topbar { background: rgba(5, 6, 13, .82) !important; -webkit-backdrop-filter: saturate(160%) blur(18px); backdrop-filter: saturate(160%) blur(18px); border-bottom: 1px solid var(--pt-line2) !important; }
  html body.dark:not(#pt):not(#pt) #mNav { background: rgba(14, 17, 38, .9) !important; -webkit-backdrop-filter: saturate(160%) blur(20px); backdrop-filter: saturate(160%) blur(20px); border-top: 1px solid var(--pt-line2) !important; box-shadow: 0 -10px 30px rgba(0, 0, 0, .35) !important; }
  html body.dark:not(#pt):not(#pt) #mNav button { color: var(--pt-ink3) !important; }
  html body.dark:not(#pt):not(#pt) #mNav button.on { color: var(--pt-accent-ink) !important; }
  html body.dark:not(#pt):not(#pt) #mNav button.on::after { background: var(--pt-accent) !important; }

  /* headings + text */
  html body.dark:not(#pt):not(#pt) :is(h1, h2, h3, .paneltitle, .ov-greet .gr2) { color: var(--pt-ink) !important; }
  html body.dark:not(#pt):not(#pt) :is(.subtitle, .panelsub, .ov-sub, .ov-greet .gr1, .crumb, .today) { color: var(--pt-ink2) !important; }
  html body.dark:not(#pt):not(#pt) .eyebrow { color: var(--pt-accent-ink) !important; }

  /* main buttons: purple gradient (was gold) */
  html body.dark:not(#pt):not(#pt) :is(.primary, .qa.gold) {
    background: linear-gradient(90deg, #7a63f0 0%, #6b55e0 55%, #5c4ac8 100%) !important; color: #fff !important;
    border: 0 !important; outline: 0 !important; border-radius: 16px !important;
    box-shadow: 0 10px 28px rgba(108, 86, 227, .22) !important; font-weight: 600 !important;
  }
  /* the icon sits in a small white circle, like the "Continue" button */
  html body.dark:not(#pt):not(#pt) :is(.primary, .qa.gold) svg, html body.dark:not(#pt):not(#pt) .primary .pl-ic svg {
    width: 18px !important; height: 18px !important; padding: 0 !important; box-sizing: border-box; border-radius: 0;
    background: transparent !important; color: #fff !important; stroke: #fff !important; stroke-width: 2.3 !important; flex: 0 0 18px;
  }
  html body.dark:not(#pt):not(#pt) :is(.primary, .qa.gold) * { color: #fff !important; }
  html body.dark:not(#pt):not(#pt) :is(.secondary, .qa:not(.gold), .select, .filter, .tinybtn:not(.done-btn), .per-wrap) {
    background-color: rgba(255, 255, 255, .045) !important; border: 1px solid rgba(255, 255, 255, .1) !important; color: var(--pt-ink) !important; box-shadow: none !important;
  }
    html body.dark:not(#pt):not(#pt) .textbtn { color: var(--pt-accent-ink) !important; }

  /* panels, lists, modals */
  html body.dark:not(#pt):not(#pt) :is(.panel, .modal, .drawer, .mproj, .pcard, .projcard, .ai-wrap) {
    background: var(--pt-card) !important; border: 1px solid var(--pt-line) !important; box-shadow: 0 10px 30px rgba(0, 0, 0, .25) !important;
  }
  html body.dark:not(#pt):not(#pt) .modalveil { background: rgba(5, 6, 18, .6) !important; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
  html body.dark:not(#pt):not(#pt) :is(input:not([type=checkbox]):not([type=radio]):not([type=range]), select, textarea, .search) {
    background-color: rgba(12, 15, 34, .85) !important; border: 1px solid rgba(255, 255, 255, .09) !important; color: var(--pt-ink) !important;
  }
  /* a field that sits inside its own styled box: the box is the field */
  html body.dark:not(#pt):not(#pt) :is(.search, .per-wrap, .cl-search, .pj-search, .searchbox, .ai-bar) :is(input, select, textarea):not(#pt):not([type=checkbox]) { background-color: transparent !important; border: 0 !important; box-shadow: none !important; }
  html body.dark:not(#pt):not(#pt) :is(input, select, textarea):focus { border-color: var(--pt-accent) !important; box-shadow: 0 0 0 3px rgba(124, 92, 255, .25) !important; outline: none !important; }
  html body.dark:not(#pt):not(#pt) :is(td, th) { border-color: var(--pt-line2) !important; }
  html body.dark:not(#pt):not(#pt) input[type=checkbox], html body.dark:not(#pt):not(#pt) input[type=radio] { accent-color: var(--pt-accent); }

  /* number tiles: tinted glass in their own colour + big faint icon (colour set by phone-theme.js as --kc: r,g,b) */
  html body.dark:not(#pt):not(#pt) .cards > .card[data-kc] {
    position: relative; overflow: hidden; isolation: isolate;
    background: linear-gradient(150deg, rgba(var(--kc), .30) 0%, rgba(var(--kc), .12) 48%, rgba(var(--kc), .05) 100%), rgba(14, 17, 38, .9) !important;
    border: 1px solid rgba(var(--kc), .42) !important; border-radius: 22px !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06), 0 10px 28px rgba(0, 0, 0, .28) !important;
  }
  html body.dark:not(#pt):not(#pt) .cards > .card[data-kc]::before, html body.dark:not(#pt):not(#pt) .cards > .card[data-kc]::after { display: none !important; }
  html body.dark:not(#pt):not(#pt) .cards > .card[data-kc] > .kicon {
    background: rgba(var(--kc), .2) !important; color: rgb(var(--kc)) !important; border: 1px solid rgba(var(--kc), .35) !important; box-shadow: none !important;
  }
  html body.dark:not(#pt):not(#pt) .cards > .card[data-kc] > .kicon svg { stroke: currentColor !important; color: rgb(var(--kc)) !important; }
  html body.dark:not(#pt):not(#pt) .cards > .card[data-kc] > .cardtop { color: var(--pt-ink) !important; }
  html body.dark:not(#pt):not(#pt) .cards > .card[data-kc] > .metric { color: #fff !important; }
  html body.dark:not(#pt):not(#pt) .cards > .card[data-kc] :is(.trend, .note, .knote) { color: rgba(235, 237, 255, .72) !important; }
  html body.dark:not(#pt):not(#pt) .kwm {
    display: block !important; position: absolute !important; right: -14px; bottom: -16px; width: 92px; height: 92px; z-index: -1 !important; pointer-events: none;
    color: rgb(var(--kc)); opacity: .16; transform: rotate(-12deg);
  }
  html body.dark:not(#pt):not(#pt) .kwm svg { width: 100%; height: 100%; stroke-width: 1.1 !important; stroke: currentColor !important; fill: none !important; }
  html[dir=rtl] body.dark:not(#pt):not(#pt) .kwm { right: auto; left: -14px; transform: rotate(12deg); }

  /* tab bar like iOS: flat dark bar, active page = purple icon + label, no pill */
  html body.dark:not(#pt):not(#pt) #mNav { background: rgba(28, 28, 36, .94) !important; border-top: 1px solid rgba(255, 255, 255, .06) !important; box-shadow: none !important; }
  html body.dark:not(#pt):not(#pt) #mNav button { color: #8e8e9a !important; font-weight: 500 !important; }
  html body.dark:not(#pt):not(#pt) #mNav button .i { background: transparent !important; color: inherit !important; box-shadow: none !important; }
  html body.dark:not(#pt):not(#pt) #mNav button.on, html body.dark:not(#pt):not(#pt) #mNav button.on .i { color: #8b6cff !important; background: transparent !important; }
  html body.dark:not(#pt):not(#pt) #mNav button .i, html body.dark:not(#pt):not(#pt) #mNav button .i::before, html body.dark:not(#pt):not(#pt) #mNav button .i::after { background: none !important; box-shadow: none !important; filter: none !important; }
  html body.dark:not(#pt):not(#pt) #mNav button.on .i svg { stroke: #8b6cff !important; color: #8b6cff !important; fill: none !important; filter: none !important; }
  html body.dark:not(#pt):not(#pt) #mNav button.on::after, html body.dark:not(#pt):not(#pt) #mNav button .dot, html body.dark:not(#pt):not(#pt) #mNav button.on > :last-child:not(span):not(.i) { display: none !important; }

  /* Projects by status: thin glowing ring with rounded ends, "Total" box in the middle, % in the legend */
  html body.dark:not(#pt):not(#pt) #statusDonutSvg { overflow: visible; filter: drop-shadow(0 0 10px rgba(45, 212, 191, .18)) drop-shadow(0 0 14px rgba(139, 108, 255, .14)); }
  html body.dark:not(#pt):not(#pt) #statusDonutSvg .d-track { stroke: rgba(255, 255, 255, .06) !important; stroke-width: 13 !important; }
  html body.dark:not(#pt):not(#pt) #statusDonutSvg .d-seg { stroke-width: 13 !important; stroke-linecap: round; }
  html body.dark:not(#pt):not(#pt) #statusDonutSvg .d-new { stroke: #8b6cff !important; }
  html body.dark:not(#pt):not(#pt) #statusDonutSvg .d-footage { stroke: #60a5fa !important; }
  html body.dark:not(#pt):not(#pt) #statusDonutSvg .d-editing { stroke: #fbbf24 !important; }
  html body.dark:not(#pt):not(#pt) #statusDonutSvg .d-qc { stroke: #f472b6 !important; }
  html body.dark:not(#pt):not(#pt) #statusDonutSvg .d-revision { stroke: #fb923c !important; }
  html body.dark:not(#pt):not(#pt) #statusDonutSvg .d-delivered { stroke: #2dd4bf !important; }
  html body.dark:not(#pt):not(#pt) #statusDonutSvg .d-other { stroke: #94a3b8 !important; }
  html body.dark:not(#pt):not(#pt) .donutcenter { display: grid !important; place-items: center; gap: 0; padding: 5px 9px 4px; border-radius: 11px; background: rgba(255, 255, 255, .045); border: 1px solid rgba(255, 255, 255, .1); position: absolute !important; inset: 50% auto auto 50% !important; transform: translate(-50%, -50%); width: auto !important; height: auto !important; min-width: 46px; text-align: center; }
  html body.dark:not(#pt):not(#pt) .donut { position: relative !important; }
  html body.dark:not(#pt):not(#pt) .donutcenter .dtot { display: block !important; font-size: 10px !important; color: #a3a8c9 !important; font-weight: 500; }
  html body.dark:not(#pt):not(#pt) .donutcenter b { font-size: 16px !important; color: #fff !important; line-height: 1.1; }
  html body.dark:not(#pt):not(#pt) .donutcenter small:not(.dtot) { display: none !important; }
  html body.dark:not(#pt):not(#pt) #statusLegend { gap: 14px !important; }
  html body.dark:not(#pt):not(#pt) #statusLegend .legendrow { display: grid !important; grid-template-columns: 1fr auto 44px; align-items: center; gap: 10px; font-size: 14px !important; color: #e6e8ff !important; font-weight: 500; }
  html body.dark:not(#pt):not(#pt) #statusLegend .legendrow b { color: #fff !important; font-size: 14px; text-align: right; }
  html body.dark:not(#pt):not(#pt) #statusLegend .legendrow .dpct { display: block !important; color: #a3a8c9; text-align: right; font-variant-numeric: tabular-nums; }
  html body.dark:not(#pt):not(#pt) #statusLegend .legendrow span:first-child::before { width: 9px !important; height: 9px !important; border-radius: 50% !important; }
  html body.dark:not(#pt):not(#pt) #statusLegend .legendrow[data-st=new] span:first-child::before { background: #8b6cff !important; }
  html body.dark:not(#pt):not(#pt) #statusLegend .legendrow[data-st=footage] span:first-child::before { background: #60a5fa !important; }
  html body.dark:not(#pt):not(#pt) #statusLegend .legendrow[data-st=editing] span:first-child::before { background: #fbbf24 !important; }
  html body.dark:not(#pt):not(#pt) #statusLegend .legendrow[data-st=qc] span:first-child::before { background: #f472b6 !important; }
  html body.dark:not(#pt):not(#pt) #statusLegend .legendrow[data-st=revision] span:first-child::before { background: #fb923c !important; }
  html body.dark:not(#pt):not(#pt) #statusLegend .legendrow[data-st=delivered] span:first-child::before { background: #2dd4bf !important; }
  html body.dark:not(#pt):not(#pt) #statusLegend .legendrow[data-st=other] span:first-child::before { background: #94a3b8 !important; }

  /* Revenue & expenses chart: teal revenue with a soft glow, lavender expenses, green dotted profit */
  html body.dark:not(#pt):not(#pt) #revenueChart .rc-rev { stroke: #2dd4bf !important; stroke-width: 3 !important; filter: drop-shadow(0 0 6px rgba(45, 212, 191, .55)); }
  html body.dark:not(#pt):not(#pt) #revenueChart .rc-s0 { stop-color: #2dd4bf !important; stop-opacity: .32 !important; }
  html body.dark:not(#pt):not(#pt) #revenueChart .rc-s1 { stop-color: #2dd4bf !important; }
  html body.dark:not(#pt):not(#pt) #revenueChart .rc-exp { stroke: #f87171 !important; stroke-width: 2.4 !important; }
  html body.dark:not(#pt):not(#pt) #revenueChart .rc-pro { stroke: #4ade80 !important; }
  html body.dark:not(#pt):not(#pt) #revenueChart .rc-dot.r { fill: #2dd4bf !important; }
  html body.dark:not(#pt):not(#pt) #revenueChart .rc-dot.e { fill: #f87171 !important; }
  html body.dark:not(#pt):not(#pt) #revenueChart .rc-dot { stroke: #141831 !important; }
  html body.dark:not(#pt):not(#pt) #revenueChart .rc-grid { stroke: rgba(255, 255, 255, .06) !important; }
  html body.dark:not(#pt):not(#pt) .legend .dot:not(.sage):not(.rc-profit-dot), html body.dark:not(#pt):not(#pt) .rc-legend .dot:not(.sage):not(.rc-profit-dot) { background: #2dd4bf !important; }
  html body.dark:not(#pt):not(#pt) .legend .dot.sage, html body.dark:not(#pt):not(#pt) .rc-legend .dot.sage { background: #f87171 !important; }
  html body.dark:not(#pt):not(#pt) .legend .dot.rc-profit-dot, html body.dark:not(#pt):not(#pt) .rc-legend .dot.rc-profit-dot { background: #4ade80 !important; }
  html body.dark:not(#pt):not(#pt) :is(.donutcenter b, .donutcenter small, .textbtn, #statusLegend .legendrow) { font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Inter', sans-serif !important; }

  /* side menu (☰): navy glass with purple selection, same as the tab bar */
  html body.dark:not(#pt):not(#pt) .sidebar { background: radial-gradient(120% 40% at 0% 0%, rgba(124, 92, 255, .22), transparent 60%), linear-gradient(180deg, #11142a 0%, #030409 100%) !important; border-right: 1px solid rgba(140, 150, 255, .12) !important; box-shadow: 20px 0 50px rgba(0, 0, 0, .5) !important; }
  html body.dark:not(#pt):not(#pt) .sidebar .navlabel { color: #7d82a8 !important; }
  html body.dark:not(#pt):not(#pt) .sidebar .nav button { color: #e6e8ff !important; background: transparent !important; box-shadow: none !important; border: 0 !important; }
  html body.dark:not(#pt):not(#pt) .sidebar .nav button .ico, html body.dark:not(#pt):not(#pt) .sidebar .nav button .ico svg { color: #8e8e9a !important; stroke: currentColor !important; }
  html body.dark:not(#pt):not(#pt) .sidebar .nav button.active { background: rgba(124, 92, 255, .16) !important; color: #b9a9ff !important; box-shadow: inset 3px 0 0 #8b6cff !important; }
  html body.dark:not(#pt):not(#pt) .sidebar .nav button.active .ico, html body.dark:not(#pt):not(#pt) .sidebar .nav button.active .ico svg { color: #8b6cff !important; }
  html body.dark:not(#pt):not(#pt) .sidebar .nav button.active * { color: inherit; }
  html body.dark:not(#pt):not(#pt) .sidebar .nav button::before, html body.dark:not(#pt):not(#pt) .sidebar .nav button.active::before { background: transparent !important; }
  html body.dark:not(#pt):not(#pt) .sidebar .nav .count { background: rgba(124, 92, 255, .22) !important; color: #c9bcff !important; border: 1px solid rgba(139, 108, 255, .35) !important; box-shadow: none !important; }
  html body.dark:not(#pt):not(#pt) .sidebar .profile { border-top-color: rgba(140, 150, 255, .12) !important; }
  html body.dark:not(#pt):not(#pt) .sidebar .profile small { color: #a3a8c9 !important; }
  html[dir=rtl] body.dark:not(#pt):not(#pt) .sidebar .nav button.active { box-shadow: inset -3px 0 0 #8b6cff !important; }
}

/* Projects by status: tap a colour (all screens) */
#statusDonutSvg .d-seg{cursor:pointer;transition:stroke-width .25s ease,opacity .25s ease,filter .25s ease}
#statusDonutSvg .d-seg.d-on{stroke-width:21!important;filter:drop-shadow(0 0 6px rgba(0,0,0,.25))}
#statusDonutSvg .d-seg.d-dim{opacity:.28}
#statusDonutSvg{overflow:visible}
#statusLegend .legendrow{cursor:pointer;transition:opacity .2s;border-radius:8px}
#statusLegend .legendrow.d-dim{opacity:.4}
#statusLegend .legendrow.d-on b{text-decoration:underline;text-underline-offset:3px}
.donutbox .donutcenter{cursor:pointer;transition:transform .2s}
.donutbox .donutcenter.d-picked{transform:scale(1.04)}
.dbreak{margin:4px 18px 18px;padding:14px 14px 10px;border-radius:16px;background:rgba(127,127,127,.07);border:1px solid rgba(127,127,127,.16);animation:dbIn .25s ease-out}
@keyframes dbIn{from{opacity:0;transform:translateY(-6px)}to{opacity:1;transform:none}}
.dbreak-h{display:flex;align-items:center;justify-content:space-between;margin-bottom:10px}.dbreak-h b{font-size:14px}
.dbreak-x{border:0;background:rgba(127,127,127,.15);color:inherit;width:26px;height:26px;border-radius:50%;font-size:17px;line-height:1;cursor:pointer}
.dbreak-row{padding:7px 0}.dbreak-top{display:flex;justify-content:space-between;gap:10px;font-size:13.5px;margin-bottom:6px}
.dbreak-name{font-weight:600;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.dbreak-n{opacity:.75;white-space:nowrap;font-variant-numeric:tabular-nums}.dbreak-n b{opacity:1}
.dbreak-bar{height:6px;border-radius:99px;background:rgba(127,127,127,.18);overflow:hidden}.dbreak-bar i{display:block;height:100%;border-radius:inherit;background:var(--dbc,#2ea062);transition:width .4s ease}
.dbreak-note,.dbreak-empty{font-size:11.5px;opacity:.6;margin:8px 0 2px}
.dbreak[data-st=new]{--dbc:#786dff}.dbreak[data-st=footage]{--dbc:#55a7dd}.dbreak[data-st=editing]{--dbc:#e0a23c}.dbreak[data-st=qc]{--dbc:#c56bb0}.dbreak[data-st=revision]{--dbc:#d58a71}.dbreak[data-st=delivered]{--dbc:#2ea062}.dbreak[data-st=other]{--dbc:#9a9eaa}
@media (max-width:760px){
  html body.dark .dbreak[data-st=new]{--dbc:#8b6cff}html body.dark .dbreak[data-st=footage]{--dbc:#60a5fa}html body.dark .dbreak[data-st=editing]{--dbc:#fbbf24}html body.dark .dbreak[data-st=qc]{--dbc:#f472b6}html body.dark .dbreak[data-st=revision]{--dbc:#fb923c}html body.dark .dbreak[data-st=delivered]{--dbc:#2dd4bf}html body.dark .dbreak[data-st=other]{--dbc:#94a3b8}
  html body.dark .dbreak{background:rgba(255,255,255,.035);border-color:rgba(140,150,255,.14);color:#f3f4ff}
  html body.dark .dbreak-bar i{box-shadow:0 0 10px var(--dbc)}
  html body.dark:not(#pt):not(#pt) #statusDonutSvg .d-seg.d-on{stroke-width:19!important;filter:drop-shadow(0 0 8px currentColor)}
}
.donutbox .donutcenter{pointer-events:none}.donutbox .donutcenter>*{pointer-events:auto}
@media (max-width:760px){html body.dark .donutbox .donutcenter{pointer-events:auto}}

/* iPhone full screen: the app draws behind the clock/battery bar and down to the home bar */
@media (max-width:760px){
  html body:not(#pt) .topbar{height:calc(62px + env(safe-area-inset-top)) !important;padding-top:env(safe-area-inset-top) !important}
  html body:not(#pt) .sidebar{padding-top:calc(22px + env(safe-area-inset-top)) !important}
  html body:not(#pt) #mNav{padding-bottom:max(4px, calc(env(safe-area-inset-bottom) - 16px)) !important;padding-top:8px !important}
  /* light mode: keep the clock readable (it is white in full screen) with a dark strip behind it */
  html body:not(.dark):not(#pt)::before{content:"";position:fixed;left:0;right:0;top:0;height:env(safe-area-inset-top);background:#1b2926;z-index:60;pointer-events:none}
}

/* phone Overview: 4 money tiles on top, the 4 others as a "Studio pulse" list right below */
.pulse{display:none}
@media (max-width:760px){
  #Overview .cards > .card:is(.kpi-revenue,.kpi-editing,.kpi-active,.kpi-completed){display:none !important}
  html body #Overview .cards > .card:not(#pt){grid-column:auto !important}
  #Overview .pulse{display:block !important;margin:0 0 16px !important;padding:14px 14px 6px !important;border-radius:22px !important}
  .pulse-h{display:flex;align-items:center;gap:10px;padding:2px 2px 10px}
  .pulse-h b{font-size:17px;font-weight:700;flex:1 1 auto}
  .pulse-bolt{width:22px;height:22px;color:#8b6cff;filter:drop-shadow(0 0 8px rgba(139,108,255,.7))}
  .pulse-bolt svg{width:100%;height:100%}
  .pulse-all{border:0;background:none;color:inherit;opacity:.8;font:inherit;font-size:13.5px;cursor:pointer;padding:4px 2px}
  .pulse-row{display:grid;grid-template-columns:40px 1fr auto;align-items:center;gap:12px;padding:12px 2px;border-top:1px solid rgba(127,127,127,.16)}
  .pulse-h + .pulse-row{border-top:0}
  .pulse-ic{width:38px;height:38px;border-radius:50%;display:grid;place-items:center;background:rgb(var(--pc));color:#fff;box-shadow:0 4px 14px rgba(var(--pc),.35)}
  .pulse-ic svg{width:19px;height:19px;stroke:currentColor}
  .pulse-t{min-width:0}
  .pulse-t b{display:block;font-size:14.5px;font-weight:650;line-height:1.3}
  .pulse-v{font-variant-numeric:tabular-nums}
  .pulse-t small{display:block;font-size:12.5px;opacity:.7;margin-top:2px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .pulse-btn{border-radius:12px;padding:9px 13px;font:inherit;font-size:13px;font-weight:600;cursor:pointer;white-space:nowrap;
    color:rgb(var(--pc));background:rgba(var(--pc),.14);border:1px solid rgba(var(--pc),.38)}
  html body.dark .pulse-btn{filter:brightness(1.25)}
  html body.dark:not(#pt):not(#pt) .pulse{background:rgba(22,26,52,.78) !important;border:1px solid rgba(140,150,255,.14) !important;color:#f3f4ff}
}

@media (max-width:760px){
  .pulse .pulse-more{display:none}
  .pulse.pulse-open .pulse-more{display:grid;animation:dbIn .25s ease-out}
  .pulse-all{display:inline-flex;align-items:center;gap:4px}
}

/* phone: chart legend centred under the title */
@media (max-width:760px){ html body #Overview .rc-legend:not(#pt){display:flex !important;justify-content:center !important;flex-wrap:wrap;gap:6px 20px !important;margin-left:0 !important;margin-right:0 !important;padding:0 !important;width:100% !important} }

/* simple look (like the reference): plain dark cards with a thin border, colour only in the small icon square */
@media (max-width:760px){
  html body.dark:not(#pt):not(#pt) .cards > .card[data-kc]{
    background:rgba(16,20,40,.82) !important;border:1px solid rgba(255,255,255,.07) !important;box-shadow:none !important;border-radius:20px !important}
  html body.dark:not(#pt):not(#pt) .cards > .card[data-kc] > .kicon{
    background:rgba(var(--kc),.16) !important;border:1px solid rgba(var(--kc),.32) !important;border-radius:11px !important;color:rgb(var(--kc)) !important}
  html body.dark:not(#pt):not(#pt) .kwm{display:block !important;opacity:.07 !important;filter:brightness(.8)}
  html body.dark:not(#pt):not(#pt) :is(.panel, .modal, .drawer, .mproj, .pcard, .projcard, .ai-wrap, .pulse){
    background:rgba(16,20,40,.82) !important;border:1px solid rgba(255,255,255,.07) !important;box-shadow:none !important}
  html body.dark:not(#pt):not(#pt) :is(.secondary, .qa:not(.gold), .select, .filter, .tinybtn:not(.done-btn), .per-wrap){
    background-color:rgba(255,255,255,.04) !important;border:1px solid rgba(255,255,255,.08) !important}
  html body.dark:not(#pt):not(#pt) .pulse-ic{box-shadow:none !important}
  html body.dark:not(#pt):not(#pt) .pulse-btn{filter:none !important}
}

/* side menu, simple: plain dark panel, soft grey selection, purple icon + text, quiet badges */
@media (max-width:760px){
  html body.dark:not(#pt):not(#pt) .sidebar{background:#0b0e1a !important;border-right:1px solid rgba(255,255,255,.06) !important;box-shadow:12px 0 40px rgba(0,0,0,.45) !important}
  html body.dark:not(#pt):not(#pt) .sidebar .nav button.active{background:rgba(255,255,255,.06) !important;box-shadow:none !important;color:#b9a9ff !important}
  html[dir=rtl] body.dark:not(#pt):not(#pt) .sidebar .nav button.active{box-shadow:none !important}
  html body.dark:not(#pt):not(#pt) .sidebar .nav .count{background:rgba(255,255,255,.08) !important;border:0 !important;color:#c7cae0 !important}
  html body.dark:not(#pt):not(#pt) .sidebar .nav button.active .count{background:rgba(139,108,255,.2) !important;color:#c9bcff !important}
  html body.dark:not(#pt):not(#pt) .sidebar .profile{border-top-color:rgba(255,255,255,.06) !important}
}

/* project lists: plain rows separated by thin lines (like the transactions list), no boxes inside boxes */
@media (max-width:760px){
  html body.dark:not(#pt):not(#pt) .pc-card{background:transparent !important;border:0 !important;border-bottom:1px solid rgba(255,255,255,.07) !important;border-radius:0 !important;box-shadow:none !important;margin:0 !important}
  html body.dark:not(#pt):not(#pt) .pc-card:last-child{border-bottom:0 !important}
  html body.dark:not(#pt):not(#pt) :is(table, tbody):has(> .pc-card, > tr.pc-card){border-spacing:0 !important;gap:0 !important}
}
@media (max-width:760px){
  html body.dark:not(#pt):not(#pt) tbody:has(> tr.pc-card){padding-left:0 !important;padding-right:0 !important}
  html body.dark:not(#pt):not(#pt) tr.pc-card{padding:14px 18px !important;width:100% !important}
}

/* project lists go edge to edge: no panel box, lines run across the whole screen */
@media (max-width:760px){
  html body.dark:not(#pt):not(#pt) .panel:has(tr.pc-card){background:transparent !important;border:0 !important;border-radius:0 !important;box-shadow:none !important;margin-left:-16px !important;margin-right:-16px !important;width:auto !important;max-width:none !important}
  html body.dark:not(#pt):not(#pt) .panel:has(tr.pc-card) :is(.table-scroll, table, tbody){border-radius:0 !important;margin:0 !important;border-spacing:0 !important;width:100% !important;max-width:none !important}
  html body.dark:not(#pt):not(#pt) .panel:has(tr.pc-card) > :not(.table-scroll){padding-left:16px !important;padding-right:16px !important}
  html body.dark:not(#pt):not(#pt) .panel:has(tr.pc-card) tr.pc-card{padding:16px 16px !important;border-bottom:1px solid rgba(255,255,255,.08) !important}
  html body.dark:not(#pt):not(#pt) .panel:has(tr.pc-card) tbody{border-top:1px solid rgba(255,255,255,.08) !important;padding:0 !important}
  html body.dark:not(#pt):not(#pt) .panel:has(tr.pc-card) tr.pc-card:last-child{border-bottom:1px solid rgba(255,255,255,.08) !important}
}

/* ===== floating pill tab bar (Instagram style) that hides while scrolling down ===== */
@media (max-width:760px){
  html body:not(#pt):not(#pt):not(#pn) #mNav{left:14px !important;right:14px !important;bottom:max(6px, calc(env(safe-area-inset-bottom) - 24px)) !important;
    height:62px !important;padding:5px !important;gap:2px !important;border-radius:999px !important;align-items:stretch !important;
    background:rgba(9,10,19,.86) !important;-webkit-backdrop-filter:saturate(170%) blur(22px) !important;backdrop-filter:saturate(170%) blur(22px) !important;
    border:1px solid rgba(255,255,255,.07) !important;box-shadow:0 14px 36px rgba(0,0,0,.6), inset 0 1px 0 rgba(255,255,255,.05) !important;
    transform:translateY(0);opacity:1;
    transition:transform .55s cubic-bezier(.22,1,.36,1), opacity .45s ease !important;will-change:transform,opacity}
  html body:not(#pt):not(#pt):not(#pn).nav-hide #mNav{transform:translateY(calc(100% + 34px)) !important;opacity:0 !important;pointer-events:none;
    transition:transform .6s cubic-bezier(.4,0,.2,1), opacity .5s ease .08s !important}
  html body:not(#pt):not(#pt):not(#pn) #mNav button{padding:0 !important;margin:0 !important;border-radius:999px !important;display:grid !important;place-items:center !important;
    color:#9b9bb4 !important;background:transparent !important;transition:background .25s, color .25s !important}
  html body:not(#pt):not(#pt):not(#pn) #mNav button > span:not(.i){display:none !important}
  html body:not(#pt):not(#pt):not(#pn) #mNav button::after{display:none !important}
  html body:not(#pt):not(#pt):not(#pn) #mNav button .i{width:auto !important;height:auto !important;background:transparent !important;box-shadow:none !important;color:inherit !important}
  html body:not(#pt):not(#pt):not(#pn) #mNav button .i svg{width:24px !important;height:24px !important;stroke:currentColor !important;color:inherit !important;stroke-width:1.55 !important}
  html body:not(#pt):not(#pt):not(#pn) #mNav button.on{background:rgba(122,99,240,.15) !important;color:#b3a3f5 !important}
  html body:not(#pt):not(#pt):not(#pn) #mNav button.on .i svg{stroke:#b3a3f5 !important;color:#b3a3f5 !important;stroke-width:1.75 !important}
  /* light mode */
  html body:not(.dark):not(#pt):not(#pt):not(#pn) #mNav{background:rgba(255,255,255,.84) !important;border-color:rgba(108,86,227,.14) !important;box-shadow:0 12px 30px rgba(40,30,90,.14) !important}
  html body:not(.dark):not(#pt):not(#pt):not(#pn) #mNav button{color:#6e6e80 !important}
  html body:not(.dark):not(#pt):not(#pt):not(#pn) #mNav button.on{background:rgba(108,86,227,.12) !important;color:#5c4ac8 !important}
  html body:not(.dark):not(#pt):not(#pt):not(#pn) #mNav button.on .i svg{stroke:#5c4ac8 !important;color:#5c4ac8 !important}
}

/* Studio pulse: the whole row opens the details (no buttons) */
@media (max-width:760px){
  .pulse-row[data-go]{cursor:pointer;-webkit-tap-highlight-color:transparent;border-radius:12px;transition:background .15s}
  .pulse-row[data-go]:active{background:rgba(255,255,255,.05)}
  .pulse-chev{display:grid;place-items:center;color:rgba(255,255,255,.32)}
  body:not(.dark) .pulse-chev{color:rgba(0,0,0,.3)}
  .pulse-chev svg{width:18px;height:18px}
}

/* Project rows on the phone: name + date on the left, deadline on the same line at the right, no progress bar
   (progress stays in the project's details and in the opened row) */
@media (max-width:760px){
  html body:not(#pt):not(#pt):not(#pc) .table-scroll tr.pc-card:not(.pc-open){grid-template-columns:minmax(0,1fr) auto !important;align-items:center !important;position:relative !important;padding-right:52px !important;column-gap:12px !important}
  html body:not(#pt):not(#pt):not(#pc) .table-scroll tr.pc-card:not(.pc-open) td.pc-prog{display:none !important}
  html body:not(#pt):not(#pt):not(#pc) .table-scroll tr.pc-card:not(.pc-open) td.pc-name{grid-column:1 !important;grid-row:1 !important;min-width:0}
  html body:not(#pt):not(#pt):not(#pc) .table-scroll tr.pc-card:not(.pc-open) td.pc-due{grid-column:2 !important;grid-row:1 !important;text-align:end !important;white-space:nowrap;font-size:14px !important}
  html body:not(#pt):not(#pt):not(#pc) .table-scroll tr.pc-card:not(.pc-open) td.pc-due::before{margin-bottom:3px !important;font-size:10.5px !important}
  html body:not(#pt):not(#pt):not(#pc) .table-scroll tr.pc-card:not(.pc-open) .pc-tog{position:absolute !important;inset-inline-end:8px;top:50%;transform:translateY(-50%);margin:0 !important}
  [dir=rtl] html body .table-scroll tr.pc-card:not(.pc-open){padding-left:52px !important}
}
