/* ennusta.com dark theme (loaded only on the shell domain, applies when <html data-theme="dark">).
   Generated parts come from pm.css via shell/build_dark_css.py; this head and the tail are hand-written. */

html[data-theme="dark"] { color-scheme: dark; }
html[data-theme="dark"] body.pmx { background: #15191f; color: #e8ebf0; }

html[data-theme="dark"] .pm {
  --pm-ink: #e8ebf0;
  --pm-line: #2a303b;
  --pm-panel: #232933;
  --pm-muted: #8b94a3;
  --pm-muted-2: #b6bdc9;
  --pm-sel: #2b6cc4;
  --pm-navy: #2b6cc4;
  --pm-deep: #7fd0f5;
  --pm-accent: #5cd4ff;
  --pm-yes: #3ecf7a;
  --pm-yes-text: #3ecf7a;
  --pm-yes-bar: #1f6b48;
  --pm-no: #f0605d;
  --pm-no-text: #f0605d;
  --pm-no-bar: #7a2a2d;
  --pm-glow: none;
}

html[data-theme="dark"] .pmx-foot { background: #1e2127; border-top-color: #2a303b; color: #9aa3b2; }

html[data-theme="dark"] .ens { background: #1b2029; border-bottom-color: #2a303b; }
html[data-theme="dark"] .ens-logo { color: #fff; }
html[data-theme="dark"] .ens-tabs a { color: #9aa3b2; }
html[data-theme="dark"] .ens-tabs a:hover,
html[data-theme="dark"] .ens-tabs a.is-on { color: #fff; }
html[data-theme="dark"] .ens-chip { background: #232933; border-color: #2a303b; color: #fff; }
html[data-theme="dark"] .ens-rank { color: #F1C40F; }
html[data-theme="dark"] .ens-rank span { color: #8b94a3; }
html[data-theme="dark"] .oas-th { color: #9aa3b2; }
html[data-theme="dark"] .oas-th:hover { background: #2a303b; color: #fff; }
html[data-theme="dark"] .pmx-hero h2 { color: #fff; }
html[data-theme="dark"] .pmx-hero p { color: #8b94a3; }
html[data-theme="dark"] .pmx-hero-link { color: #5cc0ec; }
@media (max-width: 768px) { html[data-theme="dark"] .ens-tabs { border-top-color: #262c36; } }

/* ---- generated from pm.css by shell/build_dark_css.py ---- */
html[data-theme="dark"] .pm-head { border-bottom: 1px solid #3f4753; }
html[data-theme="dark"] .pm-layout-trade.is-sibs > main > .pm-card.is-focus { background: #1a2731; }
html[data-theme="dark"] .pm-layout-trade.is-sibs aside .pm-tr,
html[data-theme="dark"] .pm-layout-trade.is-sibs aside .pm-card.is-panel { background: #1e2127; }
html[data-theme="dark"] .pm-card { background: #1e2127; }
html[data-theme="dark"] .pm-card.is-navy { background: #1f3139; color: var(--color-cyan-extra-dark, #80d6ff); border-color: #273f4a; }
html[data-theme="dark"] .pm-card.is-navy .pm-muted { color: #8baab8; }
html[data-theme="dark"] .pm-card.is-navy .pm-label { color: var(--color-cyan-extra-dark, #80d6ff); }
html[data-theme="dark"] .pm-prize-pill { background: #1f3139; border: 1px solid #273f4a; color: var(--color-cyan-extra-dark, #80d6ff); }
html[data-theme="dark"] .pm-row { background: #1e2127; }
html[data-theme="dark"] .pm-row:hover { border-color: #404d59; }
html[data-theme="dark"] .pm-cat { background: #24272c; color: #aaafb7; }
html[data-theme="dark"] .pm-btn.yes { background: #213e30; border: 1px solid #315542; }
html[data-theme="dark"] .pm-btn.no { background: #381f1e; border: 1px solid #4d2b29; }
html[data-theme="dark"] .pm-btn.main { background: #3f4753; color: #dedede; }
html[data-theme="dark"] .pm-btn.ghost { background: #1e2127; }
html[data-theme="dark"] .pm-badge { border: 1px solid #3a3e44; }
html[data-theme="dark"] .pm-badge.open { color: #9aebc6; }
html[data-theme="dark"] .pm-badge.open::before { background: #549d7d; }
html[data-theme="dark"] .pm-badge.yes { background: #213e30; border-color: #315542; }
html[data-theme="dark"] .pm-badge.no { background: #381f1e; border-color: #4d2b29; }
html[data-theme="dark"] .pm-seg button { background: #1e2127; }
html[data-theme="dark"] .pm-seg button.is-on.yes { background: #213e30; }
html[data-theme="dark"] .pm-seg button.is-on.no { background: #381f1e; }
html[data-theme="dark"] .pm-chips button { background: #1e2127; }
html[data-theme="dark"] .pm-msg.ok { background: #213e30; color: #a5eacd; }
html[data-theme="dark"] .pm-msg.err { background: #381f1e; color: #de7d75; }
html[data-theme="dark"] .pm-chart-grid.is-mid { stroke: #404d59; }
html[data-theme="dark"] .pm-table tr.is-me td { background: #20343b; }
html[data-theme="dark"] .pm-notice { background: #20343b; border: 1px solid #345461; }
html[data-theme="dark"] .pm-pill { background: #292b2f; }
html[data-theme="dark"] .pm-pill button { color: #aaafb7; }
html[data-theme="dark"] .pm-pill button.is-on.yes { background: #213e30; }
html[data-theme="dark"] .pm-pill button.is-on.no { background: #381f1e; }
html[data-theme="dark"] .pm-tr-cta { color: #bde1f2; }
html[data-theme="dark"] .pm-catpills a { background: #1e2127; }
html[data-theme="dark"] .pm-pos-pill { border: 1px solid #3a3e44; background: #292c32; }
html[data-theme="dark"] .pm-pos-pill.yes { background: #213e30; border-color: #315542; }
html[data-theme="dark"] .pm-pos-pill.no { background: #381f1e; border-color: #4d2b29; }
html[data-theme="dark"] .pm-week-wins { color: #d8aa48; }
html[data-theme="dark"] .pm-tr-cta:not([disabled]):hover { background: #4e8192; }
html[data-theme="dark"] .pm-btn.yes:hover { background: #274837; }
html[data-theme="dark"] .pm-btn.no:hover { background: #422524; }
html[data-theme="dark"] .pm-modal-box { background: #1e2127; }
html[data-theme="dark"] .pm-seg { background: #2b2e33; }
html[data-theme="dark"] .pm-row-game .pm-game-sec,
html[data-theme="dark"] .pm-game-sibs .pm-game-sec { border-top: 1px dotted #3f4753; }
html[data-theme="dark"] .pm-out { background: #1e2127; }
html[data-theme="dark"] .pm-out.is-win { background: #1b2c33; border-color: #263c46; }
html[data-theme="dark"] .pm-out-btn { background: #1f3139; border: 1px solid #273f4a; }
html[data-theme="dark"] .pm-out-btn:hover { background: #243a43; }
html[data-theme="dark"] .pm-pill.multi button.is-on { background: #1e2127; }
html[data-theme="dark"] .pm-pill.multi.as-list button { background: #292b2f; }
html[data-theme="dark"] a.pm-pos-more { background: #1e2127; }
html[data-theme="dark"] .pm-sellbtn { color: var(--pm-deep, #80d6ff); background: #1f3139; border: 1px solid #273f4a; }
html[data-theme="dark"] .pm-sellbtn:hover { background: #243a43; }
html[data-theme="dark"] .pm-confirm-est { background: #24272c; }
html[data-theme="dark"] .pm-seg-mini { background: #292c32; }
html[data-theme="dark"] .pm-pg { border: 1px solid #3a3e44; background: #1e2127; }
html[data-theme="dark"] .pm-card.pm-prize { background: #1e2127; }
html[data-theme="dark"] .pm-prize-head svg { color: #66d4ff; }
html[data-theme="dark"] .pm-prize-row:nth-child(odd) { background: #25282f; }
html[data-theme="dark"] .pm-prize-sub { border-top: 1px dotted #3f4753; }
html[data-theme="dark"] .pm-prize-pill { background: #292c32; color: #aaafb7; }
html[data-theme="dark"] .pm-row-special .pm-cat { background: #1f3139; color: #80d6ff; }
html[data-theme="dark"] .pm-special-chip { background: #1f3139; color: #80d6ff; }
html[data-theme="dark"] .pm-special-prize { background: #473e26; color: #e9cc93; }
html[data-theme="dark"] .pm-special-picked { color: #66d4ff; }
html[data-theme="dark"] .pm-special-panel h2 { color: #80d6ff; }
html[data-theme="dark"] .pm-special-prizeblock { background: #1f3139; }
html[data-theme="dark"] .pm-special-prize-k { color: #80d6ff; }
html[data-theme="dark"] .pm-me-rank { background: #292c32; color: #aaafb7; }
html[data-theme="dark"] .pm-me-rank svg { color: #66d4ff; }
html[data-theme="dark"] .pm-me-bar i { background: #46484e; }
html[data-theme="dark"] .pm-cat-more > button { background: #1e2127; }
html[data-theme="dark"] .pm-prof-head .pm-nb-pen { background: #1e2127; }
html[data-theme="dark"] .pm-prof-head .pm-nb-pen:hover { background: #24272c; }
html[data-theme="dark"] .pm-prof-head .pm-nb-cancel { background: #1e2127; }
html[data-theme="dark"] .pm-prof-stats .pm-nb-col.is-total .pm-nb-val { color: #66d4ff; }
html[data-theme="dark"] .pm-pills { background: #2b2e33; }
html[data-theme="dark"] .pm-pnl-num.is-up { color: #66d4ff; }
@media (min-width: 1101px) {
html[data-theme="dark"] .pm-out:has(.pm-out-cover):hover { border-color: #404d59; }
}
html[data-theme="dark"] .pm-sheet-handle { background: #46484e; }
html[data-theme="dark"] .pm-sheet-panel { background: #1e2127; }
html[data-theme="dark"] .pm-cat-select { background: #1e2127 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%238b909a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E") no-repeat right 12px center; }
html[data-theme="dark"] .pm-sheet-go { background: #303238; }
html[data-theme="dark"] .pm-sheet-go:hover { background: #3a3d43; }
html[data-theme="dark"] .pm-filter-btn { background: #1e2127; }
html[data-theme="dark"] .pm-filter-btn[data-open-sheet="pm-prize-sheet"] { color: #66d4ff; }
@media (max-width: 1100px) {
html[data-theme="dark"] .pm-switch { background: #1e2127; }
html[data-theme="dark"] .pm-switch a { background: #1e2127; }
html[data-theme="dark"] .pm-prof-positions .pm-pos-cell:has(> .pm-pos-pill ~ .pm-pos-pill) > .pm-pos-pill:first-child { background: #292c32; border-color: #3a3e44; }
html[data-theme="dark"] .pm.is-nick .pm-nb-sheet { background: #1e2127; }
}
html[data-theme="dark"] .pm-notice { background: #22333c; border: 1px solid #344c5a; color: #9edbf8; }


/* ---- hand-written fixes ---- */
html[data-theme="dark"] .pm-tr-cta { color: #0b2b3a; }
html[data-theme="dark"] .pm-badge.open { color: #3ecf7a; }
html[data-theme="dark"] .pm-card.pm-prize .pm-prize-ico { color: #5cd4ff; }

/* form controls (text-like inputs only; the share box wraps a bare input, so that one stays transparent) */
html[data-theme="dark"] .pm input:not([type="checkbox"]):not([type="radio"]):not([type="range"]),
html[data-theme="dark"] .pm select,
html[data-theme="dark"] .pm textarea { background-color: #232933; color: #e8ebf0; border-color: #2a303b; }
html[data-theme="dark"] .pm input::placeholder,
html[data-theme="dark"] .pm textarea::placeholder { color: #7d8696; }
html[data-theme="dark"] .pm .pm-tr-input { background: #232933; border-color: #2a303b; }
html[data-theme="dark"] .pm .pm-tr-input input { background: transparent; border: 0; }
html[data-theme="dark"] .pm .pm-tr-input:focus-within { border-color: #2c9cdc; }
html[data-theme="dark"] .pm table td,
html[data-theme="dark"] .pm table th { border-color: #2a303b; }

/* Prosentit / Kertoimet switch: one pill, flat segments, lighter active segment */
html[data-theme="dark"] .pm .pm-seg[aria-label="Näytä hinnat"] { background: #232933; border: 1px solid #2a303b; }
html[data-theme="dark"] .pm .pm-seg[aria-label="Näytä hinnat"] button:not(.is-on) { background: transparent !important; border: 0; color: #9aa3b2; }
html[data-theme="dark"] .pm .pm-seg[aria-label="Näytä hinnat"] button:hover { color: #fff; }
html[data-theme="dark"] .pm .pm-seg[aria-label="Näytä hinnat"] button.is-on { background: #3a4150; color: #fff; }

/* messages: translucent tint + bright text, readable on any dark surface */
html[data-theme="dark"] .pm-msg.ok { background: rgba(62, 207, 122, .14); color: #8be8b2; border: 1px solid rgba(62, 207, 122, .35); }
html[data-theme="dark"] .pm-msg.err { background: rgba(240, 96, 93, .14); color: #ffaaa7; border: 1px solid rgba(240, 96, 93, .35); }

/* charts and outcome colours come from PHP as presentation attributes / inline styles */
html[data-theme="dark"] .pm svg [stroke="#2b2c2d"] { stroke: #e8ebf0; }
html[data-theme="dark"] .pm svg [fill="#2b2c2d"] { fill: #e8ebf0; }
html[data-theme="dark"] .pm svg [stroke="#fff"] { stroke: #1e2127; }
html[data-theme="dark"] .pm svg [stroke="#00709c"] { stroke: #5cc0ec; }
html[data-theme="dark"] .pm svg [fill="#00709c"] { fill: #5cc0ec; }
html[data-theme="dark"] .pm svg [stroke="#b3382f"] { stroke: #f0605d; }
html[data-theme="dark"] .pm svg [fill="#b3382f"] { fill: #f0605d; }
html[data-theme="dark"] .pm svg [fill="#e7f6fc"] { fill: rgba(92, 192, 236, .14); }
html[data-theme="dark"] .pm svg [fill="#fdeceb"] { fill: rgba(240, 96, 93, .14); }
html[data-theme="dark"] .pm [style*="#2b2c2d"] { background: #e8ebf0 !important; }
html[data-theme="dark"] .pm [style*="#00709c"] { background: #5cc0ec !important; }

/* bottom sheets and popups: lighter surface, top edge and shadow so they separate from the dark page behind */
html[data-theme="dark"] .pm-sheet-panel,
html[data-theme="dark"] .pm.is-nick .pm-nb-sheet,
html[data-theme="dark"] .pm-layout-trade aside.is-sheet .pm-tr { background: #262c36; border-top: 1px solid #4a5363; box-shadow: 0 -10px 30px rgba(0, 0, 0, .55); }
html[data-theme="dark"] .pm-modal-box { background: #262c36; border: 1px solid #4a5363; box-shadow: 0 20px 50px rgba(0, 0, 0, .6); }
html[data-theme="dark"] .pm-sheet-bg,
html[data-theme="dark"] .pm-layout-trade aside.is-sheet::before { background: rgba(0, 0, 0, .62); }
html[data-theme="dark"] .pm-sheet-handle { background: #5b6575; }

/* prize sheet: no card-in-a-panel, the sheet itself is the surface */
html[data-theme="dark"] .pm-sheet .pm-card.pm-prize { background: transparent; box-shadow: none; }
html[data-theme="dark"] .pm-sheet .pm-prize-row:nth-child(odd) { background: #303846; border-radius: 8px; }
html[data-theme="dark"] .pm-sheet .pm-prize-note { padding: 0 2px; }

/* quick amount chips (10 / 50 / 100 / 250): plain blue text, no background */
html[data-theme="dark"] .pm .pm-chips button { background: transparent !important; border-color: transparent; box-shadow: none; }
