/* frontend/css/global.css */

:root{
  --border: rgba(15, 23, 42, .10);
  --shadow: 0 12px 26px rgba(15, 23, 42, .08);
}

body{
  font-family: var(--font, "Montserrat", system-ui, -apple-system, Segoe UI, Roboto, sans-serif);
  background: var(--bg, #f4f7fb);
  color: var(--text, #0f172a);
}

/* ===== Layout ===== */
.layout{
  min-height: 100vh;
  display:flex;
}

/* ===== Sidebar (unique) ===== */
.sidebar{
  width: 76px;
  background: #f7fafc;
  border-right: 1px solid var(--border);
  display:flex;
  flex-direction: column;
  align-items:center;
  padding: 14px 10px;
  position: sticky;
  top: 0;
  height: 100vh;
}

.sidebar-top{
  display:flex;
  align-items:center;
  justify-content:center;
  width: 100%;
  margin-bottom: 12px;
}

.sidebar-logo{
  width: 34px;
  height: 34px;
  object-fit: contain;
  display:block;
}

.sidebar-nav{
  width: 100%;
  display:flex;
  flex-direction: column;
  gap: 10px;
  align-items:center;
  margin-top: 10px;
}

.nav-item{
  width: 56px;
  height: 56px;
  border-radius: 14px;
  display:flex;
  align-items:center;
  justify-content:center;
  border: 1px solid transparent;
  background: transparent;
  cursor:pointer;
  text-decoration:none;
}

.nav-item:hover{
  background: #eef2ff;
  border-color: rgba(99,102,241,.25);
}

.nav-item.is-active{
  background: #3b82f6;
  border-color: rgba(59,130,246,.6);
}

.nav-icon{
  width: 22px;
  height: 22px;
  object-fit: contain;
  display:block;
  /* IMPORTANT: on ne “teinte” pas tes PNG */
}

.nav-item.is-active .nav-icon{
  /* Rend l’icône blanche si ton PNG est sombre.
     Si tes PNG sont déjà colorés, tu peux commenter cette ligne. */
  filter: brightness(0) invert(1);
}

.sidebar-bottom{
  margin-top: auto;
  width: 100%;
  display:flex;
  align-items:center;
  justify-content:center;
  padding-bottom: 6px;
}

.nav-logout{
  background: #fff;
  border: 1px solid rgba(15,23,42,.15);
}
.nav-logout:hover{
  background: #f8fafc;
}

/* ===== Main ===== */
.main{
  flex: 1;
  padding: 18px 22px;
}

/* ===== Controls ===== */
.select, .input{
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 10px 12px;
  background: #fff;
  font-size: 14px;
  outline: none;
}

.select:focus, .input:focus{
  border-color: rgba(59,130,246,.55);
  box-shadow: 0 0 0 3px rgba(59,130,246,.15);
}

.btn{
  border: none;
  border-radius: 12px;
  padding: 12px 14px;
  font-weight: 800;
  cursor: pointer;
}

.btn-primary{
  background: #3b82f6;
  color: #fff;
}
.btn-primary:hover{ background: #2563eb; }

.btn-secondary{
  background: #fff;
  border: 1px solid var(--border);
  color: #0f172a;
}
.btn-secondary:hover{ background: #f8fafc; }

.footer{
  position: fixed;
  right: 14px;
  bottom: 14px;
  background: white;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 8px 10px;
  font-size: 12px;
  color: #111827;
  box-shadow: 0 8px 18px rgba(15,23,42,.08);
}
