:root {
  --back: #adadad;

  --girl: #2b323b;
  --boy: #2b323b;
}

html,
body {
  height: 100%;
  margin: 0;
  display: flex;
  flex-direction: column;
}

/* Main wrapper for content between navbar and footer */
.main-content {
  flex: 1; /* This will make the content area take up the remaining space */
}

body {
  font-family: Roboto, sans-serif;
}

/* Navbar Styles */

.navbar {
  background-color: #dadada;
}

.nav-item {
  font-weight: bold;
  font-size: 1.125rem;
}

.nav-item .nav-link {
  white-space: nowrap;
}

.navbar-actions {
  display: flex;
  flex-wrap: nowrap;
  flex-direction: column; /* Align vertically on small screens */
  justify-content: right;
  align-items: center;
  gap: 3rem;
  width: 100%;
}

.conditional-button .btn {
  color: #555;
  font-weight: bold;
  border: none;
  margin-right: 2rem;
  background: none;
}

/* General hover effect for nav links */
.navbar .nav-link:hover,
.back-coaches:hover {
  transform: scale(1.05);
  transition: transform 0.3s ease;
  opacity: 0.9;
  box-shadow: inset 200px 0 0 0 var(--back);
}

.navbar-nav {
  margin-right: 0.875rem; /* Pull the entire navbar nav items slightly left */
}

.greet-user {
  max-width: fit-content;
  display: inline;
  font-weight: 300;
  font-size: 1rem;
  padding: 0;
  line-height: 1.5;
  margin: 0;
  text-align: center;
}

.greet-user .dropdown-menu {
  text-align: left; /* Align dropdown items to the left for usability */
}

.greet-user .dropdown-menu {
  min-width: 10rem; /* Ensure dropdown has a reasonable width */
  padding: 0.5rem; /* Add padding for dropdown content */
  text-align: center; /* Center-align dropdown items */
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* Add subtle shadow */
}

.greet-user .dropdown-menu li {
  margin: 0.25rem 0; /* Add spacing between list items */
}

/* Logout Button Styling */
.greet-user .dropdown-menu button.nav-link {
  display: block;
  width: 90%;
  padding: 0.5rem;
  background: transparent;
  border: none;
  color: #000;
  text-align: center;
  cursor: pointer;
}

.greet-user .dropdown-menu button.nav-link:hover {
  background: #f8f9fa; /* Add a subtle hover effect */
  color: #000; /* Ensure hover text color remains consistent */
}

.search-bar {
  border-radius: 10px;
  border: none;
  background-color: #f2f3f5;
  box-shadow: 0 1px 8px 0 rgba(0, 0, 0, 0.2);
}

.search-bar .form-control {
  height: 38px;
  border: none;
  border-radius: 10px 0 0 10px;
  box-shadow: none;
}

.search-bar .form-control::placeholder {
  font-size: 0.9rem; /* Adjust placeholder text size if needed */
}

.search-bar .form-control:focus {
  outline: none;
  border-color: #007bff;
  box-shadow: 0 0 4px rgba(0, 123, 255, 0.5);
}

/* Remove old background images */
.navbar-toggler .navbar-toggler-icon {
  display: none; /* Hides the default toggler icon */
}

/* Font Awesome icon styles */
.navbar-toggler i {
  font-size: 1.25rem; /* Same size for hamburger and X icons */
  color: #000; /* Match your navbar color */
}

/* Navbar Styles end */

.app-logo {
  position: absolute; /* Position relative to the viewport */
  max-width: 230px;
  max-height: 100%;
  z-index: 10;
  top: 0;
  margin: 0;
  align-self: flex-start; /* Align to the top-left corner */
  cursor: pointer; /* Makes it look clickable */
}

.app-logo:hover {
  transform: scale(1.1);
  transition: transform 0.3s ease;
  opacity: 0.9;
}

.coach-card {
  box-sizing: border-box;
  transition: opacity 0.3s ease;
}

/* Hide the entire column instead of just the card */
.coaches-page .col.hidden {
  display: none !important;
}

.coaches-page .row {
  gap: 2rem;
}

.btn-link i {
  font-size: 1.2rem;
  color: #6c757d; /* Matches Bootstrap default text-muted color */
}

/* Card Styles */

.card {
  box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2);
  transition: 0.3s;
  max-width: 15.3125rem;
  max-height: 28rem;
  box-sizing: border-box;
  border-radius: 8px;
  padding: 0;
}

.card img {
  max-width: 100%;
  max-height: 15rem;
  display: block;
  object-fit: cover;
  /* object-fit: contain; */
  border-radius: 8px 8px 0 0;
  padding: 0;
}

.detail-left img {
  max-width: 100%;
  max-height: 400px;
}
.card:hover {
  box-shadow: 0 8px 16px 0 rgba(0, 0, 0, 0.2);
}

.card-header {
  font-size: 0.875rem;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.card-header a {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}

.disabled-link {
  pointer-events: none;
  color: gray;
  text-decoration: none;
  cursor: not-allowed;
}

/* end of card */

/* card detail */
.card-detail-container {
  width: 780px;
  position: relative;
  border-radius: 10px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  border: 1px solid #e3e3e3;
}

.card-detail-container .row {
  overflow: visible;
}

.detail-right {
  border-bottom-left-radius: 10px;
  border-bottom-right-radius: 10px;
}

.card-detail-container .detail-right .card-header {
  border-top-left-radius: 0;
  border-top-right-radius: 10px;
}

.rounded-start-0 {
  border-top-left-radius: 10px !important;
  border-top-right-radius: 0 !important;
  border-bottom-left-radius: 0;
}

.card-detail-action {
  background-color: #f8f9fa;
  padding: 15px;
  border-top: 1px solid #ddd;
  border-bottom-left-radius: 10px; /* Bottom-left rounded corner */
  border-bottom-right-radius: 10px; /* Bottom-right rounded corner */
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.card-detail-container::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 10px;
  border-bottom-left-radius: 10px;
  border-bottom-right-radius: 10px;
  z-index: 0;
}

/* end of card detail */

.header-link,
.header-link:hover {
  text-decoration: none;
}

.boy-card .card-header {
  background-color: #c2c2c2;
}
.boy-card .card-body,
.boy-card .card-body p a {
  color: var(--boy);
  font-size: 0.87rem;
}
.girl-card .card-header {
  background-color: #c2c2c2;
}
.girl-card .card-body,
.girl-card .card-body p a {
  color: var(--girl);
  font-size: 0.87rem;
}

.favorite-btn {
  background: none;
  border: none;
  color: #ff6666; /* Heart color */
  font-size: 20px;
  cursor: pointer;
  transition: transform 0.3s ease, color 0.3s ease;
}

.favorite-btn:hover {
  color: #ff3333; /* Slightly darker heart on hover */
  transform: scale(1.1); /* Add a hover effect for feedback */
}

.btn-fav {
  min-width: 120px;
  max-width: 150px;
  width: 100%;
  height: 35px;
  border: none;
  border-radius: 10px;
  background: linear-gradient(
    to right,
    #bf953f,
    #fcf6ba,
    #b38728,
    #fbf5b7,
    #aa771c
  );
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  color: rgb(42, 37, 5);
  font-weight: 400;
  /* position: relative; */
  /* z-index: 2; */
  transition-duration: 3s;
  box-shadow: 5px 5px 10px rgba(0, 0, 0, 0.144);
  background-size: 200% 200%;
  text-decoration: none;
  cursor: pointer;
}

.btn-fav:hover {
  transform: scale(0.95);
  transition-duration: 2s;
  animation: gradient 3s ease infinite;
  background-position: right;
  text-decoration: none;
  font-size: 1.05rem;
}

/* Card Styles end */

.modal-body .form-label {
  display: block;
  margin-bottom: 0.5rem; /* Add space between the label and input field */
}

.modal-body .form-control {
  display: block;
  width: 100% !important; /* Ensure full width regardless of Bootstrap constraints */
  max-width: 100%; /* Prevent overflow */
  box-sizing: border-box; /* Include padding and border in the width */
}

/* form */
.form-container {
  background-color: #f8f9fa; /* Subtle background color */
  border: 1px solid #ddd; /* Light border */
  border-radius: 8px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Override Bootstrap btn-danger */
.btn-danger {
  background-color: #ed553b;
  color: #ffffff; /* White text */
  border: none;
}

.btn-outline-danger:hover {
  background-color: #f5f5f5;
  color: #ed553b;
  transition: background-color 0.3s ease;
  box-shadow: inset 0 0 0 2px #ed553b;
}

.btn-info {
  background-color: #6499ce;
  color: #ffffff;
  border: none;
}

.btn-info:hover {
  background-color: #4585c4;
  color: #ffffff;
  transition: background-color 0.3s ease;
  box-shadow: inset 0 0 0 2px #31669b;
}

/* Styles for the close button */
.close-button {
  position: absolute;
  top: 3px; /* Adjust spacing from the top */
  right: 3px; /* Adjust spacing from the right */
  z-index: 10; /* Ensure it stays above card content */
  border-radius: 30%;
  padding: 7px;
  width: 1.625; /* Set equal width */
  height: 1.625; /* Set equal height */
  background-color: #eff5fa;
}

.close-button:hover {
  background-color: #adadad;
  box-shadow: inset 0 0 0 2px #31669b;
}

.btn-outline-secondary:hover {
  background-color: #c2c2c2;
  box-shadow: inset 0 0 0 2px #31669b;
}

.coach-headline {
  text-align: center;
  padding: 2rem;
  background: linear-gradient(white, #f9f9f9); /* Light gradient */
  border-radius: 8px; /* Optional: rounded corners */
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); /* Optional: subtle shadow */
}

.coach-headline h1 {
  font-size: 2.25rem;
  font-weight: 700;
  color: #d4af37; /* Gold */
  letter-spacing: 1px;
  margin-bottom: 1rem;
}

.coach-headline h2 {
  font-size: 1.25rem;
  font-weight: 400;
  color: #333; /* Dark Grey */
  margin-bottom: 0.5rem;
}

.coach-headline p {
  font-size: 0.875rem;
  font-weight: 300;
  color: #555; /* Greyish Black */
  margin: 0;
}

.text-list-coach {
  font-weight: 300;
  color: #555;
}

/* working so hard to style this warning but the template accidentally deleted */

.warning {
  background-color: #f8d7da;
  border: 1px solid #f5c2c7;
  border-radius: 8px; /* Rounded corners for modern look */
  padding: 0;
}

.warning p:first-child {
  font-size: 1.5rem; /* Larger font for headline */
}

.warning p {
  color: #6c757d; /* Muted gray for secondary text */
  font-size: 1rem;
  margin-bottom: 1rem; /* Space between paragraphs */
}

.warning a {
  font-size: 1rem;
  font-weight: 500;
  text-decoration: none; /* Remove underline */
  color: white; /* Text color for button */
}

.warning a:hover {
  transform: scale(1.05);
  transition-duration: 2s;
  animation: gradient 3s ease infinite;
  background-position: right;
  text-decoration: none;
}

/* warning ends */

.custom-text {
  color: #548fc9;
}

.badge-active {
  background-color: #4585c4;
  color: #ffffff;
  font-size: 0.75rem;
  border: none;
}
.badge-inactive {
  color: #ed553b;
  border: solid;
}

/* Filter Bar Container */
.filter-bar {
  background: #f5f5f5;
  border-radius: 8px; /* Rounded corners */
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1); /* Subtle shadow */
  padding: 1.5rem 1rem;
  margin-top: 10px;
  display: flex;
  align-items: stretch;
  gap: 1rem; /* Even spacing between elements */
  /* height: 60px; */
}

/* Dropdowns and Inputs */
.filter-bar select {
  border: 1px solid #ddd; /* Subtle border */
  border-radius: 6px; /* Slightly rounded */
  /* padding: 0.6rem; */
  font-size: 0.875rem;
  color: #333; /* Neutral text color */
  background-color: #f9f9f9; /* Light background */
  box-shadow: inset 0 0 0 2px #e2ebf3;
  transition: all 0.2s ease;
}

.filter-bar select:hover,
.filter-bar select:focus {
  border-color: #548fc9;
  box-shadow: 0 0 4px rgba(255, 215, 0, 0.5); /* Glow effect */
}

/* Filter Feature */

.filter-bar .btn-primary {
  font-size: 0.875rem;
  background-color: #e2ebf3; /* Gold */
  color: #335a81;
  border: none;
  box-shadow: inset 0 0 0 2px #5ca8f5;
}

.filter-bar .btn-secondary {
  font-size: 0.875rem;
  background-color: #e5e4e2;
  color: #536878;
  border: none;
  box-shadow: inset 0 0 0 2px #c0c0c0;
}

.filter-bar .btn-primary:hover {
  background-color: #335a81;
  color: #fff;
  box-shadow: 0 0 6px rgba(255, 215, 0, 0.5); /* Glow effect */
}

.filter-bar .btn-secondary:hover {
  background-color: #91a3b0;
  color: #fff; /* Slightly darker on hover */
}

/* Italicize placeholder text */
.form-select.placeholder-active {
  font-style: italic;
  color: #6c757d; /* Placeholder color */
}

.form-select option {
  font-style: normal;
  color: #000;
}

.filter-bar .filter-select-wrapper select {
  max-width: 100%; /* Ensure select elements stretch within their column */
}

.filter-bar .filter-select-wrapper:nth-of-type(1) select {
  width: 250px; /* Fine-tune Country filter width */
}

.filter-bar .filter-select-wrapper:nth-of-type(2) select {
  width: 125px; /* Fine-tune Belt Rank width */
}

.filter-bar .filter-select-wrapper:nth-of-type(3) select {
  width: 125px;
}

.filter-select-wrapper {
  margin-right: 0.5rem;
}

/* Filter bar ends */

/* Quick Preview */
.quick-preview {
  background: rgba(255, 255, 255, 0.95);
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 152px;
  display: none; /* Start hidden */
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 16px;
  text-align: center;
  border: 1px solid #ccc;
  z-index: 10;
  pointer-events: none; /* Prevent accidental clicks */
}

.card-top {
  position: relative; /* Ensures .card-top is an independent hover target */
  z-index: 5;
}

/* Hover-based trigger */
.card-top:hover + .quick-preview {
  display: flex; /* Ensure visibility */
  pointer-events: auto; /* Enable interaction */
}

/* Additional styling for preview content */
.preview-bio {
  font-size: 14px;
  margin-bottom: 12px;
  color: #444;
}

.locked-details {
  font-size: 12px;
  color: #888;
  margin-bottom: 16px;
}

.lock-icon {
  font-size: 16px;
  color: #ff9800;
  margin-right: 4px;
}

.signup-btn {
  background: #6499ce;
  color: white;
  padding: 8px 12px;
  border-radius: 4px;
  text-decoration: none;
  font-size: 14px;
}

.signup-btn:hover {
  background: #31669b;
}
/* end of Quick Review */

/* footer style */
footer {
  background-color: var(--back);
  color: white;
  font-size: 18px;
  border-bottom: 3px solid var(--back);
}
/* footer style ends*/

/* search result */
.search-title {
  font-size: 1.25rem;
  font-weight: 400;
  margin-top: 1rem;
  margin-bottom: 0.5rem;
  padding: 0;
  color: #333;
}

.no-results {
  text-align: center;
  color: #999;
  font-size: 1rem;
  margin-top: 2rem;
  white-space: nowrap;
}
/* search result ends */

/* Custom styling for success messages */

.alert-success {
  background-color: #d0e0f0;
  color: #264f79;
  border-color: #548fc9;
  max-width: 300px;
  max-height: 32px; /* Height restriction */
  overflow: hidden; /* Clip any overflow */
  text-overflow: ellipsis;
  white-space: nowrap; /* Prevent text wrapping */
  margin: 0 auto; /* Center horizontally */
  padding: 0.25rem 1rem; /* Adjust padding to fit height and keep spacing */
  display: flex; /* Use flexbox for alignment */
  align-items: center; /* Vertically align text and icon */
}

.alert-success .btn-close {
  position: relative; /* Ensure positioning aligns with flex container */
  margin-left: auto; /* Push the button to the far right */
  padding: 0; /* Remove extra padding */
  line-height: 1; /* Keeps the button compact */
}

/* Optional: Add custom hover effect */
.alert-success:hover {
  background-color: #b1cce7; /* Slightly darker shade for hover */
  color: #1b334b; /* Adjust hover text color if needed */
}

.alert-error {
  background-color: #f8d7da;
  color: #842029; /* Dark red text */
  border-color: #f5c2c7;
  max-width: 500px;
  max-height: 32px; /* Restrict height */
  overflow: hidden; /* Clip extra content */
  text-overflow: ellipsis; /* Add ellipsis for overflow */
  white-space: nowrap;
  margin: 0 auto; /* Center horizontally */
  padding: 0.25rem 1rem; /* Compact padding */
  display: flex; /* Use flexbox for alignment */
  align-items: center; /* Vertically align text and close icon */
}

.alert-error .btn-close {
  position: relative; /* Ensures alignment with the flex container */
  margin-left: auto; /* Push the close button to the right */
  padding: 0; /* Remove extra padding */
  line-height: 1; /* Compact the close button */
}

/* Responsive Adjustments */

@media (max-width: 991px) {
  .btn-fav {
    align-self: stretch;
    width: 100%;
  }

  /* List text and View Favorites  */
  .list-text-viewfav {
    transform: scale(0.85);
    margin: 0;
  }

  .navbar-actions {
    flex-direction: row; /* Align side by side on larger screens */
    flex-wrap: wrap; /* Allow wrapping */
    justify-content: center; /* Center the content (search bar, buttons) */
    align-items: center;
    margin-bottom: 0.5rem;
    gap: 0;
  }

  .search-bar {
    margin-bottom: 0.5rem; /* Ensure spacing when stacked */
  }

  .navbar-nav.ms-auto {
    justify-content: center;
    align-items: center;
  }

  .greet-user {
    margin-left: 0;
    text-align: center;
  }

  /* FILTER SECTION */

  .col-md-10.offset-md-1 {
    width: 100%;
  }

  /* Adjust font size of the icon */
  .filter-bar i {
    font-size: 0.85rem; /* Smaller icon */
  }

  /* Shrink select dropdowns */
  .filter-bar .filter-select-wrapper select {
    font-size: 0.9rem; /* Smaller text */
    padding: 0.3rem; /* Reduce inner padding */
  }

  /* Adjust button sizes */
  .filter-bar button,
  .filter-bar a {
    font-size: 0.9rem; /* Smaller text */
    padding: 0.3rem 0.6rem; /* Less padding around buttons */
  }

  /* Adjust spacing between elements */
  .filter-bar form {
    gap: 0.5rem; /* Reduce spacing between form elements */
  }

  /* Make buttons share less space if needed */
  .filter-bar .d-flex .btn {
    width: auto; /* Prevents buttons from being too wide */
  }

  .filter-bar .filter-select-wrapper select {
    font-size: 0.85rem; /* Reduce font size */
  }

  /* CARD DETAIL */

  .card-detail-container {
    transform: scale(0.85);
    position: relative;
    margin: 0;
  }
  /* CARD DETAIL ends */
}

/* Adjust the form for smaller viewports */
@media (max-width: 767px) {
  .btn-fav {
    align-self: stretch;
    width: 100%;
  }

  .list-text-viewfav {
    transform: scale(0.75);
    margin: 0;
  }
  /* fiter bar */
  .filter-bar {
    position: relative;
    display: flex;
    transform: scale(0.95);
  }

  .filter-bar .d-flex {
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
  }

  .filter-bar .filter-select-wrapper {
    width: 100%; /* Ensure each select takes full width */
    margin-right: 0;
  }

  .filter-bar .col-md-3 {
    display: flex;
    justify-content: space-between;
    width: 100%;
  }

  .filter-bar i.fas.fa-filter {
    align-self: flex-start; /* Align the icon with the left of the form */
    margin-bottom: 0.5rem; /* Add spacing between the icon and selects */
  }

  .coach-headline {
    display: none;
  }

  /* CARD DETAIL  767 PX*/

  .d-flex.align-items-center.mb-3 {
    margin-bottom: 0.625rem !important;
  }

  .container.d-flex.flex-column {
    height: 100vh;
  }

  .card-detail-container {
    display: flex;
    position: relative;
    flex-direction: column;
    align-items: stretch;
    height: 100%;
    width: 400px;
  }

  .card-detail-header {
    display: none;
  }

  .rounded-start-0 {
    border-top-right-radius: 10px !important;
  }

  .card-detail-container .detail-right .card-header {
    border-top-right-radius: 0;
  }

  /* card detail ends */

  footer {
    display: none;
  }

  /* Search result */
  .search-wrapper .row-cols-1 .col {
    display: flex;
    justify-content: center;
    align-items: center;
  }

  .search-wrapper .row-cols-1 .col > * {
    flex-grow: 1;
    width: 100%;
  }

  /* Search result ends */

  .alert-error {
    transform: scale(0.85);
    max-width: 90%; /* Fit alert to viewport width */
    max-height: none; /* Allow the alert to grow vertically */
    white-space: normal; /* Allow text to wrap */
    flex-direction: column; /* Stack text and button vertically */
    align-items: stretch; /* Stretch the container */
    text-align: left; /* Align text to the left */
    padding: 1rem; /* Comfortable padding */
    position: relative; /* Enable positioning for child elements */
  }

  .alert-error .btn-close {
    position: absolute; /* Take the button out of the flow */
    top: 0.5rem; /* Position close button at the top */
    right: 0.5rem; /* Align it to the right */
    padding: 0; /* Remove extra padding */
    line-height: 1; /* Keep it compact */
  }
}

/* for distance purpose */

@media (max-width: 768px) {
  .btn-fav {
    align-self: stretch;
    width: 100%;
  }

  .coaches-page .row > .col {
    flex: 0 0 calc(50% - 1.5rem);
    max-width: calc(50% - 1.5rem);
  }
}

@media (max-width: 576px) {
  .coaches-page .row > .col {
    flex: 0 0 calc(100% - 1.5rem);
    max-width: calc(100% - 1.5rem);
  }
}

@media (min-width: 575px) and (max-width: 1200px) {
  .card-header {
    font-size: 14px;
    letter-spacing: 0.3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
}
