:root {
  color-scheme: light;
  --bg: #eef2f7;
  --surface: #ffffff;
  --surface-strong: #f8fafc;
  --text: #0f172a;
  --muted: #64748b;
  --border: #dbe3ee;
  --accent: #2563eb;
  --accent-dark: #1d4ed8;
  --accent-soft: #dbeafe;
  --success: #0f9f6e;
  --warning: #d97706;
  --danger: #dc2626;
  --shadow: 0 14px 35px rgba(15, 23, 42, 0.12);
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html,
body {
  margin: 0;
  min-width: 320px;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

body {
  min-height: 100dvh;
  overflow: hidden;
}

button,
input {
  font: inherit;
}

button {
  -webkit-tap-highlight-color: transparent;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.app-shell {
  height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--surface);
}

.topbar {
  min-height: calc(62px + var(--safe-top));
  padding: calc(10px + var(--safe-top)) 18px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  background: #0b1220;
  color: #fff;
  z-index: 30;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}

.brand-mark {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: var(--accent);
}

.brand-mark svg {
  width: 24px;
  height: 24px;
  fill: #fff;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  font-size: 1rem;
  line-height: 1.15;
  letter-spacing: -0.01em;
}

.brand small {
  margin-top: 2px;
  color: #94a3b8;
  font-size: 0.73rem;
}

.connection-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #cbd5e1;
  font-size: 0.78rem;
  white-space: nowrap;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #f59e0b;
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.14);
}

.connection-status.is-ready .status-dot {
  background: #34d399;
  box-shadow: 0 0 0 4px rgba(52, 211, 153, 0.14);
}

.connection-status.is-error .status-dot {
  background: #f87171;
  box-shadow: 0 0 0 4px rgba(248, 113, 113, 0.14);
}

.workspace {
  position: relative;
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-rows: auto minmax(250px, 1fr) auto;
  background: var(--surface);
}

.search-area {
  position: relative;
  z-index: 25;
  padding: 12px 14px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

.search-box {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 8px;
  min-height: 50px;
  padding: 5px 5px 5px 14px;
  border: 1px solid #cbd5e1;
  border-radius: 15px;
  background: #fff;
  box-shadow: 0 5px 18px rgba(15, 23, 42, 0.08);
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.search-box:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12), 0 7px 20px rgba(15, 23, 42, 0.1);
}

.search-icon {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: var(--muted);
  stroke-width: 1.8;
  stroke-linecap: round;
}

#placeSearch {
  min-width: 0;
  height: 40px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
  font-size: 1rem;
}

#placeSearch::placeholder {
  color: #94a3b8;
}

.icon-button {
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.clear-button {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 10px;
}

.clear-button:hover,
.clear-button:focus-visible {
  background: #f1f5f9;
}

.clear-button svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
}

.search-submit {
  min-height: 40px;
  padding: 0 16px;
  border: 0;
  border-radius: 11px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  cursor: pointer;
}

.search-submit:hover,
.search-submit:focus-visible {
  background: var(--accent-dark);
}

.search-submit:disabled {
  opacity: 0.55;
  cursor: wait;
}

.suggestions {
  position: absolute;
  top: calc(100% - 7px);
  left: 14px;
  right: 14px;
  max-height: min(48dvh, 420px);
  overflow-y: auto;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #fff;
  box-shadow: var(--shadow);
  z-index: 50;
}

.suggestion-item {
  width: 100%;
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 13px 14px;
  border: 0;
  border-bottom: 1px solid #edf1f6;
  background: #fff;
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.suggestion-item:last-child {
  border-bottom: 0;
}

.suggestion-item:hover,
.suggestion-item:focus-visible,
.suggestion-item.is-active {
  background: #f8fafc;
}

.suggestion-pin {
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  display: grid;
  place-items: center;
  margin-top: 1px;
  border-radius: 9px;
  background: var(--accent-soft);
  color: var(--accent-dark);
}

.suggestion-pin svg {
  width: 17px;
  height: 17px;
  fill: currentColor;
}

.suggestion-pin.is-numbered {
  background: #2563eb;
  color: #fff;
  font-size: 0.8rem;
  font-weight: 800;
  line-height: 1;
}

.suggestion-item.is-selected {
  background: #eff6ff;
  box-shadow: inset 3px 0 0 #2563eb;
}

.suggestion-item.is-selected .suggestion-pin.is-numbered {
  background: #1d4ed8;
}

.suggestion-text {
  min-width: 0;
  line-height: 1.35;
}

.suggestion-text strong {
  display: block;
  font-size: 0.94rem;
  font-weight: 650;
}

.suggestion-text small {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.8rem;
}

.suggestions-message {
  padding: 16px;
  color: var(--muted);
  font-size: 0.9rem;
  text-align: center;
}

.results-heading {
  padding: 9px 14px 7px;
  border-bottom: 1px solid #edf1f6;
  background: #f8fafc;
  color: #64748b;
  font-size: 0.72rem;
  font-weight: 750;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.suggestion-distance {
  flex: 0 0 auto;
  align-self: center;
  margin-left: auto;
  padding: 5px 8px;
  border-radius: 999px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 0.74rem;
  font-weight: 750;
  white-space: nowrap;
}

.location-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
}

.location-status {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #f8fafc;
}

.location-status.is-user {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.location-status.is-stale {
  border-color: #fed7aa;
  background: #fff7ed;
}

.location-status-icon {
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: #e2e8f0;
  color: #475569;
}

.location-status.is-user .location-status-icon {
  background: #dbeafe;
  color: #1d4ed8;
}

.location-status.is-stale .location-status-icon {
  background: #ffedd5;
  color: #c2410c;
}

.location-status-icon svg {
  width: 17px;
  height: 17px;
  fill: currentColor;
}

.location-status-copy {
  min-width: 0;
}

.location-status-copy strong,
.location-status-copy small {
  display: block;
}

.location-status-copy strong {
  overflow: hidden;
  color: #0f172a;
  font-size: 0.8rem;
  font-weight: 720;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.location-status-copy small {
  margin-top: 2px;
  overflow: hidden;
  color: var(--muted);
  font-size: 0.7rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.location-actions {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.location-button {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 11px;
  border: 1px solid #bfdbfe;
  border-radius: 11px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 0.76rem;
  font-weight: 720;
  cursor: pointer;
}

.location-button:hover,
.location-button:focus-visible {
  border-color: #93c5fd;
  background: #dbeafe;
}

.location-button-secondary {
  border-color: #cbd5e1;
  background: #fff;
  color: #334155;
}

.location-button-secondary:hover,
.location-button-secondary:focus-visible,
.location-button-secondary.is-active {
  border-color: #94a3b8;
  background: #f1f5f9;
}

.location-button:disabled {
  opacity: 0.55;
  cursor: wait;
}

.location-button svg {
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.location-button.is-busy svg {
  animation: location-spin 1s linear infinite;
}

@keyframes location-spin {
  to { transform: rotate(360deg); }
}

.map-stage {
  position: relative;
  min-height: 0;
  overflow: hidden;
  background: #dce5ef;
}

.map-canvas,
.map-placeholder {
  position: absolute;
  inset: 0;
}

.map-canvas {
  z-index: 1;
}

.map-placeholder {
  display: grid;
  place-items: center;
  padding: 20px;
  background: #e8eef5;
  z-index: 5;
}

.placeholder-grid {
  position: absolute;
  inset: 0;
  opacity: 0.55;
  background-image:
    linear-gradient(rgba(100, 116, 139, 0.15) 1px, transparent 1px),
    linear-gradient(90deg, rgba(100, 116, 139, 0.15) 1px, transparent 1px),
    radial-gradient(circle at 28% 34%, rgba(37, 99, 235, 0.15), transparent 28%),
    radial-gradient(circle at 76% 68%, rgba(15, 159, 110, 0.13), transparent 26%);
  background-size: 48px 48px, 48px 48px, auto, auto;
}

.setup-card {
  position: relative;
  width: min(430px, 100%);
  padding: 24px;
  border: 1px solid rgba(203, 213, 225, 0.9);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
  text-align: center;
}

.setup-icon {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  margin: 0 auto 14px;
  border-radius: 16px;
  background: var(--accent-soft);
  color: var(--accent-dark);
}

.setup-icon svg {
  width: 30px;
  height: 30px;
  fill: currentColor;
}

.setup-card h1 {
  margin: 0;
  font-size: 1.1rem;
}

.setup-card p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.5;
  font-size: 0.9rem;
}

.setup-card code {
  display: inline-block;
  margin-top: 12px;
  padding: 7px 10px;
  border-radius: 8px;
  background: #0f172a;
  color: #e2e8f0;
  font-size: 0.82rem;
}

.map-toolbar {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 10;
  display: inline-flex;
  padding: 4px;
  border: 1px solid rgba(203, 213, 225, 0.95);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 7px 20px rgba(15, 23, 42, 0.14);
  backdrop-filter: blur(8px);
}

.map-type {
  min-height: 34px;
  padding: 0 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #475569;
  font-size: 0.78rem;
  font-weight: 650;
  cursor: pointer;
}

.map-type.is-active {
  background: #0f172a;
  color: #fff;
}

.map-tip {
  position: absolute;
  left: 50%;
  bottom: 13px;
  z-index: 10;
  max-width: calc(100% - 28px);
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.88);
  color: #fff;
  box-shadow: 0 7px 18px rgba(15, 23, 42, 0.22);
  font-size: 0.78rem;
  white-space: nowrap;
  backdrop-filter: blur(8px);
}

.map-tip svg {
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
  fill: #93c5fd;
}

.result-sheet {
  position: relative;
  z-index: 20;
  padding: 14px 14px calc(14px + var(--safe-bottom));
  border-top: 1px solid var(--border);
  background: #fff;
  box-shadow: 0 -10px 30px rgba(15, 23, 42, 0.08);
}

.place-summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.place-copy {
  min-width: 0;
}

.place-heading-row {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.place-heading-row h2 {
  min-width: 0;
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 1rem;
}

.place-copy p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.35;
}

.manual-badge {
  flex: 0 0 auto;
  padding: 3px 7px;
  border-radius: 999px;
  background: #fff7ed;
  color: #c2410c;
  font-size: 0.68rem;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.coordinates-box {
  min-width: 168px;
  padding: 9px 11px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface-strong);
  text-align: right;
}

.coordinates-label {
  display: block;
  color: var(--muted);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

#coordinates {
  display: block;
  margin-top: 3px;
  color: var(--text);
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 0.84rem;
  font-weight: 700;
  white-space: nowrap;
}

.destination-actions {
  display: grid;
  gap: 9px;
}

.destination-action {
  width: 100%;
  min-height: 62px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) 24px;
  align-items: center;
  gap: 11px;
  padding: 10px 14px;
  border-radius: 15px;
  text-align: left;
  cursor: pointer;
  transition: transform 120ms ease, background 120ms ease, border-color 120ms ease, box-shadow 120ms ease;
}

.primary-action {
  border: 0;
  background: var(--accent);
  color: #fff;
  box-shadow: 0 10px 24px rgba(37, 99, 235, 0.24);
}

.primary-action:hover,
.primary-action:focus-visible {
  background: var(--accent-dark);
  box-shadow: 0 12px 28px rgba(37, 99, 235, 0.3);
}

.primary-action:active {
  transform: translateY(1px);
}

.primary-action:disabled {
  background: #cbd5e1;
  color: #64748b;
  box-shadow: none;
  cursor: not-allowed;
}

.secondary-action {
  border: 1px solid #cbd5e1;
  background: #fff;
  color: #0f172a;
  box-shadow: 0 7px 18px rgba(15, 23, 42, 0.08);
}

.secondary-action:hover,
.secondary-action:focus-visible {
  border-color: #94a3b8;
  background: #f8fafc;
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.12);
}

.secondary-action:active,
.destination-action:active {
  transform: translateY(1px);
}

.secondary-action:disabled {
  border-color: #e2e8f0;
  background: #f1f5f9;
  color: #94a3b8;
  box-shadow: none;
  cursor: not-allowed;
}

.secondary-action .action-icon {
  background: #e2e8f0;
}

.secondary-action .action-copy small {
  color: #64748b;
}

.secondary-action:disabled .action-copy small {
  color: #94a3b8;
}

.action-hint {
  margin: 9px 2px 0;
  color: var(--muted);
  font-size: 0.72rem;
  line-height: 1.35;
}

.action-icon {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.16);
}

.action-icon svg,
.action-arrow {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.action-icon svg {
  width: 22px;
  height: 22px;
}

.action-copy {
  min-width: 0;
}

.action-copy strong,
.action-copy small {
  display: block;
}

.action-copy strong {
  font-size: 0.95rem;
}

.action-copy small {
  margin-top: 2px;
  color: rgba(255, 255, 255, 0.76);
  font-size: 0.72rem;
}

.primary-action:disabled .action-copy small {
  color: #64748b;
}

.action-arrow {
  width: 22px;
  height: 22px;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(18px + var(--safe-bottom));
  z-index: 100;
  max-width: calc(100% - 30px);
  transform: translateX(-50%);
  padding: 11px 14px;
  border-radius: 12px;
  background: #0f172a;
  color: #fff;
  box-shadow: var(--shadow);
  font-size: 0.86rem;
  text-align: center;
}

.toast.is-error {
  background: #991b1b;
}

.noscript {
  position: fixed;
  inset: 0;
  z-index: 999;
  display: grid;
  place-items: center;
  padding: 30px;
  background: #fff;
  color: #0f172a;
  text-align: center;
}

@media (max-width: 640px) {
  .topbar {
    min-height: calc(58px + var(--safe-top));
    padding-inline: 14px;
  }

  .brand-mark {
    width: 34px;
    height: 34px;
    flex-basis: 34px;
    border-radius: 10px;
  }

  .brand-mark svg {
    width: 21px;
    height: 21px;
  }

  .connection-status span:last-child {
    display: none;
  }

  .search-area {
    padding: 10px;
  }

  .search-box {
    grid-template-columns: 22px minmax(0, 1fr) auto auto;
    min-height: 48px;
    padding-left: 11px;
  }

  .search-submit {
    width: 44px;
    padding: 0;
  }

  .search-submit span {
    display: none;
  }

  .search-submit::before {
    content: "→";
    font-size: 1.25rem;
  }

  .suggestions {
    left: 10px;
    right: 10px;
  }

  .location-panel {
    grid-template-columns: minmax(0, 1fr);
    gap: 7px;
    margin-top: 8px;
  }

  .location-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .location-button {
    min-width: 0;
    min-height: 38px;
    padding-inline: 8px;
    font-size: 0.7rem;
  }

  .location-status {
    padding-block: 7px;
  }

  .suggestion-distance {
    padding-inline: 7px;
    font-size: 0.7rem;
  }

  .map-toolbar {
    top: 9px;
    right: 9px;
  }

  .map-type {
    min-height: 32px;
    padding-inline: 8px;
    font-size: 0.72rem;
  }

  .map-tip {
    bottom: 10px;
    white-space: normal;
    text-align: center;
  }

  .result-sheet {
    padding: 11px 11px calc(11px + var(--safe-bottom));
  }

  .place-summary {
    grid-template-columns: minmax(0, 1fr);
    gap: 9px;
  }

  .coordinates-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-width: 0;
    text-align: left;
  }

  #coordinates {
    margin-top: 0;
    font-size: 0.82rem;
  }

  .destination-action {
    min-height: 58px;
  }

  .action-hint {
    display: none;
  }
}

@media (min-width: 900px) {
  body {
    padding: 22px;
    background: #dfe6ef;
  }

  .app-shell {
    width: min(1180px, 100%);
    height: calc(100dvh - 44px);
    margin: 0 auto;
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, 0.45);
    border-radius: 22px;
    box-shadow: 0 25px 60px rgba(15, 23, 42, 0.18);
  }

  .workspace {
    grid-template-columns: 365px minmax(0, 1fr);
    grid-template-rows: auto minmax(0, 1fr);
  }

  .search-area {
    grid-column: 1;
    grid-row: 1;
    border-right: 1px solid var(--border);
  }

  .map-stage {
    grid-column: 2;
    grid-row: 1 / span 2;
  }

  .result-sheet {
    grid-column: 1;
    grid-row: 2;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    border-top: 0;
    border-right: 1px solid var(--border);
    box-shadow: none;
  }

  .place-summary {
    grid-template-columns: minmax(0, 1fr);
  }

  .coordinates-box {
    text-align: left;
  }

  .location-panel {
    grid-template-columns: minmax(0, 1fr);
  }

  .location-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .location-button {
    min-width: 0;
    padding-inline: 8px;
    font-size: 0.72rem;
  }

  .suggestions {
    max-height: 440px;
  }
}

/* =========================================================
   v0.4.1 — stały panel eksportu i czytelniejsze markery
   ========================================================= */

.selected-point-label {
  display: block;
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.suggestion-pin.is-numbered {
  width: 34px;
  height: 34px;
  flex-basis: 34px;
  border: 2px solid #ffffff;
  border-radius: 11px;
  background: #0866ff;
  box-shadow: 0 3px 9px rgba(8, 102, 255, 0.3);
  font-size: 0.82rem;
}

.suggestion-item.is-selected .suggestion-pin.is-numbered {
  background: #004fd6;
}

/* Eksport jest zawsze kompaktowy i dostępny bez przewijania listy. */
.destination-actions {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.destination-action {
  min-height: 50px;
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 9px;
  padding: 8px 11px;
  border-radius: 13px;
}

.action-icon {
  width: 32px;
  height: 32px;
  border-radius: 9px;
}

.action-icon svg {
  width: 19px;
  height: 19px;
}

.action-copy strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.86rem;
}

.action-copy small,
.action-arrow,
.action-hint {
  display: none;
}

.place-copy p {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 640px) {
  .suggestions {
    max-height: min(34dvh, 270px);
  }

  .result-sheet {
    padding: 9px 10px calc(9px + var(--safe-bottom));
  }

  .place-summary {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    margin-bottom: 8px;
  }

  .place-copy p {
    display: none;
  }

  .place-heading-row h2 {
    font-size: 0.9rem;
  }

  .selected-point-label {
    margin-bottom: 2px;
    font-size: 0.6rem;
  }

  .coordinates-box {
    min-width: 124px;
    padding: 7px 9px;
  }

  .coordinates-label {
    display: none;
  }

  #coordinates {
    font-size: 0.72rem;
  }

  .destination-action {
    min-height: 46px;
    grid-template-columns: 28px minmax(0, 1fr);
    gap: 7px;
    padding: 7px 9px;
  }

  .action-icon {
    width: 28px;
    height: 28px;
    border-radius: 8px;
  }

  .action-icon svg {
    width: 17px;
    height: 17px;
  }

  .action-copy strong {
    font-size: 0.78rem;
  }
}

@media (min-width: 900px) {
  .workspace {
    grid-template-rows: minmax(0, 1fr) auto;
  }

  .search-area {
    display: flex;
    min-height: 0;
    flex-direction: column;
    overflow: hidden;
    padding-bottom: 0;
  }

  .suggestions {
    position: relative;
    top: auto;
    left: auto;
    right: auto;
    flex: 1 1 auto;
    min-height: 0;
    max-height: none;
    margin: 10px -14px 0;
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
    border-radius: 0;
    box-shadow: none;
  }

  .result-sheet {
    justify-content: initial;
    padding: 11px 13px 13px;
    background: #ffffff;
    box-shadow: 0 -8px 22px rgba(15, 23, 42, 0.06);
  }

  .place-summary {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 9px;
    margin-bottom: 9px;
  }

  .place-heading-row h2 {
    font-size: 0.92rem;
  }

  .place-copy p {
    margin-top: 2px;
    font-size: 0.72rem;
  }

  .coordinates-box {
    min-width: 140px;
    padding: 7px 9px;
    text-align: right;
  }

  .coordinates-label {
    font-size: 0.6rem;
  }

  #coordinates {
    font-size: 0.72rem;
  }
}


/* =========================================================
   v0.4.2 — równorzędny eksport, jeden X i czytelne tryby
   ========================================================= */

/* Ukrywamy natywny przycisk czyszczenia input[type="search"].
   Pozostaje wyłącznie nasz jeden, zawsze przewidywalny przycisk X. */
#placeSearch::-webkit-search-cancel-button,
#placeSearch::-webkit-search-decoration,
#placeSearch::-webkit-search-results-button,
#placeSearch::-webkit-search-results-decoration {
  -webkit-appearance: none;
  appearance: none;
  display: none;
}

#placeSearch::-ms-clear,
#placeSearch::-ms-reveal {
  display: none;
  width: 0;
  height: 0;
}

/* Oba kierunki eksportu są równorzędne — żaden nie jest domyślny. */
.primary-action,
.secondary-action {
  border: 1px solid #b8c9e6;
  background: #f7faff;
  color: #172033;
  box-shadow: 0 5px 14px rgba(15, 23, 42, 0.08);
}

.primary-action:hover,
.primary-action:focus-visible,
.secondary-action:hover,
.secondary-action:focus-visible {
  border-color: #79a4f7;
  background: #eaf2ff;
  color: #102044;
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.15);
}

.primary-action .action-icon,
.secondary-action .action-icon {
  background: #e6eefc;
  color: #20345f;
}

.primary-action .action-copy small,
.secondary-action .action-copy small {
  color: #64748b;
}

.primary-action:disabled,
.secondary-action:disabled {
  border-color: #e2e8f0;
  background: #f1f5f9;
  color: #94a3b8;
  box-shadow: none;
  cursor: not-allowed;
}

.primary-action:disabled .action-icon,
.secondary-action:disabled .action-icon {
  background: #e2e8f0;
  color: #94a3b8;
}

.primary-action:disabled .action-copy small,
.secondary-action:disabled .action-copy small {
  color: #94a3b8;
}

/* Oba przełączniki zaczynają jako neutralne. Aktywny tryb ma
   jednoznaczne, ale nienachalne podświetlenie. */
.location-button,
.location-button-secondary {
  border-color: #cbd5e1;
  background: #ffffff;
  color: #334155;
  box-shadow: none;
}

.location-button:hover,
.location-button:focus-visible,
.location-button-secondary:hover,
.location-button-secondary:focus-visible {
  border-color: #93c5fd;
  background: #f4f8ff;
  color: #1d4ed8;
}

.location-button.is-active,
.location-button-secondary.is-active {
  border-color: #60a5fa;
  background: #dbeafe;
  color: #1d4ed8;
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.08), 0 4px 12px rgba(37, 99, 235, 0.10);
}

.location-button.is-active:hover,
.location-button.is-active:focus-visible,
.location-button-secondary.is-active:hover,
.location-button-secondary.is-active:focus-visible {
  border-color: #3b82f6;
  background: #cfe3ff;
}

.location-button.is-busy {
  border-color: #f59e0b;
  background: #fff7ed;
  color: #b45309;
}

.location-button.is-busy:disabled {
  opacity: 1;
}
