/*
 * VEKTRA Compagnon & Webapp — Feuille de style Tesla V6 100 % Sombre (2.6.4-alfa8 / Compagnon 1.2.3).
 * Police Inter embarquée hors-ligne pour un rendu identique à l'application Tesla.
 */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url('fonts/inter-300.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/inter-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('fonts/inter-500.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('fonts/inter-600.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('fonts/inter-700.woff2') format('woff2');
}

:root {
  --bg: #111215;
  --bg-stage: #111215;
  --bg-card: #1a1b20;
  --bg-card-2: #22242b;
  --bg-sheet: #18191e;
  --bg-pill: #23252d;
  --bg-float: rgba(24, 25, 30, 0.92);
  --text-1: #f4f5f7;
  --text-2: #8e9199;
  --text-3: #5d6068;
  --line: rgba(255, 255, 255, 0.08);
  --blue: #3e6ae1;
  --cyan: #38bdf8;
  --teal: #5eead4;
  --green: #22c55e;
  --orange: #f59e0b;
  --red: #ef4444;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

html, body {
  width: 100%;
  height: 100%;
  background: var(--bg);
  color: var(--text-1);
  font-family: var(--font);
  font-feature-settings: "cv02", "cv03", "cv04", "cv11", "tnum";
  letter-spacing: -0.015em;
  overflow: hidden;
}

.phone-frame {
  width: 100%;
  height: 100%;
  max-width: 480px;
  margin: 0 auto;
  background: var(--bg);
  color: var(--text-1);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.phone-frame.landscape-cam {
  max-width: 100%;
}

.app-scroll {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding-top: env(safe-area-inset-top, 10px);
  padding-bottom: 34px;
  scrollbar-width: none;
}
.app-scroll::-webkit-scrollbar { display: none; }

/* ══════════════════════════════════════════════════════════════════
   1. EN-TÊTE EXACT TESLA (BOUTON MICRO + BOUTON CAMÉRA EN HAUT À DROITE)
   ══════════════════════════════════════════════════════════════════ */
.tesla-header {
  padding: 12px 18px 0;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
  position: relative;
  z-index: 4;
}
.header-left-col {
  flex: 0 1 auto;
  min-width: 0;
}
.title-color-row {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.car-name {
  font-size: clamp(20px, 5.6vw, 26px);
  font-weight: 600;
  letter-spacing: -0.025em;
  color: var(--text-1);
  line-height: 1.15;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
/* Boule de sélection de couleur masquée visuellement (conservée dans le code, Alfa 54) */
.car-paint-trigger {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.05);
  display: none !important;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: transform 0.16s ease, border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
  position: relative;
}
.car-paint-trigger:active { transform: scale(0.92); }
.car-paint-trigger.open {
  border-color: rgba(56, 189, 248, 0.75);
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.16);
}
.car-paint-orb {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #9ca3af;
  box-shadow:
    inset -3px -3px 5px rgba(0, 0, 0, 0.42),
    inset 2px 2px 4px rgba(255, 255, 255, 0.45),
    0 0 0 1px rgba(255, 255, 255, 0.22);
  transition: background 0.25s ease;
}

.battery-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
  cursor: pointer;
}
.batt-icon {
  width: 28px;
  height: 13px;
  border: 1.6px solid var(--text-2);
  border-radius: 3.5px;
  padding: 1.5px;
  position: relative;
  display: flex;
  align-items: center;
}
.batt-icon::after {
  content: '';
  position: absolute;
  right: -4px;
  top: 3px;
  width: 2px;
  height: 4.5px;
  background: var(--text-2);
  border-radius: 0 1px 1px 0;
}
.batt-fill {
  height: 100%;
  background: var(--text-2);
  border-radius: 1.5px;
  width: 82%;
  transition: width 0.35s ease, background 0.35s ease;
}
.batt-fill.charging { background: var(--green); }
.battery-main {
  font-size: 14.5px;
  font-weight: 600;
  color: var(--text-2);
}

.dmi-fuel-row {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 4px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-2);
}
.dmi-fuel-row.hidden { display: none; }

.car-state-line {
  margin-top: 5px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text-2);
  display: flex;
  align-items: center;
  gap: 6px;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-top: 4px;
}
.icon-circle-outline {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: transparent;
  border: 1.6px solid var(--text-2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-1);
  cursor: pointer;
  transition: transform 0.15s ease, border-color 0.15s ease;
}
.icon-circle-outline:active { transform: scale(0.9); }

/* ══════════════════════════════════════════════════════════════════
   2. SCÈNE VOITURE 3/4 STUDIO + CORNET DE RECHARGE 3D
   ══════════════════════════════════════════════════════════════════ */
.car-stage {
  position: relative;
  min-height: 204px;
  padding: 8px 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--bg-stage);
}
.car-photo-wrap {
  position: relative;
  width: min(376px, 100%);
  aspect-ratio: 376 / 210;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.car-3d-canvas-wrap {
  position: absolute;
  inset: 0;
  z-index: 2;
  cursor: grab;
  touch-action: none;
}
.car-3d-canvas-wrap:active { cursor: grabbing; }
.car-3d-canvas-wrap canvas {
  width: 100% !important;
  height: 100% !important;
  display: block;
}
.car-3d-loader {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  opacity: 1;
  transition: opacity 0.28s ease;
}
.car-3d-loader.hidden {
  opacity: 0;
}
.car-3d-dual-arc {
  width: 36px;
  height: 36px;
  position: relative;
}
.car-3d-dual-arc::before,
.car-3d-dual-arc::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1.8px solid transparent;
}
.car-3d-dual-arc::before {
  border-top-color: #f4f5f7;
  border-bottom-color: rgba(255, 255, 255, 0.25);
  animation: vektraArcSpin 1.05s cubic-bezier(0.55, 0.15, 0.45, 0.85) infinite;
}
.car-3d-dual-arc::after {
  inset: 6px;
  border-left-color: rgba(255, 255, 255, 0.55);
  border-right-color: rgba(255, 255, 255, 0.08);
  animation: vektraArcSpinRev 1.6s linear infinite;
}
@keyframes vektraArcSpin { to { transform: rotate(360deg); } }
@keyframes vektraArcSpinRev { to { transform: rotate(-360deg); } }
.vk-dmi-split-bar {
  height: 6px;
  border-radius: 99px;
  background: rgba(251, 146, 60, 0.35);
  overflow: hidden;
  margin: 6px 0 8px;
}
.vk-dmi-split-ev {
  height: 100%;
  background: linear-gradient(90deg, #06b6d4, #22c55e);
  border-radius: 99px;
}
.floor-glow {
  position: absolute;
  width: 310px;
  height: 85px;
  border-radius: 50%;
  background: transparent;
  bottom: 14px;
  pointer-events: none;
  z-index: 1;
  transition: background 0.45s ease;
}
.floor-glow.charging {
  background: radial-gradient(ellipse at center, rgba(34,197,94,0.34) 0%, rgba(34,197,94,0.10) 50%, rgba(0,0,0,0) 76%);
}
.floor-glow.climate {
  background: radial-gradient(ellipse at center, rgba(56,189,248,0.32) 0%, rgba(62,106,225,0.10) 50%, rgba(0,0,0,0) 76%);
}
.floor-glow.heating {
  background: radial-gradient(ellipse at center, rgba(249,115,22,0.32) 0%, rgba(239,68,68,0.10) 50%, rgba(0,0,0,0) 76%);
}
.floor-glow.glb-hidden {
  opacity: 0;
  pointer-events: none;
}
.car-fx-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 3;
  overflow: visible;
}
.car-fx-svg.glb-hidden {
  display: none !important;
}
@keyframes cableEnergyFlow { 0% { stroke-dashoffset: 52; } 100% { stroke-dashoffset: 0; } }
.cable-energy-pulse { stroke-dasharray: 8 18; animation: cableEnergyFlow 0.85s infinite linear; }
@keyframes portLedPulse { 0%, 100% { opacity: 0.45; transform: scale(0.92); } 50% { opacity: 1; transform: scale(1.14); } }
.port-led-glow { transform-box: fill-box; transform-origin: center; animation: portLedPulse 1.5s infinite ease-in-out; }
@keyframes sonicRingExpand { 0% { r: 10; opacity: 0.95; stroke-width: 2.5; } 100% { r: 85; opacity: 0; stroke-width: 0.5; } }
.sonic-ring-1 { animation: sonicRingExpand 1.1s infinite ease-out; }
.sonic-ring-2 { animation: sonicRingExpand 1.1s infinite ease-out 0.35s; }
@keyframes fanSpinTesla { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }
.spin-fan svg { animation: fanSpinTesla 1.4s infinite linear; }

/* ══════════════════════════════════════════════════════════════════
   3. BARRE DES 4 ICÔNES RAPIDES TESLA
   ══════════════════════════════════════════════════════════════════ */
.tesla-quick-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  padding: 6px 18px 16px;
}
.tq-btn {
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-2);
  cursor: pointer;
  transition: color 0.18s ease, transform 0.14s ease, filter 0.18s ease;
}
.tq-btn:active { transform: scale(0.86); }
.tq-btn.active {
  color: var(--text-1);
  filter: drop-shadow(0 0 8px rgba(255,255,255,0.22));
}
.tq-btn.active-blue {
  color: var(--cyan);
  filter: drop-shadow(0 0 10px rgba(56,189,248,0.5));
}
.tq-btn.active-green {
  color: var(--green);
  filter: drop-shadow(0 0 10px rgba(34,197,94,0.5));
}

.charging-banner {
  margin: 0 20px 10px;
  background: var(--bg-card);
  border: 1px solid rgba(34,197,94,0.35);
  border-radius: 14px;
  padding: 12px 15px;
  display: none;
  cursor: pointer;
}
.charging-banner.visible { display: block; }

/* ══════════════════════════════════════════════════════════════════
   4. LISTE DES LIGNES D'ACCUEIL TESLA
   ══════════════════════════════════════════════════════════════════ */
.tesla-menu { padding: 2px 0 8px; }
.menu-row {
  display: flex;
  align-items: center;
  padding: 15px 24px;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.12s ease;
}
.menu-row:active { background: rgba(128,128,128,0.08); transform: scale(0.99); }
.menu-icon {
  width: 26px;
  height: 26px;
  color: var(--text-2);
  margin-right: 18px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.menu-body { flex: 1; min-width: 0; }
.menu-title {
  font-size: 16.5px;
  font-weight: 600;
  color: var(--text-1);
  letter-spacing: -0.015em;
}
.menu-sub {
  font-size: 13px;
  color: var(--text-2);
  margin-top: 3px;
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.red-key-dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  border: 1.5px solid #ef4444;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.red-key-dot::after {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #ef4444;
}
.menu-chevron {
  color: var(--text-3);
  margin-left: 10px;
  font-size: 19px;
  font-weight: 400;
}

.tesla-footer {
  margin-top: 10px;
  padding: 16px 24px 14px;
  color: var(--text-2);
}
.tf-model-wide {
  font-size: 15.5px;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--text-1);
  margin-bottom: 4px;
}
.tf-trim {
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text-2);
  margin-bottom: 12px;
}
.tf-meta {
  font-size: 12.5px;
  line-height: 1.65;
  color: var(--text-2);
}

/* ══════════════════════════════════════════════════════════════════
   SOUS-PAGES PLEIN ÉCRAN
   ══════════════════════════════════════════════════════════════════ */
.full-page {
  position: absolute;
  inset: 0;
  background: var(--bg);
  color: var(--text-1);
  z-index: 30;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  transform: translateY(18px) scale(0.985);
  transition: opacity 0.24s cubic-bezier(0.22,1,0.36,1), transform 0.26s cubic-bezier(0.22,1,0.36,1);
  padding-top: env(safe-area-inset-top, 0px);
}
.full-page.open {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}

.fp-top {
  height: 54px;
  padding: 10px 18px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
  z-index: 10;
}
.fp-back-chevron {
  width: 36px;
  height: 36px;
  background: transparent;
  border: none;
  color: var(--text-1);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.fp-floating-back {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--bg-float);
  border: 1px solid var(--line);
  color: var(--text-1);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(0,0,0,0.35);
}
.fp-title {
  font-size: 16.5px;
  font-weight: 600;
  letter-spacing: -0.015em;
  color: var(--text-1);
}

/* ══════════════════════════════════════════════════════════════════
   PAGE CONTRÔLES EXACTE TESLA (4 POINTS BLANCS FENÊTRES + OVERLAY DÉROULANT + COFFRE)
   ══════════════════════════════════════════════════════════════════ */
.topdown-stage {
  position: relative;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--bg);
}
.topdown-wrap {
  position: relative;
  width: 266px;
  height: 455px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.topdown-img {
  width: 266px;
  height: 455px;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease;
}

.tesla-direct-icon {
  position: absolute;
  transform: translate(-50%, -50%);
  color: #d1d5db;
  cursor: pointer;
  padding: 10px;
  filter: drop-shadow(0 2px 10px rgba(0,0,0,0.85));
  transition: transform 0.18s cubic-bezier(0.22,1,0.36,1), color 0.18s ease;
  z-index: 6;
}
.tesla-direct-icon:active { transform: translate(-50%, -50%) scale(0.85); }
.tesla-direct-icon.active { color: #ffffff; }

.tesla-trunk-btn {
  position: absolute;
  transform: translate(-50%, -50%);
  font-family: var(--font);
  font-size: 15.5px;
  font-weight: 600;
  letter-spacing: -0.015em;
  color: #ffffff;
  text-shadow: 0 2px 10px rgba(0,0,0,0.9);
  cursor: pointer;
  padding: 7px 16px;
  border-radius: 99px;
  background: rgba(18, 20, 26, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.16);
  transition: transform 0.18s cubic-bezier(0.22,1,0.36,1), opacity 0.18s ease;
  z-index: 6;
}
.tesla-trunk-btn:active { transform: translate(-50%, -50%) scale(0.9); }
.tesla-trunk-btn.open-state {
  background: rgba(18, 20, 26, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #ffffff;
  box-shadow: none;
}

.win-white-dot {
  position: absolute;
  transform: translate(-50%, -50%);
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.22);
  border: 1.5px solid rgba(255, 255, 255, 0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,0.65);
  transition: all 0.2s cubic-bezier(0.22,1,0.36,1);
  z-index: 8;
}
.win-white-dot::after {
  content: '';
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 0 8px #ffffff;
  transition: all 0.2s ease;
}
.win-white-dot:active { transform: translate(-50%, -50%) scale(0.88); }
.win-white-dot.win-open {
  border-color: var(--cyan);
  background: rgba(56, 189, 248, 0.28);
  box-shadow: 0 0 14px rgba(56, 189, 248, 0.7);
}
.win-white-dot.win-open::after {
  background: var(--cyan);
  box-shadow: 0 0 8px var(--cyan);
}

.win-dropdown-overlay {
  position: absolute;
  background: rgba(24, 26, 33, 0.96);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 14px;
  width: 118px;
  overflow: hidden;
  box-shadow: 0 14px 34px rgba(0,0,0,0.75);
  z-index: 20;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-8px) scale(0.92);
  transform-origin: top center;
  transition: opacity 0.18s ease, transform 0.2s cubic-bezier(0.22,1,0.36,1);
}
.win-dropdown-overlay.open {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}
.win-dd-title {
  padding: 7px 10px 5px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #9ca3af;
  text-align: center;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}
.win-dd-item {
  padding: 10px 12px;
  font-size: 13px;
  font-weight: 600;
  color: #f4f5f7;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  transition: background 0.14s ease;
}
.win-dd-item:last-child { border-bottom: none; }
.win-dd-item:active { background: var(--blue); color: #fff; }
.win-dd-item.open-opt { color: #38bdf8; }

.tesla-ctrl-bottom-4 {
  padding: 12px 18px 26px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  background: var(--bg);
}
.tcb-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--text-2);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  padding: 8px 4px;
  border-radius: 12px;
  transition: color 0.15s ease, transform 0.14s ease;
}
.tcb-item:active { transform: scale(0.92); }
.tcb-item.on { color: var(--text-1); font-weight: 600; }

/* ══════════════════════════════════════════════════════════════════
   PAGE CLIMATISATION : VRAIE 3D SANS TOIT + SIÈGES AVANT CHAUFFANTS/VENTILÉS + VOLANT
   ══════════════════════════════════════════════════════════════════ */
.clim-cutaway-stage {
  position: relative;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--bg);
}
.clim-car-wrap {
  position: relative;
  width: 268px;
  height: 458px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.clim-overlay-svg {
  position: absolute;
  inset: 0;
  width: 268px;
  height: 458px;
  z-index: 5;
}

.direct-seat-symbol {
  cursor: pointer;
  transition: transform 0.15s ease;
}
.direct-seat-symbol:active { transform: scale(0.88); }
.wave-path {
  stroke: rgba(160, 168, 180, 0.55);
  stroke-width: 2.6;
  stroke-linecap: round;
  fill: none;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.65));
  transition: stroke 0.2s ease, filter 0.2s ease, opacity 0.2s ease;
}
.direct-seat-symbol.mode-heat .wave-path {
  stroke: #ef4444;
  filter: drop-shadow(0 0 7px rgba(239,68,68,0.95));
}
.direct-seat-symbol.mode-vent .wave-path {
  stroke: #38bdf8;
  filter: drop-shadow(0 0 7px rgba(56,189,248,0.95));
}
.direct-seat-symbol.lvl-1 .wave-2 { opacity: 0.22; }

.direct-wheel-symbol { cursor: pointer; }
.direct-wheel-symbol .wheel-sym-stroke {
  stroke: rgba(180, 186, 198, 0.55);
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.75));
  transition: stroke 0.2s ease, filter 0.2s ease;
}
.direct-wheel-symbol.heated .wheel-sym-stroke {
  stroke: #ef4444;
  filter: drop-shadow(0 0 7px rgba(239,68,68,0.95));
}

@keyframes cabinFlowDown {
  0% { stroke-dashoffset: 38; opacity: 0.2; }
  50% { opacity: 0.85; }
  100% { stroke-dashoffset: 0; opacity: 0.2; }
}
.cabin-air-stream {
  stroke-dasharray: 11 10;
  animation: cabinFlowDown 1.25s infinite linear;
  pointer-events: none;
}

.tesla-clim-sheet {
  background: var(--bg-sheet);
  border-top: 1px solid var(--line);
  border-radius: 24px 24px 0 0;
  padding: 10px 20px 22px;
  z-index: 8;
  max-height: 52%;
  overflow-y: auto;
  box-shadow: 0 -10px 30px rgba(0,0,0,0.28);
}
.tcs-handle {
  width: 42px;
  height: 4px;
  border-radius: 99px;
  background: rgba(128,128,128,0.35);
  margin: 0 auto 10px;
}
.tcs-temps-line {
  text-align: center;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-2);
  margin-bottom: 10px;
}
.tcs-main-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 8px 14px;
}
.tcs-side-action {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: var(--text-2);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  min-width: 54px;
}
.tcs-side-action.active {
  color: var(--text-1);
  font-weight: 600;
}
.tcs-temp-stepper {
  display: flex;
  align-items: center;
  gap: 18px;
}
.tcs-chevron-btn {
  background: transparent;
  border: none;
  color: var(--text-2);
  font-size: 24px;
  cursor: pointer;
  padding: 4px 8px;
}
.tcs-big-temp {
  font-size: 46px;
  font-weight: 300;
  letter-spacing: -0.04em;
  color: var(--text-1);
  min-width: 118px;
  text-align: center;
}
.seat-mode-pill-bar {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 10px;
}
.smp-btn {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 9px 10px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-2);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.16s ease;
}
.smp-btn.active-heat {
  background: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.45);
  color: #ef4444;
}
.smp-btn.active-vent {
  background: rgba(56, 189, 248, 0.15);
  border-color: rgba(56, 189, 248, 0.45);
  color: #38bdf8;
}
.tcs-box-group {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--bg-card);
  overflow: hidden;
  margin-top: 8px;
}
.tcs-box-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px 16px;
  border-bottom: 1px solid var(--line);
  color: var(--text-2);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
}
.tcs-box-row:last-child { border-bottom: none; }
.tcs-box-row.active {
  color: var(--text-1);
  background: rgba(62, 106, 225, 0.12);
}

/* ══════════════════════════════════════════════════════════════════
   PAGE SÉCURITÉ ET CONDUCTEURS + PNEUS TPMS 3D
   ══════════════════════════════════════════════════════════════════ */
.tesla-sec-body {
  flex: 1;
  overflow-y: auto;
  padding: 10px 22px 32px;
  scrollbar-width: none;
}
.tesla-sec-body::-webkit-scrollbar { display: none; }
.tesla-flat-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
}
.tfr-left {
  display: flex;
  align-items: center;
  gap: 16px;
  flex: 1;
  min-width: 0;
}
.tfr-icon {
  width: 28px;
  height: 28px;
  color: var(--text-2);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.sentry-ring {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 2px solid var(--text-2);
  display: flex;
  align-items: center;
  justify-content: center;
}
.sentry-ring-core {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #ef4444;
  box-shadow: 0 0 8px #ef4444;
}
.tfr-title {
  font-size: 15.5px;
  font-weight: 600;
  color: var(--text-1);
}
.tfr-sub {
  font-size: 12.5px;
  color: var(--text-2);
  margin-top: 3px;
}
.tfr-sub.link-blue {
  color: #3e6ae1;
  font-weight: 600;
}
.tesla-pill-switch {
  width: 46px;
  height: 26px;
  border-radius: 99px;
  background: rgba(128,128,128,0.32);
  position: relative;
  cursor: pointer;
  transition: background 0.2s ease;
  flex-shrink: 0;
}
.tesla-pill-switch.on { background: #3e6ae1; }
.tesla-pill-knob {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #d1d5db;
  box-shadow: 0 2px 5px rgba(0,0,0,0.4);
  transition: transform 0.2s cubic-bezier(0.22,1,0.36,1), background 0.2s ease;
}
.tesla-pill-switch.on .tesla-pill-knob {
  transform: translateX(20px);
  background: #7dd3fc;
}

.tpms-topdown-arena {
  position: relative;
  width: 100%;
  height: 340px;
  margin-top: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.tpms-car-img {
  width: 180px;
  height: 306px;
  object-fit: cover;
  display: block;
}
.tpms-wheel-Tag {
  position: absolute;
  display: flex;
  flex-direction: column;
  gap: 2px;
  z-index: 6;
}
.tpms-wheel-Tag.left-side {
  left: 4px;
  align-items: flex-end;
  text-align: right;
}
.tpms-wheel-Tag.right-side {
  right: 4px;
  align-items: flex-start;
  text-align: left;
}
.tpms-bar-val {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-1);
  display: flex;
  align-items: center;
  gap: 5px;
}
.tpms-bar-lbl {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-2);
}
.tpms-pointer-line {
  width: 22px;
  height: 1.5px;
  background: var(--text-2);
  opacity: 0.6;
}

/* ── PAGE LOCALISATION TESLA ── */
.tesla-map-stage {
  position: relative;
  flex: 1;
  background: #1b1d22;
  overflow: hidden;
}
.map-top-floating {
  position: absolute;
  top: 12px;
  left: 14px;
  right: 14px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  z-index: 8;
}
.map-addr-pill {
  flex: 1;
  min-width: 0;
  background: var(--bg-float);
  border: 1px solid var(--line);
  backdrop-filter: blur(12px);
  padding: 8px 13px;
  border-radius: 13px;
  font-size: 12.6px;
  font-weight: 600;
  line-height: 1.3;
  color: var(--text-1);
  box-shadow: 0 6px 18px rgba(0,0,0,0.34);
  text-align: center;
  white-space: normal;
  word-break: break-word;
}
.map-right-stack {
  position: absolute;
  top: 62px;
  right: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 8;
}
.tesla-red-arrow {
  position: absolute;
  top: 44%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 36px;
  height: 36px;
  filter: drop-shadow(0 6px 14px rgba(0,0,0,0.65));
  z-index: 5;
}
.map-drawer {
  background: var(--bg-sheet);
  border-top: 1px solid var(--line);
  border-radius: 22px 22px 0 0;
  padding: 10px 20px 24px;
  z-index: 9;
}
.map-tabs-row {
  display: grid;
  grid-template-columns: 1fr 1px 1fr;
  align-items: center;
  padding: 6px 0 14px;
}
.map-tab-btn {
  text-align: center;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--text-3);
  cursor: pointer;
}
.map-tab-btn.active { color: var(--text-1); }
.map-tab-div { height: 18px; background: var(--line); }
.map-dest-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
}
.map-dest-item:last-child { border-bottom: none; }
.map-km-badge {
  width: 58px;
  height: 54px;
  border-radius: 10px;
  background: var(--bg-card-2);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-2);
  flex-shrink: 0;
}

/* ── CARTES ET FORMULAIRES ── */
.tesla-list-card {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 14px;
}
.tesla-card-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 16px;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
}
.tesla-card-row:last-child { border-bottom: none; }
.section-lbl {
  font-size: 11.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-2);
  margin: 14px 0 8px;
}
.tesla-input {
  width: 100%;
  background: var(--bg-card-2);
  border: 1px solid var(--line);
  color: var(--text-1);
  padding: 11px 14px;
  border-radius: 11px;
  font-size: 13.5px;
  font-family: var(--font);
  outline: none;
}
.tesla-action-btn {
  width: 100%;
  padding: 12px 16px;
  border-radius: 11px;
  background: var(--blue);
  color: #fff;
  border: none;
  font-size: 13.5px;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.ctrl-bar-btn {
  background: var(--bg-card-2);
  border: 1px solid var(--line);
  color: var(--text-1);
  padding: 11px 10px;
  border-radius: 11px;
  font-size: 12.5px;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
  text-align: center;
  transition: all 0.16s ease;
}
.ctrl-bar-btn.active {
  background: var(--blue);
  border-color: var(--blue);
  color: #fff;
}

.color-swatch-grid {
  padding: 12px 20px 28px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.color-card {
  background: var(--bg-card);
  border: 1.5px solid var(--line);
  border-radius: 14px;
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
}
.color-card.active {
  border-color: var(--blue);
  background: rgba(62, 106, 225, 0.14);
}
.color-circle {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1.5px solid rgba(255,255,255,0.35);
  flex-shrink: 0;
}

/* ══════════════════════════════════════════════════════════════════
   CAMÉRAS EN DIRECT :
   - 4 caméras dans les 4 coins de l'espace vidéo
   - Bouton Plein écran -> 4 caméras dans chaque coin (sans Dashcam) + flèche `<` coin sup gauche + bouton "Dashcam" / "4 vues" coin sup droit
   - Bouton STOP (petit carré ■) juste en dessous du bouton des 4 carrés à droite de la voiture !
   ══════════════════════════════════════════════════════════════════ */
.cam-video-stage {
  position: relative;
  width: 100%;
  height: 264px;
  background: #050608;
  border-bottom: 1px solid var(--line);
  overflow: hidden;
  flex-shrink: 0;
}
.phone-frame.landscape-cam .cam-video-stage {
  height: 100%;
  border-bottom: none;
}
.phone-frame.landscape-cam .cam-live-scroll,
.phone-frame.landscape-cam .cam-selector-stage,
.phone-frame.landscape-cam #camNormalHeader {
  display: none;
}
.cam-live-scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  display: flex;
  flex-direction: column;
}

.cam-fs-hud {
  position: absolute;
  top: 14px;
  left: 16px;
  right: 16px;
  display: none;
  justify-content: flex-end;
  align-items: center;
  z-index: 25;
  pointer-events: none;
}
.phone-frame.landscape-cam .full-page {
  padding-top: 0;
}
.phone-frame.landscape-cam .cam-fs-hud {
  display: flex;
}
.cam-fs-back-arrow {
  pointer-events: auto;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: rgba(15, 17, 23, 0.85);
  backdrop-filter: blur(10px);
  border: 1.5px solid rgba(255,255,255,0.22);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(0,0,0,0.65);
  transition: transform 0.15s ease, background 0.15s ease;
}
.cam-fs-back-arrow:active { transform: scale(0.9); }

.cam-fs-top-right-btn {
  pointer-events: auto;
  background: rgba(15, 17, 23, 0.88);
  backdrop-filter: blur(10px);
  border: 1.5px solid rgba(255,255,255,0.24);
  color: #ffffff;
  padding: 8px 14px;
  border-radius: 12px;
  font-size: 12.5px;
  font-weight: 700;
  font-family: var(--font);
  display: flex;
  align-items: center;
  gap: 7px;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(0,0,0,0.65);
  transition: all 0.16s ease;
}
.cam-fs-top-right-btn:active { transform: scale(0.92); }
.cam-fs-top-right-btn.active-dash {
  background: var(--blue);
  border-color: #93c5fd;
}

.cam-live-stream-img,
.cam-live-h264-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 2;
  display: none;
  pointer-events: none;
}

.cam-feed-single {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at 50% 58%, #1c2434 0%, #090c12 78%);
  color: #e2e8f0;
  cursor: pointer;
  z-index: 3;
}
.cam-feed-single.has-live-video {
  background: transparent;
}
.cam-single-hint {
  margin-top: 10px;
  padding: 5px 12px;
  border-radius: 99px;
  background: rgba(15,17,23,0.72);
  border: 1px solid rgba(255,255,255,0.16);
  font-size: 11.5px;
  color: #cbd5e1;
  display: none;
}
.phone-frame.landscape-cam .cam-single-hint {
  display: inline-block;
}

.cam-grid-4 {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: none;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 2px;
  background: #000000;
  z-index: 3;
}
.cam-grid-4.has-live-video {
  background: transparent;
}
.cam-corner-box {
  position: relative;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 50% 62%, #192232 0%, #090b10 85%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  overflow: hidden;
  transition: filter 0.15s ease;
}
.cam-grid-4.has-live-video .cam-corner-box {
  background: transparent;
}
.cam-grid-4.has-live-video .cam-corner-placeholder {
  display: none;
}
.cam-corner-box:hover { filter: brightness(1.15); }
.cam-corner-box:active { filter: brightness(1.3); }

.cam-corner-tag {
  position: absolute;
  background: rgba(10, 12, 16, 0.78);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255,255,255,0.14);
  padding: 3px 9px;
  border-radius: 7px;
  font-size: 10px;
  font-weight: 700;
  color: #e2e8f0;
  display: flex;
  align-items: center;
  gap: 5px;
  z-index: 5;
}
.cam-corner-tag::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 6px #22c55e;
}
.cam-corner-box.tl .cam-corner-tag { top: 8px; left: 8px; }
.cam-corner-box.tr .cam-corner-tag { top: 8px; right: 8px; }
.cam-corner-box.bl .cam-corner-tag { bottom: 8px; left: 8px; }
.cam-corner-box.br .cam-corner-tag { bottom: 8px; right: 8px; }

.phone-frame.landscape-cam .cam-corner-box.tl .cam-corner-tag { top: 60px; left: 16px; }
.phone-frame.landscape-cam .cam-corner-box.tr .cam-corner-tag { top: 60px; right: 16px; }
.phone-frame.landscape-cam .cam-corner-box.bl .cam-corner-tag { bottom: 14px; left: 16px; }
.phone-frame.landscape-cam .cam-corner-box.br .cam-corner-tag { bottom: 14px; right: 16px; }

.cam-normal-fs-btn {
  position: absolute;
  top: 10px;
  right: 12px;
  z-index: 15;
  background: rgba(15, 17, 23, 0.82);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.18);
  color: #fff;
  padding: 6px 11px;
  border-radius: 9px;
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 5px;
}
.phone-frame.landscape-cam .cam-normal-fs-btn { display: none; }

.cam-selector-stage {
  position: relative;
  flex: 1 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  padding: 8px 40px 14px 0;
}
.cam-dot {
  position: absolute;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(24, 27, 34, 0.92);
  border: 2px solid rgba(255, 255, 255, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 6;
}
.cam-dot::after {
  content: '';
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #cbd5e1;
}
.cam-dot.active {
  border-color: var(--blue);
  background: var(--blue);
  box-shadow: 0 0 14px rgba(62,106,225,0.8);
}
.cam-dot.active::after { background: #fff; }
.cam-dot-lbl {
  position: absolute;
  bottom: -16px;
  font-size: 9px;
  font-weight: 700;
  color: var(--text-2);
  white-space: nowrap;
}

/* Colonne de boutons à droite de la voiture : Bouton 4 carrés en haut + Bouton STOP (petit carré ■) juste en dessous */
.cam-right-stack {
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 12px;
  z-index: 8;
}
.cam-side-btn {
  width: 50px;
  height: 50px;
  border-radius: 14px;
  background: var(--bg-card);
  border: 1.5px solid var(--line);
  color: var(--text-1);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(0,0,0,0.35);
  transition: all 0.16s ease;
}
.cam-side-btn:active { transform: scale(0.92); }
.cam-side-btn.active { background: var(--blue); border-color: var(--blue); color: #fff; }
.cam-side-btn.stop-btn { color: #f87171; border-color: rgba(239, 68, 68, 0.28); }
.cam-side-btn.stop-btn.stopped { background: rgba(239, 68, 68, 0.22); border-color: #ef4444; color: #ef4444; }

/* Toast */
.confirm-toast {
  position: absolute;
  bottom: 22px;
  left: 20px;
  right: 20px;
  background: #20232b;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 16px;
  padding: 13px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 14px 36px rgba(0,0,0,0.75);
  transform: translateY(160%);
  transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1);
  z-index: 90;
  font-size: 13px;
  font-weight: 500;
}
.confirm-toast.show { transform: translateY(0); }
.toast-badge { font-size: 11px; font-weight: 600; padding: 3px 8px; border-radius: 6px; background: rgba(62,106,225,0.22); color: #7ea0ff; }

/* ══════════════════════════════════════════════════════════════════
   STATUT SURVEILLANCE SENTINELLE SUR L'ACCUEIL (JUSTE AU-DESSUS DE CONTRÔLES)
   ══════════════════════════════════════════════════════════════════ */
.home-sentry-status-row {
  margin: 0 24px 6px;
  padding: 11px 15px;
  border-radius: 14px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  transition: background 0.18s ease, border-color 0.18s ease, transform 0.12s ease;
}
.home-sentry-status-row:active {
  transform: scale(0.99);
}
.home-sentry-status-row.armed {
  border-color: rgba(239, 68, 68, 0.32);
  background: linear-gradient(90deg, rgba(239, 68, 68, 0.09) 0%, var(--bg-card) 65%);
}
.hss-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.hss-icon {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-2);
  flex-shrink: 0;
  transition: color 0.2s ease;
}
.home-sentry-status-row.armed .hss-icon {
  color: #f87171;
}
.hss-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-1);
  letter-spacing: -0.015em;
}
.hss-sub {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-2);
  letter-spacing: 0.04em;
  margin-top: 2px;
}
.home-sentry-status-row.armed .hss-sub {
  color: #f87171;
}

/* ══════════════════════════════════════════════════════════════════
   BARRE DE TITRE CENTRALE LIVE | SENTINELLE & SOUS-ONGLETS TESLA
   ══════════════════════════════════════════════════════════════════ */
.tesla-top-seg {
  display: inline-flex;
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 3px;
  gap: 2px;
}
.tts-btn {
  padding: 6px 16px;
  border-radius: 8px;
  font-family: var(--font);
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-2);
  background: transparent;
  border: none;
  cursor: pointer;
  letter-spacing: -0.015em;
  transition: all 0.18s ease;
  display: flex;
  align-items: center;
  gap: 6px;
}
.tts-btn.active {
  background: var(--bg-card-2);
  color: var(--text-1);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.38);
}
.tts-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--text-3);
}
.tts-dot.armed {
  background: #ef4444;
  box-shadow: 0 0 7px #ef4444;
}

.tesla-subtabs-bar {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin: 6px 20px 10px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 3px;
  flex-shrink: 0;
}
.tsb-tab {
  padding: 9px 12px;
  text-align: center;
  font-family: var(--font);
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-2);
  border-radius: 9px;
  cursor: pointer;
  letter-spacing: -0.015em;
  transition: all 0.18s ease;
}
.tsb-tab.active {
  background: var(--bg-card-2);
  color: var(--text-1);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
}

.sentry-pane-scroll {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 4px 20px 36px;
  scrollbar-width: none;
}
.sentry-pane-scroll::-webkit-scrollbar { display: none; }

/* Cartes et contrôles Sentinelle 100 % typographie et design Tesla */
.ts-group-title {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-2);
  letter-spacing: 0.02em;
  margin: 18px 2px 8px;
}
.ts-group-title:first-child {
  margin-top: 6px;
}

.ts-card {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
}
.ts-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  gap: 12px;
}
.ts-row:last-child {
  border-bottom: none;
}
.ts-row-block {
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
}
.ts-row-block:last-child {
  border-bottom: none;
}
.ts-label {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-1);
  letter-spacing: -0.015em;
}
.ts-desc {
  font-size: 12.5px;
  font-weight: 400;
  color: var(--text-2);
  margin-top: 3px;
  line-height: 1.38;
}
.ts-val-badge {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-1);
}

/* Sélecteur segmenté pur style Tesla */
.ts-seg-row {
  display: grid;
  background: #131418;
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 3px;
  gap: 3px;
  margin-top: 10px;
}
.ts-seg-btn {
  padding: 8px 6px;
  text-align: center;
  font-family: var(--font);
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-2);
  background: transparent;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  letter-spacing: -0.01em;
  transition: all 0.16s ease;
}
.ts-seg-btn.active {
  background: var(--bg-card-2);
  color: var(--text-1);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.45);
}

/* 3 Cartes Stockage Tesla (Interne / Carte SD / Clé USB) */
.ts-storage-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 10px;
}
.ts-storage-tile {
  background: #14151a;
  border: 1.5px solid var(--line);
  border-radius: 13px;
  padding: 12px 10px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  transition: all 0.18s ease;
}
.ts-storage-tile.active {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--text-1);
}
.ts-storage-tile.unavailable {
  opacity: 0.48;
}
.tst-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.tst-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-1);
}
.tst-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--text-3);
}
.tst-dot.ok {
  background: var(--green);
}
.tst-space {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-2);
  line-height: 1.3;
}

.ts-folder-pill {
  margin-top: 10px;
  padding: 9px 12px;
  border-radius: 10px;
  background: #131418;
  border: 1px solid var(--line);
  font-size: 11.5px;
  color: var(--text-2);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.ts-folder-code {
  color: var(--text-1);
  font-weight: 600;
  font-family: var(--font);
}

/* Grille 2x2 de pastilles Tesla (Cibles IA & 4 Caméras) */
.ts-chip-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 10px;
}
.ts-chip-btn {
  padding: 11px 12px;
  border-radius: 11px;
  background: #14151a;
  border: 1.5px solid var(--line);
  color: var(--text-2);
  font-family: var(--font);
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  transition: all 0.16s ease;
}
.ts-chip-btn.active {
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--text-1);
  color: var(--text-1);
}
.ts-chip-ind {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--text-3);
}
.ts-chip-btn.active .ts-chip-ind {
  background: var(--blue);
  box-shadow: 0 0 8px var(--blue);
}

/* Slider Tesla épuré */
.ts-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 5px;
  border-radius: 99px;
  background: #2a2d36;
  outline: none;
  margin-top: 10px;
}
.ts-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
  cursor: pointer;
}

/* Liste des Clips Sentinelle (Onglet Clips — Cartes Tesla 2 étages, zéro superposition) */
.ts-clip-day-hdr {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-2);
  margin: 14px 2px 7px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.ts-clip-card {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 15px;
  overflow: hidden;
  margin-bottom: 10px;
}
.ts-clip-top {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 13px 10px;
  cursor: pointer;
}
.ts-clip-top:active { background: rgba(255, 255, 255, 0.04); }
.ts-clip-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.ts-clip-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.ts-clip-title {
  font-size: 13.8px;
  font-weight: 700;
  color: var(--text-1);
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ts-clip-sev-tag {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 99px;
  flex-shrink: 0;
}
.ts-clip-sev-tag.sev-red {
  background: rgba(239, 68, 68, 0.16);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.38);
}
.ts-clip-sev-tag.sev-amber {
  background: rgba(245, 158, 11, 0.16);
  color: #fcd34d;
  border: 1px solid rgba(245, 158, 11, 0.36);
}
.ts-clip-meta {
  font-size: 11.6px;
  color: var(--text-2);
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.ts-clip-mini-bar {
  height: 3.5px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.08);
  position: relative;
  overflow: hidden;
  margin-top: 2px;
}
.ts-clip-mini-seg {
  position: absolute;
  top: 0;
  bottom: 0;
  border-radius: 99px;
}
.ts-clip-mini-seg.amber { background: #f59e0b; }
.ts-clip-mini-seg.red { background: #ef4444; }
.ts-clip-actions {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.02);
}
.ts-clip-act-btn {
  border: none;
  background: transparent;
  color: var(--text-2);
  font-family: var(--font);
  font-size: 10.8px;
  font-weight: 600;
  padding: 9px 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  cursor: pointer;
  border-right: 1px solid rgba(255, 255, 255, 0.05);
  transition: background 0.14s ease, color 0.14s ease;
}
.ts-clip-act-btn:last-child { border-right: none; }
.ts-clip-act-btn:active { background: rgba(255, 255, 255, 0.06); color: var(--text-1); }
.ts-clip-act-btn.danger { color: #f87171; }
.ts-clip-badge {
  font-size: 10px;
  font-weight: 600;
  padding: 1.5px 6px;
  border-radius: 6px;
  background: var(--bg-card-2);
  color: var(--text-2);
  flex-shrink: 0;
}

/* Lecteur Vidéo Streaming Sentinelle Intégré (Style Tesla épuré + Timeline Orange / Rouge) */
.sentry-video-modal {
  position: absolute;
  inset: 0;
  background: #0b0c0f;
  z-index: 80;
  display: none;
  flex-direction: column;
  padding-top: env(safe-area-inset-top, 10px);
}
.sentry-video-modal.open {
  display: flex;
}
.svm-hdr-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 0;
  flex: 1;
}
.svm-hdr-sub {
  font-size: 11px;
  color: var(--text-2);
  margin-top: 1px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}
.svm-player-box {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  background: #0b0c0f;
  position: relative;
  padding: 10px 14px 8px;
  gap: 10px;
  overflow-y: auto;
}
.svm-zoom-stage {
  position: relative;
  width: 100%;
  max-width: 640px;
  aspect-ratio: 16 / 10;
  border-radius: 16px;
  overflow: hidden;
  background: #000;
  border: 1px solid rgba(255, 255, 255, 0.1);
  flex-shrink: 0;
}
.svm-video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  background: #000;
  outline: none;
  transition: transform 0.22s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}
.svm-quad-hitgrid {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  z-index: 3;
}
.svm-quad-cell {
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.svm-zoom-badge,
.svm-prox-badge {
  position: absolute;
  top: 10px;
  z-index: 5;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(11, 12, 15, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #f4f5f7;
  font-size: 10.5px;
  font-weight: 700;
  backdrop-filter: blur(8px);
}
.svm-zoom-badge { right: 10px; cursor: pointer; }
.svm-fs-btn {
  position: absolute;
  right: 10px;
  bottom: 10px;
  z-index: 6;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(11, 12, 15, 0.78);
  color: #f4f5f7;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  backdrop-filter: blur(8px);
}
.svm-fs-topbar {
  display: none;
}
/* Mode Plein Écran Paysage immersif bord-à-bord (recadrage proportionnel sans déformation) */
.sentry-video-modal.fullscreen-land {
  padding-top: 0;
  background: #000;
}
.sentry-video-modal.fullscreen-land .fp-top,
.sentry-video-modal.fullscreen-land .svm-footer-tesla,
.sentry-video-modal.fullscreen-land .svm-fs-btn {
  display: none !important;
}
.sentry-video-modal.fullscreen-land .svm-fs-topbar {
  display: flex;
  position: fixed;
  top: 12px;
  left: 16px;
  right: 16px;
  z-index: 12;
  align-items: center;
  justify-content: space-between;
  transition: opacity 0.22s ease;
}
.sentry-video-modal.fullscreen-land .svm-fs-title {
  background: rgba(11, 12, 15, 0.76);
  border: 1px solid rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(10px);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 12px;
  font-weight: 600;
  color: #f4f5f7;
}
.sentry-video-modal.fullscreen-land .svm-fs-actions {
  display: flex;
  gap: 8px;
}
.sentry-video-modal.fullscreen-land .svm-fs-pill {
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(11, 12, 15, 0.8);
  backdrop-filter: blur(10px);
  color: #f4f5f7;
  font-family: var(--font);
  font-size: 11.5px;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 999px;
  cursor: pointer;
}
.sentry-video-modal.fullscreen-land .svm-player-box {
  padding: 0;
  background: #000;
  overflow: hidden;
  position: relative;
  height: 100%;
}
.sentry-video-modal.fullscreen-land .svm-zoom-stage {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  max-width: none;
  aspect-ratio: auto;
  border-radius: 0;
  border: none;
}
.sentry-video-modal.fullscreen-land .svm-video {
  object-fit: cover;
}
.sentry-video-modal.fullscreen-land.fit-contain .svm-video {
  object-fit: contain;
}
.sentry-video-modal.fullscreen-land .svm-cam-pills {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: 116px;
  max-width: 440px;
  margin: 0 auto;
  z-index: 12;
  transition: opacity 0.22s ease;
}
.sentry-video-modal.fullscreen-land .svm-timeline-card {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: 12px;
  max-width: 680px;
  margin: 0 auto;
  z-index: 12;
  background: rgba(14, 15, 19, 0.82);
  backdrop-filter: blur(12px);
  padding: 10px 14px 8px;
  transition: opacity 0.22s ease;
}
.sentry-video-modal.fullscreen-land .svm-transport-bar {
  margin-top: 8px;
  padding-top: 8px;
}
.sentry-video-modal.fullscreen-land .svm-tl-legend {
  display: none;
}
.sentry-video-modal.fullscreen-land.hud-hidden .svm-fs-topbar,
.sentry-video-modal.fullscreen-land.hud-hidden .svm-cam-pills,
.sentry-video-modal.fullscreen-land.hud-hidden .svm-timeline-card {
  opacity: 0;
  pointer-events: none;
}
.cam-side-btn.audio-btn.audio-on {
  background: rgba(34, 197, 94, 0.2);
  border-color: rgba(34, 197, 94, 0.55);
  color: #86efac;
}
.cam-mic-bar {
  flex-shrink: 0;
  margin: 10px 14px 2px;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.09);
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.cam-mic-head {
  display: flex;
  align-items: center;
  gap: 10px;
}
.cam-mic-title {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-2);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}
.cam-mic-meter {
  flex: 1;
  height: 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  overflow: hidden;
}
.cam-mic-meter-fill {
  width: 0%;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #22c55e, #86efac);
  transition: width 160ms ease-out;
}
.cam-mic-lvl {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-3);
  min-width: 68px;
  text-align: right;
  white-space: nowrap;
}
.cam-mic-lvl.has-signal {
  color: #86efac;
}
.cam-mic-pills {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 1px;
}
.cam-mic-pills::-webkit-scrollbar {
  display: none;
}
.cam-mic-pill {
  flex: 0 0 auto;
  padding: 6px 11px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-2);
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
}
.cam-mic-pill.active {
  background: rgba(34, 197, 94, 0.22);
  border-color: rgba(34, 197, 94, 0.65);
  color: #bbf7d0;
}
/* Page Sauvegarde & Restauration (style Tesla) */
.bk-hero-card {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 6px;
}
.bk-hero-icon {
  width: 44px;
  height: 44px;
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-1);
  flex-shrink: 0;
}
.bk-hero-title { font-size: 15.5px; font-weight: 700; color: var(--text-1); }
.bk-hero-sub { font-size: 12px; color: var(--text-2); margin-top: 2px; }
.bk-inc-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--line);
}
.bk-inc-cell {
  background: var(--bg-card);
  padding: 12px 13px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.bk-inc-top { display: flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 600; color: var(--text-1); }
.bk-check { color: var(--green); font-weight: 800; }
.bk-inc-sub { font-size: 11px; color: var(--text-2); line-height: 1.32; }
.bk-actions-col {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 16px;
}
.bk-btn-primary {
  width: 100%;
  border: none;
  border-radius: 13px;
  padding: 14px 16px;
  background: #f4f5f7;
  color: #111215;
  font-family: var(--font);
  font-size: 14.5px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  cursor: pointer;
}
.bk-btn-secondary {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 13px;
  padding: 13px 16px;
  background: var(--bg-card-2);
  color: var(--text-1);
  font-family: var(--font);
  font-size: 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  cursor: pointer;
}
.bk-status-msg {
  margin-top: 12px;
  padding: 11px 13px;
  border-radius: 12px;
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.35);
  color: #86efac;
  font-size: 12.5px;
  font-weight: 600;
}
.bk-privacy-note {
  margin-top: 14px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.25);
  border-radius: 13px;
  padding: 11px 13px;
  font-size: 11.5px;
  color: var(--text-2);
  line-height: 1.4;
}

.svm-cam-pills {
  width: 100%;
  max-width: 640px;
  display: flex;
  gap: 6px;
}
.svm-cam-pill {
  flex: 1;
  padding: 7px 4px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--bg-card);
  color: var(--text-2);
  font-family: var(--font);
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
  transition: all 0.15s ease;
}
.svm-cam-pill.active {
  background: #f4f5f7;
  color: #111215;
  border-color: #f4f5f7;
}

.svm-timeline-card {
  width: 100%;
  max-width: 640px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px 14px 12px;
  box-sizing: border-box;
}
.svm-tl-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.svm-tl-time {
  font-size: 12.5px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--text-1);
}
.svm-tl-dur {
  color: var(--text-2);
  font-weight: 500;
}
.svm-jump-peak-btn {
  font-family: var(--font);
  font-size: 10.8px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 99px;
  background: rgba(239, 68, 68, 0.14);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.38);
  cursor: pointer;
}
.svm-tl-track-wrap {
  position: relative;
  height: 28px;
  display: flex;
  align-items: center;
}
.svm-tl-track {
  position: relative;
  width: 100%;
  height: 7px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.1);
  overflow: hidden;
}
.svm-tl-progress {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 0%;
  background: rgba(255, 255, 255, 0.36);
  border-radius: 99px;
  z-index: 1;
}
.svm-tl-zones {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}
.svm-tl-zone {
  position: absolute;
  top: 0;
  bottom: 0;
  border-radius: 99px;
}
.svm-tl-zone.amber {
  background: linear-gradient(90deg, rgba(245, 158, 11, 0.8), #f59e0b);
  box-shadow: 0 0 8px rgba(245, 158, 11, 0.5);
}
.svm-tl-zone.red {
  background: linear-gradient(90deg, #ef4444, #f87171);
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.72);
}
.svm-tl-thumb {
  position: absolute;
  top: 50%;
  left: 0%;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #ffffff;
  border: 2px solid #111215;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.65);
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 3;
}
.svm-seek-hidden {
  position: absolute;
  inset: 0;
  width: 100%;
  opacity: 0;
  cursor: pointer;
  z-index: 4;
}
.svm-tl-legend {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 8px;
  font-size: 10.5px;
  color: var(--text-2);
}
.svm-leg-group {
  display: flex;
  align-items: center;
  gap: 12px;
}
.svm-leg-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.svm-leg-dot {
  width: 8px;
  height: 8px;
  border-radius: 99px;
  display: inline-block;
}
.svm-leg-dot.amber { background: #f59e0b; }
.svm-leg-dot.red { background: #ef4444; }
.svm-meta-right {
  color: var(--text-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.svm-transport-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}
.svm-speed-btn {
  min-width: 44px;
  height: 32px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-1);
  font-family: var(--font);
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
}
.svm-transport-center {
  display: flex;
  align-items: center;
  gap: 14px;
}
.svm-skip-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-1);
  font-family: var(--font);
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.svm-play-tesla-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: none;
  background: #f4f5f7;
  color: #111215;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.45);
  cursor: pointer;
  transition: transform 0.14s ease;
}
.svm-play-tesla-btn:active { transform: scale(0.94); }

.svm-footer-tesla {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  padding: 10px 14px calc(14px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--line);
  background: #0b0c0f;
}
.svm-foot-btn {
  padding: 10px 8px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--bg-card);
  color: var(--text-1);
  font-family: var(--font);
  font-size: 12px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
}
.svm-foot-btn.primary {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.2);
}

/* ══════════════════════════════════════════════════════════════════
   SANTÉ & DIAGNOSTICS : JAUGES CPU/GPU, RAM, STOCKAGES + CHANGELOGS
   ══════════════════════════════════════════════════════════════════ */
.diag-banner-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 12px;
}
.diag-live-pill {
  font-size: 10.5px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(34, 197, 94, 0.15);
  color: #86efac;
  border: 1px solid rgba(34, 197, 94, 0.3);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
}
.diag-live-pill i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  display: inline-block;
}
.diag-perf-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  padding: 14px;
  border-bottom: 1px solid var(--line);
}
.diag-gauge-tile {
  background: var(--bg-card-2);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 14px;
  padding: 12px 10px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}
.diag-gauge-wrap {
  position: relative;
  width: 86px;
  height: 86px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.diag-gauge-svg {
  width: 86px;
  height: 86px;
  transform: rotate(-90deg);
}
.diag-gauge-bg {
  fill: none;
  stroke: rgba(255, 255, 255, 0.08);
  stroke-width: 7.5;
}
.diag-gauge-fg {
  fill: none;
  stroke: var(--cyan);
  stroke-width: 7.5;
  stroke-linecap: round;
  transition: stroke-dashoffset 0.45s cubic-bezier(0.22, 1, 0.36, 1), stroke 0.3s ease;
}
.diag-gauge-center {
  position: absolute;
  text-align: center;
}
.diag-gauge-pct {
  font-size: 19px;
  font-weight: 700;
  color: var(--text-1);
  line-height: 1.05;
}
.diag-gauge-unit {
  font-size: 10px;
  font-weight: 600;
  color: var(--text-2);
  letter-spacing: 0.04em;
  margin-top: 2px;
}
.diag-gauge-sub {
  font-size: 11px;
  color: var(--text-2);
  text-align: center;
}
.diag-sparkline {
  width: 100%;
  height: 20px;
}
.diag-sparkline polyline {
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.diag-ram-block {
  padding: 13px 14px 14px;
}
.diag-metric-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}
.diag-pct-badge {
  font-size: 11.5px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(56, 189, 248, 0.14);
  color: #bae6fd;
  flex-shrink: 0;
}
.diag-pct-badge.off {
  background: rgba(148, 163, 184, 0.14);
  color: #94a3b8;
}
.diag-bar-track {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  overflow: hidden;
  display: flex;
}
.diag-bar-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 0.45s cubic-bezier(0.22, 1, 0.36, 1), background 0.3s ease;
}
.diag-bar-sentry {
  height: 100%;
  background: var(--cyan);
  transition: width 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}
.diag-bar-other {
  height: 100%;
  background: rgba(148, 163, 184, 0.55);
  transition: width 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}
.diag-metric-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 8px;
  font-size: 11.5px;
  color: var(--text-2);
}
.diag-metric-foot b {
  color: var(--text-1);
  font-weight: 600;
}
.diag-storage-item {
  padding: 13px 14px;
  border-bottom: 1px solid var(--line);
}
.diag-storage-item:last-child {
  border-bottom: none;
}
.diag-storage-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}
.diag-storage-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.diag-storage-ico {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: var(--bg-card-2);
  border: 1px solid var(--line);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--cyan);
  flex-shrink: 0;
}
.diag-storage-ico.off {
  color: var(--text-3);
}
.diag-storage-legend {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 6px;
  font-size: 10.5px;
  color: var(--text-3);
}
.diag-storage-legend span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.diag-dot-mini {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  display: inline-block;
}
.upd-changelog-box {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}
.upd-cl-title {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-2);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.upd-cl-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 0;
  margin: 0;
}
.upd-cl-list li {
  position: relative;
  padding-left: 14px;
  font-size: 12.5px;
  line-height: 1.42;
  color: var(--text-1);
}
.upd-cl-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 7px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--cyan);
}
.svm-footer {
  padding: 16px 20px 26px;
  background: var(--bg-sheet);
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

/* ══════════════════════════════════════════════════════════════════
   BOUTON QUALITÉ VIDÉO TEMPS RÉEL (SD -> HD -> FHD) AU-DESSUS DES 4 CARRÉS
   ══════════════════════════════════════════════════════════════════ */
.cam-side-btn.quality-btn {
  font-family: var(--font);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: #e2e8f0;
  border-color: rgba(255, 255, 255, 0.16);
}
.cam-side-btn.quality-btn.q-hd {
  background: rgba(62, 106, 225, 0.22);
  border-color: #3e6ae1;
  color: #93c5fd;
}
.cam-side-btn.quality-btn.q-fhd {
  background: rgba(34, 197, 94, 0.18);
  border-color: #22c55e;
  color: #4ade80;
}

/* ══════════════════════════════════════════════════════════════════
   SENTINELLE : DISSUASION 2 CHOIX (VEKTRA ALERT GIF / IMAGE PERSO) & HORAIRE NOCTURNE
   ══════════════════════════════════════════════════════════════════ */
.ts-sub-expand {
  background: rgba(255, 255, 255, 0.02);
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}
.ts-deterrent-grid {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 4px;
  scrollbar-width: none;
}
.ts-deterrent-grid::-webkit-scrollbar { display: none; }
.ts-deterrent-card {
  flex: 0 0 78%;
  min-width: 192px;
  max-width: 268px;
  scroll-snap-align: start;
  background: #13151b;
  border: 1.5px solid var(--line);
  border-radius: 13px;
  padding: 8px;
  cursor: pointer;
  transition: border-color 0.18s ease, background 0.18s ease;
}
.ts-deterrent-card.active {
  border-color: var(--text-1);
  background: rgba(255, 255, 255, 0.05);
}
.tdc-preview {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 9px;
  overflow: hidden;
  background: #07090d;
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
}
.tdc-preview img,
.tdc-preview video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.tdc-badge {
  position: absolute;
  bottom: 5px;
  right: 5px;
  padding: 2px 6px;
  border-radius: 5px;
  background: rgba(239, 68, 68, 0.88);
  color: #ffffff;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.tdc-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  color: var(--text-2);
  font-size: 11px;
  font-weight: 600;
}
.tdc-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-1);
  margin-top: 7px;
}
.tdc-sub {
  font-size: 11px;
  color: var(--text-2);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ts-time-range-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.ts-time-field {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background: #13151b;
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 8px 12px;
}
.ts-time-lbl {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-2);
}
.ts-time-input {
  background: transparent;
  border: none;
  color: var(--text-1);
  font-family: var(--font);
  font-size: 15px;
  font-weight: 700;
  outline: none;
  color-scheme: dark;
}

/* ══════════════════════════════════════════════════════════════════
   VRAIE CARTE MAPLIBRE OPENFREEMAP DARK + SUGGESTIONS PHOTON + ÉDITEUR DOMICILE/TRAVAIL
   ══════════════════════════════════════════════════════════════════ */
.vektra-real-map {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background: #14171f;
  z-index: 1;
}
.maplibregl-ctrl-logo,
.maplibregl-ctrl-attrib {
  opacity: 0.45 !important;
  font-size: 9px !important;
}
.map-3d-btn.active {
  background: var(--blue);
  border-color: var(--blue);
  color: #ffffff;
}
.map-search-wrap {
  position: relative;
}
.map-suggest-dropdown {
  position: absolute;
  left: 0;
  right: 0;
  bottom: calc(100% + 4px);
  max-height: 220px;
  overflow-y: auto;
  background: #191b22;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.72);
  z-index: 40;
}
.map-suggest-item {
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
  transition: background 0.12s ease;
}
.map-suggest-item:last-child { border-bottom: none; }
.map-suggest-item:active { background: rgba(255, 255, 255, 0.07); }
.msi-title {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-1);
}
.msi-sub {
  font-size: 11.5px;
  color: var(--text-2);
  margin-top: 2px;
}

.map-dest-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.map-edit-btn {
  width: 44px;
  height: 54px;
  border-radius: 10px;
  background: var(--bg-card-2);
  border: 1px solid var(--line);
  color: var(--text-1);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.15s ease, transform 0.12s ease;
}
.map-edit-btn:active {
  transform: scale(0.93);
  background: rgba(62, 106, 225, 0.25);
}

.hw-edit-modal {
  position: absolute;
  inset: 0;
  background: var(--bg);
  z-index: 75;
  display: none;
  flex-direction: column;
  padding-top: env(safe-area-inset-top, 10px);
}
.hw-edit-modal.open {
  display: flex;
}
.hw-suggest-list {
  margin-top: 12px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
}
.hw-suggest-list:empty {
  display: none;
}

.vk-car-marker {
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.75));
}
.vk-user-marker {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #38bdf8;
  border: 3px solid #ffffff;
  box-shadow: 0 0 0 6px rgba(56, 189, 248, 0.28), 0 3px 8px rgba(0, 0, 0, 0.55);
}

/* ===== Sentinelle : jaquette + type + corbeille + confirmation (2.6.4-alfa13) ===== */
.ts-clip-row { gap: 11px; }
.ts-clip-main { flex: 1; min-width: 0; }
.ts-clip-thumb {
  width: 76px; height: 48px; flex: none; border-radius: 9px; position: relative; overflow: hidden;
  background: linear-gradient(135deg, #2b2f3a, #161a22); cursor: pointer;
}
.ts-clip-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ts-clip-thumb.noimg { background: linear-gradient(135deg, #262a33, #14171d); }
.ts-clip-camtag {
  position: absolute; top: 3px; left: 4px; background: rgba(0,0,0,.6); color: #fff;
  font-size: 8.5px; font-weight: 700; padding: 1px 5px; border-radius: 5px; letter-spacing: .3px; text-transform: uppercase;
}
.ts-clip-tplay {
  position: absolute; right: 4px; bottom: 3px; width: 18px; height: 18px; border-radius: 50%;
  background: rgba(0,0,0,.55); color: #fff; display: flex; align-items: center; justify-content: center;
}
.typechip { font-size: 10px; font-weight: 700; padding: 1px 7px; border-radius: 20px; }
.tc-person { background: rgba(240,167,59,.16); color: #f0a73b; }
.tc-car { background: rgba(62,106,225,.20); color: #6b93ff; }
.tc-other { background: rgba(142,145,153,.18); color: #aeb3bd; }
.ts-clip-trash {
  width: 36px; height: 36px; flex: none; border-radius: 50%; border: none; cursor: pointer;
  background: rgba(239,68,68,.12); color: #ef4444; display: flex; align-items: center; justify-content: center;
}
.ts-clip-trash:active { background: rgba(239,68,68,.22); }
.vk-confirm-scrim {
  position: fixed; inset: 0; z-index: 9999; background: rgba(0,0,0,.6);
  display: flex; align-items: flex-end; justify-content: center;
}
.vk-confirm-card {
  width: 100%; max-width: 520px; background: #22242b; border-radius: 22px 22px 0 0;
  border-top: 1px solid rgba(255,255,255,.08); padding: 22px 20px calc(26px + env(safe-area-inset-bottom, 0px));
}
.vk-confirm-ic {
  width: 46px; height: 46px; border-radius: 50%; background: rgba(239,68,68,.14); color: #ef4444;
  display: flex; align-items: center; justify-content: center; margin: 0 auto 12px;
}
.vk-confirm-t { color: #f4f5f7; font-size: 17px; font-weight: 700; text-align: center; }
.vk-confirm-s { color: #8e9199; font-size: 13px; text-align: center; margin-top: 7px; line-height: 1.5; }
.vk-confirm-btns { display: flex; gap: 11px; margin-top: 20px; }
.vk-btn { flex: 1; text-align: center; padding: 13px; border-radius: 13px; font-size: 14px; font-weight: 700; border: none; cursor: pointer; }
.vk-cancel { background: #23252d; color: #f4f5f7; }
.vk-del { background: #ef4444; color: #fff; }

/* ══════════════════════════════════════════════════════════════════
   BOUTONS ACCUEIL WI-FI (VERT + SIGNAL) & BLUETOOTH (BLEU + SIGNAL)
   + OVERLAYS COMPACTS STYLE TESLA (2.6.4-alfa26 / Compagnon 1.2.8)
   ══════════════════════════════════════════════════════════════════ */
.header-right-stack {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  padding-top: 4px;
}
.header-right-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.radio-wifi-btn .sig-arc,
.radio-wifi-btn .sig-dot,
.radio-bt-btn .bt-rune,
.radio-bt-btn .bt-arc {
  transition: stroke 0.25s ease, fill 0.25s ease, opacity 0.25s ease, filter 0.25s ease;
}

.radio-wifi-btn:not(.is-on),
.radio-bt-btn:not(.is-on) {
  border-color: var(--text-2);
  color: var(--text-1);
  background: transparent;
  box-shadow: none;
}
.radio-bt-btn:not(.is-on) .bt-arc { opacity: 0.22; }

.radio-wifi-btn.is-on {
  border-color: rgba(34, 197, 94, 0.88);
  background: rgba(34, 197, 94, 0.11);
  color: var(--green);
  box-shadow: 0 0 12px rgba(34, 197, 94, 0.30);
}
.radio-wifi-btn.is-on .sig-arc { stroke: rgba(34, 197, 94, 0.22); }
.radio-wifi-btn.is-on .sig-dot {
  fill: #4ade80;
  filter: drop-shadow(0 0 3px rgba(74, 222, 128, 0.9));
}
.radio-wifi-btn.is-on.sig-0 .sig-dot { animation: radioSearchPulse 1.4s infinite ease-in-out; }
.radio-wifi-btn.is-on.sig-1 .sig-1,
.radio-wifi-btn.is-on.sig-2 .sig-1,
.radio-wifi-btn.is-on.sig-2 .sig-2,
.radio-wifi-btn.is-on.sig-3 .sig-1,
.radio-wifi-btn.is-on.sig-3 .sig-2,
.radio-wifi-btn.is-on.sig-3 .sig-3 {
  stroke: #4ade80;
  filter: drop-shadow(0 0 3px rgba(74, 222, 128, 0.85));
}

.radio-bt-btn.is-on {
  border-color: rgba(56, 189, 248, 0.90);
  background: rgba(56, 189, 248, 0.12);
  color: var(--cyan);
  box-shadow: 0 0 13px rgba(56, 189, 248, 0.34);
}
.radio-bt-btn.is-on .bt-rune {
  stroke: #38bdf8;
  filter: drop-shadow(0 0 3px rgba(56, 189, 248, 0.85));
}
.radio-bt-btn.is-on .bt-arc { stroke: rgba(56, 189, 248, 0.20); opacity: 1; }
.radio-bt-btn.is-on.sig-0 .bt-rune { animation: radioSearchPulse 1.5s infinite ease-in-out; }
.radio-bt-btn.is-on.sig-1 .bt-1,
.radio-bt-btn.is-on.sig-2 .bt-1,
.radio-bt-btn.is-on.sig-2 .bt-2,
.radio-bt-btn.is-on.sig-3 .bt-1,
.radio-bt-btn.is-on.sig-3 .bt-2,
.radio-bt-btn.is-on.sig-3 .bt-3 {
  stroke: #7dd3fc;
  filter: drop-shadow(0 0 3px rgba(56, 189, 248, 0.95));
}

@keyframes radioSearchPulse {
  0%, 100% { opacity: 0.45; }
  50% { opacity: 1; }
}

.radio-overlay-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(6, 7, 10, 0.56);
  backdrop-filter: blur(4px);
  z-index: 40;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}
.radio-overlay-backdrop.open { opacity: 1; pointer-events: auto; }

.radio-popover {
  position: absolute;
  top: calc(env(safe-area-inset-top, 10px) + 104px);
  right: 16px;
  left: 16px;
  max-height: calc(100% - 140px);
  background: rgba(23, 25, 31, 0.97);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 20px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.85);
  z-index: 45;
  display: flex;
  flex-direction: column;
  overflow: visible;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-10px) scale(0.95);
  transform-origin: top right;
  transition: opacity 0.2s ease, transform 0.24s cubic-bezier(0.22, 1, 0.36, 1);
}
.radio-popover.open {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}
.radio-popover::before {
  content: '';
  position: absolute;
  top: -7px;
  width: 12px;
  height: 12px;
  background: rgba(23, 25, 31, 0.98);
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  border-left: 1px solid rgba(255, 255, 255, 0.15);
  transform: rotate(45deg);
  z-index: 1;
}
.radio-popover.anchor-wifi::before { right: 62px; }
.radio-popover.anchor-bt::before { right: 18px; }
.rp-inner {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 19px;
  position: relative;
  z-index: 2;
  max-height: 100%;
}
.rp-header {
  padding: 15px 16px 13px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--line);
  flex-shrink: 0;
}
.rp-head-left { display: flex; align-items: center; gap: 11px; min-width: 0; }
.rp-head-badge {
  width: 36px;
  height: 36px;
  border-radius: 11px;
  background: var(--bg-card-2);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-1);
  flex-shrink: 0;
  transition: all 0.2s ease;
}
.rp-head-badge.wifi-on {
  background: rgba(34, 197, 94, 0.14);
  border-color: rgba(34, 197, 94, 0.4);
  color: #4ade80;
}
.rp-head-badge.bt-on {
  background: rgba(56, 189, 248, 0.14);
  border-color: rgba(56, 189, 248, 0.4);
  color: #38bdf8;
}
.rp-title { font-size: 15px; font-weight: 600; color: var(--text-1); }
.rp-sub {
  font-size: 12px;
  color: var(--text-2);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.rp-sub.green { color: #4ade80; font-weight: 500; }
.rp-sub.blue { color: #7dd3fc; font-weight: 500; }

.tesla-pill-switch.on-wifi { background: rgba(34, 197, 94, 0.35); }
.tesla-pill-switch.on-wifi .tesla-pill-knob { transform: translateX(20px); background: #4ade80; }
.tesla-pill-switch.on-bt { background: rgba(56, 189, 248, 0.35); }
.tesla-pill-switch.on-bt .tesla-pill-knob { transform: translateX(20px); background: #38bdf8; }

.rp-body {
  overflow-y: auto;
  max-height: 440px;
  scrollbar-width: none;
}
.rp-body::-webkit-scrollbar { display: none; }

.rp-sec-bar {
  padding: 10px 16px 6px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.rp-sec-lbl {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-2);
}
.rp-scan-btn {
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text-2);
  font-family: var(--font);
  font-size: 11.5px;
  font-weight: 600;
  padding: 4px 9px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  cursor: pointer;
}
.rp-scan-btn.spinning svg { animation: rpSpin360 0.8s linear infinite; }
@keyframes rpSpin360 { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }

.rp-item-wrap { border-bottom: 1px solid rgba(255, 255, 255, 0.05); }
.rp-item-wrap:last-child { border-bottom: none; }
.rp-item {
  padding: 11px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  cursor: pointer;
  transition: background 0.14s ease;
}
.rp-item:active { background: rgba(255, 255, 255, 0.07); }
.rp-item.connected-wifi { background: rgba(34, 197, 94, 0.08); }
.rp-item.connected-bt { background: rgba(56, 189, 248, 0.08); }
.rp-item-left { display: flex; align-items: center; gap: 11px; min-width: 0; flex: 1; }
.rp-item-name {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-1);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.rp-item-meta {
  font-size: 11.5px;
  color: var(--text-2);
  margin-top: 2px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.rp-item-right { display: flex; align-items: center; gap: 8px; flex-shrink: 0; color: var(--text-2); }
.rp-tag {
  font-size: 10.5px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 6px;
  background: var(--bg-card-2);
  color: var(--text-2);
  flex-shrink: 0;
}
.rp-tag.saved { background: rgba(255, 255, 255, 0.07); color: #cbd5e1; }
.rp-tag.conn-green { background: rgba(34, 197, 94, 0.18); color: #4ade80; }
.rp-tag.conn-blue { background: rgba(56, 189, 248, 0.18); color: #7dd3fc; }

.rp-auth-drawer {
  padding: 11px 16px 13px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: rgba(14, 15, 19, 0.68);
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}
.rp-auth-hint { font-size: 11.5px; color: var(--text-2); }
.rp-input-row { position: relative; display: flex; align-items: center; }
.rp-input-row .tesla-input { padding-right: 38px; }
.rp-eye-btn {
  position: absolute;
  right: 8px;
  background: transparent;
  border: none;
  color: var(--text-2);
  cursor: pointer;
  padding: 4px;
  display: flex;
}
.rp-auth-actions { display: grid; grid-template-columns: 1fr 1.4fr; gap: 8px; }
.rp-btn-sec {
  padding: 9px 10px;
  border-radius: 10px;
  background: var(--bg-card-2);
  border: 1px solid var(--line);
  color: var(--text-2);
  font-family: var(--font);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
}
.rp-btn-pri {
  padding: 9px 10px;
  border-radius: 10px;
  border: none;
  color: #fff;
  font-family: var(--font);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
}
.rp-btn-pri.green { background: #16a34a; }
.rp-btn-pri.blue { background: #2563eb; }

.rp-off-empty {
  padding: 24px 20px;
  text-align: center;
  color: var(--text-2);
  font-size: 12.5px;
  line-height: 1.5;
}
.rp-footer-note {
  padding: 10px 16px;
  border-top: 1px solid var(--line);
  background: rgba(15, 16, 20, 0.8);
  font-size: 11px;
  color: var(--text-2);
  display: flex;
  align-items: center;
  gap: 7px;
  flex-shrink: 0;
}

/* ══════════════════════════════════════════════════════════════════
   POPOVER COULEUR VOITURE SUR LA PAGE D'ACCUEIL
   ══════════════════════════════════════════════════════════════════ */
.paint-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.48);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 55;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}
.paint-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}
.paint-popover {
  position: absolute;
  top: calc(env(safe-area-inset-top, 10px) + 58px);
  left: 16px;
  right: 16px;
  z-index: 60;
  background: rgba(24, 26, 32, 0.97);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 20px;
  padding: 14px;
  box-shadow: 0 22px 50px rgba(0, 0, 0, 0.65);
  transform: translateY(-8px) scale(0.97);
  opacity: 0;
  pointer-events: none;
  transition: all 0.2s cubic-bezier(0.22, 1, 0.36, 1);
}
.paint-popover.open {
  transform: translateY(0) scale(1);
  opacity: 1;
  pointer-events: auto;
}
.paint-pop-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.paint-pop-head strong {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-1);
}
.paint-pop-head span {
  font-size: 11.5px;
  color: var(--text-2);
}
.paint-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}
.paint-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 11px;
  border-radius: 13px;
  border: 1px solid var(--line);
  background: var(--bg-card-2);
  cursor: pointer;
  transition: all 0.16s ease;
}
.paint-option:active { transform: scale(0.97); }
.paint-option.active {
  border-color: rgba(56, 189, 248, 0.65);
  background: rgba(56, 189, 248, 0.12);
}
.paint-swatch {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow:
    inset -4px -4px 7px rgba(0, 0, 0, 0.42),
    inset 3px 3px 5px rgba(255, 255, 255, 0.42),
    0 0 0 1px rgba(255, 255, 255, 0.24);
}
.paint-name {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-1);
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.paint-check {
  font-size: 13px;
  color: var(--cyan);
  font-weight: 700;
  opacity: 0;
}
.paint-option.active .paint-check { opacity: 1; }

/* Sélecteur de seuil de charge dans Notifications */
.notif-target-box {
  margin-top: 12px;
  padding: 11px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
}
.notif-target-box.disabled {
  display: none;
}
.notif-target-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-2);
  margin-bottom: 9px;
}
.notif-target-head strong {
  color: var(--cyan);
  font-size: 13px;
  font-weight: 700;
}
.notif-target-chips {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
}
.notif-chip {
  padding: 8px 4px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: #14151a;
  color: var(--text-2);
  font-family: var(--font);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.16s ease;
}
.notif-chip.active {
  background: rgba(56, 189, 248, 0.16);
  border-color: rgba(56, 189, 248, 0.65);
  color: var(--text-1);
}

/* ══════════════════════════════════════════════════════════════════
   NOUVEAUTÉS 2.6.4-alfa45 / COMPAGNON 1.2.25 :
   - État non lié sans données véhicule par défaut
   - Cadenas centré dans l'en-tête + fraîcheur télémétrie
   - Bouton Phare rond style Tesla carte sur Contrôles
   - Bouton Actualiser rond animé sur Clips
   - Rapport de la semaine & Rappels
   - Carte Localisation : voiture vue de dessus + itinéraire bleu
   - Modale proposition réveil ACC OFF + retour visuel "En cours…"
   - Adaptation responsive tout écran + pinch-to-zoom Live
   ══════════════════════════════════════════════════════════════════ */
.home-unpaired-shell {
  padding-bottom: 24px;
}
.unpaired-card {
  margin: 28px 20px 20px;
  padding: 28px 22px 24px;
  border-radius: 20px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.unpaired-icon-ring {
  width: 62px;
  height: 62px;
  border-radius: 50%;
  background: rgba(62, 106, 225, 0.14);
  border: 1px solid rgba(62, 106, 225, 0.35);
  color: #7ea0ff;
  display: flex;
  align-items: center;
  justify-content: center;
}
.unpaired-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-1);
}
.unpaired-sub {
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-2);
  margin-bottom: 6px;
}

.home-header-lock {
  margin: 4px auto 0;
  width: 28px;
  height: 28px;
  background: transparent;
  border: none;
  color: var(--text-1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: default;
  pointer-events: none;
  flex-shrink: 0;
}
.home-header-lock.unlocked {
  color: var(--text-1);
}
.home-sync-fresh {
  margin-top: 3px;
  font-size: 11px;
  font-weight: 500;
  color: var(--text-3);
  min-height: 14px;
}

.ctrl-top-flash-btn {
  position: absolute;
  top: 12px;
  right: 16px;
  z-index: 12;
  border-radius: 50%;
  transition: transform 0.14s ease, border-color 0.18s ease, background 0.18s ease;
}
.ctrl-top-flash-btn:active { transform: scale(0.92); }

.clips-refresh-icon-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--bg-card-2);
  border: 1px solid var(--line);
  color: var(--text-1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: transform 0.15s ease, border-color 0.18s ease;
}
.clips-refresh-icon-btn:active { transform: scale(0.9); }
.clips-refresh-icon-btn.spinning svg { animation: rpSpin360 0.75s linear infinite; }

.report-stat-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 14px;
}
.report-stat-card {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 15px 14px;
}
.rsc-lbl {
  font-size: 11.5px;
  font-weight: 500;
  color: var(--text-2);
}
.rsc-val {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-1);
  margin-top: 6px;
  letter-spacing: -0.02em;
}

.vk-car-topdown-marker {
  width: 34px;
  height: 60px;
  border-radius: 11px;
  overflow: hidden;
  border: none;
  box-shadow: none;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
}
.vk-car-topdown-marker img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  filter: drop-shadow(0 3px 5px rgba(0, 0, 0, 0.55));
}

.map-route-floating-card {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  z-index: 9;
  background: rgba(24, 25, 30, 0.94);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  padding: 13px 15px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.62);
}
.map-route-pill-btn {
  padding: 9px 14px;
  border-radius: 10px;
  border: none;
  background: var(--blue);
  color: #ffffff;
  font-family: var(--font);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  flex-shrink: 0;
}
.map-route-pill-btn:active { transform: scale(0.95); }
.fp-floating-back.route-active {
  background: var(--blue);
  border-color: rgba(147, 197, 253, 0.6);
  color: #ffffff;
}

.acc-wake-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(6, 7, 10, 0.65);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  z-index: 88;
  display: none;
  align-items: flex-end;
  justify-content: center;
}
.acc-wake-backdrop.open { display: flex; }
.acc-wake-sheet {
  width: 100%;
  background: var(--bg-sheet);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 22px 22px 0 0;
  padding: 22px 20px calc(24px + env(safe-area-inset-bottom, 0px));
  box-shadow: 0 -16px 40px rgba(0, 0, 0, 0.72);
}
.acc-wake-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--text-1);
}
.acc-wake-msg {
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--text-2);
  margin-top: 8px;
}
.acc-wake-actions {
  display: grid;
  grid-template-columns: 1fr 1.35fr;
  gap: 10px;
  margin-top: 18px;
}

.vk-btn-busy {
  opacity: 0.52 !important;
  pointer-events: none;
  transition: opacity 0.15s ease;
}

.cam-feed-single {
  touch-action: none;
}
.cam-live-stream-img,
.cam-live-h264-canvas {
  transform-origin: center center;
  will-change: transform;
}

.cam-car-selector-box {
  position: relative;
  width: min(210px, 54vw);
  max-height: calc(100% - 16px);
  aspect-ratio: 215 / 365;
}
.cam-topdown-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Adaptation responsive universelle (petits écrans portrait, grands écrans, tablettes) */
.ts-row, .ts-row-block, .tesla-flat-row { min-width: 0; }
.ts-folder-pill { flex-wrap: wrap; }
.ts-folder-code { word-break: break-all; }
.ts-seg-row { overflow-x: auto; scrollbar-width: none; }
.ts-seg-row::-webkit-scrollbar { display: none; }
.ts-seg-btn { white-space: nowrap; }

@media (max-width: 390px) {
  .menu-row { padding: 14px 18px; }
  .home-sentry-status-row { margin: 0 18px 6px; }
  .tesla-sec-body { padding: 10px 16px 30px; }
  .sentry-pane-scroll { padding: 4px 14px 32px; }
  .topdown-wrap, .topdown-img { width: 236px; height: 404px; }
  .clim-car-wrap, .clim-overlay-svg { width: 236px; height: 404px; }
  #climCutawayImg { width: 236px !important; height: 404px !important; }
  .cam-selector-stage { padding-right: 54px; }
  .cam-right-stack { right: 12px; }
  .cam-side-btn { width: 44px; height: 44px; }
  .tcs-big-temp { font-size: 40px; min-width: 102px; }
  .tpms-car-img { width: 152px; height: 258px; }
}
@media (max-height: 700px) {
  .topdown-wrap, .topdown-img { width: 214px; height: 366px; }
  .clim-car-wrap, .clim-overlay-svg { width: 214px; height: 366px; }
  #climCutawayImg { width: 214px !important; height: 366px !important; }
  .cam-video-stage { height: 216px; }
}

/* ── Nouvelles fonctionnalités VEKTRA Compagnon (2.6.4-alfa48 / Compagnon 1.2.28) ── */
.vk-feat-stat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.vk-feat-stat-box {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 11px 8px;
  text-align: center;
}
.vk-feat-stat-val { font-size: 16px; font-weight: 700; color: var(--text-1); }
.vk-feat-stat-lbl { font-size: 11px; color: var(--text-2); margin-top: 2px; }

.vk-feat-chip-row { display: flex; gap: 6px; flex-wrap: wrap; }
.vk-feat-chip {
  background: var(--bg-card-2);
  border: 1px solid var(--line);
  color: var(--text-2);
  font-size: 12px;
  font-weight: 600;
  padding: 6px 11px;
  border-radius: 99px;
  cursor: pointer;
}
.vk-feat-chip.active {
  background: rgba(56, 189, 248, 0.16);
  border-color: rgba(56, 189, 248, 0.5);
  color: var(--cyan);
}
.vk-feat-input {
  background: #121318;
  border: 1px solid var(--line);
  color: var(--text-1);
  border-radius: 10px;
  padding: 9px 11px;
  font-size: 13.5px;
  width: 100%;
  font-family: inherit;
}
.vk-feat-btn-row { display: flex; gap: 8px; flex-wrap: wrap; }
.vk-feat-btn-row > * { flex: 1; }
.vk-feat-danger {
  background: rgba(239, 68, 68, 0.16);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.36);
  border-radius: 11px;
  padding: 9px 11px;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
}
.vk-feat-pill {
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 12.5px;
  line-height: 1.42;
  border: 1px solid var(--line);
}
.vk-feat-pill.warn { background: rgba(245, 158, 11, 0.10); border-color: rgba(245, 158, 11, 0.32); }
.vk-feat-pill.ok { background: rgba(34, 197, 94, 0.09); border-color: rgba(34, 197, 94, 0.28); }
.vk-feat-pill.info { background: rgba(56, 189, 248, 0.09); border-color: rgba(56, 189, 248, 0.28); }

.vk-trip-card {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 13px 14px;
  cursor: pointer;
  transition: border-color 0.15s ease;
}
.vk-trip-card.open { border-color: rgba(56, 189, 248, 0.45); }
.vk-trip-detail {
  display: none;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}
.vk-trip-card.open .vk-trip-detail { display: block; }

.vk-cabin-stage {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  background: #0a0b0e;
  border: 1px solid var(--line);
  height: 268px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.vk-cabin-stage img { height: 258px; width: auto; object-fit: contain; opacity: 0.92; }
.vk-led { position: absolute; border-radius: 99px; transition: all 0.22s ease; pointer-events: none; }
.vk-led-dash { top: 62px; left: 50%; transform: translateX(-50%); width: 116px; height: 5px; }
.vk-led-fl { top: 72px; left: calc(50% - 86px); width: 5px; height: 60px; transform: rotate(6deg); }
.vk-led-fr { top: 72px; right: calc(50% - 86px); width: 5px; height: 60px; transform: rotate(-6deg); }
.vk-led-rl { bottom: 68px; left: calc(50% - 88px); width: 5px; height: 56px; transform: rotate(-4deg); }
.vk-led-rr { bottom: 68px; right: calc(50% - 88px); width: 5px; height: 56px; transform: rotate(4deg); }
.vk-swatches { display: flex; justify-content: space-between; gap: 6px; padding: 4px 0; }
.vk-swatch {
  width: 34px; height: 34px; border-radius: 50%;
  border: 2px solid transparent; cursor: pointer; transition: transform 0.15s ease;
}
.vk-swatch.active { border-color: #fff; transform: scale(1.12); box-shadow: 0 0 12px rgba(255, 255, 255, 0.35); }
@keyframes vkLedPulse { 0%, 100% { opacity: 0.55; } 50% { opacity: 1; } }
.vk-led-music { animation: vkLedPulse 0.85s infinite ease-in-out; }

.vk-doc-ring {
  width: 72px; height: 72px; border-radius: 50%;
  background: conic-gradient(var(--green) 0 90%, rgba(255, 255, 255, 0.08) 90% 100%);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.vk-doc-ring-in {
  width: 56px; height: 56px; border-radius: 50%; background: var(--bg-card);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
}

.vk-modal-bg {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.74);
  backdrop-filter: blur(6px);
  z-index: 980;
  display: none;
  align-items: flex-end;
  justify-content: center;
}
.vk-modal-bg.open { display: flex; }
.vk-modal-sheet {
  width: 100%;
  max-width: 480px;
  max-height: 86vh;
  background: var(--bg-sheet);
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 22px 22px 0 0;
  padding: 16px 16px 26px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.vk-modal-handle {
  width: 38px; height: 4px; border-radius: 99px;
  background: rgba(255, 255, 255, 0.22); margin: 0 auto 2px;
}
.vk-snap-preview {
  width: 100%;
  max-height: 210px;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #0a0c10;
  display: block;
}
.vk-loc-action-bar {
  position: absolute;
  bottom: 94px;
  left: 14px;
  right: 14px;
  z-index: 8;
  display: flex;
  gap: 8px;
}
.vk-loc-pill-btn {
  flex: 1;
  padding: 10px 8px;
  font-size: 12px;
  font-weight: 600;
  border-radius: 12px;
  background: rgba(20, 22, 28, 0.94);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: var(--text-1);
  cursor: pointer;
}
.vk-loc-pill-btn.active {
  border-color: rgba(56, 189, 248, 0.55);
  color: var(--cyan);
}
.vk-loc-pill-btn.live-on {
  border-color: rgba(34, 197, 94, 0.55);
  color: #86efac;
}
.tesla-flat-row.keyfob-soon {
  opacity: 0.45;
  cursor: not-allowed;
}
.tesla-flat-row.keyfob-on .keyfob-ico {
  color: var(--cyan);
}
.keyfob-soon-tag {
  display: inline-block;
  margin-left: 6px;
  font-size: 10.5px;
  font-weight: 600;
  color: var(--text-2);
  background: rgba(255, 255, 255, 0.08);
  padding: 2px 7px;
  border-radius: 99px;
  vertical-align: middle;
}
.keyfob-sub-wrap {
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  transition: max-height 0.26s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.2s ease;
}
.keyfob-sub-wrap.open {
  max-height: 86px;
  opacity: 1;
}
.keyfob-sub-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 12px 11px 14px;
  margin: 6px 0 8px 18px;
  border-radius: 12px;
  background: rgba(56, 189, 248, 0.07);
  border: 1px solid rgba(56, 189, 248, 0.20);
  cursor: pointer;
  transition: background 0.16s ease, border-color 0.16s ease;
}
.keyfob-sub-row.is-on {
  background: rgba(62, 106, 225, 0.15);
  border-color: rgba(125, 211, 252, 0.42);
}
.ksr-left {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
}
.ksr-branch {
  color: var(--cyan);
  font-size: 14px;
  font-weight: 700;
  flex-shrink: 0;
}
.ksr-title {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-1);
  line-height: 1.25;
}
.diag-cpu-clickable {
  position: relative;
  cursor: pointer;
  border: 1px solid rgba(56, 189, 248, 0.32);
  transition: border-color 0.16s ease, transform 0.14s ease, background 0.16s ease;
}
.diag-cpu-clickable:active {
  transform: scale(0.97);
}
.diag-tap-badge {
  position: absolute;
  top: 7px;
  right: 7px;
  font-size: 9.5px;
  font-weight: 700;
  color: var(--cyan);
  background: rgba(56, 189, 248, 0.15);
  padding: 2px 6px;
  border-radius: 99px;
}
.diag-perf-extra-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 0 14px 14px;
}
.diag-perf-mini-tile {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 9px 11px;
}
.dpm-lbl {
  font-size: 10.5px;
  font-weight: 600;
  color: var(--text-2);
}
.dpm-val {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-1);
  margin-top: 3px;
}
.dpm-sub {
  font-size: 10.5px;
  color: var(--text-2);
  margin-top: 1px;
}
.cpu-cores-overlay {
  position: absolute;
  inset: 0;
  background: rgba(6, 8, 12, 0.78);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
  z-index: 60;
}
.cpu-cores-overlay.open {
  opacity: 1;
  pointer-events: auto;
}
.cpu-cores-sheet {
  width: 100%;
  max-height: 86%;
  background: #16181f;
  border-top: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 26px 26px 0 0;
  padding: 12px 16px 26px;
  display: flex;
  flex-direction: column;
  gap: 11px;
  transform: translateY(28px);
  transition: transform 0.26s cubic-bezier(0.22, 1, 0.36, 1);
  overflow-y: auto;
}
.cpu-cores-overlay.open .cpu-cores-sheet {
  transform: translateY(0);
}
.cpu-cores-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.cpu-cores-title {
  font-size: 15.5px;
  font-weight: 700;
  color: var(--text-1);
}
.cpu-cores-sub {
  font-size: 11.5px;
  color: var(--text-2);
  margin-top: 2px;
}
.cpu-cores-close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: var(--text-1);
  font-size: 15px;
  cursor: pointer;
}
.cpu-cluster-lbl {
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-2);
  display: flex;
  justify-content: space-between;
  margin: 6px 0 7px;
}
.cpu-cores-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}
.cpu-core-card {
  background: #101218;
  border: 1px solid var(--line);
  border-radius: 13px;
  padding: 9px 10px;
  display: flex;
  align-items: center;
  gap: 9px;
}
.cpu-core-dial {
  position: relative;
  width: 46px;
  height: 46px;
  flex-shrink: 0;
}
.cpu-core-dial svg {
  width: 46px;
  height: 46px;
  transform: rotate(-90deg);
}
.cpu-core-dial .bg {
  fill: none;
  stroke: rgba(255, 255, 255, 0.08);
  stroke-width: 5;
}
.cpu-core-dial .fg {
  fill: none;
  stroke: var(--cyan);
  stroke-width: 5;
  stroke-linecap: round;
  transition: stroke-dashoffset 0.35s ease, stroke 0.25s ease;
}
.cpu-core-dial-pct {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-1);
}
.cpu-core-info {
  min-width: 0;
  flex: 1;
}
.cpu-core-name {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-1);
}
.cpu-core-freq {
  font-size: 11px;
  font-weight: 600;
  color: var(--cyan);
  margin-top: 2px;
}
.cpu-core-max {
  font-size: 9.5px;
  color: var(--text-2);
  margin-top: 1px;
}

/* ── Licence Sentinelle & Jours restants en rouge tout en dessous des infos logicielles ── */
.tf-license-red {
  margin-top: 10px;
  padding: 8px 12px;
  border-radius: 10px;
  background: rgba(255, 59, 48, 0.12);
  border: 1px solid rgba(255, 59, 48, 0.38);
  color: #ff3b30;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.2px;
  line-height: 1.4;
  text-align: center;
}
.tf-license-red .tf-lic-sub {
  display: block;
  font-size: 10.5px;
  font-weight: 600;
  color: #ff6b63;
  margin-top: 2px;
}

.sentry-license-lock {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(10, 11, 15, 0.97);
  backdrop-filter: blur(14px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 20px;
  overflow-y: auto;
}
.sll-inner {
  width: 100%;
  max-width: 360px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.sll-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: rgba(255, 59, 48, 0.14);
  border: 1.5px solid rgba(255, 59, 48, 0.48);
  color: #ff3b30;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  box-shadow: 0 0 36px rgba(255, 59, 48, 0.22);
}
.sll-title {
  font-size: 20px;
  font-weight: 700;
  color: #ffffff;
}
.sll-desc {
  margin-top: 10px;
  font-size: 13px;
  color: #9ba5b7;
  line-height: 1.55;
}
.sll-id-card {
  margin-top: 20px;
  width: 100%;
  background: #151923;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  padding: 12px 14px;
}
.sll-id-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.9px;
  color: #7c8596;
  font-weight: 700;
}
.sll-id-row {
  margin-top: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.sll-id-val {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 1.6px;
  color: #22d3ee;
}
.sll-copy-btn {
  background: #1f2737;
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #f3f6fb;
  border-radius: 9px;
  padding: 7px 11px;
  font-size: 11.5px;
  font-weight: 700;
}
.sll-retry-btn {
  margin-top: 16px;
  width: 100%;
  background: linear-gradient(135deg, #0ea5e9, #2563eb);
  border: none;
  color: #ffffff;
  border-radius: 13px;
  padding: 13px 16px;
  font-size: 14px;
  font-weight: 700;
}
.sll-unpair-btn {
  margin-top: 10px;
  background: transparent;
  border: none;
  color: #7c8596;
  font-size: 12px;
  padding: 8px;
}
.sll-footer {
  margin-top: 28px;
  width: 100%;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}
.sll-soft {
  font-size: 11.5px;
  color: #7c8596;
  margin-top: 5px;
}
