/* ============================================================
   layout.css
   ============================================================ */

/* ======================== MAIN CONTENT ===================== */
.main-content {
  margin-left: var(--sidebar-w);
  flex: 1;
  width: calc(100% - var(--sidebar-w));
  max-width: calc(100% - var(--sidebar-w));
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}
/* ======================== TOPBAR ========================== */
.topbar {
  height: var(--topbar-h);
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  position: sticky;
  top: 0;
  z-index: 100;
}
.topbar-left { display: flex; align-items: center; gap: 16px; }
.hamburger {
  display: flex; flex-direction: column; gap: 5px;
  background: none; border: none; cursor: pointer; padding: 4px;
}
.hamburger span {
  width: 22px; height: 2px;
  background: var(--text-700);
  border-radius: 2px;
  transition: .2s;
}
.page-title {
  font-family: var(--font-display);
  font-size: 18px;
  color: var(--text-900);
  font-weight: 700;
}

.topbar-right { display: flex; align-items: center; gap: 14px; }

.search-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-base);
  border: 1.5px solid var(--border);
  border-radius: 99px;
  padding: 7px 14px;
  min-width: 220px;
}
.search-bar svg { width:15px; height:15px; stroke:var(--text-300); fill:none; stroke-width:2; flex-shrink:0; }
.search-bar input {
  border: none; background: none;
  font-family: var(--font-main);
  font-size: 13px; color: var(--text-900);
  outline: none; width: 100%;
}
.search-bar input::placeholder { color: var(--text-300); }

.btn-add {
  display: flex; align-items: center; gap: 6px;
  background: var(--green-600);
  color: #fff;
  border: none;
  border-radius: 99px;
  padding: 9px 18px;
  font-family: var(--font-main);
  font-size: 13px; font-weight: 600;
  cursor: pointer;
  transition: all .2s;
}
.btn-add:hover { background: var(--green-700); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-add svg { width:14px; height:14px; stroke:#fff; fill:none; stroke-width:2.5; }

.notif-item.notif-unread {
  background: #f0fdf4;
  border-left: 3px solid var(--green-400);
}

.notif-bell {
  width: 38px; height: 38px;
  background: var(--bg-base);
  border-radius: 50%;
  display: grid; place-items: center;
  cursor: pointer;
  position: relative;
}
.notif-bell svg { width:18px; height:18px; stroke:var(--text-500); fill:none; stroke-width:1.8; }
.notif-dot {
  position: absolute; top: 6px; right: 6px;
  width: 8px; height: 8px;
  background: var(--red);
  border-radius: 50%;
  border: 2px solid var(--bg-card);
}

/* ======================== PAGES ========================== */
.page { display: none; padding: 24px; width: 100%; box-sizing: border-box; flex: 1; animation: fadeIn .25s ease; overflow-x: visible; }
.page.active { display: block !important; }
@keyframes fadeIn { from{opacity:0;transform:translateY(8px)} to{opacity:1;transform:translateY(0)} }

