/* =========================
   BSF ACADEMY • Modern Design System
   Version 2.0 - January 2026
   Based on app.css - Blue Night Theme
   ========================= */

/* 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;
  overflow-x: hidden;
}

/* =========================
   DESIGN TOKENS
   ========================= */
:root {
  --max: 1320px;
  --page-pad: 24px;
  --page-max: 1440px;
  --quickbar-max: 1100px;

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

  --brand: #0C304C;
  --brand-dark: #091E33;
  --brand-light: #1A4A6E;
  --accent: #1E70B8;
  --cta-primary: #1E70B8;
  --cta-secondary: #0C304C;
  --cta-warning: #C2820A;

  --glass: rgba(255,255,255,.88);
  --glass2: rgba(255,255,255,.96);
  --stroke: rgba(12,48,76,.12);
  --stroke2: rgba(12,48,76,.07);
  --border: rgba(12,48,76,.10);

  --text: #1A2D42;
  --text2: #0C304C;
  --text-heading: #0C304C;
  --text-on-dark: #E8EDF2;
  --muted: #6B7A8D;
  --muted2: #8A97A6;
  --nav-text: #4A6080;

  --shadow: 0 20px 60px rgba(20,30,50,.12);
  --shadow-sm: 0 8px 24px rgba(20,30,50,.08);
  --shadow-xs: 0 4px 12px rgba(20,30,50,.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: #102840;
  --surface: #19334E;

  --brand: #4D9ED0;
  --brand-dark: #0B1E33;
  --brand-light: #1E70B8;
  --accent: #4D9ED0;
  --cta-primary: #4D9ED0;
  --cta-secondary: #4D9ED0;
  --cta-warning: #D4920E;

  --glass: rgba(11,30,51,.90);
  --glass2: rgba(16,40,64,.96);
  --stroke: rgba(77,158,208,.16);
  --stroke2: rgba(77,158,208,.08);
  --border: rgba(77,158,208,.12);

  --text: #E8EDF2;
  --text2: #E8EDF2;
  --text-heading: #FFFFFF;
  --text-on-dark: #E8EDF2;
  --muted: #8A97A6;
  --muted2: #6B7A8D;
  --nav-text: #8A97A6;

  --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;
}

/* =========================
   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 4px 12px rgba(12,48,76,.20);
}

.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;
  box-shadow: 0 4px 16px rgba(30,112,184,.25);
}

.btnPrimary:hover {
  background: var(--brand);
  border-color: var(--brand);
  box-shadow: 0 6px 20px rgba(12,48,76,.30);
  border-color: color-mix(in srgb, var(--cta-primary) 80%, var(--brand));
}

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

/* Topbar widget buttons (Chat) */
.tbar-widget-btn {
  transition: all .18s ease;
}
.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;
  }
}

.btnLogout {
  border-color: #B91C1C;
  color: #B91C1C;
}

.btnLogout:hover {
  border-color: #991B1B;
  color: #991B1B;
  background: color-mix(in srgb, #B91C1C 8%, var(--bg2));
}

.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 {
  max-width: var(--max);
  margin: 24px auto 0;
  padding: 0 24px;
}

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

.quickbarInner{
  max-width: var(--quickbar-max);
  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; }
}

.gridTwo {
  display: grid;
  grid-template-columns: 38% 62%;
  grid-template-rows: auto auto;
  align-items: start;
  column-gap: 20px;
  row-gap: 24px;
}

.colPlot { grid-column: 1; grid-row: 1; }
.colFilters { grid-column: 1; grid-row: 2; }
.colMap { grid-column: 2; grid-row: 1 / span 2; }

@media (max-width: 1080px) {
  .gridTwo {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
    column-gap: 12px;
    row-gap: 12px;
  }
  .colPlot { grid-column: 1; grid-row: auto; order: 1; }
  .colMap { grid-column: 1; grid-row: auto; order: 2; }
  .colFilters { grid-column: 1; grid-row: auto; order: 3; }
}

/* 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(4, minmax(0, 1fr));
  gap: 10px;
}

@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: var(--brand);
  box-shadow: 0 4px 12px rgba(12, 48, 76, .25);
}

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

html[data-theme="dark"] .qbtn{
  color: #E8EDF2;
  background: var(--brand-light);
  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(30, 58, 95, .35);
  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; }
}

/* =========================
   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;
}

.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; }

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

.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;
}

/* =========================
   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: 6px; }

  .logoRing { width: 32px; height: 32px; }
  .brandText { display: none; }

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

  .page { padding: 0 14px; margin-top: 18px; }
  .gridTwo { gap: 14px; }

  .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; }

  .home-hero { padding: 22px; }
  .home-hero h1 { font-size: 22px; }
  .section-hero { padding: 22px; }
  .section-hero h1 { font-size: 22px; }

  .story-band,
  .contact-slab {
    grid-template-columns: 1fr;
    padding: 20px;
  }

  .contact-slab-actions {
    justify-content: flex-start;
  }

  .gallery-grid {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 12px;
    padding-bottom: 6px;
    -webkit-overflow-scrolling: touch;
  }

  .gallery-item {
    min-width: 72vw;
    flex: 0 0 auto;
    scroll-snap-align: start;
  }
}

@media (max-width: 860px) {
  .cardFilters {
    position: sticky;
    top: 0px;
    z-index: 900;
  }

  .filtersToggle { display: inline-flex; }

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

/* =========================
   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 : 3 columns full width === */
.mTable {
  table-layout: fixed;
  width: 100%;
}

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

/* alignement specifique */
.mTable th:nth-child(3),
.mTable td:nth-child(3) {
  text-align: center; /* Discount centre */
}

/* =========================
   FORMATIONS GRID (BSF Tunisie specific)
   ========================= */
.formations-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
  margin-top: 24px;
}

.formation-card {
  background: var(--glass2);
  border: 1px solid var(--stroke);
  border-radius: var(--r-xl);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: all .25s ease;
}

.mission-hero {
  position: relative;
  padding: 42px;
  border-radius: var(--r-xl);
  margin: 8px 0 28px;
  background:
    linear-gradient(120deg, rgba(4, 20, 40, 0.88), rgba(4, 20, 40, 0.55)),
    url('../wp-content/uploads/2025/12/young-woman-presenting-on-digital-evolution-concepts-1024x684.jpeg') center/cover no-repeat;
  color: #fff;
  box-shadow: var(--shadow);
}

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

.mission-hero p {
  margin: 0 0 18px 0;
  color: rgba(255,255,255,0.85);
  max-width: 760px;
}

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

.section-hero {
  padding: 34px;
  border-radius: var(--r-xl);
  margin: 8px 0 28px;
  background: var(--glass2);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-sm);
}

.section-hero h1 {
  margin: 0 0 8px;
  font-size: 26px;
  font-weight: 900;
  letter-spacing: -0.4px;
}

.section-hero p {
  margin: 0 0 16px;
  color: var(--muted);
}

.home-hero {
  padding: 34px;
  border-radius: var(--r-xl);
  margin: 8px 0 24px;
  background: linear-gradient(120deg, rgba(7, 24, 46, 0.92), rgba(7, 24, 46, 0.65));
  color: #fff;
  box-shadow: var(--shadow);
}

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

.home-hero p {
  margin: 0 0 18px;
  color: rgba(255,255,255,0.85);
  max-width: 720px;
}

.home-hero-skill {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr);
  align-items: center;
  gap: 18px;
  padding: 24px 28px;
  height: 380px;
  max-height: 400px;
  overflow: hidden;
  background: rgba(12,48,76,0.92);
  border: 1px solid rgba(134,159,157,.45);
  color: var(--text-on-dark);
}

.home-hero-skill::before {
  content: "";
  position: absolute;
  inset: -40% -10% auto auto;
  width: 420px;
  height: 420px;
  background: radial-gradient(circle at 50% 50%, rgba(30,112,184,0.12), transparent 70%);
  opacity: .85;
  pointer-events: none;
  filter: blur(4px);
}

.home-hero-skill > * {
  position: relative;
  z-index: 1;
}

.home-hero-skill h1 {
  color: var(--text-on-dark);
  font-size: clamp(22px, 2.4vw, 34px);
  line-height: 1.15;
}

.home-hero-skill p {
  color: color-mix(in srgb, var(--text-on-dark) 90%, transparent);
  max-width: 560px;
  font-size: 15px;
}

.home-hero-content {
  max-width: 760px;
}

.home-hero-media {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 0;
  min-width: 0;
  height: 100%;
}

.home-hero-media img {
  width: 100%;
  height: 100%;
  max-width: 520px;
  max-height: 320px;
  object-fit: cover;
  object-position: center top;
  border-radius: var(--r-lg);
  border: 1px solid var(--stroke2);
  box-shadow: var(--shadow);
}

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

@media (max-width: 980px) {
  .home-hero-skill {
    grid-template-columns: 1fr;
    height: 360px;
    max-height: 400px;
    padding: 20px;
  }
  .home-hero-media img {
    max-width: 460px;
    max-height: 220px;
  }
}

@media (max-width: 640px) {
  .home-hero-skill {
    padding: 18px;
    gap: 12px;
  }
  .home-hero-skill h1 {
    font-size: 22px;
  }
  .home-hero-skill p {
    font-size: 14px;
  }
}

.home-links {
  margin: 8px 0 32px;
}

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

.home-link-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-decoration: none;
  padding: 18px;
  border-radius: var(--r-lg);
  border: 1px solid var(--stroke);
  background: var(--glass2);
  box-shadow: var(--shadow-sm);
  color: var(--text);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.home-link-card span {
  font-size: 12px;
  color: var(--muted);
}

.home-link-card strong {
  font-size: 14px;
  font-weight: 800;
}

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

.badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0 0;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.2px;
  border: 1px solid var(--stroke);
  background: var(--bg2);
  color: var(--text2);
}

.badge.primary {
  background: color-mix(in srgb, var(--cta-primary) 18%, var(--bg2));
  border-color: color-mix(in srgb, var(--cta-primary) 50%, var(--stroke));
  color: #0C304C;
}

.badge.secondary {
  background: color-mix(in srgb, var(--cta-secondary) 16%, var(--bg2));
  border-color: color-mix(in srgb, var(--cta-secondary) 50%, var(--stroke));
  color: var(--brand);
}

.badge.warning {
  background: color-mix(in srgb, var(--cta-warning) 18%, var(--bg2));
  border-color: color-mix(in srgb, var(--cta-warning) 55%, var(--stroke));
  color: #213743;
}

.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0 18px;
}

.filter-chip {
  border: 1px solid var(--stroke);
  background: var(--bg2);
  color: var(--text2);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}

.filter-chip[data-active="true"] {
  border-color: var(--cta-secondary);
  color: var(--cta-secondary);
  box-shadow: var(--shadow-xs);
}

.story-band {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 20px;
  padding: 28px;
  border-radius: var(--r-xl);
  background: linear-gradient(120deg, rgba(9, 22, 41, 0.95), rgba(9, 22, 41, 0.6));
  color: #fff;
  box-shadow: var(--shadow);
  margin: 10px 0 28px;
}

.story-kicker {
  font-size: 11px;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.7);
  font-weight: 700;
}

.story-title {
  margin: 6px 0 10px;
  font-size: 24px;
  font-weight: 900;
  letter-spacing: -0.4px;
}

.story-text {
  margin: 0 0 18px;
  color: rgba(255,255,255,0.85);
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.chip {
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.2);
  color: #fff;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
}

.story-side {
  display: grid;
  gap: 12px;
}

.story-tile {
  padding: 14px;
  border-radius: var(--r-lg);
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.18);
}

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

.story-tile p {
  margin: 0;
  font-size: 12px;
  color: rgba(255,255,255,0.78);
}

.insight-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin: 8px 0 28px;
}

.insight-card {
  padding: 18px;
  border-radius: var(--r-lg);
  border: 1px solid var(--stroke);
  background: var(--glass2);
  box-shadow: var(--shadow-sm);
}

.insight-card h4 {
  margin: 0 0 8px;
  font-size: 14px;
  font-weight: 800;
}

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

.value-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  padding: 18px;
  border-radius: var(--r-xl);
  background: var(--glass2);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-sm);
  margin: 6px 0 28px;
}

.value-pill {
  padding: 12px;
  border-radius: var(--r-md);
  background: rgba(9, 22, 41, 0.06);
  border: 1px dashed var(--stroke);
  font-size: 12px;
  font-weight: 700;
  color: var(--text2);
}

.contact-slab {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 16px;
  align-items: center;
  padding: 24px;
  border-radius: var(--r-xl);
  background: linear-gradient(120deg, rgba(16, 34, 60, 0.92), rgba(16, 34, 60, 0.6));
  color: #fff;
  box-shadow: var(--shadow);
  margin: 16px 0 12px;
}

.contact-slab p {
  margin: 0;
  color: rgba(255,255,255,0.85);
}

.contact-slab-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.timeline-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
  margin: 10px 0 26px;
}

.timeline-card {
  padding: 16px;
  border-radius: var(--r-lg);
  background: var(--glass2);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-sm);
}

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

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

.proof-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin: 8px 0 24px;
}

.proof-card {
  padding: 14px;
  border-radius: var(--r-md);
  background: rgba(9, 22, 41, 0.06);
  border: 1px solid var(--stroke);
  font-size: 12px;
  color: var(--text2);
}

.quote-strip {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  padding: 18px;
  border-radius: var(--r-xl);
  background: var(--glass2);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-sm);
  margin: 8px 0 26px;
}

.quote-strip blockquote {
  margin: 0;
  font-size: 13px;
  color: var(--text2);
}

.quote-strip span {
  font-size: 12px;
  color: var(--muted);
}

.detail-card {
  padding: 20px;
  border-radius: var(--r-lg);
  background: var(--glass2);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-sm);
  line-height: 1.7;
  color: var(--text2);
}

.detail-card p {
  margin: 0 0 12px;
}

.media-gallery {
  margin: 18px 0 10px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.media-card {
  border-radius: var(--r-md);
  overflow: hidden;
  border: 1px solid var(--stroke);
  background: var(--bg2);
  box-shadow: var(--shadow-xs);
}

.media-card img,
.media-card video {
  width: 100%;
  display: block;
}


.pack-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin: 8px 0 28px;
}

.pack-card {
  padding: 18px;
  border-radius: var(--r-lg);
  border: 1px solid var(--stroke);
  background: var(--glass2);
  box-shadow: var(--shadow-sm);
  position: relative;
}

.pack-card .tag {
  position: absolute;
  top: 14px;
  right: 14px;
  background: color-mix(in srgb, var(--cta-secondary) 15%, var(--bg2));
  color: var(--brand);
  border: 1px solid var(--cta-secondary);
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
  padding: 4px 8px;
}

.pack-card h4 {
  margin: 0 0 8px;
  font-size: 16px;
  font-weight: 900;
}

.pack-price {
  font-size: 22px;
  font-weight: 900;
  color: var(--brand);
  margin: 0 0 8px;
}

.pack-card ul {
  margin: 0 0 12px;
  padding-left: 18px;
  color: var(--text2);
  font-size: 12px;
}

.sector-cta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin: 8px 0 24px;
}

.sector-cta {
  text-decoration: none;
  padding: 14px;
  border-radius: var(--r-md);
  border: 1px solid var(--stroke);
  background: var(--glass2);
  color: var(--text);
  box-shadow: var(--shadow-xs);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.sector-cta strong {
  display: block;
  font-size: 13px;
  font-weight: 800;
  margin-bottom: 4px;
}

.sector-cta span {
  font-size: 12px;
  color: var(--muted);
}

.sector-cta:hover {
  transform: translateY(-3px);
  border-color: var(--brand);
  box-shadow: var(--shadow-sm);
}

.mission-image {
  width: 100%;
  height: 160px;
  background-size: cover;
  background-position: center;
  background-color: var(--bg1);
}

.formation-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: var(--brand);
}

.formation-image {
  width: 100%;
  height: 180px;
  background-size: cover;
  background-position: center;
  background-color: var(--bg1);
}

.formation-content {
  padding: 20px;
}

.formation-content h3 {
  margin: 0 0 12px 0;
  font-size: 16px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.3px;
}

.formation-content p {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.sector-section {
  margin: 10px 0 28px;
}

.sector-section > p {
  margin: 0 0 18px;
  color: var(--muted);
}

.sector-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 18px;
}

.sector-card {
  background: var(--glass2);
  border: 1px solid var(--stroke);
  border-radius: var(--r-lg);
  padding: 16px;
  box-shadow: var(--shadow-sm);
}

.sector-card h4 {
  margin: 0 0 10px;
  font-size: 15px;
  font-weight: 800;
  color: var(--text);
}

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

.split-section {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
  align-items: center;
  margin: 16px 0 32px;
}

.split-content p {
  margin: 0 0 12px;
  color: var(--muted);
}

.split-media {
  min-height: 320px;
  border-radius: var(--r-xl);
  background:
    linear-gradient(120deg, rgba(10, 18, 30, 0.7), rgba(10, 18, 30, 0.2)),
    url('../wp-content/uploads/2025/12/1765126686905_Firefly_A-realistic-professional-photo-style-scene-symbolizing-streamlined-business-operatio-693941.jpg') center/cover no-repeat;
  box-shadow: var(--shadow);
}

.pill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  list-style: none;
  padding: 0;
  margin: 0 0 18px;
}

.pill-list li {
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--glass2);
  border: 1px solid var(--stroke);
  font-size: 12px;
  color: var(--text2);
}

.feature-section {
  margin: 12px 0 32px;
}

.muted-text {
  margin: 0 0 14px;
  color: var(--muted);
}

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

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

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

.featured-img {
  height: 140px;
  background-size: cover;
  background-position: center;
  background-color: var(--bg1);
}

.featured-body {
  padding: 14px;
}

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

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

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

.tool-card {
  padding: 12px 14px;
  border-radius: 999px;
  text-align: center;
  background: var(--glass2);
  border: 1px solid var(--stroke);
  font-size: 12px;
  color: var(--text2);
}

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

.impact-card {
  padding: 16px;
  border-radius: var(--r-lg);
  background: var(--glass2);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-sm);
}

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

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

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

.testi-card {
  padding: 16px;
  border-radius: var(--r-lg);
  background: var(--glass2);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-sm);
}

.testi-card p {
  margin: 0 0 10px;
  font-size: 13px;
  color: var(--text2);
}

.testi-meta {
  font-size: 12px;
  color: var(--muted);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
}

.gallery-item {
  position: relative;
  height: 180px;
  border-radius: var(--r-lg);
  overflow: hidden;
  background-size: cover;
  background-position: center;
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-sm);
}

.gallery-item::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.05), rgba(0,0,0,0.55));
}

.gallery-item span {
  position: absolute;
  left: 12px;
  bottom: 10px;
  color: #fff;
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.3px;
  z-index: 1;
}

.stats-band {
  margin: 18px 0 32px;
  padding: 24px;
  border-radius: var(--r-xl);
  background: linear-gradient(120deg, rgba(18, 30, 52, 0.9), rgba(18, 30, 52, 0.6));
  color: #fff;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  box-shadow: var(--shadow);
}

.stat-item h3 {
  margin: 0 0 6px;
  font-size: 22px;
  font-weight: 900;
}

.stat-item p {
  margin: 0;
  font-size: 12px;
  color: rgba(255,255,255,0.85);
}

.newsletter {
  margin: 16px 0 32px;
  padding: 22px;
  border-radius: var(--r-xl);
  background: var(--glass2);
  border: 1px solid var(--stroke);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  box-shadow: var(--shadow-sm);
}

.newsletter h2 {
  margin: 0 0 4px;
  font-size: 20px;
  font-weight: 900;
}

.newsletter p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.newsletter-form {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.newsletter-form input {
  min-width: 220px;
  padding: 10px 12px;
  border-radius: var(--r-sm);
  border: 1px solid var(--stroke);
  background: var(--bg2);
  color: var(--text);
}

.logo-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 14px;
  align-items: center;
}

.logo-strip img {
  width: 100%;
  max-height: 64px;
  object-fit: contain;
  opacity: 0.8;
  filter: grayscale(0.4);
  transition: opacity .2s ease, filter .2s ease, transform .2s ease;
}

.logo-strip img:hover {
  opacity: 1;
  filter: grayscale(0);
  transform: translateY(-2px);
}

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

.commit-card {
  padding: 16px;
  border-radius: var(--r-lg);
  background: var(--glass2);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-sm);
}

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

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

.quick-choices {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
}

.choice-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px;
  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;
}

.choice-card strong {
  font-size: 14px;
  font-weight: 800;
}

.choice-card span {
  font-size: 12px;
  color: var(--muted);
}

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

.format-choices {
  margin-top: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.faq-accordion {
  display: grid;
  gap: 10px;
}

.faq-row {
  padding: 12px 14px;
  border-radius: var(--r-lg);
  border: 1px solid var(--stroke);
  background: var(--glass2);
}

.faq-row summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--text);
}

.faq-row p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 13px;
}

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

.road-step {
  padding: 18px;
  border-radius: var(--r-lg);
  background: var(--glass2);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-sm);
}

.road-badge {
  display: inline-flex;
  padding: 4px 10px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--brand) 16%, transparent);
  color: var(--brand);
  font-size: 11px;
  font-weight: 800;
  margin-bottom: 8px;
}

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

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

.promise-band {
  padding: 22px;
  border-radius: var(--r-xl);
  background: linear-gradient(120deg, rgba(20, 34, 58, 0.9), rgba(20, 34, 58, 0.6));
  color: #fff;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  box-shadow: var(--shadow);
}

.promise-band h2 {
  margin: 0 0 6px;
  font-size: 22px;
  font-weight: 900;
}

.promise-band p {
  margin: 0;
  color: rgba(255,255,255,0.85);
}

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

.feature-card {
  background: var(--glass2);
  border: 1px solid var(--stroke);
  border-radius: var(--r-lg);
  padding: 18px;
  box-shadow: var(--shadow-sm);
}

.feature-card h4 {
  margin: 12px 0 6px;
  font-size: 15px;
  font-weight: 800;
  color: var(--text);
}

.feature-card p {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

.iconBadge {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: color-mix(in srgb, var(--brand) 12%, transparent);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--brand);
}

.steps-section {
  margin: 12px 0 32px;
}

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

.step-card {
  background: var(--glass2);
  border: 1px solid var(--stroke);
  border-radius: var(--r-lg);
  padding: 18px;
  box-shadow: var(--shadow-sm);
}

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

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

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

.faq-section {
  margin: 12px 0 32px;
}

.faq-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
}

.faq-item {
  background: var(--glass2);
  border: 1px solid var(--stroke);
  border-radius: var(--r-lg);
  padding: 16px;
  box-shadow: var(--shadow-sm);
}

.faq-item h4 {
  margin: 0 0 8px;
  font-size: 14px;
  font-weight: 800;
}

.faq-item p {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

.cta-banner {
  margin: 16px 0 36px;
  padding: 28px;
  border-radius: var(--r-xl);
  background:
    linear-gradient(120deg, rgba(16, 26, 44, 0.9), rgba(16, 26, 44, 0.6)),
    url('../wp-content/uploads/2025/12/woman-gives-presentation-with-pie-chart-on-1536x1025.jpeg') center/cover no-repeat;
  color: #fff;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  box-shadow: var(--shadow);
}

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

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

.contact-hero {
  margin: 0 0 18px;
}

.contact-hero p {
  margin: 0;
  color: var(--muted);
}

.contact-card {
  max-width: 720px;
  background: var(--glass2);
  border: 1px solid var(--stroke);
  border-radius: var(--r-xl);
  padding: 22px;
  box-shadow: var(--shadow-sm);
}

.form-group {
  margin-bottom: 14px;
}

.form-group label {
  display: block;
  margin-bottom: 6px;
  font-weight: 600;
  color: var(--text);
  font-size: 13px;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--stroke);
  border-radius: var(--r-sm);
  background: var(--bg2);
  color: var(--text);
  font-size: 14px;
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

/* Page title */
.page h1 {
  font-size: 28px;
  font-weight: 900;
  letter-spacing: -0.5px;
  color: var(--text);
  margin: 0 0 8px 0;
}

/* Ensure hero text stays readable on dark hero background */
.page .home-hero-skill {
  color: var(--text-on-dark);
}

.page .home-hero-skill h1 {
  color: var(--text-on-dark);
}

.page .home-hero-skill p {
  color: color-mix(in srgb, var(--text-on-dark) 90%, transparent);
}

@media (max-width: 680px) {
  .mission-hero {
    padding: 28px 22px;
  }

  .mission-hero h1 {
    font-size: 22px;
  }

  .formations-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .formation-image {
    height: 150px;
  }

  .formation-content {
    padding: 16px;
  }

  .page h1 {
    font-size: 22px;
  }
}

@media (max-width: 900px) {
  .split-section {
    grid-template-columns: 1fr;
  }
  .split-media {
    min-height: 240px;
  }
  .cta-banner {
    padding: 22px;
  }
}

/* =========================
   PROFILE PAGE
   ========================= */
.profilePage {
  min-height: calc(100vh - 80px);
  background-color: var(--bg0);
  padding: 40px 20px;
  display: flex;
  justify-content: center;
  overflow-x: hidden;
  position: relative;
}

.profileLayout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 30px;
  width: 100%;
  max-width: 1200px;
  min-width: 0;
}


/* === LEFT SIDEBAR (Navigation) === */
.profileSidebar {
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-width: 0;
}

.userCard {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 30px 20px;
  text-align: center;
  box-shadow: var(--shadow-sm);
  background: var(--glass2);
  backdrop-filter: blur(16px);
}

.userAvatar {
  width: 100px;
  height: 100px;
  margin: 0 auto 16px;
  background: var(--bg2);
  color: var(--brand);
  border-radius: 50%;
  font-size: 36px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-xs);
  border: 4px solid rgba(255,255,255,0.5);
}

.userName {
  font-size: 18px;
  font-weight: 800;
  color: var(--text);
  margin: 0 0 4px;
}

.userRole {
  font-size: 13px;
  color: var(--muted);
  font-weight: 600;
  margin-bottom: 12px;
}

.completionBar {
  height: 6px;
  background: var(--bg1);
  border-radius: 99px;
  overflow: hidden;
  margin-top: 12px;
}

.completionFill {
  height: 100%;
  background: var(--brand);
  border-radius: 99px;
}

.completionText {
  font-size: 11px;
  color: var(--muted);
  margin-top: 6px;
  display: block;
}

/* Navigation Menu */
.profileNav {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.navItem {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-radius: 12px;
  color: var(--nav-text, #4a6670);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
  background: transparent;
  border: none;
  width: 100%;
  text-align: left;
}

.navItem:hover {
  background: var(--bg1);
  color: var(--text);
}

.navItem.active {
  background: var(--brand);
  color: white;
  box-shadow: var(--shadow-sm);
}

.navIcon {
  width: 18px;
  height: 18px;
}

/* === SIDEBAR ACTION BUTTONS === */
.sidebarActions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 0 4px;
}

.sidebarActionBtn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
  border: 1px solid var(--border);
  text-decoration: none;
  text-align: left;
  font-family: inherit;
}

.sidebarActionElec {
  background: #059669;
  color: #ffffff;
  border-color: #059669;
}
.sidebarActionElec:hover {
  background: #047857;
}
.sidebarActionElec.disabled {
  background: var(--bg1);
  color: var(--muted);
  border-color: var(--border);
  cursor: not-allowed;
  opacity: 0.7;
}

.sidebarActionBrowser {
  background: var(--bg2);
  color: var(--text);
  border-color: var(--border);
}
.sidebarActionBrowser:hover {
  background: var(--bg1);
}

.sidebarActionPdf {
  background: var(--brand);
  color: #ffffff;
  border-color: var(--brand);
}
.sidebarActionPdf:hover {
  opacity: 0.9;
}

/* === RIGHT CONTENT (Tabs) === */
.profileContent {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 40px;
  box-shadow: var(--shadow-sm);
  background: var(--glass2);
  min-height: 600px;
  min-width: 0;
  overflow-x: hidden;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.tabContent {
  display: none;
  animation: fadeIn 0.3s ease;
}

.tabContent.active {
  display: block;
}

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

.tabHeader {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 30px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

.tabTitle {
  font-size: 24px;
  font-weight: 800;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 12px;
}

.tabTitle i {
  color: var(--brand);
}

/* === FORMS & INPUTS === */
.formGrid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.formGroup {
  margin-bottom: 20px;
}

.formLabel {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}

.formInput, .formTextarea, .formSelect {
  width: 100%;
  padding: 12px 16px;
  border-radius: 12px;
  border: 1px solid var(--stroke);
  background: var(--bg0);
  color: var(--text);
  font-family: inherit;
  font-size: 14px;
  transition: all 0.2s;
}

.formInput:focus, .formTextarea:focus, .formSelect:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 10%, transparent);
}

.formTextarea {
  resize: vertical;
  min-height: 100px;
}

/* === COMBO BOX (Input + Dropdown) === */
.combo {
  position: relative;
  width: 100%;
}

.comboInput {
  padding-right: 40px;
}

.comboBtn {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: 1px solid var(--stroke);
  background: var(--bg0);
  cursor: pointer;
}

.comboBtn::before {
  content: '';
  display: block;
  width: 0;
  height: 0;
  margin: 0 auto;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid var(--muted);
}

.comboList {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow-sm);
  max-height: 240px;
  overflow-y: auto;
  z-index: 20;
  padding: 6px;
}

.combo.open .comboList {
  display: block;
}

.comboOption {
  width: 100%;
  text-align: left;
  background: transparent;
  border: none;
  padding: 8px 10px;
  border-radius: 8px;
  cursor: pointer;
  color: var(--text);
  font-size: 14px;
  position: relative;
  padding-right: 28px;
}

.comboOption:hover,
.comboOption.active {
  background: var(--bg1);
}

.comboOption.selected {
  font-weight: 700;
}

.comboCheck {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--brand);
  font-size: 14px;
}

/* === TIMELINE (Parcours) === */
.timeline {
  position: relative;
  padding-left: 30px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--stroke);
}

.timelineItem {
  position: relative;
  margin-bottom: 30px;
}

.timelineDot {
  position: absolute;
  left: -35px;
  top: 0;
  width: 12px;
  height: 12px;
  background: var(--brand);
  border: 3px solid var(--surface);
  border-radius: 50%;
  box-shadow: 0 0 0 2px var(--brand);
}

.timelineContent {
  background: var(--bg0);
  padding: 20px;
  border-radius: 16px;
  border: 1px solid var(--stroke);
}

.timelineHeader {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 10px;
}

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

.timelineCompany {
  font-size: 14px;
  font-weight: 600;
  color: var(--brand);
}

.timelineDate {
  font-size: 12px;
  color: var(--muted);
  font-weight: 500;
  background: var(--bg2);
  padding: 4px 10px;
  border-radius: 20px;
  border: 1px solid var(--stroke);
}

.timelineDesc {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
}

/* === SKILLS TAGS === */
.skillsContainer {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 30px;
}

.skillTag {
  background: var(--bg0);
  border: 1px solid var(--stroke);
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
}

.skillLevel {
  display: flex;
  gap: 2px;
}

.skillDot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--stroke);
}

.skillDot.filled {
  background: var(--brand);
}

/* === UPLOAD BOX === */
.uploadBox {
  border: 2px dashed var(--stroke);
  border-radius: 16px;
  padding: 40px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  background: var(--bg0);
}

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

.uploadIcon {
  width: 40px;
  height: 40px;
  color: var(--muted);
  margin-bottom: 12px;
}

/* === MODAL === */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.5);
  z-index: 2000;
  backdrop-filter: blur(5px);
  align-items: center;
  justify-content: center;
}

.modal.open {
  display: flex;
}

.modalContent {
  background: var(--surface);
  padding: 30px;
  border-radius: 20px;
  width: 100%;
  max-width: 500px;
  box-shadow: var(--shadow);
  animation: cardIn 0.3s ease;
}

#modal-exp .modalContent {
  max-width: 700px;
}

/* === RESPONSIVE === */
@media (max-width: 900px) {
  .profileLayout {
    grid-template-columns: 1fr;
  }
  
  .profileNav {
    flex-direction: row;
    overflow-x: auto;
    padding-bottom: 10px;
  }

  .navItem {
    white-space: nowrap;
    width: auto;
  }

  .sidebarActions {
    flex-direction: row;
    overflow-x: auto;
    padding-bottom: 6px;
  }

  .sidebarActionBtn {
    white-space: nowrap;
    font-size: 12px;
    padding: 8px 12px;
  }
}

@media (max-width: 720px) {
  .profilePage {
    padding: 24px 12px;
  }

  .profileLayout {
    gap: 16px;
  }

  .profileContent {
    padding: 22px;
    min-height: auto;
  }

  .tabHeader {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .formGrid {
    grid-template-columns: 1fr !important;
    gap: 12px;
  }

  .formGrid > * {
    grid-column: span 1 !important;
  }

  .techCheckboxGrid {
    grid-template-columns: 1fr;
  }

  .colorPalettes {
    grid-template-columns: 1fr;
  }

  .cvStyles {
    grid-template-columns: 1fr;
  }

  .timelineHeader {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .timelineDate {
    align-self: flex-start;
  }

  .timeline {
    padding-left: 20px;
  }

  .timeline::before {
    left: 8px;
  }

  .timelineDot {
    left: 2px;
  }

  .uploadBox {
    padding: 24px;
  }
}

@media (max-width: 520px) {
  .profilePage {
    padding: 16px 8px;
  }

  .profileLayout {
    gap: 12px;
  }

  .profileSidebar {
    gap: 12px;
  }

  .profileContent {
    padding: 16px;
    border-radius: 16px;
  }

  .userCard {
    padding: 22px 16px;
    border-radius: 16px;
  }

  .userAvatar {
    width: 80px;
    height: 80px;
    font-size: 28px;
  }

  .tabTitle {
    font-size: 18px;
  }

  .tabHeader {
    margin-bottom: 20px;
    padding-bottom: 14px;
  }

  /* formGrid goes to 1 column on small screens */
  .formGrid {
    grid-template-columns: 1fr !important;
    gap: 12px;
  }

  .formGrid > * {
    grid-column: span 1 !important;
  }

  .skillsContainer {
    gap: 6px;
  }

  .skillTag {
    padding: 6px 10px;
    font-size: 12px;
  }
}

/* Admin chat */
.adminChatPage .pageInner.adminChat {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 16px;
  align-items: start;
}

@media (max-width: 768px) {
  .adminChatPage .pageInner.adminChat {
    grid-template-columns: 1fr;
  }
}

.adminChatSidebar {
  background: var(--bg2);
  border: 1px solid var(--stroke);
  border-radius: var(--r-lg);
  padding: 12px;
  box-shadow: var(--shadow-xs);
}

.adminChatSidebar h2 {
  margin: 0 0 10px;
  font-size: 16px;
}

.adminChatList {
  display: grid;
  gap: 8px;
}

.adminChatItem {
  display: block;
  padding: 10px 12px;
  border-radius: var(--r-sm);
  border: 1px solid var(--stroke);
  background: var(--bg1);
  text-decoration: none;
  color: var(--text1);
}

.adminChatItem.active {
  border-color: var(--cta-primary);
  background: color-mix(in srgb, var(--cta-primary) 10%, var(--bg2));
}

.adminChatTitle {
  font-weight: 700;
  font-size: 13px;
}

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

.adminChatMain {
  background: var(--bg2);
  border: 1px solid var(--stroke);
  border-radius: var(--r-lg);
  padding: 12px;
  min-height: 360px;
  display: grid;
  gap: 10px;
}

.adminChatMessages {
  display: grid;
  gap: 8px;
  max-height: 520px;
  overflow: auto;
  padding-right: 4px;
}

.adminChatBubble {
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 12px;
  line-height: 1.5;
  max-width: 70%;
}

.adminChatSender {
  font-weight: 600;
  font-size: 11px;
  margin-bottom: 4px;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.adminChatBadge {
  font-size: 10px;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: var(--bg2);
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.adminChatBadge.adherent {
  background: color-mix(in srgb, var(--cta-secondary) 14%, var(--bg2));
  color: var(--text);
}

.adminChatBadge.societe {
  background: color-mix(in srgb, var(--cta-primary) 14%, var(--bg2));
  color: var(--text);
}

.adminChatBubble.admin {
  background: color-mix(in srgb, var(--cta-primary) 18%, var(--bg2));
  justify-self: end;
}

.adminChatBubble.client {
  background: color-mix(in srgb, var(--cta-secondary) 12%, var(--bg2));
  border: 1px solid var(--stroke);
}

.adminChatTime {
  font-size: 10px;
  color: var(--muted);
  margin-top: 6px;
}

.adminChatForm {
  display: grid;
  gap: 8px;
}

.adminChatForm textarea {
  border-radius: var(--r-md);
  border: 1px solid var(--stroke);
  padding: 10px 12px;
  resize: vertical;
}

.adminChatEmpty {
  color: var(--muted);
  font-size: 13px;
}

/* Admin inbox */
.adminInboxPage .pageInner.adminInbox {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 16px;
  align-items: start;
}

@media (max-width: 768px) {
  .adminInboxPage .pageInner.adminInbox {
    grid-template-columns: 1fr;
  }
}

.adminInboxSidebar {
  background: var(--bg2);
  border: 1px solid var(--stroke);
  border-radius: var(--r-lg);
  padding: 12px;
  box-shadow: var(--shadow-xs);
}

.adminInboxSidebar h2 {
  margin: 0 0 10px;
  font-size: 16px;
}

.adminInboxList {
  display: grid;
  gap: 8px;
  max-height: 640px;
  overflow: auto;
  padding-right: 4px;
}

.adminInboxItem {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border-radius: var(--r-sm);
  border: 1px solid var(--stroke);
  background: var(--bg1);
  text-decoration: none;
  color: var(--text1);
}

.adminInboxItem.unread {
  border-color: color-mix(in srgb, var(--cta-primary) 45%, var(--stroke));
  background: color-mix(in srgb, var(--cta-primary) 10%, var(--bg2));
}

.adminInboxItem.active {
  border-color: var(--cta-primary);
  background: color-mix(in srgb, var(--cta-primary) 12%, var(--bg2));
}

.adminInboxTitle {
  font-weight: 700;
  font-size: 13px;
}

.adminInboxMeta {
  font-size: 11px;
  color: var(--muted);
}

.adminInboxSnippet {
  font-size: 11px;
  color: var(--text2);
}

.adminInboxTime {
  font-size: 10px;
  color: var(--muted);
}

.adminInboxMain {
  background: var(--bg2);
  border: 1px solid var(--stroke);
  border-radius: var(--r-lg);
  padding: 14px;
  min-height: 360px;
  display: grid;
  gap: 12px;
}

.adminInboxHeader {
  display: grid;
  gap: 6px;
}

.adminInboxSubject {
  font-size: 16px;
  font-weight: 700;
}

.adminInboxDetail {
  display: grid;
  gap: 4px;
  font-size: 12px;
  color: var(--muted);
}

.adminInboxAttachments {
  border: 1px dashed var(--stroke);
  border-radius: var(--r-md);
  padding: 10px;
  background: var(--bg1);
}

.adminInboxAttachmentsTitle {
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 6px;
}

.adminInboxAttachmentsList {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.adminInboxAttachment {
  display: inline-flex;
  padding: 4px 8px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--cta-secondary) 12%, var(--bg2));
  border: 1px solid var(--stroke);
  font-size: 11px;
}

.adminInboxBody {
  border-top: 1px solid var(--stroke);
  padding-top: 10px;
}

.adminInboxBodyText {
  font-size: 12px;
  line-height: 1.6;
  color: var(--text1);
  white-space: normal;
}

.adminInboxEmpty {
  color: var(--muted);
  font-size: 13px;
}

.adminInboxReply {
  border-top: 1px solid var(--stroke);
  padding-top: 12px;
  display: grid;
  gap: 8px;
}

.adminInboxReply h3 {
  margin: 0;
  font-size: 14px;
}

.adminInboxNotice {
  padding: 8px 10px;
  border-radius: var(--r-sm);
  font-size: 12px;
  border: 1px solid var(--stroke);
  background: var(--bg1);
}

.adminInboxNotice.success {
  border-color: color-mix(in srgb, var(--cta-primary) 40%, var(--stroke));
  background: color-mix(in srgb, var(--cta-primary) 10%, var(--bg2));
}

.adminInboxNotice.error {
  border-color: #cc4b4b;
  background: color-mix(in srgb, #cc4b4b 10%, var(--bg2));
}

.adminInboxReplyForm {
  display: grid;
  gap: 8px;
}

.adminInboxReplyForm label {
  display: grid;
  gap: 6px;
  font-size: 12px;
  color: var(--muted);
}

.adminInboxReplyForm input,
.adminInboxReplyForm textarea {
  border-radius: var(--r-md);
  border: 1px solid var(--stroke);
  padding: 10px 12px;
  font-size: 12px;
  color: var(--text1);
  background: var(--bg1);
}

.adminInboxReplyLog {
  border-top: 1px dashed var(--stroke);
  padding-top: 10px;
  display: grid;
  gap: 8px;
}

.adminInboxReplyLogTitle {
  font-size: 12px;
  font-weight: 700;
}

.adminInboxReplyItem {
  border: 1px solid var(--stroke);
  border-radius: var(--r-md);
  padding: 10px;
  background: var(--bg1);
  display: grid;
  gap: 4px;
}

.adminInboxReplySubject {
  font-size: 12px;
  font-weight: 700;
}

.adminInboxReplyMeta {
  font-size: 10px;
  color: var(--muted);
}

.adminInboxReplyBody {
  font-size: 12px;
  line-height: 1.5;
  color: var(--text1);
}

.adminInboxReplyAttachments {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}
.profilePage img,
.profilePage video,
.profilePage iframe,
.profilePage table {
  max-width: 100%;
}

.profilePage table {
  width: 100%;
  display: block;
  overflow-x: auto;
}

/* ==========================================
   DESIGN CV TAB STYLES
   ========================================== */

.designSection {
  background: var(--bg1);
  border: 1px solid var(--stroke);
  border-radius: var(--r-lg);
  padding: 24px;
  margin-bottom: 24px;
}

.designSectionTitle {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 18px;
  font-weight: 700;
  color: var(--text0);
  margin: 0 0 20px 0;
}

.designSectionTitle i {
  width: 20px;
  height: 20px;
}

/* Photo Upload */
.photoUploadArea {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 24px;
  align-items: center;
}

@media (max-width: 768px) {
  .photoUploadArea {
    grid-template-columns: 1fr;
  }
}

.currentPhoto {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--stroke);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg0);
}

.profilePhotoPreview {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photoPlaceholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.photoUploadControls {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* Tech Checkbox Grid */
.techCheckboxGrid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 10px;
}

/* Color Palettes */
.colorPalettes {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 16px;
}

.paletteOption {
  cursor: pointer;
}

.paletteOption input[type="radio"] {
  display: none;
}

.paletteCard {
  background: var(--bg0);
  border: 2px solid var(--stroke);
  border-radius: var(--r-md);
  padding: 16px;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.paletteOption:hover .paletteCard {
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.paletteOption input[type="radio"]:checked + .paletteCard {
  border-color: var(--primary);
  background: var(--primary-light);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2);
}

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

.colorDot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid white;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.paletteName {
  font-weight: 600;
  font-size: 14px;
  color: var(--text0);
}

/* CV Styles */
.cvStyles {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.styleOption {
  cursor: pointer;
}

.styleOption input[type="radio"] {
  display: none;
}

.styleCard {
  background: var(--bg0);
  border: 2px solid var(--stroke);
  border-radius: var(--r-md);
  overflow: hidden;
  transition: all 0.2s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.styleOption:hover .styleCard {
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.styleOption input[type="radio"]:checked + .styleCard {
  border-color: var(--primary);
  box-shadow: 0 4px 16px rgba(59, 130, 246, 0.3);
}

.stylePreview {
  height: 120px;
  padding: 16px;
  background: white;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
}

.previewLine {
  background: #cbd5e1;
  border-radius: 2px;
  transition: all 0.3s ease;
}

.styleInfo {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.styleName {
  font-weight: 700;
  font-size: 16px;
  color: var(--text0);
}

.styleDesc {
  font-size: 13px;
  color: var(--muted);
  margin: 0;
}

/* Preview Animations */
.styleOption:hover .previewLine {
  opacity: 0.8;
}

.styleOption input[type="radio"]:checked + .styleCard .previewLine {
  animation: slideIn 0.4s ease;
}

@keyframes slideIn {
  from {
    transform: translateX(-10px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

/* ================================================================
   PEER CHAT
   ================================================================ */

.peerChat {
  max-width: 720px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  height: calc(100vh - 160px);
  min-height: 400px;
  background: var(--card, #fff);
  border-radius: 16px;
  border: 1px solid var(--border, rgba(0,0,0,0.08));
  overflow: hidden;
  backdrop-filter: blur(12px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.08);
}

.peerChat-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border, rgba(0,0,0,0.08));
  background: var(--surface, rgba(255,255,255,0.6));
  backdrop-filter: blur(12px);
}

.peerChat-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.peerChat-avatar--default {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary, #3b82f6);
  color: #fff;
}

.peerChat-avatar--default i,
.peerChat-avatar--default svg {
  width: 22px;
  height: 22px;
}

.peerChat-headerInfo {
  flex: 1;
  min-width: 0;
}

.peerChat-contactName {
  font-size: 16px;
  font-weight: 600;
  margin: 0;
  color: var(--text0, #1e293b);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.peerChat-status {
  font-size: 12px;
  color: var(--muted, #94a3b8);
}

.peerChat-back {
  margin-left: auto;
  flex-shrink: 0;
}

.peerChat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  scroll-behavior: smooth;
}

.peerChat-notice {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: var(--surface, rgba(59,130,246,0.06));
  border-radius: 10px;
  font-size: 12px;
  color: var(--muted, #64748b);
  margin-bottom: 8px;
}

.peerChat-notice i,
.peerChat-notice svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  color: var(--primary, #3b82f6);
}

.peerChat-bubble {
  max-width: 75%;
  padding: 10px 14px;
  border-radius: 16px;
  font-size: 14px;
  line-height: 1.5;
  word-break: break-word;
  animation: bubbleFadeIn 0.2s ease;
}

.peerChat-bubble.me {
  align-self: flex-end;
  background: var(--primary, #3b82f6);
  color: #fff;
  border-bottom-right-radius: 4px;
}

.peerChat-bubble.them {
  align-self: flex-start;
  background: var(--surface, #f1f5f9);
  color: var(--text0, #1e293b);
  border-bottom-left-radius: 4px;
}

[data-theme="dark"] .peerChat-bubble.them {
  background: var(--surface, rgba(255,255,255,0.08));
}

.peerChat-bubbleText {
  white-space: pre-wrap;
}

.peerChat-bubbleTime {
  font-size: 10px;
  opacity: 0.6;
  margin-top: 4px;
  text-align: right;
}

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

.peerChat-form {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  padding: 12px 16px;
  border-top: 1px solid var(--border, rgba(0,0,0,0.08));
  background: var(--surface, rgba(255,255,255,0.6));
  backdrop-filter: blur(12px);
}

.peerChat-input {
  flex: 1;
  resize: none;
  border: 1px solid var(--border, rgba(0,0,0,0.12));
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 14px;
  font-family: inherit;
  line-height: 1.4;
  background: var(--card, #fff);
  color: var(--text0, #1e293b);
  outline: none;
  transition: border-color 0.2s;
}

.peerChat-input:focus {
  border-color: var(--primary, #3b82f6);
  box-shadow: 0 0 0 3px rgba(59,130,246,0.1);
}

.peerChat-send {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  border-radius: 12px;
}

.peerChat-send i,
.peerChat-send svg {
  width: 16px;
  height: 16px;
}

/* Peer Chat - Responsive */
@media (max-width: 640px) {
  .peerChat {
    border-radius: 0;
    height: calc(100vh - 120px);
    border-left: none;
    border-right: none;
  }

  .peerChat-bubble {
    max-width: 85%;
  }

  .peerChat-header {
    padding: 12px 14px;
  }

  .peerChat-messages {
    padding: 14px;
  }

  .peerChat-form {
    padding: 10px 12px;
  }
}


/* ================================================================
   COOKIE CONSENT BANNER
   ================================================================ */

.cookie-consent {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 9999;
  padding: 0 16px 16px;
  pointer-events: none;
  opacity: 0;
  transform: translateY(100%);
  transition: opacity 0.4s ease, transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.cookie-consent--show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.cookie-consent--hide {
  opacity: 0;
  transform: translateY(100%);
  pointer-events: none;
}

.cookie-consent-inner {
  max-width: 680px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px 24px;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 16px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12), 0 2px 8px rgba(0, 0, 0, 0.06);
}

[data-theme="dark"] .cookie-consent-inner {
  background: rgba(30, 41, 59, 0.85);
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.cookie-consent-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary, #3b82f6);
  color: #fff;
  border-radius: 10px;
}

.cookie-consent-icon i,
.cookie-consent-icon svg {
  width: 20px;
  height: 20px;
}

.cookie-consent-text {
  flex: 1;
  min-width: 0;
}

.cookie-consent-text strong {
  display: block;
  font-size: 14px;
  color: var(--text0, #1e293b);
  margin-bottom: 4px;
}

.cookie-consent-text p {
  font-size: 12px;
  color: var(--muted, #64748b);
  margin: 0;
  line-height: 1.5;
}

.cookie-consent-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

.cookie-consent-actions .btn {
  padding: 8px 16px;
  font-size: 13px;
  border-radius: 10px;
  white-space: nowrap;
}

/* Cookie Consent - Responsive */
@media (max-width: 640px) {
  .cookie-consent {
    padding: 0 10px 10px;
  }

  .cookie-consent-inner {
    flex-direction: column;
    text-align: center;
    padding: 16px;
    gap: 12px;
  }

  .cookie-consent-actions {
    width: 100%;
    justify-content: center;
  }

  .cookie-consent-actions .btn {
    flex: 1;
  }
}
