/* sidebar.css — matches header.css look & feel
   Uses the same CSS variables from header.css; includes fallbacks here. */
:root{
  --bg: #0b0b0d;
  --bg-2: #111217;
  --text: #e7e9ee;
  --muted: #a8b0bc;
  --border: rgba(255,255,255,.08);
  --radius: 12px;
  --shadow: 0 10px 30px rgba(0,0,0,.35);

  /* Height of your sticky header; adjust if needed */
  --header-h: 64px;
}

/* ===== Page layout (sidebar + main) ===== */
.page-layout{
  /* 2 columns: sidebar + main; stretches both to same height */
  display: grid;
  grid-template-columns: 256px 1fr;
  align-items: stretch;
  /* full viewport height minus header; ensures sidebar fills page */
  min-height: calc(100vh - var(--header-h));
}

/* On mobile, stack vertically and let the drawer handle navigation */
@media (max-width: 980px){
  .page-layout{ grid-template-columns: 1fr; }
}

/* ===== Sidebar ===== */
.sidebar{
  width: 256px;
  background: #0c0e14; /* close to header drawer tone */
  color: var(--text);
  border-right: 1px solid var(--border);
  padding: 16px;
  flex-shrink: 0;
  /* Important: remove sticky; let grid stretch full page height */
  position: relative;
  height: 100%;
  min-height: 100%;
  display: none; /* hidden on small screens; shown >= 980px */
}
@media (min-width: 980px){
  .sidebar{ display: block; }
}

.sidebar__inner{
  display: flex;
  flex-direction: column;
  gap: 24px;
  height: 100%;
}

/* ===== Brand ===== */
.sidebar__brand{
  display: flex; align-items: center; gap: 8px;
}
.sidebar__brand-icon{
  color: #f43f5e; /* rose-500 vibe */
  font-size: 36px;
}
.sidebar__brand-title{
  font-size: 20px; font-weight: 800; letter-spacing: .2px;
}

/* ===== Sections ===== */
.sidebar__nav{
  display: flex; flex-direction: column; gap: 8px;
}
.sidebar__section-title{
  font-size: 12px; font-weight: 700; text-transform: uppercase;
  letter-spacing: .06em; color: #8b92a0;
  padding: 0 12px; margin: 0 0 6px 0;
}

/* ===== Links ===== */
.sidebar__link{
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px;
  border: 1px solid transparent;
  border-radius: 10px;
  color: rgba(231,233,238,.85);
  text-decoration: none;
  transition: background-color .12s ease, border-color .12s ease, color .12s ease, transform .12s ease;
}
.sidebar__link:hover{
  background: #141722;
  border-color: var(--border);
  color: #fff;
  transform: translateY(-1px);
}
.sidebar__link--active{
  background: #1a1d28;
  border-color: var(--border);
  color: #fff;
}

.sidebar__icon{
  font-variation-settings: 'wght' 500, 'opsz' 24;
  font-size: 22px;
}

.sidebar__text{
  font-size: 14px; font-weight: 600; line-height: 1.1;
}

/* ===== Divider & empty state ===== */
.sidebar__divider{ border: 0; height: 1px; background: var(--border); }
.sidebar__empty{
  display:block; padding: 8px 12px;
  font-size: 13px; color: var(--muted);
  opacity: .9;
}

/* ===== Focus to mirror header.css ===== */
.sidebar__link:focus{
  outline: 2px solid rgba(245,162,0,.55);
  outline-offset: 2px;
  border-radius: 10px;
}

/* ===== Optional: sticky variant (if you ever want it) =====
   Add class .sidebar--sticky on the <aside> to pin it to viewport.
   Not used now, but handy to have. */
.sidebar--sticky{
  position: sticky;
  top: var(--header-h);
  height: calc(100vh - var(--header-h));
  min-height: 0;
  overflow: auto;
}
/* Nice scrollbar for sticky mode */
.sidebar--sticky::-webkit-scrollbar{ width: 10px; }
.sidebar--sticky::-webkit-scrollbar-thumb{
  background: rgba(255,255,255,.12);
  border-radius: 99px;
}
.sidebar--sticky::-webkit-scrollbar-track{ background: transparent; }
