/* Statistics home page */
/* Section styling */
.section-statistics-home {
  background-color: #2b4359;
  padding: 30px 0;
}

.statistics-container-home {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  justify-content: center; /* ✅ centers the grid tracks */
  justify-items: center; /* ✅ centers boxes within each track */
  margin: 0 auto;
  width: 90%;
  max-width: 1200px;
}

/* Individual box */
.statistics-box-home {
  flex: 1 1 200px; /* responsive width */
  max-width: 250px;
  min-width: 250px;
  height: 250px;
  background: #027b63;
  border-radius: 12px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  text-align: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Icon styling */
.statistics-icon-home {
  font-size: 2rem;
  color: #2b4359;
}

/* Button container */
.statistics-buttons-home {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}

/* Default button style */
.statistics-buttons-home a {
  background-color: #007bff;
  color: white;
  border-radius: 5px;
  padding: 5px 10px;
  text-decoration: none;
  transition: all 0.3s;
}

/* Default hover effect */
.statistics-buttons-home a:hover {
  background-color: #0056b3;
  color: #027b63;
}

/* 🎯 Button hover overrides per box */
.statistics-box-home:nth-child() .statistics-buttons-home a:hover {
  background-color: #027b63;
  color: #ffffff;
}

/* CSS statistics chapters */
/* Section styling */
.section-statistics {
  background-color: #2b4359;
  padding: 30px 0;
}

/* Flex container */
.stats-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-around;
  gap: 20px;
  max-width: 1200px;
  margin: 0 auto;
}

/* Individual box */
.stats-box {
  flex: 1 1 200px; /* responsive width */
  max-width: 200px;
  min-width: 200px;
  height: 200px;
  background: #9cd5c0;
  border-radius: 12px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  text-align: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* 🎨 Box color overrides */
.stats-box:nth-child(2) {
  background-color: #027b63;
}

.stats-box:nth-child(3) {
  background-color: #4a736f;
}

.stats-box:nth-child(4) {
  background-color: #17a2b8;
}

.stats-box:nth-child(5) {
  background-color: #0388a6;
}

/* Icon styling */
.stats-icon {
  font-size: 2rem;
  color: #2b4359;
}

/* Button container */
.stats-buttons {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}

/* Default button style */
.stats-buttons a {
  background-color: #007bff;
  color: white;
  border-radius: 5px;
  padding: 5px 10px;
  text-decoration: none;
  transition: all 0.3s;
}

/* Default hover effect */
.stats-buttons a:hover {
  background-color: #0056b3;
  color: #9cd5c0;
}

/* 🎯 Button hover overrides per box */
.stats-box:nth-child(1) .stats-buttons a:hover {
  background-color: #9cd5c0;
  color: #ffffff;
}

/* 🎯 Button hover overrides per box */
.stats-box:nth-child(2) .stats-buttons a:hover {
  background-color: #027b63;
  color: #ffffff;
}

.stats-box:nth-child(3) .stats-buttons a:hover {
  background-color: #4a736f;
  color: #ffffff;
}

.stats-box:nth-child(4) .stats-buttons a:hover {
  background-color: #17a2b8;
  color: #ffffff;
}

.stats-box:nth-child(5) .stats-buttons a:hover {
  background-color: #0388a6;
  color: #ffffff;
}

/* Table and Canvas */
/* Container statistics */
.section_statistics_table_canvas .container {
  background-color: #2b4359;
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  justify-content: space-around;
}
.section_statistics_table_canvas .container .statistics_css {
  display: flex;
  align-items: start;
  justify-content: space-between;
}
.section_statistics_table_canvas .container .statistics_css .box {
  flex: 1;
  background: #9cd5c0;
  color: #fff;
  border-radius: 10px;
  margin: 20px 10px;
  box-shadow: 0 3px 5px rgba(0, 0, 0, 0.6);
  padding: 15px 20px;
}
.section_statistics_table_canvas
  .container
  .statistics_css
  .box:nth-of-type(1) {
  flex-grow: 3;
  background: #9cd5c0;
  color: #fff;
  border-radius: 10px;
  margin: 20px 10px;
  padding: 15px 20px;
  text-align: center;
}
.section_statistics_table_canvas
  .container
  .statistics_css
  .box:nth-of-type(2) {
  flex-grow: 1;
  background: #9cd5c0;
  color: #fff;
  border-radius: 10px;
  margin: 20px 10px;
  padding: 15px 20px;
  text-align: center;
}
/* Customize table transparency */
.table_custom_table_canvas {
  --bs-table-bg: transparent !important;
}

/* 🧭 Custom AOS animation to avoid Bootstrap conflict */
[data-aos="aos-fade-right"] {
  opacity: 0;
  transform: translateX(-30px);
  transition-property: transform, opacity;
}

[data-aos="aos-fade-right"].aos-animate {
  opacity: 1;
  transform: translateX(0);
}

.modal-backdrop {
  z-index: 1050 !important;
  background-color: rgba(0, 0, 0, 0.5) !important;
}

.modal {
  z-index: 1060 !important;
}

/* Make the table responsive in mobile phones */
/* Make table scroll instead of breaking layout */
.table-responsive-wrapper {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  width: 100%;
}

/* Responsive layout */
@media (max-width: 768px) {
  .stats-container {
    flex-direction: column;
    align-items: center;
  }
  .table_custom_table_canvas {
    font-size: 12px; /* or any size you prefer */
  }

  .table_custom_table_canvas th,
  .table_custom_table_canvas td {
    padding: 4px 6px; /* optional: reduce padding too */
  }
  .statistics-container-home {
    grid-template-columns: 1fr; /* single column layout on mobile */
  }

  .section_statistics_table_canvas .container .statistics_css {
    flex-direction: column;
    width: 100%;
  }

  .section_statistics_table_canvas .container .statistics_css .box {
    width: 100%;
    margin: 10px 0;
  }
  .mobile-adjust-btn {
    font-size: 12px;
    padding: 4px 10px;
  }
}
