/* static/style.css */

body {
  font-family: Arial, sans-serif;
  background-color: #f2f2f2;
  margin: 0;
  padding: 0;
}

h1, h2, h3 {
  color: #333;
  text-align: left;
}
/*
.container {
  max-width: 1000px;
  margin: 20px auto;
  padding: 20px;
  background: white;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
}
*/
.button {
  background-color: #007bff;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 5px;
  cursor: pointer;
}

.button:hover {
  background-color: #0056b3;
}
.selected-cell {
    outline: 2px solid #2196F3;
    background-color: #E3F2FD;
}
/* ********************Sort Spinners*****************************/


/* ********************New Adds *********************************/

  .selected {
    background-color: yellow;
  }
  td[contenteditable="true"]:focus {
    outline: 2px solid #007bff;
  }


  #taskTable tbody tr.selected {
    background-color: #b3d7ff; /* Light blue, change to any color you like */
	
	
/* Make table scrollable on smaller screens */
.table-container {
  overflow-x: auto;
  width: 100%;
}

/* Responsive stacked layout for small devices */
@media (max-width: 768px) {
  table thead {
    display: none;
  }

  table, table tbody, table tr, table td {
    display: block;
    width: 100%;
  }

  table tr {
    margin-bottom: 1rem;
    border: 1px solid #ccc;
    border-radius: 0.5rem;
    padding: 0.5rem;
    background: #fff;
  }

  table td {
    display: flex;
    justify-content: space-between;
    padding: 0.4rem 0.8rem;
    border: none;
    border-bottom: 1px solid #eee;
  }

  table td:last-child {
    border-bottom: none;
  }

  table td::before {
    content: attr(data-label);
    font-weight: bold;
  }

  table a {
    word-break: break-all;
  }

  button {
    margin: 0.2rem;
  }
}

button.btn-edit,
button.btn-delete {
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  border-radius: 6px;
  transition: background 0.2s ease;
}

button.btn-edit i {
  color: #007bff; /* blue edit icon */
}

btn-delete i {
  color: #d9534f !important; /* red trash icon */
}

button.btn-edit:hover,
button.btn-delete:hover {
  background: rgba(0, 0, 0, 0.05);
}

@media (hover: none) {
  button.btn-edit:active,
  button.btn-delete:active {
    background: rgba(0, 0, 0, 0.1);
  }
}


  }
  
.filter-bar {
  display: flex;
  align-items: flex-end;
  gap: 15px;
  margin-top: 10px;
  flex-wrap: wrap;
}

/* Keeps dropdown positioned under its input */
.search-container {
  position: relative;
  display: flex;
  align-items: center;
  gap: 5px;
}

.date-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

#peopleList {
  position: absolute;
  background: white;
  border: 1px solid #ccc;
  width: 200px;
  display: none;
  list-style: none;
  padding: 0;
  margin: 0;
  z-index: 1000;
}

/* Style adjustments for readability */
label {
  font-weight: 500;
  white-space: nowrap;
}

input[type="date"],
#peopleSearch {
  padding: 4px;
  min-width: 140px;
}

/* 🟢 Medium screens: stack groups but keep labels inline */
@media (max-width: 800px) {
  .filter-bar {
    flex-direction: column;
    align-items: flex-start;
  }

  .search-container,
  #btnSearch {
    align-self: fglex-start;
  }
}

/* 🔵 Small screens: stack inputs vertically with left-aligned labels */
@media (max-width: 500px) {
  .filter-bar {
    width: 100%;
	align-items: flex-start;
  }

  /* Stack patient search label and input */
  .search-container {
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
    gap: 4px;
  }

  /* Stack date fields */
  .date-filters {
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
    gap: 8px;
  }

  .date-filters .field {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
  }

  input[type="date"],
  #peopleSearch {
    width: 100%;
    box-sizing: border-box;
  }

  #btnSearch,
  #btnClear
  {
    width: 100%;
	align-self: center;
  }
}
<style>
.note-bubble {
  cursor: pointer;
  display: inline-block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 200px;
  vertical-align: middle;
}

/* For desktop hover tooltips */
.note-bubble[title]:hover::after {
  content: attr(title);
  position: absolute;
  background: #333;
  color: #fff;
  padding: 8px 10px;
  border-radius: 6px;
  top: 100%;
  left: 0;
  white-space: normal;
  z-index: 9999;
  width: 300px;
  font-size: 0.9em;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

/* Touch devices — show bubble on tap */
.note-bubble:active::after {
  content: attr(title);
  position: absolute;
  background: #333;
  color: #fff;
  padding: 8px 10px;
  border-radius: 6px;
  top: 100%;
  left: 0;
  white-space: normal;
  z-index: 9999;
  width: 300px;
  font-size: 0.9em;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

/* 🔹 Hide modal by default */
.app-modal {
  display: none;                /* <- This hides it initially */
  position: fixed;
  z-index: 1000;                /* Ensures it appears on top when shown */
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0,0,0,0.4); /* Semi-transparent background */
}

/* 🔹 Modal content styling */
.app-modal-content {
  background-color: #fff;
  margin: 15% auto;
  padding: 20px;
  border-radius: 8px;
  width: 400px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

/* 🔹 Buttons */
#appModalCloseBtn,
#appModalConfirmBtn,
#appModalCancelBtn {
  padding: 8px 16px;
  margin-left: 5px;
  cursor: pointer;
}


/* GROK */

  /* Make the whole page use flex so the table can grow properly */
  .min-vh-100 {
    min-height: 100vh;
  }

  /* This makes the table body scroll independently */
  .overflow-auto {
    max-height: calc(100vh - 200px); /* Adjust 200px based on your header height */
  }

  /* Optional: improve sticky header appearance */
  thead.sticky-top th {
    background-color: #f8f9fa !important;
    border-top: none;
    box-shadow: 0 2px 2px -1px rgba(0, 0, 0, 0.1);
  }

  /* Ensure sticky works inside Bootstrap table */
  table {
    width: 100%;
    table-layout: auto;
  }

  /* Optional: better mobile experience */
  @media (max-width: 768px) {
    .overflow-auto {
      max-height: calc(100vh - 250px);
    }
  }

/* Limit the width of the rep dropdown column */
.rep-select {
    max-width: 140px;        /* adjust to taste */
    width: 100%;
    white-space: normal;     /* allows wrapping */
    overflow-wrap: break-word;
    word-break: break-word;
}

/* Force options to wrap too */
.rep-select option {
    white-space: normal !important;
    overflow-wrap: break-word;
}

.site-logo {
    height: 60px;     /* adjust as needed */
}

/* --- NAVIGATION BAR STYLING --- */
.navbar .nav-link {
    color: #555 !important;         /* consistent gray */
    font-weight: normal;
}

.navbar .nav-link.active {
    font-weight: bold !important;   /* selected page highlighted */
    color: #555 !important;         /* keep same color */
}

.navbar .nav-link:hover {
    color: #000 !important;         /* optional darker hover */
}

/* Selected dropdown toggle should also appear bold */
.navbar .dropdown-toggle.active {
    font-weight: bold !important;
}


</style>