/* App Guide page, in the new site look (site.css: header, buttons, ring, footer; 18 Nov 2026).
   This file adds the guide's own hero, the sticky quick-access bar, the sections, the zoom viewer and the drawn panels. */
:root {
    --nav-h: 68px;
    --qa-h: 56px;
    /* names the viewer rules below use */
    --primary: var(--green);
    --primary-blue: var(--blue);
    --bg-dark: var(--ink);
    --bg-card: var(--surface);
    --border: var(--line);
    --text-primary: #fff;
    --text-secondary: var(--soft);
    --error: #EF5350;
    --accent-gradient: var(--grad);
}
html { scroll-behavior: smooth; }
html:not(.is-authed) .when-in, html.is-authed .when-out { display: none !important; }
.site-head .who { display: flex; align-items: center; gap: 30px; margin-left: auto; }
.site-head .who nav { margin-left: 0; }
.site-head nav a.on { color: #fff; box-shadow: inset 0 -2px 0 var(--green); padding-bottom: 4px; }

/* ── hero (as VPS setup's) ── */
.g-hero { position: relative; overflow: hidden; padding: 68px 0 0; }
.g-hero .wrap { position: relative; z-index: 1; padding-top: 72px; padding-bottom: 64px; }
.g-hero h1 { font-size: clamp(32px, 3.6vw, 48px); line-height: 1.08; }
.g-hero h1 .grad-text { display: block; width: fit-content; }
.g-hero .lede { color: var(--soft); font-size: 18px; max-width: 40em; margin-top: 20px; }
/* the i as in the July design: the text's own colour, upright; the i 0.6 of the text, its circle ~1.05 */
.g-hero .hero-i { display: inline-flex; align-items: center; justify-content: center; width: 1.75em; height: 1.75em; box-sizing: border-box; border: 1.5px solid currentColor; border-radius: 50%; font: 700 0.6em/1 'Inter', -apple-system, sans-serif; vertical-align: 0.2em; margin: 0 0.15em; }
.g-hero .g-pdf { margin-top: 26px; }
.g-hero .g-pdf svg { width: 17px; height: 17px; }
.g-hero .ring { right: -230px; top: -170px; width: 640px; height: 640px; will-change: transform; }
.g-hero .ring > svg { display: block; width: 100%; height: 100%; }

/* ── quick-access bar: sticks under the header ── */
.qa-bar { position: sticky; top: var(--nav-h); z-index: 900; background: rgba(12, 17, 23, .92); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); }
.qa-scroll { max-width: 1180px; margin: 0 auto; display: flex; gap: 8px; padding: 10px 28px; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.qa-scroll::-webkit-scrollbar { display: none; }
.qa-chip { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 7px; padding: 7px 15px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); color: var(--soft); font-size: 14px; font-weight: 600; text-decoration: none; white-space: nowrap; transition: color .2s, border-color .2s; }
.qa-chip:hover { color: #fff; border-color: var(--mute); }
.qa-chip.active { color: #04130D; background: var(--grad); border-color: transparent; }
.qa-chip .num { font-size: 12px; opacity: .7; font-weight: 700; }
.qa-chip.active .num { opacity: .85; }

/* ── sections ── */
.guide-body { max-width: 1180px; margin: 0 auto; padding: 8px 28px 96px; }
.guide-section { padding: 72px 0 24px; scroll-margin-top: calc(var(--nav-h) + var(--qa-h) + 8px); }
.guide-section + .guide-section { border-top: 1px solid var(--line-soft); }
.guide-section-head { margin-bottom: 28px; }
.guide-section-head h2 { font-size: clamp(26px, 2.6vw, 36px); }
.guide-section-head p { color: var(--soft); font-size: 17.5px; max-width: 46em; margin-top: 12px; }
.guide-figure { margin-top: 36px; }
.guide-figure:first-of-type { margin-top: 0; }
.guide-sublabel { display: inline-flex; align-items: center; gap: 9px; color: var(--soft); font-size: 15.5px; font-weight: 600; margin-bottom: 14px; }
.guide-sublabel::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 10px var(--green); }
.guide-opens { display: inline-flex; align-items: center; gap: 8px; margin-left: 14px; color: var(--mute); font-size: 14.5px; font-weight: 500; vertical-align: top; }
.guide-opens-ico { display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; border-radius: 6.5px; background: rgba(0, 212, 170, 0.15); }

/* the frame around a drawn panel: the whole frame opens the zoom viewer */
.guide-frame { position: relative; display: block; width: 100%; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; background: #0A0E13; cursor: zoom-in; transition: border-color .3s; }
.guide-frame:hover { border-color: rgba(0, 224, 138, .45); }

/* ═══ Fullscreen zoom / pan viewer (unchanged) ═══ */
.viewer {
    position: fixed;
    inset: 0;
    z-index: 2000;
    background: rgba(6, 9, 13, 0.97);
    display: none;
    touch-action: none;
    overscroll-behavior: contain;
}
.viewer.open { display: block; }
.viewer-stage {
    position: absolute;
    inset: 0;
    overflow: hidden;
    cursor: grab;
}
.viewer-stage.dragging { cursor: grabbing; }
.viewer-stage > img {
    position: absolute;
    top: 0; left: 0;
    transform-origin: 0 0;
    will-change: transform;
    -webkit-user-select: none;
    user-select: none;
    -webkit-user-drag: none;
    pointer-events: none;
    max-width: none;
}
.viewer-toolbar {
    position: absolute;
    top: 0; left: 0; right: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    background: linear-gradient(180deg, rgba(6,9,13,0.85) 0%, transparent 100%);
    z-index: 2;
    pointer-events: none;
}
.viewer-title {
    color: var(--text-primary);
    font-size: 0.95rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 0;
}
.viewer-title .dot {
    width: 8px; height: 8px; border-radius: 50%;
    background: var(--primary); flex-shrink: 0;
}
.viewer-title span {
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.viewer-controls { display: flex; gap: 0.5rem; pointer-events: auto; }
.vbtn {
    width: 40px; height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: rgba(19, 26, 33, 0.9);
    border: 1px solid var(--border);
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.2s;
    -webkit-tap-highlight-color: transparent;
}
.vbtn:hover { border-color: var(--primary); color: var(--primary); }
.vbtn svg { width: 20px; height: 20px; }
.vbtn.close:hover { border-color: var(--error); color: var(--error); }

@media (max-width: 980px) {
    .g-hero .wrap { padding-top: 40px; padding-bottom: 48px; }
    .g-hero .ring { opacity: .22; right: -320px; }
}
@media (max-width: 860px) {
    .site-head .who nav { display: none; }
}
@media (max-width: 768px) {
    .guide-frame { cursor: pointer; }
    /* Fullscreen viewer: controls sit at the bottom on mobile */
    .viewer-controls {
        position: fixed;
        left: 0; right: 0; bottom: 0;
        justify-content: center;
        gap: 0.75rem;
        padding: 1rem;
        padding-bottom: calc(1rem + env(safe-area-inset-bottom));
        background: linear-gradient(0deg, rgba(6, 9, 13, 0.9) 0%, transparent 100%);
        z-index: 3;
    }
}
@media (max-width: 600px) {
    .wrap, .guide-body { padding-left: 16px; padding-right: 16px; }
    .qa-scroll { padding: 10px 16px; }
    .guide-section { padding-top: 48px; }
    .guide-opens { display: flex; margin: -6px 0 12px; }
    .vbtn { width: 38px; height: 38px; }
}

/* ═══════════════════════════════════════════════════════════════════════
   Drawn panels (.gp): a fixed 2360 × 1360 stage — notes left and right, a
   drawn phone in the middle, lines drawn by guide.js. The stage scales as
   one unit (--s, set by guide.js), so the layout never reflows; the zoom
   viewer shows a clone of it at full size.
   ═══════════════════════════════════════════════════════════════════════ */
.gp-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 2360 / 1360;
    overflow: hidden;
}
.gp {
    --gp-green: #00E08A;
    font-size: 16px;
    line-height: 1.6;
    position: absolute;
    top: 0; left: 0;
    width: 2360px;
    height: 1360px;
    transform-origin: 0 0;
    transform: scale(var(--s, 0.4));
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    background:
        /* the July pictures' soft teal glow behind the phone */
        radial-gradient(ellipse 470px 720px at 50% 50%, rgba(0, 200, 190, 0.20), rgba(0, 160, 180, 0.07) 60%, transparent 78%),
        #0A0E13;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    color: #fff;
    text-align: left;
}
.gp-notes {
    position: absolute;
    top: 0; bottom: 0;
    width: 700px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.gp-left  { left: 70px; }
.gp-right { right: 70px; }
.gp-note {
    position: absolute;      /* top set by guide.js: level with its target */
    left: 0; right: 0;
    box-sizing: border-box;
    padding: 26px 30px 28px;
    background: #121820;
    border: 1.5px solid #222B37;
    border-radius: 20px;
}
.gp-note h3 {
    font-family: inherit;      /* not site.css's display face */
    font-stretch: normal;
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 0 0 12px;
    font-size: 27px;
    line-height: 1.25;
    font-weight: 700;
    letter-spacing: -0.01em;
    color: #fff;
}
.gp-note h3::before {
    content: attr(data-n);
    flex: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px; height: 38px;
    border-radius: 50%;
    background: linear-gradient(135deg, #00FF8F, #00A1FF);   /* as the July pictures' number circles */
    color: #04121A;
    font-size: 21px;
    font-weight: 800;
}
.gp-note p {
    margin: 0;
    font-size: 22px;
    line-height: 1.55;
    color: #C9D1DB;
}
.gp-phone {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
}
.gp-lines {
    position: absolute;
    inset: 0;
    width: 2360px;
    height: 1360px;
    overflow: visible;
    pointer-events: none;
}
.gp-lines line { stroke: var(--gp-green); stroke-width: 3; stroke-linecap: round; }
.gp-lines circle { fill: var(--gp-green); }

/* Viewer: the panel clone sits in a 2360 × 1360 holder that the viewer moves
   and scales exactly as it did the old <img>. No will-change here, so text is
   re-rendered sharp at every zoom level. */
.viewer-stage .viewer-panel {
    position: absolute;
    top: 0; left: 0;
    width: 2360px;
    height: 1360px;
    transform-origin: 0 0;
    -webkit-user-select: none;
    user-select: none;
    pointer-events: none;
}
.viewer-stage .viewer-panel .gp { transform: none; }

/* ═══ Drawn phone (.ph-*) — sizes in app dp, scaled 1.4× into the stage ═══ */
.ph-frame {
    position: relative;
    width: 412px;
    height: 892px;
    overflow: hidden;
    box-sizing: border-box;
    border-radius: 42px;
    border: 2px solid #232B36;
    background: #0A0E14;
    box-shadow: 0 0 0 6px #0D1218, 0 0 90px 10px rgba(0, 200, 190, 0.16), 0 0 220px 40px rgba(0, 150, 180, 0.10);
    transform: scale(1.4);
    font-family: 'Roboto', 'Inter', -apple-system, sans-serif;
    color: #fff;
}
.gp-phone { width: 577px; height: 1249px; }
.gp-phone > .ph-frame { transform-origin: 0 0; }

/* Home and every later screen draw inside .ph-frame in app dp. Text sizes are
   the app's × 1.15, the dev phone's text scale (screenshots, 16 Nov 2026). */
.ph-frame { height: 852px; }
.gp-phone { height: 1193px; }
.ph-frame {
    --ph-bg: #0A0E14;
    --ph-surface: #161B22;
    --ph-border: #30363D;
    --ph-primary: #00D4AA;
    --ph-text2: #9CA3AF;
    --ph-loss: #F44336;
    --ph-grad: linear-gradient(90deg, #00FF8F, #00A1FF);
    font-family: 'Roboto', sans-serif;
    font-size: 14px;
    line-height: 1.2;
}
.ph-frame svg { display: block; }
.ph-status {
    height: 40px;
    padding: 0 22px 0 26px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 15px;
    font-weight: 500;
    color: #E8EAED;
}
.ph-status-icons { display: flex; align-items: center; gap: 6px; }
.ph-header {
    height: 52px;
    margin-top: 20px;
    padding: 0 26px;
    display: flex;
    align-items: center;
}
.ph-logo { height: 45px; width: auto; display: block; }
.ph-header-btns { margin-left: auto; display: flex; gap: 11px; }
.ph-hbtn {
    width: 34px; height: 34px;
    border-radius: 8.5px;
    background: rgba(0, 212, 170, 0.15);
    color: var(--ph-primary);
    display: flex; align-items: center; justify-content: center;
}
.ph-list { padding: 14px 26px 0; }
.ph-card {
    position: relative;
    box-sizing: border-box;
    height: 69.5px;
    margin-bottom: 12px;
    padding: 0 12px 0 18px;
    display: flex;
    align-items: center;
    border-radius: 12px;
    background: var(--ph-surface);
    border: 1px solid var(--ph-border);
}
.ph-card.ph-total {
    height: 67.5px;
    border: none;
    background:
        linear-gradient(135deg, rgba(0, 212, 170, 0.15), rgba(0, 212, 170, 0.05)) padding-box,
        linear-gradient(#0A0E14, #0A0E14) padding-box,
        linear-gradient(90deg, #00FF8F, #00A1FF) border-box;
    border: 0.75px solid transparent;
}
.ph-name { display: flex; align-items: center; gap: 9px; flex: 1; min-width: 0; }
.ph-name b { font-size: 16.1px; font-weight: 700; color: #fff; letter-spacing: 0.1px; }
.ph-total .ph-name b { color: var(--ph-primary); letter-spacing: 0.4px; }
.ph-total .ph-count { font-size: 13.8px; font-weight: 700; color: var(--ph-primary); margin-left: -3px; }
.ph-expand { color: var(--ph-text2); margin-left: 2px; }
.ph-main {
    font-size: 10.4px; font-weight: 700; letter-spacing: 0.3px;
    color: #000;
    padding: 2.5px 7px;
    border-radius: 4.5px;
    background: var(--ph-grad);
}
.ph-hedged { font-size: 12.6px; font-weight: 700; color: #FFA500; }
.ph-pl { text-align: right; margin-right: 6px; }
.ph-pl small { display: block; font-size: 12.6px; color: var(--ph-text2); white-space: nowrap; }
.ph-pl small i { font-style: normal; margin-left: 9px; }
.ph-pl strong { display: block; margin-top: 3px; font-size: 16.1px; font-weight: 500; }
.ph-up { color: var(--ph-primary); }
.ph-down { color: var(--ph-loss); }
.ph-chev { color: var(--ph-text2); flex: none; }
.ph-fab {
    position: absolute;
    left: 343px; top: 708px;
    width: 51px; height: 51px;
    box-sizing: border-box;
    border-radius: 50%;
    background:
        linear-gradient(var(--ph-surface), var(--ph-surface)) padding-box,
        linear-gradient(135deg, #00FF8F, #00A1FF) border-box;
    border: 1.6px solid transparent;
    display: flex; align-items: center; justify-content: center;
}
.ph-nav {
    position: absolute;
    left: 0; right: 0; top: 782px;
    height: 54px;
    box-sizing: border-box;
    background: var(--ph-surface);
    border-top: 1px solid var(--ph-border);
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 0 4px;
}
.ph-nav span {
    flex: 1;
    display: flex; flex-direction: column; align-items: center; gap: 3px;
    font-size: 11.5px;
    color: var(--ph-text2);
}
.ph-nav span svg { color: var(--ph-text2); }
/* Selected tab: the app paints icon + label through a green→blue
   ShaderMask (top-left → bottom-right over the pair); drawn as one SVG whose
   gradient spans icon and label the same way. */
.ph-nav span.on { gap: 0; }
.ph-gesture {
    position: absolute;
    left: 0; right: 0; top: 836px; bottom: 0;
    background: #000;
}

/* ═══ Overview (pushed screen: app bar, no bottom bar) ═══ */
.ph-appbar {
    height: 52px;
    padding: 0 15px 0 4px;
    display: flex; align-items: center;
    background: var(--ph-surface);
}
.ph-back { width: 52px; height: 52px; display: flex; align-items: center; justify-content: center; color: #fff; }
.ph-title { margin-left: 18px; font-size: 20.7px; font-weight: 600; color: #fff; }
.ph-appbar .ph-header-btns { gap: 10px; }
.ph-hbtn.ph-wand { color: #fff; }
.ph-body { padding: 18px 17px 0; }
.ph-sum {
    box-sizing: border-box;
    padding: 16px 17px 14px;
    border-radius: 12px;
    background:
        linear-gradient(135deg, rgba(0, 212, 170, 0.15), rgba(0, 212, 170, 0.05)) padding-box,
        linear-gradient(#0A0E14, #0A0E14) padding-box,
        linear-gradient(90deg, #00FF8F, #00A1FF) border-box;
    border: 0.75px solid transparent;
}
.ph-sum-top { display: flex; justify-content: space-between; align-items: baseline; }
.ph-sum-top b { font-size: 15px; font-weight: 700; letter-spacing: 1.4px; color: var(--ph-primary); }
.ph-sum-top span { font-size: 13.2px; color: var(--ph-text2); }
.ph-sum-row { display: flex; margin-top: 16px; }
.ph-sum-row > div { flex: 1; }
.ph-sum-row small { display: block; font-size: 13.8px; color: var(--ph-text2); }
.ph-sum-row small i { font-style: normal; margin-left: 6px; }
.ph-sum-row strong { display: block; margin-top: 4px; font-size: 18.4px; font-weight: 600; color: #fff; }
.ph-sum hr { border: 0; border-top: 1px solid rgba(255, 255, 255, 0.12); margin: 15px 0 12px; }
.ph-sum-grid { display: flex; justify-content: space-between; text-align: center; }
.ph-sum-grid > div { flex: none; }
.ph-sum-grid small { display: block; font-size: 13.8px; color: var(--ph-text2); }
.ph-sum-grid strong { display: block; margin-top: 3px; font-size: 16.1px; font-weight: 400; }
.ph-sec {
    margin: 26px 0 0;
    display: flex; align-items: center; gap: 4px;
    font-size: 14.4px; font-weight: 500; letter-spacing: 1.6px; color: var(--ph-text2);
}
.ph-chips { display: flex; gap: 8px; margin-top: 12px; }
.ph-chip {
    display: flex; align-items: center; gap: 7px;
    padding: 6px 10px;
    border-radius: 8px;
    border: 1px solid var(--ph-primary);
    background: rgba(0, 212, 170, 0.2);
    color: var(--ph-primary);
    font-size: 13.8px; font-weight: 500;
}
.ph-chip i { font-style: normal; font-size: 11.5px; font-weight: 700; color: #000; background: var(--ph-primary); border-radius: 10px; padding: 1px 6px; }
.ph-group {
    margin-top: 12px;
    border-radius: 12px;
    border: 1px solid var(--ph-border);
    background: var(--ph-surface);
    overflow: hidden;
}
.ph-ghead {
    height: 60px;
    display: flex; align-items: center;
    padding: 0 14px 0 18px;
    border-bottom: 1px solid var(--ph-border);
}
.ph-ghead > b { font-size: 17.3px; font-weight: 700; color: #fff; margin-right: 12px; }
.ph-side { flex: 1; font-size: 13.8px; color: var(--ph-text2); }
.ph-side .b { color: var(--ph-primary); }
.ph-side .s { color: var(--ph-loss); }
.ph-gpl { text-align: right; }
.ph-gpl small { display: block; font-size: 11.5px; }
.ph-gpl strong { display: block; margin-top: 3px; font-size: 17.3px; font-weight: 700; }
.ph-row {
    height: 47px;
    display: flex; align-items: center;
    padding: 0 12px 0 18px;
    border-bottom: 1px solid var(--ph-border);
}
.ph-row:last-child { border-bottom: 0; }
.ph-rleft { display: flex; align-items: center; gap: 10px; }
.ph-tag { font-size: 11.5px; font-weight: 700; padding: 3px 7px; border-radius: 4px; }
.ph-tag.buy { color: var(--ph-primary); background: rgba(0, 212, 170, 0.15); }
.ph-tag.sell { color: var(--ph-loss); background: rgba(244, 67, 54, 0.15); }
.ph-lots { font-size: 15px; color: #fff; }
.ph-acct { font-size: 14px; color: var(--ph-text2); }
.ph-rright { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.ph-rright small { font-size: 12.6px; }
.ph-rright strong { font-size: 17.3px; font-weight: 700; }
.ph-row.open { border-bottom: 0; }
.ph-detail {
    display: flex; justify-content: space-between;
    padding: 0 18px 10px;
    border-bottom: 1px solid var(--ph-border);
}
.ph-detail div { text-align: left; }
.ph-detail div:nth-child(n+3) { text-align: right; }
.ph-detail small { display: block; font-size: 12.6px; color: var(--ph-text2); }
.ph-detail span { display: block; margin-top: 3px; font-size: 15px; color: #fff; }

/* ═══ Account (Overview's layout; summary card opens the account's details) ═══ */
.ph-sum-div { display: flex; align-items: center; gap: 8px; margin: 14px 0 10px; color: var(--ph-text2); }
.ph-sum-div::before { content: ''; flex: 1; border-top: 1px solid rgba(255, 255, 255, 0.12); }
.ph-sum .ph-sum-row:first-child { margin-top: 0; }

/* ═══ Position ═══ */
.ph-pos {
    box-sizing: border-box;
    padding: 18px 18px 14px;
    border-radius: 14px;
    background:
        linear-gradient(135deg, rgba(0, 212, 170, 0.15), rgba(0, 212, 170, 0.05)) padding-box,
        linear-gradient(#0A0E14, #0A0E14) padding-box,
        linear-gradient(90deg, #00FF8F, #00A1FF) border-box;
    border: 0.75px solid transparent;
}
.ph-pos-top { display: flex; align-items: center; gap: 12px; }
.ph-pos-top b { font-size: 25px; font-weight: 700; color: #fff; }
.ph-pos-top .ph-side-tag { font-size: 13.8px; font-weight: 700; padding: 5px 10px; border-radius: 6px; color: #fff; background: var(--ph-loss); }
.ph-pos-top span:last-child { margin-left: auto; font-size: 17px; color: #fff; }
.ph-pos-time { margin-top: 6px; font-size: 13.8px; color: #C0C7D0; }
.ph-pos .ph-sum-row { margin-top: 18px; }
.ph-pos .ph-sum-row > div:last-child { text-align: right; }
.ph-pos .ph-sum-row strong { font-size: 18.4px; font-weight: 400; }
.ph-pos .ph-sum-row strong.ph-up { font-weight: 700; }
.ph-pos .ph-sum-grid { margin-top: 12px; }
.ph-pos .ph-sum-grid > div { flex: 1; }
.ph-pos-total {
    margin-top: 14px;
    padding: 12px 18px;
    display: flex; align-items: center; justify-content: space-between;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
}
.ph-pos-total span { font-size: 15px; color: #C0C7D0; }
.ph-pos-total div { text-align: right; }
.ph-pos-total small { display: block; font-size: 16px; font-weight: 700; }
.ph-pos-total strong { display: block; margin-top: 4px; font-size: 19px; font-weight: 700; }
.ph-accts { display: flex; gap: 8px; margin-top: 10px; }
.ph-acchip {
    display: flex; align-items: center; gap: 10px;
    padding: 9px 14px 9px 11px;
    border-radius: 10px;
    border: 1px solid var(--ph-primary);
    background: rgba(0, 212, 170, 0.15);
}
.ph-acchip b { display: block; font-size: 15.5px; font-weight: 700; color: #fff; }
.ph-acchip small { display: block; font-size: 13px; }
.ph-fields { display: flex; gap: 14px; margin-top: 16px; }
.ph-fields > div { flex: 1; }
.ph-fields small { display: block; font-size: 14.4px; color: var(--ph-text2); margin-bottom: 7px; }
.ph-field {
    height: 46px; box-sizing: border-box;
    display: flex; align-items: center; padding: 0 14px;
    border-radius: 10px;
    background: var(--ph-surface);
    font-size: 17px; color: #fff;
}
.ph-field.sl { border: 1px solid rgba(244, 67, 54, 0.7); }
.ph-field.tp { border: 1px solid rgba(0, 212, 170, 0.7); }
.ph-btn {
    margin-top: 14px; height: 46px; box-sizing: border-box;
    display: flex; align-items: center; justify-content: center;
    border-radius: 10px;
    font-size: 15.5px; font-weight: 700; letter-spacing: 0.3px;
}
.ph-btn.modify { border: 1.2px solid var(--ph-primary); color: var(--ph-primary); background: rgba(0, 212, 170, 0.06); }
.ph-btn.close { background: #F44336; color: #fff; }
.ph-partial {
    margin-top: 14px; height: 50px; box-sizing: border-box;
    display: flex; align-items: center; gap: 12px; padding: 0 16px;
    border-radius: 10px; border: 1px solid var(--ph-border); background: var(--ph-surface);
    font-size: 15px; color: #C0C7D0;
}
.ph-partial i { width: 17px; height: 17px; border: 2px solid var(--ph-text2); border-radius: 3px; box-sizing: border-box; }
.ph-partial span:last-child { margin-left: auto; font-size: 13.2px; color: var(--ph-text2); }
/* P/L colours win over the summary rows' white figures */
.ph-frame strong.ph-up, .ph-frame small.ph-up, .ph-frame i.ph-up { color: var(--ph-primary); }
.ph-frame strong.ph-down, .ph-frame small.ph-down, .ph-frame i.ph-down { color: var(--ph-loss); }

/* ═══ New Order — a taller screen, drawn at 1.3× so it fits the stage ═══ */
.gp-phone.tall { width: 536px; height: 1222px; }
.gp-phone.tall > .ph-frame { height: 940px; transform: scale(1.3); }
.ph-quote { margin-left: auto; text-align: right; font-size: 13.8px; line-height: 1.25; }
.ph-quote .a { color: #F44336; }
.ph-quote .b { color: var(--ph-primary); }
.ph-label { display: block; margin: 20px 0 8px; font-size: 14.4px; font-weight: 500; letter-spacing: 1.6px; color: var(--ph-text2); }
.ph-body > .ph-label:first-child { margin-top: 4px; }
.ph-input {
    height: 52px; box-sizing: border-box;
    display: flex; align-items: center; padding: 0 16px;
    border-radius: 12px; border: 1px solid var(--ph-border); background: var(--ph-surface);
    font-size: 18px; color: #fff;
}
.ph-seg { display: flex; border-radius: 12px; background: var(--ph-surface); overflow: hidden; }
.ph-seg span { flex: 1; text-align: center; padding: 15px 0; font-size: 17px; font-weight: 700; color: var(--ph-text2); }
.ph-seg span.on.buy { background: var(--ph-primary); color: #062016; border-radius: 12px; }
.ph-seg.ex span { padding: 12px 0; font-size: 15px; font-weight: 500; }
.ph-seg.ex span.on { color: var(--ph-primary); background: rgba(0, 212, 170, 0.12); border: 1.2px solid var(--ph-primary); border-radius: 10px; }
.ph-banner {
    display: flex; align-items: center; gap: 10px;
    padding: 11px 14px; border-radius: 10px;
    border: 1px solid rgba(0, 212, 170, 0.45); background: rgba(0, 212, 170, 0.08);
    font-size: 15px; font-weight: 600; color: #fff;
}
.ph-banner svg { color: var(--ph-primary); flex: none; }
.ph-ochips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.ph-ochip {
    display: flex; align-items: center; gap: 9px;
    padding: 8px 12px 8px 10px; border-radius: 10px;
    border: 1px solid var(--ph-primary); background: rgba(0, 212, 170, 0.15);
}
.ph-ochip b { font-size: 15.5px; font-weight: 700; color: #fff; display: flex; align-items: center; gap: 6px; }
.ph-ochip small { display: block; font-size: 13px; color: #C0C7D0; }
.ph-ochip .ph-main { font-size: 9.5px; padding: 1.5px 5px; }
.ph-lotbox {
    display: flex; align-items: center; justify-content: space-between;
    height: 62px; box-sizing: border-box; padding: 0 18px;
    border-radius: 12px; border: 1px solid var(--ph-border); background: var(--ph-surface);
    font-size: 15px;
}
.ph-lotbox .m { color: #F44336; }
.ph-lotbox .p { color: var(--ph-primary); }
.ph-lotbox b { font-size: 26px; color: #fff; }
.ph-limits { margin-top: 6px; font-size: 13.8px; color: #C0C7D0; }
.ph-field.opt { color: #6B7480; }
.ph-place {
    margin-top: 22px; height: 54px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 12px; background: var(--ph-primary);
    font-size: 17px; font-weight: 700; color: #062016;
}

/* Information-only notes (operator, 16 Nov): outlined number, a small (i)
   after the title, and a dashed line ending in a hollow dot (guide.js).
   Notes for things you can tap keep the gradient number and solid line. */
.gp-note[data-kind="info"] h3::before {
    background: transparent;
    box-sizing: border-box;
    border: 2.5px solid #00E08A;
    color: #00E08A;
}
.gp-note[data-kind="info"] h3::after {
    content: 'i';
    flex: none;
    display: inline-flex; align-items: center; justify-content: center;
    width: 24px; height: 24px;
    box-sizing: border-box;
    border: 2px solid #8B95A3;
    border-radius: 50%;
    color: #8B95A3;
    font: 700 15px/1 'Inter', -apple-system, sans-serif;
    margin-left: -4px;
}
.gp-lines line.info { stroke-dasharray: 12 9; }
.gp-lines circle.info { fill: #0A0E13; stroke: var(--gp-green); stroke-width: 3.5; }

.hero-i {
    /* the i is 0.6 of the text; the circle around it ~1.05 of the text */
    display: inline-flex; align-items: center; justify-content: center;
    width: 1.75em; height: 1.75em; box-sizing: border-box;
    border: 1.5px solid currentColor; border-radius: 50%;
    font: 700 0.6em/1 'Inter', -apple-system, sans-serif;
    vertical-align: 0.2em;
    margin: 0 0.15em;
}

/* ═══ Chart + Risk Calculator ═══ */
.ph-search { display: flex; gap: 9px; padding: 2px 13px 0 14px; }
.ph-search .ph-input { flex: 1; height: 40px; border: 1.2px solid var(--ph-primary); border-radius: 10px; font-size: 17px; }
.ph-sbtn { width: 40px; height: 40px; box-sizing: border-box; border-radius: 10px; border: 1.2px solid #2A8CFF; display: flex; align-items: center; justify-content: center; color: #2A8CFF; }
.ph-pickers { display: flex; gap: 9px; padding: 9px 13px 0 13px; }
.ph-pick { flex: 1; height: 38px; box-sizing: border-box; display: flex; align-items: center; gap: 6px; padding: 0 10px 0 12px; border-radius: 10px; border: 1px solid var(--ph-border); background: var(--ph-surface); font-size: 15px; font-weight: 500; color: #fff; }
.ph-pick svg { margin-left: auto; color: var(--ph-text2); }
.ph-pick i { font-style: normal; font-size: 11px; font-weight: 700; color: #062016; background: var(--ph-primary); border-radius: 50%; width: 19px; height: 19px; display: inline-flex; align-items: center; justify-content: center; margin-left: auto; }
.ph-pick i + svg { margin-left: 2px; }
.ph-chart { position: absolute; left: 0; right: 0; top: 132px; height: 586px; overflow: hidden; }
.ph-chart > svg { position: absolute; inset: 0; }
.ph-chips2 { position: absolute; top: 6px; left: 16px; right: 10px; display: flex; gap: 8px; align-items: center; }
.ph-tf, .ph-plc, .ph-ba { height: 34px; box-sizing: border-box; display: flex; align-items: center; gap: 7px; padding: 0 10px; border-radius: 8px; font-size: 14px; }
.ph-tf { border: 1px solid var(--ph-border); background: rgba(22, 27, 34, 0.92); color: #fff; }
.ph-tf b { font-size: 15px; }
.ph-tf span { color: #C0C7D0; }
.ph-plc { border: 1px solid rgba(244, 67, 54, 0.6); background: rgba(244, 67, 54, 0.1); color: #F44336; font-weight: 600; }
.ph-ba { margin-left: auto; border: 1px solid var(--ph-primary); background: rgba(22, 27, 34, 0.92); color: var(--ph-primary); font-weight: 700; }
.ph-lbl { position: absolute; height: 21px; box-sizing: border-box; display: flex; align-items: center; padding: 0 6px; border-radius: 4px; font-size: 12.5px; font-weight: 600; white-space: nowrap; background: rgba(10, 14, 20, 0.88); }
.ph-axis { position: absolute; right: 2px; height: 21px; box-sizing: border-box; display: flex; align-items: center; padding: 0 5px; border-radius: 3px; font-size: 12.5px; font-weight: 600; }
.ph-bottom { position: absolute; left: 13px; right: 13px; top: 725px; height: 48px; display: flex; gap: 10px; }
.ph-tool { width: 46px; box-sizing: border-box; border-radius: 10px; border: 1.2px solid var(--ph-primary); display: flex; align-items: center; justify-content: center; color: var(--ph-primary); }
.ph-buy, .ph-sell { flex: 1; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 17px; font-weight: 700; }
.ph-buy { background: #00B386; color: #062016; }
.ph-sell { background: #D32F2F; color: #fff; }
.ph-bell { width: 46px; box-sizing: border-box; border-radius: 10px; border: 1.2px solid var(--ph-primary); display: flex; align-items: center; justify-content: center; color: var(--ph-primary); }
/* risk panel */
.ph-rpanel { position: absolute; left: 0; right: 0; bottom: 70px; padding-bottom: 10px !important; background: var(--ph-bg); border-top: 1px solid var(--ph-border); padding: 10px 12px 0; box-sizing: border-box; }
.ph-rrow { display: flex; gap: 8px; align-items: center; }
.ph-rseg { display: flex; border-radius: 9px; background: var(--ph-surface); padding: 3px; }
.ph-rseg span { padding: 7px 13px; font-size: 14.5px; color: #C0C7D0; border-radius: 7px; }
.ph-rseg span.on { background: linear-gradient(90deg, #00FF8F, #00A1FF); color: #000; font-weight: 600; }
.ph-rx { margin-left: auto; color: #C0C7D0; }
.ph-cards { display: flex; gap: 8px; margin-top: 10px; }
.ph-card2 { flex: 1; box-sizing: border-box; padding: 10px 11px; border-radius: 10px; min-height: 104px; }
.ph-card2.risk { background: rgba(244, 67, 54, 0.12); border: 1px solid rgba(244, 67, 54, 0.45); }
.ph-card2.rew { background: rgba(0, 212, 170, 0.1); border: 1px solid rgba(0, 212, 170, 0.45); }
.ph-card2 .hd { display: flex; align-items: center; gap: 6px; font-size: 14px; color: #C0C7D0; }
.ph-card2 .hd span:first-child { margin-right: auto; }
.ph-mini { padding: 3px 7px; border-radius: 6px; border: 1px solid rgba(255,255,255,0.25); color: #fff; font-size: 13px; }
.ph-card2 strong { display: block; margin-top: 6px; font-size: 22px; font-weight: 700; }
.ph-card2.risk strong { color: #F44336; }
.ph-card2.rew strong { color: var(--ph-primary); }
.ph-card2 small { display: block; margin-top: 3px; font-size: 12.5px; color: #C0C7D0; }
.ph-rbar { display: flex; height: 4px; margin: 12px 2px 0; border-radius: 2px; overflow: hidden; }
.ph-rbar i { flex: 1; background: #F44336; }
.ph-rbar i + i { flex: 2; background: var(--ph-primary); }
.ph-rfoot { display: flex; gap: 8px; margin-top: 10px; }
.ph-rlots { flex: 1; height: 46px; box-sizing: border-box; border-radius: 10px; border: 1px solid rgba(244, 67, 54, 0.45); background: rgba(244, 67, 54, 0.08); display: flex; align-items: center; justify-content: center; font-size: 16px; font-weight: 600; color: #fff; }
.ph-review { flex: 1; height: 46px; border-radius: 10px; background: linear-gradient(90deg, #00FF8F, #00A1FF); display: flex; align-items: center; justify-content: center; font-size: 17px; font-weight: 700; color: #000; }
.ph-corner { position: absolute; right: 5px; width: 32px; height: 32px; box-sizing: border-box; border-radius: 7px; border: 1.2px solid var(--ph-primary); background: rgba(10,14,20,0.9); display: flex; align-items: center; justify-content: center; color: var(--ph-primary); }

.ph-rrow .ph-rseg { display: flex; }
.ph-rrow .ph-rseg:first-child { flex: 2; }
.ph-rrow .ph-rseg:nth-child(2) { flex: 3; }
.ph-rrow .ph-rseg span { flex: 1; text-align: center; padding: 7px 0; }
.ph-rx { margin-left: 4px; }
.ph-mini { display: inline-flex; align-items: center; gap: 1px; white-space: nowrap; padding: 3px 5px 3px 8px; }
.ph-mini svg { flex: none; }

/* ═══ Analytics (Overview + Journal tabs) ═══ */
.ph-ahead { height: 52px; display: flex; align-items: center; gap: 8px; padding: 0 9px 0 22px; background: var(--ph-surface); }
.ph-ahead > b { font-size: 23px; font-weight: 600; color: #fff; margin-right: auto; }
.ph-dd { height: 36px; box-sizing: border-box; display: flex; align-items: center; gap: 6px; padding: 0 9px 0 13px; border-radius: 9px; border: 1px solid var(--ph-border); background: #10151C; font-size: 15.5px; color: #fff; }
.ph-dd svg { color: var(--ph-text2); }
.ph-tabs { display: flex; margin: 14px 13px 0; padding: 3px; border-radius: 11px; border: 1px solid var(--ph-border); background: var(--ph-surface); }
.ph-tabs span { flex: 1; text-align: center; padding: 7px 0; font-size: 16px; color: #C0C7D0; border-radius: 9px; }
.ph-tabs span.on { background: linear-gradient(90deg, #00FF8F, #00A1FF); color: #000; font-weight: 600; }
.ph-acard { margin: 12px 8px 0; border-radius: 12px; border: 1px solid var(--ph-border); background: var(--ph-surface); overflow: hidden; position: relative; }
.ph-acard-top { display: flex; align-items: center; padding: 8px 8px 0 16px; font-size: 13.5px; color: #C0C7D0; gap: 4px; }
.ph-acard-top .bal { color: #00FF8F; font-weight: 600; margin-right: 10px; }
.ph-acard-top .eq { color: #2AA4FF; font-weight: 600; }
.ph-acard-top .ph-dd { margin-left: auto; height: 30px; font-size: 14px; padding: 0 7px 0 11px; }
.ph-ddrow { display: flex; align-items: center; gap: 6px; padding: 0 16px; font-size: 13.5px; color: #C0C7D0; }
.ph-ddrow .f { color: #FF9F1C; font-weight: 600; margin-right: 10px; }
.ph-ddrow .m { color: #F44336; font-weight: 600; }
.ph-ddrow i { font-style: normal; width: 16px; height: 16px; box-sizing: border-box; border: 1.5px solid #C0C7D0; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 10px; font-weight: 700; margin-left: 4px; }
.ph-kpis { display: flex; gap: 8px; margin: 12px 13px 0; }
.ph-kpi { flex: 1; padding: 11px 12px; border-radius: 12px; border: 1px solid var(--ph-border); background: var(--ph-surface); }
.ph-kpi small { display: block; font-size: 12px; letter-spacing: 0.6px; color: #C0C7D0; }
.ph-kpi strong { display: block; margin-top: 6px; font-size: 19px; font-weight: 700; }
.ph-stats { display: flex; gap: 8px; margin: 10px 13px 0; }
.ph-stat { flex: 1; border-radius: 12px; border: 1px solid var(--ph-border); background: var(--ph-surface); padding: 10px 14px 0; }
.ph-stat > small { display: block; font-size: 12px; letter-spacing: 1px; color: #C0C7D0; margin-bottom: 4px; }
.ph-stat div { display: flex; justify-content: space-between; align-items: baseline; padding: 9px 0; border-top: 1px solid rgba(255,255,255,0.06); font-size: 15px; color: #C0C7D0; }
.ph-stat div:first-of-type { border-top: 0; }
.ph-stat b { font-size: 16px; color: #fff; }
.ph-orange { color: #FF9F1C !important; }
/* journal */
.ph-cal { margin: 12px 9px 0; padding: 12px 12px 10px; border-radius: 12px; border: 1px solid var(--ph-border); background: var(--ph-surface); }
.ph-calhead { display: flex; align-items: center; gap: 10px; }
.ph-calbtn { width: 34px; height: 34px; box-sizing: border-box; border-radius: 8px; border: 1px solid var(--ph-border); background: #10151C; display: flex; align-items: center; justify-content: center; color: #fff; }
.ph-calhead b { font-size: 17px; color: #fff; font-weight: 600; }
.ph-calhead .tot { margin-left: auto; font-size: 17px; font-weight: 700; color: var(--ph-primary); }
.ph-wk { display: grid; grid-template-columns: repeat(7, 1fr); margin-top: 10px; text-align: center; font-size: 13px; color: #C0C7D0; }
.ph-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; margin-top: 6px; }
.ph-day { height: 52px; box-sizing: border-box; border-radius: 7px; border: 1px solid var(--ph-border); background: #0E1319; padding: 4px 5px; font-size: 12px; color: #C0C7D0; display: flex; flex-direction: column; justify-content: space-between; }
.ph-day.g { background: rgba(0, 212, 170, 0.14); border-color: rgba(0, 212, 170, 0.35); }
.ph-day.r { background: rgba(244, 67, 54, 0.13); border-color: rgba(244, 67, 54, 0.35); }
.ph-day.today { border: 1.5px solid var(--ph-primary); }
.ph-day b { font-size: 12.5px; font-weight: 600; text-align: center; }
.ph-day.g b { color: var(--ph-primary); }
.ph-day.r b { color: #F44336; }
.ph-day.blank { visibility: hidden; }
.ph-mstats { margin: 10px 9px 0; padding: 12px 16px; border-radius: 12px; border: 1px solid var(--ph-border); background: var(--ph-surface); display: grid; grid-template-columns: 1fr 1fr 1fr; row-gap: 10px; }
.ph-mstats > small { grid-column: 1 / -1; font-size: 15px; font-weight: 600; color: #fff; }
.ph-mstats div { font-size: 13px; color: #C0C7D0; }
.ph-mstats div b { display: block; margin-top: 3px; font-size: 18px; font-weight: 700; color: #fff; }
.ph-mstats div em { display: block; font-style: normal; font-size: 12px; color: #C0C7D0; }
.ph-mstats .most { grid-column: 1 / -1; font-size: 13px; color: #C0C7D0; }

.ph-ahead > b { font-size: 21px; }
.ph-ahead .ph-dd { font-size: 14.5px; padding: 0 6px 0 11px; gap: 3px; }
.ph-kpi small { font-size: 10.5px; letter-spacing: 0.3px; white-space: nowrap; }
.ph-mstats .most { grid-column: 1 / -1; font-size: 13px; color: #C0C7D0; }

/* app colours win inside Month Stats and the stat cards */
.ph-frame b.ph-up, .ph-frame b .ph-up { color: var(--ph-primary); }
.ph-frame b.ph-down, .ph-frame b .ph-down { color: var(--ph-loss); }

/* ═══ Calendar ═══ */
.ph-cl-list { padding: 0 9px; }
.ph-dhead { display: flex; align-items: center; gap: 10px; margin: 14px 4px 8px; font-size: 16px; font-weight: 600; color: #fff; }
.ph-dhead::after { content: ''; flex: 1; border-top: 1px solid rgba(255,255,255,0.14); }
.ph-dhead.next { color: var(--ph-primary); }
.ph-dhead.next::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--ph-primary); }
.ph-dhead.next::after { border-top: 1.5px solid var(--ph-primary); }
.ph-ev { display: flex; align-items: center; gap: 11px; height: 54px; box-sizing: border-box; padding: 0 12px; margin-bottom: 6px; border-radius: 10px; border: 1px solid rgba(48,54,61,0.6); background: var(--ph-surface); }
.ph-ev.muted { opacity: 0.62; }
.ph-ev.alert { border: 1.2px solid rgba(0, 212, 170, 0.5); }
.ph-imp { width: 9px; height: 9px; border-radius: 50%; flex: none; }
.ph-imp.h { background: #F44336; } .ph-imp.m { background: #FF9F1C; } .ph-imp.l { background: #FFD60A; }
.ph-tc { width: 44px; flex: none; font-size: 15px; color: #fff; line-height: 1.25; }
.ph-tc small { display: block; font-size: 13px; color: #C0C7D0; }
.ph-en { flex: 1; min-width: 0; font-size: 15px; color: #fff; display: flex; align-items: center; gap: 6px; line-height: 1.25; }
.ph-en svg { color: var(--ph-primary); flex: none; }
.ph-vals { display: grid; grid-template-columns: repeat(3, auto); column-gap: 11px; text-align: right; font-size: 11px; color: #C0C7D0; }
.ph-vals b { font-size: 14.5px; font-weight: 400; color: #fff; }
.ph-vals b.cd { color: var(--ph-primary); font-weight: 600; }
.ph-tabs .dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; margin-right: 6px; vertical-align: 2px; }

/* ═══ Automation (the Rules sheet, over the Copilot) ═══ */
.ph-cop { position: absolute; left: 0; right: 0; top: 44px; bottom: 0; border-radius: 28px 28px 0 0; background: var(--ph-surface); }
.ph-handle { width: 32px; height: 4px; border-radius: 2px; background: #4A525C; margin: 10px auto 0; }
.ph-cop-head { display: flex; align-items: center; gap: 9px; height: 46px; margin-top: 10px; padding: 0 22px; }
.ph-cop-head b { font-size: 20px; font-weight: 600; margin-left: 6px; }
.ph-cop-head small { font-size: 13.5px; color: var(--ph-text2); margin-right: auto; }
.ph-cop-head .ph-hbtn { width: 38px; height: 38px; border-radius: 9px; }
.ph-cop-chat { padding: 10px 18px 0; }
.ph-cop-me { margin-left: 60px; padding: 12px 16px; border-radius: 16px; background: #133A33; border: 1px solid #1F6B5C; font-size: 15.5px; line-height: 1.35; }
.ph-cop-done { margin-top: 12px; padding: 12px 16px; border-radius: 14px; border: 1px solid #1F6B5C; background: #0A0E14; display: flex; align-items: center; gap: 8px; font-size: 15.5px; }
.ph-cop-done b { flex: 1; min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.ph-cop-done span { color: var(--ph-primary); font-weight: 600; }
.ph-scrim { position: absolute; left: 0; right: 0; top: 40px; bottom: 0; background: rgba(0, 0, 0, 0.54); }
.ph-rs { position: absolute; left: 0; right: 0; top: 256px; bottom: 0; border-radius: 28px 28px 0 0; background: var(--ph-surface); }
.ph-rs-title { display: flex; align-items: center; gap: 9px; height: 50px; margin-top: 6px; padding: 0 22px; }
.ph-rs-title b { font-size: 20.7px; font-weight: 600; }
.ph-rtabs { display: flex; height: 40px; box-sizing: border-box; margin: 2px 16px 0; padding: 3px; border-radius: 10px; border: 1px solid var(--ph-border); background: var(--ph-surface); }
.ph-rtabs span { flex: 1; display: flex; align-items: center; justify-content: center; border-radius: 8px; font-size: 15px; color: #C0C7D0; }
.ph-rtabs span.on { background: var(--ph-grad); color: #000; font-weight: 600; }
.ph-rsub { display: flex; margin: 8px 34px 0; border-bottom: 1px solid var(--ph-border); }
.ph-rsub span { flex: 1; height: 44px; box-sizing: border-box; display: flex; align-items: center; justify-content: center; font-size: 15px; font-weight: 500; color: #C0C7D0; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.ph-rsub span i { font-style: normal; font-weight: 400; margin-left: 4px; }
.ph-rsub span.on { color: #fff; font-weight: 600; border-bottom-color: var(--ph-primary); }
.ph-rsub span.on i { color: var(--ph-primary); }
.ph-rlist { padding: 14px 16px 0; }
.ph-rcard { box-sizing: border-box; margin-bottom: 12px; padding: 12px 6px 6px 16px; border-radius: 16px; background: #0A0E14; border: 1px solid var(--ph-border); }
.ph-rcard.on { border-color: rgba(0, 212, 170, 0.35); }
.ph-rtop { display: flex; align-items: center; min-height: 36px; gap: 9px; }
.ph-rpill { display: inline-flex; align-items: center; gap: 7px; padding: 5px 12px; border-radius: 999px; font-size: 13.8px; font-weight: 600; white-space: nowrap; }
.ph-rpill i { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.ph-rpill.ok { color: #00D4AA; background: rgba(0, 212, 170, 0.14); }
.ph-rpill.warn { color: #FF9800; background: rgba(255, 152, 0, 0.14); }
.ph-rpill.idle { color: #9CA3AF; background: rgba(156, 163, 175, 0.14); }
.ph-rmeta { flex: 1; min-width: 0; font-size: 13.8px; color: #C0C7D0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ph-rmore { width: 40px; height: 36px; display: flex; align-items: center; justify-content: center; color: var(--ph-text2); flex: none; }
.ph-rcard.off .ph-rbody { opacity: 0.7; }
.ph-rname { display: block; margin-top: 4px; padding-right: 8px; font-size: 16.7px; font-weight: 700; }
.ph-rwt > div { display: flex; padding-top: 7px; padding-right: 8px; font-size: 14.4px; line-height: 1.35; }
.ph-rwt span:first-child { width: 51px; flex: none; font-weight: 600; }
.ph-rwt .w { color: #00A1FF; }
.ph-rwt .t { color: var(--ph-primary); }
.ph-raccts { display: flex; align-items: center; gap: 9px; margin: 9px 8px 0 0; padding: 8px 0 6px; border-top: 1px solid rgba(48, 54, 61, 0.6); color: #C0C7D0; }
.ph-raccts span { flex: 1; min-width: 0; font-size: 15px; color: var(--ph-text2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ph-rhint { margin-top: 10px; text-align: center; font-size: 14.4px; color: #C0C7D0; }
.ph-rgrp { display: flex; font-style: normal; }

/* ═══ Automation · the wand sheet (account rules: components/account_risk_section.dart) ═══ */
.ph-wp { position: absolute; left: 0; right: 0; top: 92px; bottom: 0; padding: 13px 17px 0; background: var(--ph-surface); }
.ph-wcard { box-sizing: border-box; margin-bottom: 9px; border-radius: 12px; background: var(--ph-surface); border: 1px solid #555E68; }
.ph-wcard.eg-on { border: 1.2px solid rgba(0, 255, 143, 0.5); }
.ph-wcard.dll-on { border: 1.2px solid rgba(0, 161, 255, 0.5); }
.ph-whead { display: flex; align-items: center; gap: 11px; padding: 15px 17px; }
.ph-wtag { flex: none; padding: 4px 7.5px; border-radius: 5px; font-size: 13.8px; font-weight: 800; letter-spacing: 0.5px; }
.ph-wtag.eg { color: #00FF8F; background: rgba(0, 255, 143, 0.2); border: 0.5px solid rgba(0, 255, 143, 0.4); }
.ph-wtag.dll { color: #00A1FF; background: rgba(0, 161, 255, 0.2); border: 0.5px solid rgba(0, 161, 255, 0.4); }
.ph-wtitle { flex: 1; min-width: 0; }
.ph-wtitle > div { display: flex; align-items: center; gap: 6.5px; }
.ph-wtitle b { font-size: 16.1px; font-weight: 600; }
.ph-wtitle small { display: block; margin-top: 2px; font-size: 12.65px; color: #8B949E; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ph-winfo { color: var(--ph-text2); }
.ph-warmed { margin-left: 2px; padding: 2px 6.5px; border-radius: 4px; font-size: 11.5px; font-weight: 600; }
.ph-warmed.dll { color: #00A1FF; background: rgba(0, 161, 255, 0.2); border: 0.5px solid rgba(0, 161, 255, 0.35); }
.ph-wchev { color: var(--ph-text2); flex: none; }
.ph-wbody { padding: 17px; border-top: 1px solid rgba(48, 54, 61, 0.5); }
.ph-wfields { display: flex; gap: 13px; }
.ph-wfields > div { flex: 1; min-width: 0; }
.ph-wlabel { display: flex; align-items: center; gap: 4px; font-size: 13.8px; color: var(--ph-text2); }
.ph-wlabel .req { color: #F44336; }
.ph-wfield { display: flex; align-items: center; margin-top: 4px; height: 41px; padding: 0 13px; box-sizing: border-box; border-radius: 8px; background: var(--ph-bg); font-size: 16.1px; }
.ph-wfield span { flex: 1; }
.ph-wfield i { font-style: normal; font-size: 12.65px; color: #8B949E; }
.ph-wrepeat { display: flex; align-items: center; gap: 6px; margin: 6px 0 0 calc(50% + 6.5px); font-size: 12.65px; color: var(--ph-text2); }
.ph-wrepeat svg { color: #00FF8F; }
.ph-wsec { margin-top: 6px; font-size: 13.8px; color: var(--ph-text2); }
.ph-wsec.gap { margin-top: 15px; }
.ph-wseg { display: flex; margin-top: 6px; }
.ph-wseg span { flex: 1; padding: 8.5px 2px; text-align: center; font-size: 13.8px; color: #8B949E; background: var(--ph-bg); border: 0.8px solid rgba(48, 54, 61, 0.3); }
.ph-wseg span:first-child { border-radius: 6px 0 0 6px; }
.ph-wseg span:last-child { border-radius: 0 6px 6px 0; }
.ph-wseg span.on { color: #00FF8F; font-weight: 600; background: rgba(0, 255, 143, 0.18); border-color: rgba(0, 255, 143, 0.55); }
.ph-wcap { margin-top: 4px; font-size: 12.65px; font-style: italic; color: #8B949E; }
.ph-wapplyto { margin-top: 17px; font-size: 12.65px; color: var(--ph-text2); }
.ph-wchips { display: flex; flex-wrap: wrap; gap: 6.5px; margin-top: 6.5px; }
.ph-wchip { display: inline-flex; align-items: center; gap: 5px; padding: 5px 9.5px; border-radius: 6px; font-size: 13.8px; font-weight: 600; color: #00FF8F; background: rgba(0, 255, 143, 0.15); border: 1px solid #00FF8F; }
.ph-wapply { display: flex; align-items: center; justify-content: center; height: 51px; margin-top: 11px; box-sizing: border-box; border-radius: 10px; border: 1px solid #00FF8F; color: #00FF8F; font-size: 14.95px; font-weight: 500; }
.ph-under { position: absolute; left: 0; right: 0; top: 268px; }
.ph-wp { bottom: auto; padding-bottom: 17px; border-radius: 0 0 16px 16px; box-shadow: 0 8px 14px rgba(0, 0, 0, 0.54); }
/* Home's rule bars (home_cards.dart: 3 px LinearProgressIndicators over the card, clipped to its 12 px corners) */
.ph-card.ph-ruled { overflow: hidden; }
.ph-egbar, .ph-dllbar { position: absolute; left: -1px; height: 3px; max-width: calc(100% + 2px); }
.ph-egbar { top: -1px; background: #00FF8F; }
.ph-dllbar { bottom: -1px; background: #00A1FF; }
.ph-dllbar[style*="width:100%"] { width: calc(100% + 2px) !important; }
.ph-frame strong.ph-flat, .ph-frame i.ph-flat { color: #C0C7D0; }
/* Trade rules (components/automation_section.dart) */
.ph-wtag.ptp { color: #38BDF8; background: rgba(56, 189, 248, 0.2); border: 0.5px solid rgba(56, 189, 248, 0.4); }
.ph-wtag.tsl { color: #E91E8C; background: rgba(233, 30, 140, 0.2); border: 0.5px solid rgba(233, 30, 140, 0.4); }
.ph-wtag.abe { color: #FF9800; background: rgba(255, 152, 0, 0.2); border: 0.5px solid rgba(255, 152, 0, 0.4); }
.ph-wcard.abe-on { border: 1.2px solid rgba(255, 152, 0, 0.5); }
.ph-wcard.tsl-on { border: 1.2px solid rgba(233, 30, 140, 0.5); }
.ph-wcard.ptp-on { border: 1.2px solid rgba(56, 189, 248, 0.5); }
.ph-wpend { margin-left: 2px; padding: 2px 6.5px; border-radius: 4px; font-size: 11.5px; font-weight: 600; color: #FFB020; background: rgba(255, 176, 32, 0.2); border: 0.5px solid rgba(255, 176, 32, 0.35); }
.ph-wfield .hint { font-size: 13.8px; color: rgba(156, 163, 175, 0.4); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ph-wapply.tsl { height: 54px; margin-top: 17px; border-color: #E91E8C; color: #E91E8C; }
.ph-under3 { top: 350px; }
.ph-pos-top .ph-side-tag.buy { background: #00D4AA; color: #062016; }
.ph-field .hint { flex: 1; color: rgba(156, 163, 175, 0.5); }
.ph-ftag { flex: none; padding: 3px 6.5px; border-radius: 4px; font-size: 11.5px; font-weight: 800; letter-spacing: 0.5px; }
.ph-ftag.abe { color: #FF9800; background: rgba(255, 152, 0, 0.2); border: 0.5px solid rgba(255, 152, 0, 0.4); }
.ph-plc.up { border-color: rgba(0, 212, 170, 0.6); background: rgba(0, 212, 170, 0.1); color: #00D4AA; }
.ph-handle4 { position: absolute; left: 292px; width: 34px; height: 8px; }
/* New Order: one Lot ratios pill beside ACCOUNTS (components/lot_ratios_pill.dart, 17 Nov 2026) */
.ph-acc-row { display: flex; align-items: center; gap: 11px; }
.ph-ratios { padding: 6.5px 13px; border-radius: 18px; font-size: 13.8px; font-weight: 600; letter-spacing: 0; color: #C0C7D0; border: 1px solid var(--ph-border); }
.ph-ratios.on { color: #000; border-color: transparent; background: linear-gradient(90deg, #00FF8F, #00A1FF); }
.ph-ochip small.ratio { color: #00A1FF; }
.ph-symres { display: flex; gap: 8px; margin-top: 9px; }
.ph-symres span { padding: 5px 9px; border-radius: 6px; background: var(--ph-surface); font-size: 13.8px; color: var(--ph-text2); }
.ph-symres b { color: #00D4AA; font-weight: 600; }
/* a line target on an element's left edge, so the line arrives from the side */
.ph-seg.ex { position: relative; }
.ph-anchor { position: absolute; left: 0; top: 0; bottom: 0; width: 2px; }
/* Risk Calculator · Review (components/risk_accounts_sheet.dart) */
.ph-rv { position: absolute; left: 0; right: 0; bottom: 16px; z-index: 2; box-sizing: border-box; padding: 18px 18px 0; border-radius: 16px 16px 0 0; background: var(--ph-surface); display: flex; flex-direction: column; }
.ph-rvhead { display: flex; align-items: flex-start; gap: 9px; }
.ph-rvhead > div { flex: 1; }
.ph-rvhead b { display: block; font-size: 15px; font-weight: 600; line-height: 1.45; }
.ph-rvhead b.m { font-weight: 500; }
.ph-rvcap { position: relative; margin-top: 7px; font-size: 13.8px; color: #C0C7D0; }
.ph-rvrows { margin-top: 14px; }
.ph-rvrow { display: flex; gap: 9px; margin-bottom: 7px; padding: 9px 14px; border-radius: 8px; background: rgba(0, 212, 170, 0.15); border: 1px solid #00D4AA; }
.ph-rvtick { flex: none; margin-top: 1px; }
.ph-rvbody { flex: 1; min-width: 0; }
.ph-rvl1 { display: flex; align-items: center; gap: 7px; font-size: 15px; }
.ph-rvl1 b { font-weight: 600; }
.ph-rvl1 .ph-main { font-size: 10.4px; padding: 2px 6px; }
.ph-rvl1 > span:last-child { margin-left: auto; }
.ph-rvl2 { display: flex; justify-content: space-between; margin-top: 3px; font-size: 13.8px; color: #C0C7D0; white-space: nowrap; }
.ph-rvl2 i { font-style: normal; }
.ph-rvl2 i.loss { color: #F44336; }
.ph-rvl2 i.win { color: #00D4AA; }
.ph-rvfoot { display: flex; align-items: center; gap: 9px; padding: 14px 0 16px; }
.ph-rvcancel { flex: 1; text-align: center; font-size: 16px; font-weight: 600; color: var(--ph-text2); }
.ph-rvplace { flex: 2; height: 51px; display: flex; align-items: center; justify-content: center; border-radius: 12px; background: linear-gradient(90deg, #00FF8F, #00A1FF); color: #000; font-size: 16px; font-weight: 700; }
.ph-rv ~ .ph-gesture, .ph-frame > .ph-scrim { z-index: 1; }
.ph-rvorder { position: relative; }
