/* Importing fonts from the second file, must be at the top */
@import url("https://fonts.googleapis.com/css?family=Poppins:400,500,600,700&display=swap");

/* --- Localization Styles (from File 2 - must be separate for RTL/LTR) --- */
body[lang="ar"] {
  direction: rtl;
  text-align: right;
}

body[lang="ar"] .left-form {
  left: 0;
  direction: ltr;
}

body[lang="ar"] .form-check-input {
  float: right;
  margin-left: 8px;
}

body[lang="ar"] .radio-item {
  direction: rtl;
  text-align: right;
}

body[lang="ar"].text-overlay {
  direction: rtl;
}

body[lang="ar"] .radio-label {
  padding-right: 30px;
  padding-left: unset;
}

body[lang="ar"] .radio-circle {
  right: 0;
  left: unset;
}

body[lang="en"] .radio-item {
  direction: ltr;
  text-align: left;
}

body[lang="en"] .radio-dropdown i {
  margin-right: 10px;
}

body[lang="en"] .radio-dropdown .dropdown-menu {
  right: 0;
  left: auto;
}

body[lang="en"] .radio-label {
  padding-left: 30px;
  padding-right: unset;
}

body[lang="en"] .radio-circle {
  left: 0;
  right: unset;
}

/* --- Body Styles (Merged & FIXED for Centering) --- */
body {
  display: flex;
  min-height: 100vh;
  /* FIX: Use min-height to ensure full-viewport height for centering */
  width: 100vw;
  overflow-x: hidden;
  font-family: "DM Sans", sans-serif;
  margin: 0;
  padding: 0;
  position: relative;
  background-color: white;
  justify-content: center;
  /* Horizontal centering */
  align-items: center;
  /* Vertical centering */
}

/* ------------------------------------Shapes CSS (Merged) ----------------------------------------- */
.logo {
  top: 1vh;
  position: fixed;
  width: 7vw;
  height: auto;
  left: 2vw;
  z-index: 1;
}

.top-right {
  position: fixed;
  width: 20vw;
  height: auto;
  top: 0;
  right: -0.1vw;
  z-index: -1;
}

.bottom-left {
  height: 65vh;
  position: fixed;
  width: 40vw;
  bottom: -1.2vh;
  left: -10vw;
  z-index: -1;
}

/* ------------------------------------Form Container CSS (FIXED for Centering) ----------------------------------------- */
.container {
  flex-direction: row;
  height: 75vh;
  width: 80vw;
  z-index: 1;
  background-color: white;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.5);
  border-radius: 10px;
  overflow: hidden;

  flex-shrink: 0;
  /* FIX: Prevents the container from shrinking inside the flex parent */
}

.form {
  position: relative;
  margin: 20px;
  justify-items: self-start;
  justify-self: self-start;
}

.form-column {
  height: 40vh;
}

.form-label {
  margin-bottom: 5px;
  color: #b77848;
  align-self: start;
}

.form-control {
  margin-bottom: 5px;
  margin-left: 0px;
  margin-right: 0px;
}

.form-control:focus {
  border-color: white;
  box-shadow: 0 0 10px rgba(183, 120, 72, 1);
}

.form-check input:focus {
  border-color: #b77848;
  box-shadow: 0 0 10px rgba(183, 120, 72, 1);
}

.form-check-input:checked {
  background-color: #b77848;
  border-color: #b77848;
}

.form-check-input {
  margin: 8px;
  border-color: #4e2e159a;
}

.forgot-password-link {
  color: #b77848;
  font-size: 10px;
  display: block;
  text-align: left;
  margin-top: 5px;
  text-decoration: none;
}

.forgot-password-link:hover {
  color: #965a38;
  text-decoration: underline;
}

/* ------------------------------------Form & Input CSS ----------------------------------------- */
form {
  background: #fff;
  padding: 50px;
  border-radius: 12px;
  /* box-shadow: 0px 4px 12px rgba(0,0,0,0.1); */
  max-width: 900px;
  width: 100%;
}

h2 {
  text-align: center;
  margin-bottom: 20px;
  color: #2c3e50;
}

.flex {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 15px;
}

.field {
  flex: 1;
  min-width: 220px;
  display: flex;
  flex-direction: column;
  margin-bottom: 15px;
}

.label {
  font-weight: 600;
  margin-bottom: 6px;
  color: #34495e;
}

input,
select,
textarea {
  width: 100%;
  padding: 6px;
  border-radius: 6px;
  border: 1px solid #ccc;
  font-size: 14px;
  outline: none;
  transition: border 0.2s ease-in-out;
}

input:focus,
select:focus,
textarea:focus {
  border-color: #2980b9;
  box-shadow: 0px 0px 5px rgba(41, 128, 185, 0.3);
}

textarea {
  resize: vertical;
}

/* Specific visibility controls from File 1 */
#parent-field,
#faculty-field,
#batch-field,
#major-field,
#index-field,
#id-field {
  display: none;
}

/* Text style from File 1 */
p b {
  color: #ec8305;
}

/* ------------------------------------Radio Group/Tabs (from File 1) ----------------------------------------- */
.radio-group {
  display: flex;
  justify-content: center;
  gap: 60px;
  position: relative;
  background: #f4f4f4;
  padding: 10px;
  border-radius: 30px;
  width: fit-content;
  margin: 50px auto;
}

.radio-group input {
  display: none;
}

.radio-group label {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 20px;
  height: 35px;
  cursor: pointer;
  border-radius: 20px;
  font-family: sans-serif;
  font-size: 14px;
  color: #333;
  position: relative;
  z-index: 1;
  user-select: none;
  text-align: center;
}

.slider {
  position: absolute;
  top: 10px;
  left: 0;
  background: #ec8305;
  border-radius: 20px;
  z-index: 0;
  transition: all 0.4s cubic-bezier(0.68, -0.55, 0.27, 1.55);
}

.radio-group label.active {
  color: white;
}

.radio-group label span {
  display: inline;
}

.tabicon {
  display: none;
  width: 24px;
  height: 24px;
  vertical-align: middle;
}

.radio-group label.active .tabicon {
  filter: brightness(0) invert(1);
}

/* ------------------------------------Cards CSS (from File 2)----------------------------------------- */
.card-container {
  perspective: 1000px;
  width: 100%;
  border: none;
  height: 80vh;
  border-radius: 8px;
}

.card {
  width: 100%;
  height: 65vh;
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.6s ease-in-out;
  justify-content: center;
  border: none;
}

.front,
.back {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background-color: white;
  border: none;
  border-radius: 8px;
}

.back {
  transform: rotateY(180deg);
}

.card.flip-parent {
  transform: rotateY(180deg);
}

.card.flip-student {
  transform: rotateY(-180deg);
  justify-content: center;
}

.card.flip-hospital {
  transform: rotateY(180deg);
}

.card.flip-agent {
  transform: rotateY(-180deg);
  justify-content: center;
}

/* ------------------------------------Localization Radio Dropdown (from File 2) ----------------------------------------- */
.radio-dropdown {
  position: relative;
  cursor: pointer;
  display: flex;
  flex-direction: row;
  align-self: end;
  justify-self: end;
  justify-content: end;
}

.radio-dropdown i {
  font-size: 1.5rem;
  margin-left: 10px;
}

.radio-dropdown .dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  background-color: white;
  border: 1px solid #ccc;
  padding: 10px;
  border-radius: 4px;
  width: fit-content;
}

.radio-dropdown:hover .dropdown-menu {
  display: block;
}

.radio-item {
  display: flex;
  align-items: center;
  margin-bottom: 10px;
}

.radio-input {
  display: none;
}

.radio-label {
  cursor: pointer;
  padding-right: 10px;
  position: relative;
  display: inline-block;
  padding-right: 30px;
}

.radio-circle {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background-color: #fff;
  border: 2px solid #ccc;
  transition: all 0.3s ease;
}

.radio-input:checked + .radio-label .radio-circle {
  background-color: #965a38;
  border-color: #965a38;
}

.radio-input:checked + .radio-label .radio-circle::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: #fff;
}

/* ------------------------------------Button Styles (Merged) ----------------------------------------- */
.btn {
  width: 100%;
}

.submit-btn {
  width: 30%;
  border-radius: 10px;
  background-color: #ec8305;
  transition: ease-in-out 0.2s;
  padding: 10px 20px;
  border: none;
  color: white;
  font-size: 15px;
  cursor: pointer;
  margin: 0 auto;
}

.submit-btn:hover {
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  background-color: #ec8305;
  transform: translateY(-4px);
}
.submit-btn:focus, 
.submit-btn:active, 
.submit-btn:focus-visible {
    outline: none !important;
    border: none !important;
    box-shadow: none; /* Removes the default inner shadow browsers add on click */
}
.view-btn {
  padding: 8px;
  border: none;
  background: #ec8305;
  color: #fff;
  border-radius: 6px;
  cursor: pointer;
  margin-top: 25px;
  transition: ease-in-out 0.2s;
}
.view-btn:hover {
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  background-color: #ec8305;
  transform: translateY(-4px);
}
.btn-custom {
  color: white;
  background-color: #b77848;
  border: 1px solid #b77848;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.btn-custom:hover {
  color: white;
  background-color: #736c74;
  border: 1px solid #b77848;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.btn-custom:active {
  color: white;
  background-color: #736c74;
  border: 1px solid #b77848;
}

/* ------------------------------------Image/Overlay CSS (from File 2)----------------------------------------- */
.img-container {
  height: 100%;
  width: 60.333%;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  direction: ltr;
}

.img-container img {
  width: 53vw;
  height: 76vh;
  object-fit: cover;
  z-index: 1;
}

.text-overlay {
  top: 50%;
  left: 25%;
  position: absolute;
  z-index: 2;
  text-align: center;
  color: white;
  font-weight: bold;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
  user-select: none;
}

/* ------------------------------------Staff Home Styles (from File 2) ----------------------------------------- */
.choices {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 40px;
  justify-content: center;
  justify-items: center;
  align-items: center;
  padding: 20px;
}

.choice {
  padding: 50px;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
  min-width: 200px;
  text-align: center;
}

.choice:hover {
  background: #ec8305;
  color: white;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  transform: translateY(-8px);
}

.choice span {
  font-size: 18px;
  font-weight: 500;
}

/* Mobile responsive for choices */
@media (max-width: 576px) {
  .choices {
    gap: 20px;
    padding: 15px 10px;
  }
  
  .choice {
    padding: 30px 20px;
    min-width: 150px;
    width: calc(50% - 10px);
  }
  
  .choice span {
    font-size: 14px;
  }
}

@media (max-width: 374px) {
  .choices {
    gap: 15px;
    padding: 10px;
  }
  
  .choice {
    padding: 25px 15px;
    min-width: 120px;
    width: 100%;
  }
  
  .choice span {
    font-size: 13px;
  }
}

@media (min-width: 577px) and (max-width: 768px) {
  .choices {
    gap: 30px;
  }
  
  .choice {
    padding: 40px 30px;
    min-width: 180px;
  }
  
  .choice span {
    font-size: 16px;
  }
}

a {
  text-decoration: none;
  color: black;
}

.dropdown {
  position: relative;
  display: inline-block;
}

.dropbtn {
  background: none;
  border: none;
  cursor: pointer;
  font-size:30px;
  color: white;
  right: 0;
}

.dropdown-content {
  display: none;
  position: absolute;
  right: 0;
  background-color: #fff;
  min-width: 160px;
  box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.2);
  border-radius: 8px;
  z-index: 1;
}

.dropdown-content a {
  color: #333;
  padding: 12px 16px;
  text-decoration: none;
  display: block;
  transition: background 0.2s;
}

.dropdown-content a:hover {
  background-color: #f5f5f5;
}

.dropdown:hover .dropdown-content {
  display: block;
}

.profile {
  position: absolute;
  top: 15px;
  right: 20px;
}

.dropdownchoices {
  position: relative;
  display: inline-block;
}

.dropdownchoices .choice:hover {
  background: #ec8305;
  color: white;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  transform: translateY(-5px);
}

.dropdownchoices .dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: white;
  height: fit-content;
  min-width: 160px;
  box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.2);
  border-radius: 8px;
  z-index: 10;
}

.dropdownchoices .dropdown-menu a {
  display: block;
  padding: 12px 16px;
  color: black;
  text-decoration: none;
}

.dropdownchoices .dropdown-menu a:hover {
  background: #f2f2f2;
}

.dropdownchoices:hover .dropdown-menu {
  display: block;
}

.actions {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 40px;
  justify-content: center;
  justify-items: center;
  align-items: center;
}

.action {
  padding: 10px;
  border-radius: 4px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
}

.action:hover {
  background: #ec8305;
  color: white;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  transform: translateY(-4px);
}

.content-wrapper {
  background: white;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.05);
}

/* ------------------------------------Media Queries (Merged) ----------------------------------------- */
@media (max-width: 768px) {
  /* Positioning from File 2 */
  .radio-dropdown {
    right: -53vw;
    top: 2.5vh;
  }

  .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 75vh;
    width: 70vw;
    margin: 20px;
  }

  .logo {
    top: 5vh;
    position: fixed;
    width: 60px;
    height: auto;
    left: 5vw;

  }

  .row {
    margin: 0;
    width: auto;
  }

  .col-5 {
    margin: 0;
    flex: 0 0 auto;
    width: auto;
    padding: 0;
  }

  .col-7 {
    display: none;
  }

  .card-container {
    width: 65vw;
    height: 60vh;
    margin: 20px;
  }

  .card {
    height: 60vh;
    width: auto;
  }

  /* Decorative images - show but smaller on mobile */
  .bottom-left {
    max-width: 80px;
   bottom: -25vh;
    left: 0;
  }

  .top-right {
    max-width: 80px;
    top: 0;
    right: 0;
  }

  /* Radio Group/Tabs responsiveness from File 1 */
  .radio-group label span {
    display: none;
  }

  .radio-group {
    gap: 20px;
  }

  .tabicon {
    display: inline-block;
  }
}

/* Very small phones */
@media (max-width: 374px) {
  .bottom-left,
  .top-right {
    max-width: 90px;

  }
   .bottom-left{
    bottom: -2vh;
  }
}

/* Landscape mode - hide decorative images */
@media (max-width: 896px) and (orientation: landscape) {
  .bottom-left,
  .top-right {
    display: none;
  }

}

/* ////--------------------reports css/ */
/* REPLACE your current canvas rule with this: */
canvas:not(.reports-container canvas) {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 0;
    margin-top: 0;
    margin-left: 0;
    box-shadow: 0px 4px 12px rgba(0, 0, 0, 0.15);
}

/* ADD this to strip all decoration from report canvases: */
.reports-container canvas {
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 0;
    margin: 0;
    box-shadow: none;
}
/* ADD THIS after the canvas rule: */
#categoryChart {
  margin-top: 30px;
  margin-left: 20px;
}
#circleChart,
#solvedChart,
#receivedChart {
  margin: auto;
  display: block;
 
  max-width: 300px;
  position: relative;
  z-index: 10;
}

.table thead.custom-header th {
  background-color: #ec8305 !important;
  color: #ffffff !important;
  border-color: rgba(0, 0, 0, 0.08) !important;
  vertical-align: middle;
  font-weight: 600;
  text-align: center;
}

ul {
  list-style: none;
  padding: 0;
  margin-bottom: 20px;
  display: flex;
  gap: 15px;
}

ul li a {
  text-decoration: none;
  color: #ec8305;
  font-weight: bold;
  padding: 8px 15px;
  border: 1px solid #ec8305;
  border-radius: 4px;
  transition: all 0.3s;
}

ul li a:hover {
  background-color: #ec8305;
  color: white;
}

ul li a.active {
  background-color: #ec8305;
  color: white;
}

.reports-container {
  width: 80vw;
  /* default: nearly full width on small screens */
  max-width: none;
  /* remove the hard cap */
  margin: 20px auto;
  background-color: white;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);

  /* Scroll */
  max-height: 90vh;
  overflow-y: auto;
  overflow-x: hidden;
}

h5 {
  margin-bottom: 20px;
  color: #ec8305;
}

.form-label {
  font-weight: bold;
  margin-right: 10px;
}

.form-select,
input[type="date"] {
  padding: 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
  margin-right: 10px;
}

#filterBtn {
  background-color: #ec8305;
  color: white;
  border: none;
  padding: 8px 15px;
  border-radius: 4px;
  cursor: pointer;
}

#filterBtn:hover {
  background-color: #d67604;
}

#customRange {
  margin-top: 15px;
  padding: 15px;
  background-color: #f9f9f9;
  border-radius: 4px;
}



/* إضافة ستايل للتبويبات */
.radio-group {
  position: relative;
  display: flex;
  background: #f0f0f0;
  border-radius: 30px;
  padding: 5px;
  width: 100%;
  max-width: 500px;
}

.radio-group label {
  flex: 1;
  text-align: center;
  padding: 10px 15px;
  cursor: pointer;
  border-radius: 30px;
  z-index: 2;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.radio-group label.active {
  color: #fff;
}

.radio-group .slider {
  position: absolute;
  top: 5px;
  left: 0;
  border-radius: 30px;
  background: #ec8305;
  transition: all 0.3s ease;
  z-index: 1;
}

.tabicon {
  width: 24px;
  height: 24px;
  margin-bottom: 5px;
}

.flex {
  display: flex;
  gap: 20px;
  margin-bottom: 20px;
}

.flex .field {
  flex: 1;
}

.form-control {
  background-color: rgba(211, 211, 211, 0.3);
}

.call-form {
  margin-top: -10vh;
}

/* card code */
.profile-card {
  position: fixed;
  bottom: 30px;
  right: 30px;
  min-width: 100px;
  max-width: 100px;
  background: #fff;
  border-radius: 12px;
  padding: 16px;
  cursor: pointer;
  z-index: 999;
  box-shadow: 0px 4px 12px rgba(0, 0, 0, 0.2);
  overflow: hidden;
  transition: max-width 0.5s ease, max-height 0.5s ease;
  box-sizing: border-box;
}

.profile-card.expanded {
  max-width: 320px;
  max-height: 90vh;
  overflow-y: auto;
}

.profile-card .profile-img {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  overflow: hidden;
  margin-bottom: 12px;
}

.rounded-circle {
  width: 70px;
  height: 70px;
  object-fit: cover;
}

.profile-card .profile-img img {
  width: 70px;
  height: 70px;
  object-fit: cover;
}

.profile-card .card-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.profile-card .card-header img {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
}

.card-expand {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.5s ease, opacity 0.3s ease;
  opacity: 0;
  margin-top: 10px;
}

.profile-card.expanded .card-expand {
  max-height: 800px;
  opacity: 1;
}

.profile-card .name {
  font-size: 22px;
  font-weight: bold;
  margin-bottom: 15px;
}

.profile-card .info {
  font-size: 14px;
  color: #555;
  margin: 6px 0;
}

.profile-card .info span {
  font-weight: bold;
  color: #000;
}

.chart-container {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 240px;
  padding: 10px;
  margin: 10px auto;
}

/* Scroll buttons */
.scroll-to-top,
.scroll-to-bottom {
  position: fixed;
  right: 30px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background-color: #EC8305;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  cursor: pointer;
  z-index: 1000;
  opacity: 0;
  transition: opacity 0.3s ease-in-out;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  border: none;
}

.scroll-to-top {
  bottom: 30px;
}

.scroll-to-bottom {
  bottom: 90px;
}

.scroll-to-top.show,
.scroll-to-bottom.show {
  opacity: 1;
}

/* Celebration overlay */
.celebration-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.celebration-content {
  background: #fff;
  padding: 30px 40px;
  border-radius: 16px;
  box-shadow: 0 10px 40px rgba(0,0,0,0.3);
  animation: popIn 0.6s ease;
  max-width: 90%;
  text-align: center;
}

.celebration-gif {
  width: 220px;
  max-width: 100%;
  margin-bottom: 10px;
}

@keyframes popIn {
  from {
    transform: scale(0.7);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

#callsChart {
  width: 100% !important;
  height: 280px !important;
  /* adjust chart height */
}

:root {
  --bg: #f6f8fa;
  --card: #ffffff;
  --muted: #6b7280;
  --accent: #3b82f6;
}


h1 {
  margin: 0 0 8px 0;
  font-size: 20px;
}

p.lead {
  margin: 0 0 18px 0;
  color: var(--muted);
  font-size: 13px;
}

.chart-wrap {
  position: relative;
  width: 100%;
  height: 420px;
  /* responsive height */
}

.controls {
  margin-top: 14px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

button.secondary {
  background: #e6eefc;
  color: #0f172a;
  box-shadow: none;
  font-weight: 600;
}

label.small {
  font-size: 13px;
  color: var(--muted);
  display: flex;
  gap: 8px;
  align-items: center;
}

input[type="file"] {
  display: none;
}

.small-note {
  font-size: 12px;
  color: var(--muted);
  margin-top: 10px;
}

@media (max-width: 520px) {
  .chart-wrap {
    height: 320px;
  }
}
 /* profil css */
  .user-profile-card {
      max-width: 600px;
      margin: 50px auto;
      background: #fff;
      border-radius: 12px;
      box-shadow: 0px 4px 12px rgba(0,0,0,0.1);
      padding: 30px;
    }
    .profile-header {
      text-align: center;
      margin-bottom: 20px;
    }
    .profile-header i {
      font-size: 80px;
      color: #6b4226;
    }


/* reports responsiveness */
/* ============================================================
   REPORTS – SHARED NAVIGATION
   Applies to all 4 report pages
   ============================================================ */
/* UPDATE this in app.css: */
.chart-wrap-card {
    width: 100%;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 1px 8px rgba(0,0,0,0.12);
    border: 1px solid #e9ecef;
    display: flex;
    flex-direction: column;
    overflow: visible;       /* allow content to show */
    height: auto;            /* no fixed height */
}

.row.mb-4 {
    display: flex;
    align-items: stretch;
}

.row.mb-4 > [class*="col-"] {
    display: flex;
    flex-direction: column;
}

.row.mb-4 .chart-wrap-card {
    flex: 1;                 /* fills full column height */
}

.chart-wrap-card .card-body {
    padding: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: visible;
}
/* Make chart-wrap-card support Bootstrap's card-header and card-body */
.chart-wrap-card .card-header {
    padding: 12px 16px;
    background-color: #fff;
    border-bottom: 1px solid rgba(0,0,0,0.08);
}

/* Also remove max-width: 900px — it was limiting the card width */
body { overflow-x: hidden; }
.reports-container { padding: 0 10px; }
/* Desktop (992px+) */
@media (min-width: 992px) {
    .reports-container ul {
        display: flex;
        flex-direction: row;
        gap: 10px;
        list-style: none;
        padding: 0;
       margin: 20px auto 30px auto;
        width: 60%;              /* controls overall width — change to 50% or 70% as needed */
    }

    .reports-container ul li { flex: 1; }

    .reports-container ul li a {
        display: block;
        padding: 8px 12px;       /* reduced from 12px 20px */
        background: white;
        border-radius: 8px;
        text-align: center;
        text-decoration: none;
        color: rgb(54, 53, 53);
        font-size: 13px;         /* reduced from default ~16px */
        transition: all 0.2s ease;
    }

    .reports-container ul li a.active { background: #ec8305; color: white; }
    .reports-container ul li a:hover:not(.active) { background: #ec8305; color: white;  }
    .reports-container h5 { font-size: 20px; margin: 20px 0; }
}
/* Tablet (577px–991px) */
@media (min-width: 577px) and (max-width: 991px) {
 .reports-container{
  margin-top: 10vh;    
    padding: 0 10px;
     z-index: 1;
  }

    .reports-container ul {
        display: flex; flex-wrap: wrap; justify-content: center;
        gap: 8px; list-style: none; padding: 10px 0; margin-bottom: 20px;
    }
    .reports-container ul li { flex: 1; min-width: 150px; }
    .reports-container ul li a {
        display: block; padding: 12px 15px;  background: white;
        border-radius: 8px; text-align: center; font-size: 14px;
        text-decoration: none; color: #495057; transition: all 0.2s ease;
    }
    .reports-container ul li a.active { background: #ec8305; color: white; font-weight: 600; }
  .reports-container ul li a:hover:not(.active) { background: #ec8305; color: white;  }
}

/* Mobile (max 768px) */
@media (max-width: 768px) {
.reports-container{
    margin-top: 20vh;   
    padding: 0 10px;
     z-index: 1;
  }

    .reports-container ul {
        display: flex; flex-direction: column; gap: 8px;
        padding: 10px 0; margin-bottom: 20px; list-style: none;
    }
    .reports-container ul li { width: 100%; }
    .reports-container ul li a {
        display: block; padding: 12px 15px; background: white;
        border-radius: 8px; text-align: center; font-size: 14px;
        text-decoration: none; color: #495057; transition: all 0.2s ease;
    }
    .reports-container ul li a.active { background: #ec8305; color: white; font-weight: 600; }
   .reports-container ul li a:hover:not(.active) { background: #ec8305; color: white; }
    .reports-container h5 { font-size: 18px; margin: 15px 0; font-weight: 600; }
}

/* Touch devices */
@media (hover: none) and (pointer: coarse) {
    .reports-container ul li a {
        min-height: 44px; display: flex;
        align-items: center; justify-content: center;
    }
    * { -webkit-tap-highlight-color: transparent; }
}


/* ============================================================
   GENERAL REPORT (reports/index)
   ============================================================ */

.reports-container canvas { top: 50px; }

.chart-container {
    position: relative; width: 100%;
    max-width: 800px; margin: 0 auto; padding: 20px 10px;
}

@media (max-width: 768px) {
    .reports-container > div { margin-bottom: 80px !important; }
    .form-label { font-size: 14px; font-weight: 600; margin-bottom: 8px; display: block; }
    .form-select {
        width: 100%; padding: 10px 12px; font-size: 14px;
        border: 1px solid #ced4da; border-radius: 6px; margin-bottom: 15px;
    }
    #customRange { margin-top: -70px !important; margin-bottom: 80px !important; }
    #customRange label { font-size: 13px; font-weight: 600; margin-top: 10px; margin-bottom: 5px; display: block; }
    #customRange input[type="date"] {
        width: 100%; padding: 10px 12px; font-size: 14px;
        border: 1px solid #ced4da; border-radius: 6px; margin-bottom: 12px;
    }
    #customRange button {
        width: 100%; padding: 10px; font-size: 14px; background: #ec8305;
        color: white; border: none; border-radius: 6px; cursor: pointer;
        font-weight: 600; transition: background 0.2s ease;
    }
    #customRange button:hover { background: #d07004; }
    #customRange button:active { transform: scale(0.98); }
    .chart-container { padding: 15px 5px; height: auto; min-height: 300px; }
    #categoryChart { max-height: 350px !important; }
}

@media (max-width: 374px) {
    .form-select, #customRange input[type="date"], #customRange button { font-size: 13px; padding: 8px 10px; }
    .chart-container { min-height: 250px; }
    #categoryChart { max-height: 300px !important; }
}

@media (min-width: 375px) and (max-width: 576px) {
    .chart-container { min-height: 300px; }
}

@media (min-width: 577px) and (max-width: 991px) {
    #customRange { display: flex; flex-wrap: wrap; gap: 15px; align-items: flex-end; }
    #customRange label { flex: 1; min-width: 200px; }
    #customRange button { width: auto; padding: 10px 30px; }
    .chart-container { min-height: 350px; }
}

@media (min-width: 992px) {
    #customRange { display: flex; gap: 15px; align-items: flex-end; }
    #customRange label { flex: 1; max-width: 300px; }
    #customRange button { width: auto; padding: 10px 30px; }
    .chart-container { min-height: 400px; }
}

@media (hover: none) and (pointer: coarse) {
    #customRange button, .form-select, #customRange input[type="date"] { min-height: 44px; }
}

@media (max-width: 896px) and (orientation: landscape) {
    .chart-container { min-height: 250px; }
    #categoryChart { max-height: 300px !important; }
}


/* ============================================================
   DETAILED REPORT (reports/calls-per-user)
   ============================================================ */
.detailed-chart-container {
    position: relative;
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
      margin-top: 0 !important;
    /* Remove ALL height constraints */
}

.detailed-chart-container canvas {
    max-width: 100%;
    width: 100% !important;
    height: auto !important;
}

#rushHourChart { max-width: 100% !important; }
.rush-hour-container { height: 300px; width: 100%; }
#expandChartModal .modal-body { height: calc(100vh - 70px); }
#expandChartModal canvas { width: 100% !important; height: 100% !important; }

@media (max-width: 768px) {
    #filterForm { margin-top: 0 !important; margin-bottom: 20px; }
    #filterForm label { font-size: 14px; font-weight: 600; margin-bottom: 5px; display: block; }
    #filterForm select, #filterForm input {
        width: 100%; padding: 10px 12px; font-size: 14px;
        border: 1px solid #ced4da; border-radius: 6px; margin-bottom: 12px;
    }
    #custom-range { margin-top: 10px !important; }
    #custom-range input[type="date"] { margin-bottom: 10px; }
    #filterBtn { width: 100%; padding: 10px; font-size: 14px; border-radius: 6px; }
    .card { margin-bottom: 20px; border-radius: 10px; }
    .card-header { padding: 12px 15px; border-radius: 10px 10px 0 0 !important; }
    .card-header h6 { font-size: 14px !important; margin: 0; }
    .card-body { padding: 15px; }
    .rush-hour-container { height: 220px; }
    .detailed-chart-container { height: 220px; max-width: 220px; }
    .row.mb-4 { margin-bottom: 20px !important; }
    .col-md-6, .col-md-4 { margin-bottom: 15px; }
    .table-responsive { overflow-x: auto; -webkit-overflow-scrolling: touch; }
    #reportTable { font-size: 12px; min-width: 600px; }
    #reportTable th, #reportTable td { padding: 8px 6px; white-space: nowrap; }
    #reportTable thead th { font-size: 11px; font-weight: 600; }
    #expandChartModal .modal-body { height: calc(100vh - 120px); padding: 15px; }
    .modal-header { padding: 12px 15px; }
    .modal-title { font-size: 16px; }
}

@media (max-width: 374px) {
    .card-header h6 { font-size: 13px !important; }
    .detailed-chart-container { height: 180px; max-width: 180px; }
    .rush-hour-container { height: 200px; }
    #reportTable { font-size: 11px; }
}

@media (min-width: 577px) and (max-width: 991px) {
    .detailed-chart-container { height: 250px; max-width: 250px; }
    .rush-hour-container { height: 280px; }
    #reportTable { font-size: 13px; }
}

@media (min-width: 992px) {
    .detailed-chart-container { height: 300px; max-width: 300px; }
    .rush-hour-container { height: 300px; }
}

@media (hover: none) and (pointer: coarse) {
    #filterBtn { min-height: 44px; }
}

@media (max-width: 896px) and (orientation: landscape) {
    .detailed-chart-container { height: 180px; max-width: 200px; }
    .rush-hour-container { height: 200px; }
    .row.mb-4 { margin-bottom: 15px !important; }
}


/* ============================================================
   MILESTONES REPORT (reports/milestones)
   ============================================================ */

@media (max-width: 768px) {
    .milestones-table { display: block; width: 100%; border: none; }
    .milestones-table thead { display: none; }
    .milestones-table tbody { display: block; }
    .milestones-table tbody tr {
        display: block; margin-bottom: 15px; border: 1px solid #dee2e6;
        border-radius: 10px; padding: 15px; background: #fff;
        box-shadow: 0 2px 6px rgba(0,0,0,0.08);
        transition: transform 0.2s ease, box-shadow 0.2s ease;
    }
    .milestones-table tbody tr:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,0.12); }
    .milestones-table tbody td {
        display: block; text-align: left !important; padding: 10px 0;
        border: none; position: relative; padding-left: 50%; font-size: 14px;
    }
    .milestones-table tbody td:before {
        content: attr(data-label); position: absolute; left: 0; width: 45%;
        padding-right: 10px; font-weight: 600; color: #495057; font-size: 13px; text-align: left;
    }
    .milestones-table tbody td .badge { display: inline-block; padding: 6px 12px; font-size: 13px; font-weight: 600; border-radius: 6px; }
    .milestones-table tbody tr td.text-muted { text-align: center !important; padding: 20px; font-size: 14px; padding-left: 0; }
    .milestones-table tbody tr td.text-muted:before { display: none; }
}

@media (max-width: 374px) {
    .milestones-table tbody tr { padding: 12px; }
    .milestones-table tbody td { font-size: 13px; padding-left: 48%; }
    .milestones-table tbody td:before { font-size: 12px; width: 43%; }
    .milestones-table tbody td .badge { font-size: 12px; padding: 5px 10px; }
}

@media (min-width: 577px) and (max-width: 991px) {
    .milestones-table tbody tr { padding: 18px; }
    .milestones-table tbody td { font-size: 15px; }
}

@media (min-width: 992px) {
    .milestones-table { display: table; }
    .milestones-table thead { display: table-header-group; }
    .milestones-table tbody { display: table-row-group; }
    .milestones-table tbody tr { display: table-row; border: none; padding: 0; box-shadow: none; }
    .milestones-table tbody tr:hover { background-color: #f8f9fa; transform: none; }
    .milestones-table tbody td { display: table-cell; padding: 12px !important; text-align: center !important; }
    .milestones-table tbody td:before { display: none; }
    .milestones-table thead th { background-color: #f8f9fa; font-weight: 600; padding: 12px; border-bottom: 2px solid #dee2e6; }
}

@media (hover: none) and (pointer: coarse) {
    .milestones-table tbody tr { min-height: 44px; }
}


/* ============================================================
   VOICE CALLS REPORT (reports/voicecalls)
   ============================================================ */

#mainAlert {
    position: fixed; top: 20px; right: 20px;
    min-width: 250px; z-index: 1055; box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.pagination .page-link { color: #ec8305; border: 1px solid #dee2e6; margin: 0 2px; border-radius: 4px; transition: all 0.2s ease; }
.pagination .page-item.active .page-link { color: white; background-color: #ec8305; border-color: #ec8305; box-shadow: 0 4px 6px rgba(236,131,5,0.3); }
.pagination .page-link:hover { background-color: #f8f9fa; transform: translateY(-1px); }

@media (max-width: 768px) {
    #filterForm .col-md-3 { flex: 0 0 100%; max-width: 100%; margin-bottom: 10px; }
    #filterForm .form-label { font-size: 13px; font-weight: 600; margin-bottom: 5px; }
    #filterForm .form-control, #filterForm .form-select { font-size: 14px; padding: 8px 12px; }
    #filterForm .col-12.d-flex { flex-direction: row !important; gap: 10px; }
    #filterForm button { flex: 1; max-width: none !important; }
    #mainAlert { right: 10px; left: 10px; min-width: auto; font-size: 14px; }
    #resultsCount { font-size: 13px; margin-bottom: 10px; }

    #resultsTable { display: block; width: 100%; }
    #resultsTable thead { display: none; }
    #resultsTable tbody { display: block; }
    #resultsTable tbody tr {
        display: block; margin-bottom: 15px; border: 1px solid #dee2e6;
        border-radius: 8px; padding: 12px; background: #fff;
        box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    }
    #resultsTable tbody td { display: block; text-align: left !important; padding: 8px 0; border: none; position: relative; padding-left: 45%; }
    #resultsTable tbody td:before { content: attr(data-label); position: absolute; left: 0; width: 40%; padding-right: 10px; font-weight: 600; color: #495057; font-size: 13px; }
    #resultsTable tbody td.d-flex { display: flex !important; padding-left: 45%; }
    #resultsTable tbody td .btn-sm { font-size: 12px; padding: 5px 10px; }

    .pagination { flex-wrap: wrap; gap: 4px; justify-content: center; }
    .pagination .page-item { margin: 2px; }
    .pagination .page-link { padding: 6px 10px; font-size: 13px; }

    .modal-dialog { margin: 10px; max-width: calc(100% - 20px); }
    .modal-body { padding: 15px; }
    .modal-body table { font-size: 13px; }
    .modal-body table th, .modal-body table td { padding: 6px; }
    #StatusModal .table-responsive { overflow-x: auto; }
    #StatusModal table { font-size: 12px; min-width: 500px; }
    .modal-body .form-label { font-size: 13px; }
    .modal-body .form-control, .modal-body .form-select { font-size: 14px; }
}

@media (max-width: 400px) {
    .pagination .page-item:not(.active):not(:first-child):not(:last-child):not(:nth-child(2)):not(:nth-last-child(2)) { display: none; }
}

@media (min-width: 768px) and (max-width: 991px) {
    #filterForm .col-md-3 { flex: 0 0 50%; max-width: 50%; }
    #resultsTable { font-size: 14px; }
    #resultsTable th, #resultsTable td { padding: 8px; }
}

@media (min-width: 992px) {
    #resultsTable tbody td:before { display: none; }
}

@media (hover: none) and (pointer: coarse) {
    #filterForm .form-control, #filterForm .form-select { min-height: 44px; }
}