/* #368 driver.maple-360.uk/google.php + /privacy.php. Standalone: the driver app's look (colours, type, card, fields,
   buttons and the #359 cookie banner from driver-app.css) re-declared here under gs- names, so the driver app's
   own CSS is neither loaded nor changed. */

:root {
  --gs-bg: #f4f7f5;
  --gs-surface: #ffffff;
  --gs-text: #183029;
  --gs-muted: #5c6b64;
  --gs-border: #dce4df;
  --gs-input-border: #d5dbe3;
  --gs-brand: #1f8a4d;
  --gs-brand-dark: #166b3c;
  --gs-error: #b3261e;
  --gs-error-border: #e57373;
  --gs-inset: 1rem;
  --gs-max: 32rem;
  --gs-consent-h: 0px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body.gs-body {
  margin: 0;
  min-height: 100vh;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.45;
  color: var(--gs-text);
  background: var(--gs-bg);
  -webkit-tap-highlight-color: transparent;
}

.gs-main {
  width: 100%;
  max-width: var(--gs-max);
  margin-inline: auto;
  padding: calc(0.75rem + env(safe-area-inset-top, 0px)) var(--gs-inset)
    calc(1.25rem + env(safe-area-inset-bottom, 0px) + var(--gs-consent-h));
}

.gs-brand {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin: 0.25rem 0 0.85rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.gs-brand img {
  display: block;
  width: 1.75rem;
  height: 1.75rem;
  object-fit: contain;
}

.gs-card {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  background: var(--gs-surface);
  border: 1px solid var(--gs-border);
  border-radius: 0.85rem;
  padding: 1rem 1.05rem 1.15rem;
  box-shadow: 0 1px 2px rgba(24, 48, 41, 0.04);
}

.gs-card[hidden] {
  display: none;
}

.gs-title {
  margin: 0;
  font-size: 1.25rem;
  line-height: 1.25;
  font-weight: 700;
}

.gs-intro {
  margin: 0 0 0.6rem;
  color: var(--gs-muted);
  font-size: 0.95rem;
}

.gs-intro strong {
  color: var(--gs-text);
  white-space: nowrap;
}

.gs-form {
  display: flex;
  flex-direction: column;
  margin: 0;
}

.gs-field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-bottom: 0.75rem;
}

.gs-field > span {
  font-size: 0.85rem;
  font-weight: 600;
}

.gs-input {
  width: 100%;
  min-height: 2.9rem;
  border: 1px solid var(--gs-input-border);
  border-radius: 0.55rem;
  padding: 0.65rem 0.75rem;
  font: inherit;
  font-size: 16px; /* no iOS zoom on focus */
  color: var(--gs-text);
  background: #fff;
}

.gs-input:focus {
  outline: 2px solid var(--gs-brand);
  outline-offset: 0;
  border-color: var(--gs-brand);
}

.gs-select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 2.25rem;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%235c6b64' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 0.85rem center;
}

.gs-field.is-invalid .gs-input {
  border-color: var(--gs-error-border);
  background-color: #fff8f7;
}

.gs-field.is-invalid .gs-input:focus {
  outline-color: var(--gs-error);
}

.gs-err {
  font-style: normal;
  font-size: 0.85rem;
  color: var(--gs-error);
}

.gs-err[hidden],
.gs-status[hidden] {
  display: none;
}

.gs-status {
  margin: 0 0 0.75rem;
  padding: 0.6rem 0.75rem;
  border: 1px solid var(--gs-error-border);
  border-radius: 0.55rem;
  background: #fff4f3;
  color: var(--gs-error);
  font-size: 0.9rem;
}

.gs-btn {
  appearance: none;
  -webkit-appearance: none;
  display: block;
  width: 100%;
  margin: 0.25rem 0 0;
  padding: 0.75rem 1rem;
  border-radius: 0.65rem;
  border: 1px solid transparent;
  font: inherit;
  font-weight: 650;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

/* #523 r2.2: the thanks card button stays hidden until it has the applicant's own link */
.gs-btn[hidden] {
  display: none;
}

.gs-btn--primary {
  background: var(--gs-brand);
  color: #fff;
}

.gs-btn--primary:hover {
  background: var(--gs-brand-dark);
}

.gs-btn--secondary {
  background: transparent;
  border-color: var(--gs-border);
  color: var(--gs-muted);
}

.gs-btn:focus-visible,
.gs-linkbtn:focus-visible,
.gs-consent-btn:focus-visible,
.gs-footer a:focus-visible {
  outline: 2px solid var(--gs-brand-dark);
  outline-offset: 2px;
}

.gs-btn:disabled {
  opacity: 0.55;
  cursor: default;
}

.gs-small {
  margin: 0.7rem 0 0;
  font-size: 0.8rem;
  color: var(--gs-muted);
}

.gs-small a,
.gs-doc a,
.gs-footer a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* honeypot: off-screen, not display:none (some bots skip hidden fields) */
.gs-hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.gs-done {
  align-items: flex-start;
}

.gs-done:focus {
  outline: none;
}

.gs-done-tick {
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  margin-bottom: 0.25rem;
  border-radius: 50%;
  background: rgba(31, 138, 77, 0.12);
  color: var(--gs-brand);
}

.gs-done .gs-btn {
  margin-top: 0.35rem;
}

.gs-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.35rem 0.5rem;
  margin: 1rem 0 0;
  font-size: 0.78rem;
  color: var(--gs-muted);
}

.gs-linkbtn {
  display: inline;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
}

/* privacy notice */
.gs-doc h2 {
  margin: 0.9rem 0 0.15rem;
  font-size: 1rem;
}

.gs-doc p,
.gs-doc ul {
  margin: 0 0 0.35rem;
  font-size: 0.92rem;
}

.gs-doc ul {
  padding-left: 1.2rem;
}

.gs-doc li + li {
  margin-top: 0.2rem;
}

.gs-doc .gs-btn {
  margin-top: 0.9rem;
}

.gs-confirm {
  padding: 0 0.2rem;
  border-radius: 0.25rem;
  background: #fff3c4;
}

/* cookie banner (same look and copy as the driver app's #359 banner) */
.gs-consent {
  position: fixed;
  left: 50%;
  bottom: 0;
  z-index: 50;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  width: 100%;
  max-width: var(--gs-max);
  margin: 0;
  padding: 0.75rem var(--gs-inset) calc(0.7rem + env(safe-area-inset-bottom, 0px));
  background: var(--gs-surface);
  border-top: 1px solid var(--gs-border);
  box-shadow: 0 -6px 18px rgba(24, 48, 41, 0.1);
  color: var(--gs-text);
}

.gs-consent[hidden] {
  display: none !important;
}

.gs-consent-text {
  margin: 0;
  font-size: 0.8rem;
  line-height: 1.35;
}

.gs-consent-actions {
  display: flex;
  gap: 0.5rem;
}

.gs-consent-btn {
  flex: 1 1 0;
  min-height: 2.5rem;
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 600;
  cursor: pointer;
}

.gs-consent-btn--reject {
  background: var(--gs-surface);
  color: var(--gs-text);
  border: 1px solid var(--gs-border);
}

.gs-consent-btn--accept {
  background: var(--gs-brand);
  color: #fff;
  border: 1px solid var(--gs-brand);
}

@media (min-width: 600px) {
  .gs-main {
    padding-top: 2rem;
  }

  .gs-consent {
    flex-direction: row;
    align-items: center;
    gap: 0.9rem;
    border: 1px solid var(--gs-border);
    border-bottom: 0;
    border-radius: 0.85rem 0.85rem 0 0;
  }

  .gs-consent-actions {
    flex: 0 0 auto;
  }

  .gs-consent-btn {
    flex: 0 0 auto;
    min-width: 6.5rem;
  }
}

/* #411 depot picker: postcode, map (Leaflet + OpenStreetMap, loaded after a lookup) and the depot radio list.
   Without JS (or before enhancement) the list is a plain radio list; .is-enhanced hides it until a postcode lookup. */
.gs-pc > label > span {
  font-size: 0.85rem;
  font-weight: 600;
}

/* t60u: "Postcode" label + small ? button; tapping it shows / hides the home-postcode hint under the label. */
.gs-pc-head {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.gs-pc-help {
  position: relative;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.25rem;
  height: 1.25rem;
  margin: 0;
  padding: 0;
  border: 1px solid var(--gs-muted);
  border-radius: 50%;
  background: #fff;
  color: var(--gs-muted);
  font: inherit;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.gs-pc-help::after { /* ~44px tap target without a bigger icon */
  content: "";
  position: absolute;
  inset: -0.75rem;
}

.gs-pc-help[aria-expanded="true"] {
  border-color: var(--gs-brand);
  background: var(--gs-brand);
  color: #fff;
}

@media (hover: hover) {
  .gs-pc-help:hover {
    border-color: var(--gs-brand);
    color: var(--gs-brand-dark);
  }
  .gs-pc-help[aria-expanded="true"]:hover {
    color: #fff;
  }
}

.gs-pc-help:focus-visible {
  outline: 2px solid var(--gs-brand);
  outline-offset: 2px;
}

.gs-pc-hint {
  margin: 0;
  padding: 0.45rem 0.65rem;
  font-size: 0.85rem;
  color: var(--gs-text);
  background: var(--gs-bg);
  border: 1px solid var(--gs-border);
  border-radius: 0.55rem;
}

.gs-pc-hint[hidden] {
  display: none;
}

.gs-pc-row {
  display: flex;
  gap: 0.5rem;
}

.gs-pc-input {
  flex: 1 1 auto;
  min-width: 0;
  text-transform: uppercase;
}

.gs-pc-input::placeholder {
  text-transform: none;
}

.gs-pc-find {
  flex: 0 0 auto;
  width: auto;
  min-height: 2.9rem;
  margin: 0;
  padding: 0.6rem 0.85rem;
  border-color: var(--gs-brand);
  color: var(--gs-brand-dark);
  white-space: nowrap;
}

.gs-pc-find[hidden] {
  display: none;
}

.gs-depots {
  min-width: 0;
  margin: 0 0 0.75rem;
  padding: 0;
  border: 0;
}

.gs-depots > legend {
  padding: 0;
  margin-bottom: 0.35rem;
  font-size: 0.85rem;
  font-weight: 600;
}

.gs-depots.is-enhanced:not(.is-open) > legend {
  display: none; /* nothing to choose yet: the postcode comes first */
}

.gs-depots-note {
  margin: 0 0 0.5rem;
  font-size: 0.85rem;
  color: var(--gs-muted);
}

.gs-depots-note[hidden],
.gs-map[hidden],
.gs-depot-list[hidden],
.gs-applying[hidden],
.gs-depot-tag[hidden] {
  display: none;
}

.gs-map {
  position: relative;
  z-index: 0; /* Leaflet panes stay under the cookie banner */
  width: 100%;
  height: 240px;
  margin: 0 0 0.6rem;
  border: 1px solid var(--gs-border);
  border-radius: 0.65rem;
  overflow: hidden;
  background: #e8eeea;
}

.gs-depot-list {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.gs-depot {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-height: 44px;
  padding: 0.55rem 0.75rem;
  border: 1px solid var(--gs-input-border);
  border-radius: 0.6rem;
  background: #fff;
  cursor: pointer;
}

.gs-depot input {
  flex: 0 0 auto;
  width: 1.15rem;
  height: 1.15rem;
  margin: 0;
  accent-color: var(--gs-brand);
}

.gs-depot-text {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.1rem 0.45rem;
  flex: 1 1 auto;
  min-width: 0;
}

.gs-depot-name {
  font-weight: 650;
  overflow-wrap: anywhere;
}

.gs-depot-town {
  flex-basis: 100%;
  font-size: 0.82rem;
  color: var(--gs-muted);
}

.gs-depot-tag {
  padding: 0.05rem 0.45rem;
  border-radius: 999px;
  background: rgba(31, 138, 77, 0.12);
  color: var(--gs-brand-dark);
  font-size: 0.72rem;
  font-weight: 700;
}

.gs-depot-miles {
  flex: 0 0 auto;
  font-size: 0.85rem;
  color: var(--gs-muted);
  white-space: nowrap;
}

.gs-depot-tick {
  display: none;
  flex: 0 0 auto;
  color: var(--gs-brand);
}

.gs-depots.is-enhanced .gs-depot input {
  /* the row, its highlight and tick show the choice; the radio stays for keyboard and screen readers */
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.gs-depots.is-enhanced .gs-depot {
  position: relative;
}

.gs-depots.is-enhanced .gs-depot:focus-within {
  outline: 2px solid var(--gs-brand-dark);
  outline-offset: 1px;
}

.gs-depot.is-selected {
  border-color: var(--gs-brand);
  background: #f1f9f4;
  box-shadow: inset 0 0 0 1px var(--gs-brand);
}

.gs-depots.is-enhanced .gs-depot.is-selected .gs-depot-tick {
  display: block;
}

.gs-field.is-invalid .gs-depot {
  border-color: var(--gs-error-border);
}

.gs-applying {
  margin: 0.55rem 0 0;
  font-size: 0.92rem;
}

/* map pins: 44px tap area, smaller visible pin; filled when selected */
.gs-pin-wrap {
  background: none;
  border: 0;
}

.gs-pin {
  position: absolute;
  left: 50%;
  bottom: 4px;
  width: 26px;
  height: 26px;
  margin-left: -13px;
  border: 3px solid var(--gs-brand);
  border-radius: 50% 50% 50% 0;
  background: #fff;
  transform: rotate(-45deg);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.35);
}

.gs-pin.is-selected {
  background: var(--gs-brand);
  border-color: var(--gs-brand-dark);
}

.gs-map .leaflet-control-attribution {
  font-size: 0.68rem;
}

.gs-map .leaflet-control-zoom a {
  width: 34px;
  height: 34px;
  line-height: 34px;
}

@media (min-width: 920px) {
  .gs-map {
    height: 320px;
  }
}

/* #416 job questions from the driver app's Q&A: closed accordion below the form */
.gs-faq {
  margin-top: 0.85rem;
  gap: 0.3rem;
}

.gs-faq-title {
  margin: 0 0 0.25rem;
  font-size: 1.05rem;
  font-weight: 700;
}

/* #523: the heading is a full-width button that opens / closes the list; looks like the old heading */
.gs-faq-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.gs-faq-head:focus-visible {
  outline: 2px solid var(--gs-brand);
  outline-offset: 3px;
  border-radius: 4px;
}

.gs-faq-head[aria-expanded="true"] .gs-faq-chev {
  transform: rotate(225deg) translate(-2px, -2px);
}

.gs-faq-list[hidden] {
  display: none;
}

.gs-done {
  scroll-margin-top: 0.75rem;
}

.gs-faq-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.gs-faq-item + .gs-faq-item {
  border-top: 1px solid var(--gs-border);
}

.gs-faq-h {
  margin: 0;
  font-size: inherit;
}

.gs-faq-q {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  width: 100%;
  min-height: 44px;
  padding: 0.6rem 0.1rem;
  border: 0;
  background: none;
  color: var(--gs-text);
  font: inherit;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
}

.gs-faq-q:focus-visible {
  outline: 2px solid var(--gs-brand-dark);
  outline-offset: 2px;
}

.gs-faq-chev {
  flex: 0 0 auto;
  width: 0.6rem;
  height: 0.6rem;
  margin-right: 0.3rem;
  border-right: 2px solid var(--gs-muted);
  border-bottom: 2px solid var(--gs-muted);
  transform: rotate(45deg) translate(-2px, -2px);
  transition: transform 0.15s ease;
}

.gs-faq-q[aria-expanded="true"] .gs-faq-chev {
  transform: rotate(225deg) translate(-2px, -2px);
}

.gs-faq-a {
  padding: 0 0.1rem 0.75rem;
  font-size: 0.92rem;
  color: var(--gs-text);
  overflow-wrap: anywhere;
}

.gs-faq-a[hidden] {
  display: none;
}

.gs-faq-a p,
.gs-faq-a ul {
  margin: 0 0 0.45rem;
}

.gs-faq-a ul {
  padding-left: 1.2rem;
}

/* the app's pay table (answer_html): fits the card, no scrollbars (#377) */
.gs-faq-a table {
  width: 100%;
  margin: 0.2rem 0 0.55rem;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 0.85rem;
}

.gs-faq-a th,
.gs-faq-a td {
  padding: 0.3rem 0.35rem;
  border-bottom: 1px solid var(--gs-border);
  text-align: left;
  overflow-wrap: anywhere;
}

.gs-faq-a th {
  font-weight: 650;
  color: var(--gs-muted);
}

/* #523 r2.1: the thanks card has two bodies (own link / fallback); only one shows */
.gs-done .gs-intro[hidden] { display: none; }

/* #523 r2 (FE nice-to-have 2): Common questions heading is a 44px tap target on phones, like the question rows */
@media (max-width: 599px) {
  .gs-faq-head { min-height: 44px; }
}

/* t-gthanks (Jason 20 Oct 2026 11:48): the applicant's own Maple link shown on the thanks card, under the
   "Open your Maple app" button, with a Copy button. Hidden until google-signup.js has this submit's own link. */
.gs-done .gs-app-open {
  min-height: 48px;
  font-size: 1.05rem;
}

.gs-applink {
  width: 100%;
  box-sizing: border-box;
  margin-top: 0.5rem;
  padding: 0.75rem;
  border: 1px solid var(--gs-border);
  border-radius: 0.65rem;
  background: var(--gs-bg);
}

.gs-applink[hidden] {
  display: none;
}

.gs-applink-label {
  margin: 0 0 0.35rem;
  color: var(--gs-muted);
  font-size: 0.85rem;
  font-weight: 650;
}

.gs-applink-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.gs-applink-url {
  flex: 1 1 auto;
  min-width: 0;
  padding: 0.55rem 0.65rem;
  border: 1px solid var(--gs-input-border);
  border-radius: 0.55rem;
  background: var(--gs-surface);
  color: var(--gs-brand-dark);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.85rem;
  line-height: 1.35;
  overflow-wrap: anywhere;
  word-break: break-all;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.gs-applink-url:focus-visible {
  outline: 2px solid var(--gs-brand-dark);
  outline-offset: 2px;
}

.gs-done .gs-applink-copy {
  flex: 0 0 auto;
  width: auto;
  min-width: 5.25rem;
  min-height: 44px;
  margin: 0;
  padding: 0.55rem 0.9rem;
  background: var(--gs-surface);
  color: var(--gs-brand-dark);
  border-color: var(--gs-brand);
}

.gs-applink-note {
  margin: 0.45rem 0 0;
  color: var(--gs-muted);
  font-size: 0.8rem;
}

/* t-gnearest: "Nearest depot selected: DPO1 Havant (4.2 miles). Tap another to change." (aria-live status). */
.gs-depot-auto {
  margin: 0.55rem 0 0.45rem;
  padding: 0.5rem 0.7rem;
  border-radius: 0.6rem;
  background: rgba(31, 138, 77, 0.09);
  color: #145c33;
  font-size: 0.92rem;
  line-height: 1.35;
}
.gs-depot-auto[hidden] {
  display: none !important;
}
