/* =========================
   BSF GO • Modern Design System
   Version 2.0 - January 2026
   ========================= */

/* Reset */
*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* =========================
   DESIGN TOKENS
   ========================= */
:root {
  --max: 1320px;
  --page-pad: 50px;
  --page-max: 9999px;
  --quickbar-max: 9999px;

  /* Colors - Light theme (BSF palette) */
  --bg0: #F4F6F8;
  --bg1: #EDF0F4;
  --bg2: #FFFFFF;
  --bg-alt: #EDF0F4;
  --surface: #FFFFFF;

  --brand: #0C304C;
  --brand-dark: #0C304C;
  --brand-light: #1E70B8;
  --accent: #1E70B8;

  --cta-primary: #1E70B8;
  --cta-secondary: #0C304C;
  --cta-warning: #C2820A;

  --glass: rgba(255,255,255,.75);
  --glass2: rgba(255,255,255,.92);
  --stroke: rgba(134,159,157,.55);
  --stroke2: rgba(134,159,157,.25);
  --border: rgba(134,159,157,.45);

  --text: #213743;
  --text2: #213743;
  --text-heading: #0C304C;
  --text-on-dark: #F1F2F2;
  --muted: #869f9d;
  --muted2: #869f9d;
  --nav-text: #3d5a65;

  --shadow: 0 20px 60px rgba(10,40,30,.12);
  --shadow-sm: 0 8px 24px rgba(10,40,30,.08);
  --shadow-xs: 0 4px 12px rgba(10,40,30,.06);

  --r-xl: 24px;
  --r-lg: 18px;
  --r-md: 14px;
  --r-sm: 10px;
  --r-xs: 6px;
}

/* Dark theme */
html[data-theme="dark"] {
  --bg0: #0B1E33;
  --bg1: #102840;
  --bg2: #19334E;
  --bg-alt: #19334E;
  --surface: #19334E;

  --brand: #4D9ED0;
  --brand-dark: #0C304C;
  --brand-light: #19334E;
  --accent: #4D9ED0;

  --cta-primary: #4D9ED0;
  --cta-secondary: #0C304C;
  --cta-warning: #C2820A;

  --glass: rgba(25,51,78,.82);
  --glass2: rgba(25,51,78,.95);
  --stroke: rgba(77,158,208,.20);
  --stroke2: rgba(77,158,208,.10);
  --border: rgba(77,158,208,.18);

  --text: #E8F1F8;
  --text2: #E8F1F8;
  --text-heading: #FFFFFF;
  --text-on-dark: #E8F1F8;
  --muted: #7FA8C4;
  --muted2: #7FA8C4;
  --nav-text: #A8C8E0;

  --shadow: 0 20px 60px rgba(0,0,0,.35);
  --shadow-sm: 0 8px 24px rgba(0,0,0,.25);
  --shadow-xs: 0 4px 12px rgba(0,0,0,.18);
}

/* Responsive padding */
@media (max-width: 640px){
  :root{ --page-pad: 14px; }
}

/* Background */
body {
  color: var(--text);
  background-color: var(--bg0);
  min-height: 100vh;
}

/* Typographic rhythm */
h1, h2, h3, h4 {
  color: var(--text2);
  letter-spacing: -0.2px;
}

p {
  color: var(--text);
}

.pageInner > section {
  margin-bottom: 26px;
  scroll-margin-top: 90px;
}

/* =========================
   LUCIDE ICONS BASE
   ========================= */
[data-lucide] {
  width: 18px;
  height: 18px;
  stroke-width: 2;
  flex-shrink: 0;
}

.spinIcon {
  animation: spin 1s linear infinite;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* =========================
   HELPERS
   ========================= */
.hideOnMobile { display: inline-flex; }
.hideOnSmall { display: table-cell; }
.hideOnMedium { display: table-cell; }

@media (max-width: 900px) {
  .hideOnMedium { display: none !important; }
}
@media (max-width: 680px) {
  .hideOnSmall { display: none !important; }
}
@media (max-width: 580px) {
  .hideOnMobile { display: none !important; }
}

/* =========================
   TOPBAR
   ========================= */
.topbar {
  position: sticky;
  top: 12px;
  z-index: 1000;
  padding: 0 24px;
}

.topbar .wrap {
  max-width: var(--max);
  width: 100%;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  min-width: 0;

  background: var(--glass2);
  border: 1px solid var(--stroke);
  border-radius: 999px;
  padding: 8px 14px;

  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: var(--shadow-sm);
}

/* Brand */
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text);
}

.logoRing {
  position: relative;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  overflow: hidden;
  flex-shrink: 0;
  background: var(--brand);
  padding: 2px;
  box-shadow: 0 8px 20px rgba(12,48,76,.25);
}

.logoImg {
  width: 100%;
  height: 100%;
  border-radius: 999px;
  object-fit: cover;
  display: block;
}

.logoShine {
  position: absolute;
  inset: 0;
  background: none;
  pointer-events: none;
}

.brandText {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.brandName {
  font-weight: 800;
  font-size: 17px;
  letter-spacing: -0.5px;
  line-height: 1.1;
}

.brandTag {
  font-size: 11px;
  font-weight: 500;
  color: var(--muted);
  letter-spacing: 0.2px;
}

.spacer { flex: 1; }

/* Stats Badge */
.statsBadge {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: color-mix(in srgb, var(--brand) 10%, transparent);
  border: 1px solid color-mix(in srgb, var(--brand) 20%, transparent);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  color: var(--brand);
}

.statsBadge .statIcon {
  width: 14px;
  height: 14px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  height: 40px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: var(--glass2);
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: all .18s ease;
  box-shadow: var(--shadow-xs);
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
  border-color: var(--brand);
}

.btn:active {
  transform: translateY(0);
}

.btnIconSvg {
  width: 16px;
  height: 16px;
}

.btnCaret {
  width: 14px;
  height: 14px;
  opacity: .6;
}

.btnPrimary {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.btnPrimary:hover {
  background: color-mix(in srgb, var(--accent) 85%, #000);
  border-color: color-mix(in srgb, var(--accent) 85%, #000);
}

/* Dark mode: accent (#4D9ED0) is light, use dark text for contrast */
html[data-theme="dark"] .btnPrimary {
  color: #0B1E33;
}

.btnGhost {
  background: color-mix(in srgb, var(--accent) 8%, var(--bg2));
  border-color: var(--accent);
  color: var(--accent);
}

.btnOutline {
  background: transparent;
  border: 1.5px solid var(--stroke);
}

.btnOutline:hover {
  background: color-mix(in srgb, var(--brand) 8%, transparent);
  border-color: var(--brand);
  color: var(--brand);
}

.btnFull {
  width: 100%;
}

.iconBtn {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: var(--bg2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all .18s ease;
  box-shadow: var(--shadow-xs);
  color: var(--text);
}

.iconBtn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
  border-color: var(--brand);
  color: var(--brand);
}

.iconBtn .iconSun { display: none; }
html[data-theme="dark"] .iconBtn .iconMoon { display: none; }
html[data-theme="dark"] .iconBtn .iconSun { display: block; }

/* Dropdown */
.dropdown { position: relative; }

.menu {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  width: min(320px, 85vw);
  background: var(--bg2);
  border: 1px solid var(--stroke);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow);
  padding: 8px;
  display: none;
  max-height: 380px;
  overflow: auto;
}

.dropdown[aria-expanded="true"] .menu { display: block; }

.menuItem {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border-radius: var(--r-sm);
  text-decoration: none;
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  transition: all .15s ease;
}

.menuItem:hover {
  background: color-mix(in srgb, var(--brand) 10%, transparent);
  color: var(--brand);
}

.tickIcon {
  width: 16px;
  height: 16px;
  color: var(--brand);
}

/* =========================
   PAGE GRID
   ========================= */
.page, .quickbar{ width:100%; }

.page {
  margin: 0 auto;
  padding: 0 50px;
}

/* =========================
   PAGE LAYOUT (no sidebar — full width)
   ========================= */
.pageLayout {
  display: flex;
  align-items: flex-start;
  padding-top: 24px;
}

.sidebar { display: none; }

.pageMain {
  flex: 1;
  min-width: 0;
}

@media (max-width: 768px) {
  .pageLayout { padding-top: 16px; }
}

/* =========================
   VIDEO MAP (PLOT_MAP)
   ========================= */
.videoMapWrap {
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-sm);
  background: #000;
  animation: cardInFade .4s ease both;
}

.videoMapPlayer {
  width: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
}

@media (max-width: 768px) {
  .videoMapWrap { border-radius: 12px; }
}

.pageInner{
  margin: 0 auto;
  padding-left: var(--page-pad);
  padding-right: var(--page-pad);
}

.quickbarInner{
  margin: 0 auto;
  padding-left: var(--page-pad);
  padding-right: var(--page-pad);
}

.quickbar{
  margin-top: 32px;
  margin-bottom: 8px;
}

@media (max-width: 640px){
  .quickbar{ margin-top: 22px; margin-bottom: 6px; }
}

/* =========================
   HOME INTRO
   ========================= */
.homeIntro {
  margin: 18px 0 6px;
  padding: 16px 18px;
  border-radius: var(--r-lg);
  border: 1px solid var(--stroke);
  background: var(--glass2);
  box-shadow: var(--shadow-sm);
}

.homeLead {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
}

/* =========================
   ACADEMY SECTIONS
   ========================= */
.academy-hero {
  margin: 8px 0 26px;
  padding: 28px;
  border-radius: var(--r-xl);
  background:
    linear-gradient(120deg, rgba(12, 48, 76, 0.9), rgba(12, 48, 76, 0.7)),
    url('../erp1/doc/images/dolibarr_screenshot4_1920x1080.jpg') center/cover no-repeat;
  border: 1px solid rgba(255,255,255,0.08);
  color: #fff;
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
  gap: 22px;
  box-shadow: var(--shadow);
}

.academy-hero-content {
  max-width: 720px;
}

.academy-hero .btnPrimary,
.academy-hero .btnGhost {
  min-width: 180px;
}

.academy-hero .btnGhost {
  background: rgba(255,255,255,0.12);
  color: #fff;
  border-color: rgba(255,255,255,0.2);
}

.academy-kicker {
  margin: 0 0 6px;
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.6);
  font-weight: 700;
}

.academy-hero h1 {
  margin: 0 0 10px;
  font-size: 28px;
  font-weight: 900;
  letter-spacing: -0.4px;
}

.academy-lead {
  margin: 0 0 16px;
  color: rgba(255,255,255,0.82);
  max-width: 720px;
}

.academy-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.academy-hero-stats {
  display: grid;
  gap: 10px;
  align-content: start;
}

.academy-stat {
  padding: 12px;
  border-radius: var(--r-lg);
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.08);
}

.academy-stat-num {
  display: block;
  font-weight: 800;
  font-size: 16px;
}

.academy-stat-label {
  display: block;
  font-size: 12px;
  color: rgba(255,255,255,0.75);
}

.academy-section {
  margin: 0 0 28px;
}

.academy-section h2 {
  margin: 0 0 8px;
  font-size: 20px;
  font-weight: 900;
}

.academy-sub {
  margin: 0 0 16px;
  color: var(--muted);
}

.academy-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.academy-card {
  background: var(--glass2);
  border: 1px solid var(--stroke);
  border-radius: var(--r-lg);
  padding: 16px;
  box-shadow: var(--shadow-sm);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.academy-card h3 {
  margin: 0 0 8px;
  font-size: 15px;
  font-weight: 800;
}

.academy-card p {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 13px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.academy-card ul {
  margin: 0;
  padding-left: 16px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

/* Unified hover lift */
.academy-card:hover,
.academy-step:hover,
.academy-program-card:hover,
.cv-card:hover,
.startup-card:hover,
.startup-form:hover,
.usecase-card:hover,
.journey-card:hover,
.portfolio-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  border-color: var(--accent);
}

.academy-steps {
  margin-top: 8px;
}

.academy-steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}

.academy-step {
  padding: 16px;
  border-radius: var(--r-lg);
  border: 1px solid var(--stroke);
  background: var(--glass2);
  box-shadow: var(--shadow-sm);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.academy-step-num {
  display: inline-flex;
  font-size: 12px;
  font-weight: 800;
  color: var(--brand);
  margin-bottom: 6px;
}

.academy-step h4 {
  margin: 0 0 6px;
  font-size: 14px;
  font-weight: 800;
}

.academy-step p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

.academy-cta {
  margin: 0 0 30px;
  padding: 22px;
  border-radius: var(--r-xl);
  background: #0C304C;
  color: #fff;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  box-shadow: var(--shadow);
}

.academy-cta .btnPrimary {
  min-width: 190px;
}

.academy-cta h2 {
  margin: 0 0 6px;
  font-size: 20px;
  font-weight: 900;
}

.academy-cta p {
  margin: 0;
  color: rgba(255,255,255,0.82);
}

.academy-team {
  margin-top: 8px;
}

.academy-programs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.academy-program-card {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 16px;
  border-radius: var(--r-lg);
  border: 1px solid var(--stroke);
  background: var(--glass2);
  text-decoration: none;
  color: var(--text);
  box-shadow: var(--shadow-sm);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
  overflow: hidden;
}

.academy-program-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  border-color: var(--brand);
}

.program-cover {
  height: 120px;
  border-radius: var(--r-md);
  background-size: cover;
  background-position: center;
  border: 1px solid var(--stroke2);
  filter: saturate(1.08);
}

.academy-program-card h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 800;
  min-height: 34px;
}

.academy-program-card p {
  margin: 0;
  font-size: 12px;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.program-tag {
  display: inline-flex;
  width: fit-content;
  padding: 4px 10px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--brand) 18%, transparent);
  color: var(--brand);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.3px;
}

.cv-section {
  margin-top: 6px;
}

.cv-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.cv-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}

.cv-card {
  padding: 16px;
  border-radius: var(--r-lg);
  border: 1px solid var(--stroke);
  background: var(--glass2);
  box-shadow: var(--shadow-sm);
  display: grid;
  gap: 8px;
  overflow: hidden;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.cv-cover {
  height: 110px;
  border-radius: var(--r-md);
  background-size: cover;
  background-position: center;
  border: 1px solid var(--stroke2);
  filter: saturate(1.08);
}

.cv-card h3 {
  margin: 0 0 6px;
  font-size: 14px;
  font-weight: 800;
  min-height: 32px;
}

.cv-card p {
  margin: 0;
  font-size: 12px;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.startup-section {
  margin-top: 6px;
}

.startup-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.startup-card {
  padding: 16px;
  border-radius: var(--r-lg);
  border: 1px solid var(--stroke);
  background: var(--glass2);
  box-shadow: var(--shadow-sm);
  display: grid;
  gap: 8px;
  overflow: hidden;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.startup-cover {
  height: 120px;
  border-radius: var(--r-md);
  background-size: cover;
  background-position: center;
  border: 1px solid var(--stroke2);
  filter: saturate(1.08);
}

.startup-card h3 {
  margin: 0 0 8px;
  font-size: 14px;
  font-weight: 800;
  min-height: 32px;
}

.startup-card ul {
  margin: 0;
  padding-left: 16px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  max-height: 3.6em;
  overflow: hidden;
}

.startup-cta {
  margin-top: 16px;
  padding: 18px;
  border-radius: var(--r-lg);
  background: #0C304C;
  border: 1px solid rgba(255,255,255,0.08);
  color: #fff;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  box-shadow: var(--shadow);
}

.startup-cta h3 {
  margin: 0 0 6px;
  font-size: 18px;
  font-weight: 900;
}

.startup-cta p {
  margin: 0;
  color: rgba(255,255,255,0.82);
}

.visual-mosaic {
  margin: 4px 0 26px;
}

.mosaic-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
}

.mosaic-tile {
  position: relative;
  overflow: hidden;
  height: 150px;
  border-radius: var(--r-lg);
  background-size: cover;
  background-position: center;
  border: 1px solid var(--stroke2);
  box-shadow: var(--shadow-sm);
}

.mosaic-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(0,0,0,0.05), rgba(0,0,0,0.35));
}

.mosaic-wide {
  grid-column: span 3;
}

.mosaic-tall {
  grid-row: span 2;
  height: auto;
  min-height: 310px;
}

@media (max-width: 900px) {
  .mosaic-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .mosaic-wide {
    grid-column: span 2;
  }
  .mosaic-tall {
    min-height: 220px;
  }
}

.startup-intake {
  display: grid;
  gap: 16px;
}

.startup-form {
  padding: 18px;
  border-radius: var(--r-lg);
  border: 1px solid var(--stroke);
  background: var(--glass2);
  box-shadow: var(--shadow-sm);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.startup-form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.startup-form label {
  display: grid;
  gap: 6px;
  font-size: 12px;
  color: var(--text);
  font-weight: 600;
}

.startup-form label span {
  letter-spacing: 0.2px;
}

.startup-form input,
.startup-form select {
  padding: 10px 12px;
  border-radius: var(--r-sm);
  border: 1px solid var(--stroke);
  background: var(--bg2);
  color: var(--text);
  font-size: 13px;
}

.startup-form-full {
  grid-column: 1 / -1;
}

.startup-form-actions {
  margin-top: 12px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.startup-form-note {
  font-size: 12px;
  color: var(--muted);
}

.usecase-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.usecase-card {
  padding: 16px;
  border-radius: var(--r-lg);
  border: 1px solid var(--stroke);
  background: var(--glass2);
  box-shadow: var(--shadow-sm);
  display: grid;
  gap: 8px;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.usecase-card h3 {
  margin: 0;
  font-size: 14px;
  font-weight: 800;
  min-height: 32px;
}

.usecase-card p {
  margin: 0;
  font-size: 12px;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.journey-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}

.journey-card {
  padding: 16px;
  border-radius: var(--r-lg);
  border: 1px solid var(--stroke);
  background: var(--glass2);
  box-shadow: var(--shadow-sm);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.journey-step {
  display: inline-flex;
  font-size: 12px;
  font-weight: 800;
  color: var(--brand);
  margin-bottom: 6px;
}

.journey-card h3 {
  margin: 0 0 6px;
  font-size: 14px;
  font-weight: 800;
}

.journey-card p {
  margin: 0;
  font-size: 12px;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.portfolio-card {
  padding: 16px;
  border-radius: var(--r-lg);
  border: 1px solid var(--stroke);
  background: var(--glass2);
  box-shadow: var(--shadow-sm);
  display: grid;
  gap: 6px;
  overflow: hidden;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.portfolio-cover {
  height: 120px;
  border-radius: var(--r-md);
  background-size: cover;
  background-position: center;
  border: 1px solid var(--stroke2);
  filter: saturate(1.08);
}

.portfolio-tag {
  width: fit-content;
  padding: 4px 10px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--brand) 18%, transparent);
  color: var(--brand);
  font-size: 11px;
  font-weight: 700;
}

.portfolio-card h3 {
  margin: 0;
  font-size: 14px;
  font-weight: 800;
  min-height: 32px;
}

.portfolio-card p {
  margin: 0;
  font-size: 12px;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

@media (max-width: 900px) {
  .academy-hero {
    grid-template-columns: 1fr;
  }
  .academy-hero {
    padding: 20px;
  }
  .academy-hero h1 {
    font-size: 22px;
  }
  .academy-hero .btnPrimary,
  .academy-hero .btnGhost {
    min-width: 0;
    width: 100%;
  }
  .academy-hero-actions {
    width: 100%;
  }
}

@media (max-width: 680px) {
  .academy-hero {
    padding: 18px;
  }
  .academy-hero h1 {
    font-size: 20px;
  }
  .academy-kicker {
    letter-spacing: 0.12em;
  }
  .page {
    margin-top: 18px;
    padding: 0 16px;
  }
  .pageInner {
    padding-left: 0;
    padding-right: 0;
  }
  .academy-section {
    margin-bottom: 20px;
  }
  .academy-card,
  .academy-step,
  .academy-program-card,
  .cv-card,
  .startup-card,
  .startup-form,
  .usecase-card,
  .journey-card,
  .portfolio-card {
    padding: 14px;
  }
  .program-cover,
  .portfolio-cover,
  .startup-cover,
  .cv-cover {
    height: 110px;
  }
  .mosaic-tile {
    height: 140px;
  }
  .academy-programs-grid,
  .portfolio-grid,
  .usecase-grid,
  .startup-grid,
  .cv-grid,
  .journey-grid {
    grid-template-columns: 1fr;
  }
  .mosaic-grid {
    grid-template-columns: 1fr;
  }
  .mosaic-wide {
    grid-column: span 1;
  }
  .academy-cta {
    padding: 18px;
  }
}

.gridTwo {
  display: grid;
  grid-template-columns: 35% 65%;
  gap: 20px;
  align-items: start;
}

/* colFiltersStack = colonne gauche : contient filtres + vidéo empilés */
.colFiltersStack { grid-column: 1; grid-row: 1; display: flex; flex-direction: column; gap: 14px; }
.colMap          { grid-column: 2; grid-row: 1; }

@media (max-width: 1080px) {
  .gridTwo {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  /* Empêche le chevauchement : grid-row explicite pour chaque colonne */
  .colMap          { grid-column: 1; grid-row: 1; order: 1; }
  .colFiltersStack { grid-column: 1; grid-row: 2; order: 2; }

  .cardFiltersTop .filtersGrid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Cards */
.card {
  background: var(--glass2);
  border: 1px solid var(--stroke);
  border-radius: var(--r-xl);
  padding: 18px;
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  animation: cardIn .35s ease both;
}

@keyframes cardIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Disable animation on left column cards to stabilize spacing */
.colPlot.card, .colFilters.card {
  animation: cardInFade .35s ease both;
}

@keyframes cardInFade {
  from { opacity: 0; }
  to { opacity: 1; }
}

.cardTitleWrap {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
}

.cardTitleIcon {
  width: 18px;
  height: 18px;
  color: var(--brand);
}

.cardTitle {
  font-weight: 800;
  font-size: 15px;
  letter-spacing: -0.3px;
}

.filtersToggle {
  margin-left: auto;
  display: none;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: var(--bg2);
  color: var(--text);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}

.filtersToggleIcon {
  width: 14px;
  height: 14px;
}

.filtersBody {
  display: block;
}

/* =========================
   VIDEO PLOT CARD
   ========================= */
.plotVideoCard{
  padding:0;
  overflow:hidden;
  background: transparent !important;
  min-height: 200px;
  height: auto;
}

.plotVideo{
  width:100%;
  height: 240px;
  display:block;
  object-fit: cover;
  object-position: center;
  pointer-events:none;
  user-select:none;
  background: transparent;
}

.plotVideo::-webkit-media-controls,
.plotVideo::-webkit-media-controls-panel,
.plotVideo::-webkit-media-controls-play-button,
.plotVideo::-webkit-media-controls-start-playback-button{
  display:none !important;
  -webkit-appearance:none;
}

@media (max-width: 1080px){
  .plotVideo{ height: 200px; }
}

@media (max-width: 640px){
  .plotVideo{ height: 180px; }
}

/* =========================
   QUICK ACTION BUTTONS
   ========================= */
.quickbarCard{
  background: transparent;
  border: none;
  padding: 0;
}

.quickBtns{
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
}

@media (max-width: 1024px){
  .quickBtns{ grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 640px){
  .quickBtns{ gap: 8px; }
}

.qbtn{
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  height: 40px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 12px;
  letter-spacing: .2px;
  text-decoration: none;
  outline: none;
  border: none;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  transition: all .18s ease;
  white-space: nowrap;
}

@media (max-width: 640px){
  .qbtn{
    height: 38px;
    font-size: 10px;
    gap: 5px;
    border-radius: 10px;
  }
}

html[data-theme="light"] .qbtn{
  color: #ffffff;
  background: #1E70B8;
  box-shadow: 0 4px 12px rgba(30, 112, 184, .25);
}

html[data-theme="light"] .qbtn:hover{
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(30, 112, 184, .35);
  filter: brightness(0.92);
}

html[data-theme="dark"] .qbtn{
  color: #d1e5f0;
  background: #0C304C;
  box-shadow: 0 4px 12px rgba(0, 0, 0, .4);
}

html[data-theme="dark"] .qbtn:hover{
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(12, 48, 76, .5);
  filter: brightness(1.12);
}

.qbtn:active{
  transform: translateY(0px);
  transition-duration: .1s;
}

.qbtnIcon{
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  opacity: .95;
}

@media (max-width: 640px){
  .qbtnIcon{ width: 15px; height: 15px; }
}

/* Active quickbar button */
html[data-theme="dark"]  .qbtn[aria-current="page"] { background:#1a4d70; color:#ffffff; font-weight:700; box-shadow:inset 0 0 0 2px rgba(14,165,233,.6); }
html[data-theme="light"] .qbtn[aria-current="page"] { background:#0d5fa0; color:#ffffff; font-weight:700; box-shadow:inset 0 0 0 2px rgba(13,95,160,.6); }

/* Screen-reader only utility */
.sr-only { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }

/* =========================
   PLOT CARD
   ========================= */
.cardPlot { padding: 16px; }

.plotTop {
  display: flex;
  justify-content: center;
  margin-bottom: 12px;
}

.plotCategoryBadge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: var(--bg2);
  border: 1px solid var(--stroke);
  border-radius: 999px;
  box-shadow: var(--shadow-xs);
}

.plotCatIcon {
  width: 16px;
  height: 16px;
  color: var(--brand);
}

.plotCategoryText {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.plotCanvas {
  width: 100%;
  height: 170px;
  display: block;
  border-radius: var(--r-md);
  background: var(--bg0);
  border: 1px solid var(--stroke2);
}

html[data-theme="dark"] .plotCanvas {
  background: rgba(0,0,0,.25);
}

.plotBottom {
  margin-top: 12px;
}

.plotBottomInner {
  display: flex;
  justify-content: center;
}

.plotStatBox {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  background: color-mix(in srgb, var(--brand) 8%, transparent);
  border: 1px solid color-mix(in srgb, var(--brand) 20%, transparent);
  border-radius: var(--r-lg);
}

.plotStatIcon {
  width: 28px;
  height: 28px;
  color: var(--brand);
}

.plotStatContent {
  display: flex;
  flex-direction: column;
}

.plotCount {
  font-size: 26px;
  font-weight: 900;
  letter-spacing: -1px;
  line-height: 1;
  color: var(--text);
}

.plotUnit {
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  margin-top: 2px;
}

/* =========================
   MAP CARD
   ========================= */
.cardMap { padding: 16px; }

.bsfMapWrap { position: relative; }

.bsfMap {
  width: 100%;
  height: 480px;
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 1px solid var(--stroke);
  background: var(--bg0);
}

html[data-theme="dark"] .bsfMap {
  border-color: var(--stroke);
}

.bsfHud {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  pointer-events: none;
}

.bsfHudLeft, .bsfHudRight {
  display: flex;
  align-items: center;
  gap: 8px;
}

.bsfStatus, .bsfCount {
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--bg2);
  border: 1px solid var(--stroke);
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 12px;
  font-weight: 700;
  color: var(--text);
  box-shadow: var(--shadow-xs);
}

.bsfStatus .spinIcon,
.countIcon {
  width: 14px;
  height: 14px;
  color: var(--brand);
}

.bsfLocateBtn {
  pointer-events: auto;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: var(--bg2);
  box-shadow: var(--shadow-xs);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  transition: all .18s ease;
}

.bsfLocateBtn:hover {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
  box-shadow: var(--shadow-sm);
}

.bsfLocateBtn [data-lucide] {
  width: 18px;
  height: 18px;
}

/* =========================
   MERCHANTS TABLE (REDESIGNED)
   ========================= */
.mTableWrap {
  margin-top: 16px;
}

.mTableHead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.mTableTitleWrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mTableIcon {
  width: 18px;
  height: 18px;
  color: var(--brand);
}

.mTableTitle {
  font-weight: 800;
  font-size: 14px;
  letter-spacing: -0.3px;
  color: var(--text);
}

.mTableHint {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 10px;
  font-weight: 700;
  color: var(--brand);
  padding: 5px 10px;
  background: color-mix(in srgb, var(--brand) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--brand) 25%, transparent);
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.hintIcon {
  width: 12px;
  height: 12px;
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: .5; }
}

.mTableScroll {
  border-radius: var(--r-md);
  border: 1px solid var(--stroke);
  background: var(--bg2);
  overflow: hidden;
  height: 320px;
  overflow-y: auto;
}

.mTable {
  width: 100%;
  border-collapse: collapse;
  font-size: 11px;
  table-layout: fixed;
}

.mTable thead th {
  position: sticky;
  top: 0;
  text-align: left;
  padding: 10px 10px;
  font-weight: 700;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--muted);
  background: var(--bg1);
  border-bottom: 1px solid var(--stroke);
  white-space: nowrap;
}

.mTable thead th > span,
.mTable thead th > i {
  vertical-align: middle;
}

.thIcon {
  width: 12px;
  height: 12px;
  margin-right: 4px;
  opacity: .7;
  vertical-align: middle;
}

.mTable tbody td {
  padding: 9px 10px;
  border-bottom: 1px solid var(--stroke2);
  vertical-align: middle;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--text2);
}

.mRow {
  transition: background .15s ease;
}

.mRow:hover {
  background: color-mix(in srgb, var(--brand) 6%, transparent);
}

.mRow:last-child td {
  border-bottom: none;
}

.mName {
  font-weight: 700;
  color: var(--text);
  font-size: 11px;
}

.mCategory {
  font-weight: 600;
  color: var(--muted);
  font-size: 10px;
}

.mStatus {
  text-align: center;
}

.mStatusBadge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.2px;
}

.mStatusOk {
  background: color-mix(in srgb, #10b981 18%, transparent);
  border: 1px solid color-mix(in srgb, #10b981 42%, transparent);
  color: #047857;
}

html[data-theme="dark"] .mStatusOk {
  color: #6ee7b7;
}

.mStatusMuted {
  background: color-mix(in srgb, var(--muted) 15%, transparent);
  border: 1px solid color-mix(in srgb, var(--muted) 30%, transparent);
  color: var(--muted);
}

.mClaimBtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  padding: 2px 10px;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--accent) 45%, transparent);
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  color: var(--accent);
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.25px;
  text-decoration: none;
}

.mClaimBtn:hover {
  filter: brightness(1.05);
  border-color: var(--accent);
}

.mProduct {
  font-weight: 500;
  color: var(--muted2);
  font-size: 10px;
}

.mDiscount {
  font-weight: 700;
  color: var(--brand);
  font-size: 10px;
}

.mPrice {
  font-weight: 600;
  color: var(--text2);
  font-size: 10px;
}

.mDate {
  font-weight: 500;
  color: var(--muted2);
  font-size: 10px;
}

.mTableEmpty {
  text-align: center;
  padding: 24px 12px !important;
  color: var(--muted);
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.mTableEmpty .spinIcon {
  width: 16px;
  height: 16px;
}

/* =========================
   FILTERS CARD
   ========================= */
.cardFilters { padding: 16px; }

.cardFiltersTop {
  margin-bottom: 12px;
}

.filtersGrid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.cardFiltersTop .filtersGrid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  align-items: end;
}

.filterBlock {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.filterLabel {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.filterLabelIcon {
  width: 13px;
  height: 13px;
  opacity: .7;
}

.selectWrap {
  position: relative;
}

.filterInput {
  width: 100%;
  height: 42px;
  border-radius: var(--r-sm);
  border: 1px solid var(--stroke);
  background: var(--bg2);
  color: var(--text);
  padding: 0 36px 0 12px;
  font-size: 13px;
  font-weight: 600;
  outline: none;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  transition: all .18s ease;
}

.filterInput:hover {
  border-color: var(--brand);
}

.filterInput:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 15%, transparent);
}

.filterInput:disabled {
  opacity: .5;
  cursor: not-allowed;
}

.selectArrow {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  color: var(--muted);
  pointer-events: none;
}

.filtersActions {
  margin-top: 14px;
}

.cardFiltersTop .filtersActions {
  margin-top: 0;
}

.filtersActionsInline .btnFull {
  width: 100%;
  height: 42px;
}

/* =========================
   FOOTER
   ========================= */
.footer {
  margin-top: 32px;
  padding: 20px 16px 28px;
  text-align: center;
}

.footerInner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.footerText {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
}

.footerIcon {
  width: 13px;
  height: 13px;
  opacity: .7;
}

.footerDot {
  color: var(--muted2);
  font-size: 10px;
}

/* =========================
   MOBILE TWEAKS
   ========================= */
@media (max-width: 680px) {
  .topbar { padding: 0 10px; top: 6px; }
  .topbar .wrap { padding: 4px 8px; gap: 5px; }

  .logoRing { width: 32px; height: 32px; }
  .brandName { font-size: 13px; }
  .statsBadge { display: none; }

  .btn, .iconBtn { height: 32px; }
  .btn { padding: 0 10px; font-size: 11px; }
  .iconBtn { width: 32px; }

  .page { padding: 0 10px; }
  .pageLayout { padding-top: 14px; gap: 12px; }
  .gridTwo { gap: 12px; }
  .homeIntro { padding: 12px 14px; }
  .homeLead { font-size: 13px; }

  .card { padding: 14px; border-radius: var(--r-lg); }

  .plotCanvas { height: 140px; }
  .plotCount { font-size: 22px; }
  .plotStatBox { padding: 10px 16px; }
  .plotStatIcon { width: 24px; height: 24px; }

  .bsfMap { height: 340px; border-radius: var(--r-md); }
  .bsfStatus, .bsfCount { padding: 6px 10px; font-size: 11px; }
  .bsfLocateBtn { width: 34px; height: 34px; }

  .mTableScroll { max-height: 260px; }
  .mTable { font-size: 10px; }
  .mTable thead th { padding: 8px 8px; font-size: 9px; }
  .mTable tbody td { padding: 7px 8px; }

  .filterInput { height: 38px; font-size: 12px; }

  .cardFiltersTop .filtersGrid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .mosaic-grid.is-slider {
    display: flex;
    gap: 0;
    overflow: hidden;
  }

  .mosaic-grid.is-slider .mosaic-tile {
    flex: 0 0 100%;
    height: 190px;
    min-height: 0;
    display: none;
  }

  .mosaic-grid.is-slider .mosaic-tile.is-active {
    display: block;
  }
}

@media (max-width: 860px) {
  /* Filters are no longer sticky — they sit below the map in normal flow */
  .cardFilters {
    position: static;
  }

  .filtersToggle { display: inline-flex; }

  .cardFilters[data-open="false"] .filtersBody {
    display: none;
  }
}

/* colMap row 1 + colFiltersStack row 2 définis dans le bloc 1080px ci-dessus */

/* =========================
   RTL SUPPORT
   ========================= */
html[dir="rtl"] .topbar .wrap { direction: rtl; }
html[dir="rtl"] .menu { left: 0; right: auto; }
html[dir="rtl"] .mTable thead th { text-align: right; }
html[dir="rtl"] .mTable tbody td { text-align: right; }
html[dir="rtl"] .thIcon { margin-right: 0; margin-left: 4px; }
html[dir="rtl"] .selectArrow { right: auto; left: 12px; }
html[dir="rtl"] .filterInput { padding: 0 12px 0 36px; }

/* =========================
   LEAFLET CUSTOMIZATION
   ========================= */
.leaflet-popup-content-wrapper {
  border-radius: var(--r-md) !important;
  box-shadow: var(--shadow-sm) !important;
}

.leaflet-popup-content {
  margin: 12px 14px !important;
  font-family: Inter, system-ui, sans-serif !important;
  font-size: 12px !important;
  font-weight: 600 !important;
}

.bsf-tooltip-wrap {
  background: var(--bg2) !important;
  color: var(--text) !important;
  border: 1px solid var(--stroke) !important;
  border-radius: var(--r-sm) !important;
  padding: 8px 12px !important;
  font-size: 11px !important;
  font-weight: 600 !important;
  box-shadow: var(--shadow-xs) !important;
}

.bsf-tooltip-wrap::before {
  border-top-color: var(--bg2) !important;
}

/* Scrollbar styling */
.mTableScroll::-webkit-scrollbar,
.menu::-webkit-scrollbar {
  width: 6px;
}

.mTableScroll::-webkit-scrollbar-track,
.menu::-webkit-scrollbar-track {
  background: transparent;
}

.mTableScroll::-webkit-scrollbar-thumb,
.menu::-webkit-scrollbar-thumb {
  background: var(--muted2);
  border-radius: 3px;
}

.mTableScroll::-webkit-scrollbar-thumb:hover,
.menu::-webkit-scrollbar-thumb:hover {
  background: var(--muted);
}

/* === Merchants table : 4 columns full width === */
.mTable {
  table-layout: fixed;
  width: 100%;
}

.mTable th,
.mTable td {
  width: 25%;
}

/* alignement spécifique */
.mTable th:nth-child(3),
.mTable td:nth-child(3) {
  text-align: center;
}

.mTable th:nth-child(4),
.mTable td:nth-child(4) {
  text-align: center;
}

/* =========================
   TOPBAR WIDGET BUTTONS
   ========================= */
.tbar-widget-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 40px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: var(--glass2);
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: all .18s ease;
  box-shadow: var(--shadow-xs);
}

.tbar-widget-btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
  border-color: var(--accent);
  color: var(--accent);
}

.tbar-widget-btn[aria-expanded="true"] {
  background: color-mix(in srgb, var(--accent) 12%, var(--bg2));
  border-color: var(--accent);
  color: var(--accent);
}

@media (max-width: 580px) {
  .tbar-widget-btn { width: 40px; padding: 0; justify-content: center; }
  .tbar-widget-btn .hideOnMobile { display: none !important; }
}

/* ══════════════════════════════════════════════════════════════
   Grace Period Banner — Redesigned 2026-03-03
   Always uses brand-dark gradient (promotional standout element)
   ══════════════════════════════════════════════════════════════ */
.graceBanner {
  background: linear-gradient(108deg,
    #082640 0%,
    #0c3f65 40%,
    #0a3254 70%,
    #071e35 100%);
  border-bottom: 1px solid rgba(77,158,208,.25);
  padding: 14px 20px;
  position: relative;
  z-index: 90;
  overflow: hidden;
}

/* Subtle sheen overlay */
.graceBanner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 60% 120% at 80% -10%,
    rgba(77,158,208,.18) 0%, transparent 65%);
  pointer-events: none;
}

.graceBannerInner {
  max-width: 1260px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  position: relative;
}

/* ── Left block: badge + content ─────────────────────── */
.graceBannerLeft {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  flex: 1;
  min-width: 240px;
}

.graceBannerBadge {
  flex-shrink: 0;
  font-size: 22px;
  line-height: 1;
  filter: drop-shadow(0 2px 6px rgba(77,158,208,.5));
  margin-top: 2px;
}

.graceBannerContent {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.graceBannerHeadline {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  color: #cde3f5;
  line-height: 1.45;
}

.graceBannerHeadline strong {
  color: #ffffff;
  font-weight: 800;
}

.graceBannerHeadline .gbHighlight {
  color: #63c3f5;
  font-weight: 800;
}

/* ── Plan pills row ──────────────────────────────────── */
.graceBannerPlans {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  align-items: center;
}

.gbPill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .01em;
  border: 1px solid rgba(77,158,208,.22);
  background: rgba(77,158,208,.08);
  color: #8cc9e8;
  white-space: nowrap;
  transition: all .15s;
}

.gbPill.gbPillFree {
  border-color: rgba(74,222,128,.3);
  background: rgba(74,222,128,.1);
  color: #6ee7b7;
}

.gbPill.gbPillActive {
  border-color: rgba(251,191,36,.4);
  background: rgba(251,191,36,.14);
  color: #fcd34d;
  font-weight: 800;
}

/* ── CTA actions ─────────────────────────────────────── */
.graceBannerActions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  flex-wrap: wrap;
}

/* Primary CTA button */
.gbBtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 36px;
  padding: 0 16px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  font-family: inherit;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  border: none;
  transition: all .18s ease;
  letter-spacing: .01em;
}

.gbBtnPrimary {
  background: #1E70B8;
  color: #fff;
  box-shadow: 0 2px 12px rgba(30,112,184,.45);
}

.gbBtnPrimary:hover {
  background: #1a60a0;
  box-shadow: 0 4px 18px rgba(30,112,184,.6);
  transform: translateY(-1px);
  color: #fff;
}

.gbBtnGhost {
  background: rgba(255,255,255,.08);
  color: #cde3f5;
  border: 1.5px solid rgba(77,158,208,.35);
  backdrop-filter: blur(8px);
}

.gbBtnGhost:hover {
  background: rgba(77,158,208,.18);
  border-color: rgba(77,158,208,.6);
  color: #fff;
  transform: translateY(-1px);
}

/* Close button */
.graceBannerClose {
  flex-shrink: 0;
  background: none;
  border: none;
  color: rgba(255,255,255,.3);
  font-size: 20px;
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 6px;
  line-height: 1;
  transition: color .15s, background .15s;
  align-self: flex-start;
}
.graceBannerClose:hover {
  color: rgba(255,255,255,.8);
  background: rgba(255,255,255,.08);
}

/* ── Light theme override ────────────────────────────── */
html:not([data-theme="dark"]) .graceBanner {
  background: linear-gradient(108deg,
    #0C304C 0%,
    #1a5080 38%,
    #1E70B8 100%);
  border-bottom-color: rgba(30,112,184,.3);
}

html:not([data-theme="dark"]) .graceBanner::before {
  background: radial-gradient(ellipse 50% 100% at 95% -20%,
    rgba(255,255,255,.12) 0%, transparent 60%);
}

/* ── Responsive ──────────────────────────────────────── */
@media (max-width: 768px) {
  .graceBanner { padding: 12px 14px; }
  .graceBannerActions { width: 100%; }
  .gbBtn { flex: 1; justify-content: center; }
  .gbPill { font-size: 10px; padding: 2px 8px; }
}

@media (max-width: 480px) {
  .graceBannerLeft { flex-wrap: wrap; }
  .graceBannerBadge { font-size: 18px; }
  .graceBannerHeadline { font-size: 12px; }
}

/* ── Footer link-buttons ─────────────────────────────── */
.footerBtn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 14px;
  border-radius: 999px;
  border: 1px solid var(--stroke2);
  background: transparent;
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  text-decoration: none;
  transition: all .15s ease;
  white-space: nowrap;
  font-family: inherit;
  cursor: pointer;
}
.footerBtn:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 6%, transparent);
}

/* ── Lock badge for premium features (map popup) ──────────────── */
.bsf-lock-hint {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: #94a3b8;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 6px;
  padding: 3px 8px;
  margin-top: 4px;
  text-decoration: none;
  white-space: nowrap;
}
.bsf-lock-hint:hover { border-color: #0ea5e9; color: #38bdf8; }
.rowMiddle {
  overflow: hidden;
  position: relative;
  border-radius: 16px;
  border: 1px solid var(--stroke);
  background-color: #0D1B2E;
  background-image:
    linear-gradient(rgba(175, 186, 199, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(175, 186, 199, 0.08) 1px, transparent 1px);
  background-size: 34px 34px, 34px 34px, auto;
  box-shadow: var(--shadow-sm);
  animation: cardInFade .4s ease both;
  width: 100%;
}

@media (max-width: 768px) {
  .rowMiddle { border-radius: 12px; height: 180px !important; }
}

.rowMiddle::before,
.rowMiddle::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.rowMiddle::before {
  background:
    repeating-linear-gradient(
      90deg,
      transparent 0 24px,
      rgba(201, 216, 230, 0.1) 24px 25px,
      transparent 25px 48px
    ),
    repeating-linear-gradient(
      0deg,
      transparent 0 24px,
      rgba(158, 170, 184, 0.1) 24px 25px,
      transparent 25px 48px
    );
  mix-blend-mode: screen;
  opacity: 0.45;
}

.rowMiddle::after {
  background: linear-gradient(
    180deg,
    transparent 0%,
    rgba(188, 204, 218, 0.2) 48%,
    transparent 100%
  );
  height: 30%;
  transform: translateY(-100%);
  animation: scanline 3.2s linear infinite;
  opacity: 0.45;
}

@keyframes scanline {
  0% { transform: translateY(-100%); }
  100% { transform: translateY(340%); }
}

.plotCanvas {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  mix-blend-mode: screen;
  filter: saturate(1.18) contrast(1.06);
}

.plotFxCanvas {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  pointer-events: none;
  mix-blend-mode: screen;
}

/* =========================
   PLOT UI ELEMENTS
   ========================= */
.dashboardContainer {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
  margin-bottom: 1rem;
}

.dashboardPanel {
  position: relative;
  border: 1px solid var(--stroke, rgba(175, 186, 199, 0.28));
  background: var(--card, rgba(26, 47, 79, 0.62));
  backdrop-filter: blur(14px);
  border-radius: 12px;
  box-shadow: var(--shadow-sm, 0 4px 12px rgba(10, 20, 37, 0.55));
}

.rowTop,
.rowBottom {
  min-height: 70px;
  display: flex;
  align-items: center;
  padding: 0 14px;
}

.rowTop {
  justify-content: space-between;
  gap: 14px;
}

.badgeStack {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  width: 100%;
}

.categoryBadge {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--stroke, rgba(175, 186, 199, 0.28));
  border-radius: 10px;
  background: rgba(18, 33, 58, 0.55);
  padding: 8px 12px;
  width: 100%;
  min-width: 0;
  transition: border-color 0.24s ease, box-shadow 0.24s ease;
}

.catIcon {
  width: 20px;
  height: 20px;
  color: #BCCCDA;
  flex-shrink: 0;
}

.catTextWrap {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.catLabel {
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #AFBAC7;
}

.catText {
  margin-top: 2px;
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: clamp(0.9rem, 1.5vw, 1.2rem);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #DDE2E8;
}

.speedBadge {
  flex-shrink: 0;
  border: 1px solid rgba(188, 204, 218, 0.5);
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #DDE2E8;
  text-transform: uppercase;
  background: rgba(26, 47, 79, 0.72);
}

.rowBottom {
  justify-content: space-between;
  gap: 14px;
}

.statBox {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid var(--stroke, rgba(175, 186, 199, 0.28));
  background: rgba(18, 33, 58, 0.62);
  min-width: 0;
}

.statIcon {
  width: 20px;
  height: 20px;
  color: #C9D8E6;
  flex-shrink: 0;
}

.statContent {
  display: flex;
  align-items: baseline;
  gap: 8px;
  min-width: 0;
}

.statCount {
  font-family: 'Inter', sans-serif;
  font-size: clamp(1.1rem, 2vw, 1.6rem);
  font-weight: 800;
  line-height: 1;
  color: #DDE2E8;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

.statUnit {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #AFBAC7;
}

.hint {
  margin-left: auto;
  color: #BCCCDA;
  font-size: 11px;
  letter-spacing: 0.03em;
  text-align: right;
}

@media (max-width: 920px) {
  .rowTop, .rowBottom { flex-wrap: wrap; padding: 10px; }
  .speedBadge { order: 3; }
  .hint { width: 100%; text-align: left; margin-left: 0; margin-top: 8px;}
}

/* ════════════════════════════════════════════════════════════════════════
   DASHBOARD — Light Mode Premium  (applies when NOT dark)
   All hardcoded dark-navy values overridden for a luminous glass aesthetic
   ════════════════════════════════════════════════════════════════════════ */

html:not([data-theme="dark"]) .dashboardContainer {
  /* Ambient background decoration under the entire container */
  position: relative;
}

/* ── Panel shells ──────────────────────────────────────────────────────── */
html:not([data-theme="dark"]) .dashboardPanel,
html:not([data-theme="dark"]) .panel {
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(28px) saturate(200%);
  -webkit-backdrop-filter: blur(28px) saturate(200%);
  border: 1px solid rgba(30, 112, 184, 0.11);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 1),
    0 2px 0 rgba(30, 112, 184, 0.04),
    0 8px 32px rgba(12, 48, 76, 0.07),
    0 2px 8px rgba(12, 48, 76, 0.04);
}

/* ── Category badge ───────────────────────────────────────────────────── */
html:not([data-theme="dark"]) .categoryBadge {
  background: rgba(246, 250, 255, 0.78);
  border: 1px solid rgba(30, 112, 184, 0.13);
  box-shadow: 0 2px 12px rgba(30, 112, 184, 0.06);
}

html:not([data-theme="dark"]) .catIcon {
  color: #1E70B8;
}

html:not([data-theme="dark"]) .catLabel {
  color: #5A7A90;
  letter-spacing: 0.12em;
}

html:not([data-theme="dark"]) .catText {
  color: #0C304C;
}

/* ── Speed badge ──────────────────────────────────────────────────────── */
html:not([data-theme="dark"]) .speedBadge {
  background: linear-gradient(130deg,
    rgba(30, 112, 184, 0.10) 0%,
    rgba(12, 61, 110, 0.07) 100%);
  border: 1.5px solid rgba(30, 112, 184, 0.22);
  color: #1258A0;
  font-weight: 800;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 2px 10px rgba(30, 112, 184, 0.09);
}

/* ── Stat box ─────────────────────────────────────────────────────────── */
html:not([data-theme="dark"]) .statBox {
  background: rgba(246, 250, 255, 0.78);
  border: 1px solid rgba(30, 112, 184, 0.11);
  box-shadow: 0 2px 14px rgba(12, 48, 76, 0.06);
}

html:not([data-theme="dark"]) .statIcon {
  color: #1E70B8;
}

html:not([data-theme="dark"]) .statCount {
  /* Gradient text — dark navy → electric blue */
  background: linear-gradient(130deg, #0C304C 20%, #1E70B8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: transparent; /* fallback */
}

html:not([data-theme="dark"]) .statUnit {
  color: #5A7A90;
}

/* ── Hint text ────────────────────────────────────────────────────────── */
html:not([data-theme="dark"]) .hint {
  color: #7FA8C4;
}

/* ── Canvas viewport (rowMiddle): intentionally dark in light mode ────
   The canvas uses alpha:false (opaque black backing) + mix-blend-mode:screen.
   Keeping it dark ensures dots remain visible via screen blending.
   The dark data-viewport framed by light panels is a deliberate premium
   design choice (Grafana, Bloomberg, Tableau light themes). ────────── */
html:not([data-theme="dark"]) .rowMiddle {
  background-color: #08131F;
  background-image:
    linear-gradient(rgba(77, 158, 208, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(77, 158, 208, 0.07) 1px, transparent 1px);
  border: 1px solid rgba(30, 112, 184, 0.22);
  box-shadow:
    inset 0 0 60px rgba(0, 0, 0, 0.35),
    0 0 0 1px rgba(77, 158, 208, 0.1),
    0 4px 24px rgba(0, 0, 0, 0.18);
}
