/* App shell */
.app-shell { display: flex; height: 100vh; overflow: hidden; background: var(--color-bg); }

/* ── Sidebar ─────────────────────────────────────────────────────────────── */
.sidebar {
  width: var(--sidebar-width);
  background: var(--sidebar-bg);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  overflow-y: auto;
  border-right: 1px solid rgba(232, 201, 90, 0.08);
}

/* Lockup in sidebar — mavek-lockup-on-dark.svg */
.sidebar-logo {
  padding: var(--space-5) var(--space-5) var(--space-4);
  display: block;
  text-decoration: none;
  line-height: 0;
}
.sidebar-logo img {
  width: 152px;   /* scales 260×80 proportionally into 200px-wide sidebar content area */
  height: auto;
  display: block;
}

/* Nav links */
.sidebar-nav { flex: 1; padding: var(--space-2) var(--space-3); }
.sidebar-nav a {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-3);
  border-radius: var(--radius-md);
  color: var(--sidebar-text);
  font-family: var(--font-sans);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  transition: background var(--transition-fast), color var(--transition-fast);
  margin-bottom: 2px;
}
.sidebar-nav a:hover {
  background: rgba(246, 243, 232, 0.07);
  color: var(--parchment);
}
.sidebar-nav a.active {
  background: var(--sidebar-active);
  color: var(--gold-bright);
  border: 1px solid rgba(232, 201, 90, 0.18);
}
.sidebar-nav .nav-icon,
.sidebar-footer-link .nav-icon { width: 16px; height: 16px; opacity: 0.75; flex-shrink: 0; }
.sidebar-nav a.active .nav-icon,
.sidebar-footer-link.active .nav-icon { opacity: 1; }

.sidebar-footer {
  padding: var(--space-2) var(--space-3) var(--space-3);
  border-top: 1px solid rgba(246, 243, 232, 0.07);
  display: flex;
  flex-direction: column;
  gap: 2px;
}

/* Settings link in footer — mirrors .sidebar-nav a */
.sidebar-footer-link {
  display: flex; align-items: center; gap: var(--space-3);
  padding: var(--space-3) var(--space-3);
  border-radius: var(--radius-md);
  color: var(--sidebar-text);
  font-family: var(--font-sans);
  font-size: 0.8125rem; font-weight: 500;
  letter-spacing: 0.01em;
  text-decoration: none;
  transition: background var(--transition-fast), color var(--transition-fast);
}
.sidebar-footer-link:hover {
  background: rgba(246, 243, 232, 0.07);
  color: var(--parchment);
}
.sidebar-footer-link.active {
  background: var(--sidebar-active);
  color: var(--gold-bright);
  border: 1px solid rgba(232, 201, 90, 0.18);
}

/* Sign out button */
.sidebar-signout {
  display: flex; align-items: center;
  padding: var(--space-2) var(--space-3);
  width: 100%;
  border-radius: var(--radius-md);
  color: var(--sidebar-text);
  font-family: var(--font-sans);
  font-size: 0.8125rem; font-weight: 500;
  background: none; border: none; cursor: pointer; text-align: left;
  opacity: 0.55;
  transition: opacity var(--transition-fast), background var(--transition-fast);
}
.sidebar-signout:hover { opacity: 1; background: rgba(246, 243, 232, 0.07); }

/* ── Main area ───────────────────────────────────────────────────────────── */
.main-area { flex: 1; display: flex; flex-direction: column; overflow: hidden; }

/* Topbar */
.topbar {
  height: var(--topbar-height);
  background: var(--parchment);
  border-bottom: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--space-6);
  flex-shrink: 0;
}
.topbar-title {
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: 0.01em;
}
.topbar-actions { display: flex; align-items: center; gap: var(--space-3); }

/* Page content */
.page-content {
  flex: 1;
  overflow-y: auto;
  padding: var(--space-6);
  background: var(--color-bg);
}
.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-6);
}
.page-title {
  font-family: var(--font-sans);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.01em;
}

/* ── Auth layout ─────────────────────────────────────────────────────────── */
.auth-layout {
  min-height: 100vh;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--night);
  /* Subtle warm grain */
  background-image:
    radial-gradient(ellipse 80% 60% at 50% -10%, rgba(201,168,76,0.12) 0%, transparent 60%);
}
.auth-card {
  background: var(--parchment);
  border-radius: var(--radius-xl);
  padding: var(--space-10);
  width: 100%;
  max-width: 420px;
  box-shadow:
    0 0 0 1px rgba(201, 168, 76, 0.15),
    0 24px 48px rgba(10, 10, 8, 0.40);
}
.auth-logo {
  text-align: center;
  margin-bottom: var(--space-8);
  display: flex;
  justify-content: center;
  line-height: 0;
}
.auth-logo img {
  width: 180px;   /* mavek-lockup.svg at comfortable auth-card scale */
  height: auto;
  display: block;
}
