/* L.Grid.css - Ultra High-Contrast Nautical Graticule Labels for UkSeas */

  .leaflet-grid-label {
    pointer-events: none;
    user-select: none;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Segoe UI", monospace;
    font-size: 11px;
    font-weight: 700;
    color: #0f172a;
    white-space: nowrap;
    z-index: 850;
  }

  /* Light Mode (Default): Dark text on crisp white badge */
  .leaflet-grid-label .lng {
    margin-top: 4px;
    margin-left: 2px;
    color: #0f172a;
    text-shadow: -1px -1px 0 #fff, 1px -1px 0 #fff, -1px 1px 0 #fff, 1px 1px 0 #fff;
    background: rgba(255, 255, 255, 0.95);
    padding: 2px 5px;
    border-radius: 3px;
    border: 1px solid rgba(15, 23, 42, 0.5);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.45);
    display: inline-block;
    line-height: 1.2;
  }

  .leaflet-grid-label .lat {
    margin-left: 6px;
    margin-top: -8px;
    color: #0f172a;
    text-shadow: -1px -1px 0 #fff, 1px -1px 0 #fff, -1px 1px 0 #fff, 1px 1px 0 #fff;
    background: rgba(255, 255, 255, 0.95);
    padding: 2px 5px;
    border-radius: 3px;
    border: 1px solid rgba(15, 23, 42, 0.5);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.45);
    display: inline-block;
    line-height: 1.2;
  }

  /* Dark Mode: White text on solid black badge */
  [data-theme="dark"] .leaflet-grid-label,
  html:not([data-theme="light"]) .leaflet-grid-label {
    color: #ffffff;
  }

  [data-theme="dark"] .leaflet-grid-label .lng,
  [data-theme="dark"] .leaflet-grid-label .lat,
  html:not([data-theme="light"]) .leaflet-grid-label .lng,
  html:not([data-theme="light"]) .leaflet-grid-label .lat {
    color: #ffffff;
    text-shadow: -1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000, 1px 1px 0 #000;
    background: #000000;
    border: 1px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.85);
  }

  /* Graticule Line Styling: Pale slate gray */
  .leaflet-graticule-line {
    stroke: #64748b;
  }

  [data-theme="dark"] .leaflet-graticule-line,
  html:not([data-theme="light"]) .leaflet-graticule-line {
    stroke: #94a3b8;
  }
