/* 72-disposable-window.css — Chantier 3: watchlist disposable chart+profile windows.
   Floating, draggable, "jetable" (assets/disposable_windows.js). Isolated from the
   dashboard window engine — these carry no .panel-box class and no module id. */

/* ── row ▣ button (mirrors .wl-compare-* from 50-calendar-cards.css) ── */
.wl-chart-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
}
.wl-chart-ico {
  width: 15px; height: 15px;
  background-color: #5f5f66;
  transition: background-color 0.12s ease;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M2 9h2v5H2zM7 5h2v9H7zM12 2h2v12h-2z'/%3E%3C/svg%3E") no-repeat center / contain;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M2 9h2v5H2zM7 5h2v9H7zM12 2h2v12h-2z'/%3E%3C/svg%3E") no-repeat center / contain;
}
.wl-data-row:hover .wl-chart-ico { background-color: var(--accent); }
.wl-chart-btn:hover .wl-chart-ico { background-color: var(--accent-interactive); }
.wl-chart-tip {
  position: absolute;
  right: calc(100% + 8px);
  top: 50%;
  transform: translateY(-50%);
  background: var(--elevated);
  border: 1px solid var(--border-strong);
  color: var(--text);
  font-size: 11px;
  padding: 3px 7px;
  border-radius: 4px;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.12s ease;
  z-index: 60;
}
.wl-chart-btn:hover .wl-chart-tip { opacity: 1; }

/* ── the floating window: liquid-glass skin ── */
.wl-dispo {
  position: absolute;
  border-radius: 22px;
  overflow: visible;
  background: transparent;
  border: none;
  font-family: Consolas, "Courier New", monospace;
  min-width: 360px;
  min-height: 88px;
  color: #cdd8e4;
}
/* 6 stacked glass layers (radius 22) behind a transparent content layer.
   .lgc-blur (flou) and .lgc-bend (déformation SVG) MUST stay separate — on one
   layer the SVG filter cancels the backdrop-filter and the glass disappears. */
.wl-dispo > .lgc-blur, .wl-dispo > .lgc-bend, .wl-dispo > .lgc-frost,
.wl-dispo > .lgc-sheen, .wl-dispo > .lgc-face, .wl-dispo > .lgc-edge {
  position: absolute; inset: 0; border-radius: 22px; pointer-events: none;
}
.wl-dispo > .lgc-blur {
  z-index: 0;
  -webkit-backdrop-filter: blur(15px) saturate(180%) brightness(1.1);
  backdrop-filter: blur(15px) saturate(180%) brightness(1.1);
}
.wl-dispo > .lgc-bend {
  z-index: 1;
  -webkit-backdrop-filter: url(#fl-glass-distort);
  backdrop-filter: url(#fl-glass-distort);
}
.wl-dispo > .lgc-frost { z-index: 2; background: rgba(25, 25, 25, 0.14); }
.wl-dispo > .lgc-sheen {
  z-index: 3;
  background:
    radial-gradient(115% 125% at 50% 42%, rgba(255, 255, 255, 0) 55%, rgba(255, 255, 255, 0.10) 100%),
    linear-gradient(150deg, rgba(255, 255, 255, 0.14), rgba(255, 255, 255, 0) 32%);
}
.wl-dispo > .lgc-face { z-index: 10; box-shadow: 0 12px 40px rgba(0, 0, 0, 0.28); }
.wl-dispo > .lgc-edge {
  z-index: 20;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18), inset 0 1.5px 0 0 rgba(255, 255, 255, 0.22);
}
.wl-dispo > .lgc-content {
  position: relative; z-index: 30; height: 100%;
  display: flex; flex-direction: column;
  border-radius: 22px; overflow: hidden;
}
.wl-dispo-bar {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 11px;
  background: transparent;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  cursor: move;
  flex-shrink: 0;
}
.wl-dispo-lights { display: flex; gap: 7px; }
.wl-dispo-dot {
  width: 12px; height: 12px; border-radius: 50%; cursor: pointer;
  box-shadow: inset 0 0 0 0.5px rgba(0, 0, 0, 0.25);
}
.wl-dispo-dot.red { background: #ff5f57; }
.wl-dispo-dot.amber { background: #febc2e; }
.wl-dispo-title { display: flex; align-items: baseline; gap: 8px; min-width: 0; }
.wl-dispo-title b { color: #e6edf5; font-size: 13px; letter-spacing: 0.04em; }
.wl-dispo-name {
  color: #6b7c90; font-size: 11px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.wl-dispo-quote { margin-left: auto; display: flex; align-items: baseline; gap: 8px; flex-shrink: 0; }
.wl-dispo-quote .px { color: #e6edf5; font-size: 13px; }
.wl-dispo-quote .chg { font-size: 12px; }
.wl-dispo-quote .chg.pos { color: var(--positive); }
.wl-dispo-quote .chg.neg { color: var(--negative); }

.wl-dispo-periods { display: flex; gap: 4px; padding: 8px 11px 4px; flex-shrink: 0; }
.wl-dispo-pill {
  font-size: 10px; color: #7d8da0; padding: 2px 8px; border-radius: 3px;
  border: 1px solid #1e2a39; cursor: pointer; user-select: none;
}
.wl-dispo-pill:hover { border-color: #33465c; color: #aebdcf; }
.wl-dispo-pill.on { color: #0b0f16; background: #5b7fa6; border-color: #5b7fa6; font-weight: 700; }

/* ── Cours / Volume metric cards ── */
.wl-dispo-metrics { display: flex; gap: 10px; padding: 6px 15px 4px; flex-shrink: 0; }
.wl-dispo-mcard {
  flex: 1; border-radius: 13px; padding: 9px 12px; cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.28); background: rgba(255, 255, 255, 0.06);
  transition: background 0.12s ease, border-color 0.12s ease;
}
.wl-dispo-mcard .ml { font-size: 9px; letter-spacing: 0.1em; text-transform: uppercase; color: rgba(255, 255, 255, 0.85); }
.wl-dispo-mcard .mv { font-family: "JetBrains Mono", monospace; font-size: 16px; margin-top: 3px; color: #fff; }
.wl-dispo-mcard .mp {
  display: inline-flex; margin-top: 6px; font-family: "JetBrains Mono", monospace;
  font-size: 10px; padding: 1px 8px; border-radius: 20px;
}
.wl-dispo-mcard .mp.pos { color: #00C805; background: rgba(0, 200, 5, 0.18); }
.wl-dispo-mcard .mp.neg { color: #FF3737; background: rgba(255, 55, 55, 0.16); }
.wl-dispo-mcard.on { background: #fff; border-color: #fff; box-shadow: 0 6px 18px rgba(0, 0, 0, 0.28); }
.wl-dispo-mcard.on .ml { color: #6b6b72; }
.wl-dispo-mcard.on .mv { color: #12141c; }
.wl-dispo-mcard.on .mp.pos { color: #0f9d3a; background: rgba(15, 157, 58, 0.14); }
.wl-dispo-mcard.on .mp.neg { color: #d61f1f; background: rgba(214, 31, 31, 0.12); }

.wl-dispo-chart { position: relative; flex: 1 1 auto; min-height: 90px; padding: 3px 8px 6px; }
.wl-dispo-chart svg { width: 100%; height: 100%; display: block; overflow: visible; }
.wl-dispo-ax { font-family: "JetBrains Mono", monospace; font-size: 8.5px; fill: rgba(255, 255, 255, 0.72); }
.wl-dispo-cross { stroke: rgba(255, 255, 255, 0.4); stroke-dasharray: 3 3; }
.wl-dispo-tip {
  font-family: "Inter", sans-serif; background: rgba(10, 11, 14, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.20); border-radius: 7px; padding: 5px 9px; line-height: 1.25;
}
.wl-dispo-tip .td { font-size: 8.5px; color: rgba(255, 255, 255, 0.6); }
.wl-dispo-tip .tv { font-family: "JetBrains Mono", monospace; font-size: 11px; color: #fff; font-weight: 600; }
.wl-dispo-tip .tc { font-family: "JetBrains Mono", monospace; font-size: 8.5px; }
.wl-dispo-overlay {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  color: #5f7086; font-size: 11px; pointer-events: none;
}

.wl-dispo-sec {
  padding: 9px 12px 3px; font-size: 9px; letter-spacing: 0.1em;
  color: #4f627a; text-transform: uppercase; border-top: 1px solid #182230; flex-shrink: 0;
}
.wl-dispo-grid {
  padding: 2px 12px 12px; display: grid; grid-template-columns: 1fr 1fr;
  gap: 6px 22px; flex-shrink: 0;
}
.wl-dispo-kv {
  display: flex; justify-content: space-between;
  border-bottom: 1px dotted #182230; padding-bottom: 3px;
}
.wl-dispo-kv .k { color: #66788e; font-size: 11px; }
.wl-dispo-kv .v { color: #cdd8e4; font-size: 11px; }

.wl-dispo-resize { position: absolute; right: 0; bottom: 0; width: 14px; height: 14px; cursor: nwse-resize; }
.wl-dispo-resize::after {
  content: ""; position: absolute; right: 3px; bottom: 3px; width: 6px; height: 6px;
  border-right: 2px solid #3a4d63; border-bottom: 2px solid #3a4d63;
}

/* ── Activité: chips (industrie · pays · effectif · place) ── */
.wl-dispo-actsec { margin-top: 2px; }
.wl-dispo-chips { padding: 3px 16px 14px; display: flex; flex-wrap: wrap; gap: 6px 8px; flex-shrink: 0; }
.wl-dispo-chip {
  font-family: "JetBrains Mono", monospace; font-size: 10.5px; color: rgba(255, 255, 255, 0.9);
  background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 20px; padding: 2px 9px;
}

/* collapsed (🟠 réduire) — only the title bar shows */
.wl-dispo.is-collapsed { height: auto !important; min-height: 0; }
.wl-dispo.is-collapsed .wl-dispo-metrics,
.wl-dispo.is-collapsed .wl-dispo-periods,
.wl-dispo.is-collapsed .wl-dispo-chart,
.wl-dispo.is-collapsed .wl-dispo-sec,
.wl-dispo.is-collapsed .wl-dispo-grid,
.wl-dispo.is-collapsed .wl-dispo-chips,
.wl-dispo.is-collapsed .wl-dispo-resize { display: none; }
