{
  "version": 8,
  "name": "Magda Europe",
  "metadata": {
    "maptiler:copyright": "© OpenStreetMap contributors",
    "magda:notes": "PMTiles/Protomaps basemap style. Landuse layers are filtered — no default catch-all fill. Water is drawn above landuse so rivers are never hidden."
  },
  "glyphs": "https://protomaps.github.io/basemaps-assets/fonts/{fontstack}/{range}.pbf",
  "sprite": "https://protomaps.github.io/basemaps-assets/sprites/v4/light",
  "sources": {
    "protomaps": {
      "type": "vector",
      "tiles": ["https://tiles.magdazpodlasia.pl/europe-20260608-z14/{z}/{x}/{y}"],
      "minzoom": 0,
      "maxzoom": 14,
      "attribution": "© <a href=\"https://www.openstreetmap.org/copyright\" target=\"_blank\" rel=\"noopener\">OpenStreetMap contributors</a>"
    }
  },
  "layers": [
    {
      "id": "background",
      "type": "background",
      "paint": {
        "background-color": "#eef1e8"
      }
    },
    {
      "id": "landuse-green",
      "type": "fill",
      "source": "protomaps",
      "source-layer": "landuse",
      "minzoom": 7,
      "filter": [
        "in",
        ["get", "kind"],
        [
          "literal",
          [
            "park",
            "forest",
            "wood",
            "nature_reserve",
            "national_park",
            "protected_area",
            "recreation_ground",
            "village_green",
            "dog_park",
            "garden",
            "golf_course",
            "allotments",
            "playground"
          ]
        ]
      ],
      "paint": {
        "fill-color": [
          "match",
          ["get", "kind"],
          "national_park",
          "#d4e4cc",
          "protected_area",
          "#d4e4cc",
          "nature_reserve",
          "#cfe3c1",
          "forest",
          "#cfe3c1",
          "wood",
          "#d0e0c4",
          "park",
          "#d8e8c8",
          "golf_course",
          "#c8ddb8",
          "#d6e6c8"
        ],
        "fill-opacity": [
          "case",
          ["in", ["get", "kind"], ["literal", ["national_park", "protected_area", "nature_reserve"]]],
          0.35,
          ["in", ["get", "kind"], ["literal", ["forest", "wood"]]],
          0.5,
          0.6
        ]
      }
    },
    {
      "id": "landuse-natural",
      "type": "fill",
      "source": "protomaps",
      "source-layer": "landuse",
      "minzoom": 7,
      "filter": [
        "in",
        ["get", "kind"],
        [
          "literal",
          ["wetland", "meadow", "grass", "grassland", "scrub", "sand", "beach", "bare_rock"]
        ]
      ],
      "paint": {
        "fill-color": [
          "match",
          ["get", "kind"],
          "wetland",
          "#c5ddd4",
          "sand",
          "#e8e2d0",
          "beach",
          "#e8e2d0",
          "bare_rock",
          "#ddd8ce",
          "#d4e0c8"
        ],
        "fill-opacity": [
          "case",
          ["==", ["get", "kind"], "wetland"],
          0.28,
          ["in", ["get", "kind"], ["literal", ["sand", "beach", "bare_rock"]]],
          0.35,
          0.3
        ]
      }
    },
    {
      "id": "landuse-amenity",
      "type": "fill",
      "source": "protomaps",
      "source-layer": "landuse",
      "minzoom": 10,
      "filter": [
        "in",
        ["get", "kind"],
        [
          "literal",
          ["cemetery", "hospital", "school", "university", "kindergarten", "college"]
        ]
      ],
      "paint": {
        "fill-color": [
          "match",
          ["get", "kind"],
          "cemetery",
          "#d9dec4",
          "hospital",
          "#f3dce4",
          "school",
          "#ece8c9",
          "university",
          "#e8e4c4",
          "kindergarten",
          "#f0e8c8",
          "#ece8c9"
        ],
        "fill-opacity": 0.65
      }
    },
    {
      "id": "water",
      "type": "fill",
      "source": "protomaps",
      "source-layer": "water",
      "filter": [
        "any",
        ["in", ["get", "kind_detail"], ["literal", ["lake", "reservoir"]]],
        ["in", ["get", "kind"], ["literal", ["ocean", "sea", "lake"]]]
      ],
      "paint": {
        "fill-color": "#a8cfe7"
      }
    },
    {
      "id": "water-lines",
      "type": "line",
      "source": "protomaps",
      "source-layer": "water",
      "filter": [
        "any",
        ["in", ["get", "kind"], ["literal", ["river", "canal", "stream"]]],
        ["in", ["get", "kind_detail"], ["literal", ["river", "stream", "canal"]]]
      ],
      "paint": {
        "line-color": "#87bedc",
        "line-width": [
          "interpolate",
          ["linear"],
          ["zoom"],
          7,
          0.5,
          8,
          0.6,
          12,
          1.4,
          15,
          2.4
        ],
        "line-opacity": 0.9
      }
    },
    {
      "id": "boundaries",
      "type": "line",
      "source": "protomaps",
      "source-layer": "boundaries",
      "minzoom": 4,
      "filter": [
        "all",
        ["<=", ["get", "kind_detail"], 4]
      ],
      "paint": {
        "line-color": "rgba(77, 66, 56, 0.24)",
        "line-dasharray": [3, 2],
        "line-width": [
          "interpolate",
          ["linear"],
          ["zoom"],
          4,
          0.5,
          10,
          1.1
        ]
      }
    },
    {
      "id": "roads-minor-casing",
      "type": "line",
      "source": "protomaps",
      "source-layer": "roads",
      "minzoom": 10,
      "filter": [
        "in",
        ["get", "kind"],
        ["literal", ["minor_road", "path", "track", "service", "other"]]
      ],
      "paint": {
        "line-color": "#969188",
        "line-width": [
          "interpolate",
          ["linear"],
          ["zoom"],
          10,
          1.6,
          12,
          2.4,
          15,
          3.6
        ]
      }
    },
    {
      "id": "roads-minor",
      "type": "line",
      "source": "protomaps",
      "source-layer": "roads",
      "minzoom": 10,
      "filter": [
        "in",
        ["get", "kind"],
        ["literal", ["minor_road", "path", "track", "service", "other"]]
      ],
      "paint": {
        "line-color": "#ffffff",
        "line-width": [
          "interpolate",
          ["linear"],
          ["zoom"],
          10,
          1,
          12,
          1.6,
          15,
          2.8
        ]
      }
    },
    {
      "id": "roads-major-casing",
      "type": "line",
      "source": "protomaps",
      "source-layer": "roads",
      "minzoom": 7,
      "filter": [
        "in",
        ["get", "kind"],
        ["literal", ["highway", "major_road"]]
      ],
      "paint": {
        "line-color": "#a39e96",
        "line-width": [
          "interpolate",
          ["linear"],
          ["zoom"],
          7,
          1.2,
          12,
          3,
          15,
          5.5
        ]
      }
    },
    {
      "id": "roads-major",
      "type": "line",
      "source": "protomaps",
      "source-layer": "roads",
      "minzoom": 7,
      "filter": [
        "in",
        ["get", "kind"],
        ["literal", ["highway", "major_road"]]
      ],
      "paint": {
        "line-color": [
          "match",
          ["get", "kind"],
          "highway",
          "#f3c080",
          "major_road",
          "#f4d49b",
          "#fff0bf"
        ],
        "line-width": [
          "interpolate",
          ["linear"],
          ["zoom"],
          7,
          0.55,
          12,
          2,
          15,
          4
        ]
      }
    },
    {
      "id": "buildings",
      "type": "fill",
      "source": "protomaps",
      "source-layer": "buildings",
      "minzoom": 14,
      "paint": {
        "fill-color": "#dedbd0",
        "fill-opacity": [
          "interpolate",
          ["linear"],
          ["zoom"],
          14,
          0.24,
          15,
          0.42
        ]
      }
    },
    {
      "id": "place-labels-region",
      "type": "symbol",
      "source": "protomaps",
      "source-layer": "places",
      "minzoom": 4,
      "filter": [
        "any",
        ["==", ["get", "kind"], "country"],
        ["==", ["get", "kind"], "region"],
        ["in", ["get", "kind_detail"], ["literal", ["country", "state", "province"]]]
      ],
      "layout": {
        "text-field": ["coalesce", ["get", "name:pl"], ["get", "name:en"], ["get", "name"]],
        "text-font": ["Noto Sans Medium"],
        "text-size": [
          "interpolate",
          ["linear"],
          ["zoom"],
          4,
          11,
          8,
          14,
          12,
          16
        ],
        "text-max-width": 8,
        "text-letter-spacing": 0.04,
        "symbol-sort-key": ["*", -1, ["coalesce", ["get", "sort_rank"], 0]]
      },
      "paint": {
        "text-color": "#4d4238",
        "text-halo-color": "rgba(255, 255, 255, 0.85)",
        "text-halo-width": 1.4
      }
    },
    {
      "id": "place-labels-city",
      "type": "symbol",
      "source": "protomaps",
      "source-layer": "places",
      "minzoom": 7,
      "filter": [
        "any",
        ["==", ["get", "kind_detail"], "city"],
        [
          "all",
          ["==", ["get", "kind"], "locality"],
          [">=", ["coalesce", ["get", "population_rank"], 0], 10]
        ]
      ],
      "layout": {
        "text-field": ["coalesce", ["get", "name:pl"], ["get", "name:en"], ["get", "name"]],
        "text-font": ["Noto Sans Medium"],
        "text-size": [
          "interpolate",
          ["linear"],
          ["zoom"],
          7,
          12,
          10,
          14,
          14,
          17
        ],
        "text-max-width": 8,
        "symbol-sort-key": ["*", -1, ["coalesce", ["get", "sort_rank"], 0]]
      },
      "paint": {
        "text-color": "#4d4238",
        "text-halo-color": "rgba(255, 255, 255, 0.84)",
        "text-halo-width": 1.3
      }
    },
    {
      "id": "place-labels-town",
      "type": "symbol",
      "source": "protomaps",
      "source-layer": "places",
      "minzoom": 8,
      "filter": [
        "any",
        [
          "all",
          ["==", ["get", "kind_detail"], "town"],
          [">=", ["coalesce", ["get", "population_rank"], 0], 7]
        ],
        [
          "all",
          ["==", ["get", "kind"], "locality"],
          [">=", ["coalesce", ["get", "population_rank"], 0], 8],
          ["<", ["coalesce", ["get", "population_rank"], 0], 10]
        ]
      ],
      "layout": {
        "text-field": ["coalesce", ["get", "name:pl"], ["get", "name:en"], ["get", "name"]],
        "text-font": ["Noto Sans Regular"],
        "text-size": [
          "interpolate",
          ["linear"],
          ["zoom"],
          8,
          10,
          10,
          12,
          14,
          14
        ],
        "text-max-width": 8,
        "symbol-sort-key": ["*", -1, ["coalesce", ["get", "sort_rank"], 0]]
      },
      "paint": {
        "text-color": "#4d4238",
        "text-halo-color": "rgba(255, 255, 255, 0.82)",
        "text-halo-width": 1.2
      }
    },
    {
      "id": "place-labels-village",
      "type": "symbol",
      "source": "protomaps",
      "source-layer": "places",
      "minzoom": 11,
      "filter": ["==", ["get", "kind_detail"], "village"],
      "layout": {
        "text-field": ["coalesce", ["get", "name:pl"], ["get", "name:en"], ["get", "name"]],
        "text-font": ["Noto Sans Regular"],
        "text-size": [
          "interpolate",
          ["linear"],
          ["zoom"],
          11,
          10,
          13,
          12,
          14,
          14
        ],
        "text-max-width": 8,
        "symbol-sort-key": ["*", -1, ["coalesce", ["get", "sort_rank"], 0]]
      },
      "paint": {
        "text-color": "#5a4f45",
        "text-halo-color": "rgba(255, 255, 255, 0.8)",
        "text-halo-width": 1.1
      }
    },
    {
      "id": "place-labels-local",
      "type": "symbol",
      "source": "protomaps",
      "source-layer": "places",
      "minzoom": 12,
      "filter": [
        "in",
        ["get", "kind_detail"],
        ["literal", ["hamlet", "locality", "farm", "isolated_dwelling"]]
      ],
      "layout": {
        "text-field": ["coalesce", ["get", "name:pl"], ["get", "name:en"], ["get", "name"]],
        "text-font": ["Noto Sans Regular"],
        "text-size": [
          "interpolate",
          ["linear"],
          ["zoom"],
          12,
          9,
          14,
          11
        ],
        "text-max-width": 7,
        "symbol-sort-key": ["*", -1, ["coalesce", ["get", "sort_rank"], 0]]
      },
      "paint": {
        "text-color": "#6b6056",
        "text-halo-color": "rgba(255, 255, 255, 0.78)",
        "text-halo-width": 1
      }
    },
    {
      "id": "place-labels-neighbourhood",
      "type": "symbol",
      "source": "protomaps",
      "source-layer": "places",
      "minzoom": 13,
      "filter": [
        "any",
        ["==", ["get", "kind"], "neighbourhood"],
        ["==", ["get", "kind"], "macrohood"],
        ["in", ["get", "kind_detail"], ["literal", ["neighbourhood", "quarter", "allotments"]]]
      ],
      "layout": {
        "text-field": ["coalesce", ["get", "name:pl"], ["get", "name:en"], ["get", "name"]],
        "text-font": ["Noto Sans Regular"],
        "text-size": [
          "interpolate",
          ["linear"],
          ["zoom"],
          13,
          9,
          14,
          10
        ],
        "text-max-width": 7,
        "symbol-sort-key": ["*", -1, ["coalesce", ["get", "sort_rank"], 0]]
      },
      "paint": {
        "text-color": "#766654",
        "text-halo-color": "rgba(255, 255, 255, 0.76)",
        "text-halo-width": 1
      }
    },
    {
      "id": "water-labels",
      "type": "symbol",
      "source": "protomaps",
      "source-layer": "water",
      "minzoom": 11,
      "filter": [
        "has",
        "name"
      ],
      "layout": {
        "symbol-placement": "line",
        "text-field": ["coalesce", ["get", "name:pl"], ["get", "name:en"], ["get", "name"]],
        "text-font": ["Noto Sans Italic"],
        "text-size": 11
      },
      "paint": {
        "text-color": "#4f91b2",
        "text-halo-color": "rgba(255, 255, 255, 0.78)",
        "text-halo-width": 1
      }
    },
    {
      "id": "road-labels",
      "type": "symbol",
      "source": "protomaps",
      "source-layer": "roads",
      "minzoom": 13,
      "filter": [
        "has",
        "name"
      ],
      "layout": {
        "symbol-placement": "line",
        "text-field": ["get", "name"],
        "text-font": ["Noto Sans Regular"],
        "text-size": 11,
        "text-max-angle": 30
      },
      "paint": {
        "text-color": "#766654",
        "text-halo-color": "rgba(255, 255, 255, 0.84)",
        "text-halo-width": 1
      }
    },
    {
      "id": "protected-area-labels",
      "type": "symbol",
      "source": "protomaps",
      "source-layer": "pois",
      "minzoom": 9,
      "filter": [
        "all",
        [
          "in",
          ["get", "kind"],
          ["literal", ["national_park", "nature_reserve", "protected_area"]]
        ],
        [
          "any",
          ["has", "name"],
          ["has", "name:pl"],
          ["has", "name:en"]
        ]
      ],
      "layout": {
        "text-field": ["coalesce", ["get", "name:pl"], ["get", "name:en"], ["get", "name"]],
        "text-font": ["Noto Sans Italic"],
        "text-size": [
          "interpolate",
          ["linear"],
          ["zoom"],
          9,
          10,
          12,
          12,
          14,
          14
        ],
        "text-max-width": 10,
        "text-letter-spacing": 0.02
      },
      "paint": {
        "text-color": "#3d6b3a",
        "text-halo-color": "rgba(255, 255, 255, 0.85)",
        "text-halo-width": 1.4
      }
    },
    {
      "id": "road-shields",
      "type": "symbol",
      "source": "protomaps",
      "source-layer": "roads",
      "minzoom": 8,
      "filter": [
        "any",
        ["has", "shield_text"],
        ["has", "ref"]
      ],
      "layout": {
        "symbol-placement": "line",
        "symbol-spacing": 360,
        "text-field": ["coalesce", ["get", "shield_text"], ["get", "ref"]],
        "text-font": ["Noto Sans Medium"],
        "text-size": 9,
        "text-padding": 2
      },
      "paint": {
        "text-color": "#4d4238",
        "text-halo-color": "rgba(255, 255, 255, 0.9)",
        "text-halo-width": 1.4
      }
    }
  ]
}
