/* general resets */
* {
  margin: 0;
  padding: 0;
  box‑sizing: border‑box;
}
body, html {
  height: 100%;
  /* font‑family: "Segoe UI", Tahoma, Geneva, Verdana, sans‑serif; */
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  background: rgb(208, 205, 205);
}

/* Topbar container */
.topbar {
  height: 60px;
  background-color:rgb(3, 32, 62);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  border-bottom: 1px solid #e0e0e0;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
}

/* Logo styling */
.topbar .logo {
  font-size: 1.5rem;
  font-weight: bold;
  color: white;
}

/* Right‑side container */
.topbar .topbar‑right {
  display: flex;
  align-items: center;
  gap: 15px;
}

/* Home link */
.topbar .home‑link {
  text-decoration: none;
  color:red;
  background-color:white;
  font-size: 1rem;
  padding: 6px 10px;
  border-radius: 4px;
  font-weight: bold;
  transition: background-color 0.3s;
  animation: pulse 2s ease-in-out infinite; /* new line */
}
/* Define the pulse keyframes */
@keyframes pulse {
  0% {
    transform: scale(1);
    /* optionally: box-shadow: 0 0 0 0 rgba(255,0,0,0.7); */
  }
  50% {
    transform: scale(1.1);
    /* optionally: box-shadow: 0 0 0 10px rgba(255,0,0,0); */
  }
  100% {
    transform: scale(1);
    /* optionally: box-shadow: 0 0 0 0 rgba(255,0,0,0); */
  }
}
.topbar .home‑link:hover {
  background-color:red;
  color: white;
  transform: scale(1.1);
}

/* Search input */
.topbar .search‑input {
  padding: 8px 12px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 0.95rem;
  /* color: #444; */
  width: 180px;
  background-color: #f8f9fa;
  transition: width 0.3s ease, border-color 0.3s ease;
}
.topbar .search‑input:focus {
  width: 240px;
  border-color: #16a085;
  background-color: #ffffff;
  outline: none;
}

/* Profile section */
.topbar .profile button {
  font-size: 0.9rem;
  color:white;
  background-color: red;
  cursor: pointer;
  padding: 6px 10px;
  border-radius: 4px;
  font-weight: bold;
  transition: background-color 0.3s, color 0.3s;
}
.topbar .profile:hover {
  background-color:white !important;
  color: red;
}

/* Adjust main content margin so it is not hidden under the topbar */
.main {
  margin-top: 60px; /* same height as .topbar */
}


.container {
  display: flex;
  height: calc(100% ‑ 60px);
  margin-top: 60px;
}

.sidebar {
  margin-top: 50px;
  width: 200px;
  background:#007bff;
  color: #fff;
}
.sidebar .menu {
  list‑style: none;
  padding: 20px 0;
}
.sidebar .menu‑item {
  padding: 15px 20px;
  cursor: pointer;
  transition: background 0.3s;
  font-weight: bold;
  font-size: 1.4rem;
}
.sidebar .menu‑item:hover, .sidebar .menu‑item.active {
  background: red;
  /* color:rgb(45, 37, 37) ; */
}
.main‑content {
  flex: 1;
  padding: 20px;
  overflow:‑auto;
}
.panel {
  display: none;
}
.panel h2{
    color:rgb(3, 32, 62);
    margin-bottom: 20px;
}
.panel.active {
  display: block;
}






.tiles {
  display: grid;
  grid‑template‑columns: repeat(auto‑fit, minmax(150px, 1fr));
  gap: 20px;
  margin‑bottom: 30px;
}
.tile {
  padding: 20px;
  background: #fff;
  border‑radius: 8px;
  box‑shadow: 0 2px 6px rgba(0,0,0,0.1);
  text‑align: center;
}
.tile h3 {
  font‑size: 1rem;
  color:rgb(45, 37, 37);

}
.tile p {
  font‑size: 1.6rem;
  font‑weight: bold;
  margin‑top: 10px;
}
.tile.green { color:white ; font-weight: bold;   background-color:#007bff;}
.tile.blue { color: white; font-weight: bold;  background-color: #007bff;}
.tile.orange { color: white; font-weight: bold;  background-color: #007bff;}
.tile.red { color: white;font-weight: bold;  background-color: #007bff; }

.section‑info .info‑list{
    background-color: #007bff;
}
.section‑info .info‑list li{
    color:white;
    font-weight: bold;
    list-style: none;
}







.cards {
  display: grid;
  grid‑template‑columns: repeat(auto‑fit, minmax(200px, 1fr));
  gap: 20px;
  margin‑bottom: 30px;
}
.card {
  background: #007bff;
  padding: 20px;
  border‑radius: 8px;
  box‑shadow: 0 2px 6px rgba(0,0,0,0.1);
}
.card h3 {
  font‑size: 1.1rem;
  color:rgb(45, 37, 37);
}
.card p {
  font‑size: 1.5rem;
  font‑weight: bold;
  margin‑top: 8px;
  color:white;
  font-weight: bold;
}

.table‑wrapper {
  background: #fff;
  padding: 20px;
  border‑radius: 8px;
  box‑shadow: 0 2px 6px rgba(0,0,0,0.1);
}
.table‑wrapper table {
  width: 100%;
  border‑collapse: collapse;
}
.table‑wrapper th, .table‑wrapper td {
  padding: 12px;
  border‑bottom: 1px solid #eee;
  text‑align: left;
}
.table‑wrapper th {
  background: #f7f9fa;
  font‑weight: bold;
  color: #555;
}
.section‑info h4{
    color: rgb(3, 32, 62);
    margin: 20px;
    font-size: 1.4rem;
}
.info‑list, .settings‑group {
  background:  #007bff;
  padding: 20px;
  border‑radius: 8px;
  box‑shadow: 0 2px 6px rgba(0,0,0,0.1);
  margin‑bottom: 30px;
}
.info‑list li {
  padding: 8px 0;
  border‑bottom: 1px solid #f0f0f0;
  color: white;
}
.settings‑group label {
  display: block;
  margin‑bottom: 10px;
  color: white;
  font-weight: bold;
}
.settings‑group label input{
    background-color: white;
    color: #007bff;
}
.btn {
  display: inline‑block;
  padding: 10px 20px;
  background: red;
  color: #fff;
  border: none;
  border‑radius: 4px;
  cursor: pointer;
  margin‑top: 10px;
  font-weight: bold;
  font-size: 1rem;
}
.btn:hover {
  background:white;
  color: red;
}

.chart‑placeholder {
  height: 250px;
  background: #fff;
  border: 2px dashed #ccc;
  border‑radius: 8px;
  display: flex;
  align‑items: center;
  justify‑content: center;
  color: #888;
  margin‑bottom: 30px;
}



/* ✅ Responsive for Mobile ≤ 450px */
@media (max-width: 450px) {

  /* Fix layout overflow */
  body, html {
    overflow-x: hidden;
  }

  .topbar {
    flex-direction: column;
    height: auto;
    padding: 10px;
    text-align: center;
  }

  .topbar .topbar-right {
    flex-direction: column;
    gap: 8px;
    margin-top: 5px;
  }

  /* Sidebar becomes top bar menu (full width) */
  .sidebar {
    width: 100%;
    margin-top: 60px;
  }

  .sidebar .menu-item {
    font-size: 1.1rem;
    padding: 12px;
    text-align: center;
  }

  /* Main container stacks vertically */
  .container {
    flex-direction: column;
    height: auto;
    margin-top: 0;
  }

  .main-content {
    padding: 10px;
  }

  /* Tiles become 1 column */
  .tiles {
    grid-template-columns: 1fr;
  }

  .tile {
    padding: 15px;
  }

  /* Cards become 1 per row */
  .cards {
    grid-template-columns: 1fr;
  }

  .card {
    padding: 15px;
  }

  /* Table scroll if overflow */
  .table-wrapper {
    overflow-x: auto;
  }

  .table-wrapper table {
    min-width: 350px;
  }

  .settings-group {
    padding: 15px;
  }

  .btn {
    width: 100%;
    text-align: center;
  }
}
