/* ── Variables ─────────────────────────────────────────────────── */
:root {
  --brand-primary:   #0d6efd;
  --brand-accent:    #20c997;
  --sidebar-width:   220px;
  --navbar-height:   56px;
  --sidebar-bg:      #f8f9fa;
  --sidebar-border:  #e9ecef;
  --sidebar-active:  #0d6efd;
  --footer-height:   44px;
}

/* ── Base ──────────────────────────────────────────────────────── */
body {
  background: linear-gradient(180deg, #eef6ff 0%, #ffffff 40%, #f8fffb 100%);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ── Navbar ────────────────────────────────────────────────────── */
.kalcloud-navbar {
  min-height: var(--navbar-height);
  background: #1a1f36;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  position: sticky;
  top: 0;
  z-index: 1030;
}

/* ── Mobile navbar collapse ────────────────────────────────────── */
@media (max-width: 991.98px) {
  .kalcloud-navbar .navbar-collapse {
    background: #1a1f36;
    padding: 0.75rem 0;
    margin: 0 -0.75rem;
    padding-left: 0.75rem;
    border-top: 1px solid rgba(255,255,255,0.1);
  }
  .kalcloud-navbar .navbar-collapse .nav-link,
  .kalcloud-navbar .navbar-collapse .btn {
    padding: 0.6rem 1rem;
    display: block;
    width: 100%;
    text-align: left;
  }
}

/* ── App body (sidebar + main) ─────────────────────────────────── */
.app-body {
  flex: 1;
  min-height: calc(100vh - var(--navbar-height) - var(--footer-height));
}

/* ── Sidebar ───────────────────────────────────────────────────── */
.kalcloud-sidebar {
  width: var(--sidebar-width);
  min-width: var(--sidebar-width);
  background: var(--sidebar-bg);
  border-right: 1px solid var(--sidebar-border);
  padding: 1.25rem 0.75rem;
  position: sticky;
  top: var(--navbar-height);
  height: calc(100vh - var(--navbar-height) - var(--footer-height));
  overflow-y: auto;
}

.sidebar-label {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #adb5bd;
  margin: 1rem 0.5rem 0.35rem;
}

.sidebar-list {
  list-style: none;
  padding: 0;
  margin: 0 0 0.5rem;
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.65rem;
  border-radius: 0.5rem;
  color: #495057;
  text-decoration: none;
  font-size: 0.9rem;
  transition: background 0.15s ease, color 0.15s ease;
}

.sidebar-link:hover {
  background: #e9ecef;
  color: #212529;
}

.sidebar-link.active {
  background: rgba(13, 110, 253, 0.1);
  color: var(--sidebar-active);
  font-weight: 500;
}

.sidebar-icon {
  font-size: 1rem;
  line-height: 1;
  width: 1.25rem;
  text-align: center;
}

.sidebar-bottom {
  padding: 0.5rem;
  border-top: 1px solid var(--sidebar-border);
  padding-top: 1rem;
  margin-top: 0.5rem;
}

/* ── Main content ──────────────────────────────────────────────── */
.app-main {
  min-width: 0;
}

/* ── Footer ────────────────────────────────────────────────────── */
.kalcloud-footer {
  height: var(--footer-height);
  background: #f8f9fa;
  border-top: 1px solid #e9ecef;
  display: flex;
  align-items: center;
}

/* ── Shared components ─────────────────────────────────────────── */
.feature-card {
  border: 1px solid #e9ecef;
  border-radius: 1rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.feature-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 0.5rem 1rem rgba(0,0,0,0.06);
}
