@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700&display=swap');

body {
    font-family: 'Montserrat', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f4f4f4;
}

:root {
  --brand-blue: #6AB8FF;
  --text-dark: #333;
  --text-muted: #666;
  --border-color: #ddd;
  --shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* Quote Intro Section */
.quote-intro {
  max-width: 750px;
  margin: 50px auto 30px;
  padding: 0 20px;
  text-align: center;
}

.quote-intro h1 {
  font-family: 'Montserrat', sans-serif;
  font-size: 2.5em;
  font-weight: 700;
  color: var(--text-dark);
  margin: 0;
}

/* Form Container */
.quote-form-container {
  background: #ffffff;
  max-width: 750px;
  margin: 0 auto 60px;
  padding: 50px 40px;
  border-radius: 16px;
  box-shadow: var(--shadow);
}

/* Section Headers (h2) */
h2 {
  font-family: 'Montserrat', sans-serif;
  font-size: 1.8em;
  font-weight: 700;
  color: var(--text-dark);
  text-align: center;
  margin: 40px 0 30px;
  padding-bottom: 15px;
  border-bottom: 3px solid var(--brand-blue);
  position: relative;
}

h2:first-of-type {
  margin-top: 0;
}

/* Form Labels */
form label {
  display: block;
  margin: 20px 0 8px;
  font-size: 0.95em;
  font-weight: 600;
  color: var(--text-dark);
}

/* Polished Input Fields & Dropdowns */
form input, 
form select, 
form textarea {
  width: 100%;
  padding: 14px 16px;
  margin-bottom: 4px;
  border: 2px solid var(--border-color);
  border-radius: 10px;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.95em;
  color: var(--text-dark);
  background: #fff;
  transition: all 0.3s ease;
  box-sizing: border-box;
}

form input:focus, 
form select:focus,
form textarea:focus {
  outline: none;
  border-color: var(--brand-blue);
  box-shadow: 0 0 0 3px rgba(106, 184, 255, 0.1);
}

form input::placeholder {
  color: #999;
  opacity: 1;
}

/* Select dropdown arrow styling */
form select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M10.293 3.293L6 7.586 1.707 3.293A1 1 0 00.293 4.707l5 5a1 1 0 001.414 0l5-5a1 1 0 10-1.414-1.414z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px;
  cursor: pointer;
}

/* Date inputs */
form input[type="date"] {
  cursor: pointer;
}

/* Polished Submit Button */
button[type="submit"],
.submit-btn {
  display: block;
  width: 100%;
  padding: 16px 20px;
  margin-top: 40px;
  background: var(--brand-blue);
  color: white;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  font-family: 'Montserrat', sans-serif;
  font-size: 1.1em;
  font-weight: 700;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(106, 184, 255, 0.3);
}

button[type="submit"]:hover,
.submit-btn:hover {
  background: #5aa7eb;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(106, 184, 255, 0.4);
}

button[type="submit"]:active,
.submit-btn:active {
  transform: translateY(0);
}

/* Hidden sections */
#modifications-details, 
#claims-details, 
#penalty-details {
  display: none;
  margin-top: 20px;
  padding: 20px;
  background: #f9f9f9;
  border-radius: 10px;
  border-left: 4px solid var(--brand-blue);
}

.hidden {
  display: none;
}

/* Vehicle Information helpers */
.inline-two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.inline-two > div {
  display: flex;
  flex-direction: column;
}

/* Registration input - uppercase */
#registration {
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Keep placeholder text normal case */
#registration::placeholder {
  text-transform: none;
  letter-spacing: normal;
}
  font-weight: 600;
  letter-spacing: 1px;
}

/* Driver cards */
.driver-card {
  margin-top: 30px;
  padding: 25px;
  background: #f9f9f9;
  border-radius: 12px;
  border: 2px solid #eee;
}

.driver-card h3 {
  margin: 0 0 20px 0;
  font-size: 1.3em;
  color: var(--text-dark);
  padding-bottom: 10px;
  border-bottom: 2px solid var(--brand-blue);
}

/* Job autocomplete */
.job-suggest {
  position: relative;
  margin-top: 6px;
}

.job-suggest-panel {
  position: absolute;
  left: 0;
  top: calc(100% + 4px);
  right: 0;
  background: #fff;
  border: 2px solid #e0e0e0;
  border-radius: 10px;
  max-height: 220px;
  overflow-y: auto;
  z-index: 200;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
  padding: 6px;
}

.job-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 10px 12px;
  border: none;
  border-radius: 7px;
  background: none;
  text-align: left;
  font-size: 14px;
  font-family: inherit;
  color: #333;
  cursor: pointer;
  transition: background 0.15s;
  gap: 10px;
}

.job-item:hover,
.job-item:focus {
  background: rgba(106, 184, 255, 0.12);
  outline: none;
  color: #000;
}

.job-meta {
  font-size: 12px;
  color: #999;
  flex-shrink: 0;
  font-style: italic;
}

/* Scrollbar styling */
.job-suggest-panel::-webkit-scrollbar {
  width: 6px;
}
.job-suggest-panel::-webkit-scrollbar-track {
  background: #f5f5f5;
  border-radius: 10px;
}
.job-suggest-panel::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 10px;
}
.job-suggest-panel::-webkit-scrollbar-thumb:hover {
  background: #6AB8FF;
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .quote-intro h1 {
    font-size: 2em;
  }

  .quote-form-container {
    padding: 30px 25px;
    margin: 0 15px 40px;
    border-radius: 12px;
  }

  h2 {
    font-size: 1.5em;
    margin: 30px 0 20px;
  }

  .inline-two {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }

  form input, 
  form select {
    padding: 12px 14px;
    font-size: 16px; /* Prevents zoom on iOS */
  }

  button[type="submit"],
  .submit-btn {
    padding: 14px 18px;
    font-size: 1em;
  }

  .driver-card {
    padding: 20px;
  }
}

@media (max-width: 520px) {
  .quote-intro {
    margin: 30px auto 20px;
  }

  .quote-intro h1 {
    font-size: 1.75em;
  }

  .quote-form-container {
    padding: 25px 20px;
  }

  h2 {
    font-size: 1.3em;
  }
}

/* Additional polish */
form input[type="checkbox"],
form input[type="radio"] {
  width: auto;
  margin-right: 8px;
  cursor: pointer;
}

/* Helper text */
.helper-text {
  font-size: 0.85em;
  color: var(--text-muted);
  margin-top: 4px;
  font-style: italic;
}

/* Error states */
.error-input {
  border-color: #ef4444 !important;
}

.error-message {
  color: #ef4444;
  font-size: 0.85em;
  margin-top: 4px;
  font-weight: 500;
}

/* Success states */
.success-input {
  border-color: #10b981 !important;
}

/* ===== Custom Date Picker ===== */
.custom-datepicker {
  position: relative;
  width: 100%;
}

.cdp-input-row {
  display: flex;
  align-items: center;
  border: 2px solid #ddd;
  border-radius: 10px;
  background: #fff;
  overflow: hidden;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.cdp-input-row:focus-within {
  border-color: #6AB8FF;
  box-shadow: 0 0 0 3px rgba(106,184,255,0.15);
}

.cdp-text-input {
  flex: 1;
  border: none;
  outline: none;
  padding: 14px 16px;
  font-size: 15px;
  color: #333;
  background: transparent;
  font-family: inherit;
  min-width: 0;
}

.cdp-text-input::placeholder {
  color: #999;
}

.cdp-icon-btn {
  background: none;
  border: none;
  border-left: 2px solid #ddd;
  padding: 0 14px;
  height: 48px;
  display: flex;
  align-items: center;
  cursor: pointer;
  color: #999;
  flex-shrink: 0;
  transition: background 0.15s, color 0.15s;
}

.cdp-icon-btn:hover {
  background: rgba(106,184,255,0.1);
  color: #6AB8FF;
}

.cdp-popup {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 999;
  background: #fff;
  border: 2px solid #e0e0e0;
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
  width: 300px;
}

.cdp-popup.cdp-open {
  display: block;
}

.cdp-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.cdp-month-year {
  font-weight: 700;
  font-size: 15px;
  color: #333;
}

.cdp-nav {
  background: none;
  border: none;
  font-size: 22px;
  cursor: pointer;
  color: #6AB8FF;
  padding: 2px 8px;
  border-radius: 6px;
  line-height: 1;
  transition: background 0.15s;
}

.cdp-nav:hover {
  background: rgba(106,184,255,0.15);
}

.cdp-nav:disabled {
  color: #ccc;
  cursor: not-allowed;
}

.cdp-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  margin-bottom: 6px;
}

.cdp-weekdays span {
  text-align: center;
  font-size: 12px;
  font-weight: 700;
  color: #999;
  padding: 4px 0;
}

.cdp-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
}

.cdp-day {
  text-align: center;
  padding: 7px 4px;
  font-size: 13px;
  border-radius: 6px;
  cursor: pointer;
  border: none;
  background: none;
  color: #333;
  transition: background 0.15s, color 0.15s;
  font-family: inherit;
}

.cdp-day:hover:not(:disabled) {
  background: rgba(106,184,255,0.2);
  color: #333;
}

.cdp-day.today {
  font-weight: 700;
  color: #6AB8FF;
}

.cdp-day.selected {
  background: #6AB8FF;
  color: #fff;
  font-weight: 700;
}

.cdp-day:disabled {
  color: #ccc;
  cursor: not-allowed;
}

.cdp-day.empty {
  cursor: default;
}
