/* Shared ISG form styles (customer + CSR forms). */

@font-face {
  font-family: 'Stolzl';
  src: url('/fonts/Stolzl-Book.ttf') format('truetype');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: 'Stolzl';
  src: url('/fonts/Stolzl-Medium.ttf') format('truetype');
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: 'Stolzl';
  src: url('/fonts/Stolzl-Bold.ttf') format('truetype');
  font-weight: 700;
  font-display: swap;
}

:root {
  --navy: #2c4251;
  --navy-dark: #1e2f3b;
  --crimson: #9c1d1f;
  --crimson-dark: #7a1517;
  --gold: #d7b377;
  --charcoal: #575a5e;
  --light-gray: #eae8ed;
  --off-white: #f5f4f7;
  --white: #ffffff;
  --border: #d4d8de;
  --help: #7a8590;
  --font: 'Stolzl', 'Segoe UI', system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }
/* Ensure [hidden] always wins over display rules like .field { display:flex } */
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  background: var(--off-white);
  color: var(--navy);
  line-height: 1.5;
}

.wrap { max-width: 820px; margin: 0 auto; padding: 0 16px 56px; }

/* Masthead */
.masthead {
  display: flex;
  align-items: center;
  gap: 20px;
  background: var(--navy);
  color: var(--white);
  padding: 28px 32px;
  margin: 24px 0 22px;
  border-bottom: 4px solid var(--gold);
}
.masthead .logo { height: 56px; width: auto; flex-shrink: 0; }
.masthead h1 { margin: 0; font-size: 1.6rem; font-weight: 700; letter-spacing: -0.01em; }
.masthead p { margin: 6px 0 0; font-size: 0.9rem; color: rgba(255, 255, 255, 0.78); line-height: 1.5; }
.masthead a { color: var(--gold); text-decoration: none; white-space: nowrap; }
.masthead a:hover { text-decoration: underline; }

/* ---- Shared ISG Tools menu (canonical: ISG Tools Launcher nav/isg-tools-menu.html) ---- */
.masthead .isg-tools { margin-left: auto; }
.isg-tools { position: relative; font-family: inherit; }
.isg-tools > summary {
  list-style: none; cursor: pointer; user-select: none;
  display: inline-flex; align-items: center; gap: .4rem;
  min-height: 44px; padding: 0 .9rem; border-radius: 8px;
  font-weight: 600; font-size: .92rem; line-height: 1;
  color: #ffffff; background: rgba(255,255,255,.12); border: 1.5px solid rgba(255,255,255,.45);
}
.isg-tools > summary::-webkit-details-marker { display: none; }
.isg-tools > summary::after {
  content: ""; width: .5em; height: .5em; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
  transform: translateY(-2px) rotate(45deg); transition: transform .15s ease;
}
.isg-tools[open] > summary::after { transform: translateY(2px) rotate(225deg); }
.isg-tools > summary:hover { background: rgba(255,255,255,.2); }
.isg-tools > summary:focus-visible { outline: 3px solid #d7b377; outline-offset: 2px; }
.isg-tools-list {
  position: absolute; right: 0; top: calc(100% + 6px); z-index: 1000;
  min-width: 240px; margin: 0; padding: .35rem; list-style: none;
  background: #ffffff; color: #1a1a1a; border-radius: 10px;
  box-shadow: 0 6px 24px rgba(44,66,81,.22), 0 1px 2px rgba(26,26,26,.08);
}
.isg-tools-list li { margin: 0; }
.isg-tools-list a, .isg-tools-current {
  display: flex; align-items: center; min-height: 44px; padding: 0 .85rem;
  border-radius: 7px; color: #2c4251; text-decoration: none; font-size: .95rem; font-weight: 500;
}
.masthead .isg-tools-list a { color: #2c4251; white-space: normal; }
.masthead .isg-tools-list a:hover { text-decoration: none; }
.isg-tools-list a:hover { background: #eae8ed; }
.isg-tools-list a:focus-visible { outline: 3px solid #d7b377; outline-offset: -3px; }
.isg-tools-current { color: #575a5e; background: #eae8ed; cursor: default; }
.isg-tools-current::after { content: "current"; margin-left: auto; font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; color: #9c1d1f; }
.isg-tools-list li.isg-tools-all { border-top: 1px solid #eae8ed; margin-top: .25rem; padding-top: .25rem; }
.isg-tools-list li.isg-tools-all a { color: #9c1d1f; font-weight: 600; }
.masthead .isg-tools-list li.isg-tools-all a { color: #9c1d1f; }
@media (max-width: 600px) { .masthead .isg-tools { margin-left: 0; } }
@media (max-width: 480px) { .isg-tools-list { position: fixed; left: .5rem; right: .5rem; top: auto; min-width: 0; } }

/* Freight rate field: input plus the "Calculate freight" button that opens the calculator. */
.rate-row { display: flex; gap: 8px; align-items: stretch; }
.rate-row input { flex: 1 1 auto; min-width: 0; }
.freight-calc {
  flex: 0 0 auto; padding: 0 12px; min-height: 44px;
  font-family: var(--font); font-size: 0.85rem; font-weight: 600; white-space: nowrap;
  color: var(--navy); background: var(--white); border: 1.5px solid var(--navy); border-radius: 8px; cursor: pointer;
}
.freight-calc:hover { background: var(--navy); color: var(--white); }
.freight-calc:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.freight-note { color: #1f6b3a; font-weight: 600; }

/* Internal banner (CSR form) */
.internal-banner {
  background: var(--navy-dark);
  color: var(--gold);
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-align: center;
  padding: 6px 10px;
  margin: 24px 0 -8px;
}

.req { color: var(--crimson); font-weight: 700; }
.legend { margin: 0 2px 14px; font-size: 0.78rem; color: var(--help); }

/* Cards / sections */
.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-left: 3px solid var(--crimson);
  padding: 24px 26px;
  margin-bottom: 18px;
}
.card h2 {
  margin: 0 0 18px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--charcoal);
  padding-bottom: 10px;
  border-bottom: 1px solid var(--light-gray);
  display: flex;
  align-items: center;
  gap: 10px;
}

.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.grid.nested { gap: 16px; }
.field { display: flex; flex-direction: column; }
.field.full { grid-column: 1 / -1; }

label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--charcoal);
  margin-bottom: 7px;
}
.help {
  font-size: 0.76rem;
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
  color: var(--help);
  margin-top: 6px;
}

input, select, textarea {
  font-family: var(--font);
  font-size: 1rem; /* 16px: below that iOS Safari zooms the page on focus */
  color: var(--navy);
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 0;
  padding: 12px 14px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
}
input::placeholder, textarea::placeholder { color: #9aa3ab; }
input:focus, select:focus, textarea:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(215, 179, 119, 0.18);
}
select {
  cursor: pointer;
  background-image: linear-gradient(45deg, transparent 50%, var(--charcoal) 50%), linear-gradient(135deg, var(--charcoal) 50%, transparent 50%);
  background-position: calc(100% - 18px) center, calc(100% - 13px) center;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  padding-right: 36px;
}
textarea { resize: vertical; min-height: 84px; }

/* Autocomplete (material) */
.ac-wrap { position: relative; }
.ac-list {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 30;
  background: var(--white);
  border: 1px solid var(--gold);
  border-top: none;
  max-height: 260px;
  overflow-y: auto;
  box-shadow: 0 10px 26px rgba(28, 40, 51, 0.14);
}
.ac-item {
  padding: 10px 14px;
  font-size: 0.92rem;
  color: var(--navy);
  cursor: pointer;
  border-bottom: 1px solid var(--light-gray);
}
.ac-item:last-child { border-bottom: none; }
.ac-item:hover, .ac-item.active { background: rgba(215, 179, 119, 0.2); }

/* Inline map link (CSR form) */
.maplink {
  display: inline-block;
  margin-top: 8px;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--crimson);
  text-decoration: none;
  border-bottom: 1px solid rgba(156, 29, 31, 0.35);
  align-self: flex-start;
}
.maplink:hover { color: var(--crimson-dark); border-bottom-color: var(--crimson-dark); }

/* Checkbox row */
.checkrow { display: flex; align-items: center; gap: 10px; margin-top: 18px; }
.checkrow input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  margin: 0;
  padding: 0;
  border: 1.5px solid var(--border);
  border-radius: 0;
  background: var(--white);
  cursor: pointer;
  display: grid;
  place-content: center;
  transition: background 0.15s, border-color 0.15s;
}
.checkrow input[type="checkbox"]::before {
  content: '';
  width: 11px;
  height: 11px;
  transform: scale(0);
  transition: transform 0.12s ease-in-out;
  background: var(--white);
  clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%);
}
.checkrow input[type="checkbox"]:checked {
  background: var(--crimson);
  border-color: var(--crimson);
}
.checkrow input[type="checkbox"]:checked::before {
  transform: scale(1);
}
.checkrow input[type="checkbox"]:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(215, 179, 119, 0.35);
}
.checkrow label { margin: 0; text-transform: none; letter-spacing: 0; font-weight: 500; font-size: 0.9rem; color: var(--navy); cursor: pointer; }
.reveal-note {
  margin: 12px 0 0;
  padding: 12px 14px;
  background: rgba(215, 179, 119, 0.14);
  border-left: 3px solid var(--gold);
  font-size: 0.85rem;
  color: var(--navy);
}

/* Segmented Deliver / Pickup */
.segmented { display: flex; border: 1px solid var(--border); max-width: 360px; }
.segmented input { position: absolute; opacity: 0; pointer-events: none; width: 0; }
.segmented label {
  flex: 1;
  margin: 0;
  text-align: center;
  padding: 12px 8px;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  color: var(--charcoal);
  background: var(--white);
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.segmented label:first-of-type { border-right: 1px solid var(--border); }
.segmented input:checked + label { background: var(--crimson); color: var(--white); }
.segmented input:focus-visible + label { box-shadow: inset 0 0 0 2px var(--gold); }

/* Zone divider + dispatch zone */
.zone-label {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 30px 2px 14px;
  color: var(--help);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.2em;
}
.zone-label::before, .zone-label::after { content: ''; height: 1px; background: var(--border); flex: 1; }
.card.dispatch {
  background: #f1f3f6;
  border: 1px dashed #b9c2cc;
  border-left: 3px solid var(--navy);
}
.card.dispatch h2 { color: var(--navy); border-bottom-color: #dfe3e8; }
.badge {
  background: var(--gold);
  color: var(--navy-dark);
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  padding: 3px 8px;
}
.zone-note { margin: -8px 0 18px; font-size: 0.85rem; color: var(--charcoal); }

/* Submit */
.submit-row { margin-top: 8px; }
#submitBtn {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 17px;
  font-family: var(--font);
  font-size: 1rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--white);
  background: var(--crimson);
  border: 1px solid var(--crimson);
  border-radius: 0;
  cursor: pointer;
  transition: background 0.2s;
}
#submitBtn:hover:not(:disabled) { background: var(--crimson-dark); border-color: var(--crimson-dark); }
#submitBtn:disabled { cursor: default; }
#submitBtn svg { width: 18px; height: 18px; }
.errsummary {
  margin: 14px 0 0;
  padding: 12px 14px;
  background: #fbeaea;
  border-left: 3px solid var(--crimson);
  color: var(--crimson-dark);
  font-size: 0.85rem;
}

/* Success panel */
.success {
  background: var(--white);
  border: 1px solid var(--border);
  border-top: 4px solid #2d7a3a;
  padding: 44px 32px;
  text-align: center;
}
.success .check {
  width: 56px;
  height: 56px;
  margin: 0 auto 18px;
  border-radius: 50%;
  background: #2d7a3a;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
}
.success .check svg { width: 30px; height: 30px; }
.success h2 { margin: 0 0 8px; font-size: 1.4rem; color: var(--navy); }
.success p { margin: 0 auto 8px; max-width: 460px; color: var(--charcoal); font-size: 0.95rem; }
.success .ref { font-size: 0.85rem; color: var(--help); }
.success .success-tread { font-weight: 600; color: var(--navy); }
.success .success-tread.warn { color: var(--crimson); }
.success .success-tread a { color: var(--crimson); margin-left: 4px; }
.success .success-warnings {
  list-style: none;
  margin: 0 auto 16px;
  padding: 10px 14px;
  max-width: 460px;
  text-align: left;
  font-size: 0.88rem;
  color: var(--crimson);
  background: rgba(156, 29, 31, 0.06);
  border: 1px solid rgba(156, 29, 31, 0.25);
}
.help.err { color: var(--crimson); font-weight: 600; }
.success #againBtn {
  margin-top: 18px;
  padding: 12px 22px;
  font-family: var(--font);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.82rem;
  color: var(--white);
  background: var(--navy);
  border: none;
  cursor: pointer;
}
.success #againBtn:hover { background: var(--navy-dark); }

.foot {
  margin-top: 28px;
  text-align: center;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #9aa3ab;
}

@media (max-width: 600px) {
  .grid { grid-template-columns: 1fr; }
  .masthead { flex-direction: column; text-align: center; padding: 22px 20px; }
  .card { padding: 20px 18px; }
  .segmented { max-width: none; }
}

/* ---- Material lines (multi-material orders, up to 6) ---- */
.mat-line { padding: 14px 0 4px; }
.mat-line + .mat-line { border-top: 1px dashed var(--border); margin-top: 10px; }
.mat-line-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.mat-line-num {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--charcoal);
}
.mat-remove {
  background: none;
  border: none;
  padding: 2px 0;
  font-family: var(--font);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--crimson);
  cursor: pointer;
  border-bottom: 1px solid transparent;
}
.mat-remove:hover { color: var(--crimson-dark); border-bottom-color: var(--crimson-dark); }
/* 44px finger targets on touch devices for the two small text-style controls. */
@media (pointer: coarse) {
  .mat-remove { min-height: 44px; min-width: 44px; padding: 10px 8px; }
  #signOutLink { display: inline-block; min-height: 44px; line-height: 44px; padding: 0 8px; }
}
.addline-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 6px;
  padding-top: 12px;
  border-top: 1px dashed var(--border);
}
.addline {
  background: none;
  border: 1.5px dashed var(--border);
  padding: 9px 16px;
  font-family: var(--font);
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--navy);
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}
.addline:hover:not(:disabled) { border-color: var(--crimson); color: var(--crimson); }
.addline:disabled { opacity: 0.55; cursor: default; }

/* ---- Customer price-level chip (T5 — tier data ships on the CSR page only) ---- */
.tier-chip {
  display: inline-flex;
  align-self: flex-start;
  align-items: center;
  margin-top: 8px;
  background: var(--gold);
  color: var(--navy-dark);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 4px 10px;
}
.tier-chip.unknown { background: var(--light-gray); color: var(--charcoal); }

/* ---- Material-line price display + custom override (T5) ---- */
.price-display {
  font-family: var(--font);
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--navy);
  background: var(--off-white);
  border: 1px solid var(--border);
  padding: 12px 14px;
  min-height: 20px;
  line-height: 1.3;
  display: flex;
  align-items: center;
}
.price-display.is-empty { color: var(--help); font-weight: 400; font-style: italic; }
.price-display.is-custom { color: var(--crimson-dark); background: var(--white); border-color: var(--crimson); }

/* ---- Price-check link + best-quarry-prices modal ---- */
.price-check {
  display: inline-block;
  margin-top: 8px;
  background: none;
  border: none;
  padding: 0;
  font-family: var(--font);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--crimson);
  cursor: pointer;
  border-bottom: 1px solid transparent;
}
.price-check:hover { color: var(--crimson-dark); border-bottom-color: var(--crimson-dark); }

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(30, 47, 59, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 50;
}
.modal {
  background: var(--white);
  border-top: 4px solid var(--crimson);
  max-width: 640px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  padding: 22px 24px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
}
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.modal-head h3 {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--navy);
}
.modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  line-height: 1;
  color: var(--charcoal);
  cursor: pointer;
  padding: 0 2px;
}
.modal-close:hover { color: var(--crimson); }
.modal-sub { margin: 8px 0 12px; font-size: 0.82rem; color: var(--help); }
.modal-loading { margin: 16px 0; font-size: 0.9rem; color: var(--charcoal); }
.modal-foot { margin: 14px 0 0; font-size: 0.75rem; color: var(--help); }
.modal-foot a { color: var(--crimson); }

.price-scroll { overflow-x: auto; }
.price-table { border-collapse: collapse; width: 100%; font-size: 0.84rem; }
.price-table th {
  text-align: left;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--charcoal);
  padding: 6px 10px 6px 0;
  border-bottom: 2px solid var(--light-gray);
}
.price-table td { padding: 8px 10px 8px 0; border-bottom: 1px solid var(--light-gray); color: var(--navy); vertical-align: top; }
.price-table td.pit { font-weight: 600; }
.price-table td.mi { white-space: nowrap; color: var(--charcoal); }
.price-table td.mat .unit { color: var(--help); font-size: 0.75rem; }
.price-table .own {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 5px;
  background: var(--crimson);
  color: var(--white);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  vertical-align: middle;
}

/* ---- Report an issue (internal error reporting) ---- */
.report-fab {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 60;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 15px;
  border: 1px solid var(--crimson);
  background: var(--crimson);
  color: var(--white);
  font-family: var(--font);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(28, 40, 51, 0.22);
}
.report-fab:hover {
  background: var(--crimson-dark);
  border-color: var(--crimson-dark);
}
.report-panel {
  position: fixed;
  right: 16px;
  bottom: 62px;
  z-index: 60;
  width: min(360px, calc(100vw - 32px));
  background: var(--white);
  border: 1px solid var(--border);
  border-top: 3px solid var(--crimson);
  box-shadow: 0 16px 44px rgba(28, 40, 51, 0.28);
  padding: 16px 18px 18px;
}
.report-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.report-head strong {
  font-size: 0.95rem;
  color: var(--navy);
}
.report-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  line-height: 1;
  color: var(--charcoal);
  cursor: pointer;
  padding: 0 2px;
  width: auto;
}
.report-close:hover {
  color: var(--crimson);
}
.report-sub {
  margin: 6px 0 10px;
  font-size: 0.8rem;
  color: var(--help);
  line-height: 1.45;
}
.report-text {
  width: 100%;
  min-height: 90px;
  border: 1px solid var(--border);
  border-radius: 0;
  padding: 10px 12px;
  font-family: var(--font);
  font-size: 0.9rem;
  resize: vertical;
}
.report-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 12px;
}
.report-cancel {
  width: auto;
  padding: 9px 16px;
  border: 1px solid var(--border);
  background: var(--white);
  font-family: var(--font);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--navy);
  cursor: pointer;
}
.report-cancel:hover {
  border-color: var(--crimson);
  color: var(--crimson);
}
.report-submit {
  width: auto;
  padding: 9px 18px;
  border: 1px solid var(--crimson);
  background: var(--crimson);
  color: var(--white);
  font-family: var(--font);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
}
.report-submit:hover:not(:disabled) {
  background: var(--crimson-dark);
  border-color: var(--crimson-dark);
}
.report-submit:disabled {
  opacity: 0.6;
  cursor: default;
}
.report-confirm {
  margin: 12px 0 0;
  font-size: 0.82rem;
  color: #2d7a3a;
}
.report-confirm.err {
  color: var(--crimson);
}

/* ---- Interactive Map handoff (docs/2026-07-10-map-intake-handoff-design.md) ---- */
/* The map opener is a <button> (an anchor's rel=noopener would sever the live pick
   channel); make it render exactly like the .maplink anchor it replaced. */
button.maplink {
  background: none;
  border: none;
  border-bottom: 1px solid rgba(156, 29, 31, 0.35);
  padding: 0;
  font-family: inherit;
  cursor: pointer;
}
/* Field use: give the map-picker button a real finger target on touch devices. */
@media (pointer: coarse) {
  button.maplink { padding: 10px 4px; }
}

/* Flash on the material line a map pick just filled. */
.mat-line.map-filled {
  outline: 2px solid #16a34a;
  outline-offset: 3px;
  border-radius: 8px;
}

/* Confirmation / warning toast for arriving picks. Sits above the bottom-right
   "Report an issue" fab so neither covers the other on narrow screens. */
#mapToast {
  position: fixed;
  left: 50%;
  bottom: 76px;
  transform: translateX(-50%) translateY(12px);
  max-width: min(560px, 90vw);
  padding: 10px 16px;
  border-radius: 8px;
  font-size: 14px;
  line-height: 1.4;
  color: #fff;
  background: #16a34a;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s, transform 0.25s;
  z-index: 1000;
}
#mapToast.warn { background: #b45309; }
#mapToast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
