body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  background: #f4f4f4;
}

header {
  background: #007bff;
  color: #fff;
  padding: 1rem 0;
}

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  max-width: 900px;
  margin: 0 auto;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.section-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.section-actions label {
  font-weight: 600;
  color: #374151;
}

.section-actions select {
  padding: 0.55rem 0.75rem;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  background: #fff;
}

#driverLogin {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0;
}

nav ul {
  list-style: none;
  display: flex;
  gap: 1rem;
  margin: 0;
  padding: 0;
}

nav a {
  color: #fff;
  text-decoration: none;
  font-weight: bold;
}

.translate-tools {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.translate-label {
  font-size: 0.9rem;
  font-weight: bold;
}

#google_translate_element {
  min-width: 140px;
}

#google_translate_element .goog-te-gadget {
  color: #fff;
  font-size: 0;
}

#google_translate_element .goog-te-gadget .goog-te-combo {
  border: none;
  border-radius: 4px;
  padding: 0.35rem 0.5rem;
  font-size: 0.9rem;
}

main {
  max-width: 900px;
  margin: 2rem auto;
  background: #fff;
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

section {
  margin-bottom: 2rem;
}

#driverPortalAccess {
  margin-bottom: 1.5rem;
}

#driverPortalNotice {
  margin: 0;
  color: #4b5563;
}

#driverVehicleSection {
  margin-bottom: 1.5rem;
}

#driverRequestsSection {
  margin-bottom: 1.5rem;
}

#driverVehicleCard {
  border: 1px solid #d1d5db;
  border-radius: 10px;
  background: #f9fafb;
  padding: 1rem;
}

#driverRequestsList {
  display: grid;
  gap: 1rem;
}

#passengerHistoryList {
  display: grid;
  gap: 1rem;
}

#bitcoinSupportSection {
  border: 1px solid #d1d5db;
  border-radius: 10px;
  background: #f9fafb;
  padding: 1rem;
}

#bitcoinSupportSection h3 {
  margin: 0 0 0.5rem;
}

#bitcoinSupportSection p {
  margin: 0.35rem 0;
  color: #374151;
}

.btc-address-row {
  margin-top: 0.75rem;
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-wrap: wrap;
}

#bitcoinAddress {
  display: inline-block;
  padding: 0.6rem 0.75rem;
  border-radius: 8px;
  background: #111827;
  color: #f9fafb;
  font-size: 0.95rem;
  word-break: break-all;
}

#copyBitcoinAddressButton {
  width: auto;
  margin: 0;
  padding: 0.6rem 0.9rem;
  background: #1f2937;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-weight: bold;
}

#bitcoinCopyStatus {
  margin-top: 0.6rem;
  color: #166534;
  min-height: 1.2rem;
}

#driverRequestsActionStatus,
#passengerRequestStatus {
  margin: 0.5rem 0 0;
  color: #374151;
}

#passengerDecisionActions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1rem 0;
}

#passengerRequestForm {
  display: grid;
  gap: 0.9rem;
}

.passenger-request-help {
  margin: 0;
  color: #4b5563;
}

.passenger-request-field {
  display: grid;
  gap: 0.35rem;
}

.passenger-request-field label {
  font-weight: 600;
  color: #1f2937;
}

#passengerDecisionActions button,
#passengerRequestForm button {
  width: auto;
}

#declineRidePriceButton {
  background: #b91c1c;
}

#declineRidePriceButton:hover {
  background: #991b1b;
}

#selectedRideSummary {
  margin: 1rem 0;
}

.selected-ride-card,
.ride-result-card {
  border: 1px solid #d1d5db;
  border-radius: 10px;
  background: #f9fafb;
  padding: 1rem;
}

.ride-result-card {
  margin-bottom: 0.75rem;
}

.ride-result-card button {
  width: auto;
  margin-top: 0.75rem;
}

.driver-request-card {
  border: 1px solid #d1d5db;
  border-radius: 10px;
  background: #f9fafb;
  padding: 1rem;
}

.passenger-history-card {
  border: 1px solid #d1d5db;
  border-radius: 10px;
  background: #f9fafb;
  padding: 1rem;
}

.passenger-history-card h3 {
  margin: 0 0 0.5rem;
  color: #111827;
}

.passenger-history-card p {
  margin: 0.35rem 0;
  color: #374151;
}

.driver-request-card h3 {
  margin: 0 0 0.5rem;
  color: #111827;
}

.driver-request-card p {
  margin: 0.35rem 0;
  color: #374151;
}

.driver-request-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1rem;
}

.driver-request-actions button {
  width: auto;
  margin: 0;
}

.request-status {
  text-transform: capitalize;
  font-weight: 700;
}

.request-status-pending {
  color: #b45309;
}

.request-status-approved {
  color: #166534;
}

.request-status-rejected {
  color: #b91c1c;
}

#driverVehicleStatus {
  margin: 0;
  color: #374151;
}

#driverVehicleDetails {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin: 1rem 0 0;
}

#driverVehicleDetails div {
  padding: 0.85rem;
  background: #fff;
  border-radius: 8px;
  border: 1px solid #e5e7eb;
}

#driverVehicleDetails dt {
  font-size: 0.85rem;
  font-weight: bold;
  color: #6b7280;
  margin-bottom: 0.35rem;
}

#driverVehicleDetails dd {
  margin: 0;
  color: #111827;
  font-weight: 600;
}

#driverStatus {
  margin: 0;
  color: #fff;
  font-size: 0.9rem;
  white-space: nowrap;
}

#driverLoginForm {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
}

#driverLoginForm input {
  width: 170px;
  margin: 0;
}

#driverLoginForm button {

  #copyBitcoinAddressButton {
    width: 100%;
  }

  width: auto;
  margin: 0;
  white-space: nowrap;
}

#driverMapStatus {
  margin: 0 0 0.75rem;
  color: #333;
}

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.section-heading h3 {
  margin: 0 0 0.35rem;
}

.section-heading p {
  margin: 0;
  color: #4b5563;
}

#driverMap {
  width: 100%;
  height: 320px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid #d1d5db;
  background: #e5e7eb;
}

#passengerLocationSection {
  margin-top: 1.5rem;
}

#passengerRequestSection {
  margin-top: 1.5rem;
}

#passengerFareSection {
  margin-top: 1.5rem;
  border: 1px solid #d1d5db;
  border-radius: 10px;
  background: #f9fafb;
  padding: 1rem;
}

#passengerFareSection h3 {
  margin: 0 0 0.5rem;
}

#passengerFareStatus {
  margin: 0;
  color: #111827;
  font-weight: 600;
}

#passengerMap {
  width: 100%;
  height: 320px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid #d1d5db;
  background: #e5e7eb;
}

#useCurrentLocationButton {
  width: auto;
  margin: 0;
  padding: 0.75rem 1rem;
  background: #1f2937;
  color: #fff;
}

#useCurrentLocationButton:hover {
  background: #111827;
}

form input,
form button {
  margin: 0.5rem 0;
  padding: 0.5rem;
  border-radius: 4px;
  border: 1px solid #ccc;
  width: 100%;
  box-sizing: border-box;
}

form button {
  background: #007bff;
  color: #fff;
  border: none;
  cursor: pointer;
  font-weight: bold;
}

form button:hover {
  background: #0056b3;
}

#driverLogoutButton {
  background: #1f2937;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-weight: bold;
  padding: 0.6rem 1rem;
  width: auto;
}

#driverLogoutButton:hover,
#refreshDriverLocationButton:hover {
  background: #111827;
}

#refreshDriverLocationButton {
  margin-top: 1rem;
  background: #1f2937;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-weight: bold;
  padding: 0.6rem 1rem;
}

#rideResults {
  margin-top: 1rem;
}

.pac-container {
  z-index: 10000;
}

@media (max-width: 640px) {

  nav,
  .nav-actions {
    flex-direction: column;
    align-items: stretch;
  }

  #driverLogin,
  #driverLoginForm,
  .translate-tools,
  .section-heading,
  .section-actions {
    flex-direction: column;
    align-items: stretch;
  }

  #driverLoginForm input,
  #driverLoginForm button,
  #driverLogoutButton,
  #useCurrentLocationButton {
    width: 100%;
  }

  #passengerDecisionActions {
    flex-direction: column;
  }

  #passengerDecisionActions button,
  #passengerRequestForm button {
    width: 100%;
  }

  #driverVehicleDetails {
    grid-template-columns: 1fr;
  }

  .driver-request-actions {
    flex-direction: column;
  }

  .translate-tools {
    justify-content: center;
  }

  #driverStatus {
    text-align: center;
  }
}