
/* Global styles for Just Limos Portal */

body {
  font-family: sans-serif;
  padding: 2rem;
  background-color: #f9f9f9;
}

form, table {
  margin-top: 1rem;
  width: 100%;
  max-width: 1000px;
}

#tripForm.trip-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  background: #ffffff;
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

#tripForm.trip-grid label {
  flex: 1 1 calc(50% - 1rem);
  display: flex;
  flex-direction: column;
  font-weight: 600;
  color: #333;
}

#formWrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
}

#topButtons {
  width: 100%;
  max-width: 1000px;
  display: flex;
  justify-content: flex-end;
  gap: 1rem;
  margin-bottom: 1rem;
}

.centered-form {
  display: flex;
  justify-content: center;
  align-items: flex-start; /* top-aligned, change to center for vertical centering */
  min-height: 50vh; /* or 100vh for vertical center on whole page */
  width: 100%;
}



#tripForm.trip-grid label.full-width {
  flex: 1 1 100%;
}

#tripForm.trip-grid input,
#tripForm.trip-grid select,
#tripForm.trip-grid textarea {
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 6px;
  background-color: #fefefe;
  margin-top: 4px;
  font-size: 14px;
  transition: border-color 0.2s;
}

#tripForm.trip-grid input:focus,
#tripForm.trip-grid select:focus,
#tripForm.trip-grid textarea:focus {
  outline: none;
  border-color: #007bff;
}

#tripForm.trip-grid button {
  background-color: #007bff;
  color: white;
  border: none;
  padding: 12px;
  border-radius: 6px;
  font-size: 16px;
  margin-top: 10px;
  cursor: pointer;
  transition: background-color 0.3s;
}

#tripForm.trip-grid button:hover {
  background-color: #0056b3;
}

#tripForm.hidden {
  display: none;
}

.auth-controls {
  margin-bottom: 1rem;
}

#statusMsg {
  color: red;
  margin-top: 1rem;
  font-weight: bold;
}

table {
  border-collapse: collapse;
  margin-top: 2rem;
  width: 100%;
}

th, td {
  border: 1px solid #ccc;
  padding: 8px;
  text-align: left;
}

th {
  background-color: #f0f0f0;
}

.hide-email,
.hide-phone,
.hide-row {
  display: none;
}


#tripHeaderRow h2 {
  margin: 0;
  font-size: 1.4rem;
}

#tripHeaderRow #statusMsg {
  color: green;
  font-weight: bold;
  font-size: 1rem;
}
.table-wrapper {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch; /* Smooth scroll on iOS */
  margin-top: 1rem;
}

#tripTable th,
#tripTable td {
    border: 1px solid #ddd; /* Add borders for visual debugging - REMOVE THIS LATER IF NOT NEEDED */
    padding: 8px;
    text-align: left;
    white-space: nowrap; /* Prevent text wrapping within cells initially */
    overflow: hidden;    /* Hide overflowing content */
    text-overflow: ellipsis; /* Add ellipsis for hidden content */
}

/* Ensure header cells are always treated as table cells */
#tripTable thead th {
    background-color: #f2f2f2; /* Light background for headers */
    font-weight: bold;
}

/* Add a specific rule for the checkbox column to make it smaller */
#tripTable th:first-child,
#tripTable td:first-child {
    width: 5%; /* Adjust as needed for checkbox */
    text-align: center;
	
}


/* Adjust width for actions column */
#tripTable th:last-child,
#tripTable td:last-child {
    width: 120px; /* Adjust as needed for buttons */
    text-align: center;
}

/* Optional: Adjust width for phone and pickup date if they are too wide */
#tripTable th:nth-child(4), /* Phone column */
#tripTable td:nth-child(4) {
    width: 120px; /* Example width for phone */
}

#tripTable th:nth-child(5), /* Pick-up Date column */
#tripTable td:nth-child(5) {
    width: 120px; /* Example width for pick-up date */
}
/* ---------------------------------------------------------------------- */


@media (max-width: 600px) {
  body {
    padding: 1rem;
  }

  #tripTable th,
  #tripTable td {
    font-size: 13px;
    padding: 6px;
  }

  .table-wrapper {
    margin-top: 1rem;
  }
}

.table-wrapper::after {
  content: '⬅️ Scroll to see more';
  display: block;
  font-size: 12px;
  color: #888;
  text-align: center;
  margin-top: 4px;
}

@media (max-width: 600px) {
  #tripForm.trip-grid label {
    flex: 1 1 100%; /* Full-width on small screens */
  }

  #searchSection {
    flex-direction: column;
    align-items: stretch;
  }

  #searchSection input,
  #searchSection button {
    width: 95%; /* Take full width on mobile */
  }

  #searchSection button {
    margin-top: 0.5rem;
  }
}



@media (max-width: 500px) {
  .auth-controls {
    flex-direction: column;
    align-items: flex-start;
  }
}

#searchSection {
  margin-top: 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: .5rem; /* 👈 Increase this */
  align-items: center;
}


#searchField,
#searchInput {
  padding: 10px 14px;
  font-size: 16px;
  border: 2px solid #007bff;
  border-radius: 6px;
  outline: none;
  background-color: #f0f8ff;
  color: #333;
  flex: 1 1 auto;
}

#searchField:focus,
#searchInput:focus {
  border-color: #0056b3;
  background-color: #e6f0ff;
}

#searchSection button {
  background-color: #28a745;
  color: white;
  font-size: 16px;
  padding: 10px 18px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

#searchSection button:hover {
  background-color: #218838;
}



/* Make the entire form area responsive */
#tripForm {
  width: 100%;
  box-sizing: border-box;
  overflow-x: auto;
}

/* Prevent child inputs from expanding too far */
#tripForm.trip-grid input,
#tripForm.trip-grid select,
#tripForm.trip-grid textarea {
  width: 100%; /* Ensure they stay inside their flex box */
  box-sizing: border-box;
}

/* Optional: Hide horizontal scroll if undesired */
body {
  overflow-x: hidden;
}
@media (max-width: 600px) {
  #tripForm.trip-grid {
    padding: 1rem;
    gap: 0.75rem;
  }

  #tripForm.trip-grid input,
  #tripForm.trip-grid select,
  #tripForm.trip-grid textarea {
    font-size: 15px;
  }
}

button.add-trip-button {
  background-color: #800080 !important; /* Purple */
  color: #fff !important;
  padding: 12px 20px;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
  transition: background-color 0.3s ease;
}

button.add-trip-button:hover {
  background-color: #660066 !important; /* Darker purple on hover */
}





#pickupTime {
  background-image: url('https://cdn-icons-png.flaticon.com/512/61/61112.png'); /* tiny clock icon */
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 16px;
  padding-right: 30px;
}

#flatRate {
  background-color: #dcffdb !important;
  border: none !important;
  border-radius: 8px !important;
  padding: 12px 16px !important;
  font-size: 16px !important;
  font-weight: bold !important;
  color: #333 !important;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1) !important;
  transition: background-color 0.3s ease !important;
  text-align: right !important;
  cursor: pointer !important;  /* ✅ moved inside block */
}

#flatRate:focus {
  outline: none !important;
  background-color: #ffeb99 !important;
}

.wide-stop-input {
  width: 100% !important;
  min-width: 300px;
}

.customer-message {
  color: green !important;
  background-color: #e8f5e9 !important;
  border: 1px solid #a5d6a7 !important;
  border-radius: 6px !important;
  font-weight: 600 !important;
  padding: 10px !important;
  font-size: 14px !important;
}

input[name^="paymentTime"] {
  background-color: #f8f9fa;
  border: 1px solid #ccc;
  padding: 6px 8px;
  font-size: 13px;
  color: #555;
  width: 100%;
}


.add-payment-button {
  background-color: #ffefea !important;
  color: black !important;
  font-size: 16px !important;
  padding: 10px 18px !important;
  border: none !important;
  border-radius: 6px !important;
  cursor: pointer !important;
  transition: background-color 0.3s ease !important;
}

.add-payment-button:hover {
  background-color: #218838 !important;
}


.add-pickup-button {
  background-color: #d4edda !important; /* Light green */
  color: #155724 !important;
  font-size: 16px !important;
  padding: 10px 18px !important;
  border: none !important;
  border-radius: 6px !important;
  cursor: pointer !important;
  transition: background-color 0.3s ease !important;
  font-weight: bold;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.add-pickup-button:hover {
  background-color: #c3e6cb !important; /* Slightly darker on hover */
}


.add-stop-button {
  background-color: #f8d7da !important; /* Light red */
  color: #721c24 !important;
  font-size: 16px !important;
  padding: 10px 18px !important;
  border: none !important;
  border-radius: 6px !important;
  cursor: pointer !important;
  transition: background-color 0.3s ease !important;
  font-weight: bold;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.add-stop-button:hover {
  background-color: #f5c6cb !important; /* Slightly darker on hover */
}


#tripForm.trip-grid input.wide-stop-input {
  width: 100%;
  box-sizing: border-box;
}

.confirmation-button {
  display: inline-block;
  background-color: #007bff; !important; /* Bootstrap primary blue */
  color: green;
  padding: 0.5rem 1rem;
  font-weight: bold;
  font-size: 18px; !important;
  border-radius: 5px;
  border: none;
  user-select: all;
  cursor: default;
  width: 200px;
  text-align: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

/* Optional: input focus styles to remove default outline */
.confirmation-button:focus {
  outline: none;
  box-shadow: 0 0 0 3px #80bdff;
}


#tripForm input:disabled,
#tripForm select:disabled,
#tripForm textarea:disabled {
  background-color: #f2f2f2;
  color: #888;
  cursor: not-allowed;
}


  .inline-plus-btn {
    background: none;
    border: none;
    font-weight: bold;
    font-size: 1rem;
    color: #007bff;
    cursor: pointer;
    padding: 0;
    margin: 0;
    line-height: 1;
  }






#lastUpdateInfo {
  background: #f0f0f0;
  padding: 0.5em 1em;
  border-radius: 4px;
  margin-top: 1em;
  font-size: 0.85em;
  color: #333;
}





.button-primary {
  background: linear-gradient(135deg, #00c3ff, #0079ff);
  color: #fff;
  border: none;
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.1s ease;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.button-primary:hover {
  background: linear-gradient(135deg, #0094e0, #005bb5);
}

.button-primary:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

.button-secondary {
  background: #eee;
  color: #333;
  border: 2px solid #ccc;
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.1s ease;
}

.button-secondary:hover {
  background: #ddd;
}

.button-icon {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}




.payment-wrapper .history {
  margin-top: 0.5em;
  padding: 0.5em;
  background: #f9f9f9;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.payment-history-block {
  display: block; /* full width */
  width: 100%;
  padding: 0.5em;
  background: #fff;
  border-bottom: 1px solid #eee;
  margin-bottom: 0.25em;
}

.payment-history-block {
  width: 100%;
  padding: 8px 12px;
  margin-bottom: 6px;
  border: 1px solid #ddd;
  border-radius: 4px;
  background: #fafafa;
  font-family: monospace;
  line-height: 1.5;
}

/* Shared nav button base style */
.nav-button {
  display: inline-block;
  padding: 0.5rem 1.3rem;
  color: #fff;
  border: none;
  border-radius: 5px;
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  transition: background 0.22s, box-shadow 0.22s;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}

.nav-button:hover {
  background: #0056b3;
}

#navLinks {
  display: flex;
  gap: 0.75rem; /* space between buttons */
  align-items: center;
}



  /* ✅ Auth + settings buttons keep flat style */
  #navLinks button:not(.nav-button) {
    display: block;
    width: 100%;
    text-align: left;
    padding: 0.75rem 1rem;
    border: none;
    background: none;
    border-bottom: 1px solid #eee;
    cursor: pointer;
  }

  #settingsMenu {
    position: static;
    border: none;
    box-shadow: none;
    background: #f9f9f9;
  }

 #settingsMenu a {
  display: block;
  width: 100%;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid #eee;
}

/* Distinct button colors */
.nav-quotes       { background:#0d6efd; }
.nav-quotes:hover { background:#084298; }

.nav-reservations       { background:#28a745; }
.nav-reservations:hover { background:#186c2f; }

.nav-dispatch       { background:#fd7e14; }
.nav-dispatch:hover { background:#c75c03; }

.nav-reporting       { background:#6f42c1; }
.nav-reporting:hover { background:#59359a; }



/* End of styles */
